viewpoint-particle

Author Topic: unicode in a dialog?  (Read 273 times)

kdmoyers

  • Sr. Member
  • ****
  • Posts: 307
unicode in a dialog?
« on: June 15, 2019, 01:53:38 pm »
Is there a trick for getting some unicode text in a dialog?  I need the little clockwise and counterclockwise arrow characters (21BA and 21BB).

I was really hoping to find those chars in some common windows fonts, but so far no luck.  LOTS and LOTS of arrows of various flavors, but not those two.

I have already given up and used a bitmap, but it looks messy.

TIA,
-K
The mind is everything; What you think, you become.

td

  • Tech Support
  • *****
  • Posts: 3210
    • WinBatch
Re: unicode in a dialog?
« Reply #1 on: June 15, 2019, 04:49:28 pm »
Another case of big-endian/little-endian?  Consider the following:
Code: Winbatch
vtClock     = ChrHexToUnicode('BB21')
vtAntiClock = ChrHexToUnicode('BA21')

MyDialogFormat=`WWWDLGED,6.2`

MyDialogCaption=`WIL Dialog 1`
MyDialogX=3183
MyDialogY=164
MyDialogWidth=320
MyDialogHeight=153
MyDialogNumControls=004
MyDialogProcedure=`DEFAULT`
MyDialogFont=`DEFAULT`
MyDialogTextColor=`DEFAULT`
MyDialogBackground=`DEFAULT,DEFAULT`
MyDialogConfig=0
MyDialogDPI=`192,10,20`

MyDialog001=`025,122,049,016,PUSHBUTTON,"PushButton_OK",DEFAULT,"OK",1,10,@csDefButton,DEFAULT,DEFAULT,DEFAULT`
MyDialog002=`242,122,050,016,PUSHBUTTON,"PushButton_Cancel",DEFAULT,"Cancel",0,20,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog003=`098,044,022,016,VARYTEXT,"VaryText_1",vtClock,"Vary 1",DEFAULT,30,DEFAULT,"Arial Unicode MS|8602|40|34",DEFAULT,DEFAULT`
MyDialog004=`172,044,024,016,VARYTEXT,"VaryText_2",vtAntiClock,"Vary 2",DEFAULT,40,DEFAULT,"Arial Unicode MS|8602|40|34",DEFAULT,DEFAULT`

ButtonPushed=Dialog("MyDialog")
"No one who sees a peregrine falcon fly can ever forget the beauty and thrill of that flight."
  - Dr. Tom Cade

kdmoyers

  • Sr. Member
  • ****
  • Posts: 307
Re: unicode in a dialog?
« Reply #2 on: June 17, 2019, 05:06:03 am »
This is revelatory in two ways.  (1) I didn't know the default font could display unicode.  (2) never in a million years would I have thought to reverse the bytes.  Thanks man -- works great!
The mind is everything; What you think, you become.