search for: evt_menu

Displaying 20 results from an estimated 40 matches for "evt_menu".

2006 Nov 13
7
[736] trunk/wxruby2/samples/dialogs/dialogs.rb: Fixed crashing bug in on_paint and made the code style more Ruby like.
.../ins><span class="cx"> </span><span class="cx"> @max = 10 </span><span class="cx"> </span><span class="cx"> create_status_bar() </span><span class="cx"> </span><del>- evt_menu(DIALOGS_CHOOSE_COLOUR) {|event| onChooseColour(event) } - evt_menu(DIALOGS_CHOOSE_FONT) {|event| onChooseFont(event) } - evt_menu(DIALOGS_LOG_DIALOG) {|event| onLogDialog(event) } - evt_menu(DIALOGS_MESSAGE_BOX) {|event| onMessageBox(event) } - evt_menu(DIALOGS_TEXT_ENTRY) {|event| onTe...
2007 Mar 22
0
[916] branches/wxruby2/wxwidgets_282: More Wx::AUI classes, event hooks and sample
...+ mb.append(options_menu, "Options") + mb.append(notebook_menu, "Notebook") + mb.append(help_menu, "Help") + + set_menu_bar(mb) + end + + def setup_events + evt_erase_background { | e | on_erase_background(e) } + evt_size{ | e | on_size(e) } + + evt_menu(ID_CreateTree) { | e | on_create_tree } + evt_menu(ID_CreateGrid) { | e | on_create_grid } + evt_menu(ID_CreateText) { | e | on_create_text } + evt_menu(ID_CreateHTML) { | e | on_create_html } + evt_menu(ID_CreateSizeReport) { | e | on_create_size_report } + evt_menu(ID_CreateNot...
2007 Mar 23
0
[918] branches/wxruby2/wxwidgets_282/samples/aui/aui.rb: Fix a couple of little bugs and typos
...add(1, 1, 1, Wx::EXPAND) </span><span class="cx"> sz.set_item_min_size(1, 180, 20) </span><span class="cx"> return bmp_butt, sz </span><span class="lines">@@ -532,7 +533,7 @@ </span><span class="cx"> evt_menu(ID_NoGradient) { | e | on_gradient(e) } </span><span class="cx"> evt_menu(ID_VerticalGradient) { | e | on_gradient(e) } </span><span class="cx"> evt_menu(ID_HorizontalGradient) { | e | on_gradient(e) } </span><del>- evt_menu(ID_S...
2007 Nov 18
2
Issues adding sub-menu items
...menu_bar.append(menu_help, "&Help") # Assign the menubar to this frame self.menu_bar = menu_bar # Create a status bar create_status_bar(2) self.status_text = "Welcome to HL7Query!" # Set it up to handle menu events using the relevant methods evt_menu Wx::ID_EXIT, :on_quit evt_menu Wx::ID_ABOUT, :on_about end def on_quit close() end .... .... .... Wx::App.run do self.app_name = ''HL7Query'' frame = HL7Query.new(":::HL7Query:::") frame.show end -- Posted via http://www.ruby-forum.com/.
2007 Mar 20
0
[903] branches/wxruby2/wxwidgets_282/samples: Added #!/usr/bin/env ruby to the grid sample.
...d, title, pos, size, style) - sizer = Wx::BoxSizer.new(Wx::VERTICAL) - create_status_bar() - set_status_text(Wx::VERSION_STRING) - - # panel = Wx::Panel.new(self) - sel_menu = Wx::Menu.new - sel_menu.append(1002, ''Select all'', ''Select all'') - evt_menu(1002) { @grid.select_all } - sel_menu.append(1003, ''Select row 2'', ''Select row 2'') - evt_menu(1003) { @grid.select_row(1) } - sel_menu.append(1004, ''Select column 4'', ''Select col 4'') - evt_menu(1004) { @grid.select_...
2006 Nov 13
0
[731] trunk/wxruby2/samples/etc/sash.rb: Changed menu events so they call the correct method.
...t;span class="lines">@@ -30,8 +30,8 @@ </span><span class="cx"> create_status_bar(2) </span><span class="cx"> set_status_text("wxRuby Sash sample") </span><span class="cx"> </span><del>- evt_menu(Wx::ID_EXIT) { onQuit } - evt_menu(Wx::ID_ABOUT) { onAbout } </del><ins>+ evt_menu(Wx::ID_EXIT) { on_quit } + evt_menu(Wx::ID_ABOUT) { on_about } </ins><span class="cx"> </span><span class="cx"> # Start creating the sashes - thes...
2008 Jul 28
12
Segfault with GridCellChoiceEditor
I have a problem. In my application I have a few Grid objects in a Notebook. The Grid objects are populated via GridTableBase. Certain Grid cells need to have a choice interface (I''m artificially enforcing foreign key constraints). All this works to the point where you try to edit the value for that cell. The choice box renders (i.e. the drop down arrow appears) then the application
2004 Jan 08
3
pictorG
...e'',''Portre'']), ]) build_from_tree nil,@cats #set_drop_target(MyFileDropTarget.new()) #evt_tree_begin_drag(self.get_id) { |e| # puts e.get_item #} evt_tree_item_right_click(self.get_id) {|e| ShowMenu(e.get_item,e.get_point) } evt_menu(ID_EDITLAB) { edit_label get_selection } evt_tree_key_down(self.get_id) {|e| case e.get_key_code when K_F2 edit_label get_selection end } end def build_from_tree parent,tree m = parent.nil? ? Proc.new {|p,l| @root=add_root l} : Proc.new {|p,l| ap...
2006 Nov 13
0
[732] trunk/wxruby2/samples: Fixed a few crashes related to the about box menu.
...class="lines">@@ -32,8 +32,8 @@ </span><span class="cx"> s = Wx::StaticText.new(self, -1, ''The Wizard has completed'') </span><span class="cx"> </span><span class="cx"> </span><del>- evt_menu(Wx::ID_EXIT) { onQuit } - evt_menu(Wx::ID_ABOUT) { onAbout } </del><ins>+ evt_menu(Wx::ID_EXIT) { on_quit } + evt_menu(Wx::ID_ABOUT) { on_about } </ins><span class="cx"> w = Wx::Wizard.new(self, -1, ''The WxRuby Wizard'') </span>&...
2008 May 11
2
instabilities in wxRuby 1.9.6
...to show/hide child frames? Thanks for any help with this. Peter. class ChildFrame < Wx::Frame def initialize parent super(parent, -1, "Child frame") viewMenu = Wx::Menu.new viewMenu.append(Wx::ID_CLOSE, "Close\tCtrl-W", "Close this window") evt_menu(Wx::ID_CLOSE) { show false } menuBar = Wx::MenuBar.new menuBar.append(viewMenu, "&View") set_menu_bar menuBar end end class TestFrame < Wx::Frame def initialize super(nil, -1, "Test Frame") menu = Wx::Menu.new menuItem = Wx::MenuItem.new(men...
2007 Feb 14
0
[875] trunk/wxruby2/samples: Add expanded grid sample
...d, title, pos, size, style) + sizer = Wx::BoxSizer.new(Wx::VERTICAL) + create_status_bar() + set_status_text(Wx::VERSION_STRING) + + # panel = Wx::Panel.new(self) + sel_menu = Wx::Menu.new + sel_menu.append(1002, ''Select all'', ''Select all'') + evt_menu(1002) { @grid.select_all } + sel_menu.append(1003, ''Select row 2'', ''Select row 2'') + evt_menu(1003) { @grid.select_row(1) } + sel_menu.append(1004, ''Select column 4'', ''Select col 4'') + evt_menu(1004) { @grid.select_...
2006 Jul 24
6
MiniFrame.i
Hi Another little patch, adding MiniFrame (a frame with small title bar and buttons which doesn''t appear in the desktop taskbar). Also a sample - not very interesting, happy to roll this into something else if that''s better. cheers alex _______________________________________________ wxruby-users mailing list wxruby-users@rubyforge.org
2006 Apr 27
5
Major Breakthrough?
Attached are patches to make the textctrl.rb sample work fully. Note the new %directorargout typemap I added to fix wxWindows calling into SWIG. I don''t know if this can fix all such problems or not. Let me know what you think. I also rubified the sample a little bit more. Also, note that I fix the << operator so the function can be called. I hope I did this right. Roy
2008 May 20
0
[ wxruby-Bugs-20255 ] Instabilities on Linux - 1.9.7
.../2008-May/003916.html ============== require ''wx'' class ChildFrame < Wx::Frame def initialize parent super(parent, -1, "Child frame") viewMenu = Wx::Menu.new viewMenu.append(Wx::ID_CLOSE, "Close\tCtrl-W", "Close this window") evt_menu(Wx::ID_CLOSE) { show false } menuBar = Wx::MenuBar.new menuBar.append(viewMenu, "&View") set_menu_bar menuBar end end class TestFrame < Wx::Frame def initialize super(nil, -1, "Test Frame") menu = Wx::Menu.new menuItem = Wx::MenuItem.new(men...
2007 Dec 18
1
Dynamic Task Bar Menu Items
Am looking for a way to dynamically add menu items to a task bar icon menu. And then once selected - I would like to get the title of the menu item. The general idea is to read a text file: Project1 Project2 Project3 ===== Add those to the task bar menu, and when i select (for example) Project2, I want to pass the string "Project2" to the code. Also - Am wondering about how to get
2006 Nov 04
0
[720] trunk/wxruby2/doc/textile/menu.txtl: Update, rubyify and tidy
...lt;/span><span class="cx"> </span><del>-If the menu is part of a menubar, then "MenuBar":menubar.html event processing is used. </del><ins>+If the menu is part of a menubar, then "MenuBar":menubar.html event +processing is used, using @evt_menu@. </ins><span class="cx"> </span><del>-With a popup menu, there is a variety of ways to handle a menu selection event -(EVT_COMMAND_MENU_SELECTED). </del><ins>+To handle a popup menu, handle a menu selection event +(EVT_COMMAND_MENU_SELECTED). Provide...
2004 May 22
4
couple of questions
Hi folks A couple of questions: 1) I seem to get funny artifacts in the display of TreeCtrl, ComboBox and ListBox when the MDI child frame containing it is first painted (see attached - it should be two-root treeview, unopened). I''m not sure if it''s related to being in a MDI, but the controls sample looks OK. The artifacts are cleared up when it''s repainted or
2007 Apr 13
2
who can give me an EvtHandler#connect example?
I read the api document online: http://wxruby.rubyforge.org/doc/evthandler.html but still don''t know how to use it. EvtHandler#connect connect(Integer id, Integer lastId, EventType eventType, ObjectEventFunction function, Object userData = nil, EvtHandler eventSink = nil) the online doc''s example is write in C++: frame->Connect( ID_EXIT,
2005 Aug 15
16
swig_up
Tracing down some things to add in validators and I''ve run across something that kinda bothers me... In order to implement validators you have to override the clone method. The directors seems to be set up to specifically handle this situation. However, whenever C++ calls back to the object''s methods the swig_get_up function is returning false. It seems like swig_up
2006 Oct 21
0
[698] trunk/wxruby2/samples/bigdemo/MDIDemo.rbw: Removed broken background stuff to stop crash on OS X (tho still crashes
...set_menu_bar(menubar) </span><span class="cx"> </span><del>- create_status_bar() </del><ins>+ create_status_bar </ins><span class="cx"> </span><span class="cx"> evt_menu(5000) {|event| on_new_window(event)} </span><span class="cx"> evt_menu(5001) {|event| on_exit(event)} </span><del>- - if SHOW_BACKGROUND - @bg_bmp = - evt_erase_background {|event| on_erase_background(event)} - e...