I need to be able to enter French accents into input fields, eg: é.
According to this site, http://www3.uakron.edu/modlang/french/keyboard.html, it is possible to enter é from a normal keyboard by pressing:
Ctrl+' (apostrophe) then e, and in Word, this works.
However as the following example shows, wx.TextCtrls do not accept characters in this way; they only see the e, not the é.
I notice that Thunderbird doesn't see the é, either, so maybe this is a particularly thorny problem. In any case, my client is refusing to install a real French Canadian keyboard, preferring to enter accents as above.
Any ideas?
Here is a simple sample that shows the problem:
import wx
class Test(wx.App):
def OnInit(self):
self.frame=wx.Frame(None,-1)
panel=wx.Panel(self.frame,-1)
tc=wx.TextCtrl(panel,-1)
self.frame.Show()
return(True)
It works however with wxPython 2.8 unicode built on Ubuntu. Maybe you
should specify your wxPython (version, ansi/unicode) and OS.
Stani
···
--
Hank Knox schreef:
I need to be able to enter French accents into input fields, eg: é.
According to this site, http://www3.uakron.edu/modlang/french/keyboard.html, it is possible to
enter é from a normal keyboard by pressing:
Ctrl+' (apostrophe) then e, and in Word, this works.
However as the following example shows, wx.TextCtrls do not accept
characters in this way; they only see the e, not the é.
I notice that Thunderbird doesn't see the é, either, so maybe this is a
particularly thorny problem. In any case, my client is refusing to
install a real French Canadian keyboard, preferring to enter accents as
above.
Any ideas?
Here is a simple sample that shows the problem:
import wx
class Test(wx.App):
def OnInit(self):
self.frame=wx.Frame(None,-1)
panel=wx.Panel(self.frame,-1)
tc=wx.TextCtrl(panel,-1)
self.frame.Show()
return(True)
app=Test()
app.MainLoop()
Thanks,
Hank
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org
I need to be able to enter French accents into input fields, eg: é.
According to this site, http://www3.uakron.edu/modlang/french/keyboard.html, it is possible to enter é from a normal keyboard by pressing:
Ctrl+' (apostrophe) then e, and in Word, this works.
However as the following example shows, wx.TextCtrls do not accept characters in this way; they only see the e, not the é.
I notice that Thunderbird doesn't see the é, either, so maybe this is a particularly thorny problem. In any case, my client is refusing to install a real French Canadian keyboard, preferring to enter accents as above.
Any ideas?
You don't need a french keyboard to be able to set change the keyboard settings for the OS. You can load multiple keyboard settings and switch between them via a tool on the taskbar. Then you just need to learn where the keys you want are located on the keyboard.
···
--
Robin Dunn
Software Craftsman http://wxPython.org Java give you jitters? Relax with wxPython!
I need to be able to enter French accents into input fields, eg: é.
According to this site, http://www3.uakron.edu/modlang/french/keyboard.html, it is possible to enter é from a normal keyboard by pressing:
Ctrl+' (apostrophe) then e, and in Word, this works.
However as the following example shows, wx.TextCtrls do not accept characters in this way; they only see the e, not the é.
To produce acute accents on each of the vowels, type the letter with the Alt-Gr key down. It works with Thunderbird as well - áéíóú. Voila!
I notice that Thunderbird doesn't see the é, either, so maybe this is a particularly thorny problem. In any case, my client is refusing to install a real French Canadian keyboard, preferring to enter accents as above.
Any ideas?
You don't need a french keyboard to be able to set change the keyboard settings for the OS. You can load multiple keyboard settings and switch between them via a tool on the taskbar. Then you just need to learn where the keys you want are located on the keyboard.
I explained myself poorly; I suggested to my client that they change the keyboard settings as you mentioned but they seem unwilling, they prefer to use the Ctrl+' followed by letter scheme, and this is what doesnt work under wxPython (or Thunderbird, come to that). Has this come up before? Stani says that combination works under Ubuntu using a unicode build, but it doesn't using the unicode build under windows xp.
Hank
Robin Dunn wrote:
···
Hank Knox wrote:
I need to be able to enter French accents into input fields, eg: é.
According to this site, http://www3.uakron.edu/modlang/french/keyboard.html, it is possible to enter é from a normal keyboard by pressing:
Ctrl+' (apostrophe) then e, and in Word, this works.
However as the following example shows, wx.TextCtrls do not accept characters in this way; they only see the e, not the é.
I notice that Thunderbird doesn't see the é, either, so maybe this is a particularly thorny problem. In any case, my client is refusing to install a real French Canadian keyboard, preferring to enter accents as above.
Any ideas?
You don't need a french keyboard to be able to set change the keyboard settings for the OS. You can load multiple keyboard settings and switch between them via a tool on the taskbar. Then you just need to learn where the keys you want are located on the keyboard.
Some simple testing indicates that this feature is built into the
native rich text control, but not the standard edit controls (it works
in wordpad but not notepad, for example). Using the wx.TE_RICH or
wx.TE_RICH2 flag on your text controls should make this work "for
free", and indeed Works For Me using the rich text controls in the
wxPython demo under 2.8.4, win2k3.
···
On 6/16/07, Hank Knox <hank@music.mcgill.ca> wrote:
I explained myself poorly; I suggested to my client that they change the
keyboard settings as you mentioned but they seem unwilling, they prefer
to use the Ctrl+' followed by letter scheme, and this is what doesnt
work under wxPython (or Thunderbird, come to that). Has this come up
before? Stani says that combination works under Ubuntu using a unicode
build, but it doesn't using the unicode build under windows xp.
Chris,
I finally had a chance to try the wx.TE_RICH2 style - works like a charm, many thanks for the pointer.
Hank
Chris Mellon wrote:
···
On 6/16/07, Hank Knox <hank@music.mcgill.ca> wrote:
I explained myself poorly; I suggested to my client that they change the
keyboard settings as you mentioned but they seem unwilling, they prefer
to use the Ctrl+' followed by letter scheme, and this is what doesnt
work under wxPython (or Thunderbird, come to that). Has this come up
before? Stani says that combination works under Ubuntu using a unicode
build, but it doesn't using the unicode build under windows xp.
Hank
Some simple testing indicates that this feature is built into the
native rich text control, but not the standard edit controls (it works
in wordpad but not notepad, for example). Using the wx.TE_RICH or
wx.TE_RICH2 flag on your text controls should make this work "for
free", and indeed Works For Me using the rich text controls in the
wxPython demo under 2.8.4, win2k3.
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org