I''m faster than smarter :) The sample is here. -- +-[ Kontra, Gergely<kgergely@mcl.hu> PhD student Room IB113 ]---------+ | http://www.mcl.hu/~kgergely "Olyan langesz vagyok, hogy | | Mobil:(+36 20) 356 9656 ICQ: 175564914 poroltoval kellene jarnom" | +-- Magyar php mirror es magyar php dokumentacio: http://hu.php.net --+ -------------- next part -------------- #!/usr/bin/ruby require ''wxruby'' include Wx class MyImageFrame < Dialog def initialize parent, title, bmap super(parent, -1, title) @bitmap=bmap set_client_size_wh(@bitmap.get_width,@bitmap.get_height) evt_paint {|what| on_paint(what)} evt_left_down {on_click()} end def on_click close end def on_paint what dc = PaintDC.new(self) dc.draw_bitmap(@bitmap,0,0,true) end end class MyFrame < Wx::Frame def initialize(title) super(nil, -1, title) b=Button.new(self,-1,''e'') evt_button(-1) { MyImageFrame.new(self, ''yeah'',Bitmap.new(''verybigimagefile'')).show } end end class NothingApp < Wx::App def OnInit frame = MyFrame.new("Minimal wxRuby App") frame.show end end a = NothingApp.new a.main_loop()