1/************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 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. 14 * 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). 20 * 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. 25 * 26 ************************************************************************/ 27#ifndef __com_sun_star_text_TextPortion_idl__ 28#define __com_sun_star_text_TextPortion_idl__ 29 30 31#ifndef __com_sun_star_beans_XTolerantMultiPropertySet_idl__ 32#include <com/sun/star/beans/XTolerantMultiPropertySet.idl> 33#endif 34 35#ifndef __com_sun_star_container_XContentEnumerationAccess_idl__ 36#include <com/sun/star/container/XContentEnumerationAccess.idl> 37#endif 38 39#ifndef __com_sun_star_text_TextRange_idl__ 40#include <com/sun/star/text/TextRange.idl> 41#endif 42 43#ifndef __com_sun_star_text_XTextContent_idl__ 44#include <com/sun/star/text/XTextContent.idl> 45#endif 46 47#ifndef __com_sun_star_text_XTextField_idl__ 48#include <com/sun/star/text/XTextField.idl> 49#endif 50 51#ifndef __com_sun_star_text_XFootnote_idl__ 52#include <com/sun/star/text/XFootnote.idl> 53#endif 54 55 56//============================================================================= 57 58module com { module sun { module star { module text { 59 60//============================================================================= 61/** A TextPortion is a piece of text within a paragraph that does not 62 contain changes of its attributes inside. 63 64 <p> 65 It is created by an enumeration implemented in a paragraph service. 66 It may be used to export the content of the paragraph to an external 67 document format. 68 </p> 69 70 @see com::sun::star::text::TextPortionEnumeration 71 @see com::sun::star::text::XTextPortionEnumeration 72*/ 73published service TextPortion 74{ 75 service ::com::sun::star::text::TextRange; 76 77 //------------------------------------------------------------------------- 78 /** contains text frames, graphic objects, embedded objects or 79 shapes that are anchored at or as character. 80 @see com.sun.star.text.TextFrame 81 @see com.sun.star.text.TextGraphicObject 82 */ 83 [optional] 84 interface ::com::sun::star::container::XContentEnumerationAccess; 85 86 //------------------------------------------------------------------------- 87 /** gives access to a sequence of properties. 88 @since OOo 2.0 89 */ 90 [optional] 91 interface ::com::sun::star::beans::XTolerantMultiPropertySet; 92 93 //------------------------------------------------------------------------- 94 /** contains the type of the text portion. 95 96 <p> Valid content type names are:</p> 97 <dl> 98 <dt>Text</dt><dd>string content</dd> 99 <dt>TextField</dt><dd>a text field</dd> 100 <dt>TextContent</dt><dd>text content - supplied via the 101 interface <type scope="com::sun::star::container"> 102 XContentEnumerationAccess</type></dd> 103 <dt>ControlCharacter</dt><dd>a control character</dd> 104 <dt>Footnote</dt><dd>a footnote or an endnote</dd> 105 <dt>ReferenceMark</dt><dd>a reference mark</dd> 106 <dt>DocumentIndexMark</dt><dd>a document index mark</dd> 107 <dt>Bookmark</dt><dd>a bookmark</dd> 108 <dt>Redline</dt><dd>a redline portion which is a result 109 of the change tracking feature</dd> 110 <dt>Ruby</dt><dd>a ruby attribute which is used in Asian text</dd> 111 <dt>Frame</dt><dd>a frame</dd> 112 <dt>SoftPageBreak</dt><dd>a soft page break</dd> 113 <dt>InContentMetadata</dt><dd>a text range with attached metadata</dd> 114 </dl> 115 <p>For Reference marks, document index marks, etc., 2 text portions 116 will be generated, one for the start position and one for the 117 end position.</p> 118 */ 119 [readonly, property] string TextPortionType; 120 121 //------------------------------------------------------------------------- 122 /** contains the control character of a text portion of type 123 ControlCharacter. 124 @deprecated type ControlCharacter no longer implemented 125 */ 126 [readonly, property] short ControlCharacter; 127 128 //------------------------------------------------------------------------- 129 /** contains the bookmark of a text portion of type Bookmark. */ 130 [optional, readonly, property] 131 ::com::sun::star::text::XTextContent Bookmark; 132 133 //------------------------------------------------------------------------- 134 /** contains the document index mark of a text portion of type 135 DocumentIndexMark. */ 136 [optional, readonly, property] 137 ::com::sun::star::text::XTextContent DocumentIndexMark; 138 139 //------------------------------------------------------------------------- 140 /** contains the bookmark of a text portion of type ReferenceMark. */ 141 [optional, readonly, property] 142 ::com::sun::star::text::XTextContent ReferenceMark; 143 144 //------------------------------------------------------------------------- 145 /** contains the footnote of a text portion of type Footnote. */ 146 [optional, readonly, property] 147 ::com::sun::star::text::XFootnote Footnote; 148 149 //------------------------------------------------------------------------- 150 /** contains the text field of a text portion of type TextField. */ 151 [optional, readonly, property] 152 ::com::sun::star::text::XTextField TextField; 153 154 //------------------------------------------------------------------------- 155 /** contains the text range of a text portion of type InContentMetadata. 156 @since OOo 3.2 157 */ 158 [optional, readonly, property] 159 ::com::sun::star::text::XTextContent InContentMetadata; 160 161 //------------------------------------------------------------------------- 162 /** contains whether the portion is a point only. */ 163 [optional, readonly, property] boolean IsCollapsed; 164 165 //------------------------------------------------------------------------- 166 /** contains whether the portion is the start of the portion. 167 168 <p>This is used for portions which are represented by 169 2 TextPortion objects (e.g., DocmentIndexMark).</p> 170 */ 171 [optional, readonly, property] boolean IsStart; 172 173}; 174 175//============================================================================= 176 177}; }; }; }; 178#endif 179