RE: [gtkmm] Draw Image documentation
- From: Murray Cumming Comneon com
- To: cplusplushelp gmx net, gtkmm-list gnome org
- Subject: RE: [gtkmm] Draw Image documentation
- Date: Tue, 29 Jul 2003 14:57:58 +0200
Is this some example code in the tarball, or some code in the documentation,
or something else? Can you provide a patch? Please at least use bugzilla if
this is clearly a bug.
Murray Cumming
murrayc usa net
www.murrayc.com
> -----Original Message-----
> From: Ruediger Sonderfeld [mailto:cplusplushelp gmx net]
> Sent: Dienstag, 29. Juli 2003 14:41
> To: gtkmm-list gnome org
> Subject: [gtkmm] Draw Image documentation
>
>
> hi,
> the code of the draw image example ist wrong!
>
> class rgb_draw_area: public Gtk::DrawingArea {
> int width_m, height_m;
> guchar *rgbbuff_m;
> public:
> rgb_draw_area(guchar *buff,int width=0, int height=0);
> bool on_expose_event(GdkEventExpose*);
> };
>
> rgb_draw_area::rgb_draw_area(guchar *buffer,int width,int height)
> : width_m(width),height_m(height),rgbbuff_m(buffer)
> {
> set_size_request(width,height);
> }
>
> //this should return bool not int!
> bool rgb_draw_area::on_expose_event(GdkEventExpose*) {
> gdk_draw_rgb_image(get_window()->gobj(), //and fix here
>
> get_style()->get_fg_gc(Gtk::STATE_NORMAL)->gobj(), //and here
>
> 0,0,width_m,height_m,GDK_RGB_DITHER_MAX,rgbbuff_m,width_m*3);
> return true;
> }
>
> you should replace it please.
>
> I think the drawing area part of the documentation isn't very
> good at the moment
> and I had a lot of problems to understand this section!
>
> Maybe you should write a section about drawing and loading Images etc.
> (including Gtk::DrawingArea, Gtk::Image, Gdk::Pixbuf etc.)
>
> (I don't have the experience to do that)
>
> Ruediger Sonderfeld <cplusplushelp gmx net>
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtkmm-list
>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]