27#include <com/sun/star/embed/Aspects.hpp>
28#include <com/sun/star/embed/XEmbeddedObject.hpp>
36 using namespace rptui;
39 ,
const uno::Reference< report::XSection >& _xSection)
47 uno::Reference< report::XReportComponent> xReportComponent(xDescr,uno::UNO_QUERY);
48 if ( xReportComponent.is() )
50 return OObjectBase::createObject(
60 OObjectBase* pBaseObj =
dynamic_cast<OObjectBase*
>(pObj);
64 uno::Reference< report::XSection> xSection =
m_xSection;
65 uno::Reference< lang::XMultiServiceFactory>
xFactory;
67 xFactory.set(xSection->getReportDefinition(),uno::UNO_QUERY);
68 uno::Reference< drawing::XShape > xRet;
69 uno::Reference< drawing::XShape > xShape;
72 bool bChangeOrientation =
false;
73 const OUString&
sServiceName = pBaseObj->getServiceName();
74 OSL_ENSURE(!
sServiceName.isEmpty(),
"No Service Name given!");
76 if (
dynamic_cast< const OUnoObject*
>(pObj) !=
nullptr)
81 uno::Reference<beans::XPropertySet> xControlModel(rUnoObj.
GetUnoControlModel(),uno::UNO_QUERY);
82 if ( xControlModel.is() )
86 bChangeOrientation = rUnoObj.
GetObjIdentifier() == SdrObjKind::ReportDesignHorizontalFixedLine;
91 else if (
dynamic_cast< const OCustomShape*
>(pObj) !=
nullptr)
97 else if (
dynamic_cast< const SdrOle2Obj*
>(pObj) !=
nullptr)
102 sal_Int64 nAspect = embed::Aspects::MSOLE_CONTENT;
103 uno::Reference < embed::XEmbeddedObject > xObj;
107 u"80243D39-6741-46C5-926E-069164FF87BB"),
sName );
108 OSL_ENSURE(xObj.is(),
"Embedded Object could not be created!");
123 xObj->setVisualAreaSize( nAspect, aSz );
138 catch(
const uno::Exception& )
constexpr OUStringLiteral sServiceName
::comphelper::IEmbeddedHelper * GetPersist() const
void SetOutlinerParaObject(std::optional< OutlinerParaObject > pTextObject)
void SetEmptyPresObj(bool bEpt)
SdrModel & getSdrModelFromSdrObject() const
virtual SdrObjKind GetObjIdentifier() const
virtual void SetName(const OUString &rStr, const bool bSetChanged=true)
css::uno::Reference< css::embed::XEmbeddedObject > const & GetObjRef() const
void SetObjRef(const css::uno::Reference< css::embed::XEmbeddedObject > &rNewObjRef)
void SetPersistName(const OUString &rPersistName, SvxOle2Shape *pCreator=nullptr)
void SetAspect(sal_Int64 nAspect)
virtual const tools::Rectangle & GetLogicRect() const override
const css::uno::Reference< css::awt::XControlModel > & GetUnoControlModel() const
constexpr tools::Long Height() const
constexpr tools::Long Width() const
virtual css::uno::Reference< css::drawing::XShape > CreateShape(SdrObject *pObj) const
SdrPage * GetSdrPage() const
virtual rtl::Reference< SdrObject > CreateSdrObject_(const css::uno::Reference< css::drawing::XShape > &xShape)
css::uno::Reference< css::embed::XEmbeddedObject > CreateEmbeddedObject(const css::uno::Sequence< sal_Int8 > &, OUString &, OUString const *pBaseURL=nullptr)
virtual EmbeddedObjectContainer & getEmbeddedObjectContainer() const=0
static css::uno::Sequence< sal_Int8 > GetSequenceClassIDRepresentation(std::u16string_view aClassID)
OReportDrawPage(const OReportDrawPage &)=delete
css::uno::WeakReference< css::report::XSection > m_xSection
virtual css::uno::Reference< css::drawing::XShape > CreateShape(SdrObject *pObj) const override
css::uno::Reference< css::uno::XInterface > createShape(const OUString &aServiceSpecifier, css::uno::Reference< css::drawing::XShape > &_rShape, sal_Int32 nOrientation=-1)
virtual SdrObjKind GetObjIdentifier() const override
#define DBG_UNHANDLED_EXCEPTION(...)
Reference< XSingleServiceFactory > xFactory
constexpr OUStringLiteral PROPERTY_MULTILINE