InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IGraphicAttributeSuite.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: SusanCL
6 //
7 // $Author$
8 //
9 // $DateTime$
10 //
11 // $Revision$
12 //
13 // $Change$
14 //
15 // Copyright 1997-2010 Adobe Systems Incorporated. All rights reserved.
16 //
17 // NOTICE: Adobe permits you to use, modify, and distribute this file in accordance
18 // with the terms of the Adobe license agreement accompanying it. If you have received
19 // this file from a source other than Adobe, then your use, modification, or
20 // distribution of it requires the prior written permission of Adobe.
21 //
22 //========================================================================================
23 
24 #ifndef _IGraphicAttributeSuite_
25 #define _IGraphicAttributeSuite_
26 //========================================================================================
27 //________________________________________________________________________________________
28 // INCLUDES
29 //________________________________________________________________________________________
30  #include "IPMUnknown.h"
31  #include "GraphicStylesID.h"
32  #include "ShuksanID.h"
33  #include "K2Vector.h"
34 
35  #include "IGraphicAttrMessage.h"
36 //========================================================================================
37 //________________________________________________________________________________________
38 // CLASS DECLARATIONS
39 //________________________________________________________________________________________
40 class ICommand;
43 
62  {
63  //____________________________________________________________________________________
64  // Data Types
65  //____________________________________________________________________________________
66  public:
67  enum { kDefaultIID = IID_IGRAPHICATTRIBUTESUITE };
68 
69  //____________________________________________________________________________________
70  // Attribute Utilities
71  //____________________________________________________________________________________
72  public:
75  virtual uint16 GetAttributeCount (ClassID attrClassID) = 0;
76 
79  virtual int16 GetAttributeValueCount (ClassID attrClassID, uint32 whichAttribute) = 0;
80 
88  virtual const IPMUnknown* QueryAttribute (uint32 whichAttribute, ClassID attrClassID, const PMIID& interfaceID = IID_IUNKNOWN) = 0;
89 
97  virtual IPMUnknown* CreateAttributeCopy (uint32 whichAttribute, ClassID attrClassID, const PMIID& = IID_IUNKNOWN) = 0;
98 
104  virtual ErrorCode AddAttribute (const IPMUnknown* iNewAttribute) = 0;
105 
112  virtual ErrorCode CopyIntoAttribute (uint32 whichAttribute, IPMUnknown* iNewAttribute) = 0;
113 
118  virtual ErrorCode RemoveAttribute (ClassID attrClassID) = 0;
119 
125  virtual ErrorCode RemoveAllAttributes (ClassID* pAttrClassList, uint16 count) = 0;
126 
132  virtual ErrorCode AddMultAttributes (IGraphicStyleAttributeBossList* iAttrList) = 0;
133 
138 
142  virtual ErrorCode SwapStrokeAndFill (void) = 0;
143  //____________________________________________________________________________________
144  // Render Object Utilities
145  //____________________________________________________________________________________
146  public:
147 
148  // The following two methods update data in the graphic definition
149 
155  virtual ErrorCode ChangeStrokeRenderObject (ClassID renderingClass, UID renderingUID) = 0;
156 
162  virtual ErrorCode ChangeFillRenderObject (ClassID renderingClass, UID renderingUID) = 0;
163 
168  virtual UID GetFillRenderObjectUID (ClassID) = 0;
169 
174  virtual UID GetStrokeRenderObjectUID (ClassID) = 0;
175 
180  virtual bool16 IsFillRenderObjectIndeterminant (ClassID) = 0;
181 
186  virtual bool16 IsStrokeRenderObjectIndeterminant (ClassID) = 0;
187 
188  //____________________________________________________________________________________
189  // Other Utilities
190  //____________________________________________________________________________________
191  public:
199  virtual ErrorCode ApplyRenderUIDToSelection (ClassID renderingClass, UID renderingUID, ClassID renderingAttrClass) = 0;
200 
204  virtual ClassID GetCurrentRenderObjectClass (void) = 0;
205 
209  virtual ClassID GetFillClass (void) = 0;
210 
214  virtual ClassID GetStrokeClass (void) = 0;
215 
220  virtual bool16 IsAttributeEnabled (ClassID attributeClass) = 0;
221 
226  virtual bool16 IsLineTypeEnabled (ClassID attributeClass) = 0;
227 
228  //____________________________________________________________________________________
229  // Directly update graphic states rendering objects
230  // CSB should not use.
231  //____________________________________________________________________________________
232  public:
233 
237  virtual void UpdateRenderObjectsToProxyState (void) = 0;
238 
239  //____________________________________________________________________________________
240  // Get current disabled attribute class IDs and rendering types in the list.
241  //____________________________________________________________________________________
242 
246  virtual void GetDisabledAttributesList (K2Vector<ClassID>* pDisabledAttrClassList) = 0;
247 
252  virtual void GetDisabledRenderingTypesList (K2Vector<ClassID>* pDisabledFillRenderClassList, K2Vector<ClassID>* pDisabledStrokeRenderClassList) = 0;
253  };
254 
255 #endif // _IGraphicAttributeSuite_