Meadow.Foundation icon indicating copy to clipboard operation
Meadow.Foundation copied to clipboard

MicroLayout - DisplayLabel should clip text if its outside of width and heigth values

Open jorgedevs opened this issue 1 year ago • 2 comments

On a Project Lab v3, conside the following MicroLayoutSample

_screen.Controls.Add(
                new DisplayBox(0, 0, _screen.Width, _screen.Height)
                {
                    ForeColor = Color.White
                },
                new DisplayLabel(60, 20, 100, 40)
                {
                    Text = "Welcome to MicroLayout!",
                    TextColor = Color.Black,
                    BackColor = Color.Red,
                    Font = new Font12x20(),
                    VerticalAlignment = VerticalAlignment.Center,
                    HorizontalAlignment = HorizontalAlignment.Center
                });

Notice that the background color (red) delimits the bounds of this control, yet on the Text is drawn outside these boundaries.

image

jorgedevs avatar Aug 15 '23 20:08 jorgedevs