diff options
Diffstat (limited to 'offapi/com/sun/star/form')
175 files changed, 15241 insertions, 0 deletions
diff --git a/offapi/com/sun/star/form/DataAwareControlModel.idl b/offapi/com/sun/star/form/DataAwareControlModel.idl new file mode 100644 index 000000000000..d8d52376de8e --- /dev/null +++ b/offapi/com/sun/star/form/DataAwareControlModel.idl @@ -0,0 +1,195 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#define __com_sun_star_form_DataAwareControlModel_idl__ + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XBoundComponent_idl__ +#include <com/sun/star/form/XBoundComponent.idl> +#endif + +#ifndef __com_sun_star_form_XLoadListener_idl__ +#include <com/sun/star/form/XLoadListener.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + +#ifndef __com_sun_star_beans_XPropertySet_idl__ +#include <com/sun/star/beans/XPropertySet.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** is an abstract service for specialized <type>FormControlModel</type>s + which are data aware and thus can be bound to a data source. + + <p>The connection between a data-aware control model and a form which's data the + control should display is made by parentship relations. The parent of a data-aware + control model (see <type scope="com::sun::star::container">XChild</type>, inherited + via the <type>FormControlModel</type> and <type>FormComponent</type> services) has + always to be a <type scope="com::sun::star::form::component">DataForm</type>.</p> + */ +published service DataAwareControlModel +{ + service com::sun::star::form::FormControlModel; + + /** makes it possible to transfer the data of the model to the connected data field. + <p> + This interface is optional, if a component doesn't support it, it has to forward + the changes of it's value to the field it is connected to immediately (means whenever a user + interaction changes it's content). + </p> + */ + [optional] interface com::sun::star::form::XBoundComponent; + + + /** must be implemented in order to recognize when the containing form of the model connects + to its data source (loads its data). After loading the form, the model may bind to its + related field source.<br/> + This interface will seldom be used directly from outside. + */ + interface com::sun::star::form::XLoadListener; + + + /** Each <type>DataAwareControlModel</type> should be resettable for setting default values. + + <p>In the context of a control model which is data-aware, the semantics of <em>default value</em> + (see <type>XReset</type>) is as follows:<br/> + If (and only if) the control is valid bound to a column of it's <typee scope="com::sun::star::form::component">DataForm</type>, and the form + is not positioned on a new record (see <member scope="com::sun::star::sdb">RowSet::IsNew</member>), then + <member>XReset::reset</member> does not reset the model's value to it's default value, but uses the + underlying column value.<br/> + In all other cases, the model is reset to the default value as specified by the respective property.</p> + + <p>For an example, have a look at the <type scope="com::sun::star::form::component">TextField</type>. It inherites + the <member scope="com::sun::star::awt">UnoControlEditModel::Text</member> property from the underlying + service, and additionally specifies the <member scope="com::sun::star::form::component">TextField::DefaultText</member>. + </p> + + <p>In the context of a <type scope="com::sun::star::form::component">DataForm</type>, controls are + automatically reset when one of the following applies + <ul><li>The form is reset by invoking it's <type>XReset</type> interface.</li> + <li>The form moves to a new record.</li> + <li>The changes in the current record of the form are undone</li> + </ul> + </p> + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** specifies the name of the bound database field. + + <p>This property makes sense in the <em>context</em> of the control model only. Normally, a control model + is a child of a <type scope="com::sun::star::form::component">DataForm</type>, which is bound + to a higher level object such as a table or query - more general, a result set.<br/> + This member here describes the column of this result set which the control should act for.</p> + + <p>Not every control model can be bound to every database column. Usually, super services of the + <type>DataAwareControlModel</type> restrict the column types they can be used with.</p> + + @see DataAwareControlModel::BoundField + */ + [property] string DataField; + + /** determines whether or not input into this field is required, when it is actually bound to a database field. + + <p>If this property is set to <FALSE/>, then the form runtime will not check the control/model for + <NULL/> values before submitting data to the database. Usually, if a control model is bound to + a database field which cannot be <NULL/>, and the model itself does not have a value, then the database + update is prevented, showing an error message to the user. To disable this behavior on a per-control + basis, use the <code>InputRequired</code> property.</p> + + @since OOo 3.1 + */ + [optional, property] boolean InputRequired; + + //------------------------------------------------------------------------- + + /** references to the cursor field to which the control is bound. + <p>Applies only if the form the control model belongs to is loaded and the control is valid bound. + The referenced field supports the <type scope="com::sun::star::sdb">Column</type> service. + </p> + @see DataAwareControlModel::DataField + */ + [readonly, property] com::sun::star::beans::XPropertySet BoundField; + + //------------------------------------------------------------------------- + + /** references to a control model within the same document which should be used as a label. + <p>Any user interface action which needs to refer to the control is assumed to use this + property. <br/> + A very common design method for forms is to group a data aware control with a label control, + with the latter describing the content of the former. For instance, you may have a + <type scope="com::sun::star::form::component">TextField</type>, which is bound to the e-mail + column of your data source. Then you will probably add a + <type scope="com::sun::star::form::component">FixedText</type> which's label is "E-Mail", + and associate it with the TextField by setting it as <member>LabelControl</member>.<br/> + Now if you imagine a component offering data search in a form, this component will examine + the <member>LabelControl</member> property, find the <type scope="com::sun::star::form::component">FixedText</type>, + examine it's label, and use this label to refer to the <type scope="com::sun::star::form::component">TextField</type>. + </p> + <p>When setting the property, a number of constraints apply: + <ul> + <li>The object which is to be set has to support the following interfaces + <ul><li><type scope="com::sun::star::awt">XControlModel</type></li> + <li><type scope="com::sun::star::lang">XServiceInfo</type></li> + <li><type scope="com::sun::star::beans">XPropertySet</type></li> + <li><type scope="com::sun::star::container">XChild</type></li> + </ul> + </il> + <li>It has to be a part of the same document as the model who's property is to be modified.</il> + <li>Additionally, the support of a special service, indicating that the model is of the right type, + is required. Which kind of service is in the request depends on the type of the control model.<br/> + + For instance, text fields (<type scope="com::sun::star::form::component">TextField</type>) can be + labelled by label controls only (<type scope="com::sun::star::form::component">FixedText</type>), + and radio buttons (<type scope="com::sun::star::form::component">RadioButton</type>) can be labelled + by group boxes (<type scope="com::sun::star::form::component">GroupBox</type>) only. + </li> + </ul> + </p> + */ + [property] com::sun::star::beans::XPropertySet LabelControl; + +}; + +//============================================================================= + +}; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/DataSelectionType.idl b/offapi/com/sun/star/form/DataSelectionType.idl new file mode 100644 index 000000000000..6633c63050d0 --- /dev/null +++ b/offapi/com/sun/star/form/DataSelectionType.idl @@ -0,0 +1,58 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_DataSelectionType_idl__ +#define __com_sun_star_form_DataSelectionType_idl__ + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +// DocMerge from xml: enum com::sun::star::form::DataSelectionType +/** describes the type of datasource used for a form. + <p>Please do <em><b>not</b></em> use anymore, this enum is deprecated. + @deprecated + */ +published enum DataSelectionType +{ + TABLE, + QUERY, + SQL, + SQLPASSTHROUGH + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/DatabaseDeleteEvent.idl b/offapi/com/sun/star/form/DatabaseDeleteEvent.idl new file mode 100644 index 000000000000..adad03001091 --- /dev/null +++ b/offapi/com/sun/star/form/DatabaseDeleteEvent.idl @@ -0,0 +1,55 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_DatabaseDeleteEvent_idl__ +#define __com_sun_star_form_DatabaseDeleteEvent_idl__ + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** is fired if a database record is going to be deleted. + <p>Please do <em><b>not</b></em> use anymore, this struct is deprecated. + @deprecated + */ +published struct DatabaseDeleteEvent: com::sun::star::lang::EventObject +{ + sequence<any> Bookmarks; + +}; + +//============================================================================= + +}; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/DatabaseParameterEvent.idl b/offapi/com/sun/star/form/DatabaseParameterEvent.idl new file mode 100644 index 000000000000..f933f612e345 --- /dev/null +++ b/offapi/com/sun/star/form/DatabaseParameterEvent.idl @@ -0,0 +1,70 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_DatabaseParameterEvent_idl__ +#define __com_sun_star_form_DatabaseParameterEvent_idl__ + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + +#ifndef __com_sun_star_container_XIndexAccess_idl__ +#include <com/sun/star/container/XIndexAccess.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** is fired if values for parameters are needed. + */ +published struct DatabaseParameterEvent: com::sun::star::lang::EventObject +{ + /** specifies the list of parameters which are required for opening a result set. + + <p>Usually, a <type scope="com::sun::star::form::component">DataForm</type> fires this + event when loading the form requires parameters to be filled in.</p> + + <p>Every parameter object supports the <type scope="com::sun::star::beans">XPropertySet</type> + interface, and at least the properties <em>Name</em> and <em>Value</em></p> + + @see com::sun::star::sdb::RowSet + @see com::sun::star::form::component::DataForm + */ + com::sun::star::container::XIndexAccess Parameters; +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/ErrorEvent.idl b/offapi/com/sun/star/form/ErrorEvent.idl new file mode 100644 index 000000000000..b5267df0c7b5 --- /dev/null +++ b/offapi/com/sun/star/form/ErrorEvent.idl @@ -0,0 +1,60 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_ErrorEvent_idl__ +#define __com_sun_star_form_ErrorEvent_idl__ + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +// DocMerge from xml: struct com::sun::star::form::ErrorEvent +/** occurs in case of fired database exceptions triggered by + a database form. + <p>Please do <em><b>not</b></em> use anymore, this struct is deprecated. + @deprecated + */ +published struct ErrorEvent: com::sun::star::lang::EventObject +{ + any Reason; + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/FormButtonType.idl b/offapi/com/sun/star/form/FormButtonType.idl new file mode 100644 index 000000000000..a1ef60487786 --- /dev/null +++ b/offapi/com/sun/star/form/FormButtonType.idl @@ -0,0 +1,77 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormButtonType_idl__ +#define __com_sun_star_form_FormButtonType_idl__ + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specifies the action to execute when a button is pressed. + @see com::sun::star::form::component::CommandButton + */ +published enum FormButtonType +{ + //------------------------------------------------------------------------- + + /** requires the button to act like a common push button, means no special action is triggered. + */ + PUSH, + + //------------------------------------------------------------------------- + + /** When the button is clicked, it performs a submit on its containing form. + */ + SUBMIT, + + //------------------------------------------------------------------------- + + /** When the button is clicked, it performs a reset on its containing form. + */ + RESET, + + //------------------------------------------------------------------------- + + /** When the button is clicked, an URL set for the button is opened. + @see com::sun::star::form::component::CommandButton::TargetURL + @see com::sun::star::form::component::CommandButton::TargetFrame + */ + URL + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/FormComponent.idl b/offapi/com/sun/star/form/FormComponent.idl new file mode 100644 index 000000000000..27bae9588631 --- /dev/null +++ b/offapi/com/sun/star/form/FormComponent.idl @@ -0,0 +1,129 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormComponent_idl__ +#define __com_sun_star_form_FormComponent_idl__ + +#ifndef __com_sun_star_form_XFormComponent_idl__ +#include <com/sun/star/form/XFormComponent.idl> +#endif +#ifndef __com_sun_star_lang_XComponent_idl__ +#include <com/sun/star/lang/XComponent.idl> +#endif +#ifndef __com_sun_star_container_XNamed_idl__ +#include <com/sun/star/container/XNamed.idl> +#endif +#ifndef __com_sun_star_beans_XPropertySet_idl__ +#include <com/sun/star/beans/XPropertySet.idl> +#endif +#ifndef __com_sun_star_io_XPersistObject_idl__ +#include <com/sun/star/io/XPersistObject.idl> +#endif +#ifndef __com_sun_star_beans_PropertyBag_idl__ +#include <com/sun/star/beans/PropertyBag.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specifies a component which can be part of a form. + + @see FormControlModel + @see com::sun::star::form::component::Form + */ +published service FormComponent +{ + /** identifies the component as a candidate for being part of a form. + <p>This interface also provides the access to the component's parent.</p> + */ + interface com::sun::star::form::XFormComponent; + + + /** allows life-time control of form components. + */ + interface com::sun::star::lang::XComponent; + + + /** Each FormComponent must supply a name for identification. + */ + interface com::sun::star::container::XNamed; + + /** gives access to the properties. + */ + interface com::sun::star::beans::XPropertySet; + + + /** Each FormComponent must be able to be stored into and read from a stream. + */ + interface com::sun::star::io::XPersistObject; + + /** allows to associate arbitrary properties with the form component + + <p>Every concrete form component - i.e. every service which includes + the <code>FormComponent</code> service - has a set of properties which + are available as long as the component lives - the so-called <em>static + properties</em>.</p> + + <p>Additionally, you can add more properties to the component as needed, + using the <type scope="com::sun::star::beans">XPropertyContainer</type> interface. + Those properties are called <em>dynamic properties</em>.</p> + + <p>Dynamic properties are not evaluated by the component itself, + nor by the form's runtime environment. They're only remembered and available for + use by other instances.</p> + + <p>Note that dynamic properties added to a form component are, by definition, + removeable. That is, the <member scope="com::sun::star::beans">PropertyAttribute::REMOVEABLE</member> + will always be set, even if you do not specify it in the + <member scope="com::sun::star::beans">XPropertyContainer::addProperty</member> call.</p> + + @since OpenOffice.org 2.3.0 + */ + [optional] service com::sun::star::beans::PropertyBag; + + //------------------------------------------------------------------------- + + /** the name of the component. + + <p>Note that the name accessed here is the same as when using the + <type scope="com::sun::star::container">XNamed</type> interface.</p> + */ + [property] string Name; + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/FormComponentType.idl b/offapi/com/sun/star/form/FormComponentType.idl new file mode 100644 index 000000000000..ac0655b3e42f --- /dev/null +++ b/offapi/com/sun/star/form/FormComponentType.idl @@ -0,0 +1,144 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormComponentType_idl__ +#define __com_sun_star_form_FormComponentType_idl__ + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** These constants specify the class types used to identify a component. + */ +published constants FormComponentType +{ + //------------------------------------------------------------------------- + + /** This generic identifier is for controls which cannot be identified by + an other specific identifier. + */ + const short CONTROL = 1; + + /** specifies a control that is used to begin, interrupt, or end a process. + */ + const short COMMANDBUTTON = 2; + + /** specifies a control that acts like a radio button. Grouped together, such radio buttons + present a set of two or more mutually exclusive choices to the user. + */ + const short RADIOBUTTON = 3; + + /** specifies a control that displays an image that responds to mouse clicks. + */ + const short IMAGEBUTTON = 4; + + /** specifies a control that is used to check or uncheck to turn an option on or off. + */ + const short CHECKBOX = 5; + + /** specifies a control that displays a list from which the user can select one or more items. + */ + const short LISTBOX = 6; + + /** specifies a control that is used when a list box combined with a static text control or an edit + control is needed. + */ + const short COMBOBOX = 7; + + /** specifies a control that displays a frame around a group of controls with or without a caption. + */ + const short GROUPBOX = 8; + + /** specifies a control that is a text component that allows for the editing of a single line of text. + */ + const short TEXTFIELD = 9; + + /** specifies a control to display a fixed text, usually used to label other controls. + */ + const short FIXEDTEXT = 10; + + /** is a table like control to display database data. + */ + const short GRIDCONTROL = 11; + + /** specifies an control which can be used to enter text, extended by an (user-startable) file dialog + to browse for files. + */ + const short FILECONTROL = 12; + + /** specifies a control that should not be visible. + */ + const short HIDDENCONTROL = 13; + + /** specifies a control to display an image. + */ + const short IMAGECONTROL = 14; + + /** specifies a control to display and edit a date value. + */ + const short DATEFIELD = 15; + + /** specifies a control to display and edit a time value. + */ + const short TIMEFIELD = 16; + + /** specifies a field to display and edit a numeric value. + */ + const short NUMERICFIELD = 17; + + /** specifies a field to display and edit a currency value. + */ + const short CURRENCYFIELD = 18; + + /** specifies a control to display and edit a string according to a pattern. + */ + const short PATTERNFIELD = 19; + + /** specifies a control to display and edit, in the form of a scrollbar, a value from a continuous value range + */ + const short SCROLLBAR = 20; + + /** specifies a control to edit, in the form of a spin field, a value from a continuous range of values + */ + const short SPINBUTTON = 21; + + /** specifies a control which provides controller functionality for the <type scope="com::sun::star::form::component">DataForm</type> + it belongs to, such as functionality to navigate or filter this form. + */ + const short NAVIGATIONBAR = 22; +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/FormComponents.idl b/offapi/com/sun/star/form/FormComponents.idl new file mode 100644 index 000000000000..475deb7659d3 --- /dev/null +++ b/offapi/com/sun/star/form/FormComponents.idl @@ -0,0 +1,107 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormComponents_idl__ +#define __com_sun_star_form_FormComponents_idl__ + +#ifndef __com_sun_star_container_XNameContainer_idl__ +#include <com/sun/star/container/XNameContainer.idl> +#endif + +#ifndef __com_sun_star_container_XIndexContainer_idl__ +#include <com/sun/star/container/XIndexContainer.idl> +#endif + +#ifndef __com_sun_star_container_XEnumerationAccess_idl__ +#include <com/sun/star/container/XEnumerationAccess.idl> +#endif + +#ifndef __com_sun_star_container_XContainer_idl__ +#include <com/sun/star/container/XContainer.idl> +#endif + +#include <com/sun/star/script/XEventAttacherManager.idl> + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specifies the capabilities of a collection of <type>FormComponent</type>s. + + <p>The collection must provide the possibility of adding and removing + components by name and by index. The name of a component is not + necessarily unique, so the collection must be able to handle duplicate + entry names.</p> + + @see FormComponent + */ +published service FormComponents +{ + /** allows to register listeners to be notified of changes in the container. + */ + interface com::sun::star::container::XContainer; + + /** allows to add/remove elements by name. + */ + interface com::sun::star::container::XNameContainer; + + /** gives access to the elements by index. + */ + interface com::sun::star::container::XIndexContainer; + + /** creates an enumeration of the elements. + */ + interface com::sun::star::container::XEnumerationAccess; + + /** This interface has to be implemented to supply the scripting environment + for the contained components. + + <p>The interface allows managing of scripts associated with dependent components, accessed by index. + However, as a client of the <type>FormComponents</type> service, there's no need to bother with + the container aspect of the <type scope="com::sun::star::script">XEventAttacherManager</type> + directly. A <type>FormComponents</type> container will automatically synchronize the elements + you put into it with the scripting information obtained at the + <type scope="com::sun::star::script">XEventAttacherManager</type> interface.</p> + + <p>For instance, at any time you can obtain the events associated with the <code>n</code><super>th</super> + element in the form components by calling + <member scope="com::sun::star::script">XEventAttacherManager::getScriptEvents</member> + with paramter <code>n</code>. In particular, this invariant is always met, even after you + inserted/removed elements into/from the container.</p> + */ + interface com::sun::star::script::XEventAttacherManager; +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/FormControlModel.idl b/offapi/com/sun/star/form/FormControlModel.idl new file mode 100644 index 000000000000..c0cbc6051a75 --- /dev/null +++ b/offapi/com/sun/star/form/FormControlModel.idl @@ -0,0 +1,110 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormControlModel_idl__ +#define __com_sun_star_form_FormControlModel_idl__ + +#ifndef __com_sun_star_awt_UnoControlModel_idl__ +#include <com/sun/star/awt/UnoControlModel.idl> +#endif + +#ifndef __com_sun_star_form_FormComponent_idl__ +#include <com/sun/star/form/FormComponent.idl> +#endif + +#ifndef __com_sun_star_beans_XFastPropertySet_idl__ +#include <com/sun/star/beans/XFastPropertySet.idl> +#endif + +#ifndef __com_sun_star_beans_XPropertyState_idl__ +#include <com/sun/star/beans/XPropertyState.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specifies a control model within a form. + + <p>Note that the model-view-paradigm is used for form controls, too.</p> + */ +published service FormControlModel +{ + service com::sun::star::awt::UnoControlModel; + + service com::sun::star::form::FormComponent; + + /** This optional interface gives an efficient access to all + properties at once or an ability to set more than one property at once. + */ + [optional] interface com::sun::star::beans::XFastPropertySet; + + + /** This optional interface gives access to the state of the + properties, e.g. whether a default value + is to be used or not for a certain property. + */ + [optional] interface com::sun::star::beans::XPropertyState; + + //------------------------------------------------------------------------- + + /** specifies the ID for classification of the component. + @see FormComponentType + */ + [readonly, property] short ClassId; + + //------------------------------------------------------------------------- + + /** determines the relative taborder of the control associated with the model. + + <p>The default -1 is used to indicate that the tab-order of this control should be + determined automatically.</p> + + <p>Each component which supports a tabstop must provide a + <member>FormControlModel::TabIndex</member> property.</p> + + <p>Normally, a <type>FormController</type> instance is evaluating this property.</p> + */ + [optional, property] short TabIndex; + + //------------------------------------------------------------------------- + + /** used for additional information. + <p>No semantics is given for this property, it will usually be used by the creator of a document + containing form controls.</p> + */ + [property] string Tag; + +}; + +//============================================================================= + +}; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/FormController.idl b/offapi/com/sun/star/form/FormController.idl new file mode 100644 index 000000000000..f14fd5181355 --- /dev/null +++ b/offapi/com/sun/star/form/FormController.idl @@ -0,0 +1,114 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormController_idl__ +#define __com_sun_star_form_FormController_idl__ + +#ifndef __com_sun_star_form_XFormController_idl__ +#include <com/sun/star/form/XFormController.idl> +#endif + +#ifndef __com_sun_star_awt_XTabController_idl__ +#include <com/sun/star/awt/XTabController.idl> +#endif + +#ifndef __com_sun_star_container_XChild_idl__ +#include <com/sun/star/container/XChild.idl> +#endif + +#ifndef __com_sun_star_lang_XComponent_idl__ +#include <com/sun/star/lang/XComponent.idl> +#endif + +#ifndef __com_sun_star_container_XEnumerationAccess_idl__ +#include <com/sun/star/container/XEnumerationAccess.idl> +#endif + +#ifndef __com_sun_star_util_XModifyBroadcaster_idl__ +#include <com/sun/star/util/XModifyBroadcaster.idl> +#endif + +#ifndef __com_sun_star_form_XConfirmDeleteBroadcaster_idl__ +#include <com/sun/star/form/XConfirmDeleteBroadcaster.idl> +#endif + +#ifndef __com_sun_star_sdb_XSQLErrorBroadcaster_idl__ +#include <com/sun/star/sdb/XSQLErrorBroadcaster.idl> +#endif + +#ifndef __com_sun_star_sdb_XRowSetApproveBroadcaster_idl__ +#include <com/sun/star/sdb/XRowSetApproveBroadcaster.idl> +#endif + +#ifndef __com_sun_star_form_XDatabaseParameterBroadcaster_idl__ +#include <com/sun/star/form/XDatabaseParameterBroadcaster.idl> +#endif + +#ifndef __com_sun_star_form_FormControllerDispatcher_idl__ +#include <com/sun/star/form/FormControllerDispatcher.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { + +module runtime { + published interface XFormOperations; +}; + +//============================================================================= + +/** is superseded by <type scope="com::sun::star::form::runtime">FormController</type>. + @deprecated +*/ +published service FormController +{ + [optional] service FormControllerDispatcher; + [optional, property] ::com::sun::star::form::runtime::XFormOperations FormOperations; + + /** is used for notifying the (de)activation of the controller. + */ + interface com::sun::star::form::XFormController; + + interface com::sun::star::awt::XTabController; + interface com::sun::star::container::XChild; + interface com::sun::star::lang::XComponent; + interface com::sun::star::container::XEnumerationAccess; + interface com::sun::star::util::XModifyBroadcaster; + interface com::sun::star::form::XConfirmDeleteBroadcaster; + interface com::sun::star::sdb::XSQLErrorBroadcaster; + interface com::sun::star::sdb::XRowSetApproveBroadcaster; + interface com::sun::star::form::XDatabaseParameterBroadcaster; +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/FormControllerDispatcher.idl b/offapi/com/sun/star/form/FormControllerDispatcher.idl new file mode 100644 index 000000000000..e277f95c9949 --- /dev/null +++ b/offapi/com/sun/star/form/FormControllerDispatcher.idl @@ -0,0 +1,57 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormControllerDispatcher_idl__ +#define __com_sun_star_form_FormControllerDispatcher_idl__ + +#ifndef __com_sun_star_frame_XDispatchProvider_idl__ +#include <com/sun/star/frame/XDispatchProvider.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { + +//============================================================================= + +/** is not used anymore, and superseded by <type scope="com::sun::star::form::runtime">FormController</type> and + <type scope="com::sun::star::form::runtime">FormOperations</type>. + + @deprecated + */ +published service FormControllerDispatcher +{ + [optional] interface com::sun::star::frame::XDispatchProvider; +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/FormSubmitEncoding.idl b/offapi/com/sun/star/form/FormSubmitEncoding.idl new file mode 100644 index 000000000000..6fc95e8d5747 --- /dev/null +++ b/offapi/com/sun/star/form/FormSubmitEncoding.idl @@ -0,0 +1,71 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormSubmitEncoding_idl__ +#define __com_sun_star_form_FormSubmitEncoding_idl__ + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specify the MIME encoding to be used when form data is submitted. + */ +published enum FormSubmitEncoding +{ + //------------------------------------------------------------------------- + /** Specifies to use "application/x-www-form-urlencoded" as submit encoding. + <p>Usually used if the FormSubmitMethod attribute has the value POST. + </p> + */ + URL, + + //------------------------------------------------------------------------- + + /** Specifies to use "multipart/form-data" as submit encoding. + <p>Usually used when the form contains a file upload element.</p> + */ + MULTIPART, + + //------------------------------------------------------------------------- + + /** specifies to use "text/plain" + <p>Usually used if the FormSubmitMethod attribute has the value POST and + the content should be reviewed as full text.</p> + */ + TEXT +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/FormSubmitMethod.idl b/offapi/com/sun/star/form/FormSubmitMethod.idl new file mode 100644 index 000000000000..a002dc32d990 --- /dev/null +++ b/offapi/com/sun/star/form/FormSubmitMethod.idl @@ -0,0 +1,63 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_FormSubmitMethod_idl__ +#define __com_sun_star_form_FormSubmitMethod_idl__ + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specifies how information is sent to a program invoked by submitting a form. + */ +published enum FormSubmitMethod +{ + //------------------------------------------------------------------------- + + /** specifies to append the input information of a form to the target + URL as parameters. + */ + GET, + + //------------------------------------------------------------------------- + + /** speficies to send the input information in a data body. + */ + POST + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/Forms.idl b/offapi/com/sun/star/form/Forms.idl new file mode 100644 index 000000000000..533113d4aafd --- /dev/null +++ b/offapi/com/sun/star/form/Forms.idl @@ -0,0 +1,72 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_Forms_idl__ +#define __com_sun_star_form_Forms_idl__ + +#ifndef __com_sun_star_container_XNameContainer_idl__ +#include <com/sun/star/container/XNameContainer.idl> +#endif + +#ifndef __com_sun_star_container_XIndexContainer_idl__ +#include <com/sun/star/container/XIndexContainer.idl> +#endif + +#ifndef __com_sun_star_container_XEnumerationAccess_idl__ +#include <com/sun/star/container/XEnumerationAccess.idl> +#endif + +#ifndef __com_sun_star_form_FormComponents_idl__ +#include <com/sun/star/form/FormComponents.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specifies the capabilities of a collection of forms. + + <p>Basically, a <type>Forms</type> is a <type>FormComponents</type>, + with the additional restriction that the contained elements support the + <type scope="com::sun::star::form::component">Form</type> service.</p> + + @see com::sun::star::form::component::Form + */ +published service Forms +{ + service FormComponents; +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/ListSourceType.idl b/offapi/com/sun/star/form/ListSourceType.idl new file mode 100644 index 000000000000..9953b3b31c81 --- /dev/null +++ b/offapi/com/sun/star/form/ListSourceType.idl @@ -0,0 +1,89 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_ListSourceType_idl__ +#define __com_sun_star_form_ListSourceType_idl__ + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** describes the kind of data source used to fill the list data of a listbox or a combobox control. + @see com::sun::star::form::component::ListBox + @see com::sun::star::form::component::ComboBox + */ +published enum ListSourceType +{ + //------------------------------------------------------------------------- + + /** The control should be filled with a list of string values. + */ + VALUELIST, + + //------------------------------------------------------------------------- + + /** The control should be filled with the data of a table. + */ + TABLE, + + //------------------------------------------------------------------------- + + /** The control should be filled with the results of a database query. + */ + QUERY, + + //------------------------------------------------------------------------- + + /** The control should be filled with the results of a database statement. + */ + SQL, + + //------------------------------------------------------------------------- + + /** The control should be filled with the results of a database statement, + which is not evaluated by the database engine. + */ + SQLPASSTHROUGH, + + //------------------------------------------------------------------------- + + /** The control should be filled with the field names of a database table. + */ + TABLEFIELDS + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/NavigationBarMode.idl b/offapi/com/sun/star/form/NavigationBarMode.idl new file mode 100644 index 000000000000..35cd358e9538 --- /dev/null +++ b/offapi/com/sun/star/form/NavigationBarMode.idl @@ -0,0 +1,83 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_NavigationBarMode_idl__ +#define __com_sun_star_form_NavigationBarMode_idl__ + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** describes in which way the navigation of the records of a database form is performed. + */ +published enum NavigationBarMode +{ + //------------------------------------------------------------------------- + + /** no navigation bar is provided and navigation on the current + form is only possible with the keyboard (TAB/SHIFT TAB). + + <p>Note that when this mode is set, a simultaneous <type>TabulatorCycle</type> + value of <member>TabulatorCycle::CURRENT</member> means that you cannot travel + between records anymore.</p> + + @see TabulatorCycle + */ + NONE, + + //------------------------------------------------------------------------- + + /** a navigation bar is provided and navigation will be performed + on the current/active form. + <p>This is the default and most often encountered mode.</p> + */ + CURRENT, + + //------------------------------------------------------------------------- + + /** a navigation bar is provided and navigation will be performed + on the parent of the current/active form. + + <p>This options is usually used for forms containing an grid control only. + In such a form, the control has it's own navigation elements, so there is + no need to use the navigation bar for the form, but rather for it's parent. + </p> + */ + PARENT + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/PropertyBrowserController.idl b/offapi/com/sun/star/form/PropertyBrowserController.idl new file mode 100644 index 000000000000..52e50979654f --- /dev/null +++ b/offapi/com/sun/star/form/PropertyBrowserController.idl @@ -0,0 +1,147 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_PropertyBrowserController_idl__ +#define __com_sun_star_form_PropertyBrowserController_idl__ + +#ifndef __com_sun_star_frame_XController_idl__ +#include <com/sun/star/frame/XController.idl> +#endif + +#ifndef __com_sun_star_beans_XPropertySet_idl__ +#include <com/sun/star/beans/XPropertySet.idl> +#endif + +#ifndef __com_sun_star_beans_XFastPropertySet_idl__ +#include <com/sun/star/beans/XFastPropertySet.idl> +#endif + +#ifndef __com_sun_star_beans_XMultiPropertySet_idl__ +#include <com/sun/star/beans/XMultiPropertySet.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** describes a controller which can be used to browse and modify properties of form controls. + + <p>The controller can be plugged into an <type scope="com::sun::star::frame">XFrame</type>, and will + provide a visual component for inspecting control properties. This means it allows to interactively control + several aspects of a <type>FormControlModel</type> or <type>DataAwareControlModel</type>, such as it's + data binding, it's layout, and it's event binding</p> + + <p>For using a PropertyBrowserController, you need to + <ul><li>instatiate it at a service factory of your choice</li> + <li>attach it to an empty frame of your choice</li> + <li>set the IntrospectedObject property to the control model which you wish to analyze</li> + </ul> + </p> + + @example Java + <listing> + XFrame xFrame = getNewEmptyFrame(); + XMultiServiceFactory xORB = getORB(); + XPropertySet xControlModel = getMyControlModel(); + + // instantiate the controller + XController xController = (XController)UnoRuntime.queryInterface( XController.class, + xORB.createInstance( "com.sun.star.form.PropertyBrowserController" ) ); + + // marry the controller and the frame. This will cause the controller + // to create a visual component within the frame to inspect our object + xController.attachFrame( xFrame ) + + // tell the controller which object to inspect + XPropertySet xControllerProps = (XPropertySet)UnoRuntime.queryInterface( + XPropertySet.class, xController ); + + xControllerProps.setPropertyValue( "IntrospectedObject", xControlModel ); + </listing> + + @see com::sun::star::frame::XController + + @deprecated + <p>Note that nowadays, this service is only a legacy wrapper using the + <type scope="com::sun::star::inspection">ObjectInspector</type> and the + <type scope="com::sun::star::form::inspection">DefaultFormComponentInspectorModel</type> services, and knitting them together.</p> + +*/ +published service PropertyBrowserController +{ + /** contains the object to inspect. + + <p>Changing this property from outside causes the controller to update it's view + with the data of the new object</p> + */ + [property] com::sun::star::beans::XPropertySet IntrospectedObject; + + /** controls the actually visible page. + + <p>The aspects of a <type>DataAwareControlModel</type> which can be browsed and modified + using this controller can be separated into 3 groups: common aspects, data-awareness + related aspects, and bound events.</br> + The appearance of the visual component created by the controller is that 3 tab pages, one for + each group, are displayed (of course if the control does not support any aspects of a given group, + the group is omitted).<br/> + With this property, it can be controller which page is currently acticve.</p> + + <p>Valid values are (this list may be extended in the future): + <ul><li>Generic</li> + <li>Data</li> + <li>Events</li> + <ul></p> + */ + [property] string CurrentPage; + + /** ensures the basic functionality for a controller. + + <p>With supporting this interface, the component is able to operate in (and provide content + for) an <type scope="com::sun::star::frame">XFrame</type>.</p> + */ + interface com::sun::star::frame::XController; + + /** allows to access the properties of the object + */ + interface com::sun::star::beans::XPropertySet; + + /** allows to access the properties via indicies + */ + interface com::sun::star::beans::XFastPropertySet; + + /** allows to access more than one property of the object at the same time + */ + interface com::sun::star::beans::XMultiPropertySet; +}; + +//============================================================================= + +}; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/TabulatorCycle.idl b/offapi/com/sun/star/form/TabulatorCycle.idl new file mode 100644 index 000000000000..65da98a259bb --- /dev/null +++ b/offapi/com/sun/star/form/TabulatorCycle.idl @@ -0,0 +1,84 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_TabulatorCycle_idl__ +#define __com_sun_star_form_TabulatorCycle_idl__ + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specifies how the TAB key should be used in a form. + + <p>If the last control of a form is focused, and the user pressed the TAB key, there are + several possibilities how a <type>FormController</type> should handle this. + <type>TabulatorCycle</type> specifies these possibilities.</p> + + <p>Note that the <type>TabulatorCycle</type> determines what happens when SHIFT-TAB + is pressed on the <em>first</em> control of a form, as well as when TAB is pressed on the + <em>last</em> control.</p> + + <p><em>First</em> and <em>last</em> refers to the tabbing order of controls.</p> + + @see FormControlModel::TabIndex + @see FormController + */ +published enum TabulatorCycle +{ + //------------------------------------------------------------------------- + + /** pressing the TAB key from the last control moves the focus to + the first control in the tab order of the next record. + */ + RECORDS, + + //------------------------------------------------------------------------- + + /** pressing the TAB key from the last control moves the focus to + the first control in the tab order of the same record. + */ + CURRENT, + + //------------------------------------------------------------------------- + + /** pressing the TAB key from the last control of a form moves + the focus to the first control of the next form in the tab order. + */ + PAGE + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XApproveActionBroadcaster.idl b/offapi/com/sun/star/form/XApproveActionBroadcaster.idl new file mode 100644 index 000000000000..ef53896fd501 --- /dev/null +++ b/offapi/com/sun/star/form/XApproveActionBroadcaster.idl @@ -0,0 +1,81 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XApproveActionBroadcaster_idl__ +#define __com_sun_star_form_XApproveActionBroadcaster_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_form_XApproveActionListener_idl__ +#include <com/sun/star/form/XApproveActionListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** allows to probably veto actions to be performed on components. + + <p> Usually, a component which supports the + <type>XApproveActionBroadcaster</type> interface implements + <type scope="com::sun::star::awt">XActionListener</type> as well.</p> + */ +published interface XApproveActionBroadcaster: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** adds the specified listener to receive the <member>XApproveActionListener::approveAction</member> + event. + + @param aListener + the listener to be added + */ + [oneway] void addApproveActionListener( [in] com::sun::star::form::XApproveActionListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener + + @param aListener + the listener to be removed + */ + [oneway] void removeApproveActionListener( [in] com::sun::star::form::XApproveActionListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XApproveActionListener.idl b/offapi/com/sun/star/form/XApproveActionListener.idl new file mode 100644 index 000000000000..f35ef82ba509 --- /dev/null +++ b/offapi/com/sun/star/form/XApproveActionListener.idl @@ -0,0 +1,77 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XApproveActionListener_idl__ +#define __com_sun_star_form_XApproveActionListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** can be implemented to listen and probably veto actions to be performed on components. + + <p>An example for an action would be the click of a + CommandButton.</p> + + @see XApproveActionBroadcaster + @see com::sun::star::form::component::CommandButton + @see com::sun::star::form::control::CommandButton + */ +published interface XApproveActionListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when an action is performed. + + @param aEvent + A descriptor specifying the source of the event. + + @returns + <TRUE/> when the action is permitted, otherwise <FALSE/>. + */ + boolean approveAction( [in] com::sun::star::lang::EventObject aEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XBoundComponent.idl b/offapi/com/sun/star/form/XBoundComponent.idl new file mode 100644 index 000000000000..8a64b441f58a --- /dev/null +++ b/offapi/com/sun/star/form/XBoundComponent.idl @@ -0,0 +1,75 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XBoundComponent_idl__ +#define __com_sun_star_form_XBoundComponent_idl__ + +#ifndef __com_sun_star_form_XUpdateBroadcaster_idl__ +#include <com/sun/star/form/XUpdateBroadcaster.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** specifies a (form) component which is bound to a data source. + + <p>The interface provides the possibility of committing its respective + data to a data source it is bound to. A <member>commit</member> will be + performed by the environment (usually, a <type>FormController</type>).<br/> + For example, suppose you have a data-bound control that is connected + to a database field. Each time the control loses its focus, the + model (component) of the control is triggered by the environment + to store its value in the database field.</p> + + <p>A commit may fail if an <type>XUpdateListener</type> vetoes the it.</p> + + @see com::sun::star::form::XUpdateListener + */ +published interface XBoundComponent: com::sun::star::form::XUpdateBroadcaster +{ + //------------------------------------------------------------------------- + + /** commits the content of the component into the data source it is bound to. + + @returns + <TRUE/> when the commitment was successful, otherwise <FALSE/>. + */ + boolean commit(); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XBoundControl.idl b/offapi/com/sun/star/form/XBoundControl.idl new file mode 100644 index 000000000000..549e091ab1b5 --- /dev/null +++ b/offapi/com/sun/star/form/XBoundControl.idl @@ -0,0 +1,74 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XBoundControl_idl__ +#define __com_sun_star_form_XBoundControl_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** allows locking the input on components. + */ + +published interface XBoundControl: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** determines whether the input is currently locked or not. + + @returns + <TRUE/> when it is currently locked, otherwise <FALSE/>. + */ + boolean getLock(); + + //------------------------------------------------------------------------- + + /** is used for altering the current lock state of the + component. + + @param bLock + the new lock state. + */ + [oneway] void setLock( [in] boolean bLock ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XChangeBroadcaster.idl b/offapi/com/sun/star/form/XChangeBroadcaster.idl new file mode 100644 index 000000000000..e67f288c0433 --- /dev/null +++ b/offapi/com/sun/star/form/XChangeBroadcaster.idl @@ -0,0 +1,85 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XChangeBroadcaster_idl__ +#define __com_sun_star_form_XChangeBroadcaster_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_form_XChangeListener_idl__ +#include <com/sun/star/form/XChangeListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides functionality to notify listeners of data changes. + + <p>The concrete semantics of a change (i.e. the conditions for when a change event + is fired) must be specified in the service description of the providing service.</p> + + @see XChangeListener + */ +published interface XChangeBroadcaster: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** adds the specified listener to receive the "changed" event. + + @param aListener + the listener to add. + + @see com::sun::star::form::XChangeListener + */ + [oneway] void addChangeListener( [in] com::sun::star::form::XChangeListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener. + + @param aListener + the listener to remove. + + @see com::sun::star::form::XChangeListener + */ + [oneway] void removeChangeListener( [in] com::sun::star::form::XChangeListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XChangeListener.idl b/offapi/com/sun/star/form/XChangeListener.idl new file mode 100644 index 000000000000..2b817320fb75 --- /dev/null +++ b/offapi/com/sun/star/form/XChangeListener.idl @@ -0,0 +1,73 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XChangeListener_idl__ +#define __com_sun_star_form_XChangeListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** is the listener interface for receiving notifications about data changes. + + <p>The concrete semantics of a change (i.e. the conditions for when a change event + is fired) must be specified in the description of the service broadcasting the + change.</p> + + @see XChangeBroadcaster + */ +published interface XChangeListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when the data of a component has been changed. + + @param rEvent + A dedscriptor specifying the source of the event. + */ + [oneway] void changed( [in] com::sun::star::lang::EventObject rEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XConfirmDeleteBroadcaster.idl b/offapi/com/sun/star/form/XConfirmDeleteBroadcaster.idl new file mode 100644 index 000000000000..bf38373c2f49 --- /dev/null +++ b/offapi/com/sun/star/form/XConfirmDeleteBroadcaster.idl @@ -0,0 +1,86 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XConfirmDeleteBroadcaster_idl__ +#define __com_sun_star_form_XConfirmDeleteBroadcaster_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_form_XConfirmDeleteListener_idl__ +#include <com/sun/star/form/XConfirmDeleteListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides the possibility of receiving an event for confirming deletions of + rows in a <type scope="com::sun::star::form::component">DataForm</type>. + + @see XConfirmDeleteListener + */ +published interface XConfirmDeleteBroadcaster: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** remembers the specified listener to receive an event for confirming deletions + + <p><member>XConfirmDeleteListener::confirmDelete</member> is called before a + deletion is performed. You may use the event to write your own confirmation messages.</p> + + @param aListener + the listener to add. + + @see com::sun::star::form::XConfirmDeleteListener + */ + [oneway] void addConfirmDeleteListener( [in] com::sun::star::form::XConfirmDeleteListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener. + + @param aListener + the listener to remove. + + @see com::sun::star::form::XConfirmDeleteListener + */ + [oneway] void removeConfirmDeleteListener( [in] com::sun::star::form::XConfirmDeleteListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XConfirmDeleteListener.idl b/offapi/com/sun/star/form/XConfirmDeleteListener.idl new file mode 100644 index 000000000000..debd3db0265f --- /dev/null +++ b/offapi/com/sun/star/form/XConfirmDeleteListener.idl @@ -0,0 +1,71 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XConfirmDeleteListener_idl__ +#define __com_sun_star_form_XConfirmDeleteListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_sdb_RowChangeEvent_idl__ +#include <com/sun/star/sdb/RowChangeEvent.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** allows to register a component for confirming deletions of + rows in a <type scope="com::sun::star::form::component">DataForm</type>. + + @see XConfirmDeleteBroadcaster + */ +published interface XConfirmDeleteListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when the current record of a database form will be deleted. + + @param aEvent + A dedscriptor specifying the deletion request. + + @returns + <TRUE/> when the row caan be deleted, otherwise <FALSE/>. + */ + boolean confirmDelete( [in] com::sun::star::sdb::RowChangeEvent aEvent ); +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XDatabaseParameterBroadcaster.idl b/offapi/com/sun/star/form/XDatabaseParameterBroadcaster.idl new file mode 100644 index 000000000000..d73d1d4f9116 --- /dev/null +++ b/offapi/com/sun/star/form/XDatabaseParameterBroadcaster.idl @@ -0,0 +1,83 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XDatabaseParameterBroadcaster_idl__ +#define __com_sun_star_form_XDatabaseParameterBroadcaster_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_form_XDatabaseParameterListener_idl__ +#include <com/sun/star/form/XDatabaseParameterListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides the possibility of receiving an event for configuration of parameters. + <p>This interface is usually implemented by components which are to execute a statement, + and may need parameter information. For example, the + <type scope="com::sun::star::form::component">DataForm</type> is such a component. When it is + bound to a statement which contains parameters, or to a query which is based upon a parametrized + statement, it needs values to fill in the parameters with actual values when it is being loaded. + One method to gather these values is calling the <type>XDatabaseParameterListener</type> listeners, which + can fill them in.</p> + */ +published interface XDatabaseParameterBroadcaster: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** adds the specified listener, to allow it to fill in necessary parameter values. + @param aListener + the listener to add. + @see com::sun::star::form::XDatabaseParameterListener + */ + [oneway] void addParameterListener( [in] com::sun::star::form::XDatabaseParameterListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener. + @param aListener + the listener to remove. + @see com::sun::star::form::XDatabaseParameterListener + */ + [oneway] void removeParameterListener( [in] com::sun::star::form::XDatabaseParameterListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XDatabaseParameterBroadcaster2.idl b/offapi/com/sun/star/form/XDatabaseParameterBroadcaster2.idl new file mode 100644 index 000000000000..28448b136be9 --- /dev/null +++ b/offapi/com/sun/star/form/XDatabaseParameterBroadcaster2.idl @@ -0,0 +1,79 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XDatabaseParameterBroadcaster2_idl__ +#define __com_sun_star_form_XDatabaseParameterBroadcaster2_idl__ + +#ifndef __com_sun_star_form_XDatabaseParameterBroadcaster_idl__ +#include <com/sun/star/form/XDatabaseParameterBroadcaster.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { + +//============================================================================= + +/** provides the possibility of receiving an event for configuration of parameters. + + <p>Note that this interface provides exactly the same functionality as the + <type>XDatabaseParameterBroadcaster</type> interface. It exists purely for compatibility + with the <member scope="com::sun::star::script">XEventAttacher::attachSingleEventListener</member>: + It expects the methods for adding and removing listeners to follow a certain naming scheme, + respective to the name of the listener which is being added/removed.</p> + + @see XDatabaseParameterBroadcaster + @see com::sun::star::script::XEventAttacher +*/ +interface XDatabaseParameterBroadcaster2: XDatabaseParameterBroadcaster +{ + //------------------------------------------------------------------------- + /** registers an XDatabaseParameterListener + + <p>This method behaves exactly as the <member>XDatabaseParameterBroadcaster::addParameterListener</member> + method inherited from the base interface.</p> + */ + [oneway] void addDatabaseParameterListener( [in] com::sun::star::form::XDatabaseParameterListener aListener ); + + //------------------------------------------------------------------------- + + /** revokes an XDatabaseParameterListener + + <p>This method behaves exactly as the <member>XDatabaseParameterBroadcaster::removeParameterListener</member> + method inherited from the base interface.</p> + */ + [oneway] void removeDatabaseParameterListener( [in] com::sun::star::form::XDatabaseParameterListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XDatabaseParameterListener.idl b/offapi/com/sun/star/form/XDatabaseParameterListener.idl new file mode 100644 index 000000000000..38cd22bbee3f --- /dev/null +++ b/offapi/com/sun/star/form/XDatabaseParameterListener.idl @@ -0,0 +1,72 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XDatabaseParameterListener_idl__ +#define __com_sun_star_form_XDatabaseParameterListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_form_DatabaseParameterEvent_idl__ +#include <com/sun/star/form/DatabaseParameterEvent.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** allows to intercept value request for parametrized SQL statements. + */ +published interface XDatabaseParameterListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when there is a need for parameter values + + @param aEvent + the event describing the parameter value request. + + @returns + <TRUE/> when the execution of the parametrized statement should continue, <FALSE/> otherwise. + + @see com::sun::star::form::DatabaseParameterEvent + */ + boolean approveParameter( [in] com::sun::star::form::DatabaseParameterEvent aEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XDeleteListener.idl b/offapi/com/sun/star/form/XDeleteListener.idl new file mode 100644 index 000000000000..48a3dc6c9d6a --- /dev/null +++ b/offapi/com/sun/star/form/XDeleteListener.idl @@ -0,0 +1,80 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XDeleteListener_idl__ +#define __com_sun_star_form_XDeleteListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** This is the listener interface for receiving "approveDelete" and + "deleted" events posted by a database form. + + <p> "approveDelete" may be used to abort a deletion of the current data + record.</p> + + <p>Please do <em><b>not</b></em> use anymore, this interface is superseeded + by <type scope="com::sun::star::form">XConfirmDeleteListener</type>.</p> + + @deprecated + */ +published interface XDeleteListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when the current record of the database form will be deleted. + */ + boolean approveDelete( [in] com::sun::star::lang::EventObject aEvent ); + + //------------------------------------------------------------------------- + + /** is invoked when a database form has finished the delete processing and + the data has been successfully deleted from the datasource. + */ + void deleted( [in] com::sun::star::lang::EventObject aEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XErrorBroadcaster.idl b/offapi/com/sun/star/form/XErrorBroadcaster.idl new file mode 100644 index 000000000000..7775f23e9c8e --- /dev/null +++ b/offapi/com/sun/star/form/XErrorBroadcaster.idl @@ -0,0 +1,75 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XErrorBroadcaster_idl__ +#define __com_sun_star_form_XErrorBroadcaster_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_form_XErrorListener_idl__ +#include <com/sun/star/form/XErrorListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides the possibility of receiving database error events. + + <p>Please do <em><b>not</b></em> use anymore, this interface is superseeded + by <type scope="com::sun::star::sdb">XSQLErrorBroadcaster</type>.</p> + + @deprecated + */ +published interface XErrorBroadcaster: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** adds the specified listener to be notified of errors. + */ + [oneway] void addErrorListener( [in] com::sun::star::form::XErrorListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener. + */ + [oneway] void removeErrorListener( [in] com::sun::star::form::XErrorListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XErrorListener.idl b/offapi/com/sun/star/form/XErrorListener.idl new file mode 100644 index 000000000000..4b329e1e6d03 --- /dev/null +++ b/offapi/com/sun/star/form/XErrorListener.idl @@ -0,0 +1,75 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XErrorListener_idl__ +#define __com_sun_star_form_XErrorListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_form_ErrorEvent_idl__ +#include <com/sun/star/form/ErrorEvent.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** used to be notified when errors in a database form happen. + + <p>Each time an exception is triggered by a database form, the error + event is posted to the error listeners. This event may be used to + configure the error handling of a database form.</p> + + <p>Please do <em><b>not</b></em> use anymore, this interface is superseeded + by <type scope="com::sun::star::sdb">XSQLErrorListener</type>.</p> + +@since foo + @deprecated + */ +published interface XErrorListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when a database action performed by a database form raises + an exception. + */ + void errorOccured( [in] com::sun::star::form::ErrorEvent aEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XForm.idl b/offapi/com/sun/star/form/XForm.idl new file mode 100644 index 000000000000..4fc0daaf427a --- /dev/null +++ b/offapi/com/sun/star/form/XForm.idl @@ -0,0 +1,59 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XForm_idl__ +#define __com_sun_star_form_XForm_idl__ + +#ifndef __com_sun_star_form_XFormComponent_idl__ +#include <com/sun/star/form/XFormComponent.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** identifies a <type>FormComponent</type> as being a (sub-) form. + + <p>This interface does not really provide an own functionality, it is only for easier + runtime identification of form components.</p> + + @see XFormComponent + */ +published interface XForm: com::sun::star::form::XFormComponent +{ +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XFormComponent.idl b/offapi/com/sun/star/form/XFormComponent.idl new file mode 100644 index 000000000000..7d32c30deef1 --- /dev/null +++ b/offapi/com/sun/star/form/XFormComponent.idl @@ -0,0 +1,59 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XFormComponent_idl__ +#define __com_sun_star_form_XFormComponent_idl__ + +#ifndef __com_sun_star_container_XChild_idl__ +#include <com/sun/star/container/XChild.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** describes a component which may be part of a form. + + <p>This interface does not really provide an own functionality, it is only for easier + runtime identification of form components.</p> + + @see XForm + */ +published interface XFormComponent: com::sun::star::container::XChild +{ +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XFormController.idl b/offapi/com/sun/star/form/XFormController.idl new file mode 100644 index 000000000000..e78de565f7ce --- /dev/null +++ b/offapi/com/sun/star/form/XFormController.idl @@ -0,0 +1,67 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XFormController_idl__ +#define __com_sun_star_form_XFormController_idl__ + +#ifndef __com_sun_star_awt_XTabController_idl__ +#include <com/sun/star/awt/XTabController.idl> +#endif + +#ifndef __com_sun_star_awt_XControl_idl__ +#include <com/sun/star/awt/XControl.idl> +#endif + +#ifndef __com_sun_star_form_XFormControllerListener_idl__ +#include <com/sun/star/form/XFormControllerListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** is superseded by <type scope="com::sun::star::form::runtime">XFormController</type>. + @deprecated + */ +published interface XFormController: com::sun::star::awt::XTabController +{ + ::com::sun::star::awt::XControl getCurrentControl(); + [oneway] void addActivateListener( [in] ::com::sun::star::form::XFormControllerListener l ); + [oneway] void removeActivateListener( [in] ::com::sun::star::form::XFormControllerListener l ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XFormControllerListener.idl b/offapi/com/sun/star/form/XFormControllerListener.idl new file mode 100644 index 000000000000..6d12ab85eba8 --- /dev/null +++ b/offapi/com/sun/star/form/XFormControllerListener.idl @@ -0,0 +1,84 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XFormControllerListener_idl__ +#define __com_sun_star_form_XFormControllerListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** allows to be notified when the activation status of a <type>FormController</type> changes. + + <p> A form controller is activated if a form control gains the + focus and none of its controls currently owned the focus before.</p> + + @see XFormController + */ +published interface XFormControllerListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when a control of the controller gained the focus and + the controller was not previously activated. + + @param rEvent + the event happend. + */ + [oneway] void formActivated( [in] com::sun::star::lang::EventObject rEvent ); + + //------------------------------------------------------------------------- + + /** is invoked when a control of the "XFormController" lost the focus + and no control of the controller received the focus. In other + words, no control of the controller owns the focus. + + @param rEvent + the event happend. + */ + [oneway] void formDeactivated( [in] com::sun::star::lang::EventObject rEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XFormsSupplier.idl b/offapi/com/sun/star/form/XFormsSupplier.idl new file mode 100644 index 000000000000..121ee9ffac8b --- /dev/null +++ b/offapi/com/sun/star/form/XFormsSupplier.idl @@ -0,0 +1,105 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XFormsSupplier_idl__ +#define __com_sun_star_form_XFormsSupplier_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_container_XNameContainer_idl__ +#include <com/sun/star/container/XNameContainer.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides the access to a collection of forms. + */ +published interface XFormsSupplier: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** accesses the forms. + + @example StarBASIC + <listing> + REM ***** BASIC ***** + + Sub createColorSelectionBox + ' create a new shape + xShape = thisComponent.createInstance( "com.sun.star.drawing.ControlShape" ) + Dim aPos as new com.sun.star.awt.Point + aPos.X = 200 + aPos.Y = 100 + xShape.Position = aPos + Erase aPos + Dim aSize as new com.sun.star.awt.Size + aSize.Width = 2500 + aSize.Height = 5000 + xShape.Size = aSize + Erase aSize + + ' create a combo box model + xControlModel = thisComponent.createInstance( "com.sun.star.form.component.ComboBox" ) + xControlModel.Name = "ColorSelection" + xControlModel.Text = "red" + + ' marry the shape and the model + xShape.Control = xControlModel + + if ( 0 = thisComponent.DrawPage.Forms.getCount() ) Then + xForm = thisComponent.createInstance( "com.sun.star.form.component.DataForm" ) + xForm.Name = "SampleForm" + thisComponent.DrawPage.Forms.insertByIndex( 0, xForm ) + End If + ' insert the control model into the first form of the forms collection of the + ' draw page of the document + thisComponent.DrawPage.Forms.getByIndex(0).insertByIndex( 0, xControlModel ) + thisComponent.DrawPage.add( xShape ) + End Sub + </listing> + + @returns + the container of all the top-level forms belonging to the component. + */ + com::sun::star::container::XNameContainer getForms(); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XFormsSupplier2.idl b/offapi/com/sun/star/form/XFormsSupplier2.idl new file mode 100644 index 000000000000..30a22e02b91c --- /dev/null +++ b/offapi/com/sun/star/form/XFormsSupplier2.idl @@ -0,0 +1,68 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_XFormsSupplier2_idl__ +#define __com_sun_star_form_XFormsSupplier2_idl__ + +#ifndef __com_sun_star_form_XFormsSupplier_idl__ +#include <com/sun/star/form/XFormsSupplier.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { + +//============================================================================= + +/** extends the <type>XFormsSupplier</type> with convenience methods +*/ +interface XFormsSupplier2: XFormsSupplier +{ + /** determines whether there are currently forms available at all + + <p>If you need read access to the forms collection, then you might check + the existence of forms using <member>hasForms</member>, and if it returns + <FALSE/>, you can do as if <member>XFormsSupplier::getForms</member> would + have returned an empty container.</p> + + <p>Semantically, <member>hasForms</member> is equivalent to calling + <member>XElementAccess::hasElements</member> on the container returned by + <member>XFormsSupplier::getForms</member>. But when using the latter, the + implementation is forced to create a empty container, which might be potentially + expensive.</p> + */ + boolean hasForms(); +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XGrid.idl b/offapi/com/sun/star/form/XGrid.idl new file mode 100644 index 000000000000..f60fa5be9cee --- /dev/null +++ b/offapi/com/sun/star/form/XGrid.idl @@ -0,0 +1,79 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XGrid_idl__ +#define __com_sun_star_form_XGrid_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides the possibility of setting and retrieving the position + of the current cell in a grid control. + + <p>Note that a grid control does not allow free control over the current row: + In such a control, every line represents a row of data of the underlying + <type scope="com::sun::star::form::component">DataForm</type>. Thus, the <em>current + row</em> of the grid control always equals the current row of the + <type scope="com::sun::star::form::component">DataForm</type>, and can be affected only + by changing the latter.<br/> + The current column of a grid control, whoever, can be freely controlled.</p> + + @see com::sun::star::form::component::GridControl + @see com::sun::star::form::control::GridControl + @deprecated + */ +published interface XGrid: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** retrieves the current column position. + */ + short getCurrentColumnPosition(); + + //------------------------------------------------------------------------- + + /** sets the current column position. + */ + [oneway] void setCurrentColumnPosition( [in] short nPos ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XGridColumnFactory.idl b/offapi/com/sun/star/form/XGridColumnFactory.idl new file mode 100644 index 000000000000..76d1b3735b9f --- /dev/null +++ b/offapi/com/sun/star/form/XGridColumnFactory.idl @@ -0,0 +1,93 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XGridColumnFactory_idl__ +#define __com_sun_star_form_XGridColumnFactory_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_beans_XPropertySet_idl__ +#include <com/sun/star/beans/XPropertySet.idl> +#endif + +#ifndef __com_sun_star_lang_IllegalArgumentException_idl__ +#include <com/sun/star/lang/IllegalArgumentException.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** allows to create columns to be added into a grid control model. + + <p>Grid columns (more precise: models of grid columns) are direct children of + the grid control model they belong to. Grid columns can't be created on a global + service factory, instead, you need to create them on the grid, where you want to + insert them later on.</p> + + @see com::sun::star::form::component::GridControl + */ +published interface XGridColumnFactory: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** creates a new column object + + @param aColumnType + the type of column to be created + + @returns + the new column object + + @throws com::sun::star::lang::IllegalArgumentException + if <arg>aColumnType</arg> is not available. + */ + com::sun::star::beans::XPropertySet createColumn( [in] string aColumnType ) + raises( com::sun::star::lang::IllegalArgumentException ); + + //------------------------------------------------------------------------- + + /** returns a list of available column types. + + @returns + a list of column types. + */ + sequence<string> getColumnTypes(); +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XGridControl.idl b/offapi/com/sun/star/form/XGridControl.idl new file mode 100644 index 000000000000..3f9e601fc310 --- /dev/null +++ b/offapi/com/sun/star/form/XGridControl.idl @@ -0,0 +1,69 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef __com_sun_star_form_XGridControl_idl__ +#define __com_sun_star_form_XGridControl_idl__ + +#include <com/sun/star/form/XGrid.idl> +#include <com/sun/star/form/XGridControlListener.idl> +#include <com/sun/star/form/XGridFieldDataSupplier.idl> + +//============================================================================= + +module com { module sun { module star { module form { + +//============================================================================= + +/** specifies (some) functionality provided by a grid control (aka table control) + + @since OOo 3.1 + */ +interface XGridControl +{ + /** allows access to the current column position within the grid control + */ + interface XGrid; + + /** registers a listener which is to be notified about state changes in + the grid control + */ + void addGridControlListener( [in] XGridControlListener _listener ); + + /** revokes a previously registered grid control listener + */ + void removeGridControlListener( [in] XGridControlListener _listener ); + + /// provides access to the data in the control, even in non-current rows + interface XGridFieldDataSupplier; +}; + +//============================================================================= + +}; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/XGridControlListener.idl b/offapi/com/sun/star/form/XGridControlListener.idl new file mode 100644 index 000000000000..f84e99f837d2 --- /dev/null +++ b/offapi/com/sun/star/form/XGridControlListener.idl @@ -0,0 +1,57 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef __com_sun_star_form_XGridControlListener_idl__ +#define __com_sun_star_form_XGridControlListener_idl__ + +#include <com/sun/star/lang/XEventListener.idl> + +//============================================================================= + +module com { module sun { module star { module form { + +//============================================================================= + +/** specifies a listener which is to be notified about state changes in a grid control + + @see XGridControl + @since OOo 3.1 + */ +interface XGridControlListener : ::com::sun::star::lang::XEventListener +{ + /** called when the current column in a grid control changed + @see XGrid::getCurrentColumnPosition + */ + void columnChanged( [in] ::com::sun::star::lang::EventObject _event ); +}; + +//============================================================================= + +}; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/XGridFieldDataSupplier.idl b/offapi/com/sun/star/form/XGridFieldDataSupplier.idl new file mode 100644 index 000000000000..5a4aa9b57fec --- /dev/null +++ b/offapi/com/sun/star/form/XGridFieldDataSupplier.idl @@ -0,0 +1,97 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XGridFieldDataSupplier_idl__ +#define __com_sun_star_form_XGridFieldDataSupplier_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_reflection_XIdlClass_idl__ +#include <com/sun/star/reflection/XIdlClass.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides access to the data of a GridControl + + <p>You can retrieve the data type information and the data in a row.</p> + + <p>This interface allows to retrieve data even for rows which are not current, which is quite usefull, + as normally, you can't affect the current row in a grid control without moving the cursor of the underlying + <type scope="com::sun::star::form::component">DataForm</type>.</p> + + @see XGrid + @see com::sun::star::form::control::GridControl + @see com::sun::star::form::component::GridControl + + @deprecated + */ +published interface XGridFieldDataSupplier: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + /** checks whether or not the content of the grid's columns can be retrieved in the requested format. + + <p>Not every cell content can be retrieved in every representation. For example, in a text column, + you usually won't be able to retrieve the content as double.<br/> + To check if the type you need is supported by the columns, use this method.</p> + + @return + A sequence of boolean flags. Each flag corresponds to the respective column, and <TRUE/> indicates + that the column content can be retrieved in the requested format, <FALSE/> denies this. + + @see XGridColumnFactory + @see DataAwareControlModel + @see XGridFieldDataSupplier::queryFieldData + */ + sequence<boolean> queryFieldDataType( [in] type xType ); + + //------------------------------------------------------------------------- + /** retrieves the actual column data for the given row + + <p>If a column does not support the requested type, <NULL/> is returned at the respective + position.</p> + + @see XGridFieldDataSupplier::queryFieldDataType + */ + sequence<any> queryFieldData( [in] long nRow, + [in] type xType ); +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XGridPeer.idl b/offapi/com/sun/star/form/XGridPeer.idl new file mode 100644 index 000000000000..57d815caa214 --- /dev/null +++ b/offapi/com/sun/star/form/XGridPeer.idl @@ -0,0 +1,80 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XGridPeer_idl__ +#define __com_sun_star_form_XGridPeer_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_container_XIndexContainer_idl__ +#include <com/sun/star/container/XIndexContainer.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** represents the window peer of a GridControl and allows you to set + and retrieve the model data. + + <p>Usually, the columns used are the columns as supplied by the grid control model.</p> + + <p>You should use this interface only if you know exactly what you are doing. Tampering + with the columns of a grid control which is part of a complex form can really hurt ....</p> + + @deprecated + @see com::sun::star::awt::XWindowPeer + @see com::sun::star::form::component::GridControl + */ +published interface XGridPeer: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** retrieves the currently used column definitions of the peer. + */ + com::sun::star::container::XIndexContainer getColumns(); + + //------------------------------------------------------------------------- + + /** sets the column definition for the peer. + */ + [oneway] void setColumns( [in] com::sun::star::container::XIndexContainer aColumns ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XImageProducerSupplier.idl b/offapi/com/sun/star/form/XImageProducerSupplier.idl new file mode 100644 index 000000000000..74a52e8e526c --- /dev/null +++ b/offapi/com/sun/star/form/XImageProducerSupplier.idl @@ -0,0 +1,69 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XImageProducerSupplier_idl__ +#define __com_sun_star_form_XImageProducerSupplier_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_awt_XImageProducer_idl__ +#include <com/sun/star/awt/XImageProducer.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides the access to an image producer. + + @see com::sun::star::awt::XImageProducer + */ +published interface XImageProducerSupplier: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** accesses the image producer. + + @returns + the image producer. + */ + com::sun::star::awt::XImageProducer getImageProducer(); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XInsertListener.idl b/offapi/com/sun/star/form/XInsertListener.idl new file mode 100644 index 000000000000..63da8d514c4b --- /dev/null +++ b/offapi/com/sun/star/form/XInsertListener.idl @@ -0,0 +1,77 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XInsertListener_idl__ +#define __com_sun_star_form_XInsertListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** allows to receive notifications about insertions into a database form. + + <p>Please do <em><b>not</b></em> use anymore, this interface is deprecated, and + superseeded by functionality from the <type scope="com::sun::star::form::component">DataForm</type> + service, as well as the <type scope="com::sun::star::sdbc">XRowSetListener</type> and + <type scope="com::sun::star::sdb">XRowSetApproveListener</type> interfaces.</p> + + @deprecated + */ +published interface XInsertListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when a database form starts inserting a record. + */ + void inserting( [in] com::sun::star::lang::EventObject aEvent ); + + //------------------------------------------------------------------------- + + /** is invoked after a database form has inserted a record to a data source. + */ + void inserted( [in] com::sun::star::lang::EventObject aEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XLoadListener.idl b/offapi/com/sun/star/form/XLoadListener.idl new file mode 100644 index 000000000000..afbf72027e9b --- /dev/null +++ b/offapi/com/sun/star/form/XLoadListener.idl @@ -0,0 +1,114 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XLoadListener_idl__ +#define __com_sun_star_form_XLoadListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** receives load-related events from a loadable object. + + <p>The interface is typically implemented by data-bound components, + which want to listen to the data source that contains their database + form.</p> + + @see com::sun::star::form::XLoadable + @see DataAwareControlModel + */ +published interface XLoadListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when the object has successfully connected to a datasource. + + @param aEvent + the event happend. + */ + [oneway] void loaded( [in] com::sun::star::lang::EventObject aEvent ); + + //------------------------------------------------------------------------- + + /** is invoked when the object is about to be unloaded. + <p>Components may use this to stop any other event processing related to + the event source before the object is unloaded.</p> + + @param aEvent + the event happend. + */ + [oneway] void unloading( [in] com::sun::star::lang::EventObject aEvent ); + + //------------------------------------------------------------------------- + + /** is invoked after the object has disconnected from a datasource. + + @param aEvent + the event happend. + */ + [oneway] void unloaded( [in] com::sun::star::lang::EventObject aEvent ); + + //------------------------------------------------------------------------- + + /** is invoked when the object is about to be reloaded. + + <p>Components may use this to stop any other event processing related + to the event source until they get the reloaded event.</p> + + @param aEvent + the event happend. + */ + [oneway] void reloading( [in] com::sun::star::lang::EventObject aEvent ); + + //------------------------------------------------------------------------- + + /** is invoked when the object has been reloaded. + + @param aEvent + the event happend. + */ + [oneway] void reloaded( [in] com::sun::star::lang::EventObject aEvent ); +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XLoadable.idl b/offapi/com/sun/star/form/XLoadable.idl new file mode 100644 index 000000000000..1c1abb68059c --- /dev/null +++ b/offapi/com/sun/star/form/XLoadable.idl @@ -0,0 +1,107 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XLoadable_idl__ +#define __com_sun_star_form_XLoadable_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_form_XLoadListener_idl__ +#include <com/sun/star/form/XLoadListener.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides functionality to implement objects which may be loaded. + + <p>The object is typically implemented by high-level objects which can connect to a data source.</p> + + @see XLoadListener + */ +published interface XLoadable: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** loads the data. + + <p>If the data is already loaded (->isLoaded), then the method returns silently. + In this case, you should use ->reload.</p> + */ + [oneway] void load(); + + //------------------------------------------------------------------------- + + /** unloads the data. + */ + [oneway] void unload(); + + //------------------------------------------------------------------------- + + /** does a smart refresh of the object. + + <p>The final state will be the same as if unload and load were called, but reload + is the more efficient way to do the same. If the object isn't loaded, nothing happens.</p> + */ + [oneway] void reload(); + + //------------------------------------------------------------------------- + + /** returns if the object is in loaded state. + */ + boolean isLoaded(); + + //------------------------------------------------------------------------- + + /** adds the specified listener to receive load-related events + + @param aListener + the listener to add. + */ + [oneway] void addLoadListener( [in] com::sun::star::form::XLoadListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener. + + @param aListener + the listener to remove. + */ + [oneway] void removeLoadListener( [in] com::sun::star::form::XLoadListener aListener ); +}; + +}; }; }; }; + +#endif + +/*============================================================================= + +=============================================================================*/ diff --git a/offapi/com/sun/star/form/XPositioningListener.idl b/offapi/com/sun/star/form/XPositioningListener.idl new file mode 100644 index 000000000000..391380e1d3a4 --- /dev/null +++ b/offapi/com/sun/star/form/XPositioningListener.idl @@ -0,0 +1,70 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XPositioningListener_idl__ +#define __com_sun_star_form_XPositioningListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** allows to receive notifications about cursor movements into a database form. + + <p>Please do <em><b>not</b></em> use anymore, this interface is deprecated, and + superseeded by functionality from the <type scope="com::sun::star::form::component">DataForm</type> + service, as well as the <type scope="com::sun::star::sdbc">XRowSetListener</type>.</p> + + @deprecated + */ +published interface XPositioningListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when the database form has been positioned on a data record. + */ + [oneway] void positioned( [in] com::sun::star::lang::EventObject aEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XReset.idl b/offapi/com/sun/star/form/XReset.idl new file mode 100644 index 000000000000..9ef8f37e649b --- /dev/null +++ b/offapi/com/sun/star/form/XReset.idl @@ -0,0 +1,85 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XReset_idl__ +#define __com_sun_star_form_XReset_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_form_XResetListener_idl__ +#include <com/sun/star/form/XResetListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides functionality to reset components to some default values. + + <p>The semantincs of <em>default value</em> depends on the providing service.</p> + */ +published interface XReset: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** resets a component to some default value. + */ + [oneway] void reset(); + + //------------------------------------------------------------------------- + + /** adds the specified listener to receive events related to resetting the + component. + + @param aListener + the listener to add. + */ + [oneway] void addResetListener( [in] com::sun::star::form::XResetListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener + + @param aListener + the listener to remove + */ + [oneway] void removeResetListener( [in] com::sun::star::form::XResetListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XResetListener.idl b/offapi/com/sun/star/form/XResetListener.idl new file mode 100644 index 000000000000..b7f338fe59fb --- /dev/null +++ b/offapi/com/sun/star/form/XResetListener.idl @@ -0,0 +1,91 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XResetListener_idl__ +#define __com_sun_star_form_XResetListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** is the interface for receiving notificaions about reset events. + + <p>The listener is called if a component implementing the + <type>XReset</type> interface performs a reset.</br> + Order of events: + <ul><li>a reset is triggered on a component</li> + <li>the component calls <member>XReset::approveReset</member> on all its listeners</li> + <li>if all listeners approve the reset operation, the data is reset</li> + <li>the component calls <member>XReset::resetted</member> on all its listeners</li> + </ul> + </p> + + @see XReset + */ +published interface XResetListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked before a component is reset. + + @param rEvent + the event happend. + + @returns + <TRUE/> when reset was approved, <FALSE/> when the reset operation should be cancelled. + */ + boolean approveReset( [in] com::sun::star::lang::EventObject rEvent ); + + //------------------------------------------------------------------------- + + /** is invoked when a component has been reset. + + @param rEvent + the event happend. + */ + [oneway] void resetted( [in] com::sun::star::lang::EventObject rEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XRestoreListener.idl b/offapi/com/sun/star/form/XRestoreListener.idl new file mode 100644 index 000000000000..f5b4c77325f5 --- /dev/null +++ b/offapi/com/sun/star/form/XRestoreListener.idl @@ -0,0 +1,74 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XRestoreListener_idl__ +#define __com_sun_star_form_XRestoreListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** receives notifications about data beeing restored. + + <p>Such a notification is typically sent when the user cancels updating the + current record of a database form + without saving the data. After restoring, the user operates on the original data.</p> + + <p>Please do <em><b>not</b></em> use anymore, this interface is deprecated, and + superseeded by functionality from the <type scope="com::sun::star::form::component">DataForm</type> + and <type scope="com::sun::star::sdb">RowSet</type> services</p> + + @deprecated + */ +published interface XRestoreListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when a modified record has been restored + */ + void restored( [in] com::sun::star::lang::EventObject aEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XSubmit.idl b/offapi/com/sun/star/form/XSubmit.idl new file mode 100644 index 000000000000..d7b766990fdc --- /dev/null +++ b/offapi/com/sun/star/form/XSubmit.idl @@ -0,0 +1,106 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XSubmit_idl__ +#define __com_sun_star_form_XSubmit_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_awt_XControl_idl__ +#include <com/sun/star/awt/XControl.idl> +#endif + +#ifndef __com_sun_star_awt_MouseEvent_idl__ +#include <com/sun/star/awt/MouseEvent.idl> +#endif + +#ifndef __com_sun_star_form_XSubmitListener_idl__ +#include <com/sun/star/form/XSubmitListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** provides functionality to submit data from a component. + + <p>Usually, this is used by <type scope="com::sun::star::form::component">HTMLForm</type>s. + + <p>See the <A href="http://www.w3.org/TR/1999/REC-html401-19991224/interact/forms.html#h-17.13">HTML specification</A> + to learn about submitting forms.</p> + */ +published interface XSubmit: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** submits the component's data to a specified target. + + @param aControl + the control which's data is to be be submitted + + @param aMouseEvt + the event which triggered the submit, if it was a mouse event + + @see com::sun::star::awt::MouseEvent + */ + [oneway] void submit( [in] com::sun::star::awt::XControl aControl, + [in] com::sun::star::awt::MouseEvent aMouseEvt ); + + //------------------------------------------------------------------------- + + /** adds the specified listener to receive the "approveSubmit" event. + + @param aListener + the listener to add. + + @see com::sun::star::form::XSubmitListener + */ + [oneway] void addSubmitListener( [in] com::sun::star::form::XSubmitListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener. + @param aListener + the listener to remove. + @see com::sun::star::form::XSubmitListener + */ + [oneway] void removeSubmitListener( [in] com::sun::star::form::XSubmitListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XSubmitListener.idl b/offapi/com/sun/star/form/XSubmitListener.idl new file mode 100644 index 000000000000..1943c2071a2d --- /dev/null +++ b/offapi/com/sun/star/form/XSubmitListener.idl @@ -0,0 +1,79 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XSubmitListener_idl__ +#define __com_sun_star_form_XSubmitListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** receives notifications about data beeing submitted. + + <p>The submission may be cancelled, so the listener has the possibility + of verifying the data before submission.</p> + + @see XSubmit + + @deprecated + This interface is superseded by the <type scope="com::sun::star::form::submission">XSubmissionVetoListener</type> + interface. New implementations should use the latter, if possible. + */ +published interface XSubmitListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked when a component is about to submit it's data. + + @param aEvent + the event happend + + @returns + <TRUE/> when submitting was approved, otherwise <FALSE/>. + */ + boolean approveSubmit( [in] com::sun::star::lang::EventObject rEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XUpdateBroadcaster.idl b/offapi/com/sun/star/form/XUpdateBroadcaster.idl new file mode 100644 index 000000000000..cf4f20a4da69 --- /dev/null +++ b/offapi/com/sun/star/form/XUpdateBroadcaster.idl @@ -0,0 +1,84 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XUpdateBroadcaster_idl__ +#define __com_sun_star_form_XUpdateBroadcaster_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_form_XUpdateListener_idl__ +#include <com/sun/star/form/XUpdateListener.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** is the broadcaster interface for sending "approveUpdate" and "updated" events. + + <p>The component supporting this interface must do approval calls + (<member>XUpdateListener::approveUpdate</member>) immediately + before the data is updated, and notification calls + (<member>XUpdateListener::updated</member>) immediately afterwards.</p> + + @see XUpdateListener + */ +published interface XUpdateBroadcaster: com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + + /** adds the specified listener to receive the events "approveUpdate" + and "updated". + @param aListener + the listener to add. + @see com::sun::star::form::XUpdateListener + */ + [oneway] void addUpdateListener( [in] com::sun::star::form::XUpdateListener aListener ); + + //------------------------------------------------------------------------- + + /** removes the specified listener. + @param aListener + the listener to remove. + @see com::sun::star::form::XUpdateListener + */ + [oneway] void removeUpdateListener( [in] com::sun::star::form::XUpdateListener aListener ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/XUpdateListener.idl b/offapi/com/sun/star/form/XUpdateListener.idl new file mode 100644 index 000000000000..172a3593c87f --- /dev/null +++ b/offapi/com/sun/star/form/XUpdateListener.idl @@ -0,0 +1,87 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_XUpdateListener_idl__ +#define __com_sun_star_form_XUpdateListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { + +//============================================================================= + +/** used to listen on objects which allow updating their data. + <p>In addition to just get notified when an data update happened, the listener + has a chance to veto updates <em>before</em> they happen.</p> + + @see XUpdateBroadcaster + */ +published interface XUpdateListener: com::sun::star::lang::XEventListener +{ + //------------------------------------------------------------------------- + + /** is invoked to check the current data. + + <p>For a given update process, if one of the <type>XUpdateListener</type>s + vetos the change, the update is canceled, and no further notification happens.</p> + + @param aEvent + An event dedscriptor specifying the broadcaster of the change. + + @returns + <TRUE/> when the update was approved, otherwise <FALSE/>. + */ + boolean approveUpdate( [in] com::sun::star::lang::EventObject aEvent ); + + //------------------------------------------------------------------------- + + /** is invoked when an object has finished processing the updates and + the data has been successfully written. + + @param aEvent + A event dedscriptor specifying the broadcaster of the change. + */ + void updated( [in] com::sun::star::lang::EventObject aEvent ); + +}; + +//============================================================================= + +}; }; }; }; + +/*============================================================================= + +=============================================================================*/ +#endif diff --git a/offapi/com/sun/star/form/binding/BindableControlModel.idl b/offapi/com/sun/star/form/binding/BindableControlModel.idl new file mode 100644 index 000000000000..8b0d1058c77b --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableControlModel.idl @@ -0,0 +1,92 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableControlModel_idl__ +#define __com_sun_star_form_binding_BindableControlModel_idl__ + +#ifndef __com_sun_star_form_binding_XBindableValue_idl__ +#include <com/sun/star/form/binding/XBindableValue.idl> +#endif +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +/** specifies the model of a form control which supports binding to an external + value supplier. +*/ +service BindableControlModel +{ + /** specifies the basic functionality for a form control model + + <p>Via this service, bindable control models inherit the + <type scope="com::sun::star::util">XCloneable</type> interface.<br/> + If an bindable control model, at which a binding has been established (via + <member>XBindableValue::setValueBinding</member>), is being cloned, then the + binding is also established at the clone. Effectively, this means that + both control model instances share the same binding instance.</p> + */ + service com::sun::star::form::FormControlModel; + + /** specifies support for being bound to an external value + + <p>When a <type>BindableControlModel</type> is bound to an external value, + then every change in the control model's value is <em>immediately</em> reflected + in the external binding.</p> + + <p>If the binding set via this interface supports the <member>ValueBinding::ReadOnly</member> + and <member>ValueBinding::Relevant</member> properties, they're respected by the control model: + <ul><li>The control model's own <code>ReadOnly</code> property (if present) is kept in sync with the + binding's <code>ReadOnly</code> property. That is, any control using the value + binding is read-only as long as the binding is.</li> + <li>The control model's own <code>Enabled</code> property (if present) is kept in sync + with the binding's <code>Relevant</code> property. That is, any control using + the value binding is disabled as long as the binding is not relevant.</li> + </ul> + </p> + + <p>In both cases, explicit changes of the model's property are ignored if they would relax + the restriction imposed by the binding.<br/> + For instance, if the binding declares it's value to + be read-only (indicated by <member>ValueBinding::ReadOnly</member> being <TRUE/>), then + any attempt to set the <code>ReadOnly</code> property of the control model to <FALSE/> will + fail. However, if the binding's value is not read-only, then the <code>ReadOnly</code> + property at the control model can be freely set.<br/> + The very same holds for the binding's <member>ValueBinding::Relevant</member> and the control + model's <code>Enabled</code> properties.</p> + */ + interface XBindableValue; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDataAwareControlModel.idl b/offapi/com/sun/star/form/binding/BindableDataAwareControlModel.idl new file mode 100644 index 000000000000..c16d53a9c304 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDataAwareControlModel.idl @@ -0,0 +1,132 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#define __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableControlModel_idl__ +#include <com/sun/star/form/binding/BindableControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** is a specialization of the <type scope="com::sun::star::form">DataAwareControlModel</type> + which additionally supports binding to external value suppliers. + + <p>Control models usually have some kind of value property, which reflects the very current + content of the controls associated with this model. For instance, for an + <type scope="com::sun::star::form::component">TextField</type>, this would be the + <member scope="com::sun::star::awt">UnoControlEditModel::Text</member> property of the base + service. Similarily, a <type scope="com::sun::star::form::component">CheckBox</type> has + a property <member scope="com::sun::star::awt">UnoControlCheckBoxModel::State</member>, which + reflects the current check state.</p> + + <p>Usual <type scope="com::sun::star::form">DataAwareControlModel</type>s can be bound to + a column of a <type scope="com::sun::star::form::component">DataForm</type>, and exchange + their content with such a column.<br/> + In particular, when the <type scope="com::sun::star::form::component">DataForm</type> + is moved to a different record, then the bound control model is updated with the value of + it's column in this particular row.<br/> + On the other hand, when any change in the control model (e.g. resulting from a user entering + data in a control associated with the control model) is committed + (<member scope="com::sun::star::form">XBoundComponent::commit</member>), then the actual + data of the control model is written into the associated + <type scope="com::sun::star::form::component">DataForm</type> column.</p> + + <p><type>BindableDataAwareControlModel</type>'s additionally support an alternative value + binding, which forces them to exchange their value with another foreign instance. + In some sense, they are an abstraction of the data aware control models, which only + support a specialized, hard-coded value binding (namely the binding to a + <type scope="com::sun::star::form::component">DataForm</type> column).</p> + + <p>For this, they provide the <type>XBindableValue</type> interface which allows to + set an external component to exchange the value with.</p> + + <p>The following rules apply when a data aware control model is bound to an external value binding: + <ul><li><b>Priority</b><br/> + External value bindings overrule any active SQL-column binding. If an external + component is bound to a control model which currently has an active SQL binding, + this SQL binding is suspended, until the external binding is revoked. + </li> + <li><b>Activation</b><br/> + An external value binding becomes effective as soon as it is set. This is a + difference to SQL bindings, which only are effective when the parent form + of the control model is loaded (<type scope="com::sun::star::form">XLoadable</type>). + </li> + <li><b>Immediacy</b><br/> + When a <type>BindableDataAwareControlModel</type> is bound to an external value, + then every change in the control model's value is <em>immediately</em> reflected + in the external binding. This is a difference to SQL bindings of most + <type scope="com::sun::star::form">DataAwareControlModel</type>'s, where changes + in the control model's value are only propagated to the bound column upon explicit + request via <member scope="com::sun::star::form">XBoundComponent::commit</member>.<br/> + Note that this restriction is inherited from the <type>BindableControlModel</type>. + </li> + <li><b>Cloning</b><br/> + <type scope="com::sun::star::form">FormControlModel</type>s support cloning themself + via the <type scope="com::sun::star::util">XCloneable</type> interface which they + inherit from the <type scope="com::sun::star::awt">UnoControlModel</type> service.</br> + When a <type>BindableDataAwareControlModel</type> is cloned while it has an active + external value binding, then the clone is also bound to the same binding instance.<br/> + Note that this restriction is inherited from the <type>BindableControlModel</type>. + </li> + </ul> + </p> + + <p>When a <type>BindableDataAwareControlModel</type> is being bound to an external value, + using <member>XBindableValue::setValueBinding</member>, + then the control model (it's value property, respectively) and the external value are + initially synchronized by setting the external value (<member>XValueBinding::getValue</member>) + at the control model.</p> + +*/ +service BindableDataAwareControlModel +{ + /** specifies the functionality for binding the control model to a + column of an SQL <type scope="com::sun::star::form::component">DataForm</type>. + */ + service com::sun::star::form::DataAwareControlModel; + + /** specifies the functionality for <em>alternatively</em> binding the control model + to an external value. + */ + service BindableControlModel; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseCheckBox.idl b/offapi/com/sun/star/form/binding/BindableDatabaseCheckBox.idl new file mode 100644 index 000000000000..868fc02c1705 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseCheckBox.idl @@ -0,0 +1,95 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseCheckBox_idl__ +#define __com_sun_star_form_binding_BindableDatabaseCheckBox_idl__ + +#ifndef __com_sun_star_form_component_DatabaseCheckBox_idl__ +#include <com/sun/star/form/component/DatabaseCheckBox.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a check box which is data-aware and thus can be bound to a + database field, and additionally supports binding to arbitrary external values. + + <p>The <type scope="com::sun::star::form::binding">XValueBinding</type> instance which + can be associated with a <type>BindableDatabaseCheckBox</type> must support exchanging + boolean values. The following mapping between external values and control states apply: + <ul><li><TRUE/> will be mapped to the box being checked, and vice versa</li> + <li><FALSE/> will be mapped to it being unchecked, and vice versa</li> + <li><NULL/> will be mapped to it being in indetermined state, if the box currently supports + this, or being unchecked else. The indetermined of the check box will always be + mapped to <NULL/> when writing the external value.</li> + </ul></p> + + <p>If the value binding associated with a <type>BindableDatabaseCheckBox</type> + supports exchanging string values, <em>and</em> the <member scope="com::sun::star::form::component">CheckBox::RefValue</member> + is <em>not</em> empty, then the radio button will exchange it's value as string: + <ul><li>A string equal to the reference value will be mapped to the button being checked, and vice versa</li> + <li>A string not equal to the reference value will be mapped to the button being unchecked, and vice versa</li> + <li><NULL/> will be mapped to it being in indetermined state</li> + </ul></p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + @see com::sun::star::awt::UnoControlCheckBoxModel::State + @see com::sun::star::awt::UnoControlCheckBoxModel::TriState + @see com::sun::star::form::component::CheckBox::RefValue + */ +service BindableDatabaseCheckBox +{ + service com::sun::star::form::component::DatabaseCheckBox; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + + /** specifies a value which is to be associated with the control when it's <em>not</em> + checked. + + <p><member scope="com::sun::star::form::component">CheckBox::RefValue</member> is transferred to + possible external value bindings as soon as the check box is checked. With the member + <member>SecondaryRefValue</member>, clients of the check box can also associate a value with + the <em>not checked</em> state of the control.</p> + */ + [property] string SecondaryRefValue; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseComboBox.idl b/offapi/com/sun/star/form/binding/BindableDatabaseComboBox.idl new file mode 100644 index 000000000000..9c379190afcc --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseComboBox.idl @@ -0,0 +1,73 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseComboBox_idl__ +#define __com_sun_star_form_binding_BindableDatabaseComboBox_idl__ + +#ifndef __com_sun_star_form_component_DatabaseComboBox_idl__ +#include <com/sun/star/form/component/DatabaseComboBox.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a model of a combo box (a list box combined with a text + input field) which is data-aware and thus can be bound to a database field, + and additionally supports binding to arbitrary external values. + + <p>If an <type scope="com::sun::star::form::binding">ValueBinding</type> instance is + set at the field, it will exchange it's text with the binding as <em>string</em>, thus only + bindings supporting string exchange will be accepted in + <member scope="com::sun::star::form::binding">XValueBinding::setValueBinding</member>. + </p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + @see com::sun::star::awt::UnoControlComboBoxModel::Text + */ +service BindableDatabaseComboBox +{ + service com::sun::star::form::component::DatabaseComboBox; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseDateField.idl b/offapi/com/sun/star/form/binding/BindableDatabaseDateField.idl new file mode 100644 index 000000000000..2df7988e5d40 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseDateField.idl @@ -0,0 +1,70 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseDateField_idl__ +#define __com_sun_star_form_binding_BindableDatabaseDateField_idl__ + +#ifndef __com_sun_star_form_component_DatabaseDateField_idl__ +#include <com/sun/star/form/component/DatabaseDateField.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a date input field which is data-aware and thus can be bound to a + database field, and additionally supports binding to arbitrary external values. + + <p>If an <type scope="com::sun::star::form::binding">ValueBinding</type> instance is + set at the field, it will exchange it's content with the binding as <type scope="com::sun::star::util">Date</type>. + </p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + @see com::sun::star::awt::UnoControlDateFieldModel::Date + */ +service BindableDatabaseDateField +{ + service com::sun::star::form::component::DatabaseDateField; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseFormattedField.idl b/offapi/com/sun/star/form/binding/BindableDatabaseFormattedField.idl new file mode 100644 index 000000000000..c6f433339295 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseFormattedField.idl @@ -0,0 +1,69 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseFormattedField_idl__ +#define __com_sun_star_form_binding_BindableDatabaseFormattedField_idl__ + +#ifndef __com_sun_star_form_component_DatabaseFormattedField_idl__ +#include <com/sun/star/form/component/DatabaseFormattedField.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a formatted input field which is data-aware and thus can be bound to a + database field, and additionally supports binding to arbitrary external values. + + <p>The <type scope="com::sun::star::form::binding">XValueBinding</type> instance which + can be associated with a <type>BindableDatabaseFormattedField</type> must support exchanging + values of type <em>double</em>.</p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + */ +service BindableDatabaseFormattedField +{ + service com::sun::star::form::component::DatabaseFormattedField; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseListBox.idl b/offapi/com/sun/star/form/binding/BindableDatabaseListBox.idl new file mode 100644 index 000000000000..d07665579638 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseListBox.idl @@ -0,0 +1,81 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseListBox_idl__ +#define __com_sun_star_form_binding_BindableDatabaseListBox_idl__ + +#ifndef __com_sun_star_form_component_DatabaseListBox_idl__ +#include <com/sun/star/form/component/DatabaseListBox.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a list box model which is data-aware and thus can be bound to a + database field, and additionally supports binding to arbitrary external values. + + <p>There are four possible ways how a <type>BindableDatabaseListBox</type> exchanges + values with an external binding, the following lists explains all of them. If a new binding + is set at a <type>BindableDatabaseListBox</type>, the types from the following list are + tried in descending order: The first type supported by the binding is used for data exchange. + <ol><li><em>sequences of integers</em>: When used, the integers in the sequence will represent + the indexes of the selected entries of the list box.</li> + <li><em>integer values</em>: When used, the value will represent the index of the selected entry. + If no entry is selected, -1 will be transfered. If more than one entry is selected, <NULL/> + will be transfered.</li> + <li><em>sequences of strings</em>: When used, the strings in the sequence present the texts + of the selected entries of the list box.</li> + <li><em>string values</em>: When used. the value will represent the text of the selected entry. + If no entry is selected, an empty string will be transfered. If more than one entry is selected, + <NULL/> will be transfered.</li> + </ol></p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + */ +service BindableDatabaseListBox +{ + service com::sun::star::form::component::DatabaseListBox; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseNumericField.idl b/offapi/com/sun/star/form/binding/BindableDatabaseNumericField.idl new file mode 100644 index 000000000000..c34acbe14ce1 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseNumericField.idl @@ -0,0 +1,69 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseNumericField_idl__ +#define __com_sun_star_form_binding_BindableDatabaseNumericField_idl__ + +#ifndef __com_sun_star_form_component_DatabaseNumericField_idl__ +#include <com/sun/star/form/component/DatabaseNumericField.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a numeric input field which is data-aware and thus can be bound to a + database field, and additionally supports binding to arbitrary external values. + + <p>The <type scope="com::sun::star::form::binding">XValueBinding</type> instance which + can be associated with a <type>BindableDatabaseNumericField</type> must support exchanging + values of type <em>double</em>.</p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + */ +service BindableDatabaseNumericField +{ + service com::sun::star::form::component::DatabaseNumericField; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseRadioButton.idl b/offapi/com/sun/star/form/binding/BindableDatabaseRadioButton.idl new file mode 100644 index 000000000000..d2779ba1ea8d --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseRadioButton.idl @@ -0,0 +1,92 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseRadioButton_idl__ +#define __com_sun_star_form_binding_BindableDatabaseRadioButton_idl__ + +#ifndef __com_sun_star_form_component_DatabaseRadioButton_idl__ +#include <com/sun/star/form/component/DatabaseRadioButton.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a radio button which is data-aware and thus can be bound to a + database field, and additionally supports binding to arbitrary external values. + + <p>The <type scope="com::sun::star::form::binding">XValueBinding</type> instance which + can be associated with a <type>BindableDatabaseRadioButton</type> must support exchanging + boolean values. The following mapping between external values and control states apply: + <ul><li><TRUE/> will be mapped to the button being checked, and vice versa</li> + <li><FALSE/> will be mapped to it being unchecked, and vice versa</li> + <li><NULL/> will be mapped to it being in indetermined state</li> + </ul></p> + + <p>If the value binding associated with a <type>BindableDatabaseRadioButton</type> + supports exchanging string values, <em>and</em> the <member scope="com::sun::star::form::component">RadioButton::RefValue</member> + is <em>not</em> empty, then the radio button will exchange it's value as string: + <ul><li>A string equal to the reference value will be mapped to the button being checked, and vice versa</li> + <li>A string not equal to the reference value will be mapped to the button being unchecked, and vice versa</li> + <li><NULL/> will be mapped to it being in indetermined state</li> + </ul></p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + @see com::sun::star::awt::UnoControlRadioButtonModel::State + @see com::sun::star::form::component::RadioButton::RefValue + */ +service BindableDatabaseRadioButton +{ + service com::sun::star::form::component::DatabaseRadioButton; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + + /** specifies a value which is to be associated with the control when it's <em>not</em> + selected. + + <p><member scope="com::sun::star::form::component">RadioButton::RefValue</member> is transferred to + possible external value bindings as soon as the radio button is selected. With the member + <member>SecondaryRefValue</member>, clients of the radio button can also associate a value with + the <em>not selected</em> state of the control.</p> + */ + [property] string SecondaryRefValue; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseTextField.idl b/offapi/com/sun/star/form/binding/BindableDatabaseTextField.idl new file mode 100644 index 000000000000..81906b7759a5 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseTextField.idl @@ -0,0 +1,72 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseTextField_idl__ +#define __com_sun_star_form_binding_BindableDatabaseTextField_idl__ + +#ifndef __com_sun_star_form_component_DatabaseTextField_idl__ +#include <com/sun/star/form/component/DatabaseTextField.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a text input field which is data-aware and thus can be bound to a + database field, and additionally supports binding to arbitrary external values. + + <p>If an <type scope="com::sun::star::form::binding">ValueBinding</type> instance is + set at the field, it will exchange it's text with the binding as <em>string</em>, thus only + bindings supporting string exchange will be accepted in + <member scope="com::sun::star::form::binding">XValueBinding::setValueBinding</member>. + </p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + @see com::sun::star::awt::UnoControlEditModel::Text + */ +service BindableDatabaseTextField +{ + service com::sun::star::form::component::DatabaseTextField; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableDatabaseTimeField.idl b/offapi/com/sun/star/form/binding/BindableDatabaseTimeField.idl new file mode 100644 index 000000000000..fafa1a06a507 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableDatabaseTimeField.idl @@ -0,0 +1,70 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableDatabaseTimeField_idl__ +#define __com_sun_star_form_binding_BindableDatabaseTimeField_idl__ + +#ifndef __com_sun_star_form_component_DatabaseTimeField_idl__ +#include <com/sun/star/form/component/DatabaseTimeField.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableDataAwareControlModel_idl__ +#include <com/sun/star/form/binding/BindableDataAwareControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** This service specifies a date input field which is data-aware and thus can be bound to a + database field, and additionally supports binding to arbitrary external values. + + <p>If an <type scope="com::sun::star::form::binding">ValueBinding</type> instance is + set at the field, it will exchange it's content with the binding as <type scope="com::sun::star::util">Time</type>. + </p> + + @see com::sun::star::form::binding::XValueBinding::supportsType + @see com::sun::star::awt::UnoControlTimeFieldModel::Time + */ +service BindableDatabaseTimeField +{ + service com::sun::star::form::component::DatabaseTimeField; + + /** specifies the interaction between an internal binding to a database column, + and an external value binding.</p> + */ + service com::sun::star::form::binding::BindableDataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/BindableIntegerValueRange.idl b/offapi/com/sun/star/form/binding/BindableIntegerValueRange.idl new file mode 100644 index 000000000000..478c6875f717 --- /dev/null +++ b/offapi/com/sun/star/form/binding/BindableIntegerValueRange.idl @@ -0,0 +1,75 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_BindableIntegerValueRange_idl__ +#define __com_sun_star_form_binding_BindableIntegerValueRange_idl__ + +#ifndef __com_sun_star_form_binding_BindableControlModel_idl__ +#include <com/sun/star/form/binding/BindableControlModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** this service specifies a <type>BindableControlModel</type> which reflects + an integer value, out of a range of permitted integer values. + + <p><type>BindableIntegerValueRange</type>s have a value property, a minimum, and a maximum, + all of type integer.</p> +*/ +service BindableIntegerValueRange +{ + /** specifies that the control can be bound to external values + + <p>Any binding used with the control model (see <member>XBindableValue::setValueBinding</member>) + must support exchanging double values.</p> + + <p>When the (integer) value reflected by the control model is changed, it's converted + into an double value and propagated to the binding.</p> + + <p>When the external (double) value changes, it's converted as follows to an integer + value: + <ul><li>If the external value is <NULL/>, the current value of the control model + will be set to it's minimum.</li> + <li>If the external value is the <em>infinite</em> value, the control value will + be set to its maximum or minimum, depending on the sign of the external value.</li> + <li>If none of the aforementioned conditions is met, the external value will be simply + rounded.</li> + </ul> + */ + service com::sun::star::form::binding::BindableControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/IncompatibleTypesException.idl b/offapi/com/sun/star/form/binding/IncompatibleTypesException.idl new file mode 100644 index 000000000000..4f0b6551e973 --- /dev/null +++ b/offapi/com/sun/star/form/binding/IncompatibleTypesException.idl @@ -0,0 +1,54 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_binding_IncompatibleTypesException_idl__ +#define __com_sun_star_form_binding_IncompatibleTypesException_idl__ + +#ifndef __com_sun_star_uno_Exception_idl__ +#include <com/sun/star/uno/Exception.idl> +#endif + + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** thrown to indicate that the types of an <type>XValueBinding</type> and + an <type>XBindableValue</type> are incompatible +*/ +exception IncompatibleTypesException: com::sun::star::uno::Exception +{ +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/binding/InvalidBindingStateException.idl b/offapi/com/sun/star/form/binding/InvalidBindingStateException.idl new file mode 100644 index 000000000000..d25f6159e88b --- /dev/null +++ b/offapi/com/sun/star/form/binding/InvalidBindingStateException.idl @@ -0,0 +1,54 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_binding_InvalidBindingStateException_idl__ +#define __com_sun_star_form_binding_InvalidBindingStateException_idl__ + +#ifndef __com_sun_star_uno_Exception_idl__ +#include <com/sun/star/uno/Exception.idl> +#endif + + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** thrown when an <type>XValueBinding</type> cannot perform a requested + operation due to an invalid state. +*/ +exception InvalidBindingStateException: com::sun::star::uno::Exception +{ +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/binding/ListEntryEvent.idl b/offapi/com/sun/star/form/binding/ListEntryEvent.idl new file mode 100644 index 000000000000..046888d7b8cc --- /dev/null +++ b/offapi/com/sun/star/form/binding/ListEntryEvent.idl @@ -0,0 +1,74 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_ListEntryEvent_idl__ +#define __com_sun_star_form_binding_ListEntryEvent_idl__ + +#ifndef __com_sun_star_lang_EventObject_idl__ +#include <com/sun/star/lang/EventObject.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** specifies the event which is notified when a change in a string entry + list occured + + @see XListEntrySource + @see XListEntryListener +*/ +struct ListEntryEvent : com::sun::star::lang::EventObject +{ + /** denotes the position where a change occured. + + <p>The concrete semantics of the value depends on the concrete + event being notified.</p> + */ + long Position; + + /** denotes the number of changed entries, in case a change of + an entry <em>range</em> is being notified. + */ + long Count; + + /** denotes the changed entries + + <p>The concrete semantics of the value depends on the concrete + event being notified.</p> + */ + sequence< string > + Entries; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/ListEntrySource.idl b/offapi/com/sun/star/form/binding/ListEntrySource.idl new file mode 100644 index 000000000000..15ea1f3bcf27 --- /dev/null +++ b/offapi/com/sun/star/form/binding/ListEntrySource.idl @@ -0,0 +1,74 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_ListEntrySource_idl__ +#define __com_sun_star_form_binding_ListEntrySource_idl__ + +#ifndef __com_sun_star_form_binding_XListEntrySource_idl__ +#include <com/sun/star/form/binding/XListEntrySource.idl> +#endif +#ifndef __com_sun_star_lang_XComponent_idl__ +#include <com/sun/star/lang/XComponent.idl> +#endif +#ifndef __com_sun_star_util_XModifyBroadcaster_idl__ +#include <com/sun/star/util/XModifyBroadcaster.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** defines a component which provides a list of string entries +*/ +service ListEntrySource +{ + //------------------------------------------------------------------------- + /** allows read access to the entries represented by this component + */ + interface XListEntrySource; + + /** allows life time control for the component + + <p>An <type>ListEntrySource</type> will be known to one ore more components + supporting the <type>XListEntrySink</type> interface, which all work with + this source. However, they will not <em>own</em> the <type>ListEntrySource</type>. + The ownership is with another instance, which may also decide to obsolete + the <type>ListEntrySource</type> for whatever reasons (e.g. because the data model + which the binding reflected died). For this reason, a <type>ListEntrySource</type> + must offer a possibility to be obsoleted by it's owner, and to notify this + obsoletion to other interested parties, such as <type>XListEntrySink</type>s.</p> + */ + interface com::sun::star::lang::XComponent; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/ValueBinding.idl b/offapi/com/sun/star/form/binding/ValueBinding.idl new file mode 100644 index 000000000000..f7c99e8ca6af --- /dev/null +++ b/offapi/com/sun/star/form/binding/ValueBinding.idl @@ -0,0 +1,124 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_ValueBinding_idl__ +#define __com_sun_star_form_binding_ValueBinding_idl__ + +#ifndef __com_sun_star_util_XValueBinding_idl__ +#include <com/sun/star/form/binding/XValueBinding.idl> +#endif +#ifndef __com_sun_star_beans_XPropertySet_idl__ +#include <com/sun/star/beans/XPropertySet.idl> +#endif +#ifndef __com_sun_star_lang_XComponent_idl__ +#include <com/sun/star/lang/XComponent.idl> +#endif +#ifndef __com_sun_star_util_XModifyBroadcaster_idl__ +#include <com/sun/star/util/XModifyBroadcaster.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** defines a component which allows access to a single value + + <p>Read/Write access to the value represented by this component is supported, + as well as (optionally) active broadcasting of value changes</p> +*/ +service ValueBinding +{ + /** determines whether the value is currently readonly + + <p>For instance, you could imagine a <type>ValueBinding</type> which + represents a cell in a spreadsheet document, and whose value is readonly + as long as the spreadsheet is locked.</p> + + <p>As long as this property is <TRUE/>, the value binding should throw + a <type>InvalidBindingStateException</type> when its + <member>XValueBinding::setValue</member> method is invoked.</p> + */ + [optional, property, bound, readonly] boolean ReadOnly; + + /** determines the relevance of the value represented by the binding + + <p>In a more complex scenario, where different form controls are bound to different + values, which all are part of a larger data structure, some of the items in this + data structure may not be relevant currently. This is indicated by the + <member>Relevant</member> property being <FALSE/>.</p> + + <p><type>XBindableValue</type>s which are bound to this binding may or may not + react in certain ways on the (ir)relevance of their bound value.</p> + + <p>One possible reaction could be that user interface elements which are associated + with the <type>XBindableValue</type> are disabled as long as <member>Relevant</member> + is <FALSE/>.</p> + */ + [optional, property, bound, readonly] boolean Relevant; + + //------------------------------------------------------------------------- + /** allows access to the properties of the binding + */ + [optional] interface com::sun::star::beans::XPropertySet; + + //------------------------------------------------------------------------- + /** allows read and write access to the value represented by this binding + */ + interface XValueBinding; + + /** allows other components to be notified when the value represented + by the <type>ValueBinding</type> instance changes. + + <p>This interface is optional, since a binding may not support + actively notifying changes in it's value. Note, however, that in case + this interface is not supported, the bound component cannot react + on value changes, and will thus override any values which are + set by an instance other than itself.</p> + */ + [optional] interface com::sun::star::util::XModifyBroadcaster; + + /** allows life time control for the component + + <p>An <type>ValueBinding</type> may be known to one ore more components + supporting the <type>XBindableValue</type> interface, which all work with + this binding. However, they will not <em>own</em> the <type>ValueBinding</type>. + The ownership is with another instance, which may also decide to obsolete + the <type>ValueBinding</type> for whatever reasons (e.g. because the data model + which the binding reflected died). For this reason, a <type>ValueBinding</type> + must offer a possibility to be obsoleted by it's owner, and to notify this + obsoletion to other interested parties, such as <type>XBindableValue</type>s.</p> + */ + interface com::sun::star::lang::XComponent; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/XBindableValue.idl b/offapi/com/sun/star/form/binding/XBindableValue.idl new file mode 100644 index 000000000000..2d8413029323 --- /dev/null +++ b/offapi/com/sun/star/form/binding/XBindableValue.idl @@ -0,0 +1,78 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_XBindableValue_idl__ +#define __com_sun_star_form_binding_XBindableValue_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif +#ifndef __com_sun_star_form_binding_IncompatibleTypesException_idl__ +#include <com/sun/star/form/binding/IncompatibleTypesException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +interface XValueBinding; + +//============================================================================= + +/** specifies support for being bound to an external value + + @see XValueBinding +*/ +interface XBindableValue : com::sun::star::uno::XInterface +{ + /** sets an external instance which controls the value of the component + + <p>Any previously active binding will be revoked. There can be only one!</p> + + @param aBinding + the new binding which is to be used by the component. May be <NULL/>, + in this case only the current binding is revoked. + + @throws <type>IncompatibleTypesException</type> + if the new binding (provided it's not <NULL/>) supports only types + which are incompatible with the types of the bindable component. + */ + void setValueBinding( [in] XValueBinding aBinding ) + raises ( IncompatibleTypesException ); + + /** retrieves the external instance which currently controls the value of the + component + */ + XValueBinding + getValueBinding( ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/XListEntryListener.idl b/offapi/com/sun/star/form/binding/XListEntryListener.idl new file mode 100644 index 000000000000..b48ec45198fc --- /dev/null +++ b/offapi/com/sun/star/form/binding/XListEntryListener.idl @@ -0,0 +1,89 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_XListEntryListener_idl__ +#define __com_sun_star_form_binding_XListEntryListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif +#ifndef __com_sun_star_form_binding_ListEntryEvent_idl__ +#include <com/sun/star/form/binding/ListEntryEvent.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** specifies a listener for changes in a string entry list +*/ +interface XListEntryListener : com::sun::star::lang::XEventListener +{ + /** notifies the listener that a single entry in the list has change + + @param Source + is the event describing the change. The <member>ListEntryEvent::Position</member> + member denotes the position of the changed entry, the first (and only) element + of the <member>ListEntryEvent::Entries</member> member denotes the new string + */ + void entryChanged( [in] ListEntryEvent Source ); + + /** notifies the listener that a range of entries has been inserted into the list + + @param Source + is the event describing the change. The <member>ListEntryEvent::Position</member> + member denotes the position of the first inserted entry, the + <member>ListEntryEvent::Entries</member> member contains the strings which have + been inserted. + */ + void entryRangeInserted( [in] ListEntryEvent Source ); + + /** notifies the listener that a range of entries has been removed from the list + + @param Source + is the event describing the change. The <member>ListEntryEvent::Position</member> + member denotes the position of the first removed entry, the + <member>ListEntryEvent::Count</member> member the number of removed entries. + */ + void entryRangeRemoved( [in] ListEntryEvent Source ); + + /** notifies the listener that all entries of the list have changed. + + <p>The listener should retrieve the complete new list by calling the + <member>XListEntrySource::getAllListEntries</member> method of the event source + (which is denoted by <member scope="com::sun::star::lang">EventObject::Source</member>). + */ + void allEntriesChanged( [in] com::sun::star::lang::EventObject Source ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/XListEntrySink.idl b/offapi/com/sun/star/form/binding/XListEntrySink.idl new file mode 100644 index 000000000000..0f2e84a8011d --- /dev/null +++ b/offapi/com/sun/star/form/binding/XListEntrySink.idl @@ -0,0 +1,68 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_XListEntrySink_idl__ +#define __com_sun_star_form_binding_XListEntrySink_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +interface XListEntrySource; + +//============================================================================= + +/** specifies support for indirect manipulation of of a string list +*/ +interface XListEntrySink : com::sun::star::uno::XInterface +{ + /** sets the new source for the list entries of the component + + <p>The list represented by this component will be cleared, and initially + filled with the entries from the new list source.</p> + + @param Source + the new source for the list entries. May be <NULL/>, in this + case, the current source is revoked. + */ + void setListEntrySource( [in] XListEntrySource Source ); + + /** retrieves the current source for the list entries of the component. + */ + XListEntrySource + getListEntrySource( ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/XListEntrySource.idl b/offapi/com/sun/star/form/binding/XListEntrySource.idl new file mode 100644 index 000000000000..4d6390b41ece --- /dev/null +++ b/offapi/com/sun/star/form/binding/XListEntrySource.idl @@ -0,0 +1,100 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_XListEntrySource_idl__ +#define __com_sun_star_form_binding_XListEntrySource_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif +#ifndef __com_sun_star_lang_NullPointerException_idl__ +#include <com/sun/star/lang/NullPointerException.idl> +#endif +#ifndef __com_sun_star_lang_IndexOutOfBoundsException_idl__ +#include <com/sun/star/lang/IndexOutOfBoundsException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +interface XListEntryListener; + +//============================================================================= + +/** specifies a source of string list entries + + <p>The interface supports foreign components which actively retrieve list entries, + as well as components which want to passively being notified of changes in the list.</p> + + @see XListEntrySink +*/ +interface XListEntrySource : com::sun::star::uno::XInterface +{ + /** retrieves the number of entries in the list + */ + long getListEntryCount( ); + + /** provides access to a single list entry + + @throws <type scope="com::sun::star::lang">IndexOutOfBoundsException</type> + if the given position does not denote a valid index in the list + + @see getListEntryCount + */ + string getListEntry( [in] long Position ) + raises( com::sun::star::lang::IndexOutOfBoundsException ); + + /** provides access to the entirety of all list entries + */ + sequence< string > + getAllListEntries( ); + + /** adds a listener which will be notified about changes in the list + reflected by the component. + + @throws <type scope="com::sun::star::lang">NullPointerException</type> + if the given listener is <NULL/> + */ + void addListEntryListener( [in] XListEntryListener Listener ) + raises( com::sun::star::lang::NullPointerException ); + + /** revokes the given listener from the list of components which will + be notfiied about changes in the entry list. + + @throws <type scope="com::sun::star::lang">NullPointerException</type> + if the given listener is <NULL/> + */ + void removeListEntryListener( [in] XListEntryListener Listener ) + raises( com::sun::star::lang::NullPointerException ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/XValueBinding.idl b/offapi/com/sun/star/form/binding/XValueBinding.idl new file mode 100644 index 000000000000..207b3ec7e7ad --- /dev/null +++ b/offapi/com/sun/star/form/binding/XValueBinding.idl @@ -0,0 +1,104 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_binding_XValueBinding_idl__ +#define __com_sun_star_form_binding_XValueBinding_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif +#ifndef __com_sun_star_lang_NoSupportException_idl__ +#include <com/sun/star/lang/NoSupportException.idl> +#endif +#ifndef __com_sun_star_form_binding_IncompatibleTypesException_idl__ +#include <com/sun/star/form/binding/IncompatibleTypesException.idl> +#endif +#ifndef __com_sun_star_form_binding_InvalidBindingStateException_idl__ +#include <com/sun/star/form/binding/InvalidBindingStateException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module binding { + +//============================================================================= + +/** specifies a binding to a value which can be read and written. +*/ +interface XValueBinding : com::sun::star::uno::XInterface +{ + //------------------------------------------------------------------------- + /** determines the types which are supported by this binding for value exchange + + @see supportsType + */ + sequence< type > + getSupportedValueTypes( ); + + /** determines whether a given type is supported by this binding for value exchange + + <p>Calling this method is equal to calling <member>getSupportedValueTypes</member>, + and looking up the given type in the resulting type sequence.</p> + + @see getSupportedValueTypes + */ + boolean supportsType( [in] type aType ); + + /** retrieves the current value + + @throws <type>IncompatibleTypesException</type> + if the requested value type is not supported by the binding + @see getSupportedValueTypes + @see supportsType + */ + any getValue( [in] type aType ) + raises( IncompatibleTypesException ); + + /** sets the current value + + @throws <type>IncompatibleTypesException</type> + if the given value type is not supported by the binding + @throws <type>InvalidBindingStateException</type> + if the value currently cannot be changed, since the binding is not + fully operational. Possible reasons for this include the binding being + readonly, or the target of the binding not being present. + @throws <type scope="com::sun::star::lang">NoSupportException</type> + if the binding in general does not support write access to it's binding + + @see getSupportedValueTypes + @see supportsType + @see ValueBinding + */ + void setValue( [in] any aValue ) + raises( IncompatibleTypesException, InvalidBindingStateException, com::sun::star::lang::NoSupportException ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/binding/makefile.mk b/offapi/com/sun/star/form/binding/makefile.mk new file mode 100644 index 000000000000..dc9885f5fd55 --- /dev/null +++ b/offapi/com/sun/star/form/binding/makefile.mk @@ -0,0 +1,69 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/..$/..$/.. + +PRJNAME=offapi + +TARGET=cssfbinding +PACKAGE=com$/sun$/star$/form$/binding + +# --- Settings ----------------------------------------------------- +.INCLUDE : $(PRJ)$/util$/makefile.pmk + +# ------------------------------------------------------------------------ + +IDLFILES=\ + XBindableValue.idl \ + XValueBinding.idl \ + ValueBinding.idl \ + XListEntrySink.idl \ + XListEntrySource.idl \ + XListEntryListener.idl \ + ListEntryEvent.idl \ + ListEntrySource.idl \ + \ + BindableControlModel.idl \ + BindableIntegerValueRange.idl \ + BindableDataAwareControlModel.idl \ + BindableDatabaseCheckBox.idl \ + BindableDatabaseComboBox.idl \ + BindableDatabaseDateField.idl \ + BindableDatabaseFormattedField.idl \ + BindableDatabaseListBox.idl \ + BindableDatabaseNumericField.idl \ + BindableDatabaseRadioButton.idl \ + BindableDatabaseTextField.idl \ + BindableDatabaseTimeField.idl \ + \ + IncompatibleTypesException.idl \ + InvalidBindingStateException.idl \ + +# ------------------------------------------------------------------ + +.INCLUDE : target.mk +.INCLUDE : $(PRJ)$/util$/target.pmk diff --git a/offapi/com/sun/star/form/component/CheckBox.idl b/offapi/com/sun/star/form/component/CheckBox.idl new file mode 100644 index 000000000000..5db7acb3d2a6 --- /dev/null +++ b/offapi/com/sun/star/form/component/CheckBox.idl @@ -0,0 +1,92 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_CheckBox_idl__ +#define __com_sun_star_form_component_CheckBox_idl__ + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_awt_UnoControlCheckBoxModel_idl__ +#include <com/sun/star/awt/UnoControlCheckBoxModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies the model of a check box control + + <p>The model supports the properties required for HTML, thus you can build up + <type>HTMLForm</type>s with it</p> + */ +published service CheckBox +{ + service com::sun::star::awt::UnoControlCheckBoxModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default state. + + @see CheckBox::DefaultState + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlCheckBoxModel::State + @see com::sun::star::form::XReset + */ + [property] short DefaultState; + + //------------------------------------------------------------------------- + + /** contains a reference value which is used for submission in a HTML + form + + <p>When submitting a <type>HTMLForm</type> which contains a check box, + which is checked, the RefValue is used for submission. + */ + [property] string RefValue; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/ComboBox.idl b/offapi/com/sun/star/form/component/ComboBox.idl new file mode 100644 index 000000000000..c5d02077cad8 --- /dev/null +++ b/offapi/com/sun/star/form/component/ComboBox.idl @@ -0,0 +1,78 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_ComboBox_idl__ +#define __com_sun_star_form_component_ComboBox_idl__ + +#ifndef __com_sun_star_awt_UnoControlComboBoxModel_idl__ +#include <com/sun/star/awt/UnoControlComboBoxModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies a component which allows the input of text or selection + of text from a list of text values. + */ +published service ComboBox +{ + service com::sun::star::awt::UnoControlComboBoxModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default text. + + @see ComboBox::DefaultText + */ + interface com::sun::star::form::XReset; + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlComboBoxModel::Text + @see com::sun::star::form::XReset + */ + [property] string DefaultText; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/CommandButton.idl b/offapi/com/sun/star/form/component/CommandButton.idl new file mode 100644 index 000000000000..249f66c5923a --- /dev/null +++ b/offapi/com/sun/star/form/component/CommandButton.idl @@ -0,0 +1,116 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_CommandButton_idl__ +#define __com_sun_star_form_component_CommandButton_idl__ + +#include <com/sun/star/form/FormControlModel.idl> +#include <com/sun/star/awt/UnoControlButtonModel.idl> +#include <com/sun/star/form/XImageProducerSupplier.idl> +#include <com/sun/star/form/XApproveActionBroadcaster.idl> +#include <com/sun/star/form/FormButtonType.idl> +#include <com/sun/star/form/XReset.idl> + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies the control model for a clickable button which is part of a form + component hierarchy. + + @see ImageButton + */ +published service CommandButton +{ + service com::sun::star::awt::UnoControlButtonModel; + + service com::sun::star::form::FormControlModel; + + /** supplies the image producer when the button is to display an image. + + <p>If the <member scope="com::sun::star::awt">UnoControlButtonModel::ImageURL</member> points to the location of an + image to be displayed on the button, this interface can be used to retrieve an image + producer, which itself will supply the image.</p> + + <p>Usually, a control belonging to the model will use this interface to obtain the + image to be painted</p> + */ + interface com::sun::star::form::XImageProducerSupplier; + + //------------------------------------------------------------------------- + + /** describes the action to be executed by the button when pressed. + */ + [property] com::sun::star::form::FormButtonType ButtonType; + + /** describes the frame, where to open the document specified by the TargetURL. + + <p>This property is evaluated if the button is of type URL.</p> + + <p>As always, there is a number of target names which have a special meaning, and force + a special <type scope="com::sun::star::frame">Frame</type> to be used.</p> + */ + [property] string TargetFrame; + + /** specifies the URL, which should be opened if the button was clicked. + + <p>This property is evaluated if the button is of type URL.</p> + + @see com::sun::star::form::FormButtonType + */ + [property] string TargetURL; + + /** specifies the default toggle state for the button, used when it is reset. + + <p>This property is meaningful only when <member scope="com::sun::star::awt">UnoControlButtonModel::Toggle</member> + is <TRUE/>. In this case, the <code>DefaultState</code> controls to which <code>State</code> the button will + be reset.</p> + + <p>For a given implementation of the interface, if this (optional) property is present, then also the optional + interface <type scope="com::sun::star::form">XReset</type> must be present.</p> + */ + [optional, property] boolean DefaultState; + + /** allows resetting the button + + <p>This property is meaningful only when <member scope="com::sun::star::awt">UnoControlButtonModel::Toggle</member> + is <TRUE/>. In this case, the <code>DefaultState</code> controls to which <code>State</code> the button will + be reset, when <member scope="com::sun::star::form">XReset::reset</member> is invoked.</p> + + <p>For a given implementation of the interface, if this (optional) interface is present, then also the optional + property <member>DefaultState</member> must be present.</p> + */ + [optional] interface ::com::sun::star::form::XReset; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/CurrencyField.idl b/offapi/com/sun/star/form/component/CurrencyField.idl new file mode 100644 index 000000000000..1e190f2ae1ca --- /dev/null +++ b/offapi/com/sun/star/form/component/CurrencyField.idl @@ -0,0 +1,77 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_CurrencyField_idl__ +#define __com_sun_star_form_component_CurrencyField_idl__ + +#ifndef __com_sun_star_awt_UnoControlCurrencyFieldModel_idl__ +#include <com/sun/star/awt/UnoControlCurrencyFieldModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies the ControlModel for an edit field which + contains a currency value. + */ +published service CurrencyField +{ + service com::sun::star::awt::UnoControlCurrencyFieldModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default state. + + @see CurrencyField::DefaultValue + */ + interface com::sun::star::form::XReset; + + /** contains a default value for the control. + + @see com::sun::star::awt::UnoControlCurrencyFieldModel::Value + @see com::sun::star::form::XReset + */ + [property] double DefaultValue; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DataForm.idl b/offapi/com/sun/star/form/component/DataForm.idl new file mode 100644 index 000000000000..9b5f1f03f757 --- /dev/null +++ b/offapi/com/sun/star/form/component/DataForm.idl @@ -0,0 +1,232 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DataForm_idl__ +#define __com_sun_star_form_component_DataForm_idl__ + +#ifndef __com_sun_star_form_component_Form_idl__ +#include <com/sun/star/form/component/Form.idl> +#endif + +#ifndef __com_sun_star_sdb_RowSet_idl__ +#include <com/sun/star/sdb/RowSet.idl> +#endif + +#ifndef __com_sun_star_form_TabulatorCycle_idl__ +#include <com/sun/star/form/TabulatorCycle.idl> +#endif + +#ifndef __com_sun_star_form_NavigationBarMode_idl__ +#include <com/sun/star/form/NavigationBarMode.idl> +#endif + +#ifndef __com_sun_star_form_XLoadable_idl__ +#include <com/sun/star/form/XLoadable.idl> +#endif + +#ifndef __com_sun_star_sdb_XCompletedExecution_idl__ +#include <com/sun/star/sdb/XCompletedExecution.idl> +#endif + +#ifndef __com_sun_star_awt_TabControllerModel_idl__ +#include <com/sun/star/awt/TabControllerModel.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { + + published interface XReset; + published interface XDatabaseParameterBroadcaster; + +module component { +//============================================================================= +/** This service specifies a form which is connected to a database and + displays the results of SQL queries. It provides the possiblity of + adding new data records, modifying existing ones, or deleting them. + + <p>A database form is a special kind of enhanced database row set + which provides all information for displaying the data and has more + possibilities for configuring the data manipulation.</p> + +*/ +published service DataForm +{ + service com::sun::star::sdb::RowSet; + service com::sun::star::form::component::Form; + + /** is used to reset controls belonging to the form, and to reset database fields to which the + controls are bound + + <p>A <type>DataForm</type> is reset either on explicit request, or after it is moved + to the insertion row.</p> + + <p>The insertion row is a virtual row which is used to insert new records. It is reached + by calling <member scope="com::sun::star::sdbc">XResultSetUpdate::moveToInsertRow</member>. + The <type scope="com::sun::star::sdb">RowSet</type> service specifies exactly which notifications + happen in which order when calling <member scope="com::sun::star::sdbc">XResultSetUpdate::moveToInsertRow</member>, + and a <type>DataForm</type> implementation extends this with the following contract: + <ul><li>After all notifications as defined in the <type scope="com::sun::star::sdb">RowSet</type> + service have been sent, the <type>DataForm</type> resets itself, if all + <type scope="com::sun::star::form">XResetListeners</type> approve this.</li> + <li>After the reset happened, the <member scope="com::sun::star::sdb">RowSet::IsModified</member> + property is reset to <FALSE/>. This property might have been switched to <TRUE/> during listener + notifications, since listeners are allowed to change field values. Also, the + <member scope="com::sun::star::form">XReset::reset</member> implementations of bound control + models might have modified the fields they're bound to (by filling them with default values).</li> + <li>The reset listeners are notified of the completed reset operation.</li> + </ul></p> + */ + interface com::sun::star::form::XReset; + + /** used to load/unload the form + <p>Loading a form is basically the same as executing the underlying row set. In fact, all the + functionality of this interface could be simulated by using setting some properties manually, + <member scope="com::sun::star::sdbc">XRowSet::execute</member>, moving the row set cursor and so on.</p> + + <p>One main difference between <member>XLoadable::load</member> and <member scope="com::sun::star::sdbc">XRowSet::execute</member> + is that if you use the former, the row set is positioned on the first record, while in the latter case + it is position <em>before</em> the it.</p> + */ + interface com::sun::star::form::XLoadable; + + /** can be used to allow an interaction handler to supply missing data during a load process. + + <p>If data is needed during loading a form, then this is usually obtained via broadcaster-listener + mechanisms. An example for this (and currently the only one) are parameter values.</p> + <p>However, if you use this method, you can pass an interaction handler which should supply these + additional data.</p> + + @see com::sun::star::sdb::InteractionHandler + */ + interface com::sun::star::sdb::XCompletedExecution; + + /** can be used for filling parameters. + + <p>You can add your component as + <type scope="com::sun::star::form">XDatabaseParameterListener</type> + to a form to get notified whenever the form needs parameter values to be filled in<br/> + In a first approach, the form tries to fill any parameters from it's master-detail relation + (if any). All values which can't be filled are then passed to all listeners, which can + fill them by their own choice.</p> + + <p>This is sligtly changed if the form is loaded using the + <member scope="com::sun::star::sdb">XCompletedExecution::connectWithCompletion</member> method. In this case, the parameters + are obtained from the interaction handler, not from the listeners</p> + + @see XCompletedExecution + @see MasterFields + @see DetailFields + */ + interface com::sun::star::form::XDatabaseParameterBroadcaster; + + //------------------------------------------------------------------------- + /** is used for subforms and contains the names of columns of the parent form. + + <p> These columns are typically the foreign key fields of the parent form. + The values of theses columns are used to identify the data for the subform. + Each time the parent form changes it's current row, the subform requeries + it's data based on the values of the master fields.</p> + + <p>If the form is no sub form (e.g. it's parent is not a form itself), this + property is not evaluated.</p> + */ + [property] sequence<string> MasterFields; + + //------------------------------------------------------------------------- + /** is used for subforms and contains the names of the columns of the subform + which are related to the master fields of the parent form. + + <p>Entries in this sequence can either denote column names in the sub form, + or paramater names.<br/> + For instance, you could base the form on the SQL statement + <code>SELECT * FROM invoices WHERE cust_ref = :cid</code>, and add <code>cid</code> + to the DetailFields property. In this case, the parameter will be filled from + the corresponding master field.<br/> + Alternatively, you could simply base your form on the table <code>invoices</code>, + and add the column name <code>cust_ref</code> to the DetailFields. In this case, + and implicit filter clause <code>WHERE cust_ref = :<new_param_name></code> will + be created, and the artificial parameter will be filled from the corresponding + master field.<br/> + If a string in this property denotes both a column name and a parameter name, it + is undefined which way it is interpreted, but implementations of the service are required + to either decide for the paramter or the column, and proceed as usual. + </p> + + <p>The columns specified herein typically represent a part of the primary key + fields or their aliases of the detail form.</p> + + <p>If the form is no sub form (e.g. it's parent is not a form itself), this + property is not evaluated.</p> + */ + [property] sequence<string> DetailFields; + + //------------------------------------------------------------------------- + /** returns the kind of tabulator controlling. + */ + [property] com::sun::star::form::TabulatorCycle Cycle; + + //------------------------------------------------------------------------- + /** determines how an navigation bar for this form should act. + */ + [property] com::sun::star::form::NavigationBarMode NavigationBarMode; + + //------------------------------------------------------------------------- + /** determines if insertions into the form's row set are allowed. + + <p>Note that this is a recommendation for user interface components displaying the + form. Form implementations may decide to allow for insertions done via the API, even + if the property is set to <FALSE/>, but the user interface should respect the property + value.</p> + */ + [property] boolean AllowInserts; + + //------------------------------------------------------------------------- + /** determines if modifications of the current record of the form are allowed. + + <p>Note that this is a recommendation for user interface components displaying the + form. Form implementations may decide to allow for updates done via the API, even + if the property is set to <FALSE/>, but the user interface should respect the property + value.</p> + */ + [property] boolean AllowUpdates; + + //------------------------------------------------------------------------- + /** determines if deletions of records of the form are allowed. + + <p>Note that this is a recommendation for user interface components displaying the + form. Form implementations may decide to allow for deletions done via the API, even + if the property is set to <FALSE/>, but the user interface should respect the property + value.</p> + */ + [property] boolean AllowDeletes; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseCheckBox.idl b/offapi/com/sun/star/form/component/DatabaseCheckBox.idl new file mode 100644 index 000000000000..82f49ad55d02 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseCheckBox.idl @@ -0,0 +1,64 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseCheckBox_idl__ +#define __com_sun_star_form_component_DatabaseCheckBox_idl__ + +#ifndef __com_sun_star_form_component_CheckBox_idl__ +#include <com/sun/star/form/component/CheckBox.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a check box which is data-aware, and can be bound to a database field. + + <p>Mostly, you will create data-aware checkboxes as tristate checkboxes, because this + is a requirement to correctly handle <NULL/> values in databases.</p> + + @see ::com::sun::star::awt::UnoControlCheckBoxModel::TriState + */ +published service DatabaseCheckBox +{ + service com::sun::star::form::component::CheckBox; + + service com::sun::star::form::DataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseComboBox.idl b/offapi/com/sun/star/form/component/DatabaseComboBox.idl new file mode 100644 index 000000000000..2ccca56dbb3e --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseComboBox.idl @@ -0,0 +1,96 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseComboBox_idl__ +#define __com_sun_star_form_component_DatabaseComboBox_idl__ + +#ifndef __com_sun_star_form_component_ComboBox_idl__ +#include <com/sun/star/form/component/ComboBox.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + +#ifndef __com_sun_star_form_ListSourceType_idl__ +#include <com/sun/star/form/ListSourceType.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a combo box which is data-aware, and can be bound to a database field. + + <p>Like most other data aware controls, such a combo box will display the actual content + of the field it is bound to. In addition, as a combo box contains a list where the user + can choose items to fill into the control, this list can be filled with different data from + a database, too.</p> + */ +published service DatabaseComboBox +{ + service com::sun::star::form::component::ComboBox; + + service com::sun::star::form::DataAwareControlModel; + + //------------------------------------------------------------------------- + + /** determines if an empty text should be treated as a <NULL/> value. + + <p>When the user enters text into a combo box, and after this, the control + content is to be committed into the database field the control is bound to, + a decision must be made how to deal with empty strings.<br/> + This is controlled by <member>ConvertEmptyToNull</member>.</p> + + <p>If the property is set to <TRUE/>, and an empty text is to be commited, this is + converted into <NULL/>, else it is written as empty string.</p> + */ + [property] boolean ConvertEmptyToNull; + + /** describes the source of items in the combo box' list. + + <p>The concrete meaning of this property depends on the value of <member>ListSourceType</member></p> + */ + [property] string ListSource; + //------------------------------------------------------------------------- + + /** specifies the kind of list source. + + <p>Note: A value of <member scope="com::sun::star::form">ListSourceType::VALUELIST</member> + is not valid for a combo box. It won't be rejected when setting it, but controls will usually ignore it + and leave the list empty.</p> + */ + [property] com::sun::star::form::ListSourceType ListSourceType; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseCurrencyField.idl b/offapi/com/sun/star/form/component/DatabaseCurrencyField.idl new file mode 100644 index 000000000000..3d56099c31d7 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseCurrencyField.idl @@ -0,0 +1,59 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseCurrencyField_idl__ +#define __com_sun_star_form_component_DatabaseCurrencyField_idl__ + +#ifndef __com_sun_star_form_component_CurrencyField_idl__ +#include <com/sun/star/form/component/CurrencyField.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a currency field which is data-aware, and can be bound to a database field. + */ +published service DatabaseCurrencyField +{ + service com::sun::star::form::component::CurrencyField; + + service com::sun::star::form::DataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseDateField.idl b/offapi/com/sun/star/form/component/DatabaseDateField.idl new file mode 100644 index 000000000000..8673636874b0 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseDateField.idl @@ -0,0 +1,59 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseDateField_idl__ +#define __com_sun_star_form_component_DatabaseDateField_idl__ + +#ifndef __com_sun_star_form_component_DateField_idl__ +#include <com/sun/star/form/component/DateField.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a date field which is data-aware, and can be bound to a database field. + */ +published service DatabaseDateField +{ + service com::sun::star::form::component::DateField; + + service com::sun::star::form::DataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseFormattedField.idl b/offapi/com/sun/star/form/component/DatabaseFormattedField.idl new file mode 100644 index 000000000000..575ad5d8ff02 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseFormattedField.idl @@ -0,0 +1,73 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseFormattedField_idl__ +#define __com_sun_star_form_component_DatabaseFormattedField_idl__ + +#ifndef __com_sun_star_form_component_FormattedField_idl__ +#include <com/sun/star/form/component/FormattedField.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a formatted field model which is data-aware, and can be bound to a database field. + */ +published service DatabaseFormattedField +{ + service com::sun::star::form::component::FormattedField; + + service com::sun::star::form::DataAwareControlModel; + + //------------------------------------------------------------------------- + + /** determines if an empty text should be treated as a <NULL/> value. + + <p>When the user enters text into a formatted field control, and after this, the control + content is to be committed into the database field the control is bound to, + a decision must be made how to deal with empty strings.<br/> + This is controlled by <member>ConvertEmptyToNull</member>.</p> + + <p>If the property is set to <TRUE/>, and an empty text is to be commited, this is + converted into <NULL/>, else it is written as empty string.</p> + */ + [property] boolean ConvertEmptyToNull; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseImageControl.idl b/offapi/com/sun/star/form/component/DatabaseImageControl.idl new file mode 100644 index 000000000000..731a27437bf5 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseImageControl.idl @@ -0,0 +1,122 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseImageControl_idl__ +#define __com_sun_star_form_component_DatabaseImageControl_idl__ + +#ifndef __com_sun_star_awt_UnoControlImageControlModel_idl__ +#include <com/sun/star/awt/UnoControlImageControlModel.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XImageProducerSupplier_idl__ +#include <com/sun/star/form/XImageProducerSupplier.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies the model of a control used for displaying images stored in a database. + + <p>As every <type scope="com::sun::star::form">DataAwareControlModel</type>, an image control + can be bound to a database field. This means that for instance with every record change, the content + of the database field is taken, interpreted as image, and displayed in the control.<br/> + Unlike other more text-based controls, it does not interpret the content of the field as text or double, + but as binary stream (see <member scope="com::sun::star::sdb">XColumn::getBinaryStream</member>).</p> + + <p>Usually, an image control model can be bound to binary columns only, namely + <member scope="com::sun::star::sdbc">DataType::BINARY</member>, + <member scope="com::sun::star::sdbc">DataType::VARBINARY</member>, + <member scope="com::sun::star::sdbc">DataType::LONGVARBINARY</member>, + <member scope="com::sun::star::sdbc">DataType::OTHER</member>, + <member scope="com::sun::star::sdbc">DataType::LONGVARCHAR</member></p> + + <p/> + + <p>Note that besides taking the image to be displayed from the bound field, there is another option. The + <member scope="com::sun::star::awt">UnoControlImageControlModel::ImageURL</member> property specifies + the URL of an image to be displayed. If this property is changed from outside, the respective file + is loaded and set as image source.</p> + + <p>In a usual data form, the scenario will be as follows: + <ul><li>There is a DatabaseImageControl as part of the document model, which acts as + control model for an <type scope="com::sun::star::form::control">ImageControl</type>.</li> + + <li>The control is an <type scope="com::sun::star::awt">XImageConsumer</type> for the + <type scope="com::sun::star::awt">XImageProducer</type> supplied by the model.</li> + + <li>Whenever the form's cursor is positioned on a new record, the column the control + model is bound to is examined for a binary data stream. This stream is set as source + at the image producer, which notifies it's consumers, which leads to the control + displaying the image.</li> + + <li>When the user by some interaction tells the control to contain a new image, this is + exchanged by URL. For example, implementations of the control service may allow the user + to browse for image. After this, the URL of the image is set as + <member scope="com::sun::star::awt">UnoControlImageControlModel::ImageURL</member> + property at the model.<br/> + Now the control loads the image determined by the property value, and starts producing + a new data stream, which is displayed by the control (which is a consumer for this stream).<br/> + From now on, the control and thus the database record counts as modified. If the cursor of the + form is moved further, the modified record is saved, means the content of the image pointed to + by <member scope="com::sun::star::awt">UnoControlImageControlModel::ImageURL</member> + is saved into the column.</li> + </ul> + </p> + */ +published service DatabaseImageControl +{ + service com::sun::star::awt::UnoControlImageControlModel; + + service com::sun::star::form::DataAwareControlModel; + + /** supplies the caller with an <type scope="com::sun::star::awt">XImageProducer</type>. + + <p>Other components can register as <type scope="com::sun::star::awt">XImageConsumer</type> + at this producer. Then they will be notified of any change in the image to be displayed.</p> + */ + interface com::sun::star::form::XImageProducerSupplier; + + //------------------------------------------------------------------------- + + /** indicates if it is possible to change the image being displayed. + */ + [property] boolean ReadOnly; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseListBox.idl b/offapi/com/sun/star/form/component/DatabaseListBox.idl new file mode 100644 index 000000000000..daa06fef61b3 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseListBox.idl @@ -0,0 +1,159 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseListBox_idl__ +#define __com_sun_star_form_component_DatabaseListBox_idl__ + +#ifndef __com_sun_star_form_component_ListBox_idl__ +#include <com/sun/star/form/component/ListBox.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + +#ifndef __com_sun_star_form_ListSourceType_idl__ +#include <com/sun/star/form/ListSourceType.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a data-aware list box control model. + + <p>The base service for list boxes (<type>ListBox</type>) offers only + one possibility to specify the list entries: the <member>ListBox::ListSource</member> + property, which contains all the strings to be displayed.</p> + + <p>This service here extends this mimic. It allows to fill the list from a data source. + This means that a second result set is opened, which works on the same connection as the + form which the list box belongs to, but can be based on an arbitrary table or SQL statement.</p> + + <p>For instance, you may have a form which is bound to a table <em>invoice</em>, and you use it + to enter invoices for your customers. Probably, you will have a second table (say <em>customer</em>), + which (amonst other data) contains a unique key for identifying customers. In your invoice table, you will + have a foreign key referring to these customers.<br/> + Now, besides the result set the form is based on (all your invoices), the list box can be caused + to open a second result set, this time for the <em>customer</em> table, and fill it's list with entries + from this result set.<br/> + Additionally, it allows to model the relation between the two tables: When the user selects a customer from + the list, this customer has the unique id we just talked about (which is not necessarily visible to the + user in any way). The list box then automatically transfers this id into the foreign key column of + <em>invoice</em>, thus allowing the user to transparently work with human-readable strings instead of + pure numbers.<br/> + Let's call this result set the list is filled from the <em>list result set</em> here ...</p> + + */ +published service DatabaseListBox +{ + service com::sun::star::form::component::ListBox; + + service com::sun::star::form::DataAwareControlModel; + + //------------------------------------------------------------------------- + + /** specifies which column of the list result set should be used for data exchange. + + <p>When you make a selection from a list box, the "BoundColumn" + property reflects which column value of a result set should + be used as the value of the component. If the control is bound + to a database field, the column value is stored in the + database field identified by the property + <member scope="com::sun::star::form">DataAwareControlModel::DataField</member>. + + <dl> + <dt>0</dt> + <dd>The selected (displayed) list box string is stored in + the current database field.</dd> + + <dt>1 or greater</dt> + <dd>The column value of the result set at the position is + stored in the current database field.</dd> + </dl></p> + + <p>The bound column property is only used if a list source is defined + and the list source matches with the types + <member scope="com::sun::star::form">ListSourceType::TABLE</member>, + <member scope="com::sun::star::form">ListSourceType::QUERY</member>, + <member scope="com::sun::star::form">ListSourceType::SQL</member> or + <member scope="com::sun::star::form">ListSourceType::SQLPASSTHROUGH</member>. + Otherwise the property is ignored, as there is no result set from which to + get the column values.</p> + */ + [property] short BoundColumn; + + //------------------------------------------------------------------------- + + /** describes the kind of list source used. + + <p>Depending on the value of this property, the way the value of <member>ListBox::ListSource</member> + is evaluated varies. + <dl> + <dt><member scope="com::sun::star::form">ListSourceType::VALUELIST</member></dt> + <dd>The elements in the string sequence in <member>ListBox::ListSource</member> + build up the entry list.</dd> + + <dt><member scope="com::sun::star::form">ListSourceType::TABLE</member></dt> + <dd>The first element of the string sequence in <member>ListBox::ListSource</member> + determines the table which the list result set should be based on.</dd> + + <dt><member scope="com::sun::star::form">ListSourceType::QUERY</member></dt> + <dd>The first element of the string sequence in <member>ListBox::ListSource</member> + determines the query which the list result set should be based on.<br/> + For retrieving the query, the connection which the data form is working with + (<member scope="com::sun::star::sdb">RowSet::ActiveConnection</member>) is queried for + the <type scope="com::sun::star::sdb">XQueriesSupplier</type> interface.</dd> + + <dt><member scope="com::sun::star::form">ListSourceType::SQL</member></dt> + <dd>The first element of the string sequence in <member>ListBox::ListSource</member> + contains the SQL statement which the list result set should be based on.</p> + + <dt><member scope="com::sun::star::form">ListSourceType::SQLPASSTHROUGH</member></dt> + <dd>The first element of the string sequence in <member>ListBox::ListSource</member> + contains the SQL statement which the list result set should be based on.<br/> + The statement is not analyzed by the parser. This means that you can use database specific + SQL features here, but, on the other hand, loose features like parameter value substitution.</dd> + + <dt><member scope="com::sun::star::form">ListSourceType::TABLEFIELDS</member></dt> + <dd>The first element of the string sequence in <member>ListBox::ListSource</member> + determines the table which's column names should fill the list.</dd> + </dl> + </p> + + */ + [property] com::sun::star::form::ListSourceType ListSourceType; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseNumericField.idl b/offapi/com/sun/star/form/component/DatabaseNumericField.idl new file mode 100644 index 000000000000..57853d6ddc83 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseNumericField.idl @@ -0,0 +1,59 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseNumericField_idl__ +#define __com_sun_star_form_component_DatabaseNumericField_idl__ + +#ifndef __com_sun_star_form_component_NumericField_idl__ +#include <com/sun/star/form/component/NumericField.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a numeric field which is data-aware, and can be bound to a database field. + */ +published service DatabaseNumericField +{ + service com::sun::star::form::component::NumericField; + + service com::sun::star::form::DataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabasePatternField.idl b/offapi/com/sun/star/form/component/DatabasePatternField.idl new file mode 100644 index 000000000000..2488b4160cad --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabasePatternField.idl @@ -0,0 +1,74 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabasePatternField_idl__ +#define __com_sun_star_form_component_DatabasePatternField_idl__ + +#ifndef __com_sun_star_form_component_PatternField_idl__ +#include <com/sun/star/form/component/PatternField.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a data-aware control model for entering text which matches a specific + pattern. + */ +published service DatabasePatternField +{ + service com::sun::star::form::component::PatternField; + + service com::sun::star::form::DataAwareControlModel; + + //------------------------------------------------------------------------- + + /** determines if an empty text should be treated as a <NULL/> value. + + <p>When the user enters text into a pattern field, and after this, the control + content is to be committed into the database field the control is bound to, + a decision must be made how to deal with empty strings.<br/> + This is controlled by this property.</p> + + <p>If the property is set to <TRUE/>, and an empty text is to be commited, this is + converted into <NULL/>, else it is written as empty string.</p> + */ + [property] boolean ConvertEmptyToNull; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseRadioButton.idl b/offapi/com/sun/star/form/component/DatabaseRadioButton.idl new file mode 100644 index 000000000000..2b60c3fb5dd3 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseRadioButton.idl @@ -0,0 +1,59 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseRadioButton_idl__ +#define __com_sun_star_form_component_DatabaseRadioButton_idl__ + +#ifndef __com_sun_star_form_component_RadioButton_idl__ +#include <com/sun/star/form/component/RadioButton.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a radio button which is data-aware, and can be bound to a database field. + */ +published service DatabaseRadioButton +{ + service com::sun::star::form::component::RadioButton; + + service com::sun::star::form::DataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseTextField.idl b/offapi/com/sun/star/form/component/DatabaseTextField.idl new file mode 100644 index 000000000000..001f342d3c53 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseTextField.idl @@ -0,0 +1,73 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseTextField_idl__ +#define __com_sun_star_form_component_DatabaseTextField_idl__ + +#ifndef __com_sun_star_form_component_TextField_idl__ +#include <com/sun/star/form/component/TextField.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a text field which is data-aware, and can be bound to a database field. + */ +published service DatabaseTextField +{ + service com::sun::star::form::component::TextField; + + service com::sun::star::form::DataAwareControlModel; + + //------------------------------------------------------------------------- + + /** determines if an empty text should be treated as a <NULL/> value. + + <p>When the user enters text into a text field, and after this, the control + content is to be committed into the database field the control is bound to, + a decision must be made how to deal with empty strings.<br/> + This is controlled by this property.</p> + + <p>If the property is set to <TRUE/>, and an empty text is to be commited, this is + converted into <NULL/>, else it is written as empty string.</p> + */ + [property] boolean ConvertEmptyToNull; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DatabaseTimeField.idl b/offapi/com/sun/star/form/component/DatabaseTimeField.idl new file mode 100644 index 000000000000..1ac3d51ccc36 --- /dev/null +++ b/offapi/com/sun/star/form/component/DatabaseTimeField.idl @@ -0,0 +1,59 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DatabaseTimeField_idl__ +#define __com_sun_star_form_component_DatabaseTimeField_idl__ + +#ifndef __com_sun_star_form_component_TimeField_idl__ +#include <com/sun/star/form/component/TimeField.idl> +#endif + +#ifndef __com_sun_star_form_DataAwareControlModel_idl__ +#include <com/sun/star/form/DataAwareControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a data-aware field for inputting a time value. + */ +published service DatabaseTimeField +{ + service com::sun::star::form::component::TimeField; + + service com::sun::star::form::DataAwareControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/DateField.idl b/offapi/com/sun/star/form/component/DateField.idl new file mode 100644 index 000000000000..b7764c8ea874 --- /dev/null +++ b/offapi/com/sun/star/form/component/DateField.idl @@ -0,0 +1,81 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_DateField_idl__ +#define __com_sun_star_form_component_DateField_idl__ + +#ifndef __com_sun_star_awt_UnoControlDateFieldModel_idl__ +#include <com/sun/star/awt/UnoControlDateFieldModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies the model of a date field control, which is an edit field used to enter a date. +*/ +published service DateField +{ + service com::sun::star::awt::UnoControlDateFieldModel; + + service com::sun::star::form::FormControlModel; + + /** resets the control. + + <p>If you do not set a value for the <member>DefaultDate</member>, then resetting the control + will result in setting to to the current system date. This is for HTML compatibility.</p> + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlDateFieldModel::Date + @see com::sun::star::form::XReset + */ + [property] long DefaultDate; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/FileControl.idl b/offapi/com/sun/star/form/component/FileControl.idl new file mode 100644 index 000000000000..d9956c7114b6 --- /dev/null +++ b/offapi/com/sun/star/form/component/FileControl.idl @@ -0,0 +1,78 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_FileControl_idl__ +#define __com_sun_star_form_component_FileControl_idl__ + +#ifndef __com_sun_star_awt_UnoControlFileControlModel_idl__ +#include <com/sun/star/awt/UnoControlFileControlModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies the control model of an edit field for a + file name. + */ +published service FileControl +{ + service com::sun::star::awt::UnoControlFileControlModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default text. + + @see FileControl::DefaultText + */ + interface com::sun::star::form::XReset; + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlFileControlModel::Text + @see com::sun::star::form::XReset + */ + [property] string DefaultText; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/FixedText.idl b/offapi/com/sun/star/form/component/FixedText.idl new file mode 100644 index 000000000000..1bb60c47388e --- /dev/null +++ b/offapi/com/sun/star/form/component/FixedText.idl @@ -0,0 +1,64 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_FixedText_idl__ +#define __com_sun_star_form_component_FixedText_idl__ + +#ifndef __com_sun_star_awt_UnoControlFixedTextModel_idl__ +#include <com/sun/star/awt/UnoControlFixedTextModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies the control model for a text which can be + displayed, but not edited by the user. + + <p>These kind of controls is usually used to label other controls.</p> + + @see com::sun::star::form::DataAwareControlModel::LabelControl + */ +published service FixedText +{ + service com::sun::star::awt::UnoControlFixedTextModel; + + service com::sun::star::form::FormControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/Form.idl b/offapi/com/sun/star/form/component/Form.idl new file mode 100644 index 000000000000..526a2febecb0 --- /dev/null +++ b/offapi/com/sun/star/form/component/Form.idl @@ -0,0 +1,93 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_Form_idl__ +#define __com_sun_star_form_component_Form_idl__ + +#ifndef __com_sun_star_form_FormComponent_idl__ +#include <com/sun/star/form/FormComponent.idl> +#endif + +#ifndef __com_sun_star_form_FormComponents_idl__ +#include <com/sun/star/form/FormComponents.idl> +#endif + +#ifndef __com_sun_star_form_XForm_idl__ +#include <com/sun/star/form/XForm.idl> +#endif + +#ifndef __com_sun_star_awt_XTabControllerModel_idl__ +#include <com/sun/star/awt/XTabControllerModel.idl> +#endif + +#ifndef __com_sun_star_script_XEventAttacherManager_idl__ +#include <com/sun/star/script/XEventAttacherManager.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a form which is a group of FormComponents. + + <p>A form fulfills several tasks, like storing the structure of its + form components, storing the information concerning tab ordering + and control grouping, and last but not least, it provides the + event environment for its contained elements.</p> + + <p>A form acts on the one hand like a container of FormComponents + and on the other hand like a FormComponent. This generic + construction allows the definition of hierarchies of forms and their + dependent subforms.</p> + + @see com::sun::star::form::FormControlModel + */ +published service Form +{ + service com::sun::star::form::FormComponent; + + service com::sun::star::form::FormComponents; + + /** identifies a component as form. + */ + interface com::sun::star::form::XForm; + + + /** This interface has to be implemented to supply the information for tab ordering and component grouping. + + @see com::sun::star::form::FormControlModel::TabIndex + */ + interface com::sun::star::awt::XTabControllerModel; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/FormattedField.idl b/offapi/com/sun/star/form/component/FormattedField.idl new file mode 100644 index 000000000000..21ab49c523ff --- /dev/null +++ b/offapi/com/sun/star/form/component/FormattedField.idl @@ -0,0 +1,72 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_FormattedField_idl__ +#define __com_sun_star_form_component_FormattedField_idl__ + +#ifndef __com_sun_star_awt_UnoControlFormattedFieldModel_idl__ +#include <com/sun/star/awt/UnoControlFormattedFieldModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies the control model of an edit field for entering text which can be + (nearly) arbirtrarily formatted. + + @see com::sun::star::util::XNumberFormatsSupplier + */ +published service FormattedField +{ + service com::sun::star::awt::UnoControlFormattedFieldModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default state. + + @see com::sun::star::awt::UnoControlFormattedFieldModel::EffectiveValue + @see com::sun::star::awt::UnoControlFormattedFieldModel::EffectiveDefault + */ + interface com::sun::star::form::XReset; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/GridControl.idl b/offapi/com/sun/star/form/component/GridControl.idl new file mode 100644 index 000000000000..f3077ec037ac --- /dev/null +++ b/offapi/com/sun/star/form/component/GridControl.idl @@ -0,0 +1,210 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_GridControl_idl__ +#define __com_sun_star_form_component_GridControl_idl__ + +#ifndef __com_sun_star_util_Color_idl__ +#include <com/sun/star/util/Color.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XGridColumnFactory_idl__ +#include <com/sun/star/form/XGridColumnFactory.idl> +#endif + +#ifndef __com_sun_star_form_FormComponents_idl__ +#include <com/sun/star/form/FormComponents.idl> +#endif + +#ifndef __com_sun_star_container_XContainer_idl__ +#include <com/sun/star/container/XContainer.idl> +#endif + +#ifndef __com_sun_star_view_XSelectionSupplier_idl__ +#include <com/sun/star/view/XSelectionSupplier.idl> +#endif + +#ifndef __com_sun_star_container_XNameContainer_idl__ +#include <com/sun/star/container/XNameContainer.idl> +#endif + +#ifndef __com_sun_star_container_XIndexContainer_idl__ +#include <com/sun/star/container/XIndexContainer.idl> +#endif + +#ifndef __com_sun_star_container_XEnumerationAccess_idl__ +#include <com/sun/star/container/XEnumerationAccess.idl> +#endif + +#ifndef __com_sun_star_script_XEventAttacherManager_idl__ +#include <com/sun/star/script/XEventAttacherManager.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + +#ifndef __com_sun_star_awt_FontDescriptor_idl__ +#include <com/sun/star/awt/FontDescriptor.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies a model for a control which can display form data in a table-like way. + + <p>In opposite to other form controls, grid controls do not only + display the single current value of a column they are bound to. Moreover, they do + display not only the current row of the form, but all rows (at least potentially, limited + by the control size, of course).</p> + + <p>The table rows in a grid control correspond to the rows in the <type>DataForm</type> + the control belongs to, and the columns correspond to single columns of the form's row set.</p> + + <p>Columns of a grid control are modeled by own objects, too. They are very similar to usual + <type scope="com::sun::star::form">DataAwareControlModel</type>s modeling other "single-value" controls, but they are not described + as own services. Instead, they need to be created using the <type scope="com::sun::star::form">XGridColumnFactory</type> interface.</p> + */ +published service GridControl +{ + service com::sun::star::form::FormControlModel; + + /** provides basic functionality of a container of <type scope="com::sun::star::form">FormComponent</type>s. + + <p>All the container-related methods of this service related to control models, + this is what are the container elements for a <type>GridControl</type>.</p> + + <p>As the <type scope="com::sun::star::form">FormComponents</type> service also specifies + the <type scope"com::sun::star::script">XEventAttacherManager</type> service, grid control models + also provide a scripting environment for their columns.</p> + */ + service com::sun::star::form::FormComponents; + + /** allows to create column models to be inserted into the control model. + + <p>Note that the object returned by the <membere scope="com::sun::star::form">XGridColumnFactory::createColumn</member> + method is not part of the grid control, yet. It needs to be inserted using any of the + container interfaces.</p> + + <p>You always need to use this interface for creating columns for the grid control. + Column models not created this way will not be accepted when inserted later on.</p> + */ + interface com::sun::star::form::XGridColumnFactory; + + /** gives access to the currently selection. + + <p>In a grid control, single columns can be selected (at most one at a time).<br/> + For various unfortunate reaons, this selection is an aspect of the model, not of the + control as you would expect.</p> + + <p>This interface is deprecated, new implementations should not use it anymore, as it is to + be superseeded by a solution which is bound to the control, not the model.</p> + + @deprecated + */ + interface com::sun::star::view::XSelectionSupplier; + + /** resets the control. + + <p>The reset of the control is forwarded to all it's elements, means to all the column models. + As grid columns are very much like data-aware stand-alone controls, you can find a description + of the reset functionality in <member scope="com::sun::star::form">DataAwareControlModel::XReset</member>. + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** returns the border style of the control. + + <pre> + 0: No border + 1: 3D border + 2: simple border + </pre> + */ + [property] short Border; + + //------------------------------------------------------------------------- + + /** specifies the color of the border, if present + + <p>Not every border style (see <member>Border</member>) may support coloring. + For instance, usually a border with 3D effect will ignore the BorderColor setting.</p> + + @since OOo 2.0.0 + */ + [optional, property] long BorderColor; + + //------------------------------------------------------------------------- + + /** determines whether the control is enabled or disabled. + */ + [property] boolean Enabled; + + //------------------------------------------------------------------------- + + /** contains the font attributes of the text in the control. + */ + [property] com::sun::star::awt::FontDescriptor FontDescriptor; + + //------------------------------------------------------------------------- + + /** specifies the height of a row of the grid. + + <p>If the value is set to <NULL/>, the height is determined automatically according + to the current font used.</p> + + @see GridControl::FontDescriptor + */ + [property] long RowHeight; + + //------------------------------------------------------------------------- + + /** determines whether the control can be reached by the tabulator key. + */ + [property] boolean Tabstop; + + //------------------------------------------------------------------------- + + /** specifies the text color (RGB) of the control. + */ + [property] com::sun::star::util::Color TextColor; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/GroupBox.idl b/offapi/com/sun/star/form/component/GroupBox.idl new file mode 100644 index 000000000000..d4f2b57375ae --- /dev/null +++ b/offapi/com/sun/star/form/component/GroupBox.idl @@ -0,0 +1,60 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_GroupBox_idl__ +#define __com_sun_star_form_component_GroupBox_idl__ + +#ifndef __com_sun_star_awt_UnoControlGroupBoxModel_idl__ +#include <com/sun/star/awt/UnoControlGroupBoxModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies a model for a control which can be used to visually + group controls. + */ +published service GroupBox +{ + service com::sun::star::awt::UnoControlGroupBoxModel; + + service com::sun::star::form::FormControlModel; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/HTMLForm.idl b/offapi/com/sun/star/form/component/HTMLForm.idl new file mode 100644 index 000000000000..763f388a4185 --- /dev/null +++ b/offapi/com/sun/star/form/component/HTMLForm.idl @@ -0,0 +1,106 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_HTMLForm_idl__ +#define __com_sun_star_form_component_HTMLForm_idl__ + +#ifndef __com_sun_star_form_component_Form_idl__ +#include <com/sun/star/form/component/Form.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + +#ifndef __com_sun_star_form_XSubmit_idl__ +#include <com/sun/star/form/XSubmit.idl> +#endif + +#ifndef __com_sun_star_form_FormSubmitMethod_idl__ +#include <com/sun/star/form/FormSubmitMethod.idl> +#endif + +#ifndef __com_sun_star_form_FormSubmitEncoding_idl__ +#include <com/sun/star/form/FormSubmitEncoding.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies the special kind of <type>Form</type>s for HTML documents. + + <p>An HTMLForm fulfills the specification of forms in HTML. It supplies + the possibility of submitting or resetting the contents of a form. + For more information on HTML forms, please see the documentation of HTML.</p> + */ +published service HTMLForm +{ + service com::sun::star::form::component::Form; + + /** resets the control. + */ + interface com::sun::star::form::XReset; + + /** allows to submit changes. + + <p>When a form is submitted, the data contained in the form is sent + to the target URL as a series of name/value pairs. The name portion + of each pair is the name of a form component as specified by its NAME + attribute. In most cases the value portion is the value displayed + by the element, for example, the text displayed in a text field.</p> + */ + interface com::sun::star::form::XSubmit; + + /** describes the frame, where to open the document specified by the TargetURL. + */ + [property] string TargetFrame; + + //------------------------------------------------------------------------- + + /** specifies the URL, which should be used for submission. + */ + [property] string TargetURL; + //------------------------------------------------------------------------- + + /** specifies the kind of submission. + */ + [property] com::sun::star::form::FormSubmitMethod SubmitMethod; + //------------------------------------------------------------------------- + + /** specifies the kind of encoding for submission. + */ + [property] com::sun::star::form::FormSubmitEncoding SubmitEncoding; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/HiddenControl.idl b/offapi/com/sun/star/form/component/HiddenControl.idl new file mode 100644 index 000000000000..cf516df86d12 --- /dev/null +++ b/offapi/com/sun/star/form/component/HiddenControl.idl @@ -0,0 +1,65 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_HiddenControl_idl__ +#define __com_sun_star_form_component_HiddenControl_idl__ + +#ifndef __com_sun_star_form_FormComponent_idl__ +#include <com/sun/star/form/FormComponent.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies the model of a hidden control. + + <p>The only sense of a hidden control is to store data in the form which is + not visible to the user.</p> + + <p>Usually, hidden controls are used in <type scope="com::sun::star::form::component">HTMLForm</type>s, + where they contain data which is to be submitted.<br/> + Nevertheless, you can use them in your own forms for storing any data, for instance + to evaluate it in some scripting macro.</p> + */ +published service HiddenControl +{ + service com::sun::star::form::FormComponent; + + /** specifies the value of the component. + */ + [property] string HiddenValue; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/ImageButton.idl b/offapi/com/sun/star/form/component/ImageButton.idl new file mode 100644 index 000000000000..69df0e295106 --- /dev/null +++ b/offapi/com/sun/star/form/component/ImageButton.idl @@ -0,0 +1,116 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_ImageButton_idl__ +#define __com_sun_star_form_component_ImageButton_idl__ + +#ifndef __com_sun_star_awt_UnoControlImageControlModel_idl__ +#include <com/sun/star/awt/UnoControlImageControlModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XApproveActionBroadcaster_idl__ +#include <com/sun/star/form/XApproveActionBroadcaster.idl> +#endif + +#ifndef __com_sun_star_form_XImageProducerSupplier_idl__ +#include <com/sun/star/form/XImageProducerSupplier.idl> +#endif + +#ifndef __com_sun_star_form_FormButtonType_idl__ +#include <com/sun/star/form/FormButtonType.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies the control model for a clickable button which + is represented by an image. + + <p>The image to be displayed is determined by <member scope="com::sun::star::awt">UnoControlImageControlModel::ImageURL</member> + property specifies the URL of an image to be displayed.</p> + + @see CommandButton +*/ +published service ImageButton +{ + service com::sun::star::awt::UnoControlImageControlModel; + + service com::sun::star::form::FormControlModel; + + + /** supplies the caller with an <type scope="com::sun::star::awt">XImageProducer</type>. + + <p>Other components can register as <type scope="com::sun::star::awt">XImageConsumer</type> + at this producer. Then they will be notified of any change in the image to be displayed.</p> + + <p>Whenever the <member scope="com::sun::star::awt">UnoControlImageControlModel::ImageURL</member> + property is changed, the model loads the specified image, and sets it as image source + at its <type scope="com::sun::star::awt">XImageProducer</type>. Then, all + <type scope="com::sun::star::awt">XImageConsumer</type>s are notified and supplied with + the binary data of the image.<br/> + Usually, controls acting for an <type>ImageButton</type> model are consumers, and use the + data stream to display the image</p> + */ + interface com::sun::star::form::XImageProducerSupplier; + + //------------------------------------------------------------------------- + /** describes the action to be executed by the button when pressed. + */ + [property] com::sun::star::form::FormButtonType ButtonType; + + //------------------------------------------------------------------------- + /** describes the frame, where to open the document specified by the TargetURL. + + <p>This property is evaluated if the button is of type URL.</p> + + <p>As always, there is a number of target names which have a special meaning, and force + a special <type scope="com::sun::star::frame">Frame</type> to be used.</p> + */ + [property] string TargetFrame; + + //------------------------------------------------------------------------- + /** specifies the URL, which should be opened if the button was clicked. + + <p>This property is evaluated if the button is of type URL.</p> + + @see com::sun::star::form::FormButtonType + */ + [property] string TargetURL; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/ListBox.idl b/offapi/com/sun/star/form/component/ListBox.idl new file mode 100644 index 000000000000..f636d25b77ee --- /dev/null +++ b/offapi/com/sun/star/form/component/ListBox.idl @@ -0,0 +1,84 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_ListBox_idl__ +#define __com_sun_star_form_component_ListBox_idl__ + +#ifndef __com_sun_star_awt_UnoControlListBoxModel_idl__ +#include <com/sun/star/awt/UnoControlListBoxModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies a model for a control which allows to choose in a list of alternative values. + */ +published service ListBox +{ + service com::sun::star::awt::UnoControlListBoxModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default state. + + @see ListBox::DefaultSelection + */ + interface com::sun::star::form::XReset; + + /** contains the indexes of entries of the listbox, which should selected + by default. + + <p>This selection is used initially or for a reset.</p> + + @see com::sun::star::awt::UnoControlListBoxModel::SelectedItems + @see com::sun::star::form::XReset + */ + [property] sequence<short> DefaultSelection; + + + /** contains the listbox entries. + */ + [property] sequence<string> ListSource; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/NavigationToolBar.idl b/offapi/com/sun/star/form/component/NavigationToolBar.idl new file mode 100644 index 000000000000..0e3880db707d --- /dev/null +++ b/offapi/com/sun/star/form/component/NavigationToolBar.idl @@ -0,0 +1,150 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_NavigationToolBar_idl__ +#define __com_sun_star_form_component_NavigationToolBar_idl__ + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif +#ifndef __com_sun_star_awt_FontDescriptor_idl__ +#include <com/sun/star/awt/FontDescriptor.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** This service specifies the model for control which provides controller + functionality for a <type>DataForm</type>, such as navigating or filtering + the form. + */ +service NavigationToolBar +{ + service com::sun::star::form::FormControlModel; + + //------------------------------------------------------------------------- + /** denotes the border style of the control. + + Allowed values are + <ul><li><b>0</b>: no border at all</li> + <li><b>1</b>: 3D border</li> + <li><b>2</b>: simple flat</li> + </ul> + */ + [property] short Border; + + //------------------------------------------------------------------------- + /** determines whether the control is enabled or disabled. + */ + [property] boolean Enabled; + + //------------------------------------------------------------------------- + /** contains the font attributes for the text in the control + */ + [property] com::sun::star::awt::FontDescriptor FontDescriptor; + + //------------------------------------------------------------------------- + /** specifies the text color (as RGB value) of the control. + */ + [property] long TextColor; + + //------------------------------------------------------------------------- + /** specifies the text line color (as RGB value) of the control. + + <p>This color is used if the <member>FontDescriptor</member> defines + that the text in the control should be underlined or stroke out.</p> + */ + [property] long TextLineColor; + + //------------------------------------------------------------------------- + /** specifies the relief for the font described in <member>FontDescriptor</member> + + <p>The value must be one of the <type scope="com::sun::star::text">FontRelief</type> + constants.</p> + */ + [property] long FontRelief; + + //------------------------------------------------------------------------- + /** specifies the emphasis mark for the font described in <member>FontDescriptor</member> + + <p>The value must be one of the <type scope="com::sun::star::text">FontEmphasis</type> + constants.</p> + */ + [property] long FontEmphasisMark; + + //------------------------------------------------------------------------- + /** specifies the size of the icons in the control + + <p>At least the following values are to be supported: + <ul><li>0: small icons (16x16)</li> + <li>1: medium size icons (26x26)</li> + </ul> + */ + [property] short IconSize; + + //------------------------------------------------------------------------- + /** determines whether the control should provide functionality for positioning the + parent form + */ + [property] boolean ShowPosition; + + //------------------------------------------------------------------------- + /** determines whether the control should provide functionality for navigating the + parent form + */ + [property] boolean ShowNavigation; + + //------------------------------------------------------------------------- + /** determines whether the control should provide functionality for acting on the current record + of the parent form + */ + [property] boolean ShowRecordActions; + + //------------------------------------------------------------------------- + /** determines whether the control should provide functionality for filtering and sorting the + parent form + */ + [property] boolean ShowFilterSort; + + //------------------------------------------------------------------------- + /** specifies a repeat delay for the control + + <p>Some buttons of a NavigationToolBar may show repeating behaviour, e.g. may be + repeatedly triggered when the user keeps the mouse pressed over such a button.<br/> + The delay between two such triggers (in milliseconds) is specified with this property. + </p> + */ + [property] long RepeatDelay; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/NumericField.idl b/offapi/com/sun/star/form/component/NumericField.idl new file mode 100644 index 000000000000..62336316eb0a --- /dev/null +++ b/offapi/com/sun/star/form/component/NumericField.idl @@ -0,0 +1,80 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_NumericField_idl__ +#define __com_sun_star_form_component_NumericField_idl__ + +#ifndef __com_sun_star_awt_UnoControlNumericFieldModel_idl__ +#include <com/sun/star/awt/UnoControlNumericFieldModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies a component which allows the input of a numeric value. + */ +published service NumericField +{ + service com::sun::star::awt::UnoControlNumericFieldModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default value. + + @see NumericField::DefaultValue + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlNumericFieldModel::Value + @see com::sun::star::form::XReset + */ + [property] double DefaultValue; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/PatternField.idl b/offapi/com/sun/star/form/component/PatternField.idl new file mode 100644 index 000000000000..f41a12d2231e --- /dev/null +++ b/offapi/com/sun/star/form/component/PatternField.idl @@ -0,0 +1,78 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_PatternField_idl__ +#define __com_sun_star_form_component_PatternField_idl__ + +#ifndef __com_sun_star_awt_UnoControlPatternFieldModel_idl__ +#include <com/sun/star/awt/UnoControlPatternFieldModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies a component which allows the input of text which matches a specific pattern. + */ +published service PatternField +{ + service com::sun::star::awt::UnoControlPatternFieldModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default text. + + @see PatternField::DefaultText + */ + interface com::sun::star::form::XReset; + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlPatternFieldModel::Text + @see com::sun::star::form::XReset + */ + [property] string DefaultText; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/RadioButton.idl b/offapi/com/sun/star/form/component/RadioButton.idl new file mode 100644 index 000000000000..76575e3450bd --- /dev/null +++ b/offapi/com/sun/star/form/component/RadioButton.idl @@ -0,0 +1,112 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_RadioButton_idl__ +#define __com_sun_star_form_component_RadioButton_idl__ + +#ifndef __com_sun_star_awt_UnoControlRadioButtonModel_idl__ +#include <com/sun/star/awt/UnoControlRadioButtonModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies a component which acts as a radio button as needed in <type>HTMLForm</type>s. + + <p>Radio buttons are controls which can be grouped together, and in every + group, only one of the controls can be check. This means if one of them + is checked by a user interaction, all other controls in the same group + are automatically unchecked</p> + + <p>Like in HTML, radio buttons are grouped together if and only if they have the + same name (see <member scope="com::sun::star::form">FormComponent::Name</member>).</p> + */ +published service RadioButton +{ + service com::sun::star::awt::UnoControlRadioButtonModel; + + service com::sun::star::form::FormControlModel; + + /** can be used to reset the control to it's default text. + + @see RadioButton::DefaultState + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + <p> In a group of radio buttons only one button should be checked + by default.</p> + + @see com::sun::star::awt::UnoControlRadioButtonModel::State + @see com::sun::star::form::XReset + */ + [property] short DefaultState; + + //------------------------------------------------------------------------- + + /** contains a reference value which is used for submission in a HTML + form. + + <p>If the form the control belongs to is to be submitted (see + <type scope="com::sun::star::form">XSubmit</type>), and the control is checked, this reference + value is used for submission.</p> + */ + [property] string RefValue; + + + /** specifies a value which is to be associated with the control when it's <em>not</em> + selected. + + <p>In various situations, the <member>RefValue</member> is associated with the control + if and only if it is selected.<br/> + <member>UncheckedRefValue</member> provides a extensions of this concept: If present, + the value should be associated with the control when it is <em>not</em> selected.</p> + */ + [optional, property] string UncheckedRefValue; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/RichTextControl.idl b/offapi/com/sun/star/form/component/RichTextControl.idl new file mode 100644 index 000000000000..0566f658a197 --- /dev/null +++ b/offapi/com/sun/star/form/component/RichTextControl.idl @@ -0,0 +1,91 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_component_RichTextControl_idl__ +#define __com_sun_star_form_component_RichTextControl_idl__ + +#ifndef __com_sun_star_awt_UnoControlEditModel_idl__ +#include <com/sun/star/awt/UnoControlEditModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_text_TextRange_idl__ +#include <com/sun/star/text/TextRange.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies a component which extends the <type scope="com::sun::star::awt">UnoControlEditModel</type> + with capabilities to display and input formatted text. +*/ +published service RichTextControl +{ + service com::sun::star::awt::UnoControlEditModel; + + service com::sun::star::form::FormControlModel; + + /** specifies capabilities to provide rich text, as opposed to the simple text provided by the + <type scope="com::sun::star::awt">UnoControlEditModel</type> + */ + service com::sun::star::text::TextRange; + + /** specifies whether text should be automatically wrapped to fit into the control. + + <p>If set to <TRUE/>, users need to manually press the enter key to insert a line break. + If set to <FALSE/>, text is automatically wrapped at the control border.</p> + */ + [property] boolean HardLineBreaks; + + /** specifies whether the control should display the text including all its formatting. + + <p>If this is set to <FALSE/>, the control will act as ordinary + <type scope="com::sun::star::awt">UnoControlEditModel</type>.</p> + + <p>If the property is set to <TRUE/>, the control will ignore the following properties: + <ul> + <li><member scope="com::sun::star::awt">UnoControlEditModel::EchoChar</member></li> + <li><member scope="com::sun::star::awt">UnoControlEditModel::MaxTextLen</member></li> + <li><member scope="com::sun::star::awt">UnoControlEditModel::MultiLine</member></li> + <li><member scope="com::sun::star::awt">UnoControlEditModel::Align</member></li> + </ul> + </p> + */ + [property] boolean RichText; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/ScrollBar.idl b/offapi/com/sun/star/form/component/ScrollBar.idl new file mode 100644 index 000000000000..69e0fc7e78ff --- /dev/null +++ b/offapi/com/sun/star/form/component/ScrollBar.idl @@ -0,0 +1,78 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_ScrollBar_idl__ +#define __com_sun_star_form_component_ScrollBar_idl__ + +#ifndef __com_sun_star_awt_UnoControlScrollBarModel_idl__ +#include <com/sun/star/awt/UnoControlScrollBarModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + +module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies the model of a scroll bar control. +*/ +service ScrollBar +{ + service com::sun::star::awt::UnoControlScrollBarModel; + + service com::sun::star::form::FormControlModel; + + /** resets the control. + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlScrollBarModel::ScrollValue + @see com::sun::star::form::XReset + */ + [property] long DefaultScrollValue; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/SpinButton.idl b/offapi/com/sun/star/form/component/SpinButton.idl new file mode 100644 index 000000000000..09be77ed47c3 --- /dev/null +++ b/offapi/com/sun/star/form/component/SpinButton.idl @@ -0,0 +1,78 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_SpinButton_idl__ +#define __com_sun_star_form_component_SpinButton_idl__ + +#ifndef __com_sun_star_awt_UnoControlSpinButtonModel_idl__ +#include <com/sun/star/awt/UnoControlSpinButtonModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + +module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies the model of a scroll bar control. +*/ +service SpinButton +{ + service com::sun::star::awt::UnoControlSpinButtonModel; + + service com::sun::star::form::FormControlModel; + + /** resets the control. + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlSpinButtonModel::SpinValue + @see com::sun::star::form::XReset + */ + [property] long DefaultSpinValue; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/SubmitButton.idl b/offapi/com/sun/star/form/component/SubmitButton.idl new file mode 100644 index 000000000000..b540065cb989 --- /dev/null +++ b/offapi/com/sun/star/form/component/SubmitButton.idl @@ -0,0 +1,72 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_SubmitButton_idl__ +#define __com_sun_star_form_component_SubmitButton_idl__ + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_awt_UnoControlButtonModel_idl__ +#include <com/sun/star/awt/UnoControlButtonModel.idl> +#endif + +#ifndef __com_sun_star_form_submission_XSubmissionSupplier_idl__ +#include <com/sun/star/form/submission/XSubmissionSupplier.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies the control model for a button, part of a form component hierarchy, + which can be bound to external submissions. + + @see CommandButton + */ +service SubmitButton +{ + service com::sun::star::form::FormControlModel; + + /** allows binding external submissions to the control model + + <p>Note that the control model itself will not make any use of the submission. + Instead, submissions are triggered by a control (not a control <em>model</em>). + Thus, the <type scope="com::sun::star::form::control">SubmitButton</type> + control associated with a <type>SubmitButton</type> model is responsible for + using the submission supplied at this model.</p> + */ + interface com::sun::star::form::submission::XSubmissionSupplier; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/TextField.idl b/offapi/com/sun/star/form/component/TextField.idl new file mode 100644 index 000000000000..bb4cf5ce046c --- /dev/null +++ b/offapi/com/sun/star/form/component/TextField.idl @@ -0,0 +1,89 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_TextField_idl__ +#define __com_sun_star_form_component_TextField_idl__ + +#ifndef __com_sun_star_awt_UnoControlEditModel_idl__ +#include <com/sun/star/awt/UnoControlEditModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_component_RichTextControl_idl__ +#include <com/sun/star/form/component/RichTextControl.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** specifies a component which allows the input of text, either single- or multi-line. + */ +published service TextField +{ + service com::sun::star::awt::UnoControlEditModel; + + service com::sun::star::form::FormControlModel; + + /** specifies optional capabilities for displaying and inputting formatted text. + + <p>If the <member>RichTextControl::RichText</member> property is set to <TRUE/>, + then the <type>TextField</type> component will disable it's reset capabilities. This means + that all calls to <member scope="com::sun::star::form">XReset::reset</member> will be ignored.</p> + */ + [optional] service RichTextControl; + + /** can be used to reset the control to it's default text. + + @see TextField::DefaultText + */ + interface com::sun::star::form::XReset; + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlEditModel::Text + @see com::sun::star::form::XReset + */ + [property] string DefaultText; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/TimeField.idl b/offapi/com/sun/star/form/component/TimeField.idl new file mode 100644 index 000000000000..d752ca28928a --- /dev/null +++ b/offapi/com/sun/star/form/component/TimeField.idl @@ -0,0 +1,81 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_component_TimeField_idl__ +#define __com_sun_star_form_component_TimeField_idl__ + +#ifndef __com_sun_star_awt_UnoControlTimeFieldModel_idl__ +#include <com/sun/star/awt/UnoControlTimeFieldModel.idl> +#endif + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_XReset_idl__ +#include <com/sun/star/form/XReset.idl> +#endif + + +//============================================================================= + + module com { module sun { module star { module form { module component { + +//============================================================================= + +/** sepecifies the control model for a field which can be used to input time values. + */ +published service TimeField +{ + service com::sun::star::awt::UnoControlTimeFieldModel; + + service com::sun::star::form::FormControlModel; + + /** resets the control. + + <p>If you do not set a value for the <member>DefaultTime</member>, then resetting the control + will result in setting to to the current system time. This is for HTML compatibility.</p> + */ + interface com::sun::star::form::XReset; + + //------------------------------------------------------------------------- + + /** contains a default value for the control. + + <p>This value is used when the control is initially displayed, and for resetting it.</p> + + @see com::sun::star::awt::UnoControlTimeFieldModel::Time + @see com::sun::star::form::XReset + */ + [property] long DefaultTime; + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/component/makefile.mk b/offapi/com/sun/star/form/component/makefile.mk new file mode 100644 index 000000000000..37c1bb44d560 --- /dev/null +++ b/offapi/com/sun/star/form/component/makefile.mk @@ -0,0 +1,83 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/..$/..$/.. + +PRJNAME=offapi + +TARGET=cssfcomp +PACKAGE=com$/sun$/star$/form$/component + +# --- Settings ----------------------------------------------------- +.INCLUDE : $(PRJ)$/util$/makefile.pmk + +# ------------------------------------------------------------------------ + +IDLFILES=\ + CheckBox.idl\ + ComboBox.idl\ + CommandButton.idl\ + CurrencyField.idl\ + DatabaseCheckBox.idl\ + DatabaseComboBox.idl\ + DatabaseCurrencyField.idl\ + DatabaseDateField.idl\ + DatabaseImageControl.idl\ + DatabaseListBox.idl\ + DatabaseNumericField.idl\ + DatabasePatternField.idl\ + DatabaseRadioButton.idl\ + DatabaseTextField.idl\ + DatabaseFormattedField.idl\ + DatabaseTimeField.idl\ + DataForm.idl\ + DateField.idl\ + FileControl.idl\ + FixedText.idl\ + Form.idl\ + GridControl.idl\ + GroupBox.idl\ + HiddenControl.idl\ + HTMLForm.idl\ + ImageButton.idl\ + ListBox.idl\ + NumericField.idl\ + PatternField.idl\ + RadioButton.idl\ + TextField.idl\ + FormattedField.idl\ + TimeField.idl\ + NavigationToolBar.idl\ + ScrollBar.idl\ + SpinButton.idl\ + SubmitButton.idl\ + RichTextControl.idl\ + +# ------------------------------------------------------------------ + +.INCLUDE : target.mk +.INCLUDE : $(PRJ)$/util$/target.pmk diff --git a/offapi/com/sun/star/form/control/CheckBox.idl b/offapi/com/sun/star/form/control/CheckBox.idl new file mode 100644 index 000000000000..763e8ec9132c --- /dev/null +++ b/offapi/com/sun/star/form/control/CheckBox.idl @@ -0,0 +1,70 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_component_checkbox_idl__ +#define __com_sun_star_form_component_checkbox_idl__ + +#ifndef __com_sun_star_awt_UnoControlCheckBox_idl__ +#include <com/sun/star/awt/UnoControlCheckBox.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a check box control which can (but not necessarily has to) be bound to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">CheckBox</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service CheckBox +{ + service com::sun::star::awt::UnoControlCheckBox; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/ComboBox.idl b/offapi/com/sun/star/form/control/ComboBox.idl new file mode 100644 index 000000000000..b4dbfac27509 --- /dev/null +++ b/offapi/com/sun/star/form/control/ComboBox.idl @@ -0,0 +1,70 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_ComboBox_idl__ +#define __com_sun_star_form_control_ComboBox_idl__ + +#ifndef __com_sun_star_awt_UnoControlComboBox_idl__ +#include <com/sun/star/awt/UnoControlComboBox.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a combo box control. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">ComboBox</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service ComboBox +{ + service com::sun::star::awt::UnoControlComboBox; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/CommandButton.idl b/offapi/com/sun/star/form/control/CommandButton.idl new file mode 100644 index 000000000000..d4a4b48356ad --- /dev/null +++ b/offapi/com/sun/star/form/control/CommandButton.idl @@ -0,0 +1,88 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_CommandButton_idl__ +#define __com_sun_star_form_control_CommandButton_idl__ + +#ifndef __com_sun_star_awt_UnoControlButton_idl__ +#include <com/sun/star/awt/UnoControlButton.idl> +#endif + +#ifndef __com_sun_star_form_XApproveActionBroadcaster_idl__ +#include <com/sun/star/form/XApproveActionBroadcaster.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a button control. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">CommandButton</type> + service.</p> + + <p>The control is clickable, the action taken upon clicking depends on the settings + of the model the control belongs to.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel + @see com::sun::star::form::component::CommandButton::ButtonType +*/ +published service CommandButton +{ + service com::sun::star::awt::UnoControlButton; + + /** allows external instances to register as veto listener for the button's actions. + + <p>An <type scope="com::sun::star::form">XApproveActionListener</type> returning false on + it's approve-method will prevent any action which would usually be triggered - this includes + not only submitting or resetting forms, but also calling the + <type scope="com::sun::star::awt">XActionListener</type>s of the super service<br/> + This may be interesting for e.g. forms which want to provide input validation before submitting + data.<br/> + + @see com::sun::star::form::component::HTMLForm + @see com::sun::star::form::XSubmit + @see com::sun::star::form::XReset + @see com::sun::star::awt::XButton + */ + interface com::sun::star::form::XApproveActionBroadcaster; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/CurrencyField.idl b/offapi/com/sun/star/form/control/CurrencyField.idl new file mode 100644 index 000000000000..203278150878 --- /dev/null +++ b/offapi/com/sun/star/form/control/CurrencyField.idl @@ -0,0 +1,71 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_CurrencyField_idl__ +#define __com_sun_star_form_control_CurrencyField_idl__ + +#ifndef __com_sun_star_awt_UnoControlCurrencyField_idl__ +#include <com/sun/star/awt/UnoControlCurrencyField.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control which can be used for inputting currency values, and + which can (but not necessarily has to) be bound to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">CurrencyField</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service CurrencyField +{ + service com::sun::star::awt::UnoControlCurrencyField; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/DateField.idl b/offapi/com/sun/star/form/control/DateField.idl new file mode 100644 index 000000000000..ead9d296fb0e --- /dev/null +++ b/offapi/com/sun/star/form/control/DateField.idl @@ -0,0 +1,71 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_DateField_idl__ +#define __com_sun_star_form_control_DateField_idl__ + +#ifndef __com_sun_star_awt_UnoControlDateField_idl__ +#include <com/sun/star/awt/UnoControlDateField.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control which can be used for inputting date values, and + which can (but not necessarily has to) be bound to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">DateField</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service DateField +{ + service com::sun::star::awt::UnoControlDateField; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/FormattedField.idl b/offapi/com/sun/star/form/control/FormattedField.idl new file mode 100644 index 000000000000..f40453a4d1e9 --- /dev/null +++ b/offapi/com/sun/star/form/control/FormattedField.idl @@ -0,0 +1,76 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_FormattedField_idl__ +#define __com_sun_star_form_control_FormattedField_idl__ + +#ifndef __com_sun_star_awt_UnoControlFormattedField_idl__ +#include <com/sun/star/awt/UnoControlFormattedField.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control which can be used for inputting values with a arbitrary formatting, and + can (but not necessarily has to) be bound to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">FormattedField</type> + service.</p> + + <p>In addition, this control can be used in HTML forms. It triggers the + <method scope="com::sun::star::form">XSubmit::submit</method> method of the form it belongs to if + the <em>enter</em> key is pressed while it has the focus.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel + @see com::sun::star::util::XNumberFormatsSupplier +*/ +published service FormattedField +{ + service com::sun::star::awt::UnoControlFormattedField; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/GridControl.idl b/offapi/com/sun/star/form/control/GridControl.idl new file mode 100644 index 000000000000..06395d41e38d --- /dev/null +++ b/offapi/com/sun/star/form/control/GridControl.idl @@ -0,0 +1,172 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_GridControl_idl__ +#define __com_sun_star_form_control_GridControl_idl__ + +#ifndef __com_sun_star_awt_UnoControl_idl__ +#include <com/sun/star/awt/UnoControl.idl> +#endif + +#ifndef __com_sun_star_form_XGrid_idl__ +#include <com/sun/star/form/XGrid.idl> +#endif + +#ifndef __com_sun_star_form_XBoundComponent_idl__ +#include <com/sun/star/form/XBoundComponent.idl> +#endif + +#ifndef __com_sun_star_form_XGridFieldDataSupplier_idl__ +#include <com/sun/star/form/XGridFieldDataSupplier.idl> +#endif + +#ifndef __com_sun_star_util_XModifyBroadcaster_idl__ +#include <com/sun/star/util/XModifyBroadcaster.idl> +#endif + +#ifndef __com_sun_star_util_XModeSelector_idl__ +#include <com/sun/star/util/XModeSelector.idl> +#endif + +#ifndef __com_sun_star_container_XIndexAccess_idl__ +#include <com/sun/star/container/XIndexAccess.idl> +#endif + +#ifndef __com_sun_star_container_XEnumerationAccess_idl__ +#include <com/sun/star/container/XEnumerationAccess.idl> +#endif + +#ifndef __com_sun_star_container_XContainer_idl__ +#include <com/sun/star/container/XContainer.idl> +#endif + +#ifndef __com_sun_star_frame_XDispatchProviderInterception_idl__ +#include <com/sun/star/frame/XDispatchProviderInterception.idl> +#endif + +#ifndef __com_sun_star_view_XSelectionSupplier_idl__ +#include <com/sun/star/view/XSelectionSupplier.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { + +published interface XGridControl; + +module control { + +//============================================================================= + +/** describes a table-like control for displaying data. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">GridControl</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service GridControl +{ + service com::sun::star::awt::UnoControl; + + /** allows committing the content of the active cell of the control. + */ + interface com::sun::star::form::XBoundComponent; + + /** allows access to the active cell within the grid. + + <p>Only the column position can be modified using this interface, as the row position within + a table control bound to a data source is given implicitly (by the cursor position of the data source).</p> + */ + interface com::sun::star::form::XGrid; + + [optional] interface com::sun::star::form::XGridControl; + + /** used to broadcast modifications made by the user (within the active cell) + */ + interface com::sun::star::util::XModifyBroadcaster; + + /** allows access to the field data of the grid's current row in different formats + */ + [optional] interface com::sun::star::form::XGridFieldDataSupplier; + + /** allows access to objects wrapping a single column + */ + interface com::sun::star::container::XIndexAccess; + + /** allows creation of an enumeration for the column objects + */ + interface com::sun::star::container::XEnumerationAccess; + + /** is used to switch the operating modes of the control. + + <p>Besides the normal opreration mode (which is used to display the database form's data) the control may + for instance support a filter mode.</p> + */ + [optional] interface com::sun::star::util::XModeSelector; + + /** used to control the selection of rows in the grid control. + + <p>The selection used with the methods <method scope="com::sun::star::view">XSelectionSupplier::getSelection</method> + and <method scope="com::sun::star::view">XSelectionSupplier::select</method> is a sequence of Any's.<br/> + Here the elements of the Sequence are the bookmarks (in the <type scope="com::sun::star::sdb">RowSet</type>) + of the (to-be-) selected rows.</p> + */ + [optional] interface com::sun::star::view::XSelectionSupplier; + + /** allows external components to register dispatchers for some common form actions. + + <p>A grid control can contain own UI elements for traveling within the database form it belongs to (This + concept seems to make sense, as a grid control - in opposite to other data aware controls - displayes + not only one record at a time, but a larger number of records of the database form.)<br/> + With the help of this interface, external components which wish to handle such travelings themself can + register interceptors for the actions in question.</p> + + <p>Usual URLs to use include + <dl> + <dt>.uno:FormSlots/moveToFirst</dt><dd> move the cursor to the first record</dd> + <dt>.uno:FormSlots/moveToPrev</dt><dd> move the cursor to the previous record</dd> + <dt>.uno:FormSlots/moveToNext</dt><dd> move the cursor to the next record</dd> + <dt>.uno:FormSlots/moveToLast</dt><dd> move the cursor to the last record</dd> + <dt>.uno:FormSlots/moveToNew</dt><dd> move the cursor to the (one and only) <em>new</em> record</dd> + <dt>.uno:FormSlots/undoRecord</dt><dd> undo the changes done so far in the current record</dd> + </dl> + </p> + + <p>A concrete implementation of this service may offer more or less URLs, but if it offers some of the URLs + above, it must stick to the meanings defined above.</p> + */ + [optional] interface com::sun::star::frame::XDispatchProviderInterception; +}; + +//============================================================================= + +}; }; }; }; }; + + +#endif diff --git a/offapi/com/sun/star/form/control/GroupBox.idl b/offapi/com/sun/star/form/control/GroupBox.idl new file mode 100644 index 000000000000..5466f2c19c59 --- /dev/null +++ b/offapi/com/sun/star/form/control/GroupBox.idl @@ -0,0 +1,68 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_GroupBox_idl__ +#define __com_sun_star_form_control_GroupBox_idl__ + +#ifndef __com_sun_star_awt_UnoControlGroupBox_idl__ +#include <com/sun/star/awt/UnoControlGroupBox.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control which can be used for visually grouping controls + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">GroupBox</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service GroupBox +{ + service com::sun::star::awt::UnoControlGroupBox; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/ImageButton.idl b/offapi/com/sun/star/form/control/ImageButton.idl new file mode 100644 index 000000000000..278de5ca515d --- /dev/null +++ b/offapi/com/sun/star/form/control/ImageButton.idl @@ -0,0 +1,88 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_ImageButton_idl__ +#define __com_sun_star_form_control_ImageButton_idl__ + +#ifndef __com_sun_star_awt_UnoControlImageControl_idl__ +#include <com/sun/star/awt/UnoControlImageControl.idl> +#endif + +#ifndef __com_sun_star_form_XApproveActionBroadcaster_idl__ +#include <com/sun/star/form/XApproveActionBroadcaster.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control which can be used for displaying images on a control acting like a button. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">ImageButton</type> + service.</p> + + <p>The control is clickable, the action taken upon clicking depends on the settings + of the model the control belongs to.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel + @see com::sun::star::form::component::ImageButton::ButtonType +*/ +published service ImageButton +{ + service com::sun::star::awt::UnoControlImageControl; + + /** allows external instances to register as veto listener for the button's actions. + + <p>An <type scope="com::sun::star::form">XApproveActionListener</type> returning false on + it's approve-method will prevent any action which would usually be triggered - this includes + not only submitting or resetting forms, but also calling the + <type scope="com::sun::star::awt">XActionListener</type>s of the super service<br/> + This may be interesting for e.g. forms which want to provide input validation before submitting + data.<br/> + + @see com::sun::star::form::component::HTMLForm + @see com::sun::star::form::XSubmit + @see com::sun::star::form::XReset + @see com::sun::star::awt::XButton + */ + interface com::sun::star::form::XApproveActionBroadcaster; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/ImageControl.idl b/offapi/com/sun/star/form/control/ImageControl.idl new file mode 100644 index 000000000000..10ef14cdf60b --- /dev/null +++ b/offapi/com/sun/star/form/control/ImageControl.idl @@ -0,0 +1,74 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_ImageControl_idl__ +#define __com_sun_star_form_control_ImageControl_idl__ + +#ifndef __com_sun_star_awt_UnoControlImageControl_idl__ +#include <com/sun/star/awt/UnoControlImageControl.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control used for displaying images stored in a database. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">DatabaseImageControl</type> + service.</p> + + <p>If the model of the control is valid bound to a database field, the control allows + to select an image (browsing the file system) upon double clicking into it, + and forwards the URL of the chosen image to the ImageURL property of its model.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service ImageControl +{ + service com::sun::star::awt::UnoControlImageControl; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/InteractionGridControl.idl b/offapi/com/sun/star/form/control/InteractionGridControl.idl new file mode 100644 index 000000000000..480f4f26243d --- /dev/null +++ b/offapi/com/sun/star/form/control/InteractionGridControl.idl @@ -0,0 +1,85 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_component_InteractionGridControl_idl__ +#define __com_sun_star_form_component_InteractionGridControl_idl__ + +#ifndef __com_sun_star_form_control_GridControl_idl__ +#include <com/sun/star/form/control/GridControl.idl> +#endif +#ifndef __com_sun_star_frame_XDispatch_idl__ +#include <com/sun/star/frame/XDispatch.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** is an extended grid control, which allows the user to customize some of it's user interface's aspects. +*/ +published service InteractionGridControl +{ + service com::sun::star::form::control::GridControl; + + /** allows access to the UI features of the control + + <p>Though concret implementations of the service may offer different sets of aspects which can be customized, + the following commands have, if supported, a defined meaning: + <dl> + <dt>.uno:GridSlots/BrowserAttribs</dt><dd> (interactively) customize the overall appearance of the grid (font etc.)</dd> + <dt>.uno:GridSlots/RowHeight</dt><dd> (interactively) customize the row height appearance of the grid</dd> + <dt>.uno:GridSlots/ColumnAttribs</dt><dd> (interactively) customize the format of a given column</dd> + <dt>.uno:GridSlots/ColumnWidth</dt><dd> (interactively) customize the width of a given column</dd> + </dl> + </p> + + <p>The following parameters may be passed when dispatching the commands above (as before, concrete implementations + may extend this list): + <dl> + <dt>ColumnId</dt><dd> the id of the column in question, if the command is executed for a column</dd> + <dt>ColumnModelPos</dt><dd> the model position of the column in question, if the command is executed for a column</dd> + <dt>ColumnViewPos</dt><dd> the view position of the column in question, if the command is executed for a column. The + view position may differ from the model position, as in a grid control, columns can be hidden.</dd> + </dl> + </p> + */ + interface com::sun::star::frame::XDispatch; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/ListBox.idl b/offapi/com/sun/star/form/control/ListBox.idl new file mode 100644 index 000000000000..b830a2b3d045 --- /dev/null +++ b/offapi/com/sun/star/form/control/ListBox.idl @@ -0,0 +1,86 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_ListBox_idl__ +#define __com_sun_star_form_control_ListBox_idl__ + +#ifndef __com_sun_star_awt_UnoControlListBox_idl__ +#include <com/sun/star/awt/UnoControlListBox.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +#ifndef __com_sun_star_form_XChangeBroadcaster_idl__ +#include <com/sun/star/form/XChangeBroadcaster.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a list box control which can (but not necessarily has to) be bound to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">ListBox</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service ListBox +{ + service com::sun::star::awt::UnoControlListBox; + + interface com::sun::star::form::XBoundControl; + + /** allows broadcasts of HTML-compatible change events. + + <p>HTML-compatible means that a change event is broadcasted if and only if all of + the following applies. + <ul> + <li>the control loses the focus</li> + <li>the content of the control has changed, compared to the moment where it got the focus.</li> + </ul> + <p/> + */ + interface com::sun::star::form::XChangeBroadcaster; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/NavigationToolBar.idl b/offapi/com/sun/star/form/control/NavigationToolBar.idl new file mode 100644 index 000000000000..7f792a221a34 --- /dev/null +++ b/offapi/com/sun/star/form/control/NavigationToolBar.idl @@ -0,0 +1,57 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_NavigationToolBar_idl__ +#define __com_sun_star_form_control_NavigationToolBar_idl__ + +#ifndef __com_sun_star_awt_UnoControl_idl__ +#include <com/sun/star/awt/UnoControl.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module control { + +//============================================================================= + +/** This service specifies the model for control which provides controller + functionality for a <type scope="com::sun::star::form::component">DataForm</type>, such as navigating or filtering + the form. + + @see com::sun::star::form::component::NavigationToolBar +*/ +service NavigationToolBar +{ + service com::sun::star::awt::UnoControl; +}; + +//============================================================================= + +}; }; }; }; }; + + +#endif diff --git a/offapi/com/sun/star/form/control/NumericField.idl b/offapi/com/sun/star/form/control/NumericField.idl new file mode 100644 index 000000000000..b088f6a782eb --- /dev/null +++ b/offapi/com/sun/star/form/control/NumericField.idl @@ -0,0 +1,71 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_NumericField_idl__ +#define __com_sun_star_form_control_NumericField_idl__ + +#ifndef __com_sun_star_awt_UnoControlNumericField_idl__ +#include <com/sun/star/awt/UnoControlNumericField.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control for inputting numeric values and which can (but not necessarily has to) + be bound to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">NumericField</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service NumericField +{ + service com::sun::star::awt::UnoControlNumericField; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/PatternField.idl b/offapi/com/sun/star/form/control/PatternField.idl new file mode 100644 index 000000000000..8c373702bd34 --- /dev/null +++ b/offapi/com/sun/star/form/control/PatternField.idl @@ -0,0 +1,71 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_PatternField_idl__ +#define __com_sun_star_form_control_PatternField_idl__ + +#ifndef __com_sun_star_awt_UnoControlPatternField_idl__ +#include <com/sun/star/awt/UnoControlPatternField.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control for inputting text complying to a given pattern, + and which can (but not necessarily has to) be bound to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">PatternField</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service PatternField +{ + service com::sun::star::awt::UnoControlPatternField; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/RadioButton.idl b/offapi/com/sun/star/form/control/RadioButton.idl new file mode 100644 index 000000000000..b600885453a8 --- /dev/null +++ b/offapi/com/sun/star/form/control/RadioButton.idl @@ -0,0 +1,70 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_RadioButton_idl__ +#define __com_sun_star_form_control_RadioButton_idl__ + +#ifndef __com_sun_star_awt_UnoControlRadioButton_idl__ +#include <com/sun/star/awt/UnoControlRadioButton.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a radio button control which can (but not necessarily has to) be bound to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">RadioButton</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service RadioButton +{ + service com::sun::star::awt::UnoControlRadioButton; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/SubmitButton.idl b/offapi/com/sun/star/form/control/SubmitButton.idl new file mode 100644 index 000000000000..a0174a45f673 --- /dev/null +++ b/offapi/com/sun/star/form/control/SubmitButton.idl @@ -0,0 +1,88 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_SubmitButton_idl__ +#define __com_sun_star_form_control_SubmitButton_idl__ + +#ifndef __com_sun_star_awt_UnoControlButton_idl__ +#include <com/sun/star/awt/UnoControlButton.idl> +#endif + +#ifndef __com_sun_star_form_submission_XSubmission_idl__ +#include <com/sun/star/form/submission/XSubmission.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module control { + +//============================================================================= + +/** specifies a button control which can execute external submissions + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">SubmitButton</type> + service.</p> + + <p>The control is clickable. When clicked (by mouse or keyboard, or programmatically), + the following happens: + <ol><li>Any <type scope="com::sun::star::form::submission">XSubmissionVetoListener</type>s registered + at the component are given the chance to veto the submission. + </li> + <li>The model of the control is examined for an external submission object. That is, + <member scope="com::sun::star::form::submission">XSubmissionSupplier::getSubmission</member> + is called at the model.<br/> + If there is such a submission object, its + <member scope="com::sun::star::form::submission">XSubmission::submit</member> method is invoked. + </li> + <li>If there is no external submission, the parent object of the model is examined + for the presence of the <type scope="com::sun::star::form">XSubmit</type> interface. If it + is present, it's <member scope="com::sun::star::form">XSubmit::submit</member> method is + invoked.<br/> + Since the parent object of a submit button can only be a <type scope="com::sun::star::form::component">Form</type>, + this means that <type>SubmitButton</type>s are also able to submit <type scope="com::sun::star::form::component">HTMLForm</type>s. + </li> + </ol> + </p> +*/ +service SubmitButton +{ + /** allows interception (and vetoing) of submissions triggered by the control. + */ + interface com::sun::star::form::submission::XSubmission; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/TextField.idl b/offapi/com/sun/star/form/control/TextField.idl new file mode 100644 index 000000000000..71a1ace31ec2 --- /dev/null +++ b/offapi/com/sun/star/form/control/TextField.idl @@ -0,0 +1,90 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_TextField_idl__ +#define __com_sun_star_form_control_TextField_idl__ + +#ifndef __com_sun_star_awt_UnoControlEdit_idl__ +#include <com/sun/star/awt/UnoControlEdit.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif +#ifndef __com_sun_star_form_XChangeBroadcaster_idl__ +#include <com/sun/star/form/XChangeBroadcaster.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control for entering arbiotrary text which can (but not necessarily has to) be bound + to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">TextField</type> + service.</p> + + <p>In addition, this control can be used in HTML forms. It triggers the + <method scope="com::sun::star::form">XSubmit::submit</method> method of the form it belongs to if + the <em>enter</em> is pressed while it has the focus.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service TextField +{ + service com::sun::star::awt::UnoControlEdit; + + interface com::sun::star::form::XBoundControl; + + /** allows broadcasts of HTML-compatible change events. + + <p>HTML-compatible means that a change event is broadcasted if and only if all of + the following applies. + <ul> + <li>the control loses the focus</li> + <li>the content of the control has changed, compared to the moment where it got the focus.</li> + </ul> + <p/> + */ + interface com::sun::star::form::XChangeBroadcaster; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/TimeField.idl b/offapi/com/sun/star/form/control/TimeField.idl new file mode 100644 index 000000000000..20cd540c82a2 --- /dev/null +++ b/offapi/com/sun/star/form/control/TimeField.idl @@ -0,0 +1,71 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_control_TimeField_idl__ +#define __com_sun_star_form_control_TimeField_idl__ + +#ifndef __com_sun_star_awt_UnoControlTimeField_idl__ +#include <com/sun/star/awt/UnoControlTimeField.idl> +#endif + +#ifndef __com_sun_star_form_XBoundControl_idl__ +#include <com/sun/star/form/XBoundControl.idl> +#endif + +//============================================================================= + + module com { module sun { module star { module form { module control { + +//============================================================================= + +/** describes a control for inputting time values which can (but not necessarily has to) be bound + to a database field. + + <p>The model of the control has to support the <type scope="com::sun::star::form::component">TimeField</type> + service.</p> + + @see com::sun::star::awt::UnoControl + @see com::sun::star::awt::UnoControlModel +*/ +published service TimeField +{ + service com::sun::star::awt::UnoControlTimeField; + + interface com::sun::star::form::XBoundControl; +}; + +//============================================================================= + +}; }; }; }; }; + +/*============================================================================= + +=============================================================================*/ + +#endif + + diff --git a/offapi/com/sun/star/form/control/makefile.mk b/offapi/com/sun/star/form/control/makefile.mk new file mode 100644 index 000000000000..6e972b224b69 --- /dev/null +++ b/offapi/com/sun/star/form/control/makefile.mk @@ -0,0 +1,64 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/..$/..$/.. + +PRJNAME=offapi + +TARGET=cssfcontrol +PACKAGE=com$/sun$/star$/form$/control + +# --- Settings ----------------------------------------------------- +.INCLUDE : $(PRJ)$/util$/makefile.pmk + +# ------------------------------------------------------------------------ + +IDLFILES=\ + CheckBox.idl \ + ComboBox.idl \ + CommandButton.idl \ + CurrencyField.idl \ + DateField.idl \ + FormattedField.idl \ + GridControl.idl \ + GroupBox.idl \ + ImageButton.idl \ + ImageControl.idl \ + InteractionGridControl.idl \ + ListBox.idl \ + NumericField.idl \ + PatternField.idl \ + RadioButton.idl \ + TextField.idl \ + TimeField.idl \ + SubmitButton.idl \ + NavigationToolBar.idl + +# ------------------------------------------------------------------ + +.INCLUDE : target.mk +.INCLUDE : $(PRJ)$/util$/target.pmk diff --git a/offapi/com/sun/star/form/inspection/ButtonNavigationHandler.idl b/offapi/com/sun/star/form/inspection/ButtonNavigationHandler.idl new file mode 100644 index 000000000000..99145dc4f036 --- /dev/null +++ b/offapi/com/sun/star/form/inspection/ButtonNavigationHandler.idl @@ -0,0 +1,65 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_ButtonNavigationHandler_idl__ +#define __com_sun_star_form_ButtonNavigationHandler_idl__ + +#ifndef __com_sun_star_inspection_XPropertyHandler_idl__ +#include <com/sun/star/inspection/XPropertyHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements a property handler for use with an <type scope="com::sun::star::inspection">ObjectInspector</type> + which is able to enhance the <member scope="com::sun::star::form::component">CommandButton::ButtonType</member> + and <member scope="com::sun::star::form::component">CommandButton::TargetURL</member> properties of a + <type scope="com::sun::star::form::component">CommandButton</type>. + + <p>For this, the two properties are superseded by new versions, where as button type, additional + possible values are added for navigating the parent form of the button. For instance, in an + <type scope="com::sun::star::inspection">ObjectInspector</type> using this handler, the user will be able + to choose a button type saying "move to the next record", which, when chosen, well, moves the parent + database form of the button to the next record.</p> + + @see com::sun::star::inspection::XPropertyHandler + @see com::sun::star::form::component::CommandButton +*/ +service ButtonNavigationHandler +{ + interface com::sun::star::inspection::XPropertyHandler; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/inspection/CellBindingPropertyHandler.idl b/offapi/com/sun/star/form/inspection/CellBindingPropertyHandler.idl new file mode 100644 index 000000000000..609f087f71f1 --- /dev/null +++ b/offapi/com/sun/star/form/inspection/CellBindingPropertyHandler.idl @@ -0,0 +1,68 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_inspection_CellBindingPropertyHandler_idl__ +#define __com_sun_star_form_inspection_CellBindingPropertyHandler_idl__ + +#ifndef __com_sun_star_inspection_XPropertyHandler_idl__ +#include <com/sun/star/inspection/XPropertyHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements a property handler for use with an <type scope="com::sun::star::inspection">ObjectInspector</type> + which is able to provide properties to bind a form component to a spreadsheet cell. + + <p>The handler expects a value named "ContextDocument" in the context in which it is created. + That is, the <type scope="com::sun::star::uno">XComponentContext</type> used for creating the + <type>CellBindingPropertyHandler</type> is examined for a value with this name. If the object in this + value denotes a spreadsheet document (indicated by supporting the <type scope="com::sun::star::sheet">XSpreadsheetDocument</type> + interface), this document is used to create the <type scope="com::sun::star::form::binding">ValueBinding</type>s + to bind the inspected object to cells in this document.</p> + + @see com::sun::star::inspection::XPropertyHandler + @see com::sun::star::form::binding::BindableControlModel + @see com::sun::star::form::binding::ValueBinding + @see com::sun::star::table::CellValueBinding + @see com::sun::star::table::ListPositionCellBinding + @see com::sun::star::uno::XComponentContext::getValueByName +*/ +service CellBindingPropertyHandler +{ + interface com::sun::star::inspection::XPropertyHandler; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/inspection/DefaultFormComponentInspectorModel.idl b/offapi/com/sun/star/form/inspection/DefaultFormComponentInspectorModel.idl new file mode 100644 index 000000000000..b743fe4be85b --- /dev/null +++ b/offapi/com/sun/star/form/inspection/DefaultFormComponentInspectorModel.idl @@ -0,0 +1,101 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_DefaultFormComponentInspectorModel_idl__ +#define __com_sun_star_form_DefaultFormComponentInspectorModel_idl__ + +#ifndef __com_sun_star_inspection_XObjectInspectorModel_idl__ +#include <com/sun/star/inspection/XObjectInspectorModel.idl> +#endif +#ifndef __com_sun_star_lang_IllegalArgumentException_idl__ +#include <com/sun/star/lang/IllegalArgumentException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements a <type scope="com::sun::star::inspection">XObjectInspectorModel</type> for + inspecting form components, in particular all components implementing the <type>FormComponent</type> + service. + + <p>A <type>DefaultFormComponentInspectorModel</type> provides the following handlers by default: + <ul><li><type>ButtonNavigationHandler</type></li> + <li><type>CellBindingPropertyHandler</type></li> + <li><type>EditPropertyHandler</type></li> + <li><type>EventHandler</type></li> + <li><type>FormComponentPropertyHandler</type></li> + <li><type>SubmissionPropertyHandler</type></li> + <li><type>XMLFormsPropertyHandler</type></li> + <li><type>XSDValidationPropertyHandler</type></li> + </ul></p> + + @see com::sun::star::inspection::XObjectInspectorModel::HandlerFactories +*/ +service DefaultFormComponentInspectorModel : com::sun::star::inspection::XObjectInspectorModel +{ + /** creates a default DefaultFormComponentInspectorModel, providing factories for all + handlers listed above. + + @since OOo 2.2.0 + */ + createDefault(); + + /** creates a default DefaultFormComponentInspectorModel, providing factories for all + handlers listed above, and describing an ObjectInspector which has a help section. + + @param minHelpTextLines + denotes the minimum number of lines of text to be reserved for the help + section. + + @param maxHelpTextLines + denotes the maximum number of lines of text to be reserved for the help + section. + + @throws ::com::sun::star::lang::IllegalArgumentException + if <arg>minHelpTextLines</arg> or <arg>maxHelpTextLines</arg> are negative, + or if <arg>minHelpTextLines</arg> is greater than <arg>maxHelpTextLines</arg>. + + @see XObjectInspectorModel::HasHelpSection + @see XObjectInspectorModel::MinHelpTextLines + @see XObjectInspectorModel::MaxHelpTextLines + + @since OOo 2.2.0 + */ + createWithHelpSection( + [in] long minHelpTextLines, + [in] long maxHelpTextLines + ) + raises ( ::com::sun::star::lang::IllegalArgumentException ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/inspection/EditPropertyHandler.idl b/offapi/com/sun/star/form/inspection/EditPropertyHandler.idl new file mode 100644 index 000000000000..2e206f7f1f52 --- /dev/null +++ b/offapi/com/sun/star/form/inspection/EditPropertyHandler.idl @@ -0,0 +1,69 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_inspection_EditPropertyHandler_idl__ +#define __com_sun_star_form_inspection_EditPropertyHandler_idl__ + +#ifndef __com_sun_star_inspection_XPropertyHandler_idl__ +#include <com/sun/star/inspection/XPropertyHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements a property handler for use with an <type scope="com::sun::star::inspection">ObjectInspector</type> + which provides convinience wrappers for some properties existing at a form component + derived from <type scope="com::sun::star::awt">UnoControlEditModel</type>. + + <p>First, the handler supersedes the HScroll and the VScroll properties of a <type scope="com::sun::star::awt">UnoControlEditModel</type> + and puts them into one common property, allowing the user to choose whether she want to + have "no", a "vertical", a "horizontal", or "both" scrollbars.<p> + + <p>Second, if it detects a <type scope="com::sun::star::form::component">RichTextControl</type> to inspect, + it supersedes the <member scope="com::sun::star::form::component">RichTextControl::RichText</member> + and the <member scope="com::sun::star::awt">UnoControlEditModel::MultiLine</member> properties with a new + one which allows choosing the text type with one single action.</p> + + @see com::sun::star::inspection::XPropertyHandler + @see com::sun::star::awt::UnoControlEditModel + @see com::sun::star::form::component::RichTextControl + @see com::sun::star::form::component::TextField +*/ +service EditPropertyHandler +{ + interface com::sun::star::inspection::XPropertyHandler; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/inspection/EventHandler.idl b/offapi/com/sun/star/form/inspection/EventHandler.idl new file mode 100644 index 000000000000..3940c082af22 --- /dev/null +++ b/offapi/com/sun/star/form/inspection/EventHandler.idl @@ -0,0 +1,63 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_EventHandler_idl__ +#define __com_sun_star_form_EventHandler_idl__ + +#ifndef __com_sun_star_inspection_XPropertyHandler_idl__ +#include <com/sun/star/inspection/XPropertyHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements a property handler for use with an <type scope="com::sun::star::inspection">ObjectInspector</type> + which, for a <type scope="com::sun::star::form">FormComponent</type>, provides the script events + offered by this form component. + + <p>For this, the parent of the form component, which by definition supports the <type scope="com::sun::star::form">FormComponent</type> + service, is examined for the <type scope="com::sun::star::script">XEventAttacherManager</type> interface.</p> + + @see com::sun::star::inspection::XPropertyHandler + @see com::sun::star::form::component::CommandButton + @see com::sun::star::form::FormComponents + @see com::sun::star::script::XEventAttacherManager +*/ +service EventHandler +{ + interface com::sun::star::inspection::XPropertyHandler; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/inspection/FormComponentPropertyHandler.idl b/offapi/com/sun/star/form/inspection/FormComponentPropertyHandler.idl new file mode 100644 index 000000000000..3b51ba36b6ac --- /dev/null +++ b/offapi/com/sun/star/form/inspection/FormComponentPropertyHandler.idl @@ -0,0 +1,56 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_inspection_FormComponentPropertyHandler_idl__ +#define __com_sun_star_form_inspection_FormComponentPropertyHandler_idl__ + +#ifndef __com_sun_star_inspection_XPropertyHandler_idl__ +#include <com/sun/star/inspection/XPropertyHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements the default property handler for all known types of <type scope="com::sun::star::form">FormComponent</type>s. + + @see com::sun::star::inspection::XPropertyHandler + @see com::sun::star::form::FormComponents +*/ +service FormComponentPropertyHandler +{ + interface com::sun::star::inspection::XPropertyHandler; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/inspection/SubmissionPropertyHandler.idl b/offapi/com/sun/star/form/inspection/SubmissionPropertyHandler.idl new file mode 100644 index 000000000000..449368af6a1a --- /dev/null +++ b/offapi/com/sun/star/form/inspection/SubmissionPropertyHandler.idl @@ -0,0 +1,67 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_inspection_SubmissionPropertyHandler_idl__ +#define __com_sun_star_form_inspection_SubmissionPropertyHandler_idl__ + +#ifndef __com_sun_star_inspection_XPropertyHandler_idl__ +#include <com/sun/star/inspection/XPropertyHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements a property handler for use with an <type scope="com::sun::star::inspection">ObjectInspector</type> + which provides properties for button controls which support submission of XML forms. + + <p>The handler expects a value named "ContextDocument" in the context in which it is created. + That is, the <type scope="com::sun::star::uno">XComponentContext</type> used for creating the + <type>CellBindingPropertyHandler</type> is examined for a value with this name. If the object in this + value denotes a XML form document (indicated by supporting the <type scope="com::sun::star::xforms">XFormsSupplier</type> + interface), this document is used to examine the XML submissions which the button can be bound to.</p> + + @see com::sun::star::inspection::XPropertyHandler + @see com::sun::star::form::submission::XSubmission + @see com::sun::star::form::submission::XSubmissionProvider + @see com::sun::star::form::component::SubmitButton + @see com::sun::star::xforms::XSubmission + @see com::sun::star::uno::XComponentContext::getValueByName +*/ +service SubmissionPropertyHandler +{ + interface com::sun::star::inspection::XPropertyHandler; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/inspection/XMLFormsPropertyHandler.idl b/offapi/com/sun/star/form/inspection/XMLFormsPropertyHandler.idl new file mode 100644 index 000000000000..654e17a21ba4 --- /dev/null +++ b/offapi/com/sun/star/form/inspection/XMLFormsPropertyHandler.idl @@ -0,0 +1,73 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_inspection_XMLFormsPropertyHandler_idl__ +#define __com_sun_star_form_inspection_XMLFormsPropertyHandler_idl__ + +#ifndef __com_sun_star_inspection_XPropertyHandler_idl__ +#include <com/sun/star/inspection/XPropertyHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements a property handler for use with an <type scope="com::sun::star::inspection">ObjectInspector</type> + which provides properties related to binding form control models to XForm bindings. + + <p>The handler introduces new properties to choose an <type scope="com::sun::star::xforms">XModel</type> + and a <type scope="com::sun::star::xforms">Binding</type> within this model. Additionally, + it introduces properties which reflect the different facets of the binding (e.g. + <member scope="com::sun::star::xforms">Binding::BindingExpression</member>), so they can be changed + directly in the <type scope="com::sun::star::inspection">ObjectInspector</type> as if they were a + property of the form component which is being inspected.</p> + + <p>The handler expects a value named "ContextDocument" in the context in which it is created. + That is, the <type scope="com::sun::star::uno">XComponentContext</type> used for creating the + <type>CellBindingPropertyHandler</type> is examined for a value with this name. If the object in this + value denotes a XML form document (indicated by supporting the <type scope="com::sun::star::xforms">XFormsSupplier</type> + interface), this document is used to do XML binding related work.</p> + + @see com::sun::star::inspection::XPropertyHandler + @see com::sun::star::form::binding::BindableControlModel + @see com::sun::star::form::binding::ValueBinding + @see com::sun::star::xforms::Binding + @see com::sun::star::uno::XComponentContext::getValueByName +*/ +service XMLFormsPropertyHandler +{ + interface com::sun::star::inspection::XPropertyHandler; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/inspection/XSDValidationPropertyHandler.idl b/offapi/com/sun/star/form/inspection/XSDValidationPropertyHandler.idl new file mode 100644 index 000000000000..6896225cfbdd --- /dev/null +++ b/offapi/com/sun/star/form/inspection/XSDValidationPropertyHandler.idl @@ -0,0 +1,77 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_inspection_XSDValidationPropertyHandler_idl__ +#define __com_sun_star_form_inspection_XSDValidationPropertyHandler_idl__ + +#ifndef __com_sun_star_inspection_XPropertyHandler_idl__ +#include <com/sun/star/inspection/XPropertyHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module inspection { + +//============================================================================= + +/** implements a property handler for use with an <type scope="com::sun::star::inspection">ObjectInspector</type> + which provides properties related to binding form control models to XForm bindings and validating + the form control content. + + <p>By using an <type>XMLFormsPropertyHandler</type>, an <type scope="com::sun::star::inspection">ObjectInspector</type> + can be used to bind form components to <type scope="com::sun::star::xforms">Binding</type> instances. + Since those instances also support validating form control content (by supporting an + <type scope="com::sun::star::form::validation">XValidator</type> interface), it seems reasonable to + edit those validate-related properties (like the XSD data type to validate against) in the + <type scope="com::sun::star::inspection">ObjectInspector</type>, too. This is what an <type>XSDValidationPropertyHandler</type> + is good for.</p> + + <p>The handler expects a value named "ContextDocument" in the context in which it is created. + That is, the <type scope="com::sun::star::uno">XComponentContext</type> used for creating the + <type>CellBindingPropertyHandler</type> is examined for a value with this name. If the object in this + value denotes a XML form document (indicated by supporting the <type scope="com::sun::star::xforms">XFormsSupplier</type> + interface), this document is used to do XML binding related work.</p> + + @see com::sun::star::inspection::XPropertyHandler + @see com::sun::star::form::binding::BindableControlModel + @see com::sun::star::form::binding::ValueBinding + @see com::sun::star::forms::validation::ValidatableControlModel + @see com::sun::star::xforms::Binding + @see com::sun::star::xsd::XDataType + @see com::sun::star::uno::XComponentContext::getValueByName +*/ +service XSDValidationPropertyHandler +{ + interface com::sun::star::inspection::XPropertyHandler; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/inspection/makefile.mk b/offapi/com/sun/star/form/inspection/makefile.mk new file mode 100644 index 000000000000..e867febf8220 --- /dev/null +++ b/offapi/com/sun/star/form/inspection/makefile.mk @@ -0,0 +1,54 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/..$/..$/.. + +PRJNAME=offapi + +TARGET=cssfinsp +PACKAGE=com$/sun$/star$/form$/inspection + +# --- Settings ----------------------------------------------------- +.INCLUDE : $(PRJ)$/util$/makefile.pmk + +# ------------------------------------------------------------------------ + +IDLFILES=\ + ButtonNavigationHandler.idl \ + CellBindingPropertyHandler.idl \ + DefaultFormComponentInspectorModel.idl \ + EditPropertyHandler.idl \ + EventHandler.idl \ + FormComponentPropertyHandler.idl \ + SubmissionPropertyHandler.idl \ + XMLFormsPropertyHandler.idl \ + XSDValidationPropertyHandler.idl + +# ------------------------------------------------------------------ + +.INCLUDE : target.mk +.INCLUDE : $(PRJ)$/util$/target.pmk diff --git a/offapi/com/sun/star/form/makefile.mk b/offapi/com/sun/star/form/makefile.mk new file mode 100644 index 000000000000..b1161cb2a14a --- /dev/null +++ b/offapi/com/sun/star/form/makefile.mk @@ -0,0 +1,104 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/..$/.. + +PRJNAME=offapi + +TARGET=cssform +PACKAGE=com$/sun$/star$/form + +# --- Settings ----------------------------------------------------- +.INCLUDE : $(PRJ)$/util$/makefile.pmk + +# ------------------------------------------------------------------------ + +IDLFILES=\ + modules.idl\ + DataAwareControlModel.idl\ + DatabaseDeleteEvent.idl\ + DatabaseParameterEvent.idl\ + DataSelectionType.idl\ + ErrorEvent.idl\ + FormButtonType.idl\ + FormComponent.idl\ + FormComponents.idl\ + FormComponentType.idl\ + FormController.idl\ + FormControllerDispatcher.idl\ + FormControlModel.idl\ + Forms.idl\ + FormSubmitEncoding.idl\ + FormSubmitMethod.idl\ + ListSourceType.idl\ + NavigationBarMode.idl\ + PropertyBrowserController.idl\ + TabulatorCycle.idl\ + XApproveActionBroadcaster.idl\ + XApproveActionListener.idl\ + XBoundComponent.idl\ + XBoundControl.idl\ + XChangeBroadcaster.idl\ + XChangeListener.idl\ + XConfirmDeleteBroadcaster.idl\ + XConfirmDeleteListener.idl\ + XDatabaseParameterBroadcaster.idl\ + XDatabaseParameterBroadcaster2.idl\ + XDatabaseParameterListener.idl\ + XDeleteListener.idl\ + XErrorBroadcaster.idl\ + XErrorListener.idl\ + XForm.idl\ + XFormComponent.idl\ + XFormController.idl\ + XFormControllerListener.idl\ + XFormsSupplier.idl\ + XFormsSupplier2.idl\ + XGrid.idl\ + XGridColumnFactory.idl\ + XGridControl.idl\ + XGridControlListener.idl\ + XGridFieldDataSupplier.idl\ + XGridPeer.idl\ + XImageProducerSupplier.idl\ + XInsertListener.idl\ + XLoadListener.idl\ + XPositioningListener.idl\ + XReset.idl\ + XResetListener.idl\ + XRestoreListener.idl\ + XSubmit.idl\ + XSubmitListener.idl\ + XUpdateBroadcaster.idl\ + XUpdateListener.idl\ + XLoadable.idl\ + + +# ------------------------------------------------------------------ + +.INCLUDE : target.mk +.INCLUDE : $(PRJ)$/util$/target.pmk diff --git a/offapi/com/sun/star/form/modules.idl b/offapi/com/sun/star/form/modules.idl new file mode 100644 index 000000000000..176443733589 --- /dev/null +++ b/offapi/com/sun/star/form/modules.idl @@ -0,0 +1,68 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_modules_form_idl__ +#define __com_sun_star_modules_form_idl__ + +module com { module sun { module star { module form { + + /** collects functionality for binding form controls to external + data sources. + */ + module binding { }; + + /** collects form control model descriptions + */ + module component { }; + + /** collects form control descriptions + */ + module control { }; + + /** collects services for inspecting form/components + @see com::sun::star::inspection::ObjectInspector + @see com::sun::star::inspection + */ + module inspection { }; + + /** collects functionality needed during a form's runtime, e.g. + when it is active and interacts with the user. + */ + module runtime { }; + + /** collects functionality for submitting forms to external data sinks + */ + module submission { }; + + /** collects functionality to validate form components by help + of external validator instances + */ + module validation { }; + +}; }; }; }; + +#endif + diff --git a/offapi/com/sun/star/form/runtime/FeatureState.idl b/offapi/com/sun/star/form/runtime/FeatureState.idl new file mode 100644 index 000000000000..996aff1e8076 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/FeatureState.idl @@ -0,0 +1,62 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ +#ifndef __com_sun_star_form_runtime_FeatureState_idl__ +#define __com_sun_star_form_runtime_FeatureState_idl__ + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +/** encapsulates the state of a FormFeature + + @see XFormOperations + + @since OpenOffice.org 2.2.0 + */ +struct FeatureState +{ + /** determines whether the respective feature is enabled (i.e. available) + in the current state of the form. + */ + boolean Enabled; + + /** determines the state of the feature. The concrete semantics depends + on the concrete <type>FormFeature</type>. + */ + any State; +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif + diff --git a/offapi/com/sun/star/form/runtime/FilterEvent.idl b/offapi/com/sun/star/form/runtime/FilterEvent.idl new file mode 100644 index 000000000000..b7cc035113cb --- /dev/null +++ b/offapi/com/sun/star/form/runtime/FilterEvent.idl @@ -0,0 +1,65 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef __com_sun_star_form_runtime_FilterEvent_idl__ +#define __com_sun_star_form_runtime_FilterEvent_idl__ + +#include <com/sun/star/lang/EventObject.idl> + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +/** is an event fired by a filter controller, when the filter managed by the controller changes. + + @see XFilterController + + @since OpenOffice.org 3.3 + */ +struct FilterEvent : ::com::sun::star::lang::EventObject +{ + /** denotes the index of the <em>disjunctive term</em> to which the event applies, if any. + */ + long DisjunctiveTerm; + + /** denotes the index of the <em>filter component</em> to which the event applies, if any. + */ + long FilterComponent; + + /** denotes the <em>predicate expression</em> associated with the event. + */ + string PredicateExpression; +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/FormController.idl b/offapi/com/sun/star/form/runtime/FormController.idl new file mode 100644 index 000000000000..6a03270a1b52 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/FormController.idl @@ -0,0 +1,52 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef __offapi_com_sun_star_form_runtime_FormController_idl__ +#define __offapi_com_sun_star_form_runtime_FormController_idl__ + +#include <com/sun/star/form/runtime/XFormController.idl> + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +/** specifies a component controlling the interaction between the user and multiple + form controls belonging to a single form. + */ +service FormController +{ + interface XFormController; +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/FormFeature.idl b/offapi/com/sun/star/form/runtime/FormFeature.idl new file mode 100644 index 000000000000..57ebcc8ef7b7 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/FormFeature.idl @@ -0,0 +1,155 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_runtime_FormFeature_idl__ +#define __com_sun_star_form_runtime_FormFeature_idl__ + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +/** specifies the operations on a user interface form, as supported by the + <type>XFormOperations</type> interface. + + @since OpenOffice.org 2.2.0 +*/ +constants FormFeature +{ + /** moves the form to a record given by absolute position. + + <p>This operation cannot be executed without arguments. When executing it (i.e. + when calling <member scope="com::sun::star::form::runtime">XFormOperations::executeWithArguments</member>), + you need to specify a parameter named <em>Position</em> of type <code>long</code>, which + denotes the position to move the form to.</p> + */ + const short MoveAbsolute = 1; + + /** determines the number of total records in the form, + including the potentially active insertion row. + + <p>This is not strictly an operation you can do on a form, but rather a + state you can retrieve (and display to the user) using the <type>XFormOperations</type>' + respective methods.</p> + + <p>The state obtained here is a string, not a number. This is because in an UI + form, the fact that the current record count is not yet known (since not all + records have been visited, yet) is indicated by an asterik (<code>*</code>) besides + the record count.</p> + */ + const short TotalRecords = 2; + + /// moves the form to the first record + const short MoveToFirst = 3; + + /// moves the form to the record before the current record, if there is any + const short MoveToPrevious = 4; + + /// moves the form to the record after the current record, if there is any + const short MoveToNext = 5; + + /// moves the form to the last record + const short MoveToLast = 6; + + /// moves the form to the insertion row, if privileges allow + const short MoveToInsertRow = 7; + + /** saves all changes in the form's current record, including changes in the current + control which had not yet been committed to the form + */ + const short SaveRecordChanges = 8; + + /** revertsall changes in the form's current record, including changes in the current + control which had not yet been committed to the form + */ + const short UndoRecordChanges = 9; + + /** deletes the current record, while honoring any registered + <type scope="com::sun::star::form">XConfirmDeleteListener</type>s + */ + const short DeleteRecord = 10; + + /// reloads the form content + const short ReloadForm = 11; + + /// sorts the form ascending by the field which the active form control is bound to. + const short SortAscending = 12; + + /// sorts the form descending by the field which the active form control is bound to. + const short SortDescending = 13; + + /// opens a dialog which allows the user to interactively specify a form sorting order + const short InteractiveSort = 14; + + /** adds a filter to the form, which is defined by the active form control and its + current value + + <p>For instance, if the currently active form control is bound to a table field + named <code>Price</code>, and currently has a value of <code>100</code>, then invoking + the <code>AutoFilter</code> operation will put an additional filter <code>Price = 100</code> + on the form.</p> + */ + const short AutoFilter = 15; + + /// opens a dialog which allows the user to interactively specify a form filter + const short InteractiveFilter = 16; + + /** toggles the <member scope="com::sun::star::sdb">RowSet::ApplyFilter</member> property + of a the form. + */ + const short ToggleApplyFilter = 17; + + /** removes all filter and sort criterions put on the form. + + <p>Note that this does not apply to criterios which are part of the form's + data source. That is, if you bind the form to the SQL command <code>SELECT * FROM + Articles WHERE Price > 100</code>, then the <code>Price > 100</code> filter + will not be removed.</p> + + <p>Effectively, this operation resets the <member scope="com::sun::star::sdb">RowSet::Filter</member> + and <member scope="com::sun::star::sdb">RowSet::Order</member> properties of the form.</p> + */ + const short RemoveFilterAndSort = 18; + + /** refreshs the current control + + <p>Basically, this means calling XRefreshable::refresh on the current control, if it supports + this interface.</p> + + @since OOo 3.1 + */ + const short RefreshCurrentControl = 19; +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/FormOperations.idl b/offapi/com/sun/star/form/runtime/FormOperations.idl new file mode 100644 index 000000000000..aa4b7e825c8c --- /dev/null +++ b/offapi/com/sun/star/form/runtime/FormOperations.idl @@ -0,0 +1,91 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_runtime_FormOperations_idl__ +#define __com_sun_star_form_runtime_FormOperations_idl__ + +#ifndef __com_sun_star_form_runtime_XFormOperations_idl__ +#include <com/sun/star/form/runtime/XFormOperations.idl> +#endif +#ifndef __com_sun_star_form_runtime_XFormController_idl__ +#include <com/sun/star/form/runtime/XFormController.idl> +#endif +#ifndef __com_sun_star_form_XForm_idl__ +#include <com/sun/star/form/XForm.idl> +#endif +#ifndef __com_sun_star_lang_IllegalArgumentException_idl__ +#include <com/sun/star/lang/IllegalArgumentException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +/** encapsulates operations on a database form which has a UI representation, + and is interacting with the user. + + @since OpenOffice.org 2.2.0 + */ +service FormOperations : XFormOperations +{ + /** creates a <code>FormOperations</code> instance which works on a <type scope="com::sun::star::form">FormController</type> + instance. + @throws IllegalArgumentException + if the given form controller is <NULL/>, or does not have a model denoting a valid + <type scope="com::sun::star::form::component">DataForm</type> instance. + */ + createWithFormController( + [in] XFormController Controller + ) + raises( + ::com::sun::star::lang::IllegalArgumentException + ); + + /** creates a <code>FormOperations</code> instance which works on a <type scope="com::sun::star::form::component">DataForm</type> + instance. + + @throws IllegalArgumentException + if the given form is <NULL/>, or does not support the <type scope="com::sun::star::form::component">DataForm</type> + service. + */ + createWithForm( + [in] XForm Form + ) + raises( + ::com::sun::star::lang::IllegalArgumentException + ); +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/XFeatureInvalidation.idl b/offapi/com/sun/star/form/runtime/XFeatureInvalidation.idl new file mode 100644 index 000000000000..b435e64a6d81 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/XFeatureInvalidation.idl @@ -0,0 +1,76 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_runtime_XFeatureInvalidation_idl__ +#define __com_sun_star_form_runtime_XFeatureInvalidation_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +/** implements a callback for a <type>XFormOperations</type> instance, which is called + when the state of one or more <type>FormFeature</type>s might have changed. + + @see XFormOperations + + @since OpenOffice.org 2.2.0 +*/ +interface XFeatureInvalidation +{ + /** invalidates the given <type>FormFeature</type>s + + <p>Invalidation means that any user interface representation (such as toolbox buttons), or + any dispatches associated with the features in question are potentially out-of-date, and + need to be updated.</p> + + @param Features + The set of features whose state might have changed. + */ + void invalidateFeatures( [in] sequence< short > Features ); + + /** invalidates all features + + <p>This method is used of it cannot be exactly and reliably determined + which features might actually have changed their state. In this case, the callee + should assume all features it is interested in must be requeried.</p> + */ + void invalidateAllFeatures(); +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/XFilterController.idl b/offapi/com/sun/star/form/runtime/XFilterController.idl new file mode 100644 index 000000000000..8f3fded592d9 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/XFilterController.idl @@ -0,0 +1,181 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef __offapi_com_sun_star_form_runtime_XFilterController_idl__ +#define __offapi_com_sun_star_form_runtime_XFilterController_idl__ + +#include <com/sun/star/awt/XControl.idl> +#include <com/sun/star/lang/IndexOutOfBoundsException.idl> + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +interface XFilterControllerListener; + +/** provides access to a form based filter for a database form + + <p>In a form based filter, form controls bound to a searchable database field are replaced with a control + which allows entering a search expression. This so-called <em>predicate expression</em> is basically a part of an + SQL <code>WHERE</code> clause, but without the the part denoting the database column. For instance, if you + have a form control bound to a table column named <code>Name</code>, then entering the string + <q>LIKE '%Smith%'</q> effectively consitutes a SQL <code>WHERE</code> clause <code>"Name" LIKE '%Smith%'</code>.</p> + + <p>In the actual document view, there are usually some relaxations to this. For instance, keywords such as + <code>LIKE</code> might be localized, according to OpenOffice.org's UI locale. Also, for an equality criterion, + the equality sign <code>=</code> is usually omitted. However, this interface here provides programmatic access + to the form based filter, so those relaxations are not considered here.</p> + + <p>The filter maintained by a filter controller is, logically, a disjunctive normal form of an SQL <code>WHERE</code> + class. That is, it is a disjunction of <em>m</em> terms, where each term is a conjunction of <em>n</em> clauses + of the form <code><column> <predicate> <literal></code> or of the form <code><em><column> + IS [NOT] NULL</em></code>.</p> + + <p><em>n</em> equals the number of filter controls which the filter controller is responsible for. This number + doesn't change during one session of the form based filter. On the other hand, <em>m</em>, the number of disjunctive + terms, is dynamic.</p> + + <a name="active_term"></a> + <p>With the above, there are potentially <em>m * n</em> <em>predicate expressions</em> (though usually only a fraction + of those will actually exist). Since in a form based filter, there are only <em>n</em> filter controls, and each + filter control displays exactly one <em>predicate expression</em>, this means that only a part of the complete + filter can be displayed, in particular, only one <em>disjunctive term</em> can be displayed at a time. Thus, + the filter controller knows the concept of an <em>active term</em>, denoted by the <member>ActiveTerm</member> + attribute, controls which of the terms is currently displayed in the form controls.</p> + + @see XFormController + @see com::sun::star::sdbc::XResultSetMetaData::isSearchable + @see com::sun::star::sdb::XSingleSelectQueryAnalyzer::getStructuredFilter + @see com::sun::star::sdb::SQLFilterOperator + + @since OpenOffice.org 3.3 + */ +interface XFilterController +{ + /** registers a listener to be notified of certain changes in the form based filter. + + <p>Registering the same listener multiple times results in multiple notifications of the same event, + and also requires multiple revocations of the listener. + */ + void addFilterControllerListener( [in] XFilterControllerListener _Listener ); + + /** revokes a listener which was previously registered to be notified of certain changes in the form based filter. + */ + void removeFilterControllerListener( [in] XFilterControllerListener _Listener ); + + /** is the number of <em>filter components</em>, or filter controls, which the filter controller is responsible + for. + + <p>This number is constant during one session of the form based filter.</p> + */ + [attribute, readonly] long FilterComponents; + + /** is the number of <em>disjunctive terms</em> of the filter expression represented by the form based filter. + */ + [attribute, readonly] long DisjunctiveTerms; + + /** denotes the <a href="#active_term"><em>active term</em></a> of the filter controller. + */ + [attribute] long ActiveTerm + { + set raises ( ::com::sun::star::lang::IndexOutOfBoundsException ); + }; + + /** sets a given <em>predicate expression</em> + + @param _Component + denotes the filter component whose expression is to be set. Must be greater than or equal to 0, and smaller than + <member>FilterComponents</member>. + + @param _Term + denotes the <em>disjunctive term</em> in which the expression is to be set. Must be greater than or equal to 0, + and smaller than <member>DisjunctiveTerms</member>. + + @param _PredicateExpression + denotes the <em>predicate expression</em> to set for the given filter component in the given term. + + @throws ::com::sun::star::lang::IndexOutOfBoundsException + if one of the indexes is out of the allowed range + */ + void + setPredicateExpression( [in] long _Component, [in] long _Term, [in] string _PredicateExpression ) + raises( ::com::sun::star::lang::IndexOutOfBoundsException ); + + /** retrieves the filter component with the given index. + + <p>The filter control has the same control model as the control which it stands in for. Consequently, you can use this method + to obtain the database column which the filter control works on, by examining the control model's <code>BoundField</code> + property.</p> + + @param _Component + denotes the index of the filter component whose control should be obtained. Must be greater than or equal to 0, + and smaller than <member>FilterComponents</member>. + + @throws ::com::sun::star::lang::IndexOutOfBoundsException + if <arg>_Component</arg> is out of the allowed range. + + @see ::com::sun::star::form::component::DataAwareControlModel::BoundField + */ + ::com::sun::star::awt::XControl + getFilterComponent( [in] long _Component ) + raises( ::com::sun::star::lang::IndexOutOfBoundsException ); + + /** retrieves the entirety of the <em>predicate expressions</em> represented by the filter controller. + + <p>Each element of the returned sequence is a <em>disjunctive term</em>, having exactly <member>FilterComponents</member> + elements, which denote the single <em>predicate expressions</em> of this term.</p> + */ + sequence< sequence< string > > + getPredicateExpressions(); + + /** removes a given <em>disjunctive term</em> + + @param _Term + the index of the term to remove. Must be greater than or equal to 0, and smaller than + <member>DisjunctiveTerms</member>. + + @throws ::com::sun::star::lang::IndexOutOfBoundsException + if <arg>_Term</arg> is out of the allowed range. + */ + void + removeDisjunctiveTerm( [in] long _Term ) + raises( ::com::sun::star::lang::IndexOutOfBoundsException ); + + /** appends an empty disjunctive term to the list of terms. + */ + void + appendEmptyDisjunctiveTerm(); +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/XFilterControllerListener.idl b/offapi/com/sun/star/form/runtime/XFilterControllerListener.idl new file mode 100644 index 000000000000..c737f9b24c70 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/XFilterControllerListener.idl @@ -0,0 +1,85 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef __com_sun_star_form_runtime_XFilterControllerListener_idl__ +#define __com_sun_star_form_runtime_XFilterControllerListener_idl__ + +#include <com/sun/star/lang/XEventListener.idl> +#include <com/sun/star/form/runtime/FilterEvent.idl> + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +/** is implemented by components listening for events fired by an <type>XFilterController</type>. + + @since OpenOffice.org 3.3 +*/ +interface XFilterControllerListener : ::com::sun::star::lang::XEventListener +{ + /** is fired when a single <em>predicate expression</em> of the filter represented by the filter + controller changed. + + <p><member>FilterEvent::DisjunctiveTerm</member> is the index of the <em>disjunctive term</em> in which the + expression changed. This usually equals <member>XFilterController::ActiveTerm</member>.</p> + + <p><member>FilterEvent::FilterComponent</member> denotes the index of the filter component whose + <em>predicate expression</em> changed.</p> + + <p><member>FilterEvent::PredicateExpression</member> is the new <em>predicate expressions</em>.</p> + */ + void predicateExpressionChanged( [in] FilterEvent _Event ); + + /** is fired when a <em>disjunctive term</em> was removed from the filter of the filter controller. + + <p><member>FilterEvent::DisjunctiveTerm</member> is the index of the <em>disjunctive term</em> which was + removed.</p> + + <p><member>FilterEvent::FilterComponent</member> and <member>FilterEvent::PredicateExpression</member> are not + used for this event type.</p> + */ + void disjunctiveTermRemoved( [in] FilterEvent _Event ); + + /** is fired when a <em>disjunctive term</em> was added to the filter of the filter controller. + + <p><member>FilterEvent::DisjunctiveTerm</member> is the index of the <em>disjunctive term</em> which was + added.</p> + + <p><member>FilterEvent::FilterComponent</member> and <member>FilterEvent::PredicateExpression</member> are not + used for this event type.</p> + */ + void disjunctiveTermAdded( [in] FilterEvent _Event ); +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/XFormController.idl b/offapi/com/sun/star/form/runtime/XFormController.idl new file mode 100644 index 000000000000..983b0bd61f07 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/XFormController.idl @@ -0,0 +1,374 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef __offapi_com_sun_star_form_runtime_XFormController_idl__ +#define __offapi_com_sun_star_form_runtime_XFormController_idl__ + +#include <com/sun/star/awt/XTabController.idl> +#include <com/sun/star/container/XChild.idl> +#include <com/sun/star/lang/XComponent.idl> +#include <com/sun/star/container/XIndexAccess.idl> +#include <com/sun/star/container/XEnumerationAccess.idl> +#include <com/sun/star/util/XModifyBroadcaster.idl> +#include <com/sun/star/util/XModeSelector.idl> +#include <com/sun/star/form/XConfirmDeleteBroadcaster.idl> +#include <com/sun/star/sdb/XSQLErrorBroadcaster.idl> +#include <com/sun/star/sdb/XRowSetApproveBroadcaster.idl> +#include <com/sun/star/form/XDatabaseParameterBroadcaster2.idl> +#include <com/sun/star/form/XFormControllerListener.idl> +#include <com/sun/star/task/XInteractionHandler.idl> +#include <com/sun/star/lang/IllegalArgumentException.idl> +#include <com/sun/star/form/runtime/XFilterController.idl> + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +interface XFormOperations; +interface XFormControllerContext; + +//============================================================================= + +/** specifies a component controlling the interaction between the user and form functionality. + + <p>As soon as a form (containing controls) is to be presented to the user, + there is a need for an instance controlling the user interaction.<br/> + Such a <code>FormController</code> is responsible for dialog processing, + like controlling the tab order and the grouping of controls.</p> + + <p>As a form may contain one or many subforms, a <type>FormController</type> may + contain one or more other <type>FormController</type>s, so the form model structure or hierarchy + is reflected in the structure of <type>FormController</type>s. That is, retrieving the parent of + the model of a controller will give you the same object as retrieving the model of the parent of + the controller. Similarly, retrieving the model of the <code>n</code><sup>th</sup> child of + a controller gives you the same object as retrieving the <code>n</code><sup>th</sup> child of + the model of the controller.</p> + + <p>A controller is called <em>active</em> if one of the controls it is responsible for has the focus, + else inactive. To be notified whenever this activation state of a given controller changes, you can + add listeners.</p> + + <p>This interface supersedes the <type scope="com::sun::star::form">FormController</type>.</p> + + <h3>Responsibilities</h3> + <p>A <type>FormController</type> is responsible for a <type scope="com::sun::star::awt">UnoControlContainer</type>, + and all controls therein.</p> + + <p>Furthermore, a form controller is responsible for preventing invalid user input. That is, if the form + contains controls bound to a database, or to an external validator, then the form controller will + check their current value when the current record is to be saved to the database.</p> + + <p>First, it will check whether any controls with an external validator exist. If so, those validators + will be asked to validate the current control content. If this fails, the message provided by the validator + is displayed to the user, the control is focused, and the update of the record is vetoed.</p> + + <p>Second, the controls are examined for NULL values. If a control is bound to a database field which + is declared to be <code>NOT NULL</code>, no auto-increment field, but still <NULL/>, then an error + message is shown to the user saying that input is required, the respective control is focused, and + the update of the record is vetoed.</p> + + <p>Note that you can precent the second check - for database fields containing <NULL/> values - on + a per-form and a per-database basis.<br/> + For the former, you need to add a boolean property <code>FormsCheckRequiredFields</code> to the form + (aka the <code>FormController</code>'s model), using its + <member scope="com::sun::star::beans">XPropertyContainer::addProperty</member> method, with a value + of <FALSE/>.<br/> + For the latter, you need to set the respective property of the data source's <code>Settings</code> + (also named <code>FormsCheckRequiredFields</code>) to <FALSE/>.</p> + + <p>Alternatively, you can prevent the check on a per-control basis, using the + <member>DataAwareControlModel::InputRequired</member> property of a single control model.</p> + + <p>If a control which the controller is responsible for supports the <type scope="com::sun::star::frame">XDispatchProviderInterception</type> + interface, the controller registers a dispatch interceptor. Then, the control can try to delegate part of its + functionality to the controller by querying the dispatch interceptor for it.</p> + + <p>Below, there's a list of URLs which have a defined meaning - if an implementation supports one of them, + there must be a guaranteed semantices. However, concrete implementations may support an arbitrary sub or super + set of these URLs.</p> + + <p>In general, all URLs start with the same prefix, namely <em>.uno:FormController/</em>. To this, a suffix is + appended which describes the requested functionality.<br/> + Example: The URL suffix for deleting the current record is <em>deleteRecord</em>, so the complete URL for + requesting a dispatcher for this functionality is <em>.uno:FormController/deleteRecord</em>.</p> + + <p>Some URLs may require parameters. For this, the sequence of <type scope="com::sun::star::beans">PropertyValue</type>s + passed to the <member scope="com::sun::star::frame">XDispatch::dispatch</member> call is used - every property value is + used as one named parameter.</p> + + <p>For all URLs, interested parties can register as status listeners (<type scope="com::sun::star::frame">XStatusListener</type>) + at the dispatchers, and be notified whenever the functionality associated with the URL becomes enabled or + disabled.<br/> + For instance, the URL with the suffix <em>moveToFirst</em> is associated with moving the form to the first + record, and it will be disabled in case the form is already positioned on the first record.</p> + + <table style="width:100%;" border="0" cellpadding="2" cellspacing="2"><tbody> + + <tr style="vertical-align: top;"> + <td><b>URL suffix</b></td> + <td><b>functionality</b></td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>positionForm</em></td> + <td>positions the form on a record given by absolute number.<br/> + There's one parameter for this functionality, named <em>Position</em>, which must be a long + value specifying the absolute position to which the form should be moved</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>RecordCount</em></td> + <td>This is a passive functionality: It cannot be dispatched, instead, interested parties may + use the dispatcher to add as <type scope="com::sun::star::frame">XStatusListener</type>, and be + notified when the record count changes.<br/> + The status value which is being notified (<member scope="com::sun::star::frame">FeatureStateEvent::State</member>) + is a string which can be used to display the record count. In particular, if the record count is not yet known + (<member scope="com::sun::star::sdb">RowSet::IsRowCountFinal</member> is <FALSE/>), this is indicated in the + string, too.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>moveToFirst</em></td> + <td>moves the form to the first record</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>moveToPrev</em></td> + <td>moves the form to the record preceding the current one</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>moveToNext</em></td> + <td>moves the form to the record after the current one</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>moveToLast</em></td> + <td>moves the form to the last record</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>moveToNew</em></td> + <td>moves the form to the virtual "insert row", where new records can be inserted</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>saveRecord</em></td> + <td>Commits any potentially pending changes in the current control, and saves the current record to + the database, or inserts a new record if the form is currently positioned on the virtual insertion row.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>undoRecord</em></td> + <td>reverts the changes done to the current record. Basically, this means refreshing the + current row from the database, and updating all controls with the new content.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>deleteRecord</em></td> + <td>deletes the current record, after asking the user for confirmation.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>refreshForm</em></td> + <td>reloads the complete form. After this, the form is positioned on the first record</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>sortUp</em></td> + <td>Adds an order clause to the form, to sort it ascending by the field which the current control is bound to, + and then reloads the form.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>sortDown</em></td> + <td>Adds an order clause to the form, to sort it descending by the field which the current control is bound to, + and then reloads the form.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>sort</em></td> + <td>opens an dialog, which allows the user to manipulate the current sorting order of the form. If the dialog + is closed with OK, the form is reloaded after setting the new sorting order.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>autoFilter</em></td> + <td>creates, from the current control, a filter for the form. This is, if the current control is bound to + the field, say, "customer", and contains the value "Furs, Inc.", then a filter "customer = 'Furs, Inc.'" + is created and set at the form. After this, the form is reloaded.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>filter</em></td> + <td>opens an dialog, which allows the user to manipulate the current filter of the form. If the dialog + is closed with OK, the form is reloaded after setting the new filter.</td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>applyFilter</em></td> + <td><p>Toggles the <member scope="com::sun::star::sdb">RowSet::ApplyFilter</member> property + of the form.</p> + <p>Additionally, status listeners will be provided with the current (boolean) state of this property + in the <member scope="com::sun::star::frame">FeatureStateEvent::State</member> member of the event + notified by the dispatcher.</p></td> + </tr> + + <tr style="vertical-align: top;"> + <td><em>removeFilterOrder</em></td> + <td>completely removes any filter and sorting order from the form, and reloads it.</td> + </tr> + + </tbody></table> + + @see ::com::sun::star::form::component:Form + @see ::com::sun::star::form::binding::BindableControlModel + @see ::com::sun::star::sdb::DataSource::Settings + + @since OpenOffice.org 3.3 + */ +interface XFormController +{ + /** is used for tab controlling and grouping of the controls. + + <p>The model obtained via <member scope="com::sun::star::awt">XTabController::getModel</member> is the form for which the + controller is responsible.</p> + */ + interface ::com::sun::star::awt::XTabController; + + /** allows access to the parent controller. + */ + interface ::com::sun::star::container::XChild; + + /** allows access to the sub controllers. + */ + interface ::com::sun::star::container::XIndexAccess; + + /** allows enumerating sub controllers + */ + interface ::com::sun::star::container::XEnumerationAccess; + + /** allows life time control of the controller. + */ + interface ::com::sun::star::lang::XComponent; + + /** allows to register as listener for modifications in the controls which the controller is responsible + for. + */ + interface ::com::sun::star::util::XModifyBroadcaster; + + /** used to notify deletions of data in the form before they happen. + + <p>A form controller listens for deletion events at the form it is responsible for. If and only if no + <type scope="com::sun::star::form">XConfirmDeleteListener</type> is registered at + the controller, it uses an own dialog to ask the user for confirmation.</p> + */ + interface ::com::sun::star::form::XConfirmDeleteBroadcaster; + + /** is used to notify errors which happen in the form the controller is responsible for. + + <p>A form controller listens for error events at the form it is responsible for. If and only if no + <type scope="com::sun::star::sdb">XSQLErrorListener</type> is registered at the controller, it + uses an own dialog to notify the user of the error.</p> + + */ + interface ::com::sun::star::sdb::XSQLErrorBroadcaster; + + /** is used for multiplexing row set events happening on the form which the controller is responsible for. + */ + interface ::com::sun::star::sdb::XRowSetApproveBroadcaster; + + /** is used broadcasting parameter events in the form. + + <p>A form controller listens for parameter events at the form it is responsible for. If and only if no + <type scope="com::sun::star::form">XDatabaseParameterListener</type> is registered at the controller, it + uses an own dialog to ask the user for parameter values.</p> + */ + interface ::com::sun::star::form::XDatabaseParameterBroadcaster2; + + /** allows switching the form controller to different operation modes. + + <a name="mode_selector"></a> + <p>The two modes usually (but not necessarily) supported by a form controller are the <code>DataMode</code> + and the <code>FilterMode</code>, where the former is the usual modus operandi for displaying and modifying + data, and the latter is a special mode to enter a filter for the database form which the controller is + responsible for.</p> + */ + interface ::com::sun::star::util::XModeSelector; + + /** allows controlling the filter mode. + + <p>If the form controller supports a <a href="#mode_selector">form based filter mode</a>, then it shall also + support the <type>XFilterController</type> interface, which allows controlling this mode.</p> + */ + [optional] interface XFilterController; + + /** denotes the instance which is used to implement operations on the form which the controller + works for. + + <p>This instance can be used, for instance, to determine the current state of certain form features.</p> + */ + [attribute, readonly] XFormOperations FormOperations; + + /** provicdes access to the currently active control + */ + [attribute, readonly] ::com::sun::star::awt::XControl CurrentControl; + + /** allows to delegate certain tasks to the context of the form controller + */ + [attribute] XFormControllerContext Context; + + /** used (if not <NULL/>) for user interactions triggered by the form controller. + */ + [attribute] ::com::sun::star::task::XInteractionHandler InteractionHandler; + + /** adds the specified listener to receive notifications whenever the activation state of + the controller changes. + */ + void addActivateListener( [in] ::com::sun::star::form::XFormControllerListener _Listener ); + + /** removes the specified listener from the list of components to receive notifications whenever the activation + state of the controller changes. + */ + void removeActivateListener( [in] ::com::sun::star::form::XFormControllerListener _Listener ); + + /** adds a controller to the list of child controllers + @throws ::com::sun::star::lang::IllegalArgumentException + if the given controller is <NULL/>, or cannot rightfully be a child controller. Since controllers + mirror the hierarchy of the forms the are responsible for, this means that the form of the given + child controller must be a child of the controller at which the method is invoked. + */ + void addChildController( [in] XFormController _ChildController ) + raises ( ::com::sun::star::lang::IllegalArgumentException ); +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/XFormControllerContext.idl b/offapi/com/sun/star/form/runtime/XFormControllerContext.idl new file mode 100644 index 000000000000..434faba18288 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/XFormControllerContext.idl @@ -0,0 +1,58 @@ +/************************************************************************* + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * +************************************************************************/ + +#ifndef __offapi_com_sun_star_form_runtime_XFormControllerContext_idl__ +#define __offapi_com_sun_star_form_runtime_XFormControllerContext_idl__ + +#include <com/sun/star/awt/XControl.idl> + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +//============================================================================= + +/** provides a context for a <type>FormController</type> + +<p>A <type>FormController</type> knows about the controls it is responsible + for, and about the control container which those controls live in. However, it doesn't know + about a possible larger context, like a scrollable view which the controls are embedded into. + To compensate this, it can be provided a <code>XFormControllerContext</code>.</p> + */ +interface XFormControllerContext +{ + /** ensures the given control is visible, by scrolling the view if necessary. + */ + void makeVisible( [in] ::com::sun::star::awt::XControl _Control ); +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/XFormOperations.idl b/offapi/com/sun/star/form/runtime/XFormOperations.idl new file mode 100644 index 000000000000..f6f040ccc199 --- /dev/null +++ b/offapi/com/sun/star/form/runtime/XFormOperations.idl @@ -0,0 +1,284 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_runtime_XFormOperations_idl__ +#define __com_sun_star_form_runtime_XFormOperations_idl__ + +#ifndef __com_sun_star_form_runtime_FeatureState_idl__ +#include <com/sun/star/form/runtime/FeatureState.idl> +#endif + +#ifndef __com_sun_star_lang_XComponent_idl__ +#include <com/sun/star/lang/XComponent.idl> +#endif +#ifndef __com_sun_star_sdbc_XRowSet_idl__ +#include <com/sun/star/sdbc/XRowSet.idl> +#endif +#ifndef __com_sun_star_sdbc_XResultSetUpdate_idl__ +#include <com/sun/star/sdbc/XResultSetUpdate.idl> +#endif +#ifndef __com_sun_star_form_runtime_XFormController_idl__ +#include <com/sun/star/form/runtime/XFormController.idl> +#endif +#ifndef __com_sun_star_lang_IllegalArgumentException_idl__ +#include <com/sun/star/lang/IllegalArgumentException.idl> +#endif +#ifndef __com_sun_star_lang_WrappedTargetException_idl__ +#include <com/sun/star/lang/WrappedTargetException.idl> +#endif +#ifndef __com_sun_star_beans_NamedValue_idl__ +#include <com/sun/star/beans/NamedValue.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module runtime { + +interface XFeatureInvalidation; + +//============================================================================= + +/** encapsulates operations on a database form. + + <p>This instance allows for operations on a user interface form, by saving its clients + from various tedious and error-prone operations.</p> + + <p>As an example, imagine you have a database form, displayed in some user + interface, which you want to move to the next record.<br/> + It is as easy as calling <member scope="com:::sun::star::sdbc">XResultSet::next</member> + on this form, right? Wrong. First, you need to care for saving the current + record, so the user doesn't lose her input. So you need to call + <member scope="com::sun::star::sdbc">XResultSetUpdate::updateRow</member> or + <member scope="com::sun::star::sdbc">XResultSetUpdate::insertRow</member>, depending + on the form's <member scope="com::sun::star::sdb">RowSet::IsNew</member> property.<br/> + But then you're done, right? Wrong, again.<br/> + When the user just entered some data into one of the form fields, but did not yet + leave this field, then the data is not yet committed to the form, not to talk + about being committed to the underlying database. So, before everything else, + you would nee to obtain the active control of the form, and commit it.<br/> + <em>Now</em> you're done ...</p> + + <p>As another example, consider that you want to delete the current record from the + form. You have to take into account any <type scope="com::sun::star::form">XConfirmDeleteListener</type>s + registered at the <type scope="com::sun::star::form">FormController</type> or the + <type scope="com::sun::star::form::component">DataForm</type>.</p> + + <p>If you agree that this is ugly to do and maintain, then <code>XFormOperations</code> + is for you. It provides a <member>execute</member> method, which will do all of the above + for you; plus some similar convenient wrappers for similar functionality.</p> + + @see FormFeature + + @since OpenOffice.org 2.2.0 + */ +interface XFormOperations : ::com::sun::star::lang::XComponent +{ + /** provides access to the cursor of the form the instance is operating on. + */ + [attribute, readonly] ::com::sun::star::sdbc::XRowSet Cursor; + + /** provides access to the update cursor of the form the instance is operating on. + */ + [attribute, readonly] ::com::sun::star::sdbc::XResultSetUpdate UpdateCursor; + + /** provides access to the form controller which the instance is operating on. + + <p>Note that it is possible to operate on a user interface form without + actually having access to the form controller instance. However, in this + case some functionality will not be available. In particular, every feature + which relies on the active control of the controller might be of limited use.</p> + */ + [attribute, readonly] ::com::sun::star::form::runtime::XFormController Controller; + + /** retrieves the current state of the given feature + + <p>You would usually use this to update some user interface to reflect this state. + For instance, you could imagine a toolbar button which is associated with a given feature. + This button would be enabled if and only if the respective feature is currently + available, and be checked if and only if the feature state is a <code>boolean</code> + evaluating to <TRUE/>.<p> + + @param Feature + the feature whose state is to be determimed. Must be one of the <type>FormFeature</type> + constants.<br/> + An invalid value here will be silently ignored, and simply return a <type>FeatureState</type> + indicating <em>disabled</em> with a <NULL/> state.</p> + */ + FeatureState getState( + [in] short Feature + ); + + /** determines whether a feature is currently enabled. + + <p>Calling this is equivalent to calling <member>getState</member>, and evaluating the + <member>FeatureState::Enabled</member> member.</p> + + @param Feature + the feature whose state is to be determimed. Must be one of the <type>FormFeature</type> + constants.<br/> + An invalid value here will be silently ignored, and simply return <FALSE/>. + */ + boolean isEnabled( + [in] short Feature + ); + + /** executes the operation associated with the given feature + + @param Feature + the feature which is to be executed. Must be one of the <type>FormFeature</type> + constants. + + @throws ::com::sun::star::lang::IllegalArgumentException + if the given Feature is unknown, not executable, or striclty requires arguments + to be executed. + + @throws ::com::sun::star::sdbc::SQLException + if a database access erorr occurs + + @throws ::com::sun::star::lang::WrappedTargetException + if an exception is caught which is no <type scope="com::sun::star::uno">RuntimeException</type> + and no <type scope="com::sun::star::sdbc">SQLException</type>. + + @see executeWithArguments + */ + void execute( + [in] short Feature + ) + raises ( ::com::sun::star::lang::IllegalArgumentException + , ::com::sun::star::sdbc::SQLException + , ::com::sun::star::lang::WrappedTargetException + ); + + /** executes the operation associated with the given feature, with passing arguments for execution + + @param Feature + the feature which is to be executed. Must be one of the <type>FormFeature</type> + constants. + + @param Arguments + the named arguments for the feature to execute. See the <type>FormFeature</type> list + for features which require arguments. + + @throws ::com::sun::star::lang::IllegalArgumentException + if the given feature is unknown, or not executable + + @throws ::com::sun::star::lang::IllegalArgumentException + if the given arguments are not sufficient to execute the feature + + @throws ::com::sun::star::sdbc::SQLException + if a database access erorr occurs + + @throws ::com::sun::star::lang::WrappedTargetException + if an exception is caught which is no <type scope="com::sun::star::uno">RuntimeException</type> + and no <type scope="com::sun::star::sdbc">SQLException</type>. + */ + void executeWithArguments( + [in] short Feature, + [in] sequence< ::com::sun::star::beans::NamedValue > Arguments + ) + raises ( ::com::sun::star::lang::IllegalArgumentException + , ::com::sun::star::sdbc::SQLException + , ::com::sun::star::lang::WrappedTargetException + ); + + /** commits the current record of the form + + @param RecordInserted + will be <TRUE/> if a record has been inserted, i.e. the form was positioned + on the insertion row. + + @return + <TRUE/> if and only if the current record needed being committed. That's the + case if the record or the active control of the form were modified. + + @throws ::com::sun::star::sdbc::SQLException + if a database access erorr occurs + */ + boolean commitCurrentRecord( + [out] boolean RecordInserted + ) + raises ( ::com::sun::star::sdbc::SQLException ); + + /** commits the current control of our controller + + @throws ::com::sun::star::sdbc::SQLException + if a database access erorr occurs + */ + boolean commitCurrentControl( + ) + raises ( ::com::sun::star::sdbc::SQLException ); + + /** determines whether the form is currently positioned on the insertion row + + <p>This is a convenience method only. Calling it es equivalent to examing the + <member scope="com::sun::star::sdb">RowSet::IsNew</member> property of the form.</p> + + @throws ::com::sun::star::lang::WrappedTargetException + if an error occurs obtaining the form property + */ + boolean isInsertionRow( + ) + raises ( ::com::sun::star::lang::WrappedTargetException ); + + /** determines whether the current row of the form is modified + + <p>This is a convenience method only. Calling it es equivalent to examing the + <member scope="com::sun::star::sdb">RowSet::IsModified</member> property of the form.</p> + + @throws ::com::sun::star::lang::WrappedTargetException + if an error occurs obtaining the form property + */ + boolean isModifiedRow( + ) + raises ( ::com::sun::star::lang::WrappedTargetException ); + + /** denotes the instance which should be notified about features whose state might have changed. + + <p>If this attribute is not <NULL/>, the instance which it denotes will be notified + whenever the state of any supported feature might have changed.</p> + + <p>For instance, imagine a form whose current row has just been moved to another + record, using the <member>execute</member> method. This means that potentially, the state + of all movement-related features might have changed.</p> + + <p>Note that the instance does not actually notify changes in the feature states, but only + <em>potential</em> changes: It's up to the callee to react on this appropriately. This is + since OpenOffice.org's application framework features own mechanisms to cache and invalidate + feature states, so we do not burden this implementation here with such mechanisms.</p> + + @see FormFeature + */ + [attribute] XFeatureInvalidation FeatureInvalidation; +}; + +//============================================================================= + +}; }; }; }; }; + +//============================================================================= + +#endif diff --git a/offapi/com/sun/star/form/runtime/makefile.mk b/offapi/com/sun/star/form/runtime/makefile.mk new file mode 100644 index 000000000000..4b34b28cae9a --- /dev/null +++ b/offapi/com/sun/star/form/runtime/makefile.mk @@ -0,0 +1,56 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/..$/..$/.. + +PRJNAME=offapi + +TARGET=cssfrunt +PACKAGE=com$/sun$/star$/form$/runtime + +# --- Settings ----------------------------------------------------- +.INCLUDE : $(PRJ)$/util$/makefile.pmk + +# ------------------------------------------------------------------------ + +IDLFILES=\ + FeatureState.idl \ + FilterEvent.idl \ + FormFeature.idl \ + FormOperations.idl \ + FormController.idl \ + XFeatureInvalidation.idl \ + XFilterController.idl \ + XFilterControllerListener.idl \ + XFormController.idl \ + XFormControllerContext.idl \ + XFormOperations.idl \ + +# ------------------------------------------------------------------ + +.INCLUDE : target.mk +.INCLUDE : $(PRJ)$/util$/target.pmk diff --git a/offapi/com/sun/star/form/submission/XSubmission.idl b/offapi/com/sun/star/form/submission/XSubmission.idl new file mode 100644 index 000000000000..7eacf7f13935 --- /dev/null +++ b/offapi/com/sun/star/form/submission/XSubmission.idl @@ -0,0 +1,114 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_submission_XSubmission_idl__ +#define __com_sun_star_form_submission_XSubmission_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif +#ifndef __com_sun_star_util_VetoException_idl__ +#include <com/sun/star/util/VetoException.idl> +#endif +#ifndef __com_sun_star_lang_WrappedTargetException_idl__ +#include <com/sun/star/lang/WrappedTargetException.idl> +#endif +#ifndef __com_sun_star_lang_NoSupportException_idl__ +#include <com/sun/star/lang/NoSupportException.idl> +#endif +#ifndef __com_sun_star_task_XInteractionHandler_idl__ +#include <com/sun/star/task/XInteractionHandler.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module submission { + +interface XSubmissionVetoListener; + +//============================================================================= + +/** is implemented by components which support submitting data. +*/ +interface XSubmission : com::sun::star::uno::XInterface +{ + /** tells the component to submit data + + @throws com::sun::star::util::VetoException + if the submission has been vetoed. Usually, this indicates that not all + requirements for the submission, e.g. data consistency, are fulfilled. + + @throws com::sun::star::lang::WrappedTargetException + if an error occured during invoking the submission target + */ + void submit( ) + raises ( com::sun::star::util::VetoException, com::sun::star::lang::WrappedTargetException ); + + /** tells the component to submit data + + @param aHandler + This handler allows additional user interaction, which may be necessary before + the submission can be performed. + + @throws com::sun::star::util::VetoException + if the submission has been vetoed. Usually, this indicates that not all + requirements for the submission, e.g. data consistency, are fulfilled. + + @throws com::sun::star::lang::WrappedTargetException + if an error occured during invoking the submission target + */ + void submitWithInteraction( [in] com::sun::star::task::XInteractionHandler aHandler ) + raises ( com::sun::star::util::VetoException, com::sun::star::lang::WrappedTargetException ); + + /** registers the given listener to be notified when a submission occurs + + @param listener + the listener to register + + @throws com::sun::star::lang::NoSupportException + when the component does not support external componentsw vetoing the submission + */ + void addSubmissionVetoListener( [in] XSubmissionVetoListener listener ) + raises ( com::sun::star::lang::NoSupportException ); + + /** revokes a listener which has previously been registered to be notified when a submission occurs + + @param listener + the listener to revoke + + @throws com::sun::star::lang::NoSupportException + when the component does not support external componentsw vetoing the submission + */ + void removeSubmissionVetoListener( [in] XSubmissionVetoListener listener ) + raises ( com::sun::star::lang::NoSupportException ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/submission/XSubmissionSupplier.idl b/offapi/com/sun/star/form/submission/XSubmissionSupplier.idl new file mode 100644 index 000000000000..8132bfcdf1ac --- /dev/null +++ b/offapi/com/sun/star/form/submission/XSubmissionSupplier.idl @@ -0,0 +1,60 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_submission_XSubmissionSupplier_idl__ +#define __com_sun_star_form_submission_XSubmissionSupplier_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module submission { + +interface XSubmission; + +//============================================================================= + +/** is implemented by a component which allows access to a component which can + submit data. + + @see XSubmission +*/ +interface XSubmissionSupplier : com::sun::star::uno::XInterface +{ + /** specifies the <type>XSubmission</type> instance to which the submission + request should be delegated. + */ + [attribute] XSubmission Submission; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/submission/XSubmissionVetoListener.idl b/offapi/com/sun/star/form/submission/XSubmissionVetoListener.idl new file mode 100644 index 000000000000..0c9f32f5fa91 --- /dev/null +++ b/offapi/com/sun/star/form/submission/XSubmissionVetoListener.idl @@ -0,0 +1,71 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_submission_XSubmissionVetoListener_idl__ +#define __com_sun_star_form_submission_XSubmissionVetoListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif +#ifndef __com_sun_star_util_VetoException_idl__ +#include <com/sun/star/util/VetoException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module submission { + +//============================================================================= + +/** is implement by components which want to observe (and probably veto) the + submission of data. + + @see XSubmission +*/ +interface XSubmissionVetoListener : com::sun::star::lang::XEventListener +{ + /** is invoked when a component, at which the listener has been registered, + is about to submit its data. + + @param event + The submission event. The <member scope="com::sun::star::lang">EventObject::Source</member> + member of the structure describes the component which is about to submit its data. + + @throws com::sun::star::util::VetoException + when the submission is vetoed. <member scope="com::sun::star::uno">Exception::Message</member> + should contain a justification for the veto then. + */ + void submitting( [in] com::sun::star::lang::EventObject event ) + raises ( com::sun::star::util::VetoException ); + +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/submission/makefile.mk b/offapi/com/sun/star/form/submission/makefile.mk new file mode 100644 index 000000000000..27a60084cb29 --- /dev/null +++ b/offapi/com/sun/star/form/submission/makefile.mk @@ -0,0 +1,48 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/..$/..$/.. + +PRJNAME=offapi + +TARGET=cssfsubmission +PACKAGE=com$/sun$/star$/form$/submission + +# --- Settings ----------------------------------------------------- +.INCLUDE : $(PRJ)$/util$/makefile.pmk + +# ------------------------------------------------------------------------ + +IDLFILES=\ + XSubmission.idl \ + XSubmissionSupplier.idl \ + XSubmissionVetoListener.idl \ + +# ------------------------------------------------------------------ + +.INCLUDE : target.mk +.INCLUDE : $(PRJ)$/util$/target.pmk diff --git a/offapi/com/sun/star/form/validation/ValidatableBindableControlModel.idl b/offapi/com/sun/star/form/validation/ValidatableBindableControlModel.idl new file mode 100644 index 000000000000..9b436b605efa --- /dev/null +++ b/offapi/com/sun/star/form/validation/ValidatableBindableControlModel.idl @@ -0,0 +1,79 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_validation_ValidatableBindableControlModel_idl__ +#define __com_sun_star_form_validation_ValidatableBindableControlModel_idl__ + +#ifndef __com_sun_star_form_validation_ValidatableControlModel_idl__ +#include <com/sun/star/form/validation/ValidatableControlModel.idl> +#endif + +#ifndef __com_sun_star_form_binding_BindableControlModel_idl__ +#include <com/sun/star/form/binding/BindableControlModel.idl> +#endif +//============================================================================= + +module com { module sun { module star { module form { module validation { + +/** specifies a control model which supports both binding to an external value supplier, + and to an external validator. + + <p>There are two methods how the value which is represented by a control model + can interact with other components (well, except the trivial ones accessible + by using <type scope="com::sun::star::beans">XPropertySet</type>): + <ul><li>binding the value to an external component via <type scope="com::sun::star::form::binding">XBindableValue</type></li> + <li>validating the current value by an external component, via <type>XValidatable</type> and <type>XValidator</type></li> + </ul></p> + + <p>The <type>ValidatableBindableControlModel</type> services describes the interaction of these concepts + for control models which support both of them.</p> +*/ +service ValidatableBindableControlModel +{ + /** specifies support for validating the current value of the control + */ + service ValidatableControlModel; + + /** specifies support for binding the control value to an external component + + <p>If a value binding is established at the control model (by using + <member scope="com::sun::star::form::binding">XBindableValue::setValueBinding</member> with a non-<NULL/> + binding), this binding is analyzed for validation support. If it is present (read: if the + binding also supports the <type>XValidator</type> interface), the binding is also + established as validator, as if it has been passed to <member>XValidatable::setValidator</member>.<br/> + If, while this binding is active (in both its roles as value binding and validator), + an attempt is made to establish another validator, this is blocked with raising a + <type scope="com::sun::star::util">VetoException</type> upon calling <member>XValidatable::setValidator</member>.</p> + */ + service com::sun::star::form::binding::BindableControlModel; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/validation/ValidatableControlModel.idl b/offapi/com/sun/star/form/validation/ValidatableControlModel.idl new file mode 100644 index 000000000000..5ca51efdab1f --- /dev/null +++ b/offapi/com/sun/star/form/validation/ValidatableControlModel.idl @@ -0,0 +1,97 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_validation_ValidatableControlModel_idl__ +#define __com_sun_star_form_validation_ValidatableControlModel_idl__ + +#ifndef __com_sun_star_form_FormControlModel_idl__ +#include <com/sun/star/form/FormControlModel.idl> +#endif + +#ifndef __com_sun_star_form_validation_XValidatableFormComponent_idl__ +#include <com/sun/star/form/validation/XValidatableFormComponent.idl> +#endif + +#ifndef __com_sun_star_form_validation_XValidityConstraintListener_idl__ +#include <com/sun/star/form/validation/XValidityConstraintListener.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module validation { + +/** specifies the model of a form control which supports live validation of its + input. + + <p>Validatable control models support setting a validator with dynamic + validity constraints, and broadcasting changes in their value as well as the + validity of their value.</p> +*/ +service ValidatableControlModel +{ + /** specifies the basic functionality for a form control model + + <p>Via this service, validatable control models inherit the + <type scope="com::sun::star::util">XCloneable</type> interface.<br/> + If an validatable control model, at which a validator has been set (via + <member>XValidatable::setValidator</member>), is being cloned, then the + validator is also set at the clone. Effectively, this means that + both control model instances share the same validator instance.</p> + */ + service com::sun::star::form::FormControlModel; + + /** enables support for validating the value of the control model + + <p>Setting an retrieving the current validator of the control model is + possible via the <type>XValidatable</type> interface (which + <type>XValidatableFormComponent</type> is derived from).</p> + + <p>Easy access to the current value of the control, as well as it's validity + (relative to the active validator), is provided by the methods <member>XValidatableFormComponent::isValid</member> + and <member>XValidatableFormComponent::getCurrentValue</member>.</p> + + <p>Note that the type of the value provided by <member>XValidatableFormComponent::getCurrentValue</member> + is not specified here, but depends on the concrete control type.</p> + */ + interface XValidatableFormComponent; + + /** enables support for validators with dynamic validity constraints. + + <p>As soon as a validator is set via <member>XValidatable::setValidator</member>, the validatable + control model registers itself as listener. If the validity constraint of the validator + changes, the <type>ValidatableControlModel</type> re-validates it's current valid, and + broadcasts any resuling changes to all its <type>XFormComponentValidityListener</type>, if + necessary.</p> + */ + interface XValidityConstraintListener; +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/validation/XFormComponentValidityListener.idl b/offapi/com/sun/star/form/validation/XFormComponentValidityListener.idl new file mode 100644 index 000000000000..f28c054918b9 --- /dev/null +++ b/offapi/com/sun/star/form/validation/XFormComponentValidityListener.idl @@ -0,0 +1,63 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_validation_XFormComponentValidityListener_idl__ +#define __com_sun_star_form_validation_XFormComponentValidityListener_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module validation { + +//============================================================================= + +/** is the listener interface to be notified of changes of a <type>XValidatableFormComponent</type> +*/ +interface XFormComponentValidityListener : com::sun::star::lang::XEventListener +{ + /** called when the validity and/or the value of the form component at which the listener + is registered changed. + + @param Source + The member <member scope="com::sun::star::lang">EventObject::Source</member> + represents the <type>XValidatableFormComponent</type> whose validity, value, or text changed. + */ + void componentValidityChanged( [in] com::sun::star::lang::EventObject Source ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/validation/XValidatable.idl b/offapi/com/sun/star/form/validation/XValidatable.idl new file mode 100644 index 000000000000..aa7799dfff85 --- /dev/null +++ b/offapi/com/sun/star/form/validation/XValidatable.idl @@ -0,0 +1,77 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_validation_XValidatable_idl__ +#define __com_sun_star_form_validation_XValidatable_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_util_VetoException_idl__ +#include <com/sun/star/util/VetoException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module validation { + +interface XValidator; + +//============================================================================= + +/** specifies support for validating a component + + @see XValidator +*/ +interface XValidatable : com::sun::star::uno::XInterface +{ + /** sets an external instance which is able to validate the component + + <p>Any previously active validator will be revoked - there can be only one!</p> + + @param Validator + the new validator which is to be used by the component. May be <NULL/>, + in this case only the current validator is revoked. + + @throws <type scope="com::sun::star::util">VetoException</type> + if changing the validator is not allowed in the current component state + */ + void setValidator( [in] XValidator Validator ) + raises ( com::sun::star::util::VetoException ); + + /** retrieves the external instance which is currently used to validate the component + */ + XValidator + getValidator( ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/validation/XValidatableFormComponent.idl b/offapi/com/sun/star/form/validation/XValidatableFormComponent.idl new file mode 100644 index 000000000000..eae3a9f48518 --- /dev/null +++ b/offapi/com/sun/star/form/validation/XValidatableFormComponent.idl @@ -0,0 +1,126 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_validation_XValidatableFormComponent_idl__ +#define __com_sun_star_form_validation_XValidatableFormComponent_idl__ + +#ifndef __com_sun_star_form_validation_XValidatable_idl__ +#include <com/sun/star/form/validation/XValidatable.idl> +#endif + +#ifndef __com_sun_star_lang_NoSupportException_idl__ +#include <com/sun/star/lang/NoSupportException.idl> +#endif + +#ifndef __com_sun_star_lang_NullPointerException_idl__ +#include <com/sun/star/lang/NullPointerException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module validation { + +interface XFormComponentValidityListener; + +//============================================================================= + +/** is a convenience interface for accessing several aspects of a form component + which supports validation. + + <p>A validatable form component has two aspects which other parties might + be interested in: + <ul> + <li>The pure validity flag: Whatever the user enters in the component, this is + either valid (relative to the active validator), or invalid.</li> + <li>The current value: Even if the validity flag does not change with the user + input (e.g. because the user replaces one invalid value with another invalid + value), observers might be interested in the current value, for example to + include it in a feedback message to the user.</li> + </ul> + </p> + + <p>An <type>XValidatableFormComponent</type> allows to easily access both of these aspects.</p> + + <p>Note that all of the information provided at this interface can also obtained by other means, + but much more inconviniently.</p> + + @see XValidatable + @see XValidator +*/ +interface XValidatableFormComponent : XValidatable +{ + /** determines whether the current value of the component passed the validity test + at the validator. + + <p>Calling this is equal to calling <member>XValidator::isValid</member> with + the current value (see <member>getCurrentValue</member>) of the component, where + the validator is obtained via <member>XValidatable::getValidator</member>.</p> + + <p>If no validator has been set (<member>XValidatable::setValidator</member>), this method + returns true.</p> + */ + boolean isValid(); + + /** retrieves the current value of the component. + + <p>The type of the current value, as well as it's semantics, depend on the service + implementing this interface.</p> + + <p>Again, this is a convenience method. For example, for a <type scope="com::sun::star::form::component">FormattedField</type>, + calling this method is equivalent to retrieving the + <member scope="com::sun::star::awt">UnoControlFormattedFieldModel::EffectiveValue</member>.</p> + + <p>If no validator has been set (<member>XValidatable::setValidator</member>), the value returned + here is defined by the service implementing this interface.</p> + */ + any getCurrentValue(); + + /** registers the given listener. + + <p><type>XFormComponentValidityListener</type>s are called whenever <em>any</em> of the aspects + of the validatable form component (the validity flag, or the value) changed.</p> + + @throws <type scope="com::sun::star::lang">NullPointerException</type> + if the given listener is <NULL/> + */ + void addFormComponentValidityListener( [in] XFormComponentValidityListener Listener ) + raises( com::sun::star::lang::NullPointerException ); + + /** registers the given listener. + + @throws <type scope="com::sun::star::lang">NullPointerException</type> + if the given listener is <NULL/> + */ + void removeFormComponentValidityListener( [in] XFormComponentValidityListener Listener ) + raises( com::sun::star::lang::NullPointerException ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/validation/XValidator.idl b/offapi/com/sun/star/form/validation/XValidator.idl new file mode 100644 index 000000000000..03753ef90fbb --- /dev/null +++ b/offapi/com/sun/star/form/validation/XValidator.idl @@ -0,0 +1,107 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_validation_XValidator_idl__ +#define __com_sun_star_form_validation_XValidator_idl__ + +#ifndef __com_sun_star_uno_XInterface_idl__ +#include <com/sun/star/uno/XInterface.idl> +#endif + +#ifndef __com_sun_star_lang_NullPointerException_idl__ +#include <com/sun/star/lang/NullPointerException.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module validation { + +interface XValidityConstraintListener; + +//============================================================================= + +/** specifies a component able to validate (the content of) other components + + <p>Validators support simple validity checks and retrieving justifications for + invalidity.</p> + + <p>Validators may additionally support dynamic validity constraints. In such a case, + the validity of a given value may change, without the value changing itself.<br/> + To be notified about this, interested components should register as <type>XValidityConstraintListener</type>. + + @see XValidatable +*/ +interface XValidator : com::sun::star::uno::XInterface +{ + /** determines whether the given value is valid + + @param aValue + the value to check for validity + @return + <TRUE/> if and only if the value is considered valid. + */ + boolean isValid( [in] any Value ); + + /** retrieves a justification for the invalidity of the given value + + @param aValue + the value which has been recognized as being invalid + @return + a human-readable string, which explains why the given valus is considered invalid. + */ + string explainInvalid( [in] any Value ); + + /** registers the given validity listener. + + <p>Usually, an <type>XValidatable</type> instance will also add itself as validity listener, + as soon as the validator is introduced to it.</p> + + <p>Implementations which do not support dynamic validity contraints should simply ignore this + call.</p> + + @throws <type scope="com::sun::star::lang">NullPointerException</type> + if the given listener is <NULL/> + @see XValidityConstraintListener + */ + void addValidityConstraintListener( [in] XValidityConstraintListener Listener ) + raises( com::sun::star::lang::NullPointerException ); + + /** revokes the given validity listener + + @throws <type scope="com::sun::star::lang">NullPointerException</type> + if the given listener is <NULL/> + @see XValidityConstraintListener + */ + void removeValidityConstraintListener( [in] XValidityConstraintListener Listener ) + raises( com::sun::star::lang::NullPointerException ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/validation/XValidityConstraintListener.idl b/offapi/com/sun/star/form/validation/XValidityConstraintListener.idl new file mode 100644 index 000000000000..593b230f6d52 --- /dev/null +++ b/offapi/com/sun/star/form/validation/XValidityConstraintListener.idl @@ -0,0 +1,60 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef __com_sun_star_form_validation_XValidityConstraintListener_idl__ +#define __com_sun_star_form_validation_XValidityConstraintListener_idl__ + +#ifndef __com_sun_star_lang_XEventListener_idl__ +#include <com/sun/star/lang/XEventListener.idl> +#endif + +//============================================================================= + +module com { module sun { module star { module form { module validation { + +//============================================================================= + +/** specifies an interface for listening for changes in the validity constraints + represented by an <type>XValidator</type>. +*/ +interface XValidityConstraintListener : com::sun::star::lang::XEventListener +{ + /** called when the validity constraint represented by an <type>XValidator</type>, + at which the listener is registered, changed. + + @param Source + The event source. The member <member scope="com::sun::star::lang">EventObject::Source</member> + represents the validator component whose validity constraint changed. + */ + void validityConstraintChanged( [in] com::sun::star::lang::EventObject Source ); +}; + +//============================================================================= + +}; }; }; }; }; + +#endif diff --git a/offapi/com/sun/star/form/validation/makefile.mk b/offapi/com/sun/star/form/validation/makefile.mk new file mode 100644 index 000000000000..752438c94f2c --- /dev/null +++ b/offapi/com/sun/star/form/validation/makefile.mk @@ -0,0 +1,53 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/..$/..$/.. + +PRJNAME=offapi + +TARGET=cssfvalidation +PACKAGE=com$/sun$/star$/form$/validation + +# --- Settings ----------------------------------------------------- +.INCLUDE : $(PRJ)$/util$/makefile.pmk + +# ------------------------------------------------------------------------ + +IDLFILES=\ + XValidatable.idl \ + XValidator.idl \ + XValidityConstraintListener.idl \ + XValidatableFormComponent.idl \ + XFormComponentValidityListener.idl \ + \ + ValidatableControlModel.idl \ + ValidatableBindableControlModel.idl \ + +# ------------------------------------------------------------------ + +.INCLUDE : target.mk +.INCLUDE : $(PRJ)$/util$/target.pmk |