Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members

unatwin.hpp

00001 /* ==================================================== ======== ======= *
00002  *
00003  *  unatwin.hpp  [Native Layer: platform dependent implementation]
00004  *  Ubit Project  [Elc][2003]
00005  *  Author: Eric Lecolinet
00006  *
00007  *  Part of the Ubit Toolkit: A Brick Construction Game Model for Creating GUIs
00008  *
00009  *  (C) 1999-2003 Eric Lecolinet @ ENST Paris
00010  *  WWW: http://www.enst.fr/~elc/ubit   Email: elc@enst.fr (subject: ubit)
00011  *
00012  * ***********************************************************************
00013  * COPYRIGHT NOTICE : 
00014  * THIS PROGRAM IS DISTRIBUTED WITHOUT ANY WARRANTY AND WITHOUT EVEN THE 
00015  * IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 
00016  * YOU CAN REDISTRIBUTE IT AND/OR MODIFY IT UNDER THE TERMS OF THE GNU 
00017  * GENERAL PUBLIC LICENSE AS PUBLISHED BY THE FREE SOFTWARE FOUNDATION; 
00018  * EITHER VERSION 2 OF THE LICENSE, OR (AT YOUR OPTION) ANY LATER VERSION.
00019  * SEE FILES 'COPYRIGHT' AND 'COPYING' FOR MORE DETAILS.
00020  * ***********************************************************************
00021  *
00022  * ==================================================== [Elc:03] ======= *
00023  * ==================================================== ======== ======= */
00024 
00025 #ifndef _unatwin_hpp_
00026 #define _unatwin_hpp_
00027 //pragma ident  "@(#)unatwin.hpp        ubit:03.06.04"
00028 #include <ubit/ubit_config.h>
00029 #include <ubit/unatgraph.hpp>
00030 
00031 
00032 class UNatWin {
00033 public:
00034   UNatWin();
00035   ~UNatWin();
00036 
00037   // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
00038 
00039   void move(class UNatDisp*, u_pos x, u_pos y);
00040   void resize(class UNatDisp*, u_dim w, u_dim h);
00041   void show(class UNatDisp*, bool);
00042   void toBack(class UNatDisp*);
00043   void toFront(class UNatDisp*);
00044 
00046   void where(class UNatDisp*, u_pos &screen_x, u_pos &screen_y);
00047   void setTitle(class UNatDisp*, const UStr&);
00048 
00050   UX_Window getXWindow() {return xwin;}
00051 
00052   bool isRealized() const {return (xwin != None);}
00053   static bool realizeMenu(class UNatDisp*,     UNatWin*, UWin*);
00054   static bool realizeDialog(class UNatDisp*,   UNatWin*, UWin*);
00055   static bool realizeFrame(class UNatDisp*,    UNatWin*, UWin*);
00056   static bool realizeMainFrame(class UNatDisp*,UNatWin*, UWin*);
00057   static bool realizeIncrust(class UNatDisp*,  UNatWin*, UWin*);
00058   //void reshapeCB(class UNatDisp*, class UView *winview);
00059   void reshapeCB(class UNatDisp*, class UWin*);
00060 
00061   static void initWinAttributes(class UNatDisp*, XSetWindowAttributes&, 
00062                                 unsigned long &wattr_mask);
00063   void initEventsAndProperties(class UNatDisp*, UWin*);
00064 
00065 private:
00066   friend class UGraph;
00067   friend class UWinGraph;
00068   friend class UNatGraph;
00069   UX_Window xwin;   // corresponding X Window
00070 };
00071 
00072 
00073 #endif
00074 /* ==================================================== [TheEnd] ======= */
00075 /* ==================================================== [Elc:03] ======= */

Generated on Sat Nov 20 11:58:04 2004 for Ubit[Eric.Lecolinet@enst.fr] by  doxygen 1.3.9.1