private void drawTextUILayout(TextUILayout drawable, IDrawer drawer) { drawer.DrawString( drawable.Font, drawable.Area, drawable.Tint, drawable.Text, drawable.SourceRectangle ); }
/// <summary> /// Draw the form on the screen /// </summary> /// <param name="screen">Instance of IDrawable device</param> public virtual void Paint(IDrawer screen) { // Paint once if (!initPaint) { return; } screen.FillRectangle(0, titleBarSize, screen.Width, screen.Height - titleBarSize, this.BackgroundColor); initPaint = false; screen.FillRectangle(0, 0, screen.Width, titleBarSize, FEZ_Components.FEZTouch.Color.Black); screen.DrawString(this.Title, 5, 5, FEZ_Components.FEZTouch.Color.White, FEZ_Components.FEZTouch.Color.Black); }
/// <summary> /// Draw the Grid /// </summary> /// <param name="screen">Screen device</param> public override void Paint(IDrawer screen) { base.Paint(screen); for (int i = 0; i < ControlRows; i++) { for (int j = 0; j < ControlColumns; j++) { String currentControl = Controls[i][j]; if (currentControl != null && currentControl != String.Empty) { int x = xOffset + (j * xDrawable / 2); int y = yOffset + (i * FEZ_Components.FEZTouch.FONT_HEIGHT + 2); screen.DrawString(currentControl, x, y, this.ForegroundColor, this.BackgroundColor); } } } }