Marek,
here is a version of the menuPick handler that works for ASCII and Unicode Labels. But probably only as long as the bug is not fixed.
It is probably a good idea to mark all pull-down menus you modify to change them once the bug is fixed. (also the ones with the short work around)
By the way I higly recommend lcTaskList by Bill Vlahos $10 in the Livecode store for this kind of marking. You see all the marks , which you can also custom define, in all script at a glance. (disclaimer: no financial interest in lcTaskList)
Code: Select all
on menuPick pItemName
   -- -- if you want to see what is in pItemName
   --   put "" into msg
   --   repeat for each char aChar in pItemName
   --      put charToNum(aChar) & "-"  after msg
   --   end repeat
   
   if "unicodeLabel" is among the keys of the properties of me then
      set the unicodeText of the templateField to pItemName
      put the text of the templateField into pItemName
      reset the templateField
   end if
   
   switch pItemName
      case "Choice 1" 
         answer "Choice 1"
         break
      case "Choice 2"
         answer "Choice 2"
         break
      case "Choice 3"
         answer "Choice 3"
         break
      default
         answer "default, not Choice n"
   end switch
end menuPick
if you put pItemName for "Choice 1" in its unicode glory you see
Code: Select all
67-0-104-0-111-0-105-0-99-0-101-0-32-0-49-0-
As to why it is so: maybe an attempt to use unicode throughout once a unicode label is defined????
I think I stop now fooling around with unicode in Livecode, it is not good for my mental health. I admire you, Marek, and all the others that use Livecode in a non-ASCII language.
Kind regards
Bernd