xref: /trunk/main/reportdesign/source/core/api/FixedText.cxx (revision cf6516809c57e1bb0a940545cca99cdad54d4ce2)
19e0e4191SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
39e0e4191SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
49e0e4191SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
59e0e4191SAndrew Rist  * distributed with this work for additional information
69e0e4191SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
79e0e4191SAndrew Rist  * to you under the Apache License, Version 2.0 (the
89e0e4191SAndrew Rist  * "License"); you may not use this file except in compliance
99e0e4191SAndrew Rist  * with the License.  You may obtain a copy of the License at
10cdf0e10cSrcweir  *
119e0e4191SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12cdf0e10cSrcweir  *
139e0e4191SAndrew Rist  * Unless required by applicable law or agreed to in writing,
149e0e4191SAndrew Rist  * software distributed under the License is distributed on an
159e0e4191SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
169e0e4191SAndrew Rist  * KIND, either express or implied.  See the License for the
179e0e4191SAndrew Rist  * specific language governing permissions and limitations
189e0e4191SAndrew Rist  * under the License.
19cdf0e10cSrcweir  *
209e0e4191SAndrew Rist  *************************************************************/
219e0e4191SAndrew Rist 
229e0e4191SAndrew Rist 
23*b63233d8Sdamjan #include "precompiled_reportdesign.hxx"
24cdf0e10cSrcweir #include "FixedText.hxx"
25cdf0e10cSrcweir #include <com/sun/star/beans/PropertyAttribute.hpp>
26cdf0e10cSrcweir #ifndef REPORTDESIGN_SHARED_CORESTRINGS_HRC
27cdf0e10cSrcweir #include "corestrings.hrc"
28cdf0e10cSrcweir #endif
29cdf0e10cSrcweir #include <com/sun/star/beans/XPropertyState.hpp>
30cdf0e10cSrcweir #ifndef REPORTDESIGN_CORE_RESOURCE_HRC_
31cdf0e10cSrcweir #include "core_resource.hrc"
32cdf0e10cSrcweir #endif
33cdf0e10cSrcweir #include "core_resource.hxx"
34cdf0e10cSrcweir #include <comphelper/sequence.hxx>
35cdf0e10cSrcweir #include "Tools.hxx"
36cdf0e10cSrcweir #include <tools/debug.hxx>
37cdf0e10cSrcweir #include <comphelper/property.hxx>
38cdf0e10cSrcweir #include "FormatCondition.hxx"
39cdf0e10cSrcweir #include <com/sun/star/text/ParagraphVertAlign.hpp>
40cdf0e10cSrcweir #include "ReportHelperImpl.hxx"
41cdf0e10cSrcweir // =============================================================================
42cdf0e10cSrcweir namespace reportdesign
43cdf0e10cSrcweir {
44cdf0e10cSrcweir // =============================================================================
45cdf0e10cSrcweir     using namespace com::sun::star;
46cdf0e10cSrcweir     using namespace comphelper;
lcl_getFixedTextOptionals()47cdf0e10cSrcweir uno::Sequence< ::rtl::OUString > lcl_getFixedTextOptionals()
48cdf0e10cSrcweir {
49cdf0e10cSrcweir     ::rtl::OUString pProps[] = { PROPERTY_DATAFIELD,PROPERTY_MASTERFIELDS,PROPERTY_DETAILFIELDS };
50cdf0e10cSrcweir     return uno::Sequence< ::rtl::OUString >(pProps,sizeof(pProps)/sizeof(pProps[0]));
51cdf0e10cSrcweir }
DBG_NAME(rpt_OFixedText)52cdf0e10cSrcweir DBG_NAME( rpt_OFixedText )
53cdf0e10cSrcweir // -----------------------------------------------------------------------------
54cdf0e10cSrcweir OFixedText::OFixedText(uno::Reference< uno::XComponentContext > const & _xContext)
55cdf0e10cSrcweir :FixedTextBase(m_aMutex)
56cdf0e10cSrcweir ,FixedTextPropertySet(_xContext,static_cast< Implements >(IMPLEMENTS_PROPERTY_SET),lcl_getFixedTextOptionals())
57cdf0e10cSrcweir ,m_aProps(m_aMutex,static_cast< container::XContainer*>( this ),_xContext)
58cdf0e10cSrcweir {
59cdf0e10cSrcweir     DBG_CTOR( rpt_OFixedText,NULL);
60cdf0e10cSrcweir     m_aProps.aComponent.m_sName  = RPT_RESSTRING(RID_STR_FIXEDTEXT,m_aProps.aComponent.m_xContext->getServiceManager());
61cdf0e10cSrcweir     m_aProps.aComponent.m_nBorder = 0; // no border
62cdf0e10cSrcweir }
63cdf0e10cSrcweir // -----------------------------------------------------------------------------
OFixedText(uno::Reference<uno::XComponentContext> const & _xContext,const uno::Reference<lang::XMultiServiceFactory> & _xFactory,uno::Reference<drawing::XShape> & _xShape)64cdf0e10cSrcweir OFixedText::OFixedText(uno::Reference< uno::XComponentContext > const & _xContext
65cdf0e10cSrcweir                        ,const uno::Reference< lang::XMultiServiceFactory>& _xFactory
66cdf0e10cSrcweir                        ,uno::Reference< drawing::XShape >& _xShape)
67cdf0e10cSrcweir :FixedTextBase(m_aMutex)
68cdf0e10cSrcweir ,FixedTextPropertySet(_xContext,static_cast< Implements >(IMPLEMENTS_PROPERTY_SET),lcl_getFixedTextOptionals())
69cdf0e10cSrcweir ,m_aProps(m_aMutex,static_cast< container::XContainer*>( this ),_xContext)
70cdf0e10cSrcweir {
71cdf0e10cSrcweir     DBG_CTOR( rpt_OFixedText,NULL);
72cdf0e10cSrcweir     m_aProps.aComponent.m_sName  = RPT_RESSTRING(RID_STR_FIXEDTEXT,m_aProps.aComponent.m_xContext->getServiceManager());
73cdf0e10cSrcweir     m_aProps.aComponent.m_nBorder = 0; // no border
74cdf0e10cSrcweir     m_aProps.aComponent.m_xFactory = _xFactory;
75cdf0e10cSrcweir     osl_incrementInterlockedCount( &m_refCount );
76cdf0e10cSrcweir     {
77cdf0e10cSrcweir         m_aProps.aComponent.setShape(_xShape,this,m_refCount);
78cdf0e10cSrcweir     }
79cdf0e10cSrcweir     osl_decrementInterlockedCount( &m_refCount );
80cdf0e10cSrcweir }
81cdf0e10cSrcweir // -----------------------------------------------------------------------------
~OFixedText()82cdf0e10cSrcweir OFixedText::~OFixedText()
83cdf0e10cSrcweir {
84cdf0e10cSrcweir     DBG_DTOR( rpt_OFixedText,NULL);
85cdf0e10cSrcweir }
86cdf0e10cSrcweir // -----------------------------------------------------------------------------
IMPLEMENT_FORWARD_REFCOUNT(OFixedText,FixedTextBase)87cdf0e10cSrcweir IMPLEMENT_FORWARD_REFCOUNT( OFixedText, FixedTextBase )
88cdf0e10cSrcweir // --------------------------------------------------------------------------------
89cdf0e10cSrcweir uno::Any SAL_CALL OFixedText::queryInterface( const uno::Type& _rType ) throw (uno::RuntimeException)
90cdf0e10cSrcweir {
91cdf0e10cSrcweir     uno::Any aReturn = FixedTextBase::queryInterface(_rType);
92cdf0e10cSrcweir     if ( !aReturn.hasValue() )
93cdf0e10cSrcweir         aReturn = FixedTextPropertySet::queryInterface(_rType);
94cdf0e10cSrcweir     if ( !aReturn.hasValue() && OReportControlModel::isInterfaceForbidden(_rType) )
95cdf0e10cSrcweir         return aReturn;
96cdf0e10cSrcweir 
97cdf0e10cSrcweir     return aReturn.hasValue() ? aReturn : (m_aProps.aComponent.m_xProxy.is() ? m_aProps.aComponent.m_xProxy->queryAggregation(_rType) : aReturn);
98cdf0e10cSrcweir }
99cdf0e10cSrcweir 
100cdf0e10cSrcweir //IMPLEMENT_FORWARD_XINTERFACE2(OFixedText,FixedTextBase,FixedTextPropertySet)
101cdf0e10cSrcweir // -----------------------------------------------------------------------------
dispose()102cdf0e10cSrcweir void SAL_CALL OFixedText::dispose() throw(uno::RuntimeException)
103cdf0e10cSrcweir {
104cdf0e10cSrcweir     FixedTextPropertySet::dispose();
105cdf0e10cSrcweir     cppu::WeakComponentImplHelperBase::dispose();
106cdf0e10cSrcweir     uno::Reference< report::XFixedText> xHoldAlive = this;
107cdf0e10cSrcweir }
108cdf0e10cSrcweir // -----------------------------------------------------------------------------
getImplementationName_Static()109cdf0e10cSrcweir ::rtl::OUString OFixedText::getImplementationName_Static(  ) throw(uno::RuntimeException)
110cdf0e10cSrcweir {
111cdf0e10cSrcweir     return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.report.OFixedText"));
112cdf0e10cSrcweir }
113cdf0e10cSrcweir 
114cdf0e10cSrcweir //--------------------------------------------------------------------------
getImplementationName()115cdf0e10cSrcweir ::rtl::OUString SAL_CALL OFixedText::getImplementationName(  ) throw(uno::RuntimeException)
116cdf0e10cSrcweir {
117cdf0e10cSrcweir     return getImplementationName_Static();
118cdf0e10cSrcweir }
119cdf0e10cSrcweir //--------------------------------------------------------------------------
getSupportedServiceNames_Static()120cdf0e10cSrcweir uno::Sequence< ::rtl::OUString > OFixedText::getSupportedServiceNames_Static(  ) throw(uno::RuntimeException)
121cdf0e10cSrcweir {
122cdf0e10cSrcweir     uno::Sequence< ::rtl::OUString > aServices(1);//2);
123cdf0e10cSrcweir     aServices.getArray()[0] = SERVICE_FIXEDTEXT;
124cdf0e10cSrcweir     //aServices.getArray()[1] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.component.FixedText"));
125cdf0e10cSrcweir 
126cdf0e10cSrcweir     return aServices;
127cdf0e10cSrcweir }
128cdf0e10cSrcweir //------------------------------------------------------------------------------
create(uno::Reference<uno::XComponentContext> const & xContext)129cdf0e10cSrcweir uno::Reference< uno::XInterface > OFixedText::create(uno::Reference< uno::XComponentContext > const & xContext)
130cdf0e10cSrcweir {
131cdf0e10cSrcweir     return *(new OFixedText(xContext));
132cdf0e10cSrcweir }
133cdf0e10cSrcweir 
134cdf0e10cSrcweir //--------------------------------------------------------------------------
getSupportedServiceNames()135cdf0e10cSrcweir uno::Sequence< ::rtl::OUString > SAL_CALL OFixedText::getSupportedServiceNames(  ) throw(uno::RuntimeException)
136cdf0e10cSrcweir {
137cdf0e10cSrcweir     return getSupportedServiceNames_Static();
138cdf0e10cSrcweir }
139cdf0e10cSrcweir //------------------------------------------------------------------------------
supportsService(const::rtl::OUString & ServiceName)140cdf0e10cSrcweir sal_Bool SAL_CALL OFixedText::supportsService(const ::rtl::OUString& ServiceName) throw( uno::RuntimeException )
141cdf0e10cSrcweir {
142cdf0e10cSrcweir     return ::comphelper::existsValue(ServiceName,getSupportedServiceNames_Static());
143cdf0e10cSrcweir }
144cdf0e10cSrcweir // -----------------------------------------------------------------------------
145cdf0e10cSrcweir // XReportComponent
146cdf0e10cSrcweir REPORTCOMPONENT_IMPL(OFixedText,m_aProps.aComponent)
147cdf0e10cSrcweir REPORTCOMPONENT_IMPL2(OFixedText,m_aProps.aComponent)
REPORTCOMPONENT_NOMASTERDETAIL(OFixedText)148cdf0e10cSrcweir REPORTCOMPONENT_NOMASTERDETAIL(OFixedText)
149cdf0e10cSrcweir REPORTCONTROLFORMAT_IMPL(OFixedText,m_aProps.aFormatProperties)
150cdf0e10cSrcweir // -----------------------------------------------------------------------------
151cdf0e10cSrcweir uno::Reference< beans::XPropertySetInfo > SAL_CALL OFixedText::getPropertySetInfo(  ) throw(uno::RuntimeException)
152cdf0e10cSrcweir {
153cdf0e10cSrcweir     return FixedTextPropertySet::getPropertySetInfo();
154cdf0e10cSrcweir }
155cdf0e10cSrcweir // -----------------------------------------------------------------------------
setPropertyValue(const::rtl::OUString & aPropertyName,const uno::Any & aValue)156cdf0e10cSrcweir void SAL_CALL OFixedText::setPropertyValue( const ::rtl::OUString& aPropertyName, const uno::Any& aValue ) throw (beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException, lang::WrappedTargetException, uno::RuntimeException)
157cdf0e10cSrcweir {
158cdf0e10cSrcweir     FixedTextPropertySet::setPropertyValue( aPropertyName, aValue );
159cdf0e10cSrcweir }
160cdf0e10cSrcweir // -----------------------------------------------------------------------------
getPropertyValue(const::rtl::OUString & PropertyName)161cdf0e10cSrcweir uno::Any SAL_CALL OFixedText::getPropertyValue( const ::rtl::OUString& PropertyName ) throw (beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
162cdf0e10cSrcweir {
163cdf0e10cSrcweir     return FixedTextPropertySet::getPropertyValue( PropertyName);
164cdf0e10cSrcweir }
165cdf0e10cSrcweir // -----------------------------------------------------------------------------
addPropertyChangeListener(const::rtl::OUString & aPropertyName,const uno::Reference<beans::XPropertyChangeListener> & xListener)166cdf0e10cSrcweir void SAL_CALL OFixedText::addPropertyChangeListener( const ::rtl::OUString& aPropertyName, const uno::Reference< beans::XPropertyChangeListener >& xListener ) throw (beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
167cdf0e10cSrcweir {
168cdf0e10cSrcweir     FixedTextPropertySet::addPropertyChangeListener( aPropertyName, xListener );
169cdf0e10cSrcweir }
170cdf0e10cSrcweir // -----------------------------------------------------------------------------
removePropertyChangeListener(const::rtl::OUString & aPropertyName,const uno::Reference<beans::XPropertyChangeListener> & aListener)171cdf0e10cSrcweir void SAL_CALL OFixedText::removePropertyChangeListener( const ::rtl::OUString& aPropertyName, const uno::Reference< beans::XPropertyChangeListener >& aListener ) throw (beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
172cdf0e10cSrcweir {
173cdf0e10cSrcweir     FixedTextPropertySet::removePropertyChangeListener( aPropertyName, aListener );
174cdf0e10cSrcweir }
175cdf0e10cSrcweir // -----------------------------------------------------------------------------
addVetoableChangeListener(const::rtl::OUString & PropertyName,const uno::Reference<beans::XVetoableChangeListener> & aListener)176cdf0e10cSrcweir void SAL_CALL OFixedText::addVetoableChangeListener( const ::rtl::OUString& PropertyName, const uno::Reference< beans::XVetoableChangeListener >& aListener ) throw (beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
177cdf0e10cSrcweir {
178cdf0e10cSrcweir     FixedTextPropertySet::addVetoableChangeListener( PropertyName, aListener );
179cdf0e10cSrcweir }
180cdf0e10cSrcweir // -----------------------------------------------------------------------------
removeVetoableChangeListener(const::rtl::OUString & PropertyName,const uno::Reference<beans::XVetoableChangeListener> & aListener)181cdf0e10cSrcweir void SAL_CALL OFixedText::removeVetoableChangeListener( const ::rtl::OUString& PropertyName, const uno::Reference< beans::XVetoableChangeListener >& aListener ) throw (beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException)
182cdf0e10cSrcweir {
183cdf0e10cSrcweir     FixedTextPropertySet::removeVetoableChangeListener( PropertyName, aListener );
184cdf0e10cSrcweir }
185cdf0e10cSrcweir // -----------------------------------------------------------------------------
186cdf0e10cSrcweir // XReportControlModel
getDataField()187cdf0e10cSrcweir ::rtl::OUString SAL_CALL OFixedText::getDataField() throw ( beans::UnknownPropertyException, uno::RuntimeException)
188cdf0e10cSrcweir {
189cdf0e10cSrcweir     throw beans::UnknownPropertyException();
190cdf0e10cSrcweir }
191cdf0e10cSrcweir // -----------------------------------------------------------------------------
setDataField(const::rtl::OUString &)192cdf0e10cSrcweir void SAL_CALL OFixedText::setDataField( const ::rtl::OUString& /*_datafield*/ ) throw (lang::IllegalArgumentException, beans::UnknownPropertyException, uno::RuntimeException)
193cdf0e10cSrcweir {
194cdf0e10cSrcweir     throw beans::UnknownPropertyException();
195cdf0e10cSrcweir }
196cdf0e10cSrcweir // -----------------------------------------------------------------------------
197cdf0e10cSrcweir 
198cdf0e10cSrcweir // -----------------------------------------------------------------------------
getPrintWhenGroupChange()199cdf0e10cSrcweir ::sal_Bool SAL_CALL OFixedText::getPrintWhenGroupChange() throw (beans::UnknownPropertyException, uno::RuntimeException)
200cdf0e10cSrcweir {
201cdf0e10cSrcweir     ::osl::MutexGuard aGuard(m_aMutex);
202cdf0e10cSrcweir     return m_aProps.bPrintWhenGroupChange;
203cdf0e10cSrcweir }
204cdf0e10cSrcweir // -----------------------------------------------------------------------------
setPrintWhenGroupChange(::sal_Bool _printwhengroupchange)205cdf0e10cSrcweir void SAL_CALL OFixedText::setPrintWhenGroupChange( ::sal_Bool _printwhengroupchange ) throw (beans::UnknownPropertyException, uno::RuntimeException)
206cdf0e10cSrcweir {
207cdf0e10cSrcweir     set(PROPERTY_PRINTWHENGROUPCHANGE,_printwhengroupchange,m_aProps.bPrintWhenGroupChange);
208cdf0e10cSrcweir }
209cdf0e10cSrcweir // -----------------------------------------------------------------------------
getConditionalPrintExpression()210cdf0e10cSrcweir ::rtl::OUString SAL_CALL OFixedText::getConditionalPrintExpression() throw (beans::UnknownPropertyException, uno::RuntimeException)
211cdf0e10cSrcweir {
212cdf0e10cSrcweir     ::osl::MutexGuard aGuard(m_aMutex);
213cdf0e10cSrcweir     return m_aProps.aConditionalPrintExpression;
214cdf0e10cSrcweir }
215cdf0e10cSrcweir // -----------------------------------------------------------------------------
setConditionalPrintExpression(const::rtl::OUString & _conditionalprintexpression)216cdf0e10cSrcweir void SAL_CALL OFixedText::setConditionalPrintExpression( const ::rtl::OUString& _conditionalprintexpression ) throw (beans::UnknownPropertyException, uno::RuntimeException)
217cdf0e10cSrcweir {
218cdf0e10cSrcweir     set(PROPERTY_CONDITIONALPRINTEXPRESSION,_conditionalprintexpression,m_aProps.aConditionalPrintExpression);
219cdf0e10cSrcweir }
220cdf0e10cSrcweir // -----------------------------------------------------------------------------
221cdf0e10cSrcweir 
222cdf0e10cSrcweir // XCloneable
createClone()223cdf0e10cSrcweir uno::Reference< util::XCloneable > SAL_CALL OFixedText::createClone(  ) throw (uno::RuntimeException)
224cdf0e10cSrcweir {
225cdf0e10cSrcweir     uno::Reference< report::XReportComponent> xSource = this;
226cdf0e10cSrcweir     uno::Reference< report::XFixedText> xSet(cloneObject(xSource,m_aProps.aComponent.m_xFactory,SERVICE_FIXEDTEXT),uno::UNO_QUERY_THROW);
227cdf0e10cSrcweir     return xSet.get();
228cdf0e10cSrcweir }
229cdf0e10cSrcweir // -----------------------------------------------------------------------------
230cdf0e10cSrcweir 
231cdf0e10cSrcweir // XFixedText
getLabel()232cdf0e10cSrcweir ::rtl::OUString SAL_CALL OFixedText::getLabel() throw (uno::RuntimeException)
233cdf0e10cSrcweir {
234cdf0e10cSrcweir     ::osl::MutexGuard aGuard(m_aMutex);
235cdf0e10cSrcweir     return m_sLabel;
236cdf0e10cSrcweir }
237cdf0e10cSrcweir // -----------------------------------------------------------------------------
setLabel(const::rtl::OUString & _label)238cdf0e10cSrcweir void SAL_CALL OFixedText::setLabel( const ::rtl::OUString& _label ) throw (uno::RuntimeException)
239cdf0e10cSrcweir {
240cdf0e10cSrcweir     set(PROPERTY_LABEL,_label,m_sLabel);
241cdf0e10cSrcweir }
242cdf0e10cSrcweir // -----------------------------------------------------------------------------
243cdf0e10cSrcweir // XChild
getParent()244cdf0e10cSrcweir uno::Reference< uno::XInterface > SAL_CALL OFixedText::getParent(  ) throw (uno::RuntimeException)
245cdf0e10cSrcweir {
246cdf0e10cSrcweir     return OShapeHelper::getParent(this);
247cdf0e10cSrcweir }
248cdf0e10cSrcweir // -----------------------------------------------------------------------------
setParent(const uno::Reference<uno::XInterface> & Parent)249cdf0e10cSrcweir void SAL_CALL OFixedText::setParent( const uno::Reference< uno::XInterface >& Parent ) throw (lang::NoSupportException, uno::RuntimeException)
250cdf0e10cSrcweir {
251cdf0e10cSrcweir     OShapeHelper::setParent(Parent,this);
252cdf0e10cSrcweir }
253cdf0e10cSrcweir // -----------------------------------------------------------------------------
createFormatCondition()254cdf0e10cSrcweir uno::Reference< report::XFormatCondition > SAL_CALL OFixedText::createFormatCondition(  ) throw (uno::Exception, uno::RuntimeException)
255cdf0e10cSrcweir {
256cdf0e10cSrcweir     return new OFormatCondition(m_aProps.aComponent.m_xContext);
257cdf0e10cSrcweir }
258cdf0e10cSrcweir // -----------------------------------------------------------------------------
259cdf0e10cSrcweir // XContainer
addContainerListener(const uno::Reference<container::XContainerListener> & xListener)260cdf0e10cSrcweir void SAL_CALL OFixedText::addContainerListener( const uno::Reference< container::XContainerListener >& xListener ) throw (uno::RuntimeException)
261cdf0e10cSrcweir {
262cdf0e10cSrcweir     m_aProps.addContainerListener(xListener);
263cdf0e10cSrcweir }
264cdf0e10cSrcweir // -----------------------------------------------------------------------------
removeContainerListener(const uno::Reference<container::XContainerListener> & xListener)265cdf0e10cSrcweir void SAL_CALL OFixedText::removeContainerListener( const uno::Reference< container::XContainerListener >& xListener ) throw (uno::RuntimeException)
266cdf0e10cSrcweir {
267cdf0e10cSrcweir     m_aProps.removeContainerListener(xListener);
268cdf0e10cSrcweir }
269cdf0e10cSrcweir // -----------------------------------------------------------------------------
270cdf0e10cSrcweir // XElementAccess
getElementType()271cdf0e10cSrcweir uno::Type SAL_CALL OFixedText::getElementType(  ) throw (uno::RuntimeException)
272cdf0e10cSrcweir {
273cdf0e10cSrcweir     return ::getCppuType(static_cast< uno::Reference<report::XFormatCondition>*>(NULL));
274cdf0e10cSrcweir }
275cdf0e10cSrcweir // -----------------------------------------------------------------------------
hasElements()276cdf0e10cSrcweir ::sal_Bool SAL_CALL OFixedText::hasElements(  ) throw (uno::RuntimeException)
277cdf0e10cSrcweir {
278cdf0e10cSrcweir     return m_aProps.hasElements();
279cdf0e10cSrcweir }
280cdf0e10cSrcweir // -----------------------------------------------------------------------------
281cdf0e10cSrcweir // XIndexContainer
insertByIndex(::sal_Int32 Index,const uno::Any & Element)282cdf0e10cSrcweir void SAL_CALL OFixedText::insertByIndex( ::sal_Int32 Index, const uno::Any& Element ) throw (lang::IllegalArgumentException, lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
283cdf0e10cSrcweir {
284cdf0e10cSrcweir     m_aProps.insertByIndex(Index,Element);
285cdf0e10cSrcweir }
286cdf0e10cSrcweir // -----------------------------------------------------------------------------
removeByIndex(::sal_Int32 Index)287cdf0e10cSrcweir void SAL_CALL OFixedText::removeByIndex( ::sal_Int32 Index ) throw (lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
288cdf0e10cSrcweir {
289cdf0e10cSrcweir     m_aProps.removeByIndex(Index);
290cdf0e10cSrcweir }
291cdf0e10cSrcweir // -----------------------------------------------------------------------------
292cdf0e10cSrcweir // XIndexReplace
replaceByIndex(::sal_Int32 Index,const uno::Any & Element)293cdf0e10cSrcweir void SAL_CALL OFixedText::replaceByIndex( ::sal_Int32 Index, const uno::Any& Element ) throw (lang::IllegalArgumentException, lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
294cdf0e10cSrcweir {
295cdf0e10cSrcweir     m_aProps.replaceByIndex(Index,Element);
296cdf0e10cSrcweir }
297cdf0e10cSrcweir // -----------------------------------------------------------------------------
298cdf0e10cSrcweir // XIndexAccess
getCount()299cdf0e10cSrcweir ::sal_Int32 SAL_CALL OFixedText::getCount(  ) throw (uno::RuntimeException)
300cdf0e10cSrcweir {
301cdf0e10cSrcweir     return m_aProps.getCount();
302cdf0e10cSrcweir }
303cdf0e10cSrcweir // -----------------------------------------------------------------------------
getByIndex(::sal_Int32 Index)304cdf0e10cSrcweir uno::Any SAL_CALL OFixedText::getByIndex( ::sal_Int32 Index ) throw (lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException)
305cdf0e10cSrcweir {
306cdf0e10cSrcweir     return m_aProps.getByIndex( Index );
307cdf0e10cSrcweir }
308cdf0e10cSrcweir // -----------------------------------------------------------------------------
309cdf0e10cSrcweir // XShape
getPosition()310cdf0e10cSrcweir awt::Point SAL_CALL OFixedText::getPosition(  ) throw (uno::RuntimeException)
311cdf0e10cSrcweir {
312cdf0e10cSrcweir     return OShapeHelper::getPosition(this);
313cdf0e10cSrcweir }
314cdf0e10cSrcweir // -----------------------------------------------------------------------------
setPosition(const awt::Point & aPosition)315cdf0e10cSrcweir void SAL_CALL OFixedText::setPosition( const awt::Point& aPosition ) throw (uno::RuntimeException)
316cdf0e10cSrcweir {
317cdf0e10cSrcweir     OShapeHelper::setPosition(aPosition,this);
318cdf0e10cSrcweir }
319cdf0e10cSrcweir // -----------------------------------------------------------------------------
getSize()320cdf0e10cSrcweir awt::Size SAL_CALL OFixedText::getSize(  ) throw (uno::RuntimeException)
321cdf0e10cSrcweir {
322cdf0e10cSrcweir     return OShapeHelper::getSize(this);
323cdf0e10cSrcweir }
324cdf0e10cSrcweir // -----------------------------------------------------------------------------
setSize(const awt::Size & aSize)325cdf0e10cSrcweir void SAL_CALL OFixedText::setSize( const awt::Size& aSize ) throw (beans::PropertyVetoException, uno::RuntimeException)
326cdf0e10cSrcweir {
327cdf0e10cSrcweir     OShapeHelper::setSize(aSize,this);
328cdf0e10cSrcweir }
329cdf0e10cSrcweir // -----------------------------------------------------------------------------
330cdf0e10cSrcweir 
331cdf0e10cSrcweir // XShapeDescriptor
getShapeType()332cdf0e10cSrcweir ::rtl::OUString SAL_CALL OFixedText::getShapeType(  ) throw (uno::RuntimeException)
333cdf0e10cSrcweir {
3349320a50fSMichael Stahl     return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.ControlShape"));
335cdf0e10cSrcweir }
336cdf0e10cSrcweir // -----------------------------------------------------------------------------
337cdf0e10cSrcweir // -----------------------------------------------------------------------------
338cdf0e10cSrcweir // =============================================================================
339cdf0e10cSrcweir } // namespace reportdesign
340cdf0e10cSrcweir // =============================================================================
341