LibreOffice Module winaccessibility (master) 1
AccText.cxx
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#include "stdafx.h"
21#include <UAccCOM.h>
22#include "AccText.h"
23
24using namespace com::sun::star::accessibility;
25using namespace com::sun::star::uno;
26
34COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::addSelection(long startOffset, long endOffset)//, unsigned char * success)
35{
36
38}
39
48COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_attributes(long offset, long * startOffset, long * endOffset, BSTR * textAttributes)
49{
50
51 return CAccTextBase::get_attributes(offset, startOffset, endOffset, textAttributes);
52}
53
59COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_caretOffset(long * offset)
60{
61
63}
64
74COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_characterExtents(long offset, IA2CoordinateType coordType, long * x, long * y, long * width, long * height)
75{
76
77 return CAccTextBase::get_characterExtents(offset, coordType, x, y, width, height);
78}
79
85COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_nSelections(long * nSelections)
86{
87
89}
90
100COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_offsetAtPoint(long x, long y, IA2CoordinateType coordType, long * offset)
101{
102
104}
105
113COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_selection(long selection, long * startOffset, long * endOffset)
114{
115
117}
118
126COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_text(long startOffset, long endOffset, BSTR * text)
127{
128
130}
131
141COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_textBeforeOffset(long offset, IA2TextBoundaryType boundaryType, long * startOffset, long * endOffset, BSTR * text)
142{
143
144 return CAccTextBase::get_textBeforeOffset(offset, boundaryType,
146}
147
157COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_textAfterOffset(long offset, IA2TextBoundaryType boundaryType, long * startOffset, long * endOffset, BSTR * text)
158{
159
160 return CAccTextBase::get_textAfterOffset(offset, boundaryType,
162}
163
173COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_textAtOffset(long offset, IA2TextBoundaryType boundaryType, long * startOffset, long * endOffset, BSTR * text)
174{
175
176 return CAccTextBase::get_textAtOffset(offset, boundaryType,
178}
179
186COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::removeSelection(long selectionIndex)//, unsigned char * success)
187{
188
189 return CAccTextBase::removeSelection(selectionIndex);//, success);
190}
191
198COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::setCaretOffset(long offset)
199{
200
202}
203
213COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::setSelection(long selectionIndex, long startOffset, long endOffset)
214{
215
216 return CAccTextBase::setSelection(selectionIndex, startOffset,
217 endOffset);
218}
219
225COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_nCharacters(long * nCharacters)
226{
227
229}
230
231COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_newText( IA2TextSegment *newText)
232{
234}
235
236COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_oldText( IA2TextSegment *oldText)
237{
239}
240
247COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::scrollSubstringToPoint(long startIndex, long endIndex,enum IA2CoordinateType coordinateType, long x, long y )
248{
249
250 return CAccTextBase::scrollSubstringToPoint(startIndex, endIndex, coordinateType, x, y);
251}
252
253COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::scrollSubstringTo(long startIndex, long endIndex,enum IA2ScrollType scrollType)
254{
255
257}
258
259/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
STDMETHOD() get_nSelections(long *nSelections)
Get selections count.
STDMETHOD() get_caretOffset(long *offset)
Get caret position.
long long long * endOffset
Definition: AccTextBase.h:43
long long endIndex
Definition: AccTextBase.h:102
STDMETHOD() setSelection(long selectionIndex, long startOffset, long endOffset)
Set special selection.
STDMETHOD() get_selection(long selectionIndex, long *startOffset, long *endOffset)
Get selection range.
STDMETHOD() get_text(long startOffset, long endOffset, BSTR *text)
Get special text.
long IA2TextBoundaryType boundaryType
Definition: AccTextBase.h:71
long IA2CoordinateType long long long long * height
Definition: AccTextBase.h:54
long IA2CoordinateType long long long * width
Definition: AccTextBase.h:54
long IA2CoordinateType long * x
Definition: AccTextBase.h:54
STDMETHOD() setCaretOffset(long offset)
Set caret position.
STDMETHOD() get_addSelection(long startOffset, long endOffset)
Get special selection.
Definition: AccTextBase.cxx:91
STDMETHOD() get_offsetAtPoint(long x, long y, IA2CoordinateType coordType, long *offset)
Get offset of some special point.
STDMETHOD() get_nCharacters(long *nCharacters)
Get characters count.
STDMETHOD() get_newText(IA2TextSegment *newText)
STDMETHOD() scrollSubstringTo(long startIndex, long endIndex, enum IA2ScrollType scrollType)
STDMETHOD() get_oldText(IA2TextSegment *oldText)
long IA2TextBoundaryType long long BSTR * text
Definition: AccTextBase.h:71
long long * startOffset
Definition: AccTextBase.h:43
long IA2CoordinateType coordType
Definition: AccTextBase.h:54
STDMETHOD() removeSelection(long selectionIndex)
Remove selection.
long long long BSTR * textAttributes
Definition: AccTextBase.h:43
long IA2CoordinateType long long * y
Definition: AccTextBase.h:54
STDMETHOD() get_offsetAtPoint(long x, long y, IA2CoordinateType coordType, long *offset) override
Get offset of some special point.
Definition: AccText.cxx:100
STDMETHOD() get_textAfterOffset(long offset, IA2TextBoundaryType boundaryType, long *startOffset, long *endOffset, BSTR *text) override
Get special text after some position.
Definition: AccText.cxx:157
STDMETHOD() get_nCharacters(long *nCharacters) override
Get characters count.
Definition: AccText.cxx:225
STDMETHOD() get_newText(IA2TextSegment *newText) override
Definition: AccText.cxx:231
STDMETHOD() get_oldText(IA2TextSegment *oldText) override
Definition: AccText.cxx:236
STDMETHOD() scrollSubstringToPoint(long startIndex, long endIndex, enum IA2CoordinateType coordinateType, long x, long y) override
Scroll to special sub-string .
Definition: AccText.cxx:247
STDMETHOD() get_nSelections(long *nSelections) override
Get selections count.
Definition: AccText.cxx:85
STDMETHOD() get_selection(long selection, long *startOffset, long *endOffset) override
Get selection range.
Definition: AccText.cxx:113
STDMETHOD() scrollSubstringTo(long startIndex, long endIndex, enum IA2ScrollType scrollType) override
Makes a specific part of string visible on screen.
Definition: AccText.cxx:253
STDMETHOD() setCaretOffset(long offset) override
Set caret position.
Definition: AccText.cxx:198
STDMETHOD() addSelection(long startOffset, long endOffset) override
Get special selection.
Definition: AccText.cxx:34
STDMETHOD() setSelection(long selectionIndex, long startOffset, long endOffset) override
Set special selection.
Definition: AccText.cxx:213
STDMETHOD() get_text(long startOffset, long endOffset, BSTR *text) override
Get special text.
Definition: AccText.cxx:126
STDMETHOD() get_attributes(long offset, long *startOffset, long *endOffset, BSTR *textAttributes) override
Get special attributes.
Definition: AccText.cxx:48
STDMETHOD() get_characterExtents(long offset, IA2CoordinateType coordType, long *x, long *y, long *width, long *height) override
Get character extents.
Definition: AccText.cxx:74
STDMETHOD() get_caretOffset(long *offset) override
Get caret position.
Definition: AccText.cxx:59
STDMETHOD() get_textAtOffset(long offset, IA2TextBoundaryType boundaryType, long *startOffset, long *endOffset, BSTR *text) override
Get special text at some position.
Definition: AccText.cxx:173
STDMETHOD() removeSelection(long selectionIndex) override
Remove selection.
Definition: AccText.cxx:186
STDMETHOD() get_textBeforeOffset(long offset, IA2TextBoundaryType boundaryType, long *startOffset, long *endOffset, BSTR *text) override
Get special text before some position.
Definition: AccText.cxx:141
IA2ScrollType
These constants control the scrolling of an object or substring into a window.
IA2CoordinateType
These constants define which coordinate system a point is located in.
IA2TextBoundaryType
This enum defines values which specify a text boundary type.
IA2TextSegment oldText
Returns any removed text.
long nCharacters
Returns total number of characters.
long nSelections
Returns the number of active non-contiguous selections.
IA2TextSegment newText
Returns any inserted text.
long selection([in] long selectionIndex,[out] long startOffset)
Returns the character offsets of Nth active text selection.
A structure containing a substring and the start and end offsets in the enclosing string.