LibreOffice Module slideshow (master) 1
Public Member Functions | List of all members
slideshow::internal::AttributableShape Class Referenceabstract

Represents an animatable shape, that can have its attributes changed. More...

#include <attributableshape.hxx>

Inheritance diagram for slideshow::internal::AttributableShape:
[legend]
Collaboration diagram for slideshow::internal::AttributableShape:
[legend]

Public Member Functions

virtual ShapeAttributeLayerSharedPtr createAttributeLayer ()=0
 Create a new shape attribute layer. More...
 
virtual bool revokeAttributeLayer (const ShapeAttributeLayerSharedPtr &rLayer)=0
 Revoke a previously generated attribute layer. More...
 
virtual ShapeAttributeLayerSharedPtr getTopmostAttributeLayer () const =0
 Get the topmost shape attribute layer (if any). More...
 
virtual void setVisibility (bool bVisible)=0
 Change default shape visibility. More...
 
virtual const DocTreeNodeSuppliergetTreeNodeSupplier () const =0
 Retrieve interface for DocTreeNode creation. More...
 
virtual DocTreeNodeSuppliergetTreeNodeSupplier ()=0
 
virtual DocTreeNode getSubsetNode () const =0
 Query the subset this shape displays. More...
 
virtual AttributableShapeSharedPtr getSubset (const DocTreeNode &rTreeNode) const =0
 Query a subset Shape, if already existent at this object. More...
 
virtual bool createSubset (AttributableShapeSharedPtr &o_rSubset, const DocTreeNode &rTreeNode)=0
 Create a subset Shape. More...
 
virtual bool revokeSubset (const AttributableShapeSharedPtr &rShape)=0
 Revoke a previously generated shape subset. More...
 
- Public Member Functions inherited from slideshow::internal::AnimatableShape
virtual void enterAnimationMode ()=0
 Notify the Shape that an animation starts now. More...
 
virtual void leaveAnimationMode ()=0
 Notify the Shape that it is no longer animated. More...
 
- Public Member Functions inherited from slideshow::internal::Shape
 Shape ()
 
virtual ~Shape ()
 
 Shape (const Shape &)=delete
 
Shapeoperator= (const Shape &)=delete
 
virtual css::uno::Reference< css::drawing::XShape > getXShape () const =0
 Get the associated XShape of this shape. More...
 
virtual void addViewLayer (const ViewLayerSharedPtr &rNewLayer, bool bRedrawLayer)=0
 Add a new view layer. More...
 
virtual bool removeViewLayer (const ViewLayerSharedPtr &rNewLayer)=0
 Withdraw the shape from a view layer. More...
 
virtual void clearAllViewLayers ()=0
 Withdraw all view layers at once. More...
 
virtual bool update () const =0
 Update the shape. More...
 
virtual bool render () const =0
 Render the shape. More...
 
virtual bool isContentChanged () const =0
 Query whether shape content changed. More...
 
virtual ::basegfx::B2DRectangle getBounds () const =0
 Get the current shape position and size. More...
 
virtual ::basegfx::B2DRectangle getDomBounds () const =0
 Get the DOM position and size of the shape. More...
 
virtual ::basegfx::B2DRectangle getUpdateArea () const =0
 Get the current shape update area. More...
 
virtual bool isVisible () const =0
 Query whether the shape is visible at all. More...
 
virtual double getPriority () const =0
 Get the shape priority. More...
 
virtual bool isBackgroundDetached () const =0
 Query whether the Shape is currently detached from the background. More...
 
virtual bool isForeground () const
 Check whether the shape belongs to the foreground. More...
 
virtual void setIsForeground (const bool bIsForeground)
 Set the flag that holds whether the shape is in the foreground or not. More...
 

Detailed Description

Represents an animatable shape, that can have its attributes changed.

Over an animatable shape, this interface adds attribute modification methods. Furthermore, the shape can be queried for sub items, which in turn can be separated out into own AttributableShapes.

Definition at line 43 of file attributableshape.hxx.

Member Function Documentation

◆ createAttributeLayer()

virtual ShapeAttributeLayerSharedPtr slideshow::internal::AttributableShape::createAttributeLayer ( )
pure virtual

Create a new shape attribute layer.

This method creates a new layer for shape attributes, which lies atop of all previous attribute layers. That is most typically used when a new SMIL animation starts (which according to the spec always lies atop of all previous animations). Thus, subsequent calls to this method generate a sandwich of attribute layers, which in total define the shape's attributes.

Please note that the attribute layers do not contain the underlying XShape's attributes as default. Instead, attributes not explicitly set by animations remain in invalid state, allowing the shape's paint method to determine whether they have to override the underlying graphical shape representation. XShape attributes must be passed explicitly to animations which need them (e.g. 'by' animations).

Returns
the new layer

Implemented in slideshow::internal::DrawShape.

◆ createSubset()

virtual bool slideshow::internal::AttributableShape::createSubset ( AttributableShapeSharedPtr o_rSubset,
const DocTreeNode rTreeNode 
)
pure virtual

Create a subset Shape.

This method creates a clone of this Shape, which renders only the selected subset of itself. Multiple createSubset() calls for the same DocTreeNode will all share the same subset shape.

The original shape (i.e. the one this method is called on) will cease to display the selected subset part. That is, together the shapes will display the original content, but the content of all subset shapes and their original shape will always be mutually disjunct.

After deregistering the subset shape a matching number of times via revokeSubset(), the original shape will resume displaying the subsetted part.

Attention: \n To maintain view integrity, this method
should only be called from the LayerManager
Parameters
o_rSubsetThe requested Shape
rTreeNodeA DocTreeNode instance queried from this Shape, which specifies the subset of the Shape to render
Returns
true, if the shape was newly created, and false, if an already existing subset is returned.

Implemented in slideshow::internal::DrawShape.

◆ getSubset()

virtual AttributableShapeSharedPtr slideshow::internal::AttributableShape::getSubset ( const DocTreeNode rTreeNode) const
pure virtual

Query a subset Shape, if already existent at this object.

This method returns a clone of this Shape, which renders only the selected subset of itself, but only if such a subset has been explicitly created before.

Parameters
rTreeNodeA DocTreeNode instance queried from this Shape, which specifies the subset of the Shape to render.
Returns
a NULL Shape pointer, if no subset exists for the given DocTreeNode.

Implemented in slideshow::internal::DrawShape.

◆ getSubsetNode()

virtual DocTreeNode slideshow::internal::AttributableShape::getSubsetNode ( ) const
pure virtual

Query the subset this shape displays.

This method returns a tree node denoting the subset displayed by this shape. If this shape is not a subset shape, an empty tree node should be returned. If this shape is a subset, and itself has subsetted children, this method might return more than the shape is actually displaying (because a single DocTreeNode is not able to model holes in the range).

Implemented in slideshow::internal::DrawShape.

◆ getTopmostAttributeLayer()

virtual ShapeAttributeLayerSharedPtr slideshow::internal::AttributableShape::getTopmostAttributeLayer ( ) const
pure virtual

Get the topmost shape attribute layer (if any).

This method returns the topmost layer for shape attributes, i.e. the one which ultimately determines the shape's look.

Please note that the attribute layers do not contain the underlying XShape's attributes as default. Instead, attributes not explicitly set by animations remain in invalid state, allowing the shape's paint method to determine whether they have to override the underlying graphical shape representation. XShape attributes must be passed explicitly to animations which need them (e.g. 'by' animations).

Returns
the topmost layer

Implemented in slideshow::internal::DrawShape.

◆ getTreeNodeSupplier() [1/2]

virtual const DocTreeNodeSupplier & slideshow::internal::AttributableShape::getTreeNodeSupplier ( ) const
pure virtual

Retrieve interface for DocTreeNode creation.

This method provides the caller with a reference to the DocTreeNodeSupplier interface, which can be used to request specific tree nodes for this shape.

Implemented in slideshow::internal::DrawShape.

◆ getTreeNodeSupplier() [2/2]

virtual DocTreeNodeSupplier & slideshow::internal::AttributableShape::getTreeNodeSupplier ( )
pure virtual

◆ revokeAttributeLayer()

virtual bool slideshow::internal::AttributableShape::revokeAttributeLayer ( const ShapeAttributeLayerSharedPtr rLayer)
pure virtual

Revoke a previously generated attribute layer.

This method revokes a previously generated attribute layer, and removes the effect of that layer from this shape. The layer need not be the current toplevel layer, it can also be revoked from in between.

Parameters
rLayerLayer to revoke. Must have been generated by createAttributeLayer() at the same Shape.
Returns
true, if layer was successfully removed, false otherwise (e.g. if the given layer was not generated for this shape).

Implemented in slideshow::internal::DrawShape.

◆ revokeSubset()

virtual bool slideshow::internal::AttributableShape::revokeSubset ( const AttributableShapeSharedPtr rShape)
pure virtual

Revoke a previously generated shape subset.

After revoking a subset shape, the corresponding subset part will become visible again on the original shape.

Attention: \n To maintain view integrity, this method
should only be called from the LayerManager
Parameters
rShapeThe subset to revoke
Returns
true, if the last client called revokeSubset().

Implemented in slideshow::internal::DrawShape.

◆ setVisibility()

virtual void slideshow::internal::AttributableShape::setVisibility ( bool  bVisible)
pure virtual

Change default shape visibility.

This method hides or unhides a shape. Note that every attribute layer generated for this shape is able to override the setting given here, until it is revoked.

Parameters
bVisibleWhen true, shape will be visible, when false, invisible (modulo attribute layer overrides).

Implemented in slideshow::internal::DrawShape.


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