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_awt_grid_UnoControlGridModel_idl__ 28#define __com_sun_star_awt_grid_UnoControlGridModel_idl__ 29 30#include <com/sun/star/awt/grid/XGridColumnModel.idl> 31#include <com/sun/star/awt/grid/XGridDataModel.idl> 32#include <com/sun/star/awt/UnoControlModel.idl> 33#include <com/sun/star/view/SelectionType.idl> 34#include <com/sun/star/awt/FontDescriptor.idl> 35#include <com/sun/star/style/VerticalAlignment.idl> 36#include <com/sun/star/util/Color.idl> 37 38//============================================================================= 39 40module com { module sun { module star { module awt { module grid { 41 42//============================================================================= 43 44/** specifies the standard model of a <type>UnoControlGrid</type> control. 45 46 @since OOo 3.3 47 */ 48published service UnoControlGridModel 49{ 50 /** specifies the standard model of an <type scope="com::sun::star::awt">UnoControl</type>. */ 51 service com::sun::star::awt::UnoControlModel; 52 53 /** Specifies whether the grid control should display a special header column. 54 55 <p>The default value is <FALSE/></p> 56 */ 57 [property] boolean ShowRowHeader; 58 59 /** specifies the width of the row header column, if applicable. 60 61 <p>The width is specified in application font units - see <type scope="com::sun::star::util">MeasureUnit</type>.</p> 62 63 <p>The value given here is ignored if <member>ShowRowHeader</member> is <FALSE/>.</p> 64 */ 65 [property] long RowHeaderWidth; 66 67 /** Specifies whether the grid control should display a title row. 68 69 <p>The default value is <TRUE/></p> 70 */ 71 [property] boolean ShowColumnHeader; 72 73 /** specifies the height of the column header row, if applicable. 74 75 <p>The height is specified in application font units - see <type scope="com::sun::star::util">MeasureUnit</type>.</p> 76 77 <p>The value given here is ignored if <member>ShowColumnHeader</member> is <FALSE/>.</p> 78 79 <p>If the property is <void/>, the grid control shall automatically determine a height which conveniently allows, 80 according to the used font, to display one line of text.</p> 81 */ 82 [property, maybevoid] long ColumnHeaderHeight; 83 84 /** Specifies the height of rows in the grid control. 85 86 <p>The height is specified in application font units - see <type scope="com::sun::star::util">MeasureUnit</type>.</p> 87 */ 88 [property, maybevoid] long RowHeight; 89 90 /** Specifies the <type>XGridColumnModel</type> that is providing the column structure. 91 92 <p>You can implement your own instance of <type>XGridColumnModel</type> or use 93 the <type>DefaultGridColumnModel</type>. 94 95 <p>The column model is in the ownership of the grid model: When you set a new column model, or dispose 96 the grid model, then the (old) column model is disposed, too.</p> 97 98 <p>The default for this property is an empty instance of the <type>DefaultGridColumnModel</type>.</p> 99 */ 100 [property] XGridColumnModel ColumnModel; 101 102 /** Specifies the <type>XGridDataModel</type> that is providing the hierarchical data. 103 104 <p>You can implement your own instance of <type>XGridDataModel</type> or use 105 the <type>DefaultGridDataModel</type>. 106 107 <p>The data model is in the ownership of the grid model: When you set a new data model, or dispose 108 the grid model, then the (old) data model is disposed, too.</p> 109 110 <p>The default for this property is an empty instance of the <type>DefaultGridDataModel</type>.</p> 111 */ 112 [property] XGridDataModel GridDataModel; 113 114 /** Specifies the vertical scrollbar mode. 115 <p>The default value is <FALSE/></p> 116 */ 117 [property] boolean HScroll; 118 119 /** Specifies the horizontal scrollbar mode. 120 <p>The default value is <FALSE/></p> 121 */ 122 [property] boolean VScroll; 123 124 /** Specifies that the control can be reached with the TAB key. 125 */ 126 [property] boolean Tabstop; 127 128 /** Specifies the selection mode that is enabled for this grid control. 129 <p>The default value is <member scope="com::sun::star::view">SelectionType::SINGLE</member></p> 130 */ 131 [property] ::com::sun::star::view::SelectionType SelectionModel; 132 133 /** controls whether or not to paint horizontal and vertical lines between the grid cells. 134 135 @see GridLineColor 136 */ 137 [property] boolean UseGridLines; 138 139 /** specifies the color to be used when drawing lines between cells 140 141 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 142 depending on the control's style settings.</p> 143 144 @see UseGridLines 145 */ 146 [property, maybevoid] ::com::sun::star::util::Color GridLineColor; 147 148 /** specifies the color to be used when drawing the background of row or column headers 149 150 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 151 depending on the control's style settings.</p> 152 */ 153 [property, maybevoid] ::com::sun::star::util::Color HeaderBackgroundColor; 154 155 /** specifies the color to be used when drawing the text within row or column headers 156 157 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 158 depending on the control's style settings.</p> 159 */ 160 [property, maybevoid] ::com::sun::star::util::Color HeaderTextColor; 161 162 /** specifies the color to be used when drawing the background of selected cells, while the control has the focus. 163 164 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 165 depending on the control's style settings.</p> 166 */ 167 [property, maybevoid] ::com::sun::star::util::Color ActiveSelectionBackgroundColor; 168 169 /** specifies the color to be used when drawing the background of selected cells, while the control does not have 170 the focus. 171 172 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 173 depending on the control's style settings.</p> 174 */ 175 [property, maybevoid] ::com::sun::star::util::Color InactiveSelectionBackgroundColor; 176 177 /** specifies the color to be used when drawing the text of selected cells, while the control has the focus. 178 179 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 180 depending on the control's style settings.</p> 181 */ 182 [property, maybevoid] ::com::sun::star::util::Color ActiveSelectionTextColor; 183 184 /** specifies the color to be used when drawing the text of selected cells, while the control does not have 185 the focus. 186 187 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 188 depending on the control's style settings.</p> 189 */ 190 [property, maybevoid] ::com::sun::star::util::Color InactiveSelectionTextColor; 191 192 /** specifies the colors to be used as background for data rows. 193 194 <p>If this sequence is non-empty, the data rows will be rendered with alternating background colors: Assuming 195 the sequence has <code>n</code> elements, each row will use the background color as specified by its number's 196 remainder modulo <code>n</code>.</p> 197 198 <p>If this sequence is empty, all rows will use the same background color as the control as whole.</p> 199 200 <p>If this property has a value of <VOID/>, rows will be painted 201 in alternating background colors, every second row having a background color derived from the control's 202 selection color.</p> 203 */ 204 [property, maybevoid] sequence< ::com::sun::star::util::Color > RowBackgroundColors; 205 206 /** specifies the vertical alignment of the content in the control. 207 */ 208 [property] com::sun::star::style::VerticalAlignment VerticalAlign; 209 210 /** specifies the font attributes of the text in the control. 211 */ 212 [property] com::sun::star::awt::FontDescriptor FontDescriptor; 213 214 /** specifies the color to be used when drawing cell texts 215 216 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 217 depending on the control's style settings.</p> 218 */ 219 [property, maybevoid] ::com::sun::star::util::Color TextColor; 220 221 /** specifies the color to be used when drawing text lines (underlining and strikethrough) 222 223 <p>If this property has a value of <VOID/>, the grid control renderer will use some default color, 224 depending on the control's style settings.</p> 225 */ 226 [property, maybevoid] com::sun::star::util::Color TextLineColor; 227 228 /** specifies the <type scope="com::sun::star::text">FontEmphasis</type> 229 value of the text in the control. 230 */ 231 [property] short FontEmphasisMark; 232 233 /** specifies the <type scope="com::sun::star::text">FontRelief</type> 234 value of the text in the control. 235 */ 236 [property] short FontRelief; 237 238 /** specifies the help text of the control. 239 */ 240 [property] string HelpText; 241 242 /** specifies the help URL of the control. 243 */ 244 [property] string HelpURL; 245 246}; 247 248//============================================================================= 249 250}; }; }; }; }; 251 252#endif 253