1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23
24#ifndef __com_sun_star_accessibility_XAccessibleTextAttributes_idl__
25#define __com_sun_star_accessibility_XAccessibleTextAttributes_idl__
26
27#ifndef __com_sun_star_lang_IndexOutOfBoundsException_idl__
28#include <com/sun/star/lang/IndexOutOfBoundsException.idl>
29#endif
30#ifndef __com_sun_star_beans_PropertyValue_idl__
31#include <com/sun/star/beans/PropertyValue.idl>
32#endif
33
34module com { module sun { module star { module accessibility {
35
36/** Implement this interface to give access to the attributes of a text.
37
38    @since OOo 2.0.4
39*/
40published interface XAccessibleTextAttributes
41{
42    /** Get the default attribute set for the text.
43
44        <p>Returns a set of all default paragraph and default character
45        attributes that are associated for the text. To prevent the method
46        from returning possibly large sets of attributes that the caller
47        is not interested in the caller can provide a list of attributes
48        that he wants to be returned.</p>
49
50        @param RequestedAttributes
51            This string sequence defines the set of attributes that the
52            caller is interested in. When there are requested attributes
53            that are not defined for the text then they are ignored.
54
55            <p>When the sequence is empty all attributes are returned.</p>
56
57        @return
58            Returns the requested attributes of the text. Each attribute
59            is represented by a <type scope="::com::sun::star::beans">PropertyValue</type>
60            object.
61    */
62    sequence<::com::sun::star::beans::PropertyValue>
63        getDefaultAttributes ( [in] sequence<string> RequestedAttributes );
64
65    /** Get the run attribute set for the specified position.
66
67        <p>Returns a set of character attributes that are associated for
68        the character at the given index and are directly set or are set
69        via a character style. To prevent the method from returning all of
70        these attributes the caller can provide a list of attributes
71        that he wants to be returned.</p>
72
73        @param Index
74            The index of the character for which to return its attributes.
75            The valid range is 0..length of text-1.
76
77        @param RequestedAttributes
78            This string sequence defines the set of attributes that the
79            caller is interested in. When there are requested attributes
80            that are not defined for the text then they are ignored.
81
82            <p>When the sequence is empty all attributes are returned.</p>
83
84        @return
85            Returns the requested attributes of the specified character.
86            Each attribute is represented by a
87            <type scope="::com::sun::star::beans">PropertyValue</type> object.
88
89        @throws ::com::sun::star::lang::IndexOutOfBoundsException
90            if the index is invalid
91    */
92    sequence<::com::sun::star::beans::PropertyValue>
93        getRunAttributes ( [in] long Index,
94                           [in] sequence<string> RequestedAttributes )
95        raises (::com::sun::star::lang::IndexOutOfBoundsException);
96
97};
98
99}; }; }; };
100
101#endif
102