📄 mainform.c
字号:
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
xPosEnd = xPosBegin;
yPosEnd = PlotPixelY + TraceAmp;
WinDrawLine (xPosBegin, yPosBegin, xPosEnd, yPosEnd);
}
else if (CurrValue[0] == true)
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
WinDrawPixel (xPosBegin, yPosBegin);
}
else
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY + TraceAmp;
WinDrawPixel (xPosBegin, yPosBegin);
WinDrawPixel (xPosBegin, (yPosBegin -1));
}
PrevValue[0] = CurrValue[0];
PlotPixelY += (TraceAmp + InterSpc);
}
else
{
CtlHideControl(GetObjectPtr(frmMainCh0LabelButton));
}
/*============================================================*/
/* Do Channel 1 if it is active. */
/*============================================================*/
if (AppPrefs.bChnlOn[1] == true)
{
CtlHideControl(GetObjectPtr(frmMainCh1LabelButton));
FrmSetObjectPosition(pFrm,
FrmGetObjectIndex(pFrm, frmMainCh1LabelButton),
0, PlotPixelY);
CtlShowControl(GetObjectPtr(frmMainCh1LabelButton));
if (CurrValue[1] != PrevValue[1])
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
xPosEnd = xPosBegin;
yPosEnd = PlotPixelY + TraceAmp;
WinDrawLine (xPosBegin, yPosBegin, xPosEnd, yPosEnd);
}
else if (CurrValue[1] == true)
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
WinDrawPixel (xPosBegin, yPosBegin);
}
else
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY + TraceAmp;
WinDrawPixel (xPosBegin, yPosBegin);
WinDrawPixel (xPosBegin, (yPosBegin -1));
}
PrevValue[1] = CurrValue[1];
PlotPixelY += (TraceAmp + InterSpc);
}
else
{
CtlHideControl(GetObjectPtr(frmMainCh1LabelButton));
}
/*============================================================*/
/* Do Channel 2 if it is active. */
/*============================================================*/
if (AppPrefs.bChnlOn[2] == true)
{
CtlHideControl(GetObjectPtr(frmMainCh2LabelButton));
FrmSetObjectPosition(pFrm,
FrmGetObjectIndex(pFrm, frmMainCh2LabelButton),
0, PlotPixelY);
CtlShowControl(GetObjectPtr(frmMainCh2LabelButton));
if (CurrValue[2] != PrevValue[2])
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
xPosEnd = xPosBegin;
yPosEnd = PlotPixelY + TraceAmp;
WinDrawLine (xPosBegin, yPosBegin, xPosEnd, yPosEnd);
}
else if (CurrValue[2] == true)
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
WinDrawPixel (xPosBegin, yPosBegin);
}
else
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY + TraceAmp;
WinDrawPixel (xPosBegin, yPosBegin);
WinDrawPixel (xPosBegin, (yPosBegin -1));
}
PrevValue[2] = CurrValue[2];
PlotPixelY += (TraceAmp + InterSpc);
}
else
{
CtlHideControl(GetObjectPtr(frmMainCh2LabelButton));
}
/*============================================================*/
/* Do Channel 3 if it is active. */
/*============================================================*/
if (AppPrefs.bChnlOn[3] == true)
{
CtlHideControl(GetObjectPtr(frmMainCh3LabelButton));
FrmSetObjectPosition(pFrm,
FrmGetObjectIndex(pFrm, frmMainCh3LabelButton),
0, PlotPixelY);
CtlShowControl(GetObjectPtr(frmMainCh3LabelButton));
if (CurrValue[3] != PrevValue[3])
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
xPosEnd = xPosBegin;
yPosEnd = PlotPixelY + TraceAmp;
WinDrawLine (xPosBegin, yPosBegin, xPosEnd, yPosEnd);
}
else if (CurrValue[3] == true)
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
WinDrawPixel (xPosBegin, yPosBegin);
}
else
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY + TraceAmp;
WinDrawPixel (xPosBegin, yPosBegin);
WinDrawPixel (xPosBegin, (yPosBegin -1));
}
PrevValue[3] = CurrValue[3];
PlotPixelY += (TraceAmp + InterSpc);
}
else
{
CtlHideControl(GetObjectPtr(frmMainCh3LabelButton));
}
/*============================================================*/
/* Do Channel 4 if it is active. */
/*============================================================*/
if (AppPrefs.bChnlOn[4] == true)
{
CtlHideControl(GetObjectPtr(frmMainCh4LabelButton));
FrmSetObjectPosition(pFrm,
FrmGetObjectIndex(pFrm, frmMainCh4LabelButton),
0, PlotPixelY);
CtlShowControl(GetObjectPtr(frmMainCh4LabelButton));
if (CurrValue[4] != PrevValue[4])
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
xPosEnd = xPosBegin;
yPosEnd = PlotPixelY + TraceAmp;
WinDrawLine (xPosBegin, yPosBegin, xPosEnd, yPosEnd);
}
else if (CurrValue[4] == true)
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
WinDrawPixel (xPosBegin, yPosBegin);
}
else
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY + TraceAmp;
WinDrawPixel (xPosBegin, yPosBegin);
WinDrawPixel (xPosBegin, (yPosBegin -1));
}
PrevValue[4] = CurrValue[4];
PlotPixelY += (TraceAmp + InterSpc);
}
else
{
CtlHideControl(GetObjectPtr(frmMainCh4LabelButton));
}
/*============================================================*/
/* Do Channel 5 if it is active. */
/*============================================================*/
if (AppPrefs.bChnlOn[5] == true)
{
CtlHideControl(GetObjectPtr(frmMainCh5LabelButton));
FrmSetObjectPosition(pFrm,
FrmGetObjectIndex(pFrm, frmMainCh5LabelButton),
0, PlotPixelY);
CtlShowControl(GetObjectPtr(frmMainCh5LabelButton));
if (CurrValue[5] != PrevValue[5])
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
xPosEnd = xPosBegin;
yPosEnd = PlotPixelY + TraceAmp;
WinDrawLine (xPosBegin, yPosBegin, xPosEnd, yPosEnd);
}
else if (CurrValue[5] == true)
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY;
WinDrawPixel (xPosBegin, yPosBegin);
}
else
{
xPosBegin = 24 + ((UInt32)SmplIdx * 136 /
(PlotData.PlotToSmplIdx -
PlotData.PlotFromSmplIdx));
yPosBegin = PlotPixelY + TraceAmp;
WinDrawPixel (xPosBegin, yPosBegin);
WinDrawPixel (xPosBegin, (yPosBegin -1));
}
PrevValue[5] = CurrValue[5];
PlotPixelY += (TraceAmp + InterSpc);
}
else
{
CtlHideControl(GetObjectPtr(frmMainCh5LabelButton));
}
/*============================================================*/
/* Do Channel 6 if it is active. */
/*============================================================*/
if (AppPrefs.bChnlOn[6] == true)
{
CtlHideControl(GetObjectPtr(frmMainCh6LabelButton));
FrmSetObjectPosition(pFrm,
FrmGetObjectIndex(pFrm, frmMainCh6LabelButton),
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -