LibreOffice Module slideshow (master) 1
Classes | Public Member Functions | Private Member Functions | Private Attributes | List of all members
slideshow::internal::ShapeImporter Class Reference

This class imports all shapes from a given XShapes object. More...

#include <shapeimporter.hxx>

Collaboration diagram for slideshow::internal::ShapeImporter:
[legend]

Classes

struct  XShapesEntry
 

Public Member Functions

 ShapeImporter (const css::uno::Reference< css::drawing::XDrawPage > &xPage, css::uno::Reference< css::drawing::XDrawPage > xActualPage, css::uno::Reference< css::drawing::XDrawPagesSupplier > xPagesSupplier, const SlideShowContext &rContext, sal_Int32 nOrdNumStart, bool bConvertingMasterPage)
 Create shape importer. More...
 
ShapeSharedPtr importBackgroundShape ()
 This method imports the presentation background shape. More...
 
ShapeSharedPtr importShape ()
 This method imports presentation-visible shapes (and skips all others). More...
 
bool isImportDone () const
 Test whether import is done. More...
 
const PolyPolygonVectorgetPolygons () const
 
double getImportedShapesCount () const
 

Private Member Functions

bool isSkip (css::uno::Reference< css::beans::XPropertySet > const &xPropSet, std::u16string_view shapeType, css::uno::Reference< css::drawing::XLayer > const &xLayer)
 
ShapeSharedPtr createShape (css::uno::Reference< css::drawing::XShape > const &xCurrShape, css::uno::Reference< css::beans::XPropertySet > const &xPropSet, std::u16string_view shapeType) const
 
void importPolygons (css::uno::Reference< css::beans::XPropertySet > const &xPropSet)
 

Private Attributes

css::uno::Reference< css::drawing::XDrawPage > mxPage
 
css::uno::Reference< css::drawing::XDrawPagesSupplier > mxPagesSupplier
 
const SlideShowContextmrContext
 
PolyPolygonVector maPolygons
 
::std::stack< XShapesEntrymaShapesStack
 
double mnAscendingPrio
 
bool mbConvertingMasterPage
 

Detailed Description

This class imports all shapes from a given XShapes object.

Definition at line 46 of file shapeimporter.hxx.

Constructor & Destructor Documentation

◆ ShapeImporter()

slideshow::internal::ShapeImporter::ShapeImporter ( const css::uno::Reference< css::drawing::XDrawPage > &  xPage,
css::uno::Reference< css::drawing::XDrawPage >  xActualPage,
css::uno::Reference< css::drawing::XDrawPagesSupplier >  xPagesSupplier,
const SlideShowContext rContext,
sal_Int32  nOrdNumStart,
bool  bConvertingMasterPage 
)

Create shape importer.

Parameters
xPagePage containing the shapes
xActualPageActual page that's imported - if xPage is a master page, this argument must refer to the using, i.e the page that embeds this specific masterpage. Otherwise, this argument is probably equal to xPage.
nOrdNumStartEach shape receives a z order number, in order of import (which relies on the fact that the API returns the shapes in draw order - which it does, currently). Since we might mix several pages on screen (e.g. master page and foreground page), this value can be used as an offset to distinguish those pages.
bConvertingMasterPageWhen true, then the master page is imported. Otherwise, this object imports the draw page.

Definition at line 517 of file shapeimporter.cxx.

References maShapesStack.

Member Function Documentation

◆ createShape()

ShapeSharedPtr slideshow::internal::ShapeImporter::createShape ( css::uno::Reference< css::drawing::XShape > const &  xCurrShape,
css::uno::Reference< css::beans::XPropertySet > const &  xPropSet,
std::u16string_view  shapeType 
) const
private

◆ getImportedShapesCount()

double slideshow::internal::ShapeImporter::getImportedShapesCount ( ) const
inline

Definition at line 97 of file shapeimporter.hxx.

References mnAscendingPrio.

◆ getPolygons()

const PolyPolygonVector & slideshow::internal::ShapeImporter::getPolygons ( ) const

Definition at line 512 of file shapeimporter.cxx.

References maPolygons.

◆ importBackgroundShape()

ShapeSharedPtr slideshow::internal::ShapeImporter::importBackgroundShape ( )

This method imports the presentation background shape.

Definition at line 417 of file shapeimporter.cxx.

References slideshow::internal::createBackgroundShape(), mrContext, and slideshow::internal::ShapeImporter::XShapesEntry::mxShapes.

◆ importPolygons()

void slideshow::internal::ShapeImporter::importPolygons ( css::uno::Reference< css::beans::XPropertySet > const &  xPropSet)
private

◆ importShape()

ShapeSharedPtr slideshow::internal::ShapeImporter::importShape ( )

◆ isImportDone()

bool slideshow::internal::ShapeImporter::isImportDone ( ) const

Test whether import is done.

Returns
true, if all shapes are imported via the importShape() call.

Definition at line 507 of file shapeimporter.cxx.

◆ isSkip()

bool slideshow::internal::ShapeImporter::isSkip ( css::uno::Reference< css::beans::XPropertySet > const &  xPropSet,
std::u16string_view  shapeType,
css::uno::Reference< css::drawing::XLayer > const &  xLayer 
)
private

Definition at line 337 of file shapeimporter.cxx.

References a, slideshow::internal::getPropertyValue(), and u.

Member Data Documentation

◆ maPolygons

PolyPolygonVector slideshow::internal::ShapeImporter::maPolygons
private

Definition at line 131 of file shapeimporter.hxx.

◆ maShapesStack

::std::stack<XShapesEntry> slideshow::internal::ShapeImporter::maShapesStack
private

Definition at line 132 of file shapeimporter.hxx.

Referenced by ShapeImporter().

◆ mbConvertingMasterPage

bool slideshow::internal::ShapeImporter::mbConvertingMasterPage
private

Definition at line 134 of file shapeimporter.hxx.

◆ mnAscendingPrio

double slideshow::internal::ShapeImporter::mnAscendingPrio
private

Definition at line 133 of file shapeimporter.hxx.

Referenced by getImportedShapesCount().

◆ mrContext

const SlideShowContext& slideshow::internal::ShapeImporter::mrContext
private

Definition at line 130 of file shapeimporter.hxx.

◆ mxPage

css::uno::Reference<css::drawing::XDrawPage> slideshow::internal::ShapeImporter::mxPage
private

Definition at line 128 of file shapeimporter.hxx.

◆ mxPagesSupplier

css::uno::Reference<css::drawing::XDrawPagesSupplier> slideshow::internal::ShapeImporter::mxPagesSupplier
private

Definition at line 129 of file shapeimporter.hxx.


The documentation for this class was generated from the following files: