07-08-2015 09:25 AM
Dear all,
I use Labwindows CVI, and would like to write the text « Ref= 50 Ω » on a label text but this does not work correctly. It seems to me that I cannot mix the symbol « Ω » with letters in the same text label. So, I write in different two text labels separatly the text « Ref= 50» and the text « Ω ». The two text labels are near each other, just to make them like they are written in a same text label. When the application is not resized, this seems to work fine.
However, when I resize the panel application, the symbol « Ω » moves write the other text label. In the final, the two text labels become far away each from other, and they do not look like they are together.
I would like to know how can write « Ref= 50 Ω » in one text label, or how can I avoid the moving of text labels when the Panel is resized.
Thank you in advance for your answer.
Best regards,
--
Hapiest
Solved! Go to Solution.
07-08-2015 09:56 AM
That's not a easy task: the best I can suggest you is to find a font that includes both alphanumeric digits and symbols. Unfortunately it seems you have very limited choices: on my system (Win7 with 130+ elements in windows/fonts folder) only NISYSTEM font permits to obtain that label but with a very ugly aspect in my opinion.
See here:
07-08-2015 09:56 AM - edited 07-08-2015 10:08 AM
I think that at present this is not easily possible... it would work for a Unicode character set, but right now Unicode is not supported (see here if you want to help changing it)
... I see (Roberto was faster by two seconds) that it IS possible...
Anyway, my suggested way out would be to write "Ref = 50 Ohm", no symbol
07-08-2015 10:51 AM
could you please tell me which symbol you gave to print Ω symbol with (NISYSTEM, wstern)?
07-08-2015 11:18 AM
Actually, even absent Unicode support, in this particular case you don't have to be stuck with the NISYSTEM font.
You can use any common font, as long as you specify the Greek character set. This works because practically all non-Western character sets also support the unaccented western European characters (i.e. the ASCII codes 0 - 127). So, for example, while it's true that without Unicode you can't combine Greek characters with Turkish characters in the same text label, you can however combine Greek with English and you can combine Turkish with English.
Entering the text in the control is a different matter. If you're pasting the string, it's straightforward. But if you're typing, you need to toggle your keyboard language input, so that you can enter the codes that correspond to the character you want (for example, the omega character).
To change the keyboard input, you first need to make sure the language bar is visible in your taskbar:
Then you need to populate it with the languages you might ever want to enter:
Once you do this, you should have the languages you need in your taskbar:
You need to then pick the language corresponding to the characters you wish to enter and then type the keys that correspond to those characters. For the omega character, you'll need to switch to Greek and press the 'v' key (in a typical English keyboard):
07-08-2015 12:07 PM
awesome...
Now I've learnt even how to show the assignment of keys in Windows, after so many years I've seen this keyboard layout preview the first time...
Thanks for this great answer
07-09-2015 02:48 AM
Luis, that's definitely the best solution to this problem I've ever heard!
Till now I was used to type in the codes corresponding to the symbols I most frequently used (e.g. Alt+246 for ÷, or Alt+241 for ±), and I couldn't obtain the Ω!
I see that I can do the same programmatically, provided I ignore that in the source editor the string is displayed with a different symbol, trusting that the final result will be correct:
07-09-2015 03:15 AM
wonderful!
Thank you for all, clear and efficient!
07-09-2015 03:24 AM
you made a mistake... you should mark the answer of Luis as solution to your problem (not my comment)
07-09-2015 03:28 AM
Sorry, yes thank you again LuisG!