21 #include <com/sun/star/drawing/XLayerSupplier.hpp>
22 #include <com/sun/star/container/XIndexAccess.hpp>
23 #include <com/sun/star/beans/XPropertySet.hpp>
24 #include <com/sun/star/frame/XModel.hpp>
31 using ::com::sun::star::uno::Reference;
33 using namespace ::
cppu;
44 Reference< XLayerSupplier > xLayerSupplier( rExport.
GetModel(), UNO_QUERY );
45 if( !xLayerSupplier.is() )
48 Reference< XIndexAccess > xLayerManager( xLayerSupplier->getLayerManager(), UNO_QUERY );
49 if( !xLayerManager.is() )
52 const sal_Int32
nCount = xLayerManager->getCount();
56 static const OUStringLiteral strName(
u"Name" );
57 static const OUStringLiteral strTitle(
u"Title" );
58 static const OUStringLiteral strDescription(
u"Description" );
59 static const OUStringLiteral strIsVisible(
u"IsVisible");
60 static const OUStringLiteral strIsPrintable(
u"IsPrintable");
61 static const OUStringLiteral strIsLocked(
u"IsLocked" );
73 xLayer->getPropertyValue( strName ) >>= sTmp;
77 bool bTmpVisible(
true );
78 bool bTmpPrintable(
true );
79 xLayer->getPropertyValue( strIsVisible) >>= bTmpVisible;
80 xLayer->getPropertyValue( strIsPrintable) >>= bTmpPrintable;
95 bool bTmpLocked(
false );
96 xLayer->getPropertyValue( strIsLocked ) >>= bTmpLocked;
106 xLayer->getPropertyValue(strTitle) >>= sTmp;
114 xLayer->getPropertyValue(strDescription) >>= sTmp;
const css::uno::Reference< css::frame::XModel > & GetModel() const
void AddAttribute(sal_uInt16 nPrefix, const char *pName, const OUString &rValue)
constexpr sal_uInt16 XML_NAMESPACE_DRAW
constexpr sal_uInt16 XML_NAMESPACE_SVG
#define TOOLS_WARN_EXCEPTION(area, stream)
static void exportLayer(SvXMLExport &rExport)
Handling of tokens in XML:
void Characters(const OUString &rChars)
css::uno::Any const SvXMLExport & rExport