Пример #1
0
/*
 * Function:	Draw
 *
 * Description:	draw the "STI Lights" items
 *
 * Parameters:
 *		void
 * 
 * Return Values
 *		none
 *
 * Discussion:
 *
 *				Upon entry, draw the control items necessary to perform
 *				the STI Lights diagnostics
 */
void
TCDSti::Draw(void) 
{
	if (m_HardwareMode == SOFTWARE_ONLY)
	{
		m_IBox.SetWindowText("System Alarm tests are unavailable in "\
			"SOFTWARE ONLY mode.");
	}
	else
	{
		CClientDC dc((CWnd *)m_pMainWnd);
//		m_pMainWnd->OnPrepareDC(&dc);

		CFont *oldFont = dc.SelectObject(&m_dlgFont);
		int oldBkMode  = dc.SetBkMode(TRANSPARENT);

		dc.DrawEdge(m_MoveBox, EDGE_ETCHED, BF_RECT);
		dc.DrawEdge(m_LEDBox,  EDGE_ETCHED, BF_RECT);

		// picture border
		dc.DrawEdge(CRect(298,18, 302+NCAM_XPIXELS, 22+NCAM_YPIXELS),  EDGE_SUNKEN, BF_RECT);
		dc.DrawEdge(CRect(294,14, 306+NCAM_XPIXELS, 26+NCAM_YPIXELS),  EDGE_RAISED, BF_RECT);

		// display the snapshot
		m_Picture.Draw(&dc, CPoint(300,20), m_Picture.GetDimensions());

		// draw alignment circles
		DrawCircles();
	}
}
Пример #2
0
/*
 * Function:	AlignmentSnap
 *
 * Description:	setup and take a 'snapshots'
 *
 * Parameters:
 *		void
 * 
 * Return Values
 *		none
 *
 * Discussion:
 *
 *				get Led 'OnOff' state from TCDLedButton, write the definitions
 *				into dome memory and flash the LED's
 */
void
TCDSti::AlignmentSnap(void)
{
	DomeReset();

	GetLeds();
	SnapShot(70);
	DrawCircles();
}
Пример #3
0
Файл: main.cpp Проект: EQ4/axLib
void MidiPartition::OnPaint()
{
	axGC* gc = GetGC();
	axRect rect(GetRect());
	axRect rect0(axPoint(0, 0), rect.size);

	gc->SetColor(axColor(0.3, 0.3, 0.3), 1.0);
	gc->DrawRectangle(rect0);

	DrawLines(gc, rect0);
	DrawHeighlightedCircle(gc, rect0);
	DrawCircles(gc, rect0);
	DrawSelectedCircle(gc, rect0);

	gc->SetColor(axColor(0.0, 0.0, 0.0), 1.0);
	gc->DrawRectangleContour(rect0);
}
Пример #4
0
void TestOLED()
{
	/* if your display isn't working, this is a good place to start -- see
	   if you can read the command register */
	TestReadStatus();

	EnableFill(true);

//	FindEdges();
	DrawEdges();
	DrawFullRect();
	ScrollDisplay();
//	DrawColorBars();
	FillScreenPixels();
	DrawCircles();
	
	TestReadPixel();
}