1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 module com
{ module sun
{ module star
{ module ui
{
22 /** specifies a user interface configuration manager interface which
23 controls the structure of all customizable user interface
29 interface XUIConfigurationManager
: ::com
::sun
::star
::uno
::XInterface
31 /** resets the configuration manager to the default user interface
34 This means that all user interface configuration data of the
35 instance will be removed. A module based user interface
36 configuration manager removes user defined elements, but set all
37 other elements back to default. It is not possible to remove
38 default elements from a module user interface configuration
44 /** retrieves information about all user interface elements within
45 the user interface configuration manager.
48 makes it possible to narrow the result set to only one type
49 of user interface elements. If all user interface element
50 types should be returned com::sun::star::ui::UIElementType::UNKNOWN
54 returns all user interface elements within the user interface
55 configuration manager that meet the given ElementType
56 specification. <p>The following
57 com::sun::star::beans::PropertyValue entries
58 are defined inside the sequence for every user interface element.
60 <li><b>ResourceURL</b>specifies the unique resource URL for
61 the user interface element.</li>
62 <li><b>UIName</b>specifies the user interface name for the
63 user interface element. Not all user interface elements have
64 set UIName. At least menubars do not.</li>
70 sequence
< sequence
< com
::sun
::star
::beans
::PropertyValue
> > getUIElementsInfo
( [in] short ElementType
) raises
( com
::sun
::star
::lang
::IllegalArgumentException
);
72 /** creates an empty settings data container.
75 an empty user interface element settings data container, which
76 implements UIElementSettings.
78 ::com
::sun
::star
::container
::XIndexContainer createSettings
();
80 /** determines if the settings of a user interface element is part the
81 user interface configuration manager.
84 a resource URL which identifies the user interface element. A
85 resource URL must meet the following syntax:
86 "private:resource/$type/$name. It is only allowed to use ASCII
87 characters for type and name.
90 `TRUE` if settings have been found, otherwise `FALSE`.
92 boolean hasSettings
( [in] string ResourceURL
) raises
( com
::sun
::star
::lang
::IllegalArgumentException
);
94 /** retrieves the settings of a user interface element.
97 a resource URL which identifies the user interface element. A
98 resource URL must meet the following syntax:
99 "private:resource/$type/$name. It is only allowed to use ASCII
100 characters for type and name.
103 must be `TRUE` if the retrieved settings should be a writable.
104 Otherwise `FALSE` should be provided to get a shareable reference
105 to the settings data.
108 settings data of an existing user interface element, which
109 implements UIElementSettings. If the settings data
111 com::sun::star::container::NoSuchElementException
112 is thrown. If the \p ResourceURL is not valid or
113 describes an unknown type a
114 com::sun::star::lang::IllegalArgumentException
117 ::com
::sun
::star
::container
::XIndexAccess getSettings
( [in] string ResourceURL
, [in] boolean bWriteable
) raises
( com
::sun
::star
::container
::NoSuchElementException
, com
::sun
::star
::lang
::IllegalArgumentException
);
119 /** replaces the settings of a user interface element with new settings.
122 a resource URL which identifies the user interface element to
123 be replaced. If no element with the given resource URL exists a
124 com::sun::star::container::NoSuchElementException
128 the new settings data of an existing user interface element, which
129 implements UIElementSettings.
132 If the settings data cannot be found a
133 com::sun::star::container::NoSuchElementException
134 is thrown. If the \p ResourceURL is not valid or describes
136 com::sun::star::lang::IllegalArgumentException
137 is thrown. If the configuration manager is read-only a
138 com::sun::star::lang::IllegalAccessException is
142 void replaceSettings
( [in] string ResourceURL
, [in] ::com
::sun
::star
::container
::XIndexAccess aNewData
) raises
( com
::sun
::star
::container
::NoSuchElementException
, com
::sun
::star
::lang
::IllegalArgumentException
, com
::sun
::star
::lang
::IllegalAccessException
);
144 /** removes the settings of an existing user interface element.
147 a resource URL which identifies the user interface element settings
151 If the settings data cannot be found a
152 com::sun::star::container::NoSuchElementException is
153 thrown. If the \p ResourceURL is not valid or describes an
154 unknown type a com::sun::star::lang::IllegalArgumentException
155 is thrown. If the configuration manager is read-only a
156 com::sun::star::lang::IllegalAccessException is thrown.
159 void removeSettings
( [in] string ResourceURL
) raises
( com
::sun
::star
::container
::NoSuchElementException
, com
::sun
::star
::lang
::IllegalArgumentException
, com
::sun
::star
::lang
::IllegalAccessException
);
161 /** inserts the settings of a new user interface element.
163 @param NewResourceURL
164 a resource URL which identifies the new user interface element.
167 the settings data of the new user interface element, which implements
171 If the settings data is already present a
172 com::sun::star::container::ElementExistException
173 is thrown. If the \p NewResourceURL is not valid or describes
174 an unknown type a com::sun::star::lang::IllegalArgumentException
175 is thrown. If the configuration manager is read-only a
176 com::sun::star::lang::IllegalAccessException is thrown.
179 void insertSettings
( [in] string NewResourceURL
, [in] ::com
::sun
::star
::container
::XIndexAccess aNewData
) raises
( com
::sun
::star
::container
::ElementExistException
, com
::sun
::star
::lang
::IllegalArgumentException
, com
::sun
::star
::lang
::IllegalAccessException
);
181 /** retrieves the image manager from the user interface configuration
185 Every user interface configuration manager has one image manager
186 instance which controls all images of a module or document.
190 the image manager of the user interface configuration manager.
192 com
::sun
::star
::uno
::XInterface getImageManager
();
194 /** retrieves the keyboard short cut manager from the user interface
195 configuration manager.
198 Every user interface configuration manager has one keyboard short cut
199 manager instance which controls all short cuts of a module or document.
203 the short cut manager of the user interface configuration manager.
205 com
::sun
::star
::ui
::XAcceleratorConfiguration getShortCutManager
();
207 /** retrieves the events manager from the user interface configuration manager.
210 Every user interface configuration manager has one events manager
211 instance which controls the mapping of events to script URLs of a module
216 the events manager of the user interface configuration
217 manager, if one exists.
219 com
::sun
::star
::uno
::XInterface getEventsManager
();
225 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */