Caret.h
Go to the documentation of this file.
1 /*--------------------------------------------------------------------------------------+
2 |
3 | Supplied under applicable software license agreement.
4 |
5 | Copyright (c) 2018 Bentley Systems, Incorporated. All rights reserved.
6 |
7 +---------------------------------------------------------------------------------------*/
8 #pragma once
9 
10 #include "TextAPICommon.h"
11 
13 
16 
17 
18 //=======================================================================================
28 //
29 // @remark Required library : DgnPlatform<ApiNumber>.lib i.e. DgnPlatform5.lib
30 // @bsiclass Bentley Systems
31 //=======================================================================================
33  {
34 private:
35  virtual void MakeClassAbstract() = 0;
36 public:
37 
39  public: DGNPLATFORM_EXPORT CaretPtr Clone () const;
40 
44  public: DGNPLATFORM_EXPORT bool IsAt (CaretCR) const;
45 
48  public: DGNPLATFORM_EXPORT bool IsBefore (CaretCR) const;
49 
52  public: DGNPLATFORM_EXPORT bool IsBeforeOrAt (CaretCR) const;
53 
56  public: DGNPLATFORM_EXPORT bool IsAfter (CaretCR) const;
57 
60  public: DGNPLATFORM_EXPORT bool IsAfterOrAt (CaretCR) const;
61 
64  public: DGNPLATFORM_EXPORT bool IsAtBeginning () const;
65 
69  public: DGNPLATFORM_EXPORT bool IsAtEnd () const;
70 
72  public: DGNPLATFORM_EXPORT ParagraphCP GetCurrentParagraphCP () const;
73 
75  public: DGNPLATFORM_EXPORT RunCP GetCurrentRunCP () const;
76 
78  public: DGNPLATFORM_EXPORT bool IsInField() const;
79 
81  public: DGNPLATFORM_EXPORT TextFieldPtr GetCurrentField() const;
82 
84  public: DGNPLATFORM_EXPORT WChar GetPreviousCharacter () const;
85 
87  public: DGNPLATFORM_EXPORT WChar GetNextCharacter () const;
88 
91  public: DGNPLATFORM_EXPORT BentleyStatus MoveToNextParagraph ();
92 
95  public: DGNPLATFORM_EXPORT BentleyStatus MoveToNextRun ();
96 
99  public: DGNPLATFORM_EXPORT BentleyStatus MoveToNextField ();
100 
103  public: DGNPLATFORM_EXPORT BentleyStatus MoveToNextRunInParagraph ();
104 
107  public: DGNPLATFORM_EXPORT BentleyStatus MoveToNextCharacter ();
108 
111  public: DGNPLATFORM_EXPORT BentleyStatus MoveToPreviousParagraph ();
112 
115  public: DGNPLATFORM_EXPORT BentleyStatus MoveToPreviousRun ();
116 
119  public: DGNPLATFORM_EXPORT BentleyStatus MoveToPreviousRunInParagraph ();
120 
123  public: DGNPLATFORM_EXPORT BentleyStatus MoveToPreviousCharacter ();
124 
126  public: DGNPLATFORM_EXPORT ParagraphIterator CreateParagraphBegin () const;
127 
129  public: DGNPLATFORM_EXPORT ParagraphIterator CreateParagraphEnd () const;
130 
132  public: DGNPLATFORM_EXPORT RunIterator CreateRunBegin () const;
133 
135  public: DGNPLATFORM_EXPORT RunIterator CreateRunEnd () const;
136 
137  }; // Caret
138 
140 
142 
Represents an insertable location within a TextBlock.
Definition: Caret.h:32
An STL iterator-like wrapper around Caret, that allows you to easily iterate paragraphs.
Definition: TextBlockIterators.h:23
#define END_BENTLEY_DGNPLATFORM_NAMESPACE
Definition: DgnPlatformBaseType.r.h:69
wchar_t WChar
Definition: Bentley.h:223
#define DGNPLATFORM_EXPORT
Definition: DgnPlatform/ExportMacros.h:58
struct DgnPlatform::Caret const & CaretCR
Definition: DgnPlatform.h:172
An STL iterator-like wrapper around Caret, that allows you to iterate runs.
Definition: TextBlockIterators.h:90
#define CLRPUBLIC
Definition: DgnPlatform/ExportMacros.h:12
BentleyStatus
Definition: Bentley.h:208
#define BEGIN_BENTLEY_DGNPLATFORM_NAMESPACE
Definition: DgnPlatformBaseType.r.h:68
Concrete class that can be used to implement the reference-counting pattern.
Definition: RefCounted.h:109

Copyright © 2017 Bentley Systems, Incorporated. All rights reserved.