I don't want any shortcut keys for my gadgets, so I put GA_Underscore,0, in all the buttons gadgets. I do so because the text changes in the button gadgets and may have an _ in the text occasionally.
When I do GA_Underscore,0, for CheckBox objects I get a bunch of garbage text appended to the end of the text. See attached image.
It works fine for everything else.
GA_Underscore in CheckBox objects
- Daedalus
- Posts: 42
- Joined: Sat Jun 18, 2011 12:30 am
- Location: From Ireland, living in Glasgow
- Contact:
Re: GA_Underscore in CheckBox objects
Hmmm, sounds like using null might do funny things since the labels are probably all null-terminated strings, so all contain a null character that some code somewhere mistakenly decides needs to be underlined. That's what your screenshot looks like anyway - the null at the end of your label is swallowed and the garbage is whatever is in memory after the end of your string.
As a workaround, can you set it to a character that isn't used in any of your strings? Like "%", or maybe even a non-printable character.
As a workaround, can you set it to a character that isn't used in any of your strings? Like "%", or maybe even a non-printable character.
- broadblues
- AmigaOS Core Developer
- Posts: 600
- Joined: Sat Jun 18, 2011 2:40 am
- Location: Portsmouth, UK
- Contact:
Re: GA_Underscore in CheckBox objects
try using ~0 not 0
Re: GA_Underscore in CheckBox objects
~0 works. Maybe a note should be made of that in the autodocs......?
Thanks
Thanks
Workbench Explorer - A better way to browse drawers
- salass00
- AmigaOS Core Developer
- Posts: 530
- Joined: Sat Jun 18, 2011 3:12 pm
- Location: Finland
- Contact:
Re: GA_Underscore in CheckBox objects
The reason is as others have already stated that it tries to underscore the NUL-terminator character.mritter0 wrote: When I do GA_Underscore,0, for CheckBox objects I get a bunch of garbage text appended to the end of the text. See attached image.
This bug should be fixed in checkbox.gadget 53.10.