I'm trying to set the main window's icon using FLTK2, and the trick used
for fltk1 seems not to work.

I'm doing:


  fltk::open_display();

#if 0
  this->icon((char *)XCreateBitmapFromData(fltk::xdisplay,
                                   DefaultRootWindow(fltk::xdisplay),
                                   (char *)sudoku_bits, sudoku_width,
                                   sudoku_height));
#endif

#if 0
  Pixmap p, mask;
  if ( XpmCreatePixmapFromData(fltk::xdisplay,
                               DefaultRootWindow(fltk::xdisplay),
                               english_flag_xpm, &p, &mask, NULL) == XpmSuccess 
)
    {
      this->icon((char *)p);
    }
#endif


The code works without any issues.  However, as soon as the window is
shown, the application segfaults.

Is there any trick to setting a window's icon on fltk2.0?  The docs are
severely lacking, as the icon() function is undocumented.


-- 
Gonzalo Garramuño
[EMAIL PROTECTED]

AMD4400 - ASUS48N-E
GeForce7300GT
Kubuntu Edgy

_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to