Line data Source code
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_TEXTMARKUPHELPER_HXX
20 : #define INCLUDED_SW_SOURCE_CORE_ACCESS_TEXTMARKUPHELPER_HXX
21 :
22 : #include <sal/types.h>
23 : #include <com/sun/star/lang/IndexOutOfBoundsException.hpp>
24 : #include <com/sun/star/lang/IllegalArgumentException.hpp>
25 : #include <com/sun/star/uno/RuntimeException.hpp>
26 : #include <com/sun/star/uno/Sequence.h>
27 :
28 : namespace com { namespace sun { namespace star { namespace accessibility {
29 : struct TextSegment;
30 : } } } }
31 :
32 : class SwAccessiblePortionData;
33 : class SwTextNode;
34 : class SwWrongList; // #i108125#
35 : class SwTextMarkupHelper
36 : {
37 : public:
38 : SwTextMarkupHelper( const SwAccessiblePortionData& rPortionData,
39 : const SwTextNode& rTextNode );
40 : SwTextMarkupHelper( const SwAccessiblePortionData& rPortionData,
41 : const SwWrongList& rTextMarkupList ); // #i108125#
42 0 : ~SwTextMarkupHelper() {}
43 :
44 : sal_Int32 getTextMarkupCount( const sal_Int32 nTextMarkupType )
45 : throw (::com::sun::star::lang::IllegalArgumentException,
46 : ::com::sun::star::uno::RuntimeException);
47 :
48 : ::com::sun::star::accessibility::TextSegment getTextMarkup(
49 : const sal_Int32 nTextMarkupIndex,
50 : const sal_Int32 nTextMarkupType )
51 : throw (::com::sun::star::lang::IndexOutOfBoundsException,
52 : ::com::sun::star::lang::IllegalArgumentException,
53 : ::com::sun::star::uno::RuntimeException);
54 :
55 : ::com::sun::star::uno::Sequence< ::com::sun::star::accessibility::TextSegment >
56 : getTextMarkupAtIndex( const sal_Int32 nCharIndex,
57 : const sal_Int32 nTextMarkupType )
58 : throw (::com::sun::star::lang::IndexOutOfBoundsException,
59 : ::com::sun::star::lang::IllegalArgumentException,
60 : ::com::sun::star::uno::RuntimeException);
61 :
62 : private:
63 : SwTextMarkupHelper( const SwTextMarkupHelper& ) SAL_DELETED_FUNCTION;
64 : SwTextMarkupHelper& operator=( const SwTextMarkupHelper& ) SAL_DELETED_FUNCTION;
65 :
66 : const SwAccessiblePortionData& mrPortionData;
67 :
68 : // #i108125#
69 : const SwTextNode* mpTextNode;
70 : const SwWrongList* mpTextMarkupList;
71 : };
72 : #endif
73 :
74 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|