>From: "Haris Bogdanović˘ <fbogdanovi / xnet.hr>
>Newsgroups: comp.lang.ruby
>Sent: Friday, September 25, 2009 7:13 PM
>Subject: wxruby - painting in device context
>
> Hi.
> I'm trying to paint in DC context:
>
> # ---------------------------------------------------
> frame = Frame.new(nil, -1, "")
> frame.paint { |dc|
>    dc.draw_line(50, 50, 100, 100)                                #  for
> this I don't see the line
>
>    dc.draw_bitmap(Bitmap.new('c:\img.bmp'),0,0)        # and for this 
> program crashes
> }
> # -----------------------------------------------------------
> Does anyone know why is this happening ?
>
> Thanks.
>

Hello Haris:

I haven't been able to get a line drawn either but I know it's possible. 
The WxRuby samples directory contains a files called bitmap.rb and 
graphics_drawing.rb that draws bitmaps, text and rectangles.

Michael