Beispiel #1
0
 protected virtual void Draw()
 {
     lcd.DrawBox(dialogWindowOuther, true);
     lcd.DrawBox(dialogWindowInner, false);
     OnDrawContent();
     lcd.WriteTextBox(font, titleRect, title, false, Lcd.Alignment.Center);
     lcd.Update();
 }
Beispiel #2
0
        public void Draw(Font f, Rectangle r, bool color)
        {
            int       xCheckBoxSize = (int)f.maxWidth;
            Rectangle outer         = new Rectangle(new Point(Lcd.Width - xCheckBoxSize + edgeSize, r.P1.Y + edgeSize), new Point(r.P2.X - edgeSize, r.P2.Y - edgeSize));
            Rectangle innter        = new Rectangle(new Point(Lcd.Width - xCheckBoxSize + lineSize + edgeSize, r.P1.Y + lineSize + edgeSize), new Point(r.P2.X - lineSize - edgeSize, r.P2.Y - lineSize - edgeSize));
            Point     fontPoint     = f.TextSize("v");
            Point     checkPoint    = new Point(Lcd.Width - xCheckBoxSize + (int)fontPoint.X - edgeSize, r.P1.Y);

            lcd.WriteTextBox(f, r, text, color);
            lcd.DrawBox(outer, color);
            lcd.DrawBox(innter, !color);
            if (Checked)
            {
                lcd.WriteText(f, checkPoint, "v", color);
            }
        }