1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: LineDescriptor.idl,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #ifndef __com_sun_star_inspection_LineDescriptor_idl__
32 #define __com_sun_star_inspection_LineDescriptor_idl__
34 #ifndef com_sun_star_graphic_XGraphic_idl
35 #include
<com
/sun
/star
/graphic
/XGraphic.idl
>
38 //=============================================================================
39 module com
{ module sun
{ module star
{ module inspection
{
41 interface XPropertyControl
;
43 //-----------------------------------------------------------------------------
44 /** describes the appearance of a line representing a single property in an <type>ObjectInspector</type>.
46 Such a line consists of
47 <ul><li>a label with a human-readable name for the property</li>
48 <li>a control which is used for user interaction - i.e. it displays the current property
49 value, and allows the user entering a new one.</li>
50 <li>(optional) one or two buttons which, when clicked, can start a more complex, interactive
51 property value input. For instance, if you have a property whose value is a path in the
52 file system, such a button could be used to let the user browse for a path with a
53 usual file picker.</li>
56 @see XPropertyHandler::describePropertyLine
57 @see PropertyLineElement
63 /** denotes the human-readable display name used to present a property to the user
67 /** denotes the control which should be used to represent the property at the UI.
69 @see XPropertyControlFactory
71 XPropertyControl
Control;
73 /** specifies the URL to the help topic to be associated with the property
77 /** detetrmines whether a button exists which can be used for a more complex, interactive
80 <p>If no image for the primary button is specified, but a primary button is present,
81 the three dots will be displayed on the button.</p>
83 @see XPropertyHandler::onInteractivePropertySelection
84 @see HasSecondaryButton
85 @see PrimaryButtonImageURL
86 @see PrimaryButtonImage
88 boolean HasPrimaryButton
;
90 /** describes a unique id to associate with the primary button
92 <p>In OpenOffice.org, UI elements sometimes require a so-called UniqueID, which can be
93 used to uniquely (within the whole application) identify this UI element. For instance,
94 automating the OpenOffice.org UI via a dedicated separate application ("TestTool") requires
97 <p>If a primary button exists for a property's UI representation (<member>HasPrimaryButton</member>),
98 it gets the ID specified herein.</p>
100 long PrimaryButtonId
;
102 /** describes the URL of an image to display on the primary button, if any.
104 <p>This URL will be used to obtain an actual <type scope="com::sun::star::graphic">XGraphic</type>
105 object from an <type scope="com::sun::star::graphic">GraphicProvider</type>.</p>
107 <p>The property will be ignored if <member>HasPrimaryButton</member> is <FALSE/>.</p>
109 <p>If you need to specify a graphic which does not have an URL, but is available as
110 <type scope="com::sun::star::graphic">XGraphic</type> only, then you must leave
111 <code>PrimaryButtonImageURL</code> empty, and use the <member>PrimaryButtonImage</member> property.
113 @see PrimaryButtonImage
115 string PrimaryButtonImageURL
;
117 /** describes a graphics to display at the primary button, if any.
119 <p>The property will be ignored if <member>HasPrimaryButton</member> is <FALSE/>, or
120 if <member>PrimaryButtonImageURL</member> is a non-empty string.</p>
122 @see HasPrimaryButton
123 @see PrimaryButtonImageURL
125 com
::sun
::star
::graphic
::XGraphic PrimaryButtonImage
;
127 /** detetrmines whether a secondary button exists which can be used for a more complex, interactive
128 property value input.
130 <p>A secondary button subordinated to the primary button. If no primary button exists
131 (<member>HasPrimaryButton</member>), this member is ignored.</p>
133 @see XPropertyHandler::onInteractivePropertySelection
134 @see HasSecondaryButton
136 boolean HasSecondaryButton
;
138 /** describes a unique id to associate with the primary button
140 <p>If a secondary button exists for a property's UI representation (<member>HasSecondaryButton</member>),
141 it gets the ID specified herein.</p>
145 long SecondaryButtonId
;
147 /** describes the URL of an image to display on the secondary button, if any.
149 <p>This URL will be used to obtain an actual <type scope="com::sun::star::graphic">XGraphic</type>
150 object from an <type scope="com::sun::star::graphic">GraphicProvider</type>.</p>
152 <p>The property will be ignored if <member>HasSecondaryButton</member> is <FALSE/>.</p>
154 <p>If you need to specify a graphic which does not have an URL, but is available as
155 <type scope="com::sun::star::graphic">XGraphic</type> only, then you must leave
156 <code>SecondaryButtonImageURL</code> empty, and use the <member>SecondaryButtonImage</member> property.
158 @see SecondaryButtonImage
160 string SecondaryButtonImageURL
;
162 /** describes a graphics to display at the secondary button, if any.
164 <p>The property will be ignored if <member>HasSecondaryButton</member> is <FALSE/>, or
165 if <member>SecondaryButtonImageURL</member> is a non-empty string.</p>
167 @see HasSecondaryButton
168 @see SecondaryButtonImageURL
170 com
::sun
::star
::graphic
::XGraphic SecondaryButtonImage
;
172 /** describes the indent level for the property
174 <p>If a given property semantically depends on another one, the indent level
175 can be used to visually represent this fact. For this, the dependent property's
176 indent level would be one larger than the indent level of the other property.</p>
178 <p>Normally, <type>XPropertyHandler</type>s will set this to <code>0</code> when describing
179 the UI for a normal property.
183 /** describes the category into which the property should be sorted by the <type>ObjectInspector</type>.
185 <p>An <type>ObjectInspector</type> can visually group properties which semantically belong
186 together (for instance using tab pages). The decision which properties actually belong together
187 is made using this <member>Category</member> attribute.</p>
189 <p>For your implementation of <type>XPropertyHandler</type>, it's recommended that you document the programmatic
190 names used for property categories. This way, your handler might be re-used in
191 different contexts, where only the <type>XObjectInspectorModel</type> needs to provide consistent
192 UI names for the categories.</p>
194 @see XObjectInspectorModel::describeCategories
199 //=============================================================================