base.h

Go to the documentation of this file.
00001 /**
00002  * \file base.h <gre/base.h>
00003  * \brief Base GRE definitions
00004  *
00005  * \if NODOC
00006  * $Id: base.h_v 1.32 2005/10/05 21:47:18 mju Exp $
00007  *
00008  * $Log: base.h_v $
00009  * Revision 1.32  2005/10/05 21:47:18  mju
00010  * Add fwd decl for layer_formula.
00011  *
00012  * Revision 1.31  2005/09/14 21:52:59  mju
00013  * Add rendertarget_GroupActiveElems.
00014  *
00015  * Revision 1.30  2005/07/19 17:05:54  mju
00016  * Add rendertarget_GroupMatte.
00017  *
00018  * Revision 1.29  2005/05/20 20:31:47  mju
00019  * Change datatip member to positive name.
00020  *
00021  * Revision 1.28  2005/05/17 17:35:58  mju
00022  * Add noHighlight to datatipparms.
00023  *
00024  * Revision 1.27  2005/05/03 15:02:17  mju
00025  * Add rendertarget_None.
00026  *
00027  * Revision 1.26  2005/05/02 17:43:28  mju
00028  * Add drawflag_useDataTipColor.
00029  *
00030  * Revision 1.25  2005/04/29 18:07:10  mju
00031  * Fix enum order.
00032  *
00033  * Revision 1.24  2005/04/29 17:49:06  mju
00034  * Add rendertarget enum.
00035  *
00036  * Revision 1.23  2005/03/31 16:57:05  fileserver!dwilliss
00037  * Rename one of our types to MIUNICODE because it conflicted with a Microsoft #define
00038  *
00039  * Revision 1.22  2005/03/01 22:59:45  scowan
00040  * Removed unused all background flag.
00041  *
00042  * Revision 1.21  2005/03/01 14:20:27  mju
00043  * Remove unused/unneeded drawflag values.
00044  *
00045  * Revision 1.20  2005/02/24 18:52:07  mju
00046  * Add drawflag_erase.
00047  *
00048  * Revision 1.19  2005/02/23 16:55:45  mju
00049  * Add drawflag_onlyHighlighted.
00050  *
00051  * Revision 1.18  2005/02/21 18:45:55  mju
00052  * Add drawflags for noHighlighting and includeUnhighlighted.
00053  *
00054  * Revision 1.17  2005/02/18 22:34:10  mju
00055  * Add drawflag_ViewInView.
00056  *
00057  * Revision 1.16  2005/02/18 17:05:51  mju
00058  * Add drawflag_NoUpdateScreen.
00059  *
00060  * Revision 1.15  2005/02/15 15:37:50  mju
00061  * Remove unused drawflags.
00062  *
00063  * Revision 1.14  2005/02/14 18:52:31  mju
00064  * Add groupview decl.
00065  *
00066  * Revision 1.13  2005/01/20 16:53:37  mju
00067  * Add enums for listpos, drawflags, highlightmode.
00068  * Move some defns here from mdisp.
00069  *
00070  * Revision 1.12  2004/07/21 21:55:39  mju
00071  * Add layerview decl, move labelplacement decls here.
00072  *
00073  * Revision 1.11  2004/04/30 14:04:23  mju
00074  * Fwd declare callback_msg.
00075  *
00076  * Revision 1.10  2004/03/12 20:51:01  mju
00077  * Add copy ctor/op= for datatipparms.
00078  *
00079  * Revision 1.9  2004/03/12 18:19:26  mju
00080  * Change datatipparms prefix/suffix to be mistring.
00081  *
00082  * Revision 1.8  2004/03/04 18:57:24  mju
00083  * Move more shared stuff here.
00084  *
00085  * Revision 1.7  2004/02/06 16:00:50  mju
00086  * Add GRE_FIND_FLAGS enum.
00087  *
00088  * Revision 1.4  2003/09/15 13:48:59  fileserver!dwilliss
00089  * Doxygen
00090  *
00091  * Revision 1.3  2003/07/30 14:43:49  mju
00092  * Ignore forward decls.
00093  *
00094  * Revision 1.2  2003/06/17 13:39:33  mju
00095  * Add MFC_TREEVIEW decl.
00096  *
00097  * Revision 1.1  2003/06/16 19:39:13  mju
00098  * Initial revision
00099  * \endif
00100 **/
00101 
00102 #ifndef  INC_GRE_BASE_H
00103 #define  INC_GRE_BASE_H
00104 
00105 #ifndef  INC_MI32_STDDEFNS_H
00106    #include <mi32/stddefns.h>
00107 #endif
00108 
00109 #ifndef  INC_RVC_STYLE_H
00110    #include <rvc/style.h>
00111 #endif
00112 
00113 #ifndef  INC_MI32_GREMODE_H
00114    #include <mi32/gremode.h>
00115 #endif
00116 
00117 #ifndef  INC_MI32_LABLSTYL_H
00118    #include <mi32/lablstyl.h>
00119 #endif
00120 
00121 
00122 #ifndef GENERATING_DOXYGEN_OUTPUT
00123 // Forward-declare classes.
00124 class GRE_CALLBACK_MSG;
00125 class GRE_ELEMSAMPLE_DC;
00126 class GRE_LAYER;
00127 class GRE_LAYER_FORMULA;
00128 class GRE_LAYER_RASTER;
00129 class GRE_LAYER_SURFACE;
00130 class GRE_LAYERDC;
00131 class GRE_LAYOUT;
00132 class GRE_LEGEND;
00133 class GRE_GROUP;
00134 class GRE_OBJECT;
00135 class GRE_TOOL;
00136 class GRE_VIEW;
00137 class GRE_VIEWABLE;
00138 class GRE_VIEWPOINT3D;
00139 
00140 #ifdef WIN32_MFC
00141 class GRE_MFC_VIEW;
00142 class GRE_MFC_DLGCOMPSELQUERY;
00143 class GRE_MFC_TREEVIEW;
00144 class GRE_MFC_STATUSBAR;
00145 #endif
00146 
00147 namespace GRE {
00148    class LABELPLACE;
00149    class LABELPLACEMENT;
00150    class LAYERVIEW;
00151    class GROUPVIEW;
00152    }
00153 
00154 namespace RVC {
00155    class DBASE;
00156    }
00157 #endif // GENERATING_DOXYGEN_OUTPUT
00158 
00159 
00160 //! GRE object types.
00161 enum GRE_OBJTYPE {
00162    GRE_OBJTYPE_None =   0,
00163    GRE_OBJTYPE_System = 0x01,
00164    GRE_OBJTYPE_Layout = 0x02,
00165    GRE_OBJTYPE_Group =  0x04,
00166    GRE_OBJTYPE_Layer =  0x08,
00167    GRE_OBJTYPE_View =   0x10,
00168    GRE_OBJTYPE_All =    0xFF,
00169    };
00170 DEFINE_ENUM_OP_BITWISE(GRE_OBJTYPE);
00171 
00172 #define  GRE_MAXVIEWS         32             //!< Maximum number of views per viewable object
00173 #define  GRE_GROUP_NAMELEN    64
00174 
00175 #ifdef X_NATIVE
00176 //! Item type in "object manager" list.
00177 enum GRE_OBJMGRITEM {
00178    GRE_OBJMGRITEM_Layer =     0,
00179    GRE_OBJMGRITEM_Component = 1,
00180    GRE_OBJMGRITEM_Table =     2,
00181    GRE_OBJMGRITEM_RawForm =   3,
00182    };
00183 #endif
00184 
00185 enum GRE_FIND_FLAGS {
00186    GRE_FIND_ViewCoords =      0x0000,  //!< Point given in "view" coordinates
00187    GRE_FIND_DisplayCoords =   0x0001,  //!< Point given in "display" coordinates
00188    GRE_FIND_LayerCoords =     0x0002,  //!< Point given in "layer" (object) coordinates
00189    GRE_FIND_UseClosest =      0x0004,  //!< Return closest if no other found
00190    GRE_FIND_NoSingleLayer =   0x0008,  //!< Don't check single-layer groups
00191    GRE_FIND_No3D =            0x0010,  //!< Don't check 3-D groups
00192    GRE_FIND_SearchDrawnSet =  0x0020,  //!< Only search the "drawn" element set
00193    GRE_FIND_MapCoords =       0x0040   //!< Point given in "map" coordinates
00194    };
00195 DEFINE_ENUM_OP_BITWISE(GRE_FIND_FLAGS);
00196 
00197 /*----------------------------------------------------------------------------*/
00198 /*    Flags used in Mdisp...Create functions                                  */
00199 /*----------------------------------------------------------------------------*/
00200 
00201 #define  GRE_SERIAL_VERSION   3
00202 
00203 namespace GRE {
00204 
00205    //! Position in list for use in creation and reordering.
00206    enum LISTPOS {
00207       LISTPOS_First =   0,
00208       LISTPOS_After =   1,
00209       LISTPOS_Before =  2,
00210       LISTPOS_Last =    3
00211       };
00212 
00213    //! Condition for redrawing views.
00214    enum DRAWCONDITION {
00215       DRAWCONDITION_Always,         //!< Always draw
00216       DRAWCONDITION_IfNeeded,       //!< Only draw if has changed
00217       DRAWCONDITION_IfAutoUpdate    //!< Only draw if auto-update preference is on and has changed
00218       };
00219 
00220    //! Drawing flags.
00221    enum DRAWFLAGS {
00222       DRAWFLAG_None =                  0x00000000,
00223       DRAWFLAG_ViewInView =            0x00000001, //!< Draw to view-in-view buffer
00224       DRAWFLAG_OnlyHighlighted =       0x00000002, //!< Only draw 'highlighted' elements
00225       DRAWFLAG_Erase =                 0x00000010, //!< Erase elements (for GRE_VIEW::DrawLayerElement/s)
00226       DRAWFLAG_ForceDraw =             0x00000020, //!< Force all specified elements to draw even if not "selected"
00227       DRAWFLAG_UpdateSearchTree =      0x00000040, //!< Update search tree when drawing even if in tree already
00228       DRAWFLAG_UpdateScreen =          0x00000080, //!< Refresh screen after drawing
00229       DRAWFLAG_NoUpdateScreen =        0x00000100, //!< Disable screen refresh after drawing
00230       DRAWFLAG_NoHighlighting =        0x00000200, //!< Draw elements without highlighting
00231       DRAWFLAG_UpdateBuffers =         0x00000400, //!< Update render buffers
00232       DRAWFLAG_SelectChanged =         DRAWFLAG_UpdateBuffers,
00233       DRAWFLAG_AllNonLocViews =        0x00001000, //!< Draw all non-locator views
00234       DRAWFLAG_NoMessage =             0x00004000, //!< Don't display messages while drawing
00235       DRAWFLAG_Wireframe =             0x00008000, //!< Only draw wireframes
00236       DRAWFLAG_NoResumeTool =          0x00010000, //!< Don't "resume" tool after drawing view
00237       DRAWFLAG_NoBlankScreen =         0x00040000, //!< Don't "blank" screen when start drawing view
00238       DRAWFLAG_NoCallbacks =           0x00400000, //!< Don't invoke callback lists while drawing
00239       DRAWFLAG_CheckDrawnSet =         0x00800000, //!< Check "drawn" set for highlighting
00240       DRAWFLAG_ReduceSpeckle3D =       0x01000000, //!< Perform 3D background speckle reduction
00241       DRAWFLAG_UseDataTipColor =       0x02000000, //!< Draw in 'datatip element' color.
00242       DRAWFLAG_UseHighlightColor =     0x04000000, //!< Draw elements in "highlight" color
00243       DRAWFLAG_UseActiveColor =        0x08000000, //!< Draw element in "active" color
00244       DRAWFLAG_NoCheckVisible =        0x10000000, //!< Don't check visiblity of layer/group in view
00245       DRAWFLAG_LabelPlacementPass =    0x20000000, //!< Internal use: 2nd pass to render just labels
00246       };
00247    DEFINE_ENUM_OP_BITWISE(DRAWFLAGS)
00248 
00249    //! Targets for rendering individual elements.
00250    enum RENDERTARGET {
00251       RENDERTARGET_None =              0x0000,
00252       RENDERTARGET_LayerNormal =       0x0001,     //!< Layer buffer for unhighlighted elements
00253       RENDERTARGET_LayerHighlight =    0x0002,     //!< Layer buffer for highlighted elements
00254       RENDERTARGET_LayerLabel =        0x0004,     //!< Layer buffer for labels
00255       RENDERTARGET_LayerAll =          0x0007,     //!< All layer buffers
00256       RENDERTARGET_Group =             0x0010,     //!< Group combined buffer
00257       RENDERTARGET_GroupActiveElems =  0x0020,     //!< Group 'active elements' buffer
00258       RENDERTARGET_GroupMatte =        0x0040,     //!< Group matte buffer
00259       RENDERTARGET_GroupOverlay =      0x0080,     //!< Group overlay buffer
00260       RENDERTARGET_GroupAll =          0x00F0,     //!< All group buffers
00261       RENDERTARGET_ViewMemory =        0x1000,     //!< View memory buffer
00262       RENDERTARGET_ViewScreen =        0x8000      //!< View screen (unbuffered)
00263       };
00264    DEFINE_ENUM_OP_BITWISE(RENDERTARGET)
00265 
00266    //! Mode for highlighing elements.
00267    enum HIGHLIGHTMODE {
00268       HIGHLIGHTMODE_NotSet =     0,    //!< Not set, use parent's setting
00269       HIGHLIGHTMODE_Replace =    1,    //!< Replace selected set with elements provided
00270       HIGHLIGHTMODE_Add =        2,    //!< Add elements provided to selected set
00271       HIGHLIGHTMODE_Subtract =   3,    //!< Subtract elements from selected set
00272       HIGHLIGHTMODE_Toggle =     4,    //!< Toggle selection status of elements
00273       };
00274    }
00275 
00276 
00277 
00278 #define  MDISPSELECT_ViewCoords           0x0000   //!< Point(s) in "view" coordinates
00279 #define  MDISPSELECT_DisplayCoords        0x0001   //!< Point(s) in "display" coordinates
00280 #define  MDISPSELECT_AutoOpenDefaultLayer 0x0002   //!< Automatically make "default" layer elements selectable
00281 #define  MDISPSELECT_AutoOpenActiveLayer  0x0004   //!< Automatically make "active" layer elements selectable
00282 #define  MDISPSELECT_AutoOpenTable        0x0008   //!< Automatically open table(s) for selectable element types
00283 
00284 #define  MDISPVISIBLE_AllViews         0xFFFFFFFF
00285 #define  MDISPVISIBLE_Locator          0x00000001
00286 #define  MDISPVISIBLE_Hardcopy         0x80000000
00287 
00288 //===================================================================================================================
00289 
00290 #define  LABELSELECT_None           0x0000
00291 #define  LABELSELECT_AllDrawnElem   0x0001   //!< Show labels for all "drawn" elements
00292 #define  LABELSELECT_IfFit          0x0002   //!< If label fits inside/alongside element
00293 
00294 #define  LABELTEXT_None             0x0000
00295 #define  LABELTEXT_ByAttribute      0x0001
00296 #define  LABELTEXT_ByField          LABELTEXT_ByAttribute
00297 #define  LABELTEXT_ByScript         0x0002
00298 #define  LABELTEXT_ByQuery          LABELTEXT_ByScript
00299 
00300 #define  LABELPOSN_Default             0
00301 
00302 #define  LABELPOSN_PointAboveLeft      1
00303 #define  LABELPOSN_PointAboveCenter    2
00304 #define  LABELPOSN_PointAboveRight     3
00305 #define  LABELPOSN_PointCenterLeft     4
00306 #define  LABELPOSN_PointCenter         5
00307 #define  LABELPOSN_PointCenterRight    6
00308 #define  LABELPOSN_PointBelowLeft      7
00309 #define  LABELPOSN_PointBelowCenter    8
00310 #define  LABELPOSN_PointBelowRight     9
00311 
00312 #define  AUTOLABELOPTM_None            0x00
00313 #define  AUTOLABELOPTM_Fast            0x01
00314 #define  AUTOLABELOPTM_Full            0x02
00315 #define  AUTOLABELOPTM_HideOverlap     0x04
00316 
00317 #define  AUTOLABELPRIORITY_AllSame     0
00318 #define  AUTOLABELPRIORITY_ByField     1
00319 #define  AUTOLABELPRIORITY_ByScript    2
00320 
00321 
00322 //===================================================================================================================
00323 //!      Parameters needed for various element types
00324 
00325 //! Selection parameters for determining which elements to draw
00326 struct SELECTPARMS {
00327    public:
00328       UINT16 Mode;                           //!< Selection mode - SELECTMODE_...
00329       INT16 Table;                           //!< 'Selection' table number
00330       MIUNICODE *QueryStr;                   //!< Query script for selection by query
00331       RVC::OBJECTNAME TableName;             //!< 'Selection' table name
00332 
00333       SELECTPARMS (                          //! Default constructor
00334          );
00335       SELECTPARMS (                          //! Copy constructor
00336          const SELECTPARMS& rhs
00337          );
00338       ~SELECTPARMS ();                       //! Destructor
00339 
00340       SELECTPARMS& operator= (               //! Assignment
00341          const SELECTPARMS& rhs
00342          );
00343 
00344       //! Check and validate for specified database and optionally fix mode if none valid.
00345       void CheckTable (
00346          const RVC::DBASE& db,               //!< Database object
00347          bool fixmode                        //!< Fix selection mode if necessary
00348          );
00349 
00350       //! Determine if need to have a valid database table.
00351       bool NeedTable (
00352          ) const { return ((Mode & SELECTMODE_NeedsTable) != 0); }
00353 
00354       //! Validate settings and fix if necessary.
00355       void Validate ();
00356    };
00357 
00358 //! Basic style parameters for element drawing
00359 struct STYLEPARMS {
00360    public:
00361       UINT16 Mode;                           //!< Selection mode - STYLEMODE_...
00362       INT16 Table;                           //!< 'Style assignment' table number
00363       MIUNICODE *QueryStr;                   //!< Query string for styling by scipt
00364       RVC::OBJECTNAME TableName;             //!< 'Style Assignment' table name
00365 
00366       STYLEPARMS (                           //! Default constructor
00367          );
00368       STYLEPARMS (                           //! Copy constructor
00369          const STYLEPARMS& rhs
00370          );
00371       ~STYLEPARMS ();                        //! Destructor
00372 
00373       STYLEPARMS& operator= (                //! Assignment
00374          const STYLEPARMS& rhs
00375          );
00376 
00377       //! Check and validate for specified database and optionally fix mode if none valid.
00378       void CheckTable (
00379          const RVC::DBASE& db,               //!< Database object
00380          bool fixmode,                       //!< Fix selection mode if necessary
00381          const RVC::STYLE::TYPE styletype = RVC::STYLE::TYPE_NumTypes
00382          );
00383 
00384       //! Determine if need to have a valid database table.
00385       bool NeedTable (
00386          ) const { return ((Mode & STYLEMODE_NeedsTable) != 0); }
00387 
00388       //! Validate settings and fix if necessary.
00389       void Validate ();
00390    };
00391 
00392 //! DataTip parameters.
00393 struct DATATIPPARMS {
00394    public:
00395       #ifndef GENERATING_DOXYGEN_OUTPUT
00396       class FORM;
00397       #endif // GENERATING_DOXYGEN_OUTPUT
00398 
00399       RVC::OBJECTNAME TableName;             //!< Table name
00400       RVC::OBJECTNAME FieldName;             //!< Field name
00401       INT32 TableNum;                        //!< Table number
00402       INT32 FieldNum;                        //!< Field number
00403       UINT8 Visible;                         //!< Show this DataTip
00404       UINT8 IsNumeric;                       //!< Set if field is numeric
00405       UINT8 UnitType;                        //!< Field unit type, here for validation against DBFIELDINFO
00406       UINT8 UnitStored;                      //!< Copied from DBFIELDINFO so can use in conversion
00407       UINT8 UnitShown;                       //!< Unit to show field in
00408       UINT8 DecPlaces;                       //!< Decimal places for floating-point fields
00409       UINT8 NoChgField;                      //!< Set if user cannot change field (eg. for RGB raster)
00410       UINT8 HighlightElem;                   //!< Set to highlight element in view when datatip shown
00411       MISTRING Prefix;                       //!< Label to place before value in string, defaults to table.field name
00412       MISTRING Suffix;                       //!< Label to place after value in string, defaults to unit name
00413 
00414       //! Get serialization item definition array.
00415       static const SERIALIZER::ITEMDEF *GetSerialItemDef();
00416 
00417       //! Default constructor.
00418       DATATIPPARMS (
00419          );
00420 
00421       DATATIPPARMS (
00422          const DATATIPPARMS& rhs
00423          );
00424 
00425       DATATIPPARMS& operator= (
00426          const DATATIPPARMS& rhs
00427          );
00428 
00429       //! Set suffix to default based on unit type/shown.
00430       void SetDefaultSuffix (
00431          );
00432 
00433    };
00434 
00435 //! Automatic labeling parameters
00436 struct AUTOLABELPARMS {
00437    public:
00438       static const SERIALIZER::ITEMDEF *GetSerialItemDef();
00439       UINT8 SelectMode;                      //!< LABELSELECT_...
00440       UINT8 TextMode;                        //!< LABELTEXT_...
00441       UINT8 Posn;                            //!< LABELPOSN_... Label position relative to element
00442       UINT8 Optm;                            //!< AUTOLABELOPTM_... Optimization
00443       UINT8 Priority;                        //!< AUTOLABELPRIORITY_... priority mode
00444       RVC::OBJECTNAME TableName;             //!< Table name for LABELMODE_ByField
00445       RVC::OBJECTNAME FieldName;             //!< Field name for LABELMODE_ByField
00446       MIUNICODE *QueryStr;                   //!< Query string for LABELMODE_ByScript
00447       TEXTSTYLE Style;                       //!< Label style
00448       LABELFRAMEPARMS FrameParms;            //!< Label Frame Parameters
00449       RVC::OBJECTNAME PriorityTableName;     //!< Table name for AUTOLABELPRIORITY_ByField
00450       RVC::OBJECTNAME PriorityFieldName;     //!< Field name for AUTOLABELPRIORITY_ByField
00451       double m_MinScaleVisible;              //!< Minimum scale at which labels are visible
00452       double m_MaxScaleVisible;              //!< Maximum scale at which labels are visible
00453 
00454       //! Default constructor
00455       AUTOLABELPARMS (
00456          );
00457 
00458       //! Copy constructor
00459       AUTOLABELPARMS (
00460          const AUTOLABELPARMS& rhs
00461          );
00462 
00463       //! Destructor
00464       ~AUTOLABELPARMS (
00465          );
00466 
00467       //! Assignment
00468       AUTOLABELPARMS& operator= (
00469          const AUTOLABELPARMS& rhs
00470          );
00471 
00472       //! Check and validate for specified database and optionally fix mode if none valid.
00473       void CheckTable (
00474          const RVC::DBASE& db,               //!< Database object
00475          bool fixmode                        //!< Fix mode if necessary
00476          );
00477 
00478       //! Determine if labels are selected and visible at specified scale.
00479       bool IsSelected (
00480          double scale                  //!< Map scale
00481          ) const { return (SelectMode != LABELSELECT_None && scale >= m_MinScaleVisible && (m_MaxScaleVisible <= 0.0 || scale <= m_MaxScaleVisible)); }
00482 
00483       void Validate ();
00484 
00485    private:
00486       #ifndef GENERATING_DOXYGEN_OUTPUT
00487       void Copy (const AUTOLABELPARMS& rhs);
00488       #endif // GENERATING_DOXYGEN_OUTPUT
00489    };
00490 
00491 //! Parameters for LegendView associated with element
00492 struct LEGENDPARMS {
00493    public:
00494 
00495       RVC::OBJECTNAME TableName;             //!< Table for legend labels
00496       RVC::OBJECTNAME FieldName;             //!< Field for legend labels
00497       MGD::STYLESAMPLEFLAGS SampleFlags;           //!< Flags for legend element drawing
00498 
00499       LEGENDPARMS (                          //! Default constructor
00500          ): SampleFlags(MGD::STYLESAMPLE_Default) { }
00501       // No allocated members so can use compiler generated dtor, copy ctor, assignment
00502    };
00503 
00504 //! Point/Node element parameters.
00505 struct POINTPARMS {
00506    public:
00507 
00508       struct POINTSTYLEPARMS : public STYLEPARMS {
00509          POINTSTYLE Normal;                  //!< Style to use in normal drawing
00510          };
00511 
00512       SELECTPARMS Select;
00513       POINTSTYLEPARMS Style;
00514       DATATIPPARMS DataTip;                  //!< DataTip parameters
00515       AUTOLABELPARMS AutoLabel;
00516       LEGENDPARMS Legend;
00517       RVC::OBJECTNAME LegendElemTableName;
00518 
00519       POINTPARMS ();
00520       POINTPARMS (const POINTPARMS& rhs);
00521       ~POINTPARMS ();
00522 
00523       POINTPARMS& operator= (const POINTPARMS& rhs);
00524       void Validate ();
00525    };
00526 
00527 //! Line element parameters
00528 struct LINEPARMS {
00529    public:
00530 
00531       struct LINESTYLEPARMS : public STYLEPARMS {
00532          LINESTYLE Normal;             //!< Style to use in normal drawing
00533          };
00534 
00535       SELECTPARMS Select;
00536       LINESTYLEPARMS Style;
00537       DATATIPPARMS DataTip;            //!< DataTip parameters
00538       AUTOLABELPARMS AutoLabel;
00539       LEGENDPARMS Legend;
00540       RVC::OBJECTNAME LegendElemTableName;
00541 
00542       LINEPARMS ();
00543       LINEPARMS (const LINEPARMS& rhs);
00544       ~LINEPARMS ();
00545 
00546       LINEPARMS& operator= (const LINEPARMS& rhs);
00547       void Validate ();
00548    };
00549 
00550 //! Polygon/Area element parameters
00551 struct POLYPARMS {
00552    public:
00553 
00554       struct POLYSTYLEPARMS : public STYLEPARMS {
00555          POLYSTYLE Normal;             //!< Style to use in normal drawing
00556          };
00557 
00558       SELECTPARMS Select;
00559       POLYSTYLEPARMS Style;
00560       DATATIPPARMS DataTip;            //!< DataTip parameters
00561       AUTOLABELPARMS AutoLabel;
00562       LEGENDPARMS Legend;
00563       LEGENDPARMS LegendInt;           //!< Label inside the polygon sample
00564       RVC::OBJECTNAME LegendElemTableName;
00565       bool ShowInteriorLabel;          //!< Show the label inside the polygon sample
00566       bool ShowLabel;                  //!< Show the label outside the polygon sample
00567 
00568       POLYPARMS ();
00569       POLYPARMS (const POLYPARMS& rhs);
00570       ~POLYPARMS ();
00571 
00572       POLYPARMS& operator= (const POLYPARMS& rhs);
00573       void Validate ();
00574    };
00575 
00576 //! Label/Text element parameters
00577 struct LABELPARMS {
00578    public:
00579 
00580       struct LABELSTYLEPARMS : public STYLEPARMS {
00581          TEXTSTYLE Normal;             //!< Style to use in normal drawing
00582          LABELFRAMEPARMS FrameParms;
00583          
00584          LABELSTYLEPARMS ();
00585          };
00586 
00587       SELECTPARMS Select;
00588       LABELSTYLEPARMS Style;
00589       DATATIPPARMS DataTip;            //!< DataTip parameters
00590       double MinScaleVisible;          //!< Minimum scale at which labels are visible
00591       double MaxScaleVisible;          //!< Maximum scale at which labels are visible
00592 
00593       LABELPARMS ();
00594       LABELPARMS (const LABELPARMS& rhs);
00595       ~LABELPARMS ();
00596 
00597       LABELPARMS& operator= (const LABELPARMS& rhs);
00598 
00599       //! Determine if labels are visible at specified scale.
00600       bool IsVisibleAtScale (
00601          double scale                  //!< Map scale
00602          ) const { return (scale >= MinScaleVisible && (MaxScaleVisible <= 0.0 || scale <= MaxScaleVisible)); }
00603       void Validate ();
00604    };
00605 
00606 //! 3D parameters for 3d points
00607 struct D3POINTPARMS {
00608    public:
00609 
00610       enum MODE {
00611          MODE_None      = 0,
00612          MODE_Height    = 1,
00613          MODE_Elevation = 2
00614          };
00615 
00616       MODE Mode;
00617       RVC::OBJECTNAME TableName; //!<  table for z value
00618       RVC::OBJECTNAME FieldName; //!< field for z value
00619       UINT8 Unit;             //!<  unit for distance
00620       LINEPARMS Line;
00621       POINTPARMS Point;
00622       bool UseColorStack;
00623       COLOR BelowColor;       //!<  Color to display wireframe below surface
00624       COLOR AboveColor;       //!<  Color to display wireframe above surface
00625 
00626       D3POINTPARMS ();
00627       D3POINTPARMS (const D3POINTPARMS& rhs);
00628       ~D3POINTPARMS ();
00629 
00630       D3POINTPARMS& operator= (const D3POINTPARMS& rhs);
00631    };
00632 
00633 //! 3D parameters for 3d polygons
00634 struct D3POLYPARMS {
00635    public:
00636 
00637       enum MODE {
00638          MODE_None      = 0,
00639          MODE_Height    = 1,
00640          MODE_Elevation = 2
00641          };
00642       enum BASE {
00643          BASE_Minimum   = 0,
00644          BASE_Maximum   = 1
00645          };
00646 
00647       MODE Mode;
00648       BASE Base;
00649       RVC::OBJECTNAME TableName;       //!<  table for z value
00650       RVC::OBJECTNAME FieldName;       //!< field for z value
00651       UINT8 Unit;             //!<  unit for distance
00652       POLYPARMS Poly;
00653       bool UseColorStack;
00654       COLOR BelowColor;       //!<  Color to display wireframe below surface
00655       COLOR AboveColor;       //!<  Color to display wireframe above surface
00656 
00657       D3POLYPARMS ();
00658       D3POLYPARMS (const D3POLYPARMS& rhs);
00659       ~D3POLYPARMS ();
00660 
00661       D3POLYPARMS& operator= (const D3POLYPARMS& rhs);
00662    };
00663 
00664 //===================================================================================================================
00665 
00666 #endif   // INC_GRE_BASE_H

Generated on Wed May 31 15:26:38 2006 for TNTsdk by  doxygen 1.3.8-20040913