In the samples directory of WxRuby-ruby 192 there is a file called dialogs.rb. Within this file there is a series of menu appends . A subset of is shown below. ---------------------------------- file_menu.append(DIALOGS_CHOOSE_COLOUR, "&Choose colour") file_menu.append_separator() file_menu.append(DIALOGS_CHOOSE_FONT, "Choose &font") ----------------------------------------------- What is the & trying to tell me? Why not just "Choose colour" or "Choose font" -- Ann Maybury ann.maybury@gmail.com _______________________________________________ wxruby-users mailing list wxruby-users@rubyforge.org http://rubyforge.org/mailman/listinfo/wxruby-users
On Sat, May 7, 2011 at 12:44 PM, Ann Maybury <ann.maybury at gmail.com> wrote:> In the samples directory of WxRuby-ruby 192 there is a file called > dialogs.rb. > > Within this file there is a series of menu appends . A subset of is shown > below. > > ---------------------------------- > file_menu.append(DIALOGS_CHOOSE_COLOUR, "&Choose colour") > file_menu.append_separator() > file_menu.append(DIALOGS_CHOOSE_FONT, "Choose &font") > > ----------------------------------------------- > What is the & trying to tell me? Why not just "Choose colour" or "Choose > font" > -- >That give you shortcut alt+key on the label something like : *C*hoose colour and Choose *f*ont if you try running it, press alt and you will see it -- Suka linux? Kunjungi blog saya http://penguinroad.blogspot.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/wxruby-users/attachments/20110507/ec4d9650/attachment.html>
Phillip & Kerrie Shelton
2011-May-07 05:46 UTC
[wxruby-users] Why the & in the middle of a string?
It has to do with keyboard short cuts. That & puts a line under the next char and when the dialog is open you can use that key to do that action instead of the mouse. So with the sample dialog in your email, if you type ''c'' you will open the colour chooser and ''f'' gets you the font dialog On 07/05/2011 3:14 PM, "Ann Maybury" <ann.maybury at gmail.com> wrote: In the samples directory of WxRuby-ruby 192 there is a file called dialogs.rb. Within this file there is a series of menu appends . A subset of is shown below. ---------------------------------- file_menu.append(DIALOGS_CHOOSE_COLOUR, "&Choose colour") file_menu.append_separator() file_menu.append(DIALOGS_CHOOSE_FONT, "Choose &font") ----------------------------------------------- What is the & trying to tell me? Why not just "Choose colour" or "Choose font" -- Ann Maybury ann.maybury at gmail.com _______________________________________________ wxruby-users mailing list wxruby-users at rubyforge.org http://rubyforge.org/mailman/listinfo/wxruby-users -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/wxruby-users/attachments/20110507/309d9bae/attachment.html>
Phillip & Kerrie Shelton <philkez <at> gmail.com> writes:> > > It has to do with keyboard short cuts. That & puts a line under the next charand when the dialog is open you can use that key to do that action instead of the mouse. So with the sample dialog in your email, if you type ''c'' you will open the colour chooser and ''f'' gets you the font dialog> > > On 07/05/2011 3:14 PM, "Ann Maybury" <ann.maybury <at> gmail.com> wrote:In thesamples directory of WxRuby-ruby 192 there is a file called dialogs.rb.Within this file there is a series of menu appends .?? A subset of is shown below.----------------------------------? ? file_menu.append(DIALOGS_CHOOSE_COLOUR, "&Choose colour")> ??? file_menu.append_separator()??? file_menu.append(DIALOGS_CHOOSE_FONT,"Choose &font")-----------------------------------------------What is the & trying to tell me?? Why not just "Choose colour" or "Choose font" THANKS FOR YOUR RESPONSE. When I run the samples/dialogs/dialogs.rb from which my question arose, there are no underlines following the &. Is there some configuration option that I may be missing? aNN
On Sun, May 8, 2011 at 7:32 AM, Ann Maybury <ann.maybury at gmail.com> wrote:> Phillip & Kerrie Shelton <philkez <at> gmail.com> writes: > > > > > > > It has to do with keyboard short cuts. That & puts a line under the next > char > and when the dialog is open you can use that key to do that action instead > of > the mouse. So with the sample dialog in your email, if you type ''c'' you > will > open the colour chooser and ''f'' gets you the font dialog > > > > > > On 07/05/2011 3:14 PM, "Ann Maybury" <ann.maybury <at> gmail.com> > wrote:In the > samples directory of WxRuby-ruby 192 there is a file called > dialogs.rb.Within > this file there is a series of menu appends . A subset of is shown > below.---------------------------------- > file_menu.append(DIALOGS_CHOOSE_COLOUR, "&Choose colour") > > file_menu.append_separator() file_menu.append(DIALOGS_CHOOSE_FONT, > "Choose &font")-----------------------------------------------What is the & > trying to tell me? Why not just "Choose colour" or "Choose font" > > THANKS FOR YOUR RESPONSE. > > When I run the samples/dialogs/dialogs.rb from which my question arose, > there > are no underlines following the &. Is there some configuration option > that I > may be missing? > >Press and hold Alt key you should see it -- Suka linux? Kunjungi blog saya http://penguinroad.blogspot.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/wxruby-users/attachments/20110509/9f9c61cd/attachment.html>