20#include <com/sun/star/beans/XPropertySet.hpp>
21#include <com/sun/star/container/XNamed.hpp>
22#include <com/sun/star/drawing/XDrawPage.hpp>
41#include <oox/token/namespaces.hxx>
42#include <oox/token/properties.hxx>
43#include <oox/token/tokens.hxx>
56: FragmentHandler2( rFilter, rFragmentPath )
57, mpSlidePersistPtr( pPersistPtr )
58, meShapeLocation( eShapeLocation )
60 OUString aVMLDrawingFragmentPath = getFragmentPathFromFirstTypeFromOfficeDoc(
u"vmlDrawing" );
61 if( !aVMLDrawingFragmentPath.isEmpty() )
63 getFilter(), aVMLDrawingFragmentPath, *pPersistPtr->getDrawing() ) );
74 switch( aElementToken )
76 case PPT_TOKEN( sldMaster ):
77 case PPT_TOKEN( handoutMaster ):
78 case PPT_TOKEN( sld ):
81 Reference< css::beans::XPropertySet > xSet(xSlide, UNO_QUERY);
85 std::optional<bool> aShowMasterShapes = rAttribs.
getBool(XML_showMasterSp);
86 if (aShowMasterShapes.has_value() && !aShowMasterShapes.value())
87 xSet->setPropertyValue(
"IsBackgroundObjectsVisible",
Any(
false));
94 case PPT_TOKEN(
notes ):
98 OUString aNotesFragmentPath = getFragmentPathFromFirstTypeFromOfficeDoc(
u"notesMaster" );
100 std::vector< SlidePersistPtr >& rMasterPages( rFilter.
getMasterPages() );
101 bool bNotesFragmentPathFound =
false;
102 for (
auto const& masterPage : rMasterPages)
104 if( masterPage->getPath() == aNotesFragmentPath )
108 bNotesFragmentPathFound=
true;
115 std::make_shared<PPTShape>(
Master,
"com.sun.star.drawing.GroupShape" ),
mpSlidePersistPtr->getNotesTextStyle() );
116 pMasterPersistPtr->setPath( aNotesFragmentPath );
124 case PPT_TOKEN( notesMaster ):
126 case PPT_TOKEN( cSld ):
130 case PPT_TOKEN( spTree ):
134 std::make_shared<PPTShape>(
meShapeLocation,
"com.sun.star.drawing.GroupShape" ) );
138 case PPT_TOKEN( controls ):
140 case PPT_TOKEN( control ):
150 case PPT_TOKEN( timing ):
154 case PPT_TOKEN( hf ):
158 case PPT_TOKEN( bg ):
160 case PPT_TOKEN( bgPr ):
168 case PPT_TOKEN( bgRef ):
170 const FillProperties *pFillProperties =
nullptr;
175 ? std::make_shared<FillProperties>( *pFillProperties )
176 : std::make_shared<FillProperties>();
183 case A_TOKEN( overrideClrMapping ):
184 case PPT_TOKEN( clrMap ):
188 ? std::make_shared<oox::drawingml::ClrMap>()
195 case PPT_TOKEN( clrMapOvr ):
196 case PPT_TOKEN( sldLayoutIdLst ):
198 case PPT_TOKEN( txStyles ):
200 case PPT_TOKEN( custDataLst ):
201 case PPT_TOKEN( tagLst ):
205 case PPT_TOKEN( cmLst ):
207 case PPT_TOKEN(
cm ):
220 case PPT_TOKEN(
pos ):
226 case PPT_TOKEN( cmAuthor ):
252 Reference< XNamed > xNamed( xSlide, UNO_QUERY );
257 catch( uno::Exception& )
Provides access to attribute values of an element.
OUString getStringDefaulted(sal_Int32 nAttrToken) const
Returns the string value of the specified attribute, returns an empty string if attribute not present...
std::optional< OUString > getXString(sal_Int32 nAttrToken) const
Returns the string value of the specified attribute.
std::optional< sal_Int32 > getInteger(sal_Int32 nAttrToken) const
Returns the 32-bit signed integer value of the specified attribute (decimal).
std::optional< bool > getBool(sal_Int32 nAttrToken) const
Returns the boolean value of the specified attribute.
A helper that maps property identifiers to property values.
bool setProperty(sal_Int32 nPropId, Type &&rValue)
Sets the specified property to the passed value.
A wrapper for a UNO property set.
void setProperties(const css::uno::Sequence< OUString > &rPropNames, const css::uno::Sequence< css::uno::Any > &rValues)
Puts the passed properties into the property set.
bool importFragment(const rtl::Reference< FragmentHandler > &rxHandler)
Imports a fragment using the passed fragment handler, which contains the full path to the fragment st...
std::vector< SlidePersistPtr > & getMasterPages()
virtual ~SlideFragmentHandler() override
const ::std::vector< OUString > & getCharVector() const
SlideFragmentHandler(::oox::core::XmlFilterBase &rFilter, const OUString &rFragmentPath, const SlidePersistPtr &pPersistPtr, const ShapeLocation eShapeLocation)
virtual ::oox::core::ContextHandlerRef onCreateContext(sal_Int32 aElementToken, const AttributeList &rAttribs) override
SlidePersistPtr mpSlidePersistPtr
ShapeLocation meShapeLocation
::std::vector< OUString > maCharVector
virtual void onCharacters(const OUString &rChars) override
virtual void finalizeImport() override
PropertyMap maSlideProperties
#define TOOLS_WARN_EXCEPTION(area, stream)
::rtl::Reference< ContextHandler > ContextHandlerRef
::rtl::Reference< FragmentHandler > FragmentHandlerRef
std::shared_ptr< ClrMap > ClrMapPtr
std::shared_ptr< FillProperties > FillPropertiesPtr
std::shared_ptr< SlidePersist > SlidePersistPtr
const snew_slide_value_info_layout notes[]
Contains information about a form control embedded in a draw page.
OUString maName
Programmatical name of the form control.
void setShapeId(sal_Int32 nShapeId)
Sets the string representation of the passed numeric shape identifier.
OUString maFragmentPath
Path to the fragment describing the form control properties.
constexpr OUStringLiteral PROP_Visible