Version 6.4.0.0.beta1, tag libreoffice-6.4.0.0.beta1
[LibreOffice.git] / winaccessibility / source / UAccCOM / AccText.cxx
blob7c646cdfc285e339f5d1037923c31ef3a8f0c4bf
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
20 #include "stdafx.h"
21 #include "AccText.h"
23 #if defined __clang__
24 #pragma clang diagnostic push
25 #pragma clang diagnostic ignored "-Wnon-virtual-dtor"
26 #endif
27 #include <UAccCOM.h>
28 #if defined __clang__
29 #pragma clang diagnostic pop
30 #endif
32 using namespace com::sun::star::accessibility;
33 using namespace com::sun::star::uno;
35 /**
36 * Get special selection.
37 * @param startOffset Start selection offset.
38 * @param endOffset End selection offset.
39 * @param success Variant to accept the result of if the method call is successful.
40 * @return Result.
42 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::addSelection(long startOffset, long endOffset)//, unsigned char * success)
45 return CAccTextBase::get_addSelection(startOffset, endOffset);//, success);
48 /**
49 * Get special attributes.
50 * @param offset Offset.
51 * @param startOffset Variant to accept start offset.
52 * @param endOffset Variant to accept end offset.
53 * @param textAttributes Variant to accept attributes.
54 * @return Result.
56 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_attributes(long offset, long * startOffset, long * endOffset, BSTR * textAttributes)
59 return CAccTextBase::get_attributes(offset, startOffset, endOffset, textAttributes);
62 /**
63 * Get caret position.
64 * @param offset Variant to accept caret offset.
65 * @return Result.
67 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_caretOffset(long * offset)
70 return CAccTextBase::get_caretOffset(offset);
73 /**
74 * Get character extents.
75 * @param offset Offset.
76 * @param x Variant to accept x position.
77 * @param y Variant to accept y position.
78 * @param width Variant to accept width.
79 * @param Height Variant to accept height.
80 * @return Result.
82 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_characterExtents(long offset, IA2CoordinateType coordType, long * x, long * y, long * width, long * height)
85 return CAccTextBase::get_characterExtents(offset, coordType, x, y, width, height);
88 /**
89 * Get selections count.
90 * @param nSelections Variant to accept selections count.
91 * @return Result.
93 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_nSelections(long * nSelections)
96 return CAccTextBase::get_nSelections(nSelections);
99 /**
100 * Get offset of some special point.
101 * @param x X position of one point.
102 * @param x Y position of one point.
103 * @param coordType Type.
104 * @param offset Variant to accept offset.
105 * @return Result.
108 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_offsetAtPoint(long x, long y, IA2CoordinateType coordType, long * offset)
111 return CAccTextBase::get_offsetAtPoint(x, y, coordType, offset);
115 * Get selection range.
116 * @param selection selection count.
117 * @param startOffset Variant to accept the start offset of special selection.
118 * @param endOffset Variant to accept the end offset of special selection.
119 * @return Result.
121 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_selection(long selection, long * startOffset, long * endOffset)
124 return CAccTextBase::get_selection(selection, startOffset, endOffset);
128 * Get special text.
129 * @param startOffset Start position of special range.
130 * @param endOffset End position of special range.
131 * @param text Variant to accept the text of special range.
132 * @return Result.
134 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_text(long startOffset, long endOffset, BSTR * text)
137 return CAccTextBase::get_text(startOffset, endOffset, text);
141 * Get special text before some position.
142 * @param offset Special position.
143 * @param boundaryType Boundary type.
144 * @param startOffset Variant to accept the start offset.
145 * @param endOffset Variant to accept the end offset.
146 * @param text Variant to accept the special text.
147 * @return Result.
149 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_textBeforeOffset(long offset, IA2TextBoundaryType boundaryType, long * startOffset, long * endOffset, BSTR * text)
152 return CAccTextBase::get_textBeforeOffset(offset, boundaryType,
153 startOffset, endOffset, text);
157 * Get special text after some position.
158 * @param offset Special position.
159 * @param boundaryType Boundary type.
160 * @param startOffset Variant to accept the start offset.
161 * @param endOffset Variant to accept the end offset.
162 * @param text Variant to accept the special text.
163 * @return Result.
165 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_textAfterOffset(long offset, IA2TextBoundaryType boundaryType, long * startOffset, long * endOffset, BSTR * text)
168 return CAccTextBase::get_textAfterOffset(offset, boundaryType,
169 startOffset, endOffset, text);
173 * Get special text at some position.
174 * @param offset Special position.
175 * @param boundaryType Boundary type.
176 * @param startOffset Variant to accept the start offset.
177 * @param endOffset Variant to accept the end offset.
178 * @param text Variant to accept the special text.
179 * @return Result.
181 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_textAtOffset(long offset, IA2TextBoundaryType boundaryType, long * startOffset, long * endOffset, BSTR * text)
184 return CAccTextBase::get_textAtOffset(offset, boundaryType,
185 startOffset, endOffset, text);
189 * Remove selection.
190 * @param selectionIndex Special selection index
191 * @param success Variant to accept the memthod called result.
192 * @return Result.
194 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::removeSelection(long selectionIndex)//, unsigned char * success)
197 return CAccTextBase::removeSelection(selectionIndex);//, success);
201 * Set caret position.
202 * @param offset Special position.
203 * @param success Variant to accept the memthod called result.
204 * @return Result.
206 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::setCaretOffset(long offset)
209 return CAccTextBase::setCaretOffset(offset);
213 * Set special selection.
214 * @param selectionIndex Special selection index.
215 * @param startOffset start position.
216 * @param endOffset end position.
217 * @param success Variant to accept the memthod called result.
218 * @return Result.
221 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::setSelection(long selectionIndex, long startOffset, long endOffset)
224 return CAccTextBase::setSelection(selectionIndex, startOffset,
225 endOffset);
229 * Get characters count.
230 * @param nCharacters Variant to accept the characters count.
231 * @return Result.
233 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_nCharacters(long * nCharacters)
236 return CAccTextBase::get_nCharacters(nCharacters);
239 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_newText( IA2TextSegment *newText)
241 return CAccTextBase::get_newText(newText);
244 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::get_oldText( IA2TextSegment *oldText)
246 return CAccTextBase::get_oldText(oldText);
250 * Scroll to special sub-string .
251 * @param startIndex Start index of sub string.
252 * @param endIndex End index of sub string.
253 * @return Result.
255 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::scrollSubstringToPoint(long startIndex, long endIndex,enum IA2CoordinateType coordinateType, long x, long y )
258 return CAccTextBase::scrollSubstringToPoint(startIndex, endIndex, coordinateType, x, y);
261 COM_DECLSPEC_NOTHROW STDMETHODIMP CAccText::scrollSubstringTo(long startIndex, long endIndex,enum IA2ScrollType scrollType)
264 return CAccTextBase::scrollSubstringTo(startIndex, endIndex,scrollType);
267 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */