win (XP) "@" in a field -Keycombination (QWERTZ only)

Malte Brill malte.brill at t-online.de
Wed Jun 23 07:56:07 EDT 2004


Hi List.

I hope this didn´t come up before.

On German keyboard layouts (QWERTZ) it is possible to have the "@" character
typed in in 2 ways.

1: ctrl+alt (left side of the keyboard)+q
2: alt gr (right side of keyboard)+q

While 2 works (tested on on XP) 1 doesn´t. It is not a major issue for me.
But people want things to behave like thei´re used to.

Here is a quick fix:

in the field´s script:

on commandkeydown thekey
  if theKey="q" and the optionkey is down then
    put word 2 of the selectedChunk into selectionStart
    put word 4 of the selectedchunk into selectionEnd
    if selectionStart-SelectionEnd=1 then
      put "@" after char (selectionEnd) of me
    else
      put "@" into char (selectionStart) to (selectionEnd) of me
    end if
  else
    pass commandKeyDown
  end if
end commandkeydown 

If anyone could check this for 98,ME or 2000 with a german keyboard (QWERTZ)
Layout, I´d be really thankful.

I suspect that other keyboard layouts might have similar keycombination
problems. So maybe someone else will find it useful.

Best,

Malte





More information about the use-livecode mailing list