#107 CodeCompletion is keyboard-dependent

closed
nobody
None
5
2007-04-16
2006-09-20
Nicolas Chopin
No

CodeCompletion does not work out of the box for French,
and presumably other foreign keyboards. I could make it
work by doing the following quick and dirty edit:

# Initial Code
DrFrame.AddKeyEvent(OnAutoComplete, ord('.'))
DrFrame.AddKeyEvent(OnCallTip, ord('9'), Shift=1)
DrFrame.AddKeyEvent(OnHideCallTip, ord('0'), Shift=1)

# to be replaced by
DrFrame.AddKeyEvent(OnAutoComplete, 59)
DrFrame.AddKeyEvent(OnCallTip, ord('('))
DrFrame.AddKeyEvent(OnHideCallTip, ord(')'))

The number 59 may be specific to French keyboard, but
for two next commands, I guess ord('(') should be
"universal", and should make more sense that the
hard-coded parenthesis.

My laptop has UK keyboard, and codecompletion works out
of the box.

I don't know how easy it is to work around this
problem, but it would be nice to issue at least a
warning when plugin is installed, so that users know
they have to edit the *.py file.

BTW, to have calltips for additional libraries, one can
also add:
from lib import *
in CodeCompletion.py
I guess this is not very elegant, but I find it useful.
Again, maybe a short notice to users...

Discussion

  • Logged In: YES
    user_id=772872

    Thank you for your tip.

     
    • status: open --> closed