1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23#ifndef __com_sun_star_report_XImageControl_idl__
24#define __com_sun_star_report_XImageControl_idl__
25
26#ifndef __com_sun_star_report_XReportControlModel_idl__
27#include <com/sun/star/report/XReportControlModel.idl>
28#endif
29#ifndef __com_sun_star_form_XImageProducerSupplier_idl__
30#include <com/sun/star/form/XImageProducerSupplier.idl>
31#endif
32
33//=============================================================================
34
35 module com {  module sun {  module star {  module report {
36
37//=============================================================================
38published interface XImageControl
39{
40    interface XReportControlModel;
41
42    /** supplies the caller with an <type scope="com::sun::star::awt">XImageProducer</type>.
43
44        <p>Other components can register as <type scope="com::sun::star::awt">XImageConsumer</type>
45        at this producer. Then they will be notified of any change in the image to be displayed.</p>
46
47        <p>Whenever the <member scope="com::sun::star::awt">UnoControlImageControlModel::ImageURL</member>
48        property is changed, the model loads the specified image, and sets it as image source
49        at its <type scope="com::sun::star::awt">XImageProducer</type>. Then, all
50        <type scope="com::sun::star::awt">XImageConsumer</type>s are notified and supplied with
51        the binary data of the image.<br/>
52        Usually, controls acting for an <type>ImageControl</type> model are consumers, and use the
53        data stream to display the image</p>
54     */
55    interface com::sun::star::form::XImageProducerSupplier;
56
57    /** specifies an URL to an image to use for the control.
58     */
59    [attribute,bound] string ImageURL;
60
61    /** defines how to scale the image
62
63        <p>If this property is present, it supersedes the <member>ScaleImage</member> property.</p>
64
65        <p>The value of this property is one of the <type scope="com::sun::star::awt">ImageScaleMode</type> constants.</p>
66
67        @since OpenOffice 3.2
68    */
69    [attribute,bound] short ScaleMode
70    {
71        set raises (com::sun::star::lang::IllegalArgumentException);
72    };
73
74    /** Specifies that the IRI given in the data field should be preserved, otherwise the content will be inserted in the resulting report document.
75        If the data field contains something different as string then this attribute will be ignored.
76    */
77    [attribute,bound] boolean PreserveIRI;
78};
79
80published service ImageControl : XImageControl;
81//=============================================================================
82
83}; }; }; };
84
85/*=============================================================================
86
87=============================================================================*/
88#endif
89