LibreOffice Module sw (master)  1
accpara.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  *
9  * This file incorporates work covered by the following license notice:
10  *
11  * Licensed to the Apache Software Foundation (ASF) under one or more
12  * contributor license agreements. See the NOTICE file distributed
13  * with this work for additional information regarding copyright
14  * ownership. The ASF licenses this file to you under the Apache
15  * License, Version 2.0 (the "License"); you may not use this file
16  * except in compliance with the License. You may obtain a copy of
17  * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18  */
19 #ifndef INCLUDED_SW_SOURCE_CORE_ACCESS_ACCPARA_HXX
20 #define INCLUDED_SW_SOURCE_CORE_ACCESS_ACCPARA_HXX
21 
22 #include "acccontext.hxx"
23 #include <com/sun/star/accessibility/AccessibleScrollType.hpp>
24 #include <com/sun/star/accessibility/XAccessibleEditableText.hpp>
25 #include <com/sun/star/accessibility/XAccessibleSelection.hpp>
26 #include <com/sun/star/accessibility/XAccessibleHypertext.hpp>
27 #include <com/sun/star/accessibility/XAccessibleTextMarkup.hpp>
28 #include <com/sun/star/accessibility/XAccessibleMultiLineText.hpp>
29 #include <com/sun/star/accessibility/XAccessibleTextSelection.hpp>
30 #include <com/sun/star/accessibility/XAccessibleExtendedAttributes.hpp>
31 #include <com/sun/star/accessibility/XAccessibleTextAttributes.hpp>
32 #include "accselectionhelper.hxx"
33 #include <unordered_map>
34 #include <svl/lstner.hxx>
35 
36 class SwTextFrame;
37 class SwPaM;
40 class SwRangeRedline;
41 class SwXTextPortion;
42 class SwParaChangeTrackingInfo; //#i108125#
43 
44 namespace com { namespace sun { namespace star {
45  namespace i18n { struct Boundary; }
46  namespace accessibility { class XAccessibleHyperlink; }
47  namespace style { struct TabStop; }
48 } } }
49 
50 typedef std::unordered_map< OUString,
51  css::beans::PropertyValue > tAccParaPropValMap;
52 
54  public SfxListener,
55  public SwAccessibleContext,
56  public css::accessibility::XAccessibleEditableText,
57  public css::accessibility::XAccessibleSelection,
58  public css::accessibility::XAccessibleHypertext,
59  public css::accessibility::XAccessibleTextMarkup,
60  public css::accessibility::XAccessibleMultiLineText,
61  public css::accessibility::XAccessibleTextAttributes,
62  public css::accessibility::XAccessibleTextSelection,
63  public css::accessibility::XAccessibleExtendedAttributes
64 {
65  friend class SwAccessibleHyperlink;
66 
67  OUString m_sDesc; // protected by base classes mutex
68 
69  // data for this paragraph's text portions; this contains the
70  // mapping from the core 'model string' to the accessible text
71  // string.
72  // pPortionData may be NULL; it should only be accessed through the
73  // Get/Clear/Has/UpdatePortionData() methods
74  std::unique_ptr<SwAccessiblePortionData> m_pPortionData;
75  std::unique_ptr<SwAccessibleHyperTextData> m_pHyperTextData;
76 
77  sal_Int32 m_nOldCaretPos; // The 'old' caret pos. It's only valid as long
78  // as the cursor is inside this object (protected by
79  // mutex)
80 
81  bool m_bIsHeading; // protected by base classes mutex
82  sal_Int32 m_nHeadingLevel;
83 
84  // implementation for XAccessibleSelection
86 
87  std::unique_ptr<SwParaChangeTrackingInfo> mpParaChangeTrackInfo; // #i108125#
88 
89  // XAccessibleComponent
91 
93  OUString const & GetString();
94 
95  static OUString GetDescription();
96 
97  // get the current care position
98  sal_Int32 GetCaretPos();
99 
100  // determine the current selection. Fill the values with
101  // -1 if there is no selection in the this paragraph
102  // @param pSelection (optional) check only Nth selection in ring
103  bool GetSelectionAtIndex(sal_Int32 * pSelection, sal_Int32& nStart, sal_Int32& nEnd);
104  bool GetSelection(sal_Int32& nStart, sal_Int32& nEnd) {
105  return GetSelectionAtIndex(nullptr, nStart, nEnd);
106  }
107 
108  // helper for GetSelection and getCaretPosition
109  // #i27301# - add parameter <_bForSelection>, which indicates,
110  // if the cursor is retrieved for selection or for caret position.
111  SwPaM* GetCursor( const bool _bForSelection );
112 
113  // for cut/copy/paste: execute a particular slot at the view shell
114  void ExecuteAtViewShell( sal_uInt16 nSlot );
115 
116  // helper method for get/setAttributes
117  // (for the special case of (nEndIndex==-1) a single character will
118  // be selected)
119  SwXTextPortion* CreateUnoPortion( sal_Int32 nStart, sal_Int32 nEnd );
120 
121  // methods for checking the parameter range:
122 
123  // does nPos point to a char?
124  static bool IsValidChar(sal_Int32 nPos, sal_Int32 nLength);
125 
126  // does nPos point to a position? (may be behind the last character)
127  static bool IsValidPosition(sal_Int32 nPos, sal_Int32 nLength);
128 
129  // is nBegin...nEnd a valid range? (nEnd points past the last character)
130  static bool IsValidRange(sal_Int32 nBegin, sal_Int32 nEnd, sal_Int32 nLength);
131 
132  // Ensure ordered range (i.e. nBegin is smaller then nEnd)
133  static void OrderRange(sal_Int32& nBegin, sal_Int32& nEnd)
134  {
135  if( nBegin > nEnd )
136  {
137  sal_Int32 nTmp = nBegin; nBegin = nEnd; nEnd = nTmp;
138  }
139  }
140 
142  OUString GetFieldTypeNameAtIndex(sal_Int32 nIndex);
143 
144  // #i63870#
146  const css::uno::Sequence< OUString >& aRequestedAttributes,
147  tAccParaPropValMap& rDefAttrSeq,
148  const bool bOnlyCharAttrs = false );
150  const sal_Int32 nIndex,
151  const css::uno::Sequence< OUString >& aRequestedAttributes,
152  tAccParaPropValMap& rRunAttrSeq );
153 
155  const css::uno::Sequence< OUString >& aRequestedAttributes,
156  tAccParaPropValMap& rSupplementalAttrSeq );
157 
158  void _correctValues(
159  const sal_Int32 nIndex,
160  std::vector< css::beans::PropertyValue >& rValues );
161 
162 public:
163  bool IsHeading() const;
164 
165 protected:
166 
167  // Set states for getAccessibleStateSet.
168  // This derived class additionally sets MULTILINE(1), MULTISELECTABLE(+),
169  // FOCUSABLE(+) and FOCUSED(+)
170  virtual void GetStates( ::utl::AccessibleStateSetHelper& rStateSet ) override;
171 
172  virtual void InvalidateContent_( bool bVisibleDataFired ) override;
173 
174  virtual void InvalidateCursorPos_() override;
175  virtual void InvalidateFocus_() override;
176 
177  virtual ~SwAccessibleParagraph() override;
178 
179  // handling of data for the text portions
180 
181  // force update of new portion data
183  void UpdatePortionData();
184 
185  // remove the current portion data
186  void ClearPortionData();
187 
188  // get portion data; update if necessary
191  {
192  if( m_pPortionData == nullptr )
194  return *m_pPortionData;
195  }
196 
197  //helpers for word boundaries
198 
199  bool GetCharBoundary( css::i18n::Boundary& rBound,
200  sal_Int32 nPos );
201  bool GetWordBoundary( css::i18n::Boundary& rBound,
202  const OUString& rText,
203  sal_Int32 nPos );
204  bool GetSentenceBoundary( css::i18n::Boundary& rBound,
205  const OUString& rText,
206  sal_Int32 nPos );
207  bool GetLineBoundary( css::i18n::Boundary& rBound,
208  const OUString& rText,
209  sal_Int32 nPos );
210  static bool GetParagraphBoundary( css::i18n::Boundary& rBound,
211  const OUString& rText );
212  bool GetAttributeBoundary( css::i18n::Boundary& rBound,
213  sal_Int32 nPos );
214  bool GetGlyphBoundary( css::i18n::Boundary& rBound,
215  const OUString& rText,
216  sal_Int32 nPos );
217 
218  // get boundaries of word/sentence/etc. for specified text type
219  // Does all argument checking, and then delegates to helper methods above.
223  bool GetTextBoundary( css::i18n::Boundary& rBound,
224  const OUString& rText,
225  sal_Int32 nPos,
226  sal_Int16 aTextType );
227 
228  virtual void Notify(SfxBroadcaster& rBC, const SfxHint& rHint) override;
229 
230 public:
231 
232  SwAccessibleParagraph( std::shared_ptr<SwAccessibleMap> const& pInitMap,
233  const SwTextFrame& rTextFrame );
234 
235  inline operator css::accessibility::XAccessibleText *();
236 
237  virtual bool HasCursor() override; // required by map to remember that object
238 
239  css::uno::Sequence< css::style::TabStop > GetCurrentTabStop( sal_Int32 nIndex );
240  virtual sal_Int16 SAL_CALL getAccessibleRole() override;
241 
242  // XAccessibleContext
243 
244  // Return this object's description.
245  virtual OUString SAL_CALL
246  getAccessibleDescription() override;
247 
248  // Return the parents locale or throw exception if this object has no
249  // parent yet/anymore.
250  virtual css::lang::Locale SAL_CALL
251  getLocale() override;
252 
253  // #i27138# - paragraphs are in relation CONTENT_FLOWS_FROM and/or CONTENT_FLOWS_TO
254  virtual css::uno::Reference<
255  css::accessibility::XAccessibleRelationSet> SAL_CALL
256  getAccessibleRelationSet() override;
257 
258  // XAccessibleComponent
259 
260  virtual void SAL_CALL grabFocus() override;
261  // #i71385#
262  virtual sal_Int32 SAL_CALL getForeground() override;
263  virtual sal_Int32 SAL_CALL getBackground() override;
264 
265  // XServiceInfo
266 
267  // Returns an identifier for the implementation of this object.
268  virtual OUString SAL_CALL
269  getImplementationName() override;
270 
271  // Return whether the specified service is supported by this class.
272  virtual sal_Bool SAL_CALL
273  supportsService (const OUString& sServiceName) override;
274 
275  // Returns a list of all supported services. In this case that is just
276  // the AccessibleContext service.
277  virtual css::uno::Sequence< OUString> SAL_CALL
278  getSupportedServiceNames() override;
279 
280  // XInterface
281 
282  // (XInterface methods need to be implemented to disambiguate
283  // between those inherited through SwAccessibleContext and
284  // XAccessibleEditableText).
285 
286  virtual css::uno::Any SAL_CALL queryInterface(
287  const css::uno::Type& aType ) override;
288 
289  virtual void SAL_CALL acquire( ) throw () override
290  { SwAccessibleContext::acquire(); };
291 
292  virtual void SAL_CALL release( ) throw () override
293  { SwAccessibleContext::release(); };
294 
295  // XTypeProvider
296  virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes( ) override;
297  virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId( ) override;
298 
299  // XAccessibleText
300  virtual sal_Int32 SAL_CALL getCaretPosition() override;
301  virtual sal_Bool SAL_CALL setCaretPosition( sal_Int32 nIndex ) override;
302  virtual sal_Unicode SAL_CALL getCharacter( sal_Int32 nIndex ) override;
303  virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getCharacterAttributes( sal_Int32 nIndex, const css::uno::Sequence< OUString >& aRequestedAttributes ) override;
304  virtual css::awt::Rectangle SAL_CALL getCharacterBounds( sal_Int32 nIndex ) override;
305  virtual sal_Int32 SAL_CALL getCharacterCount( ) override;
306  virtual sal_Int32 SAL_CALL getIndexAtPoint( const css::awt::Point& aPoint ) override;
307  virtual OUString SAL_CALL getSelectedText( ) override;
308  virtual sal_Int32 SAL_CALL getSelectionStart() override;
309  virtual sal_Int32 SAL_CALL getSelectionEnd() override;
310  virtual sal_Bool SAL_CALL setSelection( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) override;
311  virtual OUString SAL_CALL getText( ) override;
312  virtual OUString SAL_CALL getTextRange( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) override;
313  virtual css::accessibility::TextSegment SAL_CALL getTextAtIndex( sal_Int32 nIndex, sal_Int16 aTextType ) override;
314  virtual css::accessibility::TextSegment SAL_CALL getTextBeforeIndex( sal_Int32 nIndex, sal_Int16 aTextType ) override;
315  virtual css::accessibility::TextSegment SAL_CALL getTextBehindIndex( sal_Int32 nIndex, sal_Int16 aTextType ) override;
316  virtual sal_Bool SAL_CALL copyText( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) override;
317  virtual sal_Bool SAL_CALL scrollSubstringTo( sal_Int32 nStartIndex, sal_Int32 nEndIndex, css::accessibility::AccessibleScrollType aScrollType) override;
318 
319  // XAccessibleEditableText
320  virtual sal_Bool SAL_CALL cutText( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) override;
321  virtual sal_Bool SAL_CALL pasteText( sal_Int32 nIndex ) override;
322  virtual sal_Bool SAL_CALL deleteText( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) override;
323  virtual sal_Bool SAL_CALL insertText( const OUString& sText, sal_Int32 nIndex ) override;
324  virtual sal_Bool SAL_CALL replaceText( sal_Int32 nStartIndex, sal_Int32 nEndIndex, const OUString& sReplacement ) override;
325  virtual sal_Bool SAL_CALL setAttributes( sal_Int32 nStartIndex, sal_Int32 nEndIndex, const css::uno::Sequence< css::beans::PropertyValue >& aAttributeSet ) override;
326  virtual sal_Bool SAL_CALL setText( const OUString& sText ) override;
327 
328  // XAccessibleSelection
329  virtual void SAL_CALL selectAccessibleChild(
330  sal_Int32 nChildIndex ) override;
331 
332  virtual sal_Bool SAL_CALL isAccessibleChildSelected(
333  sal_Int32 nChildIndex ) override;
334  virtual void SAL_CALL clearAccessibleSelection( ) override;
335  virtual void SAL_CALL selectAllAccessibleChildren( ) override;
336  virtual sal_Int32 SAL_CALL getSelectedAccessibleChildCount( ) override;
337  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getSelectedAccessibleChild(
338  sal_Int32 nSelectedChildIndex ) override;
339 
340  // index has to be treated as global child index.
341  virtual void SAL_CALL deselectAccessibleChild(
342  sal_Int32 nChildIndex ) override;
343 
344  // XAccessibleHypertext
345  virtual sal_Int32 SAL_CALL getHyperLinkCount() override;
346  virtual css::uno::Reference<
347  css::accessibility::XAccessibleHyperlink >
348  SAL_CALL getHyperLink( sal_Int32 nLinkIndex ) override;
349  virtual sal_Int32 SAL_CALL getHyperLinkIndex( sal_Int32 nCharIndex ) override;
350 
351  // #i71360#
352  // XAccessibleTextMarkup
353  virtual sal_Int32 SAL_CALL getTextMarkupCount( sal_Int32 nTextMarkupType ) override;
354 
355  virtual css::accessibility::TextSegment SAL_CALL
356  getTextMarkup( sal_Int32 nTextMarkupIndex,
357  sal_Int32 nTextMarkupType ) override;
358 
359  virtual css::uno::Sequence< css::accessibility::TextSegment > SAL_CALL
360  getTextMarkupAtIndex( sal_Int32 nCharIndex,
361  sal_Int32 nTextMarkupType ) override;
362 
363  // XAccessibleTextSelection
364  virtual sal_Bool SAL_CALL scrollToPosition( const css::awt::Point& aPoint, sal_Bool isLeftTop ) override;
365  virtual sal_Int32 SAL_CALL getSelectedPortionCount( ) override;
366  virtual sal_Int32 SAL_CALL getSeletedPositionStart( sal_Int32 nSelectedPortionIndex ) override;
367  virtual sal_Int32 SAL_CALL getSeletedPositionEnd( sal_Int32 nSelectedPortionIndex ) override;
368  virtual sal_Bool SAL_CALL removeSelection( sal_Int32 selectionIndex ) override;
369  virtual sal_Int32 SAL_CALL addSelection( sal_Int32 selectionIndex, sal_Int32 startOffset, sal_Int32 endOffset) override;
370  // XAccessibleExtendedAttributes
371  virtual css::uno::Any SAL_CALL getExtendedAttributes() override ;
372  sal_Int32 GetRealHeadingLevel();
373 
374  // #i89175#
375  // XAccessibleMultiLineText
376  virtual sal_Int32 SAL_CALL getLineNumberAtIndex( sal_Int32 nIndex ) override;
377 
378  virtual css::accessibility::TextSegment SAL_CALL
379  getTextAtLineNumber( sal_Int32 nLineNo ) override;
380 
381  virtual css::accessibility::TextSegment SAL_CALL
382  getTextAtLineWithCaret() override;
383 
384  virtual sal_Int32 SAL_CALL getNumberOfLineWithCaret() override;
385 
386  // #i63870#
387  // XAccessibleTextAttributes
388  virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getDefaultAttributes( const css::uno::Sequence< OUString >& aRequestedAttributes ) override;
389  virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getRunAttributes( sal_Int32 nIndex, const css::uno::Sequence< OUString >& aRequestedAttributes ) override;
390 };
391 
392 inline SwAccessibleParagraph::operator css::accessibility::XAccessibleText *()
393 {
394  return static_cast< css::accessibility::XAccessibleEditableText * >( this );
395 }
396 
397 #endif
398 
399 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual sal_Int32 SAL_CALL getSeletedPositionStart(sal_Int32 nSelectedPortionIndex) override
Definition: accpara.cxx:3018
void _getDefaultAttributesImpl(const css::uno::Sequence< OUString > &aRequestedAttributes, tAccParaPropValMap &rDefAttrSeq, const bool bOnlyCharAttrs=false)
Definition: accpara.cxx:1444
bool GetWordBoundary(css::i18n::Boundary &rBound, const OUString &rText, sal_Int32 nPos)
Definition: accpara.cxx:559
Represents the visualization of a paragraph.
Definition: txtfrm.hxx:151
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: accpara.cxx:884
css::uno::Sequence< css::style::TabStop > GetCurrentTabStop(sal_Int32 nIndex)
Definition: accpara.cxx:1083
virtual sal_Bool SAL_CALL setSelection(sal_Int32 nStartIndex, sal_Int32 nEndIndex) override
Definition: accpara.cxx:2222
bool GetAttributeBoundary(css::i18n::Boundary &rBound, sal_Int32 nPos)
Definition: accpara.cxx:617
static bool GetParagraphBoundary(css::i18n::Boundary &rBound, const OUString &rText)
Definition: accpara.cxx:608
static OUString GetDescription()
Definition: accpara.cxx:122
void ExecuteAtViewShell(sal_uInt16 nSlot)
Definition: accpara.cxx:457
virtual sal_Int32 SAL_CALL getSeletedPositionEnd(sal_Int32 nSelectedPortionIndex) override
Definition: accpara.cxx:3029
virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getSelectedAccessibleChild(sal_Int32 nSelectedChildIndex) override
Definition: accpara.cxx:2749
virtual void SAL_CALL selectAccessibleChild(sal_Int32 nChildIndex) override
Definition: accpara.cxx:2714
virtual void GetStates(::utl::AccessibleStateSetHelper &rStateSet) override
Definition: accpara.cxx:216
OUString const & GetString()
get the (accessible) text string (requires frame; check before)
Definition: accpara.cxx:117
virtual sal_Int32 SAL_CALL getHyperLinkCount() override
Definition: accpara.cxx:2828
bool IsHeading() const
Definition: accpara.cxx:209
virtual sal_Int32 SAL_CALL getBackground() override
Definition: accpara.cxx:859
virtual sal_Bool SAL_CALL setAttributes(sal_Int32 nStartIndex, sal_Int32 nEndIndex, const css::uno::Sequence< css::beans::PropertyValue > &aAttributeSet) override
Definition: accpara.cxx:2650
void _getSupplementalAttributesImpl(const css::uno::Sequence< OUString > &aRequestedAttributes, tAccParaPropValMap &rSupplementalAttrSeq)
Definition: accpara.cxx:1756
virtual css::awt::Rectangle SAL_CALL getCharacterBounds(sal_Int32 nIndex) override
Definition: accpara.cxx:2045
virtual sal_Int32 SAL_CALL getSelectionEnd() override
Definition: accpara.cxx:2211
virtual sal_Unicode SAL_CALL getCharacter(sal_Int32 nIndex) override
Definition: accpara.cxx:1068
virtual sal_Bool SAL_CALL scrollToPosition(const css::awt::Point &aPoint, sal_Bool isLeftTop) override
Definition: accpara.cxx:2968
virtual sal_Bool SAL_CALL setText(const OUString &sText) override
Definition: accpara.cxx:2707
virtual sal_Bool SAL_CALL isAccessibleChildSelected(sal_Int32 nChildIndex) override
Definition: accpara.cxx:2722
virtual css::lang::Locale SAL_CALL getLocale() override
Return the parents locale or throw exception if this object has no parent yet/anymore.
Definition: accpara.cxx:721
bool GetSelectionAtIndex(sal_Int32 *pSelection, sal_Int32 &nStart, sal_Int32 &nEnd)
Definition: accpara.cxx:3348
virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getRunAttributes(sal_Int32 nIndex, const css::uno::Sequence< OUString > &aRequestedAttributes) override
Definition: accpara.cxx:1734
virtual css::accessibility::TextSegment SAL_CALL getTextBehindIndex(sal_Int32 nIndex, sal_Int16 aTextType) override
Definition: accpara.cxx:2388
virtual sal_Bool SAL_CALL insertText(const OUString &sText, sal_Int32 nIndex) override
Definition: accpara.cxx:2599
virtual sal_Int32 SAL_CALL getHyperLinkIndex(sal_Int32 nCharIndex) override
Definition: accpara.cxx:2901
virtual sal_Int32 SAL_CALL getSelectedPortionCount() override
Definition: accpara.cxx:2973
virtual sal_Bool SAL_CALL pasteText(sal_Int32 nIndex) override
Definition: accpara.cxx:2579
virtual void InvalidateFocus_() override
Definition: accpara.cxx:380
SwAccessiblePortionData & GetPortionData()
Definition: accpara.hxx:190
static bool IsValidRange(sal_Int32 nBegin, sal_Int32 nEnd, sal_Int32 nLength)
Definition: accpara.cxx:525
virtual sal_Int32 SAL_CALL getNumberOfLineWithCaret() override
Definition: accpara.cxx:3285
sal_uInt16 sal_Unicode
virtual sal_Bool SAL_CALL scrollSubstringTo(sal_Int32 nStartIndex, sal_Int32 nEndIndex, css::accessibility::AccessibleScrollType aScrollType) override
Definition: accpara.cxx:2497
SwAccessibleSelectionHelper m_aSelectionHelper
Definition: accpara.hxx:85
SwXTextPortion * CreateUnoPortion(sal_Int32 nStart, sal_Int32 nEnd)
Definition: accpara.cxx:482
std::unique_ptr< SwAccessiblePortionData > m_pPortionData
Definition: accpara.hxx:74
static bool IsValidChar(sal_Int32 nPos, sal_Int32 nLength)
Definition: accpara.cxx:513
virtual OUString SAL_CALL getText() override
Definition: accpara.cxx:2256
virtual sal_Int32 SAL_CALL getForeground() override
Definition: accpara.cxx:838
SwAccessibleParagraph(std::shared_ptr< SwAccessibleMap > const &pInitMap, const SwTextFrame &rTextFrame)
Definition: accpara.cxx:397
virtual css::uno::Reference< css::accessibility::XAccessibleRelationSet > SAL_CALL getAccessibleRelationSet() override
Definition: accpara.cxx:737
virtual css::accessibility::TextSegment SAL_CALL getTextMarkup(sal_Int32 nTextMarkupIndex, sal_Int32 nTextMarkupType) override
Definition: accpara.cxx:3167
virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getCharacterAttributes(sal_Int32 nIndex, const css::uno::Sequence< OUString > &aRequestedAttributes) override
Definition: accpara.cxx:1336
virtual sal_Int32 SAL_CALL getTextMarkupCount(sal_Int32 nTextMarkupType) override
Definition: accpara.cxx:2941
sal_Int32 m_nOldCaretPos
Definition: accpara.hxx:77
virtual OUString SAL_CALL getImplementationName() override
Definition: accpara.cxx:873
PaM is Point and Mark: a selection of the document model.
Definition: pam.hxx:136
std::unique_ptr< SwParaChangeTrackingInfo > mpParaChangeTrackInfo
Definition: accpara.hxx:87
virtual sal_Int16 SAL_CALL getAccessibleRole() override
Definition: accpara.cxx:3501
virtual sal_Bool SAL_CALL cutText(sal_Int32 nStartIndex, sal_Int32 nEndIndex) override
Definition: accpara.cxx:2564
virtual void SAL_CALL grabFocus() override
Definition: accpara.cxx:772
virtual css::accessibility::TextSegment SAL_CALL getTextBeforeIndex(sal_Int32 nIndex, sal_Int16 aTextType) override
Definition: accpara.cxx:2317
SwPaM * GetCursor(const bool _bForSelection)
Definition: accpara.cxx:185
sal_Int32 m_nHeadingLevel
Definition: accpara.hxx:82
static bool IsValidPosition(sal_Int32 nPos, sal_Int32 nLength)
Definition: accpara.cxx:519
virtual css::uno::Any SAL_CALL getExtendedAttributes() override
Definition: accpara.cxx:3539
virtual void SAL_CALL selectAllAccessibleChildren() override
Definition: accpara.cxx:2735
virtual bool HasCursor() override
Definition: accpara.cxx:430
unsigned char sal_Bool
virtual void InvalidateCursorPos_() override
Definition: accpara.cxx:330
collect text portion data from the layout through SwPortionHandler interface
Definition: accportions.hxx:39
sal_Int32 GetCaretPos()
Definition: accpara.cxx:127
virtual css::accessibility::TextSegment SAL_CALL getTextAtLineWithCaret() override
Definition: accpara.cxx:3270
const SwRangeRedline * GetRedlineAtIndex()
Definition: accpara.cxx:532
bool GetTextBoundary(css::i18n::Boundary &rBound, const OUString &rText, sal_Int32 nPos, sal_Int16 aTextType)
Definition: accpara.cxx:653
bool GetLineBoundary(css::i18n::Boundary &rBound, const OUString &rText, sal_Int32 nPos)
Definition: accpara.cxx:596
virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getDefaultAttributes(const css::uno::Sequence< OUString > &aRequestedAttributes) override
Definition: accpara.cxx:1596
virtual void SAL_CALL acquire() override
Definition: accpara.hxx:289
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() override
Definition: accpara.cxx:1008
OUString GetFieldTypeNameAtIndex(sal_Int32 nIndex)
Definition: accpara.cxx:1167
static void OrderRange(sal_Int32 &nBegin, sal_Int32 &nEnd)
Definition: accpara.hxx:133
virtual sal_Int32 SAL_CALL getCaretPosition() override
Definition: accpara.cxx:1015
sal_Int32 GetRealHeadingLevel()
Definition: accpara.cxx:3517
virtual css::uno::Any SAL_CALL queryInterface(const css::uno::Type &aType) override
Definition: accpara.cxx:932
virtual sal_Int32 SAL_CALL getIndexAtPoint(const css::awt::Point &aPoint) override
Definition: accpara.cxx:2111
virtual OUString SAL_CALL getSelectedText() override
Definition: accpara.cxx:2187
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes() override
Definition: accpara.cxx:994
virtual sal_Int32 SAL_CALL getSelectedAccessibleChildCount() override
Definition: accpara.cxx:2742
virtual css::accessibility::TextSegment SAL_CALL getTextAtLineNumber(sal_Int32 nLineNo) override
Definition: accpara.cxx:3246
virtual void SAL_CALL deselectAccessibleChild(sal_Int32 nChildIndex) override
Definition: accpara.cxx:2758
bool GetSelection(sal_Int32 &nStart, sal_Int32 &nEnd)
Definition: accpara.hxx:104
virtual void Notify(SfxBroadcaster &rBC, const SfxHint &rHint) override
Definition: accpara.cxx:3343
std::unordered_map< OUString, css::beans::PropertyValue > tAccParaPropValMap
Definition: accpara.hxx:51
virtual sal_Bool SAL_CALL supportsService(const OUString &sServiceName) override
Return whether the specified service is supported by this class.
Definition: accpara.cxx:878
void _correctValues(const sal_Int32 nIndex, std::vector< css::beans::PropertyValue > &rValues)
Definition: accpara.cxx:1816
virtual sal_Int32 SAL_CALL addSelection(sal_Int32 selectionIndex, sal_Int32 startOffset, sal_Int32 endOffset) override
Definition: accpara.cxx:3103
virtual OUString SAL_CALL getAccessibleDescription() override
Definition: accpara.cxx:708
bool GetGlyphBoundary(css::i18n::Boundary &rBound, const OUString &rText, sal_Int32 nPos)
Definition: accpara.cxx:625
virtual sal_Bool SAL_CALL setCaretPosition(sal_Int32 nIndex) override
Definition: accpara.cxx:1036
void _getRunAttributesImpl(const sal_Int32 nIndex, const css::uno::Sequence< OUString > &aRequestedAttributes, tAccParaPropValMap &rRunAttrSeq)
Definition: accpara.cxx:1633
virtual sal_Int32 SAL_CALL getLineNumberAtIndex(sal_Int32 nIndex) override
Definition: accpara.cxx:3230
virtual sal_Bool SAL_CALL replaceText(sal_Int32 nStartIndex, sal_Int32 nEndIndex, const OUString &sReplacement) override
Definition: accpara.cxx:2604
virtual css::uno::Reference< css::accessibility::XAccessibleHyperlink > SAL_CALL getHyperLink(sal_Int32 nLinkIndex) override
Definition: accpara.cxx:2846
std::unique_ptr< SwAccessibleHyperTextData > m_pHyperTextData
Definition: accpara.hxx:75
const char sServiceName[]
Definition: accdoc.cxx:57
virtual OUString SAL_CALL getTextRange(sal_Int32 nStartIndex, sal_Int32 nEndIndex) override
Definition: accpara.cxx:2265
virtual ~SwAccessibleParagraph() override
Definition: accpara.cxx:420
bool GetCharBoundary(css::i18n::Boundary &rBound, sal_Int32 nPos)
Definition: accpara.cxx:547
virtual sal_Int32 SAL_CALL getSelectionStart() override
Definition: accpara.cxx:2200
virtual sal_Bool SAL_CALL copyText(sal_Int32 nStartIndex, sal_Int32 nEndIndex) override
Definition: accpara.cxx:2485
virtual void InvalidateContent_(bool bVisibleDataFired) override
Definition: accpara.cxx:248
virtual css::uno::Sequence< css::accessibility::TextSegment > SAL_CALL getTextMarkupAtIndex(sal_Int32 nCharIndex, sal_Int32 nTextMarkupType) override
Definition: accpara.cxx:3195
virtual sal_Bool SAL_CALL deleteText(sal_Int32 nStartIndex, sal_Int32 nEndIndex) override
Definition: accpara.cxx:2594
virtual sal_Int32 SAL_CALL getCharacterCount() override
Definition: accpara.cxx:2102
virtual sal_Bool SAL_CALL removeSelection(sal_Int32 selectionIndex) override
Definition: accpara.cxx:3040
bool GetSentenceBoundary(css::i18n::Boundary &rBound, const OUString &rText, sal_Int32 nPos)
Definition: accpara.cxx:583
virtual void SAL_CALL release() override
Definition: accpara.hxx:292
virtual void SAL_CALL clearAccessibleSelection() override
Definition: accpara.cxx:2730
virtual css::accessibility::TextSegment SAL_CALL getTextAtIndex(sal_Int32 nIndex, sal_Int16 aTextType) override
Definition: accpara.cxx:2281