28#include <osl/diagnose.h>
46class SvxAccessibleTextIndex
49 SvxAccessibleTextIndex() :
61 void SetParagraph( sal_Int32 nPara )
65 sal_Int32 GetParagraph()
const {
return mnPara; }
76 void SetIndex( sal_Int32 nPara, sal_Int32 nIndex,
const SvxTextForwarder& rTF ) { SetParagraph(nPara); SetIndex(nIndex, rTF); }
77 sal_Int32 GetIndex()
const {
return mnIndex; }
91 void SetEEIndex( sal_Int32 nPara, sal_Int32 nEEIndex,
const SvxTextForwarder& rTF ) { SetParagraph(nPara); SetEEIndex(nEEIndex, rTF); }
92 sal_Int32 GetEEIndex()
const;
94 void SetFieldOffset( sal_Int32 nOffset, sal_Int32 nLen ) { mnFieldOffset = nOffset; mnFieldLen = nLen; }
95 sal_Int32 GetFieldOffset()
const {
return mnFieldOffset; }
96 sal_Int32 GetFieldLen()
const {
return mnFieldLen; }
97 void AreInField() { mbInField =
true; }
98 bool InField()
const {
return mbInField; }
100 void SetBulletOffset( sal_Int32 nOffset, sal_Int32 nLen ) { mnBulletOffset = nOffset; mnBulletLen = nLen; }
101 sal_Int32 GetBulletOffset()
const {
return mnBulletOffset; }
102 sal_Int32 GetBulletLen()
const {
return mnBulletLen; }
103 bool InBullet()
const {
return mbInBullet; }
106 bool IsEditableRange(
const SvxAccessibleTextIndex& rEnd )
const;
112 sal_Int32 mnFieldOffset;
113 sal_Int32 mnFieldLen;
114 sal_Int32 mnBulletOffset;
115 sal_Int32 mnBulletLen;
134 if( rStart.GetParagraph() <= rEnd.GetParagraph() ||
135 (rStart.GetParagraph() == rEnd.GetParagraph() &&
136 rStart.GetEEIndex() <= rEnd.GetEEIndex()) )
138 if( rEnd.InField() && rEnd.GetFieldOffset() )
139 return ESelection( rStart.GetParagraph(), rStart.GetEEIndex(),
140 rEnd.GetParagraph(), rEnd.GetEEIndex()+1 );
142 else if( rStart.GetParagraph() > rEnd.GetParagraph() ||
143 (rStart.GetParagraph() == rEnd.GetParagraph() &&
144 rStart.GetEEIndex() > rEnd.GetEEIndex()) )
146 if( rStart.InField() && rStart.GetFieldOffset() )
147 return ESelection( rStart.GetParagraph(), rStart.GetEEIndex()+1,
148 rEnd.GetParagraph(), rEnd.GetEEIndex() );
151 return ESelection( rStart.GetParagraph(), rStart.GetEEIndex(),
152 rEnd.GetParagraph(), rEnd.GetEEIndex() );
157 return ESelection( rIndex.GetParagraph(), rIndex.GetEEIndex(),
158 rIndex.GetParagraph(), rIndex.GetEEIndex() + 1 );
161sal_Int32 SvxAccessibleTextIndex::GetEEIndex()
const
164 "SvxAccessibleTextIndex::GetEEIndex: index value overflow");
169void SvxAccessibleTextIndex::SetEEIndex( sal_Int32 nEEIndex,
const SvxTextForwarder& rTF )
180 mnEEIndex = nEEIndex;
183 sal_Int32 nCurrField, nFieldCount = rTF.
GetFieldCount( GetParagraph() );
197 for( nCurrField=0; nCurrField < nFieldCount; ++nCurrField )
201 if( aFieldInfo.aPosition.nIndex > nEEIndex )
204 if( aFieldInfo.aPosition.nIndex == nEEIndex )
210 mnIndex += std::max(aFieldInfo.aCurrentText.getLength()-1, sal_Int32(0));
214void SvxAccessibleTextIndex::SetIndex( sal_Int32 nIndex,
const SvxTextForwarder& rTF )
228 sal_Int32 nCurrField, nFieldCount = rTF.
GetFieldCount( GetParagraph() );
231 "SvxAccessibleTextIndex::SetIndex: index value overflow");
242 sal_Int32 nBulletLen = aBulletInfo.
aText.getLength();
244 if( nIndex < nBulletLen )
247 SetBulletOffset( nIndex, nBulletLen );
252 mnEEIndex = mnEEIndex - nBulletLen;
255 for( nCurrField=0; nCurrField < nFieldCount; ++nCurrField )
260 if( aFieldInfo.aPosition.nIndex > mnEEIndex )
263 mnEEIndex -= std::max(aFieldInfo.aCurrentText.getLength()-1, sal_Int32(0));
266 if( aFieldInfo.aPosition.nIndex >= mnEEIndex )
269 SetFieldOffset( std::max(aFieldInfo.aCurrentText.getLength()-1, sal_Int32(0)) - (aFieldInfo.aPosition.nIndex - mnEEIndex),
270 aFieldInfo.aCurrentText.getLength() );
271 mnEEIndex = aFieldInfo.aPosition.nIndex ;
277bool SvxAccessibleTextIndex::IsEditableRange(
const SvxAccessibleTextIndex& rEnd )
const
279 if( GetIndex() > rEnd.GetIndex() )
280 return rEnd.IsEditableRange( *
this );
282 if( InBullet() || rEnd.InBullet() )
285 if( InField() && GetFieldOffset() )
288 if( rEnd.InField() && rEnd.GetFieldOffset() >= rEnd.GetFieldLen() - 1 )
295SvxEditSourceAdapter::SvxEditSourceAdapter() : mbEditSourceValid( false )
299SvxEditSourceAdapter::~SvxEditSourceAdapter()
303std::unique_ptr<SvxEditSource> SvxEditSourceAdapter::Clone()
const
305 if( mbEditSourceValid && mpAdaptee )
307 std::unique_ptr< SvxEditSource > pClonedAdaptee( mpAdaptee->Clone() );
311 std::unique_ptr<SvxEditSourceAdapter> pClone(
new SvxEditSourceAdapter());
312 pClone->SetEditSource( std::move(pClonedAdaptee) );
313 return std::unique_ptr< SvxEditSource >(pClone.release());
322 if( mbEditSourceValid && mpAdaptee )
328 maTextAdapter.SetForwarder(*pTextForwarder);
330 return &maTextAdapter;
339 return GetTextForwarderAdapter();
344 if( mbEditSourceValid && mpAdaptee )
345 return mpAdaptee->GetViewForwarder();
352 if( mbEditSourceValid && mpAdaptee )
356 if( pEditViewForwarder )
362 maEditViewAdapter.SetForwarder(*pEditViewForwarder, *pTextAdapter);
364 return &maEditViewAdapter;
374 return GetEditViewForwarderAdapter( bCreate );
377void SvxEditSourceAdapter::UpdateData()
379 if( mbEditSourceValid && mpAdaptee )
380 mpAdaptee->UpdateData();
385 if( mbEditSourceValid && mpAdaptee )
386 return mpAdaptee->GetBroadcaster();
388 return maDummyBroadcaster;
391void SvxEditSourceAdapter::SetEditSource( std::unique_ptr< SvxEditSource > && pAdaptee )
395 mpAdaptee = std::move(pAdaptee);
396 mbEditSourceValid =
true;
403 mbEditSourceValid =
false;
408 : mpTextForwarder(nullptr)
425 SvxAccessibleTextIndex
aIndex;
435 SvxAccessibleTextIndex aStartIndex;
436 SvxAccessibleTextIndex aEndIndex;
445 std::swap( aStartIndex, aEndIndex );
451 if( aStartIndex.InField() )
454 "SvxAccessibleTextIndex::GetText: index value overflow");
456 sStr = sStr.copy( aStartIndex.GetFieldOffset() );
458 if( aEndIndex.InField() && aEndIndex.GetFieldOffset() )
460 DBG_ASSERT(sStr.getLength() - (aEndIndex.GetFieldLen() - aEndIndex.GetFieldOffset()) >= 0,
461 "SvxAccessibleTextIndex::GetText: index value overflow");
463 sStr = sStr.copy(0, sStr.getLength() - (aEndIndex.GetFieldLen() - aEndIndex.GetFieldOffset()) );
468 if( aEndIndex.InBullet() )
471 sStr += aBulletInfo2.
aText;
473 DBG_ASSERT(sStr.getLength() - (aEndIndex.GetBulletLen() - aEndIndex.GetBulletOffset()) >= 0,
474 "SvxAccessibleTextIndex::GetText: index value overflow");
476 sStr = sStr.copy(0, sStr.getLength() - (aEndIndex.GetBulletLen() - aEndIndex.GetBulletOffset()) );
478 else if( aStartIndex.GetParagraph() != aEndIndex.GetParagraph() &&
481 OUString sBullet = aBulletInfo2.
aText;
483 DBG_ASSERT(sBullet.getLength() - (aEndIndex.GetBulletLen() - aEndIndex.GetBulletOffset()) >= 0,
484 "SvxAccessibleTextIndex::GetText: index value overflow");
486 sBullet = sBullet.copy(0, sBullet.getLength() - (aEndIndex.GetBulletLen() - aEndIndex.GetBulletOffset()) );
489 sStr = sStr.replaceAt(
GetTextLen(aStartIndex.GetParagraph()) - aStartIndex.GetIndex(), 0, sBullet );
499 SvxAccessibleTextIndex aStartIndex;
500 SvxAccessibleTextIndex aEndIndex;
551 SvxAccessibleTextIndex aStartIndex;
552 SvxAccessibleTextIndex aEndIndex;
572 SvxAccessibleTextIndex aStartIndex;
573 SvxAccessibleTextIndex aEndIndex;
586 SvxAccessibleTextIndex aStartIndex;
587 SvxAccessibleTextIndex aEndIndex;
600 SvxAccessibleTextIndex aStartIndex;
601 SvxAccessibleTextIndex aEndIndex;
614 SvxAccessibleTextIndex aStartIndex;
615 SvxAccessibleTextIndex aEndIndex;
648 SvxAccessibleTextIndex
aIndex;
650 return aIndex.GetEEIndex();
667 SvxAccessibleTextIndex
aIndex;
699 SvxAccessibleTextIndex
aIndex;
712 DBG_ASSERT(pOutDev!=
nullptr,
"SvxAccessibleTextAdapter::GetCharBounds: No ref device");
731 DBG_ASSERT(pOutDev!=
nullptr,
"SvxAccessibleTextAdapter::GetCharBounds: No ref device");
795 SvxAccessibleTextIndex
aIndex;
799 "SvxAccessibleTextIndex::SetIndex: index value overflow");
814 DBG_ASSERT(pOutDev!=
nullptr,
"SvxAccessibleTextAdapter::GetIndexAtPoint: No ref device");
821 Point aPoint = rPoint;
825 "SvxAccessibleTextIndex::SetIndex: index value overflow");
837 DBG_ASSERT(pOutDev!=
nullptr,
"SvxAccessibleTextAdapter::GetIndexAtPoint: No ref device");
849 Point aPoint = rPoint;
853 "SvxAccessibleTextIndex::SetIndex: index value overflow");
863 SvxAccessibleTextIndex
aIndex;
870 "SvxAccessibleTextIndex::SetIndex: index value overflow");
874 nEnd =
aIndex.GetBulletLen();
882 nStart +
aIndex.GetFieldLen() >= 0,
883 "SvxAccessibleTextIndex::SetIndex: index value overflow");
888 nEnd = nStart +
aIndex.GetFieldLen();
896 aIndex.SetEEIndex( nPara, nStart, *
this );
898 "SvxAccessibleTextIndex::SetIndex: index value overflow");
899 nStart =
aIndex.GetIndex();
901 aIndex.SetEEIndex( nPara, nEnd, *
this );
903 "SvxAccessibleTextIndex::SetIndex: index value overflow");
913 SvxAccessibleTextIndex
aIndex;
920 "SvxAccessibleTextIndex::SetIndex: index value overflow");
924 nEndIndex =
aIndex.GetBulletLen();
932 "SvxAccessibleTextIndex::SetIndex: index value overflow");
935 nStartIndex =
aIndex.GetIndex() -
aIndex.GetFieldOffset();
936 nEndIndex = nStartIndex +
aIndex.GetFieldLen();
944 aIndex.SetEEIndex( nPara, nStartIndex, *
this );
946 "SvxAccessibleTextIndex::SetIndex: index value overflow");
947 nStartIndex =
aIndex.GetIndex();
949 aIndex.SetEEIndex( nPara, nEndIndex, *
this );
951 "SvxAccessibleTextIndex::SetIndex: index value overflow");
952 nEndIndex =
aIndex.GetIndex();
968 SvxAccessibleTextIndex aEndIndex;
970 sal_Int32 nCurrIndex, nLastIndex;
971 for( nCurrLine=0, nCurrIndex=0, nLastIndex=0; nCurrLine<=nLine; ++nCurrLine )
973 nLastIndex = nCurrIndex;
978 aEndIndex.SetEEIndex( nPara, nCurrIndex, *
this );
981 SvxAccessibleTextIndex aStartIndex;
982 aStartIndex.SetEEIndex( nPara, nLastIndex, *
this );
984 return aEndIndex.GetIndex() - aStartIndex.GetIndex();
987 return aEndIndex.GetIndex();
1004 SvxAccessibleTextIndex aStartIndex;
1005 SvxAccessibleTextIndex aEndIndex;
1017 SvxAccessibleTextIndex aStartIndex;
1018 SvxAccessibleTextIndex aEndIndex;
1072 SvxAccessibleTextIndex aStartIndex;
1073 SvxAccessibleTextIndex aEndIndex;
1082 std::swap( aStartIndex, aEndIndex );
1085 return aStartIndex.IsEditableRange( aEndIndex );
1090 OSL_FAIL(
"not implemented" );
1096 OSL_FAIL(
"not implemented" );
1101 OSL_FAIL(
"not implemented" );
1106 OSL_FAIL(
"not implemented" );
1110 : mpViewForwarder(nullptr)
1111 , mpTextForwarder(nullptr)
1152 SvxAccessibleTextIndex aStartIndex;
1153 SvxAccessibleTextIndex aEndIndex;
1159 aEndIndex.GetIndex() >= 0,
1160 "SvxAccessibleTextEditViewAdapter::GetSelection: index value overflow");
1162 rSel =
ESelection( aStartIndex.GetParagraph(), aStartIndex.GetIndex(),
1163 aEndIndex.GetParagraph(), aEndIndex.GetIndex() );
1172 SvxAccessibleTextIndex aStartIndex;
1173 SvxAccessibleTextIndex aEndIndex;
sal_Int32 GetIndexAtPoint(const Point &rPoint)
void GetCharacterBounds(sal_Int32 nIndex, tools::Rectangle &rRect)
static SvxFont CreateSvxFontFromItemSet(const SfxItemSet &rItemSet)
void Move(tools::Long nHorzMove, tools::Long nVertMove)
virtual void QuickSetAttribs(const SfxItemSet &rSet, const ESelection &rSel) override
virtual bool QuickFormatDoc(bool bFull=false) override
Updates the formatting.
virtual OUString CalcFieldValue(const SvxFieldItem &rField, sal_Int32 nPara, sal_Int32 nPos, std::optional< Color > &rpTxtColor, std::optional< Color > &rpFldColor, std::optional< FontLineStyle > &rpFldLineStyle) override
virtual LanguageType GetLanguage(sal_Int32, sal_Int32) const override
Query language of character at given position on the underlying edit engine.
virtual SfxItemSet GetParaAttribs(sal_Int32 nPara) const override
virtual bool Delete(const ESelection &) override
Delete given text range and reformat text.
virtual sal_Int32 GetTextLen(sal_Int32 nParagraph) const override
virtual void RemoveAttribs(const ESelection &rSelection) override
virtual void GetPortions(sal_Int32 nPara, std::vector< sal_Int32 > &rList) const override
virtual sal_Int32 GetFieldCount(sal_Int32 nPara) const override
Query number of fields in the underlying edit engine.
virtual OUString GetText(const ESelection &rSel) const override
virtual EBulletInfo GetBulletInfo(sal_Int32 nPara) const override
Query information regarding bullets for given paragraph on the underlying edit engine.
virtual MapMode GetMapMode() const override
Query the map mode of the underlying EditEngine/Outliner.
virtual SfxItemSet GetAttribs(const ESelection &rSel, EditEngineAttribs nOnlyHardAttrib=EditEngineAttribs::All) const override
virtual void GetLineBoundaries(sal_Int32 &rStart, sal_Int32 &rEnd, sal_Int32 nParagraph, sal_Int32 nLine) const override
Query bounds of line in paragraph.
virtual void SetParaAttribs(sal_Int32 nPara, const SfxItemSet &rSet) override
bool HaveTextBullet(sal_Int32 nPara) const
virtual void QuickInsertLineBreak(const ESelection &rSel) override
bool IsEditable(const ESelection &rSelection) const
Query whether all text in given selection is editable.
sal_Int32 CalcEditEngineIndex(sal_Int32 nPara, sal_Int32 nLogicalIndex)
virtual bool GetWordIndices(sal_Int32 nPara, sal_Int32 nIndex, sal_Int32 &nStart, sal_Int32 &nEnd) const override
Get the start and the end index of the word at the given index.
virtual void SetStyleSheet(sal_Int32 nPara, const OUString &rStyleName) override
virtual bool GetIndexAtPoint(const Point &, sal_Int32 &nPara, sal_Int32 &nIndex) const override
Query paragraph and character index of the character at the given point.
virtual bool InsertText(const OUString &, const ESelection &) override
Insert/Replace given text in given range and reformat text.
SvxTextForwarder * mpTextForwarder
virtual bool GetAttributeRun(sal_Int32 &nStartIndex, sal_Int32 &nEndIndex, sal_Int32 nPara, sal_Int32 nIndex, bool bInCell=false) const override
Query range of similar attributes.
virtual bool IsValid() const override
Query state of forwarder.
virtual void FieldClicked(const SvxFieldItem &rField) override
virtual SfxItemState GetItemState(const ESelection &rSel, sal_uInt16 nWhich) const override
virtual void AppendParagraph() override
virtual bool SetDepth(sal_Int32 nPara, sal_Int16 nNewDepth) override
Set the outline depth of given paragraph.
virtual EFieldInfo GetFieldInfo(sal_Int32 nPara, sal_uInt16 nField) const override
Query information for given field number in the underlying edit engine.
virtual sal_Int32 GetLineCount(sal_Int32 nPara) const override
Query number of lines in the formatted paragraph.
virtual tools::Rectangle GetCharBounds(sal_Int32 nPara, sal_Int32 nIndex) const override
Query the bounding rectangle of the given character.
virtual sal_Int32 AppendTextPortion(sal_Int32 nPara, const OUString &rText, const SfxItemSet &rSet) override
virtual sal_Int32 GetLineNumberAtIndex(sal_Int32 nPara, sal_Int32 nIndex) const override
Query the line number for an index in the paragraphs text.
virtual SfxItemPool * GetPool() const override
virtual sal_Int16 GetDepth(sal_Int32 nPara) const override
Get the outline depth of given paragraph.
virtual void CopyText(const SvxTextForwarder &rSource) override
virtual tools::Rectangle GetParaBounds(sal_Int32 nPara) const override
Query the bounding rectangle of the given paragraph.
virtual OutputDevice * GetRefDevice() const override
Query the reference output device of the underlying EditEngine/Outliner.
virtual OUString GetStyleSheet(sal_Int32 nPara) const override
virtual sal_Int32 GetParagraphCount() const override
SvxAccessibleTextAdapter()
virtual const SfxItemSet * GetEmptyItemSetPtr() override
virtual ~SvxAccessibleTextAdapter() override
bool HaveImageBullet(sal_Int32 nPara) const
void SetForwarder(SvxTextForwarder &)
virtual sal_Int32 GetLineLen(sal_Int32 nPara, sal_Int32 nLine) const override
Query line length.
virtual void QuickInsertText(const OUString &rText, const ESelection &rSel) override
virtual void QuickInsertField(const SvxFieldItem &rFld, const ESelection &rSel) override
virtual Point PixelToLogic(const Point &rPoint, const MapMode &rMapMode) const override
Convert from screen to logical, EditEngine-relative coordinates.
void SetForwarder(SvxEditViewForwarder &, SvxAccessibleTextAdapter &)
SvxEditViewForwarder * mpViewForwarder
virtual ~SvxAccessibleTextEditViewAdapter() override
virtual bool IsValid() const override
Query state of forwarder.
virtual bool Cut() override
Cut current selection to clipboard.
virtual Point LogicToPixel(const Point &rPoint, const MapMode &rMapMode) const override
Convert from logical, EditEngine-relative coordinates to screen coordinates.
virtual bool Paste() override
Paste clipboard into current selection.
virtual bool SetSelection(const ESelection &rSelection) override
Set selection in view.
SvxAccessibleTextAdapter * mpTextForwarder
SvxAccessibleTextEditViewAdapter()
virtual bool GetSelection(ESelection &rSelection) const override
Query current selection.
virtual bool Copy() override
Copy current selection to clipboard.
Encapsulates EditView and OutlinerView for the purpose of unified EditEngine/Outliner access.
virtual bool Copy()=0
Copy current selection to clipboard.
virtual bool SetSelection(const ESelection &rSelection)=0
Set selection in view.
virtual bool Paste()=0
Paste clipboard into current selection.
virtual bool GetSelection(ESelection &rSelection) const =0
Query current selection.
virtual bool Cut()=0
Cut current selection to clipboard.
This item stores a field (SvxFieldData).
Contains an EditEngine or an Outliner and unifies access to them.
virtual bool IsValid() const =0
Query state of forwarder.
virtual void QuickInsertText(const OUString &rText, const ESelection &rSel)=0
virtual MapMode GetMapMode() const =0
Query the map mode of the underlying EditEngine/Outliner.
virtual void QuickInsertLineBreak(const ESelection &rSel)=0
virtual void SetStyleSheet(sal_Int32 nPara, const OUString &rStyleName)=0
virtual void QuickSetAttribs(const SfxItemSet &rSet, const ESelection &rSel)=0
virtual bool GetAttributeRun(sal_Int32 &nStartIndex, sal_Int32 &nEndIndex, sal_Int32 nPara, sal_Int32 nIndex, bool bInCell=false) const =0
Query range of similar attributes.
virtual OutputDevice * GetRefDevice() const =0
Query the reference output device of the underlying EditEngine/Outliner.
virtual LanguageType GetLanguage(sal_Int32 nPara, sal_Int32 nIndex) const =0
Query language of character at given position on the underlying edit engine.
virtual OUString GetStyleSheet(sal_Int32 nPara) const =0
virtual bool SetDepth(sal_Int32 nPara, sal_Int16 nNewDepth)=0
Set the outline depth of given paragraph.
virtual SfxItemSet GetAttribs(const ESelection &rSel, EditEngineAttribs nOnlyHardAttrib=EditEngineAttribs::All) const =0
virtual void GetPortions(sal_Int32 nPara, std::vector< sal_Int32 > &rList) const =0
virtual sal_Int32 GetFieldCount(sal_Int32 nPara) const =0
Query number of fields in the underlying edit engine.
virtual bool QuickFormatDoc(bool bFull=false)=0
Updates the formatting.
virtual void FieldClicked(const SvxFieldItem &rField)=0
virtual sal_Int16 GetDepth(sal_Int32 nPara) const =0
Get the outline depth of given paragraph.
virtual bool Delete(const ESelection &rSelection)=0
Delete given text range and reformat text.
virtual SfxItemSet GetParaAttribs(sal_Int32 nPara) const =0
virtual EBulletInfo GetBulletInfo(sal_Int32 nPara) const =0
Query information regarding bullets for given paragraph on the underlying edit engine.
virtual EFieldInfo GetFieldInfo(sal_Int32 nPara, sal_uInt16 nField) const =0
Query information for given field number in the underlying edit engine.
virtual SfxItemPool * GetPool() const =0
virtual OUString CalcFieldValue(const SvxFieldItem &rField, sal_Int32 nPara, sal_Int32 nPos, std::optional< Color > &rpTxtColor, std::optional< Color > &rpFldColor, std::optional< FontLineStyle > &rpFldLineStyle)=0
virtual tools::Rectangle GetParaBounds(sal_Int32 nPara) const =0
Query the bounding rectangle of the given paragraph.
virtual tools::Rectangle GetCharBounds(sal_Int32 nPara, sal_Int32 nIndex) const =0
Query the bounding rectangle of the given character.
virtual sal_Int32 GetTextLen(sal_Int32 nParagraph) const =0
virtual sal_Int32 GetLineCount(sal_Int32 nPara) const =0
Query number of lines in the formatted paragraph.
virtual OUString GetText(const ESelection &rSel) const =0
virtual void SetParaAttribs(sal_Int32 nPara, const SfxItemSet &rSet)=0
virtual bool GetIndexAtPoint(const Point &rPoint, sal_Int32 &rPara, sal_Int32 &rIndex) const =0
Query paragraph and character index of the character at the given point.
virtual void GetLineBoundaries(sal_Int32 &rStart, sal_Int32 &rEnd, sal_Int32 nParagraph, sal_Int32 nLine) const =0
Query bounds of line in paragraph.
virtual sal_Int32 GetParagraphCount() const =0
virtual bool GetWordIndices(sal_Int32 nPara, sal_Int32 nIndex, sal_Int32 &rStart, sal_Int32 &rEnd) const =0
Get the start and the end index of the word at the given index.
virtual sal_Int32 GetLineLen(sal_Int32 nPara, sal_Int32 nLine) const =0
Query line length.
virtual sal_Int32 GetLineNumberAtIndex(sal_Int32 nPara, sal_Int32 nIndex) const =0
Query the line number for an index in the paragraphs text.
virtual void QuickInsertField(const SvxFieldItem &rFld, const ESelection &rSel)=0
virtual bool InsertText(const OUString &rText, const ESelection &rSel)=0
Insert/Replace given text in given range and reformat text.
virtual SfxItemState GetItemState(const ESelection &rSel, sal_uInt16 nWhich) const =0
Encapsulates the document view for the purpose of unified EditEngine/Outliner access.
virtual Point LogicToPixel(const Point &rPoint, const MapMode &rMapMode) const =0
Convert from logical, EditEngine-relative coordinates to screen coordinates.
virtual bool IsValid() const =0
Query state of forwarder.
virtual Point PixelToLogic(const Point &rPoint, const MapMode &rMapMode) const =0
Convert from screen to logical, EditEngine-relative coordinates.
#define DBG_ASSERT(sCon, aError)
#define EE_PARA_NOT_FOUND
std::deque< AttacherIndex_Impl > aIndex
EditEngineAttribs
values for: SfxItemSet GetAttribs( const ESelection& rSel, EditEngineAttribs nOnlyHardAttrib = EditEn...
static ESelection MakeEESelection(const SvxAccessibleTextIndex &rStart, const SvxAccessibleTextIndex &rEnd)