InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
TextVariableInfo.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: rkamicar
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 // Note:
24 //
25 //========================================================================================
26 
27 #ifndef _TextVariableInfo_
28 #define _TextVariableInfo_
29 
33 {
34 private:
36  void Init();
37 
38  friend class TextVariableImpl;
39 
42  WideString name;
46  WideString contents;
49  ClassID baseTypeID;
52  ClassID formatterID;
55  UID fuid;
58  int32 flags;
61  WideString textBefore;
64  WideString textAfter;
65 
66  void ReadWrite(IPMStream *s, ImplementationID prop);
67 
68 public:
71 
73  bool16 operator== (const AddVariableInfo &other) const;
74  bool16 operator!= (const AddVariableInfo &other) const;
75 
79  {
80  kSection = 0,
81  kDocument
82  };
83 
86  enum UseStyles
87  {
88  kFirstInPage = 0,
89  kLastInPage,
90  };
91 
92  const WideString& GetName() const {return name;}
95  void SetName(const WideString &s) {name = s;}
99  const WideString& GetContents() const {return contents;}
102  void SetContents(const WideString &s) {contents = s;}
105  const ClassID GetBaseTypeID() const {return baseTypeID;}
108  void SetBaseTypeID(ClassID id) {baseTypeID = id;}
111  const ClassID GetFormatterID() const {return formatterID;}
114  void SetFormatterID(ClassID id) {formatterID = id;}
117  const UID GetUID() const {return fuid;}
120  void SetUID(UID uid) {fuid = uid;}
123  int32 GetFlags() const {return flags;}
126  void SetFlags(int32 b) {flags = b;}
129  const WideString& GetTextBefore() const {return textBefore;}
132  void SetTextBefore(const WideString &s) {textBefore = s;}
135  const WideString& GetTextAfter() const {return textAfter;}
138  void SetTextAfter(const WideString &s) {textAfter = s;}
141  ScopeStyles GetScope() const;
147  UseStyles GetUse() const;
151  /* Get Delete End Punctuation
152  */
153  bool16 GetDeleteEndPunctuation() const;
154  /* Set Delete End Punctuation
155  */
156  void SetDeleteEndPunctuation(bool16 b);
159  bool16 GetIncludeExtension() const;
162  void SetIncludePath(bool16 b);
165  bool16 GetIncludePath() const;
168  void SetIncludeExtension(bool16 b);
171  bool16 GetEmperorDate() const;
174  void SetEmperorDate(bool16 b);
175 
176  typedef object_type data_type;
177 };
178 
179 #endif // _TextVariableInfo_
180