> It's not a problem since it's a Win32 specific application.

OK, if you are dead-set on going this way, it is pretty easy - see the
"Operating System Issues" section of the fltk docs.

But basicaly, by the time you are inside your widget's draw() method,
fltk will have set up these values for you:

extern HINSTANCE fl_display;
extern HWND fl_window;
extern HDC fl_gc;
COLORREF fl_RGB();
HPEN fl_pen();
HBRUSH fl_brush();


Of these, the only one you need is the HDC, which will appear as fl_gc,
so you can simply do:


My_widget::draw()
{
        // some stuff

        DrawIcon(fl_gc, X, Y, hIcon);

        // other stuff
}



> In fact, it's because I must display an Icon getting from the 
> function :
> GetClassLong( hWnd , GCL_HICONSM );
> ( 
> 
> This function return an handle to a win2 icon...

Well, that's one way to do that... Still not clear what you are trying
to achieve, though...


SELEX Sensors and Airborne Systems Limited
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 
3EL
A company registered in England & Wales.  Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************

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

Reply via email to