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#ifndef __com_sun_star_text_Shape_idl__ 24#define __com_sun_star_text_Shape_idl__ 25 26#ifndef __com_sun_star_text_TextContent_idl__ 27#include <com/sun/star/text/TextContent.idl> 28#endif 29#ifndef __com_sun_star_text_XTextFrame_idl__ 30#include <com/sun/star/text/XTextFrame.idl> 31#endif 32#ifndef __com_sun_star_text_XTextRange_idl__ 33#include <com/sun/star/text/XTextRange.idl> 34#endif 35#ifndef __com_sun_star_drawing_Shape_idl__ 36#include <com/sun/star/drawing/Shape.idl> 37#endif 38#ifndef __com_sun_star_text_TextContentAnchorType_idl__ 39#include <com/sun/star/text/TextContentAnchorType.idl> 40#endif 41#ifndef __com_sun_star_text_WrapTextMode_idl__ 42#include <com/sun/star/text/WrapTextMode.idl> 43#endif 44 45//============================================================================= 46 47 module com { module sun { module star { module text { 48 49//============================================================================= 50 51/** specifies the service of shapes in a text document 52 */ 53published service Shape 54{ 55 service com::sun::star::drawing::Shape; 56 //------------------------------------------------------------------------- 57 /** contains the number of the page where the objects are anchored. 58 <p> The value is valid only if the 59 AnchorType is 60 <const>TextContentAnchorType::AT_PAGE</const>.</p> 61 */ 62 [property] short AnchorPageNo; 63 //------------------------------------------------------------------------- 64 /** contains the text frame the current frame is anchored to. 65 <p> The value is valid only if the 66 AnchorType is <const>TextContentAnchorType::AT_FRAME</const>.</p> 67 */ 68 [property] com::sun::star::text::XTextFrame AnchorFrame; 69 //------------------------------------------------------------------------- 70 /** specifies how the text content is attached to its surrounding 71 <type>Text</type>. 72 */ 73 [optional, property] com::sun::star::text::TextContentAnchorType AnchorType; 74 //------------------------------------------------------------------------- 75 /** determines the horizontal orientation of the object. 76 77 @see BaseFrame::HoriOrientation 78 */ 79 [property] short HoriOrient; 80 //------------------------------------------------------------------------- 81 /** contains the horizontal position of the object (1/100 mm). 82 <p> It is only valid if "HoriOrient" is HoriOrientation_NONE.</p> 83 */ 84 [property] long HoriOrientPosition; 85 86 //------------------------------------------------------------------------- 87 /** determines the environment of the object to which the orientation 88 is related. 89 90 @see BaseFrame::RelOrientation 91 */ 92 [property] short HoriOrientRelation; 93 94 //------------------------------------------------------------------------- 95 /** determines the vertical orientation of the object. 96 97 @see BaseFrame::VertOrientation 98 */ 99 [property] short VertOrient; 100 101 //------------------------------------------------------------------------- 102 /** contains the vertical position of the object (1/100 mm). 103 104 It is only valid if <member>TextEmbeddedObject::VertOrient</member> is 105 <const>VertOrientation::NONE</const>. 106 */ 107 [property] long VertOrientPosition; 108 109 //------------------------------------------------------------------------- 110 111 /** determines the environment of the object to which the orientation is related. 112 113 @see BaseFrame::RelOrientation 114 */ 115 [property] short VertOrientRelation; 116 //------------------------------------------------------------------------- 117 /** contains the left margin of the object. 118 */ 119 [property] long LeftMargin; 120 121 //------------------------------------------------------------------------- 122 /** contains the right margin of the object. 123 */ 124 [property] long RightMargin; 125 //------------------------------------------------------------------------- 126 127 /** contains the top margin of the object. 128 */ 129 [property] long TopMargin; 130 131 //------------------------------------------------------------------------- 132 /** contains the bottom margin of the object. 133 */ 134 [property] long BottomMargin; 135 //------------------------------------------------------------------------- 136 /** determines the type of the surrounding text. 137 138 @deprecated 139 */ 140 [property] com::sun::star::text::WrapTextMode Surround; 141 //------------------------------------------------------------------------- 142 /** determines if the text of the paragraph in which the object 143 is anchored, wraps around the object. 144 */ 145 [property] boolean SurroundAnchorOnly; 146 //------------------------------------------------------------------------- 147 148 /** determines if the text wraps around the contour of the object. 149 */ 150 [property] boolean SurroundContour; 151 //------------------------------------------------------------------------- 152 153 /** the text flows only around the contour of the object. 154 */ 155 [property] boolean ContourOutside; 156 //------------------------------------------------------------------------- 157 /** determines if the object is opaque or transparent for text. 158 */ 159 [property] boolean Opaque; 160 //------------------------------------------------------------------------- 161 /** contains a text range where the shape should be anchored to. 162 <p>There are two different ways to get newly created shapes into the 163 text document. One of them is to use the insertTextContent() method of 164 the <type scope="com::sun::star::text">XSimpleText</type>. The other is to call the add() 165 method of the <type scope="com::sun::star::drawing">XShapes</type> interface. 166 To be able to determine an anchor position for shape that are anchored at a certain 167 text position the property TextRange is used.</p> 168 169 <p>This property is used when the shape gets inserted/added 170 and becomes invalid after that.</p> 171 172 */ 173 [property] com::sun::star::text::XTextRange TextRange; 174 175 //------------------------------------------------------------------------- 176 /** determines the influence of the text wrap on the positioning of the 177 shape 178 179 <p>The value of this property is only evaluated for the positioning 180 of the shape, if the text document setting ConsiderTextWrapOnObjPos 181 is <TRUE/>. Valid values are given by <member>WrapInfluenceOnPosition</member></p> 182 183 @since OpenOffice 2.0 184 */ 185 [optional, property] short WrapInfluenceOnPosition; 186 187 //------------------------------------------------------------------------- 188 /** determines the transformation of the shape in horizontal left-to-right 189 layout 190 191 <p>This property is needed for the export of the OASIS Open Office 192 file format to the OpenOffice.org file format. It provides the 193 transformation property of the included service com::sun::star::drawing::Shape 194 converted to the horizontal left-to-right layout.</p> 195 196 @since OpenOffice 2.0 197 */ 198 [optional, readonly, property] com::sun::star::drawing::HomogenMatrix3 TransformationInHoriL2R; 199 //------------------------------------------------------------------------- 200 /** determines layout direction the position attributes of the shape 201 is given 202 203 <p>Valid values are given by <member>PositionLayoutDir</member></p> 204 205 @since OpenOffice 2.0 206 */ 207 [optional, property] short PositionLayoutDir; 208 //------------------------------------------------------------------------- 209 /** determines the start position of the shape in horizontal left-to-right 210 layout 211 212 <p>This property is needed for the export of the OASIS Open Office 213 file format to the OpenOffice.org file format. It provides the 214 start position property of the included service com::sun::star::drawing::Shape 215 converted to the horizontal left-to-right layout.</p> 216 217 @since OpenOffice 2.0 218 */ 219 [optional, readonly, property] com::sun::star::awt::Point StartPositionInHoriL2R; 220 //------------------------------------------------------------------------- 221 /** determines the end position of the shape in horizontal left-to-right 222 layout 223 224 <p>This property is needed for the export of the OASIS Open Office 225 file format to the OpenOffice.org file format. It provides the 226 end position property of the included service com::sun::star::drawing::Shape 227 converted to the horizontal left-to-right layout.</p> 228 229 @since OpenOffice 2.0 230 */ 231 [optional, readonly, property] com::sun::star::awt::Point EndPositionInHoriL2R; 232}; 233 234//============================================================================= 235 236}; }; }; }; 237 238#endif 239