Author Topic: Label text is ugly at runtime  (Read 1537 times)

ScottyP

  • Newbie
  • *
  • Posts: 15
    • View Profile
Label text is ugly at runtime
« on: April 20, 2021, 04:48:43 AM »
Hi folks,

I have a basic label (windows forms control) with white text on a black background (though the backcolour isnt the issue) and it looks fine at design time but when the application runs, the text looks multicoloured and "bitty" as if you can see through the letters.

Any ideas? Looks rubbish on screen especially on a large display. Not sure if this VS issue or AHMI.

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5268
    • View Profile
    • AdvancedHMI
Re: Label text is ugly at runtime
« Reply #1 on: April 20, 2021, 05:44:23 AM »
Add a Label to the form instead of a BasicLabel to see if it has the same problem.

ScottyP

  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: Label text is ugly at runtime
« Reply #2 on: April 20, 2021, 08:17:07 AM »
Hi Archie, yep same problem. It looks fine on the form till run time then it looks like it breaks up into dots with coloured ones among white ones. Hard to explain but can try to add a picture if that's possible to upload. I do have a background image on the form and the label is set to black background with white text, but various combinations of fore and back colour have the same effect.

Studio 2019 and AHMI 3.99 - forgot to mention.
« Last Edit: April 20, 2021, 08:19:41 AM by ScottyP »

Godra

  • Hero Member
  • *****
  • Posts: 1438
    • View Profile
Re: Label text is ugly at runtime
« Reply #3 on: April 20, 2021, 04:40:26 PM »
You have not provided information about your display and its settings.

Have you tried creating a new Visual Studio project, non-AHMI, to see how it displays visual controls?

ScottyP

  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: Label text is ugly at runtime
« Reply #4 on: April 21, 2021, 06:15:44 AM »
Hi, I can do. I am about to start a new project so will soon find out. I've written hundreds of desktop apps with VB before but have never seen this happen. Admittedly I'm new to VS and .NET apps but the main difference is Object based code rather than anything else.

This issue affects every display the software has been run on so far. I'm a controls engineer, tried it on a Dell laptop screen, large Samsung LED HD TV and a PC monitor, all fairly recent hardware (and different computers for each display). Same result on all. The label text looks perfect on the design screen, and this issue only affects the "label" designated controls. Items like the BevelButtonDisplay do not suffer any change when running.

Vitor

  • Newbie
  • *
  • Posts: 20
    • View Profile
Re: Label text is ugly at runtime
« Reply #5 on: April 21, 2021, 03:07:07 PM »
The problem its the size of TV or monitor.
If you try it on a 15 or 17 or 21" will appear better. But if you use a 50" TV or monitor it becames really ugly.
One solution its use a diferent font or font size, ex font Segoe UI or Arial size 12

ScottyP

  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: Label text is ugly at runtime
« Reply #6 on: May 03, 2021, 11:17:18 AM »
No it's the same on every device. Tried 15" laptop screen, big TV etc. I do have a picture background on the form and I think that is what's causing the label to render badly.