attr.h

Go to the documentation of this file.
00001 // $Id: attr.h 751 2006-03-31 15:43:49Z alex $
00002 /* @@tag:xara-cn@@ DO NOT MODIFY THIS LINE
00003 ================================XARAHEADERSTART===========================
00004  
00005                Xara LX, a vector drawing and manipulation program.
00006                     Copyright (C) 1993-2006 Xara Group Ltd.
00007        Copyright on certain contributions may be held in joint with their
00008               respective authors. See AUTHORS file for details.
00009 
00010 LICENSE TO USE AND MODIFY SOFTWARE
00011 ----------------------------------
00012 
00013 This file is part of Xara LX.
00014 
00015 Xara LX is free software; you can redistribute it and/or modify it
00016 under the terms of the GNU General Public License version 2 as published
00017 by the Free Software Foundation.
00018 
00019 Xara LX and its component source files are distributed in the hope
00020 that it will be useful, but WITHOUT ANY WARRANTY; without even the
00021 implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
00022 See the GNU General Public License for more details.
00023 
00024 You should have received a copy of the GNU General Public License along
00025 with Xara LX (see the file GPL in the root directory of the
00026 distribution); if not, write to the Free Software Foundation, Inc., 51
00027 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
00028 
00029 
00030 ADDITIONAL RIGHTS
00031 -----------------
00032 
00033 Conditional upon your continuing compliance with the GNU General Public
00034 License described above, Xara Group Ltd grants to you certain additional
00035 rights. 
00036 
00037 The additional rights are to use, modify, and distribute the software
00038 together with the wxWidgets library, the wxXtra library, and the "CDraw"
00039 library and any other such library that any version of Xara LX relased
00040 by Xara Group Ltd requires in order to compile and execute, including
00041 the static linking of that library to XaraLX. In the case of the
00042 "CDraw" library, you may satisfy obligation under the GNU General Public
00043 License to provide source code by providing a binary copy of the library
00044 concerned and a copy of the license accompanying it.
00045 
00046 Nothing in this section restricts any of the rights you have under
00047 the GNU General Public License.
00048 
00049 
00050 SCOPE OF LICENSE
00051 ----------------
00052 
00053 This license applies to this program (XaraLX) and its constituent source
00054 files only, and does not necessarily apply to other Xara products which may
00055 in part share the same code base, and are subject to their own licensing
00056 terms.
00057 
00058 This license does not apply to files in the wxXtra directory, which
00059 are built into a separate library, and are subject to the wxWindows
00060 license contained within that directory in the file "WXXTRA-LICENSE".
00061 
00062 This license does not apply to the binary libraries (if any) within
00063 the "libs" directory, which are subject to a separate license contained
00064 within that directory in the file "LIBS-LICENSE".
00065 
00066 
00067 ARRANGEMENTS FOR CONTRIBUTION OF MODIFICATIONS
00068 ----------------------------------------------
00069 
00070 Subject to the terms of the GNU Public License (see above), you are
00071 free to do whatever you like with your modifications. However, you may
00072 (at your option) wish contribute them to Xara's source tree. You can
00073 find details of how to do this at:
00074   http://www.xaraxtreme.org/developers/
00075 
00076 Prior to contributing your modifications, you will need to complete our
00077 contributor agreement. This can be found at:
00078   http://www.xaraxtreme.org/developers/contribute/
00079 
00080 Please note that Xara will not accept modifications which modify any of
00081 the text between the start and end of this header (marked
00082 XARAHEADERSTART and XARAHEADEREND).
00083 
00084 
00085 MARKS
00086 -----
00087 
00088 Xara, Xara LX, Xara X, Xara X/Xtreme, Xara Xtreme, the Xtreme and Xara
00089 designs are registered or unregistered trademarks, design-marks, and/or
00090 service marks of Xara Group Ltd. All rights in these marks are reserved.
00091 
00092 
00093       Xara Group Ltd, Gaddesden Place, Hemel Hempstead, HP2 6EX, UK.
00094                         http://www.xara.com/
00095 
00096 =================================XARAHEADEREND============================
00097  */
00098 
00099 // Attribute type definitions
00100 
00101 #ifndef INC_ATTR
00102 #define INC_ATTR
00103 
00104 #include "doccoord.h"
00105 
00106 class Path;
00107 
00108 /********************************************************************************************
00109     These are the Attribute type definitions
00110 ********************************************************************************************/
00111 
00112 /********************************************************************************************
00113 
00114 < LineCapType
00115 
00116 Comment:
00117     enum LineCapType
00118     {
00119         LineCapButt,
00120         LineCapRound,
00121         LineCapSquare
00122     };
00123     
00124 ********************************************************************************************/
00125 
00126 enum LineCapType
00127 {
00128     LineCapButt,
00129     LineCapRound,
00130     LineCapSquare
00131 };
00132 
00133 /********************************************************************************************
00134 
00135 < JointType
00136 
00137 Comment:
00138     enum JointType
00139     {
00140         MitreJoin,
00141         RoundJoin,
00142         BevelledJoin    
00143     };
00144     
00145 ********************************************************************************************/
00146 
00147 enum JointType
00148 {
00149     MitreJoin,
00150     RoundJoin,
00151     BevelledJoin    
00152 };
00153 
00154 /********************************************************************************************
00155 
00156 < WindingType
00157 
00158 Comment:
00159     enum WindingType
00160     {
00161         NonZeroWinding,
00162         NegativeWinding,
00163         EvenOddWinding,
00164         PositiveWinding
00165     };
00166     
00167 ********************************************************************************************/
00168 
00169 enum WindingType
00170 {
00171     NonZeroWinding,
00172     NegativeWinding,
00173     EvenOddWinding,
00174     PositiveWinding
00175 };
00176    
00177 /********************************************************************************************
00178 
00179 < DrawModeType
00180 
00181 Comment:
00182     enum DrawModeType
00183     {
00184         DM_COPYPEN = 13,    // These are set to the same numbers as Windows uses, so they can
00185         DM_EORPEN = 7       // be passed straight to the CDC::SetROP2 function.
00186     };
00187     
00188 ********************************************************************************************/
00189 
00190 enum DrawModeType
00191 {
00192     DM_COPYPEN = 13,    // These are set to the same numbers as Windows uses, so they can
00193     DM_EORPEN = 7,      // be passed straight to the CDC::SetROP2 function.
00194 
00195     DM_EORDITHER = 1    // Used for drawing grad fills with EOR - we just want the brush
00196                         // to be set as if we were using DM_COPYPEN, i.e. dithered and
00197                         // not messed about with like it is when we do DM_EORPEN.
00198 };
00199 
00200 /********************************************************************************************
00201 
00202 < BlobType
00203 
00204 Comment:
00205     MonoOn
00206     enum BlobType
00207     {
00208         BT_UNSELECTED,
00209         BT_SELECTED,
00210         BT_SELECTEDLARGEST,                         the larger of the two above
00211         BT_CLICKME,                                 invisible blob used for click detection
00212         BT_MSTAGEFILLUNSELECTED,
00213         BT_MSTAGEFILLSELECTED,
00214         BT_MSTAGESELECTEDLARGEST,
00215         BT_CLIPVIEW                                 refers to ClipView's ToolObject blobs
00216     };
00217     MonoOff
00218     
00219 ********************************************************************************************/
00220 
00221 enum BlobType
00222 {
00223     BT_UNSELECTED,
00224     BT_SELECTED,
00225     BT_SELECTEDLARGEST,
00226     BT_CLICKME,
00227     BT_MSTAGEFILLUNSELECTED,
00228     BT_MSTAGEFILLSELECTED,
00229     BT_MSTAGESELECTEDLARGEST,
00230     BT_CLIPVIEW
00231 };
00232 
00233 /********************************************************************************************
00234     Dash Records.  These define Dash patterns for dotted lines.
00235 ********************************************************************************************/
00236 
00237 /********************************************************************************************
00238 
00239 >   class DashRec : public CCObject
00240 
00241     Author:     Will_Cowling (Xara Group Ltd) <camelotdev@xara.com>
00242     Created:    14/10/94
00243     Purpose:    A class defining a Dash pattern.
00244     SeeAlso:    -
00245 
00246 ********************************************************************************************/
00247 
00248 enum StockDash
00249 {
00250 // These are old dashes,
00251 // don't use these any more
00252     SD_DASH = 1,
00253     SD_DOT,
00254     SD_DASHDOT,
00255     SD_DASHDOTDOT,
00256     SD_FILLMESH,
00257 
00258 // New Dashes
00259     SD_SOLID = 0,
00260     SD_DASH1,
00261     SD_DASH2,
00262     SD_DASH3,
00263     SD_DASH4,
00264     SD_DASH5,
00265     SD_DASH6,
00266     SD_DASH7,
00267     SD_DASH8,
00268     SD_DASH9,
00269     SD_DASH10,
00270     SD_DASH11,
00271     SD_DASH12,
00272     SD_DASH13,
00273     SD_DASH14,
00274     SD_DASH15,
00275     SD_DASH16,
00276     SD_DASH17,
00277     SD_DASH18,
00278     SD_DASH19,
00279     SD_DASH20,
00280     SD_DASH_GUIDELAYER,
00281 
00282     NUM_STOCK_DASHES
00283 };
00284 
00285 typedef INT32 DashElement;
00286 
00287 class DashRec : public CCObject
00288 {
00289     CC_DECLARE_DYNCREATE(DashRec)
00290 public:
00291     DashRec();
00292     
00293     INT32 operator==(DashRec&);
00294     INT32 operator==(StockDash);
00295     DashRec& operator=(DashRec&);
00296     DashRec& operator=(StockDash);
00297 
00298 // Number of Stock Dashes available
00299     static INT32 GetNumStockDashes() { return NUM_STOCK_DASHES; }
00300     static String_256 GetStockDashName(StockDash);
00301 
00302     INT32 GetDashID() { return DashID; }
00303     BOOL ShouldScaleWithLineWidth() { return ScaleWithLineWidth; }
00304 
00305     void CheckAndFix();
00306     void CheckIfDefaultPattern();
00307 
00308 public:
00309     INT32 Elements;
00310     INT32 DashStart;
00311     DashElement* ElementData;
00312 
00313     INT32 LineWidth;
00314     BOOL ScaleWithLineWidth;
00315     INT32 DashID;
00316 };
00317 
00318 #endif // INC_ATTR

Generated on Sat Nov 10 03:44:12 2007 for Camelot by  doxygen 1.4.4