[wxPython-users] Ampersands and static text
Robin Dunn
robin at alldunn.com
Wed Apr 25 14:15:13 PDT 2007
Bob Klahn wrote:
> At 12:30 PM 4/24/2007, Dj Gilcrease wrote:
>> On 4/24/07, Bob Klahn <bobklahn at comcast.net> wrote:
>>> What'a happening with the ampersand here? When ampersands occur in
>>> display
>>> text, I need them to display as ampersands.
>>>
>>> What do I need to do to get ampersands to display properly?
>>
>> use && to get it to display properly.
>>
>> & is use to signify a hotkey
>
> Yikes! I do know that. I shouldn't have used a button in the sample
> code I posted. My actual example uses a StaticText control rather than
> a button; I didn't expect to have the ampersand problem there. Why does
> the problem occur with static text?
Windows supports mnemonics on static texts, and they cause the next
control to be activated, which usually means that the item gets the focus.
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
More information about the wxpython-users
mailing list