search for: posctrl

Displaying 1 result from an estimated 1 matches for "posctrl".

Did you mean: pinctrl
2008 Mar 31
2
Mouse motion example - help
...x'' class MyFrame < Wx::Frame def initialize super(nil, -1, "My Frame", :size => [300,300]) @my_panel = Wx::Panel.new(self, -1) evt_motion(){ |event| on_move(event)} Wx::StaticText.new(@my_panel, -1, :label => "Pos:", :pos => [10, 12]) @posCtrl = Wx::TextCtrl.new(@my_panel, -1, "",:pos => [40, 10]) show end def on_move(event) @pos = event.get_position @posCtrl.change_value("#{@pos}") end end Wx::App.run{MyFrame.new}