1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * OpenOffice.org - a multi-platform office productivity suite
10 * This file is part of OpenOffice.org.
12 * OpenOffice.org is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 3
14 * only, as published by the Free Software Foundation.
16 * OpenOffice.org is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License version 3 for more details
20 * (a copy is included in the LICENSE file that accompanied this code).
22 * You should have received a copy of the GNU Lesser General Public License
23 * version 3 along with OpenOffice.org. If not, see
24 * <http://www.openoffice.org/license.html>
25 * for a copy of the LGPLv3 License.
27 ************************************************************************/
28 #ifndef __com_sun_star_awt_XSimpleTabController_idl__
29 #define __com_sun_star_awt_XSimpleTabController_idl__
31 #include
<com
/sun
/star
/awt
/XTabListener.idl
>
32 #include
<com
/sun
/star
/uno
/XInterface.idl
>
33 #include
<com
/sun
/star
/lang
/IndexOutOfBoundsException.idl
>
34 #include
<com
/sun
/star
/beans
/NamedValue.idl
>
36 //=============================================================================
38 module com
{ module sun
{ module star
{ module awt
{
40 //=============================================================================
42 /** specifies the basic operations for a tab controller,
43 but does not require XControl as type of tabs.
45 interface XSimpleTabController
: com
::sun
::star
::uno
::XInterface
47 //-------------------------------------------------------------------------
48 /** create a new tab and return an unique ID,
49 which can be used further to address this tab by using other methods
53 an unique ID for this new tab.
57 //-------------------------------------------------------------------------
58 /** remove a tab with the given ID.
61 the ID of the tab, which should be removed.
63 @throws ::com::sun::star::lang::IndexOutOfBoundsException
64 if the specified ID isn't used inside this tab controller.
66 void removeTab
( [in] long ID )
67 raises
( com
::sun
::star
::lang
::IndexOutOfBoundsException
);
69 //-------------------------------------------------------------------------
70 /** change some properties of the specified tab.
72 @descr Such properties can be:
75 <td><b>Property</b></td>
77 <td><b>Description</b></td>
82 <td>the title of the tab, which is shown at the UI.</td>
87 <td>describe the order of this tab in relation to all other tabs inside this control.</td>
91 @attention Not all properties must be supported by all implementations of this interface.
92 Of course some important ones should be handled by every implementation ...
96 the ID of the tab, which should be changed.
98 @throws ::com::sun::star::lang::IndexOutOfBoundsException
99 if the specified ID isn't used inside this tab controller.
101 void setTabProps
( [in] long ID ,
102 [in] sequence
< com
::sun
::star
::beans
::NamedValue
> Properties
)
103 raises
( com
::sun
::star
::lang
::IndexOutOfBoundsException
);
105 //-------------------------------------------------------------------------
106 /** retrieve the set of properties for the specified tab.
111 @throws ::com::sun::star::lang::IndexOutOfBoundsException
112 if the specified ID isn't used inside this tab controller.
114 sequence
< com
::sun
::star
::beans
::NamedValue
> getTabProps
( [in] long ID )
115 raises
( com
::sun
::star
::lang
::IndexOutOfBoundsException
);
117 //-------------------------------------------------------------------------
118 /** activate the specified tab.
120 @descr The new tab will be activated and all listener will get an event describing this.
121 Of course there will be an event too, which notifies listener about the deactivation
122 of the last active tab.
125 the ID of the new active tab.
127 @throws ::com::sun::star::lang::IndexOutOfBoundsException
128 if the specified ID isn't used inside this tab controller.
130 void activateTab
( [in] long ID )
131 raises
( com
::sun
::star
::lang
::IndexOutOfBoundsException
);
133 //-------------------------------------------------------------------------
134 /** return the unique ID of the current active tab.
137 the ID of the active tab.
139 long getActiveTabID
();
141 //-------------------------------------------------------------------------
142 /** register listener for inserting/removing tabs and changing their properties.
145 the listener to register.
147 void addTabListener
( [in] XTabListener Listener
);
149 //-------------------------------------------------------------------------
150 /** unregister listener for inserting/removing tabs and changing their properties.
153 the listener to unregister.
155 void removeTabListener
( [in] XTabListener Listener
);
158 //=============================================================================
164 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */