LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

arial font substitution for (LabVIEW for) Linux

Hello,
as LabVIEW was not capable of keeping the font size and spacing constant when running a VI under different Windows versions, screen resolutions etc, I have never used the "application", "system" and "dialog" font options in LabVIEW but have fixed all fonts to Arial 14 pt. This worked wonderful on all Windows systems - without that unnerving problem that control lables overwrite each other and things like that (what always happened when using LabVIEWs "application" font option).

Now, when running the same VIs under LabVIEW for Linux, the font looks terrible, as there is no Arial font in Linux. Does somebody know an easy way to solve this problem without setting all fonts to "application font" in LabVIEW? For instance, any "ini file type" setting in Linux telling the operating system which font to use when Arial is not present, or any free font substitution that we could add to our installer routine that the operating system would use automatically instead of Arial?

Best regards,
Gabs
0 Kudos
Message 1 of 5
(4,103 Views)
Hi Gabs,

you already posted that question about three years, ago.
http://forums.ni.com/ni/board/message?board.id=170&message.id=89833&requireLogin=False

Didn't this post solve your problem?

Daniel
NIG
Message 2 of 5
(4,079 Views)
Hello Daniel,
no, it didn't help (even if it was a great hint; I should have posted that in my thread 3 years ago, sorry...). The fonts in my VI still look terribly large. There is a file "fonts.conf" (Fontconfig) but it looks like LabVIEW does not change the font size on the front panels when changing anything globally. Another problem is that we do not know which Linux distribution our customers are using, therefore any distrubution-specific solution is not the best way to solve this problem. So I was hoping that LabVIEW with its new version for Linux has some better solution now...
Best regards,
Gabriela
0 Kudos
Message 3 of 5
(4,069 Views)
Hi Gabriela,

there is only one solution to your problem and that's the system fonts (because that's the case they were made for). I don't see another way to solve this one. Sorry...

Daniel
NIG
0 Kudos
Message 4 of 5
(4,053 Views)
Unfortunately, your problem is a version of a generic problem faced by GUI programmers of all types - how do you handle varying system fonts?  There are various solutions, based on who your customers are.  You are using one of the easy ones that works well until you start doing cross-platform development.  The main options are, in order or increasing complexity:
  1. Lock the font to a specific font and size.  This works well if your customers are limited to a single platform and are not visually impaired (do not want to use large fonts).
  2. Use system fonts and allow extra space.  This is a compromise that only works in most cases.  Use about 50% extra for small strings and 10% - 20% for larger strings.  This also gives you extra space for localization, should you need it.  Visually impaired customers will run into space issues, because large fonts can be 2X or more larger than the default, system fonts.  Note that the different Windows variants have different font sizes as well.  Windows Vista increased default font sizes, especially for some Asian languages, such as Japanese.
  3. Query the font size on entry into a GUI VI and rescale everything appropriately.  This is hard, since it must be done for every VI with a GUI.  Some system dialogs do not handle large fonts well, so you will probably end up replacing them with your own versions to get good appearance.  You could probably write a system to handle this sort of scaling, but to my knowledge, no one has (please prove me wrong Smiley Wink).  I have always used custom code when needed.
No one really does this well.  Change your system font on a Windows OS to large fonts and note all the problems you run into.  I would recommend option 2, unless you have a lot of extra time.  Your customers will love you if you pull off option 3.

More tips to help.
  1. Do your development on the platform with the largest system fonts.  If this is not possible, change the LabVIEW system fonts of your development system to match the largest size you support.  I usually develop using 13pt Verdana, since it is one of the largest of the variable spaced fonts.
  2. Check your work by using large fonts in Windows.  If it looks good there, it will probably be OK for most uses.
Good luck!
Message 5 of 5
(4,039 Views)