Page 1 of 1
Wish List: Support for Non-Unicode Paste
Posted: Sat Nov 26, 2011 2:21 pm
by PGilbert
If I do a copy of a function from a non-unicode APL interpreter (APL+Win) and paste it into a Dyalog Unicode interpreter, the APL characters are lost (garbled) in the paste. I know that there is the ]IN and ]OUT function to do that but sometimes you just need to do a quick copy/paste of something. Is a 'Paste Non-Unicode' choice in the Dyalog menu would fix that issue or it's more complicated than that ?
Pierre Gilbert
Re: Wish List: Support for Non-Unicode Paste
Posted: Mon Nov 28, 2011 2:01 pm
by AndyS|Dyalog
It is a little more complicated than that :-(
Different APLs hold APL characters using different bytes; for example, in a Classic Dyalog APL, ⍺ and ⍵ are held as 184 and 190 respectively - I believe that APL+Win holds them as 224 and 23. To be able to paste from another APL into Dyalog would require us to include the appropriate mapping in the interpreter - and to be able to identify when such a mapping was needed.
However, it should be possible to do something with the Clipboard object .. one option that springs to mind is to create a function which reads the Text from a clipboard object, applies a mapping, and replaces that newly mapped text in the clipboard - at which point you could paste into Dyalog APL (or indeed, the other way around) .. and you could then add an icon into your session which had that mapping function as its callback. You could also add a callback to the ClipChange event, but you'd have to work out what needed to be done at that point !
If only everyone supported Unicode text ..
Re: Wish List: Support for Non-Unicode Paste
Posted: Mon Nov 28, 2011 2:49 pm
by PGilbert
Thanks Andy for your reply this is helpfull. Too bad that all the APL vendors don't have something has basic has their []AV all the same.