LibreOffice Module sc (master)  1
AccessibleCsvControl.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 
20 #pragma once
21 
22 #include <memory>
23 #include <com/sun/star/accessibility/AccessibleRole.hpp>
24 #include <com/sun/star/accessibility/AccessibleScrollType.hpp>
25 #include <com/sun/star/accessibility/XAccessibleText.hpp>
26 #include <com/sun/star/accessibility/XAccessibleTable.hpp>
27 #include <com/sun/star/accessibility/XAccessibleSelection.hpp>
28 #include <tools/gen.hxx>
29 #include <rtl/ref.hxx>
30 #include <rtl/ustrbuf.hxx>
32 #include <cppuhelper/implbase1.hxx>
33 #include <cppuhelper/implbase2.hxx>
34 #include <cppuhelper/implbase3.hxx>
36 #include <comphelper/uno3.hxx>
37 #include <map>
38 
39 class ScCsvControl;
40 namespace utl { class AccessibleStateSetHelper; }
41 
44 {
45 private:
47 
48 public:
49  explicit ScAccessibleCsvControl(ScCsvControl& rControl);
50  virtual ~ScAccessibleCsvControl() override;
51 
52  virtual void SAL_CALL disposing() override;
53 
54  virtual void SAL_CALL grabFocus( ) override;
55  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleAtPoint( const css::awt::Point& aPoint ) override;
56 
57  // events -----------------------------------------------------------------
58 public:
60  virtual void SendFocusEvent( bool bFocused );
62  virtual void SendCaretEvent();
64  void SendVisibleEvent();
66  void SendSelectionEvent();
68  virtual void SendTableUpdateEvent( sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn, bool bAllRows );
70  virtual void SendInsertColumnEvent( sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn );
72  virtual void SendRemoveColumnEvent( sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn );
73 
74  // helpers ----------------------------------------------------------------
75 protected:
76  virtual css::awt::Rectangle implGetBounds() override;
77 
80 
83 };
84 
85 class ScCsvRuler;
86 
87 typedef ::cppu::ImplHelper2<css::accessibility::XAccessible,
88  css::accessibility::XAccessibleText> ScAccessibleCsvRulerImpl;
89 
92 {
93 private:
94  OUStringBuffer maBuffer;
95 
96 public:
97  explicit ScAccessibleCsvRuler( ScCsvRuler& rRuler );
98  virtual ~ScAccessibleCsvRuler() override;
99 
100  // XAccessibleComponent -----------------------------------------------------
101  virtual css::uno::Reference< css::accessibility::XAccessibleContext > SAL_CALL getAccessibleContext( ) override { return this; }
102 
103  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleParent( ) override;
104 
105  virtual OUString SAL_CALL getAccessibleDescription( ) override;
106  virtual OUString SAL_CALL getAccessibleName( ) override;
107 
108  virtual sal_Int32 SAL_CALL getForeground( ) override;
109 
110  virtual sal_Int32 SAL_CALL getBackground( ) override;
111 
112  // XAccessibleContext -----------------------------------------------------
113 
115  virtual sal_Int32 SAL_CALL getAccessibleChildCount() override;
116 
118  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleChild( sal_Int32 nIndex ) override;
119 
120  virtual sal_Int16 SAL_CALL getAccessibleRole( ) override { return css::accessibility::AccessibleRole::TEXT; }
121 
123  virtual css::uno::Reference< css::accessibility::XAccessibleRelationSet > SAL_CALL getAccessibleRelationSet() override;
124 
126  virtual css::uno::Reference< css::accessibility::XAccessibleStateSet > SAL_CALL getAccessibleStateSet() override;
127 
128  // XAccessibleText --------------------------------------------------------
129 
131  virtual sal_Int32 SAL_CALL getCaretPosition() override;
132 
134  virtual sal_Bool SAL_CALL setCaretPosition( sal_Int32 nIndex ) override;
135 
137  virtual sal_Unicode SAL_CALL getCharacter( sal_Int32 nIndex ) override;
138 
140  virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getCharacterAttributes( sal_Int32 nIndex, const css::uno::Sequence< OUString >& aRequestedAttributes ) override;
141 
143  virtual css::awt::Rectangle SAL_CALL getCharacterBounds( sal_Int32 nIndex ) override;
144 
146  virtual sal_Int32 SAL_CALL getCharacterCount() override;
147 
149  virtual sal_Int32 SAL_CALL getIndexAtPoint( const css::awt::Point& rPoint ) override;
150 
152  virtual OUString SAL_CALL getSelectedText() override;
153 
155  virtual sal_Int32 SAL_CALL getSelectionStart() override;
156 
158  virtual sal_Int32 SAL_CALL getSelectionEnd() override;
159 
161  virtual sal_Bool SAL_CALL setSelection( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) override;
162 
164  virtual OUString SAL_CALL getText() override;
165 
167  virtual OUString SAL_CALL getTextRange( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) override;
168 
170  virtual css::accessibility::TextSegment SAL_CALL getTextAtIndex( sal_Int32 nIndex, sal_Int16 aTextType ) override;
171  virtual css::accessibility::TextSegment SAL_CALL getTextBeforeIndex( sal_Int32 nIndex, sal_Int16 aTextType ) override;
172  virtual css::accessibility::TextSegment SAL_CALL getTextBehindIndex( sal_Int32 nIndex, sal_Int16 aTextType ) override;
173 
175  virtual sal_Bool SAL_CALL copyText( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) override;
176 
177  virtual sal_Bool SAL_CALL scrollSubstringTo( sal_Int32 nStartIndex, sal_Int32 nEndIndex, css::accessibility::AccessibleScrollType aScrollType) override;
178 
179  // XInterface -------------------------------------------------------------
180 
182 
183  // XTypeProvider ----------------------------------------------------------
184 
185  DECLARE_XTYPEPROVIDER()
186 
187  // events -----------------------------------------------------------------
188 public:
190  virtual void SendCaretEvent() override;
191 
192  // helpers ----------------------------------------------------------------
193 private:
194 
196  void ensureValidIndex( sal_Int32 nIndex ) const;
198  void ensureValidIndexWithEnd( sal_Int32 nIndex ) const;
201  void ensureValidRange( sal_Int32& rnStartIndex, sal_Int32& rnEndIndex ) const;
202 
204  ScCsvRuler& implGetRuler() const;
205 
210  void constructStringBuffer();
212  sal_Int32 implGetTextLength() const;
213 
215  bool implHasSplit( sal_Int32 nApiPos );
216 
218  sal_Int32 implGetFirstEqualFormatted( sal_Int32 nApiPos );
220  sal_Int32 implGetLastEqualFormatted( sal_Int32 nApiPos );
221 };
222 
223 class ScCsvGrid;
225 
226 typedef ::cppu::ImplHelper3<
227  css::accessibility::XAccessible,
228  css::accessibility::XAccessibleTable,
229  css::accessibility::XAccessibleSelection >
231 
233 class ScAccessibleCsvGrid : public ScAccessibleCsvControl, public ScAccessibleCsvGridImpl
234 {
235 protected:
236  typedef std::map< sal_Int32, rtl::Reference<ScAccessibleCsvCell> > XAccessibleSet;
237 
238 private:
239  XAccessibleSet maAccessibleChildren;
240 
241 public:
242  explicit ScAccessibleCsvGrid( ScCsvGrid& rGrid );
243  virtual ~ScAccessibleCsvGrid() override;
244  virtual void SAL_CALL disposing() override;
245 
246  // XAccessibleComponent ---------------------------------------------------
247  virtual css::uno::Reference< css::accessibility::XAccessibleContext > SAL_CALL getAccessibleContext( ) override { return this; }
248 
249  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleParent( ) override;
250 
252  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleAtPoint( const css::awt::Point& rPoint ) override;
253 
254  virtual OUString SAL_CALL getAccessibleDescription( ) override;
255  virtual OUString SAL_CALL getAccessibleName( ) override;
256 
257  virtual sal_Int32 SAL_CALL getForeground( ) override;
258 
259  virtual sal_Int32 SAL_CALL getBackground( ) override;
260 
261  virtual sal_Int16 SAL_CALL getAccessibleRole( ) override { return css::accessibility::AccessibleRole::TABLE; }
262 
263  // XAccessibleContext -----------------------------------------------------
264 
266  virtual sal_Int32 SAL_CALL getAccessibleChildCount() override;
267 
269  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleChild( sal_Int32 nIndex ) override;
270 
272  virtual css::uno::Reference< css::accessibility::XAccessibleRelationSet > SAL_CALL getAccessibleRelationSet() override;
273 
275  virtual css::uno::Reference< css::accessibility::XAccessibleStateSet > SAL_CALL getAccessibleStateSet() override;
276 
277  // XAccessibleTable -------------------------------------------------------
278 
280  virtual sal_Int32 SAL_CALL getAccessibleRowCount() override;
281 
283  virtual sal_Int32 SAL_CALL getAccessibleColumnCount() override;
284 
286  virtual OUString SAL_CALL getAccessibleRowDescription( sal_Int32 nRow ) override;
287 
289  virtual OUString SAL_CALL getAccessibleColumnDescription( sal_Int32 nColumn ) override;
290 
293  virtual sal_Int32 SAL_CALL getAccessibleRowExtentAt( sal_Int32 nRow, sal_Int32 nColumn ) override;
294 
297  virtual sal_Int32 SAL_CALL getAccessibleColumnExtentAt( sal_Int32 nRow, sal_Int32 nColumn ) override;
298 
300  virtual css::uno::Reference< css::accessibility::XAccessibleTable > SAL_CALL getAccessibleRowHeaders() override;
301 
303  virtual css::uno::Reference< css::accessibility::XAccessibleTable > SAL_CALL getAccessibleColumnHeaders() override;
304 
306  virtual css::uno::Sequence< sal_Int32 > SAL_CALL getSelectedAccessibleRows() override;
307 
309  virtual css::uno::Sequence< sal_Int32 > SAL_CALL getSelectedAccessibleColumns() override;
310 
312  virtual sal_Bool SAL_CALL isAccessibleRowSelected( sal_Int32 nRow ) override;
313 
315  virtual sal_Bool SAL_CALL isAccessibleColumnSelected( sal_Int32 nColumn ) override;
316 
318  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleCellAt( sal_Int32 nRow, sal_Int32 nColumn ) override;
319 
321  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleCaption() override;
322 
324  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleSummary() override;
325 
327  virtual sal_Bool SAL_CALL isAccessibleSelected( sal_Int32 nRow, sal_Int32 nColumn ) override;
328 
330  virtual sal_Int32 SAL_CALL getAccessibleIndex( sal_Int32 nRow, sal_Int32 nColumn ) override;
331 
333  virtual sal_Int32 SAL_CALL getAccessibleRow( sal_Int32 nChildIndex ) override;
334 
336  virtual sal_Int32 SAL_CALL getAccessibleColumn( sal_Int32 nChildIndex ) override;
337 
338  // XAccessibleSelection ---------------------------------------------------
339 
341  virtual void SAL_CALL selectAccessibleChild( sal_Int32 nChildIndex ) override;
342 
344  virtual sal_Bool SAL_CALL isAccessibleChildSelected( sal_Int32 nChildIndex ) override;
345 
347  virtual void SAL_CALL clearAccessibleSelection() override;
348 
350  virtual void SAL_CALL selectAllAccessibleChildren() override;
351 
353  virtual sal_Int32 SAL_CALL getSelectedAccessibleChildCount() override;
354 
356  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getSelectedAccessibleChild( sal_Int32 nSelectedChildIndex ) override;
357 
359  virtual void SAL_CALL deselectAccessibleChild( sal_Int32 nSelectedChildIndex ) override;
360 
361  // XInterface -------------------------------------------------------------
362 
363  virtual css::uno::Any SAL_CALL queryInterface( const css::uno::Type& rType ) override;
364 
365  virtual void SAL_CALL acquire() noexcept override;
366 
367  virtual void SAL_CALL release() noexcept override;
368 
369  // XTypeProvider ----------------------------------------------------------
370 
372  virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes() override;
373 
375  virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() override;
376 
377  // events -----------------------------------------------------------------
378 public:
380  virtual void SendFocusEvent( bool bFocused ) override;
382  virtual void SendTableUpdateEvent( sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn, bool bAllRows ) override;
384  virtual void SendInsertColumnEvent( sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn ) override;
386  virtual void SendRemoveColumnEvent( sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn ) override;
387 
388  // helpers ----------------------------------------------------------------
389 private:
390 
392  void ensureValidIndex( sal_Int32 nIndex ) const;
394  void ensureValidPosition( sal_Int32 nRow, sal_Int32 nColumn ) const;
395 
397  ScCsvGrid& implGetGrid() const;
398 
400  bool implIsColumnSelected( sal_Int32 nColumn ) const;
402  void implSelectColumn( sal_Int32 nColumn, bool bSelect );
403 
405  sal_Int32 implGetRowCount() const;
407  sal_Int32 implGetColumnCount() const;
409  sal_Int32 implGetSelColumnCount() const;
411  sal_Int32 implGetCellCount() const { return implGetRowCount() * implGetColumnCount(); }
412 
414  sal_Int32 implGetRow( sal_Int32 nIndex ) const { return nIndex / implGetColumnCount(); }
416  sal_Int32 implGetColumn( sal_Int32 nIndex ) const { return nIndex % implGetColumnCount(); }
418  sal_Int32 implGetSelColumn( sal_Int32 nSelColumn ) const;
420  sal_Int32 implGetIndex( sal_Int32 nRow, sal_Int32 nColumn ) const { return nRow * implGetColumnCount() + nColumn; }
421 
423  OUString implGetCellText( sal_Int32 nRow, sal_Int32 nColumn ) const;
425  rtl::Reference<ScAccessibleCsvCell> implCreateCellObj(sal_Int32 nRow, sal_Int32 nColumn);
426 
427  css::uno::Reference<css::accessibility::XAccessible> getAccessibleCell(sal_Int32 nRow, sal_Int32 nColumn);
428 };
429 
432  , public cppu::ImplHelper1<css::accessibility::XAccessible>
434 {
435 protected:
436  typedef ::std::unique_ptr< SvxEditSource > SvxEditSourcePtr;
437 
438 private:
439  OUString maCellText;
440  sal_Int32 mnLine;
441  sal_uInt32 mnColumn;
442  sal_Int32 mnIndex;
443 
444 public:
445  explicit ScAccessibleCsvCell(
446  ScCsvGrid& rGrid,
447  const OUString& rCellText,
448  sal_Int32 nRow, sal_Int32 nColumn);
449  virtual ~ScAccessibleCsvCell() override;
450 
451  virtual void SAL_CALL disposing() override;
452 
453  // XAccessibleComponent ---------------------------------------------------
454 
456  virtual void SAL_CALL grabFocus() override;
457 
458  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleParent( ) override;
459 
460  virtual css::uno::Reference< css::accessibility::XAccessibleContext > SAL_CALL getAccessibleContext( ) override { return this; }
461 
462  virtual OUString SAL_CALL getAccessibleDescription( ) override;
463  virtual OUString SAL_CALL getAccessibleName( ) override;
464  virtual sal_Int16 SAL_CALL getAccessibleRole( ) override { return css::accessibility::AccessibleRole::TEXT; }
465 
466  virtual sal_Int32 SAL_CALL getForeground( ) override;
467 
468  virtual sal_Int32 SAL_CALL getBackground( ) override;
469 
470  // XAccessibleContext -----------------------------------------------------
471 
473  virtual sal_Int32 SAL_CALL getAccessibleChildCount() override;
474 
476  virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleChild( sal_Int32 nIndex ) override;
477 
479  virtual sal_Int32 SAL_CALL getAccessibleIndexInParent() override;
480 
482  virtual css::uno::Reference< css::accessibility::XAccessibleRelationSet > SAL_CALL getAccessibleRelationSet() override;
483 
485  virtual css::uno::Reference< css::accessibility::XAccessibleStateSet > SAL_CALL getAccessibleStateSet() override;
486 
487  // XInterface -------------------------------------------------------------
488 
490 
491  // XTypeProvider ----------------------------------------------------------
492 
493  DECLARE_XTYPEPROVIDER()
494 
495 private:
497  ScCsvGrid& implGetGrid() const;
499  Point implGetRealPos() const;
501  sal_uInt32 implCalcPixelWidth(sal_uInt32 nChars) const;
503  Size implGetRealSize() const;
505  virtual css::awt::Rectangle implGetBounds() override;
506 
508  ::std::unique_ptr< SvxEditSource > implCreateEditSource();
509 };
510 
511 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual ~ScAccessibleCsvControl() override
Type
virtual css::uno::Any SAL_CALL queryInterface(css::uno::Type const &rType) SAL_OVERRIDE
virtual sal_Bool SAL_CALL scrollSubstringTo(sal_Int32 nStartIndex, sal_Int32 nEndIndex, css::accessibility::AccessibleScrollType aScrollType) override
std::map< sal_Int32, rtl::Reference< ScAccessibleCsvCell > > XAccessibleSet
virtual void SendFocusEvent(bool bFocused)
Sends a GetFocus or LoseFocus event to all listeners.
virtual sal_Int32 SAL_CALL getSelectionEnd() override
Returns the end index of the selection (ruler returns -1).
signed char sal_Int8
virtual sal_Int32 SAL_CALL getAccessibleIndexInParent() override
virtual sal_Int32 SAL_CALL getIndexAtPoint(const css::awt::Point &rPoint) override
Returns the character index at the specified coordinate (object's coordinate system).
virtual void SendInsertColumnEvent(sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn)
Sends a table model changed event for an inserted column to all listeners.
Accessible class representing the CSV grid control.
virtual sal_Int32 SAL_CALL getSelectionStart() override
Returns the start index of the selection (ruler returns -1).
Accessible class representing a cell of the CSV grid control.
virtual css::uno::Sequence< css::beans::PropertyValue > SAL_CALL getCharacterAttributes(sal_Int32 nIndex, const css::uno::Sequence< OUString > &aRequestedAttributes) override
Returns the attributes of the specified character.
virtual OUString SAL_CALL getSelectedText() override
Returns the selected text (ruler returns empty string).
void ensureValidIndex(sal_Int32 nIndex) const
void ensureValidRange(sal_Int32 &rnStartIndex, sal_Int32 &rnEndIndex) const
Base class for the CSV ruler and the data grid control.
Definition: csvcontrol.hxx:222
virtual OUString SAL_CALL getText() override
Returns the entire text.
Accessible base class used for CSV controls.
virtual css::uno::Reference< css::accessibility::XAccessibleContext > SAL_CALL getAccessibleContext() override
A ruler control for the CSV import dialog.
Definition: csvruler.hxx:32
XAccessibleSet maAccessibleChildren
virtual OUString SAL_CALL getTextRange(sal_Int32 nStartIndex, sal_Int32 nEndIndex) override
Returns the specified range [Start,End) of the text.
sal_Int32 implGetColumn(sal_Int32 nIndex) const
Returns the column index from cell index (including header).
sal_uInt32 mnColumn
The grid line index (core index).
virtual sal_Int16 SAL_CALL getAccessibleRole() override
void SendSelectionEvent()
Sends a selection changed event to all listeners.
sal_uInt16 sal_Unicode
ScAccessibleCsvRuler(ScCsvRuler &rRuler)
Contains the text representation of the ruler.
virtual OUString SAL_CALL getAccessibleName() override
::cppu::ImplHelper2< css::accessibility::XAccessible, css::accessibility::XAccessibleText > ScAccessibleCsvRulerImpl
virtual sal_Bool SAL_CALL setCaretPosition(sal_Int32 nIndex) override
Sets the position of the caret.
ScCsvRuler & implGetRuler() const
Returns the VCL ruler control.
virtual css::uno::Reference< css::accessibility::XAccessibleStateSet > SAL_CALL getAccessibleStateSet() override
Returns the current set of states.
ScCsvControl & implGetControl() const
Returns the VCL control.
void SendVisibleEvent()
Sends a visible area changed event to all listeners.
virtual sal_Int32 SAL_CALL getCharacterCount() override
Returns the count of characters.
virtual void SendRemoveColumnEvent(sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn)
Sends a table model changed event for a removed column to all listeners.
sal_Int32 implGetRow(sal_Int32 nIndex) const
Returns the row index from cell index (including header).
virtual void SAL_CALL grabFocus() override
virtual css::uno::Reference< css::accessibility::XAccessibleRelationSet > SAL_CALL getAccessibleRelationSet() override
Returns the relation to the grid control.
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes() SAL_OVERRIDE
virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleParent() override
virtual ~ScAccessibleCsvRuler() override
ScAccessibleCsvControl(ScCsvControl &rControl)
Pointer to the VCL control.
virtual css::awt::Rectangle implGetBounds() override
virtual sal_Int16 SAL_CALL getAccessibleRole() override
virtual sal_Int32 SAL_CALL getForeground() override
unsigned char sal_Bool
virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleAtPoint(const css::awt::Point &aPoint) override
sal_Int32 mnIndex
The grid column index (core index).
virtual void SendTableUpdateEvent(sal_uInt32 nFirstColumn, sal_uInt32 nLastColumn, bool bAllRows)
Sends a table model changed event for changed cell contents to all listeners.
sal_Int32 implGetTextLength() const
Returns the character count of the text.
bool implHasSplit(sal_Int32 nApiPos)
Returns true, if the character at the specified index has a split.
sal_Int32 mnLine
The text contents of this cell.
virtual sal_Bool SAL_CALL copyText(sal_Int32 nStartIndex, sal_Int32 nEndIndex) override
Copies the specified text range into the clipboard (ruler does nothing).
sal_Int32 implGetFirstEqualFormatted(sal_Int32 nApiPos)
Returns the first character index with equal formatting as at nApiPos.
virtual css::awt::Rectangle SAL_CALL getCharacterBounds(sal_Int32 nIndex) override
Returns the screen coordinates of the specified character.
virtual sal_Int16 SAL_CALL getAccessibleRole() override
virtual css::uno::Reference< css::accessibility::XAccessibleContext > SAL_CALL getAccessibleContext() override
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() SAL_OVERRIDE
Accessible class representing the CSV ruler control.
virtual sal_Bool SAL_CALL setSelection(sal_Int32 nStartIndex, sal_Int32 nEndIndex) override
Selects a part of the text (ruler does nothing).
void ensureValidIndexWithEnd(sal_Int32 nIndex) const
virtual OUString SAL_CALL getAccessibleDescription() override
virtual css::accessibility::TextSegment SAL_CALL getTextBeforeIndex(sal_Int32 nIndex, sal_Int16 aTextType) override
::std::unique_ptr< SvxEditSource > SvxEditSourcePtr
virtual void SendCaretEvent() override
Sends a caret changed event to all listeners.
sal_Int32 implGetIndex(sal_Int32 nRow, sal_Int32 nColumn) const
Returns the child index from cell position (including header).
virtual css::accessibility::TextSegment SAL_CALL getTextBehindIndex(sal_Int32 nIndex, sal_Int16 aTextType) override
virtual sal_Int32 SAL_CALL getAccessibleChildCount() override
Returns the child count (the ruler does not have children).
virtual void SendCaretEvent()
Sends a caret changed event to all listeners.
rtl::Reference<::utl::AccessibleStateSetHelper > implCreateStateSet()
Creates a StateSetHelper and fills it with DEFUNC, OPAQUE, ENABLED, SHOWING and VISIBLE.
virtual sal_Int32 SAL_CALL getCaretPosition() override
Return the position of the caret.
virtual sal_Int32 SAL_CALL getBackground() override
virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleChild(sal_Int32 nIndex) override
Throws an exception (the ruler does not have children).
virtual css::accessibility::TextSegment SAL_CALL getTextAtIndex(sal_Int32 nIndex, sal_Int16 aTextType) override
Returns the specified text portion.
virtual css::uno::Reference< css::accessibility::XAccessibleContext > SAL_CALL getAccessibleContext() override
sal_Int32 implGetLastEqualFormatted(sal_Int32 nApiPos)
Returns the last character index with equal formatting as at nApiPos.
virtual void SAL_CALL disposing() override
void constructStringBuffer()
Builds the entire string buffer.
virtual sal_Unicode SAL_CALL getCharacter(sal_Int32 nIndex) override
Returns the specified character.
#define DECLARE_XINTERFACE()
A data grid control for the CSV import dialog.
Definition: csvgrid.hxx:57