InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ITextMiscellanySuite.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Michael Martz
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 _ITextMiscellanySuite_
28 #define _ITextMiscellanySuite_
29 
30 #include "IPMUnknown.h"
31 #include "TextEditorModelID.h"
32 #include "CTextEnum.h"
33 #include "BravoForwardDecl.h" // for kDontKnowScript
34 
35 class WideString;
36 class IPMFont;
37 class GraphicsData;
38 class IControlView;
39 class IActiveContext;
40 
45  {
46  //____________________________________________________________________________________________
47  // Data Types
48  //____________________________________________________________________________________________
49  public:
50  enum { kDefaultIID = IID_ITEXTMISCELLANYSUITE };
51 
52  //____________________________________________________________________________________________
53  // Member functions
54  //____________________________________________________________________________________________
55  public:
56  //________________________________________________________________________________________
57  // DESCR: Should the "Fill with Placeholder text" function be enabled for the
58  // selection.
59  //
60  // RETURNS: kTrue / kFalse
61  //________________________________________________________________________________________
62  virtual bool16 CanFillWithPlaceHolderText (void) const = 0;
63 
64  //________________________________________________________________________________________
65  // DESCR: Process commands in a sequence which fill with placeholder text those
66  // items in the selection.
67  //
68  // RETURNS: Error code.
69  //________________________________________________________________________________________
70  virtual ErrorCode FillWithPlaceHolderText (int32 script = kDontKnowScript) = 0;
71 
72 
73 
78  virtual ErrorCode GetFirstSelectedWord(PMString& word) = 0;
79 
83  virtual ErrorCode GetSelectedText(WideString &text) = 0;
84 
94  virtual ErrorCode GetGlyphsFromSelection(WideString& theChars, K2Vector<Text::GlyphID>& glyphList, IPMFont **selectedFont = nil) = 0;
95 
96  // Determine the typing range based on the selection and special character, and set RangeData on the global workspace
97  virtual ErrorCode SetWorkSpaceTypingRangeData(int32 specialCharacter, PMIID interfaceID) = 0;
98 
102  virtual ErrorCode IsSelectionCompletelyOverset(bool16 &result) = 0;
103 
107  virtual bool16 CanDrawSelectedFrameEdges() = 0;
108 
112  virtual void DrawSelectedFrameEdges(GraphicsData *gd) = 0;
113 
117  virtual void GetFrameThreadsBBox(GraphicsData *gd, PMRect& invalRect) = 0;
118 
126  typedef enum { kNextFrame, kPreviousFrame, kFirstFrame, kLastFrame } WhichOtherFrame;
127 
137  virtual bool16 CanSelectAnotherFrame(WhichOtherFrame which) = 0;
138 
144  virtual ErrorCode SelectAnotherFrame(WhichOtherFrame which, IActiveContext* ac) = 0;
145 
149  virtual bool16 CanOffscreenWithShape(IPMUnknown *pShape) = 0;
150 
155  virtual ErrorCode IsSelectionInDeletedText(bool16 &result) = 0;
156 
160  virtual bool16 IsSafeSelectionForFindFontDialog() const = 0;
161 
167  virtual bool16 WantCheckOutOrAlertCant() = 0;
168 
173  {
180  };
181 
189  virtual bool16 IsHiddenTextInSelection(HintForInsertionPoint hint = kDontLook) = 0;
190  };
191 
192 #endif // _ITextMiscellanySuite_