Update ooo320-m1
[ooovba.git] / offapi / com / sun / star / awt / grid / XGridSelection.idl
blob35c7d689b3abdad2a79cdf860c984175146fe4ce
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: XListBox.idl,v $
10 * $Revision: 1.8 $
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 ************************************************************************/
30 #ifndef __com_sun_star_awt_grid_XGridSelection_idl__
31 #define __com_sun_star_awt_grid_XGridSelection_idl__
33 #include <com/sun/star/uno/XInterface.idl>
34 #include <com/sun/star/awt/grid/XGridSelectionListener.idl>
35 #include <com/sun/star/view/SelectionType.idl>
37 //=============================================================================
39 module com { module sun { module star { module awt { module grid {
41 //=============================================================================
43 /** This interfaces provides access to the selection of row for <type>UnoControlGrid</type>.
44 */
45 interface XGridSelection: com::sun::star::uno::XInterface
47 /** Returns the lowest index of the selection.
48 @returns
49 the lowest index.
51 long getMinSelectionIndex();
53 /** Returns the highest index of the selection.
54 @returns
55 the highest index.
57 long getMaxSelectionIndex();
59 /** Adds a selection intervall.
60 @param start
61 the start row index.
62 @param length
63 the number of rows to be selected.
65 [oneway] void insertIndexIntervall( [in] long start, [in] long length);
67 /** Removes a selection intervall.
68 @param start
69 the start row index.
70 @param length
71 the number of rows to be selected.
73 [oneway] void removeIndexIntervall( [in] long start, [in] long length);
75 /** Returns the indicies of all selected rows.
76 @returns
77 a sequence of indicies.
79 sequence< long > getSelection();
81 /** Returns whether rows are selected.
82 @returns
83 <true/> if rows are selected otherwise <false/>.
85 boolean isSelectionEmpty();
87 /** Returns whether a specific row is selected.
88 @param
89 the index of a row.
90 @returns
91 <true/> if row are selected otherwise <false/>.
93 boolean isSelectedIndex( [in] long index);
95 /** Marks a row as selected.
96 @param
97 the index of a row.
99 [oneway] void selectRow( [in] long y);
102 [oneway] void selectColumn( [in] long x);
105 /** Adds a listener for the <type>GridSelectionEvent</type> posted after the grid changes.
106 @param Listener
107 the listener to add.
109 [oneway] void addSelectionListener( [in] XGridSelectionListener listener);
111 //-------------------------------------------------------------------------
113 /** Removes a listener previously added with <method>addSelectionListener()</method>.
114 @param Listener
115 the listener to remove.
117 [oneway] void removeSelectionListener( [in] XGridSelectionListener listener);
122 //=============================================================================
124 }; }; }; }; };
126 #endif