Displaying 5 results from an estimated 5 matches for "get_y".
Did you mean:
get_
2006 Apr 07
3
Pointer position on keypress event?
Hi.
Is there any straightforward way to tell pointer position (x, y)
upon keypress? In original wxWidgets, wxKeyEvent supports GetX()
and GetY() methods, but wxRuby''s KeyEvent object does not have
one. I also checked with event.methods and event.instance_variables.
Do I need to keep track of pointer position by evt_motion?
--
Taisuke Yamada <tyamadajp@spam.rakugaki.org>,
2007 Oct 02
0
[ wxruby-Patches-14375 ] bigdemo/wxScrolledWindow - paint bug with scrolled window
...et_XY(event)
@curLine = []
capture_mouse()
@drawing = true
end
end
To:
def on_left_button_event_down(event)
if event.left_is_down() and !@drawing
set_focus()
set_XY(event)
@event_x_old = event.get_x # added this to save the current absolute...
@event_y_old = event.get_y # ... mouse position
@curLine = []
capture_mouse()
@drawing = true
end
end
----
And in on_left_button_event_motion
From:
paint do | dc |
dc.set_pen(Wx::Pen.new("MEDIUM FOREST GREEN", 4, Wx::SOLID))
coords = [@x, @y] + convert_event_coords(event)
@curLine.push(coord...
2005 Jan 22
9
Dragging images across the canvas
...ation
#
wb = Wx::WHITE_BRUSH
dc.set_brush(wb)
dc.set_pen(Wx::WHITE_PEN)
dc.draw_rectangle(ox,oy,ox+w,oy+h)
# Draw at the new location
#
dc.draw_bitmap(@bitmap,nx,ny,false)
dc.free
end
def on_motion(event)
x = event.get_x
y = event.get_y
move_region(x,y) if (@left_dn and (@reg.contains(x,y) == 0))
end
def on_paint
paint{|dc|
dc.clear
dc.draw_bitmap(@bitmap, 0, 0, false)
}
w,h = @bitmap.get_width, @bitmap.get_height
@reg = Wx::Region.new(0,0,w,h)
end
end
class ImagesApp < Wx::App...
2007 Jan 03
0
[823] trunk/wxruby2/doc/textile: Remove docs for some deprecated classes
...rol#get_label":#TabControl_getlabel
-* "TabControl#get_row_position":#TabControl_getrowposition
-* "TabControl#get_selected":#TabControl_getselected
-* "TabControl#get_width":#TabControl_getwidth
-* "TabControl#get_x":#TabControl_getx
-* "TabControl#get_y":#TabControl_gety
-* "TabControl#hit_test":#TabControl_hittest
-* "TabControl#on_draw":#TabControl_ondraw
-* "TabControl#set_col_position":#TabControl_setcolposition
-* "TabControl#set_font":#TabControl_setfont
-* "TabControl#set_id":#TabContro...
2007 Jul 05
8
when can publish the next version?
when can publish the next version?
i am waiting...
_______________________________________________
wxruby-users mailing list
wxruby-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/wxruby-users