merged tag ooo/OOO330_m14
[LibreOffice.git] / offapi / com / sun / star / text / XFlatParagraph.idl
blobd9e5143a860fef15c4f5f7d232157fa897990032
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * This file is part of OpenOffice.org.
11 * OpenOffice.org is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License version 3
13 * only, as published by the Free Software Foundation.
15 * OpenOffice.org is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Lesser General Public License version 3 for more details
19 * (a copy is included in the LICENSE file that accompanied this code).
21 * You should have received a copy of the GNU Lesser General Public License
22 * version 3 along with OpenOffice.org. If not, see
23 * <http://www.openoffice.org/license.html>
24 * for a copy of the LGPLv3 License.
26 ************************************************************************/
28 #ifndef __com_sun_star_text_XFlatParagraph_idl__
29 #define __com_sun_star_text_XFlatParagraph_idl__
31 #ifndef __com_sun_star_uno_XInterface_idl__
32 #include <com/sun/star/uno/XInterface.idl>
33 #endif
35 #ifndef __com_sun_star_lang_Locale_idl__
36 #include <com/sun/star/lang/Locale.idl>
37 #endif
39 #ifndef __com_sun_star_lang_IllegalArgumentException_idl__
40 #include <com/sun/star/lang/IllegalArgumentException.idl>
41 #endif
43 #ifndef __com_sun_star_beans_PropertyValue_idl__
44 #include <com/sun/star/beans/PropertyValue.idl>
45 #endif
47 #ifndef __com_sun_star_text_XTextMarkup_idl__
48 #include <com/sun/star/text/XTextMarkup.idl>
49 #endif
51 //=============================================================================
53 module com { module sun { module star { module text {
55 //=============================================================================
57 /** provides functionality to ...
59 @since OOo 3.0
62 interface XFlatParagraph: com::sun::star::text::XTextMarkup
65 //-------------------------------------------------------------------------
66 /** get the content of the paragraph
68 @returns
69 the content of the paragraph.
71 string getText();
73 //-------------------------------------------------------------------------
74 /** check whether the content has been modified
76 @returns
77 <TRUE/> if the content has been modified,
78 <FALSE/> otherwise.
80 boolean isModified();
82 //-------------------------------------------------------------------------
83 /** change the 'checked' flag of the respective text node, i.e., mark the
84 text node as 'processed'
86 @param nType
87 type, see <type>TextMarkupType</type>.
89 @param bVal
90 <TRUE/> the respective text node has been processed
91 <FALSE/> the respective text node needs to be processed again
92 later
94 void setChecked( [in] long nType, [in] boolean bVal );
96 //-------------------------------------------------------------------------
97 /** returns whether the respective text node has already been processed
99 @param nType
100 type, see <type>TextMarkupType</type>.
102 @returns
103 <TRUE/> if the respective text node has been checked
104 <FALSE/> otherwise.
106 boolean isChecked( [in] long nType );
108 //-------------------------------------------------------------------------
109 /** get the language of the specific text
111 @param nPos
112 start index of the text.
114 @param nLen
115 the length of the text.
117 @returns
118 the locale for the language identified.
119 If no language could be identified, the locale will be empty.
121 @throws IllegalArgumentException
122 when any argument is wrong.
124 com::sun::star::lang::Locale getLanguageOfText( [in] long nPos, [in] long nLen )
125 raises( com::sun::star::lang::IllegalArgumentException );
127 //-------------------------------------------------------------------------
128 /** get the single most probable language of the specific text,
129 especially after getLanguageOfText fails
131 @param nPos
132 start index of the text.
134 @param nLen
135 the length of the text.
137 @returns
138 the locale for the language identified.
140 @throws IllegalArgumentException
141 when any argument is wrong.
143 com::sun::star::lang::Locale getPrimaryLanguageOfText( [in] long nPos,
144 [in] long nLen )
145 raises( com::sun::star::lang::IllegalArgumentException );
147 //-------------------------------------------------------------------------
148 /** replace the specific text with new text.
150 @param nPos
151 start index of the text.
153 @param nLen
154 the length of the text.
156 @param nNewText
157 new text.
159 @param aAttributes
160 the given set of attributes e.g. Language
162 @throws IllegalArgumentException
163 when any argument is wrong.
165 void changeText( [in] long nPos, [in] long nLen, [in] string aNewText,
166 [in] sequence<::com::sun::star::beans::PropertyValue> aAttributes )
167 raises( com::sun::star::lang::IllegalArgumentException );
169 //-------------------------------------------------------------------------
170 /** replace the attributes of the specific text with the given set of attributes.
172 @param nPos
173 start index of the text.
175 @param nLen
176 the length of the text.
178 @param aAttributes
179 the given set of attributes e.g. Language.
181 @throws IllegalArgumentException
182 when any argument is wrong.
184 void changeAttributes( [in] long nPos, [in] long nLen,
185 [in] sequence<::com::sun::star::beans::PropertyValue> aAttributes )
186 raises( com::sun::star::lang::IllegalArgumentException );
188 //-------------------------------------------------------------------------
189 /** get a list of indexes that separate each two different languages
191 @returns
192 a list of indices.
194 sequence< long > getLanguagePortions();
197 //=============================================================================
199 }; }; }; };
201 #endif