Sophie

Sophie

distrib > Mandriva > 10.0-com > i586 > by-pkgid > af7a4b7f1ee5a4a084c41b9005da5527 > files > 496

libfox1.1_46-devel-1.1.46-1mdk.i586.rpm

<html>
<head>
<link rel="stylesheet" href="page.css" type="text/css">
<title>fox-toolkit.org - Documentation</title>
</head>
<body bgcolor=#ffffff link=#990033 vlink=#990033 alink=#990033 text=#000000>
<font face='verdana,sans-serif' size=2 >

<!---- TOPIC TITLE WITH LOGO--->
<table border=0 cellpadding= cellspacing=2 width=100% ><tr><td><a href='http://www.fox-toolkit.org/doc.html'><img src='../art/foxlogo_small.jpg' border=0></a></td><td width=100% valign=bottom><font face='verdana,sans-serif' size=2 ><b>
<a class="qindex" href="index.html">Main Page</a> &nbsp; <a class="qindex" href="hierarchy.html">Class Hierarchy</a> &nbsp; <a class="qindex" href="classes.html">Alphabetical List</a> &nbsp; <a class="qindex" href="annotated.html">Compound List</a> &nbsp; <a class="qindex" href="files.html">File List</a> &nbsp; <a class="qindex" href="functions.html">Compound Members</a>
<br><img src='../art/line.gif' width=100% height=1></b></font></td></tr></table>
<p>
<!--- TOPIC TITLE WITH LOGO --->
<!-- Generated by Doxygen 1.3.3 -->
<h1>FXWindow.h</h1><div class="fragment"><pre>00001 <span class="comment">/********************************************************************************</span>
00002 <span class="comment">*                                                                               *</span>
00003 <span class="comment">*                            W i n d o w   O b j e c t                          *</span>
00004 <span class="comment">*                                                                               *</span>
00005 <span class="comment">*********************************************************************************</span>
00006 <span class="comment">* Copyright (C) 1997,2004 by Jeroen van der Zijp.   All Rights Reserved.        *</span>
00007 <span class="comment">*********************************************************************************</span>
00008 <span class="comment">* This library is free software; you can redistribute it and/or                 *</span>
00009 <span class="comment">* modify it under the terms of the GNU Lesser General Public                    *</span>
00010 <span class="comment">* License as published by the Free Software Foundation; either                  *</span>
00011 <span class="comment">* version 2.1 of the License, or (at your option) any later version.            *</span>
00012 <span class="comment">*                                                                               *</span>
00013 <span class="comment">* This library is distributed in the hope that it will be useful,               *</span>
00014 <span class="comment">* but WITHOUT ANY WARRANTY; without even the implied warranty of                *</span>
00015 <span class="comment">* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU             *</span>
00016 <span class="comment">* Lesser General Public License for more details.                               *</span>
00017 <span class="comment">*                                                                               *</span>
00018 <span class="comment">* You should have received a copy of the GNU Lesser General Public              *</span>
00019 <span class="comment">* License along with this library; if not, write to the Free Software           *</span>
00020 <span class="comment">* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA.    *</span>
00021 <span class="comment">*********************************************************************************</span>
00022 <span class="comment">* $Id: FXWindow.h,v 1.105 2004/02/08 17:17:34 fox Exp $                         *</span>
00023 <span class="comment">********************************************************************************/</span>
00024 <span class="preprocessor">#ifndef FXWINDOW_H</span>
00025 <span class="preprocessor"></span><span class="preprocessor">#define FXWINDOW_H</span>
00026 <span class="preprocessor"></span>
00027 <span class="preprocessor">#ifndef FXDRAWABLE_H</span>
00028 <span class="preprocessor"></span><span class="preprocessor">#include "FXDrawable.h"</span>
00029 <span class="preprocessor">#endif</span>
00030 <span class="preprocessor"></span>
00031 
00032 <span class="keyword">namespace </span>FX {
00033 
00034 <span class="comment"></span>
00035 <span class="comment">/// Layout hints for child widgets</span>
00036 <span class="comment"></span><span class="keyword">enum</span> {
00037   <a class="code" href="group__FXWindow__0.html#a0a2131">LAYOUT_NORMAL</a>      = 0,                                   <span class="comment">/// Default layout mode</span>
00038 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2132">LAYOUT_SIDE_TOP</a>    = 0,                                   <span class="comment">/// Pack on top side (default)</span>
00039 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2133">LAYOUT_SIDE_BOTTOM</a> = 0x00000001,                          <span class="comment">/// Pack on bottom side</span>
00040 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2134">LAYOUT_SIDE_LEFT</a>   = 0x00000002,                          <span class="comment">/// Pack on left side</span>
00041 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2135">LAYOUT_SIDE_RIGHT</a>  = <a class="code" href="group__FXWindow__0.html#a0a2134">LAYOUT_SIDE_LEFT</a>|<a class="code" href="group__FXWindow__0.html#a0a2133">LAYOUT_SIDE_BOTTOM</a>, <span class="comment">/// Pack on right side</span>
00042 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2136">LAYOUT_FILL_COLUMN</a> = 0x00000001,                          <span class="comment">/// Matrix column is stretchable</span>
00043 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2137">LAYOUT_FILL_ROW</a>    = 0x00000002,                          <span class="comment">/// Matrix row is stretchable</span>
00044 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2138">LAYOUT_LEFT</a>        = 0,                                   <span class="comment">/// Stick on left (default)</span>
00045 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2139">LAYOUT_RIGHT</a>       = 0x00000004,                          <span class="comment">/// Stick on right</span>
00046 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2140">LAYOUT_CENTER_X</a>    = 0x00000008,                          <span class="comment">/// Center horizontally</span>
00047 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2141">LAYOUT_FIX_X</a>       = <a class="code" href="group__FXWindow__0.html#a0a2139">LAYOUT_RIGHT</a>|<a class="code" href="group__FXWindow__0.html#a0a2140">LAYOUT_CENTER_X</a>,        <span class="comment">/// X fixed</span>
00048 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2142">LAYOUT_TOP</a>         = 0,                                   <span class="comment">/// Stick on top (default)</span>
00049 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2143">LAYOUT_BOTTOM</a>      = 0x00000010,                          <span class="comment">/// Stick on bottom</span>
00050 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2144">LAYOUT_CENTER_Y</a>    = 0x00000020,                          <span class="comment">/// Center vertically</span>
00051 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2145">LAYOUT_FIX_Y</a>       = <a class="code" href="group__FXWindow__0.html#a0a2143">LAYOUT_BOTTOM</a>|<a class="code" href="group__FXWindow__0.html#a0a2144">LAYOUT_CENTER_Y</a>,       <span class="comment">/// Y fixed</span>
00052 <span class="comment"></span>  LAYOUT_RESERVED_1  = 0x00000040,
00053   LAYOUT_RESERVED_2  = 0x00000080,
00054   <a class="code" href="group__FXWindow__0.html#a0a2148">LAYOUT_FIX_WIDTH</a>   = 0x00000100,                          <span class="comment">/// Width fixed</span>
00055 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2149">LAYOUT_FIX_HEIGHT</a>  = 0x00000200,                          <span class="comment">/// height fixed</span>
00056 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2150">LAYOUT_MIN_WIDTH</a>   = 0,                                   <span class="comment">/// Minimum width is the default</span>
00057 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2151">LAYOUT_MIN_HEIGHT</a>  = 0,                                   <span class="comment">/// Minimum height is the default</span>
00058 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2152">LAYOUT_FILL_X</a>      = 0x00000400,                          <span class="comment">/// Stretch or shrink horizontally</span>
00059 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2153">LAYOUT_FILL_Y</a>      = 0x00000800,                          <span class="comment">/// Stretch or shrink vertically</span>
00060 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2154">LAYOUT_FILL</a>        = <a class="code" href="group__FXWindow__0.html#a0a2152">LAYOUT_FILL_X</a>|<a class="code" href="group__FXWindow__0.html#a0a2153">LAYOUT_FILL_Y</a>,         <span class="comment">/// Stretch or shrink in both directions</span>
00061 <span class="comment"></span>  <a class="code" href="group__FXWindow__0.html#a0a2155">LAYOUT_EXPLICIT</a>    = <a class="code" href="group__FXWindow__0.html#a0a2141">LAYOUT_FIX_X</a>|<a class="code" href="group__FXWindow__0.html#a0a2145">LAYOUT_FIX_Y</a>|<a class="code" href="group__FXWindow__0.html#a0a2148">LAYOUT_FIX_WIDTH</a>|<a class="code" href="group__FXWindow__0.html#a0a2149">LAYOUT_FIX_HEIGHT</a>   <span class="comment">/// Explicit placement</span>
00062 <span class="comment"></span>  };
00063 
00064 <span class="comment"></span>
00065 <span class="comment">/// Frame border appearance styles (for subclasses)</span>
00066 <span class="comment"></span><span class="keyword">enum</span> {
00067   <a class="code" href="group__FXWindow__1.html#a0a2156">FRAME_NONE</a>   = 0,                                     <span class="comment">/// Default is no frame</span>
00068 <span class="comment"></span>  <a class="code" href="group__FXWindow__1.html#a0a2157">FRAME_SUNKEN</a> = 0x00001000,                            <span class="comment">/// Sunken border</span>
00069 <span class="comment"></span>  <a class="code" href="group__FXWindow__1.html#a0a2158">FRAME_RAISED</a> = 0x00002000,                            <span class="comment">/// Raised border</span>
00070 <span class="comment"></span>  <a class="code" href="group__FXWindow__1.html#a0a2159">FRAME_THICK</a>  = 0x00004000,                            <span class="comment">/// Thick border</span>
00071 <span class="comment"></span>  <a class="code" href="group__FXWindow__1.html#a0a2160">FRAME_GROOVE</a> = <a class="code" href="group__FXWindow__1.html#a0a2159">FRAME_THICK</a>,                           <span class="comment">/// A groove or etched-in border</span>
00072 <span class="comment"></span>  <a class="code" href="group__FXWindow__1.html#a0a2161">FRAME_RIDGE</a>  = <a class="code" href="group__FXWindow__1.html#a0a2159">FRAME_THICK</a>|<a class="code" href="group__FXWindow__1.html#a0a2158">FRAME_RAISED</a>|<a class="code" href="group__FXWindow__1.html#a0a2157">FRAME_SUNKEN</a>, <span class="comment">/// A ridge or embossed border</span>
00073 <span class="comment"></span>  <a class="code" href="group__FXWindow__1.html#a0a2162">FRAME_LINE</a>   = <a class="code" href="group__FXWindow__1.html#a0a2158">FRAME_RAISED</a>|<a class="code" href="group__FXWindow__1.html#a0a2157">FRAME_SUNKEN</a>,             <span class="comment">/// Simple line border</span>
00074 <span class="comment"></span>  <a class="code" href="group__FXWindow__1.html#a0a2163">FRAME_NORMAL</a> = <a class="code" href="group__FXWindow__1.html#a0a2157">FRAME_SUNKEN</a>|<a class="code" href="group__FXWindow__1.html#a0a2159">FRAME_THICK</a>               <span class="comment">/// Regular raised/thick border</span>
00075 <span class="comment"></span>  };
00076 
00077 <span class="comment"></span>
00078 <span class="comment">/// Packing style (for packers)</span>
00079 <span class="comment"></span><span class="keyword">enum</span> {
00080   <a class="code" href="group__FXWindow__2.html#a0a2164">PACK_NORMAL</a>         = 0,              <span class="comment">/// Default is each its own size</span>
00081 <span class="comment"></span>  <a class="code" href="group__FXWindow__2.html#a0a2165">PACK_UNIFORM_HEIGHT</a> = 0x00008000,     <span class="comment">/// Uniform height</span>
00082 <span class="comment"></span>  <a class="code" href="group__FXWindow__2.html#a0a2166">PACK_UNIFORM_WIDTH</a>  = 0x00010000      <span class="comment">/// Uniform width</span>
00083 <span class="comment"></span>  };
00084 
00085 
00086 <span class="keyword">class </span>FXCursor;
00087 <span class="keyword">class </span>FXAccelTable;
00088 <span class="keyword">class </span>FXComposite;
00089 
00090 <span class="comment"></span>
00091 <span class="comment">/// Base class for all windows</span>
00092 <span class="comment"></span><span class="keyword">class </span>FXAPI FXWindow : <span class="keyword">public</span> FXDrawable {
00093   FXDECLARE(FXWindow)
00094 <span class="keyword">private</span>:
00095   FXWindow     *parent;                 <span class="comment">// Parent Window</span>
00096   FXWindow     *owner;                  <span class="comment">// Owner Window</span>
00097   FXWindow     *first;                  <span class="comment">// First Child</span>
00098   FXWindow     *last;                   <span class="comment">// Last Child</span>
00099   FXWindow     *next;                   <span class="comment">// Next Sibling</span>
00100   FXWindow     *prev;                   <span class="comment">// Previous Sibling</span>
00101   FXWindow     *focus;                  <span class="comment">// Focus Child</span>
00102   FXuint        wk;                     <span class="comment">// Window Key</span>
00103 <span class="keyword">protected</span>:
00104   FXCursor     *defaultCursor;          <span class="comment">// Normal Cursor</span>
00105   FXCursor     *dragCursor;             <span class="comment">// Cursor during drag</span>
00106   FXAccelTable *accelTable;             <span class="comment">// Accelerator table</span>
00107   FXObject     *target;                 <span class="comment">// Target object</span>
00108   FXSelector    message;                <span class="comment">// Message ID</span>
00109   FXint         xpos;                   <span class="comment">// Window X Position</span>
<a name="l00110"></a><a class="code" href="classFX_1_1FXWindow.html">00110</a>   FXint         ypos;                   <span class="comment">// Window Y Position</span>
00111   FXColor       backColor;              <span class="comment">// Window background color</span>
00112   <a class="code" href="classFX_1_1FXString.html">FXString</a>      tag;                    <span class="comment">// Help tag</span>
00113   FXuint        flags;                  <span class="comment">// Window state flags</span>
00114   FXuint        options;                <span class="comment">// Window options</span>
00115 <span class="keyword">public</span>:
00116 
00117   <span class="comment">// Common DND types</span>
00118   <span class="keyword">static</span> FXDragType deleteType;         <span class="comment">// Delete request</span>
00119   <span class="keyword">static</span> FXDragType textType;           <span class="comment">// Ascii text request</span>
00120   <span class="keyword">static</span> FXDragType colorType;          <span class="comment">// Color</span>
00121   <span class="keyword">static</span> FXDragType urilistType;        <span class="comment">// URI List</span>
00122   <span class="keyword">static</span> <span class="keyword">const</span> FXDragType stringType;   <span class="comment">// Clipboard text type (pre-registered)</span>
00123   <span class="keyword">static</span> <span class="keyword">const</span> FXDragType imageType;    <span class="comment">// Clipboard image type (pre-registered)</span>
00124 
00125 <span class="keyword">protected</span>:
00126 <span class="preprocessor">#ifdef WIN32</span>
00127 <span class="preprocessor"></span>  <span class="keyword">virtual</span> FXID GetDC() <span class="keyword">const</span>;
00128   <span class="keyword">virtual</span> <span class="keywordtype">int</span> ReleaseDC(FXID) <span class="keyword">const</span>;
00129   <span class="keyword">virtual</span> <span class="keyword">const</span> <span class="keywordtype">char</span>* GetClass() <span class="keyword">const</span>;
00130 <span class="preprocessor">#else</span>
00131 <span class="preprocessor"></span>  <span class="keywordtype">void</span> addColormapWindows();
00132   <span class="keywordtype">void</span> remColormapWindows();
00133 <span class="preprocessor">#endif</span>
00134 <span class="preprocessor"></span>
00135 <span class="keyword">protected</span>:
00136   FXWindow();
00137   FXWindow(<a class="code" href="classFX_1_1FXApp.html">FXApp</a>* a,<a class="code" href="classFX_1_1FXVisual.html">FXVisual</a> *vis);
00138   FXWindow(<a class="code" href="classFX_1_1FXApp.html">FXApp</a>* a,FXWindow* own,FXuint opts,FXint x,FXint y,FXint w,FXint h);
00139   <span class="keyword">static</span> FXWindow* findDefault(FXWindow* window);
00140   <span class="keyword">static</span> FXWindow* findInitial(FXWindow* window);
00141   <span class="keyword">virtual</span> FXbool doesOverrideRedirect() <span class="keyword">const</span>;
00142 <span class="keyword">private</span>:
00143   FXWindow(<span class="keyword">const</span> FXWindow&amp;);
00144   FXWindow&amp; operator=(<span class="keyword">const</span> FXWindow&amp;);
00145 
00146 <span class="keyword">protected</span>:
00147 
00148   <span class="comment">// Window state flags</span>
00149   <span class="keyword">enum</span> {
00150     FLAG_SHOWN        = 0x00000001,     <span class="comment">// Is shown</span>
00151     FLAG_ENABLED      = 0x00000002,     <span class="comment">// Able to receive input</span>
00152     FLAG_UPDATE       = 0x00000004,     <span class="comment">// Is subject to GUI update</span>
00153     FLAG_DROPTARGET   = 0x00000008,     <span class="comment">// Drop target</span>
00154     FLAG_FOCUSED      = 0x00000010,     <span class="comment">// Has focus</span>
00155     FLAG_DIRTY        = 0x00000020,     <span class="comment">// Needs layout</span>
00156     FLAG_RECALC       = 0x00000040,     <span class="comment">// Needs recalculation</span>
00157     FLAG_TIP          = 0x00000080,     <span class="comment">// Show tip</span>
00158     FLAG_HELP         = 0x00000100,     <span class="comment">// Show help</span>
00159     FLAG_DEFAULT      = 0x00000200,     <span class="comment">// Default widget</span>
00160     FLAG_INITIAL      = 0x00000400,     <span class="comment">// Initial widget</span>
00161     FLAG_SHELL        = 0x00000800,     <span class="comment">// Shell window</span>
00162     FLAG_ACTIVE       = 0x00001000,     <span class="comment">// Window is active</span>
00163     FLAG_PRESSED      = 0x00002000,     <span class="comment">// Button has been pressed</span>
00164     FLAG_KEY          = 0x00004000,     <span class="comment">// Keyboard key pressed</span>
00165     FLAG_CARET        = 0x00008000,     <span class="comment">// Caret is on</span>
00166     FLAG_CHANGED      = 0x00010000,     <span class="comment">// Window data changed</span>
00167     FLAG_LASSO        = 0x00020000,     <span class="comment">// Lasso mode</span>
00168     FLAG_TRYDRAG      = 0x00040000,     <span class="comment">// Tentative drag mode</span>
00169     FLAG_DODRAG       = 0x00080000,     <span class="comment">// Doing drag mode</span>
00170     FLAG_SCROLLINSIDE = 0x00100000,     <span class="comment">// Scroll only when inside</span>
00171     FLAG_SCROLLING    = 0x00200000,     <span class="comment">// Right mouse scrolling</span>
00172     FLAG_OWNED        = 0x00400000      <span class="comment">// Window handle owned by widget</span>
00173     };
00174 
00175 <span class="keyword">public</span>:
00176 
00177   <span class="comment">// Message handlers</span>
00178   <span class="keywordtype">long</span> onPaint(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00179   <span class="keywordtype">long</span> onMap(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00180   <span class="keywordtype">long</span> onUnmap(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00181   <span class="keywordtype">long</span> onConfigure(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00182   <span class="keywordtype">long</span> onUpdate(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00183   <span class="keywordtype">long</span> onMotion(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00184   <span class="keywordtype">long</span> onMouseWheel(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00185   <span class="keywordtype">long</span> onEnter(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00186   <span class="keywordtype">long</span> onLeave(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00187   <span class="keywordtype">long</span> onLeftBtnPress(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00188   <span class="keywordtype">long</span> onLeftBtnRelease(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00189   <span class="keywordtype">long</span> onMiddleBtnPress(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00190   <span class="keywordtype">long</span> onMiddleBtnRelease(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00191   <span class="keywordtype">long</span> onRightBtnPress(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00192   <span class="keywordtype">long</span> onRightBtnRelease(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00193   <span class="keywordtype">long</span> onBeginDrag(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00194   <span class="keywordtype">long</span> onEndDrag(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00195   <span class="keywordtype">long</span> onDragged(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00196   <span class="keywordtype">long</span> onKeyPress(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00197   <span class="keywordtype">long</span> onKeyRelease(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00198   <span class="keywordtype">long</span> onUngrabbed(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00199   <span class="keywordtype">long</span> onDestroy(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00200   <span class="keywordtype">long</span> onFocusSelf(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00201   <span class="keywordtype">long</span> onFocusIn(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00202   <span class="keywordtype">long</span> onFocusOut(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00203   <span class="keywordtype">long</span> onSelectionLost(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00204   <span class="keywordtype">long</span> onSelectionGained(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00205   <span class="keywordtype">long</span> onSelectionRequest(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00206   <span class="keywordtype">long</span> onClipboardLost(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00207   <span class="keywordtype">long</span> onClipboardGained(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00208   <span class="keywordtype">long</span> onClipboardRequest(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00209   <span class="keywordtype">long</span> onDNDEnter(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00210   <span class="keywordtype">long</span> onDNDLeave(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00211   <span class="keywordtype">long</span> onDNDMotion(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00212   <span class="keywordtype">long</span> onDNDDrop(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00213   <span class="keywordtype">long</span> onDNDRequest(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00214   <span class="keywordtype">long</span> onCmdShow(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00215   <span class="keywordtype">long</span> onCmdHide(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00216   <span class="keywordtype">long</span> onUpdToggleShown(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00217   <span class="keywordtype">long</span> onCmdToggleShown(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00218   <span class="keywordtype">long</span> onCmdRaise(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00219   <span class="keywordtype">long</span> onCmdLower(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00220   <span class="keywordtype">long</span> onCmdEnable(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00221   <span class="keywordtype">long</span> onCmdDisable(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00222   <span class="keywordtype">long</span> onCmdUpdate(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00223   <span class="keywordtype">long</span> onUpdYes(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00224   <span class="keywordtype">long</span> onCmdDelete(FXObject*,FXSelector,<span class="keywordtype">void</span>*);
00225 
00226 <span class="keyword">public</span>:
00227 
00228   <span class="comment">// Message ID's common to most Windows</span>
00229   <span class="keyword">enum</span> {
00230     ID_NONE,
00231     ID_HIDE,            <span class="comment">// ID_HIDE+FALSE</span>
00232     ID_SHOW,            <span class="comment">// ID_HIDE+TRUE</span>
00233     ID_TOGGLESHOWN,
00234     ID_LOWER,
00235     ID_RAISE,
00236     ID_DELETE,
00237     ID_DISABLE,         <span class="comment">// ID_DISABLE+FALSE</span>
00238     ID_ENABLE,          <span class="comment">// ID_DISABLE+TRUE</span>
00239     ID_UNCHECK,         <span class="comment">// ID_UNCHECK+FALSE</span>
00240     ID_CHECK,           <span class="comment">// ID_UNCHECK+TRUE</span>
00241     ID_UNKNOWN,         <span class="comment">// ID_UNCHECK+MAYBE</span>
00242     ID_UPDATE,
00243     ID_AUTOSCROLL,
00244     ID_TIPTIMER,
00245     ID_HSCROLLED,
00246     ID_VSCROLLED,
00247     ID_SETVALUE,
00248     ID_SETINTVALUE,
<a name="l00249"></a><a class="code" href="classFX_1_1FXWindow.html#a1">00249</a>     ID_SETREALVALUE,
00250     ID_SETSTRINGVALUE,
00251     ID_SETICONVALUE,
<a name="l00252"></a><a class="code" href="classFX_1_1FXWindow.html#a2">00252</a>     ID_SETINTRANGE,
00253     ID_SETREALRANGE,
00254     ID_GETINTVALUE,
00255     ID_GETREALVALUE,
00256     ID_GETSTRINGVALUE,
00257     ID_GETICONVALUE,
00258     ID_GETINTRANGE,
00259     ID_GETREALRANGE,
00260     ID_SETHELPSTRING,
<a name="l00261"></a><a class="code" href="classFX_1_1FXWindow.html#a5">00261</a>     ID_GETHELPSTRING,
00262     ID_SETTIPSTRING,
00263     ID_GETTIPSTRING,
<a name="l00264"></a><a class="code" href="classFX_1_1FXWindow.html#a6">00264</a>     ID_QUERY_TIP,
00265     ID_QUERY_HELP,
00266     ID_QUERY_MENU,
<a name="l00267"></a><a class="code" href="classFX_1_1FXWindow.html#a7">00267</a>     ID_HOTKEY,
00268     ID_ACCEL,
00269     ID_UNPOST,
<a name="l00270"></a><a class="code" href="classFX_1_1FXWindow.html#a8">00270</a>     ID_POST,
00271     ID_MDI_TILEHORIZONTAL,
00272     ID_MDI_TILEVERTICAL,
<a name="l00273"></a><a class="code" href="classFX_1_1FXWindow.html#a9">00273</a>     ID_MDI_CASCADE,
00274     ID_MDI_MAXIMIZE,
00275     ID_MDI_MINIMIZE,
<a name="l00276"></a><a class="code" href="classFX_1_1FXWindow.html#a10">00276</a>     ID_MDI_RESTORE,
00277     ID_MDI_CLOSE,
00278     ID_MDI_WINDOW,
<a name="l00279"></a><a class="code" href="classFX_1_1FXWindow.html#a11">00279</a>     ID_MDI_MENUWINDOW,
00280     ID_MDI_MENUMINIMIZE,
00281     ID_MDI_MENURESTORE,
<a name="l00282"></a><a class="code" href="classFX_1_1FXWindow.html#a12">00282</a>     ID_MDI_MENUCLOSE,
00283     ID_MDI_NEXT,
00284     ID_MDI_PREV,
<a name="l00285"></a><a class="code" href="classFX_1_1FXWindow.html#a13">00285</a>     ID_LAST
00286     };
00287 
<a name="l00288"></a><a class="code" href="classFX_1_1FXWindow.html#a14">00288</a> <span class="keyword">public</span>:
00289 
00290   <span class="comment">// Common DND type names</span>
<a name="l00291"></a><a class="code" href="classFX_1_1FXWindow.html#a15">00291</a>   <span class="keyword">static</span> <span class="keyword">const</span> FXchar deleteTypeName[];
00292   <span class="keyword">static</span> <span class="keyword">const</span> FXchar textTypeName[];
00293   <span class="keyword">static</span> <span class="keyword">const</span> FXchar colorTypeName[];
<a name="l00294"></a><a class="code" href="classFX_1_1FXWindow.html#a16">00294</a>   <span class="keyword">static</span> <span class="keyword">const</span> FXchar urilistTypeName[];
00295 
00296 <span class="keyword">public</span>:
<a name="l00297"></a><a class="code" href="classFX_1_1FXWindow.html#a17">00297</a> <span class="comment"></span>
00298 <span class="comment">  /// Constructor</span>
00299 <span class="comment"></span>  FXWindow(<a class="code" href="classFX_1_1FXComposite.html">FXComposite</a>* p,FXuint opts=0,FXint x=0,FXint y=0,FXint w=0,FXint h=0);
00300 <span class="comment"></span>
00301 <span class="comment">  /// Return a pointer to the parent window</span>
00302 <span class="comment"></span>  FXWindow* getParent()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> parent; }
00303 <span class="comment"></span>
00304 <span class="comment">  /// Return a pointer to the owner window</span>
00305 <span class="comment"></span>  FXWindow* getOwner()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> owner; }
00306 <span class="comment"></span>
00307 <span class="comment">  /// Return a pointer to the shell window</span>
00308 <span class="comment"></span>  FXWindow* getShell() <span class="keyword">const</span>;
00309 <span class="comment"></span>
00310 <span class="comment">  /// Return a pointer to the root window</span>
00311 <span class="comment"></span>  FXWindow* getRoot() <span class="keyword">const</span>;
00312 <span class="comment"></span>
00313 <span class="comment">  /// Return a pointer to the next (sibling) window, if any</span>
00314 <span class="comment"></span>  FXWindow* getNext()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> next; }
00315 <span class="comment"></span>
00316 <span class="comment">  /// Return a pointer to the previous (sibling) window , if any</span>
00317 <span class="comment"></span>  FXWindow* getPrev()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> prev; }
00318 <span class="comment"></span>
00319 <span class="comment">  /// Return a pointer to this window's first child window , if any</span>
00320 <span class="comment"></span>  FXWindow* getFirst()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> first; }
00321 <span class="comment"></span>
00322 <span class="comment">  /// Return a pointer to this window's last child window, if any</span>
00323 <span class="comment"></span>  FXWindow* getLast()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> last; }
00324 <span class="comment"></span>
00325 <span class="comment">  /// Return a pointer to the currently focused child window</span>
00326 <span class="comment"></span>  FXWindow* getFocus()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> focus; }
00327 <span class="comment"></span>
00328 <span class="comment">  /// Change window key</span>
00329 <span class="comment"></span>  <span class="keywordtype">void</span> setKey(FXuint k){ wk=k; }
<a name="l00330"></a><a class="code" href="classFX_1_1FXWindow.html#a28">00330</a> <span class="comment"></span>
00331 <span class="comment">  /// Return window key</span>
00332 <span class="comment"></span>  FXuint getKey()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> wk; }
<a name="l00333"></a><a class="code" href="classFX_1_1FXWindow.html#a29">00333</a> <span class="comment"></span>
00334 <span class="comment">  /// Set the message target object for this window</span>
00335 <span class="comment"></span>  <span class="keywordtype">void</span> setTarget(<a class="code" href="classFX_1_1FXObject.html">FXObject</a> *t){ target=t; }
00336 <span class="comment"></span>
00337 <span class="comment">  /// Get the message target object for this window, if any</span>
00338 <span class="comment"></span>  FXObject* getTarget()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> target; }
00339 <span class="comment"></span>
00340 <span class="comment">  /// Set the message identifier for this window</span>
00341 <span class="comment"></span>  <span class="keywordtype">void</span> setSelector(FXSelector sel){ message=sel; }
<a name="l00342"></a><a class="code" href="classFX_1_1FXWindow.html#a32">00342</a> <span class="comment"></span>
00343 <span class="comment">  /// Get the message identifier for this window</span>
00344 <span class="comment"></span>  FXSelector getSelector()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> message; }
<a name="l00345"></a><a class="code" href="classFX_1_1FXWindow.html#a33">00345</a> <span class="comment"></span>
00346 <span class="comment">  /// Get this window's x-coordinate, in the parent's coordinate system</span>
00347 <span class="comment"></span>  FXint getX()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> xpos; }
00348 <span class="comment"></span>
00349 <span class="comment">  /// Get this window's y-coordinate, in the parent's coordinate system</span>
00350 <span class="comment"></span>  FXint getY()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> ypos; }
00351 <span class="comment"></span>
00352 <span class="comment">  /// Return the default width of this window</span>
00353 <span class="comment"></span>  <span class="keyword">virtual</span> FXint getDefaultWidth();
00354 <span class="comment"></span>
00355 <span class="comment">  /// Return the default height of this window</span>
00356 <span class="comment"></span>  <span class="keyword">virtual</span> FXint getDefaultHeight();
00357 <span class="comment"></span>
00358 <span class="comment">  /// Return width for given height</span>
00359 <span class="comment"></span>  <span class="keyword">virtual</span> FXint getWidthForHeight(FXint givenheight);
00360 <span class="comment"></span>
00361 <span class="comment">  /// Return height for given width</span>
00362 <span class="comment"></span>  <span class="keyword">virtual</span> FXint getHeightForWidth(FXint givenwidth);
00363 <span class="comment"></span>
00364 <span class="comment">  /// Set this window's x-coordinate, in the parent's coordinate system</span>
00365 <span class="comment"></span>  <span class="keywordtype">void</span> setX(FXint x);
00366 <span class="comment"></span>
00367 <span class="comment">  /// Set this window's y-coordinate, in the parent's coordinate system</span>
00368 <span class="comment"></span>  <span class="keywordtype">void</span> setY(FXint y);
00369 <span class="comment"></span>
00370 <span class="comment">  /// Set the window width</span>
00371 <span class="comment"></span>  <span class="keywordtype">void</span> setWidth(FXint w);
00372 <span class="comment"></span>
00373 <span class="comment">  /// Set the window height</span>
00374 <span class="comment"></span>  <span class="keywordtype">void</span> setHeight(FXint h);
00375 <span class="comment"></span>
00376 <span class="comment">  /// Set layout hints for this window</span>
00377 <span class="comment"></span>  <span class="keywordtype">void</span> setLayoutHints(FXuint lout);
00378 <span class="comment"></span>
00379 <span class="comment">  /// Get layout hints for this window</span>
00380 <span class="comment"></span>  FXuint getLayoutHints() <span class="keyword">const</span>;
00381 <span class="comment"></span>
00382 <span class="comment">  /// Return a pointer to the accelerator table</span>
00383 <span class="comment"></span>  FXAccelTable* getAccelTable()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> accelTable; }
<a name="l00384"></a><a class="code" href="classFX_1_1FXWindow.html#a43">00384</a> <span class="comment"></span>
00385 <span class="comment">  /// Set the accelerator table</span>
00386 <span class="comment"></span>  <span class="keywordtype">void</span> setAccelTable(<a class="code" href="classFX_1_1FXAccelTable.html">FXAccelTable</a>* acceltable){ accelTable=acceltable; }
00387 <span class="comment"></span>
00388 <span class="comment">  /// Add a hot key</span>
00389 <span class="comment"></span>  <span class="keywordtype">void</span> addHotKey(FXHotKey code);
<a name="l00390"></a><a class="code" href="classFX_1_1FXWindow.html#a45">00390</a> <span class="comment"></span>
00391 <span class="comment">  /// Remove a hot key</span>
00392 <span class="comment"></span>  <span class="keywordtype">void</span> remHotKey(FXHotKey code);
00393 <span class="comment"></span>
00394 <span class="comment">  /// Change help tag for this widget</span>
00395 <span class="comment"></span>  <span class="keywordtype">void</span> setHelpTag(<span class="keyword">const</span> <a class="code" href="classFX_1_1FXString.html">FXString</a>&amp;  text){ tag=text; }
00396 <span class="comment"></span>
00397 <span class="comment">  /// Get the help tag for this widget</span>
00398 <span class="comment"></span>  FXString getHelpTag()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> tag; }
00399 <span class="comment"></span>
00400 <span class="comment">  /// Return true if window is a shell window</span>
00401 <span class="comment"></span>  FXbool isShell() <span class="keyword">const</span>;
00402 <span class="comment"></span>
00403 <span class="comment">  /// Return true if specified window is owned by this window</span>
00404 <span class="comment"></span>  FXbool isOwnerOf(<span class="keyword">const</span> FXWindow* window) <span class="keyword">const</span>;
00405 <span class="comment"></span>
00406 <span class="comment">  /// Return true if specified window is ancestor of this window</span>
00407 <span class="comment"></span>  FXbool isChildOf(<span class="keyword">const</span> FXWindow* window) <span class="keyword">const</span>;
00408 <span class="comment"></span>
00409 <span class="comment">  /// Return true if this window contains child in its subtree</span>
00410 <span class="comment"></span>  FXbool containsChild(<span class="keyword">const</span> FXWindow* child) <span class="keyword">const</span>;
00411 <span class="comment"></span>
00412 <span class="comment">  /// Return the child window at specified coordinates</span>
00413 <span class="comment"></span>  FXWindow* getChildAt(FXint x,FXint y) <span class="keyword">const</span>;
00414 <span class="comment"></span>
00415 <span class="comment">  /// Return the number of child windows for this window</span>
00416 <span class="comment"></span>  FXint numChildren() <span class="keyword">const</span>;
00417 <span class="comment"></span>
00418 <span class="comment">  /**</span>
00419 <span class="comment">  * Return the index (starting from zero) of the specified child window,</span>
00420 <span class="comment">  * or -1 if the window is not a child or NULL</span>
00421 <span class="comment">  */</span>
00422   FXint indexOfChild(<span class="keyword">const</span> FXWindow *window) <span class="keyword">const</span>;
00423 <span class="comment"></span>
00424 <span class="comment">  /**</span>
00425 <span class="comment">  * Return the child window at specified index,</span>
00426 <span class="comment">  * or NULL if the index is negative or out of range</span>
00427 <span class="comment">  */</span>
00428   FXWindow* childAtIndex(FXint index) <span class="keyword">const</span>;
00429 <span class="comment"></span>
00430 <span class="comment">  /// Return the common ancestor of window a and window b</span>
00431 <span class="comment"></span>  <span class="keyword">static</span> FXWindow* commonAncestor(FXWindow* a,FXWindow* b);
00432 <span class="comment"></span>
00433 <span class="comment">  /// Set the default cursor for this window</span>
00434 <span class="comment"></span>  <span class="keywordtype">void</span> setDefaultCursor(FXCursor* cur);
00435 <span class="comment"></span>
00436 <span class="comment">  /// Return the default cursor for this window</span>
00437 <span class="comment"></span>  FXCursor* getDefaultCursor()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> defaultCursor; }
00438 <span class="comment"></span>
00439 <span class="comment">  /// Set the drag cursor for this window</span>
00440 <span class="comment"></span>  <span class="keywordtype">void</span> setDragCursor(FXCursor* cur);
00441 <span class="comment"></span>
00442 <span class="comment">  /// Return the drag cursor for this window</span>
00443 <span class="comment"></span>  FXCursor* getDragCursor()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> dragCursor; }
00444 <span class="comment"></span>
00445 <span class="comment">  /// Return the cursor position and mouse button-state</span>
00446 <span class="comment"></span>  FXint getCursorPosition(FXint&amp; x,FXint&amp; y,FXuint&amp; buttons) <span class="keyword">const</span>;
00447 <span class="comment"></span>
00448 <span class="comment">  /// Warp the cursor to the new position</span>
00449 <span class="comment"></span>  FXint setCursorPosition(FXint x,FXint y);
00450 <span class="comment"></span>
00451 <span class="comment">  /// Return true if this window is able to receive mouse and keyboard events</span>
00452 <span class="comment"></span>  FXbool isEnabled() <span class="keyword">const</span>;
00453 <span class="comment"></span>
00454 <span class="comment">  /// Return true if the window is active</span>
00455 <span class="comment"></span>  FXbool isActive() <span class="keyword">const</span>;
00456 <span class="comment"></span>
00457 <span class="comment">  /// Return true if this window is a control capable of receiving the focus</span>
00458 <span class="comment"></span>  <span class="keyword">virtual</span> FXbool canFocus() <span class="keyword">const</span>;
00459 <span class="comment"></span>
00460 <span class="comment">  /// Return true if this window has the focus</span>
00461 <span class="comment"></span>  FXbool hasFocus() <span class="keyword">const</span>;
00462 <span class="comment"></span>
00463 <span class="comment">  /// Move the focus to this window</span>
00464 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> setFocus();
00465 <span class="comment"></span>
00466 <span class="comment">  /// Remove the focus from this window</span>
00467 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> killFocus();
00468 <span class="comment"></span>
00469 <span class="comment">  /**</span>
00470 <span class="comment">  * This changes the default window which responds to the Return</span>
00471 <span class="comment">  * key in a dialog. If enable is TRUE, this window becomes the default</span>
00472 <span class="comment">  * window; when enable is FALSE, this window will be no longer the</span>
00473 <span class="comment">  * default window.  Finally, when enable is MAYBE, the default window</span>
00474 <span class="comment">  * will revert to the initial default window.</span>
00475 <span class="comment">  */</span>
00476   <span class="keyword">virtual</span> <span class="keywordtype">void</span> setDefault(FXbool enable=TRUE);
00477 <span class="comment"></span>
00478 <span class="comment">  /// Return true if this is the default window</span>
00479 <span class="comment"></span>  FXbool isDefault() <span class="keyword">const</span>;
00480 <span class="comment"></span>
00481 <span class="comment">  /// Make this window the initial default window</span>
00482 <span class="comment"></span>  <span class="keywordtype">void</span> setInitial(FXbool enable=TRUE);
00483 <span class="comment"></span>
00484 <span class="comment">  /// Return true if this is the initial default window</span>
00485 <span class="comment"></span>  FXbool isInitial() <span class="keyword">const</span>;
00486 <span class="comment"></span>
00487 <span class="comment">  /// Enable the window to receive mouse and keyboard events</span>
00488 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> enable();
00489 <span class="comment"></span>
00490 <span class="comment">  /// Disable the window from receiving mouse and keyboard events</span>
00491 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> disable();
00492 <span class="comment"></span>
00493 <span class="comment">  /// Create all of the server-side resources for this window</span>
00494 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> create();
00495 <span class="comment"></span>
00496 <span class="comment">  /// Attach foreign window handle to this window</span>
00497 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> attach(FXID w);
00498 <span class="comment"></span>
00499 <span class="comment">  /// Detach the server-side resources for this window</span>
00500 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> detach();
00501 <span class="comment"></span>
00502 <span class="comment">  /// Destroy the server-side resources for this window</span>
00503 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> destroy();
00504 <span class="comment"></span>
00505 <span class="comment">  /// Raise this window to the top of the stacking order</span>
00506 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> raise();
00507 <span class="comment"></span>
00508 <span class="comment">  /// Lower this window to the bottom of the stacking order</span>
00509 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> lower();
00510 <span class="comment"></span>
00511 <span class="comment">  /// Move this window to the specified position in the parent's coordinates</span>
00512 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> move(FXint x,FXint y);
00513 <span class="comment"></span>
00514 <span class="comment">  /// Resize this window to the specified width and height</span>
00515 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> resize(FXint w,FXint h);
00516 <span class="comment"></span>
00517 <span class="comment">  /// Move and resize this window in the parent's coordinates</span>
00518 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> position(FXint x,FXint y,FXint w,FXint h);
00519 <span class="comment"></span>
00520 <span class="comment">  /// Mark this window's layout as dirty for later layout</span>
00521 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> recalc();
00522 <span class="comment"></span>
00523 <span class="comment">  /// Perform layout immediately</span>
00524 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> layout();
00525 <span class="comment"></span>
00526 <span class="comment">  /// Force a GUI update of this window and its children</span>
00527 <span class="comment"></span>  <span class="keywordtype">void</span> forceRefresh();
00528 <span class="comment"></span>
00529 <span class="comment">  /// Change the parent for this window</span>
00530 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> reparent(FXWindow* newparent);
00531 <span class="comment"></span>
00532 <span class="comment">  /// Scroll rectangle x,y,w,h by a shift of dx,dy</span>
00533 <span class="comment"></span>  <span class="keywordtype">void</span> scroll(FXint x,FXint y,FXint w,FXint h,FXint dx,FXint dy) <span class="keyword">const</span>;
00534 <span class="comment"></span>
00535 <span class="comment">  /// Mark the specified rectangle to be repainted later</span>
00536 <span class="comment"></span>  <span class="keywordtype">void</span> update(FXint x,FXint y,FXint w,FXint h) <span class="keyword">const</span>;
00537 <span class="comment"></span>
00538 <span class="comment">  /// Mark the entire window to be repainted later</span>
00539 <span class="comment"></span>  <span class="keywordtype">void</span> update() <span class="keyword">const</span>;
00540 <span class="comment"></span>
00541 <span class="comment">  /// If marked but not yet painted, paint the given rectangle now</span>
00542 <span class="comment"></span>  <span class="keywordtype">void</span> repaint(FXint x,FXint y,FXint w,FXint h) <span class="keyword">const</span>;
00543 <span class="comment"></span>
00544 <span class="comment">  /// If marked but not yet painted, paint the window now</span>
00545 <span class="comment"></span>  <span class="keywordtype">void</span> repaint() <span class="keyword">const</span>;
00546 <span class="comment"></span>
00547 <span class="comment">  /**</span>
00548 <span class="comment">  * Grab the mouse to this window; future mouse events will be</span>
00549 <span class="comment">  * reported to this window even while the cursor goes outside of this window</span>
00550 <span class="comment">  */</span>
00551   <span class="keywordtype">void</span> grab();
00552 <span class="comment"></span>
00553 <span class="comment">  /// Release the mouse grab</span>
00554 <span class="comment"></span>  <span class="keywordtype">void</span> ungrab();
00555 <span class="comment"></span>
00556 <span class="comment">  /// Return true if the window has been grabbed</span>
00557 <span class="comment"></span>  FXbool grabbed() <span class="keyword">const</span>;
00558 <span class="comment"></span>
00559 <span class="comment">  /// Grab keyboard device</span>
00560 <span class="comment"></span>  <span class="keywordtype">void</span> grabKeyboard();
00561 <span class="comment"></span>
00562 <span class="comment">  /// Ungrab keyboard device</span>
00563 <span class="comment"></span>  <span class="keywordtype">void</span> ungrabKeyboard();
00564 <span class="comment"></span>
00565 <span class="comment">  /// Return true if active grab is in effect</span>
00566 <span class="comment"></span>  FXbool grabbedKeyboard() <span class="keyword">const</span>;
00567 <span class="comment"></span>
00568 <span class="comment">  /// Show this window</span>
00569 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> show();
00570 <span class="comment"></span>
00571 <span class="comment">  /// Hide this window</span>
00572 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> hide();
00573 <span class="comment"></span>
00574 <span class="comment">  /// Return true if the window is shown</span>
00575 <span class="comment"></span>  FXbool shown() <span class="keyword">const</span>;
00576 <span class="comment"></span>
00577 <span class="comment">  /// Return true if the window is composite</span>
00578 <span class="comment"></span>  <span class="keyword">virtual</span> FXbool isComposite() <span class="keyword">const</span>;
00579 <span class="comment"></span>
00580 <span class="comment">  /// Return true if the window is under the cursor</span>
00581 <span class="comment"></span>  FXbool underCursor() <span class="keyword">const</span>;
00582 <span class="comment"></span>
00583 <span class="comment">  /// Return true if this window owns the primary selection</span>
00584 <span class="comment"></span>  FXbool hasSelection() <span class="keyword">const</span>;
00585 <span class="comment"></span>
00586 <span class="comment">  /// Try to acquire the primary selection, given a list of drag types</span>
00587 <span class="comment"></span>  FXbool acquireSelection(<span class="keyword">const</span> FXDragType *types,FXuint numtypes);
00588 <span class="comment"></span>
00589 <span class="comment">  /// Release the primary selection</span>
00590 <span class="comment"></span>  FXbool releaseSelection();
00591 <span class="comment"></span>
00592 <span class="comment">  /// Return true if this window owns the clipboard</span>
00593 <span class="comment"></span>  FXbool hasClipboard() <span class="keyword">const</span>;
00594 <span class="comment"></span>
00595 <span class="comment">  /// Try to acquire the clipboard, given a list of drag types</span>
00596 <span class="comment"></span>  FXbool acquireClipboard(<span class="keyword">const</span> FXDragType *types,FXuint numtypes);
00597 <span class="comment"></span>
00598 <span class="comment">  /// Release the clipboard</span>
00599 <span class="comment"></span>  FXbool releaseClipboard();
00600 <span class="comment"></span>
00601 <span class="comment">  /// Enable this window to receive drops</span>
00602 <span class="comment"></span>  <span class="keywordtype">void</span> dropEnable();
00603 <span class="comment"></span>
00604 <span class="comment">  /// Disable this window from receiving drops</span>
00605 <span class="comment"></span>  <span class="keywordtype">void</span> dropDisable();
00606 <span class="comment"></span>
00607 <span class="comment">  /// Return true if this window is able to receive drops</span>
00608 <span class="comment"></span>  FXbool isDropEnabled() <span class="keyword">const</span>;
00609 <span class="comment"></span>
00610 <span class="comment">  /// Return true if a drag operaion has been initiated from this window</span>
00611 <span class="comment"></span>  FXbool isDragging() <span class="keyword">const</span>;
00612 <span class="comment"></span>
00613 <span class="comment">  /// Initiate a drag operation with a list of previously registered drag types</span>
00614 <span class="comment"></span>  FXbool beginDrag(<span class="keyword">const</span> FXDragType *types,FXuint numtypes);
00615 <span class="comment"></span>
00616 <span class="comment">  /**</span>
00617 <span class="comment">  * When dragging, inform the drop-target of the new position and</span>
00618 <span class="comment">  * the drag action</span>
00619 <span class="comment">  */</span>
00620   FXbool handleDrag(FXint x,FXint y,FXDragAction action=DRAG_COPY);
00621 <span class="comment"></span>
00622 <span class="comment">  /// Terminate the drag operation with or without actually dropping the data</span>
00623 <span class="comment"></span>  FXbool endDrag(FXbool drop=TRUE);
00624 <span class="comment"></span>
00625 <span class="comment">  /// Return true if this window is the target of a drop</span>
00626 <span class="comment"></span>  FXbool isDropTarget() <span class="keyword">const</span>;
<a name="l00627"></a><a class="code" href="classFX_1_1FXWindow.html#a116">00627</a> <span class="comment"></span>
00628 <span class="comment">  /**</span>
00629 <span class="comment">  * When being dragged over, indicate that no further SEL_DND_MOTION messages</span>
00630 <span class="comment">  * are required while the cursor is inside the given rectangle</span>
00631 <span class="comment">  */</span>
00632   <span class="keywordtype">void</span> setDragRectangle(FXint x,FXint y,FXint w,FXint h,FXbool wantupdates=TRUE) <span class="keyword">const</span>;
00633 <span class="comment"></span>
00634 <span class="comment">  /**</span>
00635 <span class="comment">  * When being dragged over, indicate we want to receive SEL_DND_MOTION messages</span>
00636 <span class="comment">  * every time the cursor moves</span>
00637 <span class="comment">  */</span>
00638   <span class="keywordtype">void</span> clearDragRectangle() <span class="keyword">const</span>;
00639 <span class="comment"></span>
00640 <span class="comment">  /// When being dragged over, indicate acceptance or rejection of the dragged data</span>
00641 <span class="comment"></span>  <span class="keywordtype">void</span> acceptDrop(FXDragAction action=DRAG_ACCEPT) <span class="keyword">const</span>;
00642 <span class="comment"></span>
00643 <span class="comment">  /// The target accepted our drop</span>
00644 <span class="comment"></span>  <a class="code" href="group__fxdefs__6.html#a0">FXDragAction</a> didAccept() <span class="keyword">const</span>;
00645 <span class="comment"></span>
00646 <span class="comment">  /// When being dragged over, inquire the drag types which are being offered</span>
00647 <span class="comment"></span>  FXbool inquireDNDTypes(FXDNDOrigin origin,FXDragType*&amp; types,FXuint&amp; numtypes) <span class="keyword">const</span>;
00648 <span class="comment"></span>
00649 <span class="comment">  /// When being dragged over, return true if we are offered the given drag type</span>
00650 <span class="comment"></span>  FXbool offeredDNDType(FXDNDOrigin origin,FXDragType type) <span class="keyword">const</span>;
00651 <span class="comment"></span>
00652 <span class="comment">  /// When being dragged over, return the drag action</span>
00653 <span class="comment"></span>  <a class="code" href="group__fxdefs__6.html#a0">FXDragAction</a> inquireDNDAction() <span class="keyword">const</span>;
00654 <span class="comment"></span>
00655 <span class="comment">  /**</span>
00656 <span class="comment">  * Set DND data; the array must be allocated with FXMALLOC and ownership is</span>
00657 <span class="comment">  * transferred to the system</span>
00658 <span class="comment">  */</span>
00659   FXbool setDNDData(FXDNDOrigin origin,FXDragType type,FXuchar* data,FXuint size) <span class="keyword">const</span>;
00660 <span class="comment"></span>
00661 <span class="comment">  /**</span>
00662 <span class="comment">  * Get DND data; the caller becomes the owner of the array and must free it</span>
00663 <span class="comment">  * with FXFREE</span>
00664 <span class="comment">  */</span>
00665   FXbool getDNDData(FXDNDOrigin origin,FXDragType type,FXuchar*&amp; data,FXuint&amp; size) <span class="keyword">const</span>;
00666 <span class="comment"></span>
00667 <span class="comment">  /// Return true if window logically contains the given point</span>
00668 <span class="comment"></span>  <span class="keyword">virtual</span> FXbool contains(FXint parentx,FXint parenty) <span class="keyword">const</span>;
00669 <span class="comment"></span>
00670 <span class="comment">  /// Translate coordinates from fromwindow's coordinate space to this window's coordinate space</span>
00671 <span class="comment"></span>  <span class="keywordtype">void</span> translateCoordinatesFrom(FXint&amp; tox,FXint&amp; toy,<span class="keyword">const</span> FXWindow* fromwindow,FXint fromx,FXint fromy) <span class="keyword">const</span>;
00672 <span class="comment"></span>
00673 <span class="comment">  /// Translate coordinates from this window's coordinate space to towindow's coordinate space</span>
00674 <span class="comment"></span>  <span class="keywordtype">void</span> translateCoordinatesTo(FXint&amp; tox,FXint&amp; toy,<span class="keyword">const</span> FXWindow* towindow,FXint fromx,FXint fromy) <span class="keyword">const</span>;
00675 <span class="comment"></span>
00676 <span class="comment">  /// Set window background color</span>
00677 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> setBackColor(FXColor clr);
00678 <span class="comment"></span>
00679 <span class="comment">  /// Get background color</span>
00680 <span class="comment"></span>  FXColor getBackColor()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> backColor; }
00681 <span class="comment"></span>
00682 <span class="comment">  /// Relink this window before sibling in the window list</span>
00683 <span class="comment"></span>  <span class="keywordtype">void</span> linkBefore(FXWindow* sibling);
00684 <span class="comment"></span>
00685 <span class="comment">  /// Relink this window after sibling in the window list</span>
00686 <span class="comment"></span>  <span class="keywordtype">void</span> linkAfter(FXWindow* sibling);
00687 
00688   <span class="keyword">virtual</span> FXbool doesSaveUnder() <span class="keyword">const</span>;
00689 <span class="comment"></span>
00690 <span class="comment">  /// Save window to stream</span>
00691 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> save(FXStream&amp; store) <span class="keyword">const</span>;
00692 <span class="comment"></span>
00693 <span class="comment">  /// Restore window from stream</span>
00694 <span class="comment"></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> load(FXStream&amp; store);
00695 <span class="comment"></span>
00696 <span class="comment">  /// Destroy window</span>
00697 <span class="comment"></span>  <span class="keyword">virtual</span> ~FXWindow();
00698   };
00699 
00700 }
00701 
00702 <span class="preprocessor">#endif</span>
</pre></div></font>

<!--- COPYRIGHT -->
<p>
<table width=100% cellpadding=0 cellspacing=0><tr><td width=100% valign=top id=HEADLINE align=right>
<img src='../art/line.gif' width=100% height=1><font size=-1>
Copyright &copy; 1997-2004 Jeroen van der Zijp</font>
</td></tr></table>
</p>
<!--- COPYRIGHT -->
</body>
</html>