LibreOffice Module svx (master)  1
Classes | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
EnhancedCustomShape2d Class Reference

#include <EnhancedCustomShape2d.hxx>

Inheritance diagram for EnhancedCustomShape2d:
[legend]
Collaboration diagram for EnhancedCustomShape2d:
[legend]

Classes

struct  EquationResult
 
struct  Handle
 

Public Member Functions

SAL_DLLPRIVATE bool IsFlipVert () const
 
SAL_DLLPRIVATE bool IsFlipHorz () const
 
SAL_DLLPRIVATE sal_Int32 GetRotateAngle () const
 
SdrObjectCreateLineGeometry ()
 
SdrObjectCreateObject (bool bLineGeometryNeededOnly)
 
void ApplyGluePoints (SdrObject *pObj)
 
tools::Rectangle GetTextRect () const
 
const tools::RectangleGetLogicRect () const
 
sal_uInt32 GetHdlCount () const
 
bool GetHandlePosition (const sal_uInt32 nIndex, Point &rReturnPosition) const
 
bool SetHandleControllerPosition (const sal_uInt32 nIndex, const css::awt::Point &rPosition)
 
 EnhancedCustomShape2d (SdrObjCustomShape &rSdrObjCustomShape)
 
virtual ~EnhancedCustomShape2d () override
 
SAL_DLLPRIVATE double GetEnumFunc (const EnhancedCustomShape::ExpressionFunct eVal) const
 
void GetParameter (double &rParameterReturnValue, const css::drawing::EnhancedCustomShapeParameter &, const bool bReplaceGeoWidth, const bool bReplaceGeoHeight) const
 
SAL_DLLPRIVATE double GetAdjustValueAsDouble (const sal_Int32 nIndex) const
 
SAL_DLLPRIVATE double GetEquationValueAsDouble (const sal_Int32 nIndex) const
 
- Public Member Functions inherited from SfxItemSet
SfxPoolItem const ** GetItems_Impl () const
 
 SfxItemSet (const SfxItemSet &)
 
 SfxItemSet (SfxItemSet &&) noexcept
 
 SfxItemSet (SfxItemPool &)
 
 SfxItemSet (typename std::enable_if< svl::detail::validRanges< WIDs... >(), SfxItemPool & >::type pool, svl::Items< WIDs... >)
 
 SfxItemSet (SfxItemPool &, std::initializer_list< Pair > wids)
 
 SfxItemSet (SfxItemPool &, const sal_uInt16 *nWhichPairTable)
 
virtual ~SfxItemSet ()
 
virtual std::unique_ptr< SfxItemSetClone (bool bItems=true, SfxItemPool *pToPool=nullptr) const
 
sal_uInt16 Count () const
 
sal_uInt16 TotalCount () const
 
const SfxPoolItemGet (sal_uInt16 nWhich, bool bSrchInParent=true) const
 
const T & Get (TypedWhichId< T > nWhich, bool bSrchInParent=true) const
 
const SfxPoolItemGetItem (sal_uInt16 nWhich, bool bSearchInParent=true) const
 
const T * GetItem (sal_uInt16 nWhich, bool bSearchInParent=true) const
 
const T * GetItem (TypedWhichId< T > nWhich, bool bSearchInParent=true) const
 
sal_uInt16 GetWhichByPos (sal_uInt16 nPos) const
 
SfxItemState GetItemState (sal_uInt16 nWhich, bool bSrchInParent=true, const SfxPoolItem **ppItem=nullptr) const
 
bool HasItem (sal_uInt16 nWhich, const SfxPoolItem **ppItem=nullptr) const
 
void DisableItem (sal_uInt16 nWhich)
 
void InvalidateItem (sal_uInt16 nWhich)
 
sal_uInt16 ClearItem (sal_uInt16 nWhich=0)
 
void ClearInvalidItems ()
 
void InvalidateAllItems ()
 
void SetParent (const SfxItemSet *pNew)
 
const SfxPoolItemPut (const SfxPoolItem &rItem, sal_uInt16 nWhich)
 
const SfxPoolItemPut (std::unique_ptr< SfxPoolItem > xItem, sal_uInt16 nWhich)
 
const SfxPoolItemPut (const SfxPoolItem &rItem)
 
const SfxPoolItemPut (std::unique_ptr< SfxPoolItem > xItem)
 
bool Put (const SfxItemSet &, bool bInvalidAsDefault=true)
 
void PutExtended (const SfxItemSet &, SfxItemState eDontCareAs, SfxItemState eDefaultAs)
 
bool Set (const SfxItemSet &, bool bDeep=true)
 
void Intersect (const SfxItemSet &rSet)
 
void MergeValues (const SfxItemSet &rSet)
 
void Differentiate (const SfxItemSet &rSet)
 
void MergeValue (const SfxPoolItem &rItem, bool bOverwriteDefaults=false)
 
SfxItemPoolGetPool () const
 
const sal_uInt16 * GetRanges () const
 
void SetRanges (const sal_uInt16 *pRanges)
 
void MergeRange (sal_uInt16 nFrom, sal_uInt16 nTo)
 
const SfxItemSetGetParent () const
 
bool operator== (const SfxItemSet &) const
 
bool Equals (const SfxItemSet &, bool bComparePool) const
 
void dumpAsXml (xmlTextWriterPtr pWriter) const
 

Static Public Member Functions

static OUString GetEquation (const sal_uInt16 nFlags, sal_Int32 nPara1, sal_Int32 nPara2, sal_Int32 nPara3)
 
static SAL_DLLPRIVATE void AppendEnhancedCustomShapeEquationParameter (OUString &rParameter, const sal_Int32 nPara, const bool bIsSpecialValue)
 
static void SetEnhancedCustomShapeParameter (css::drawing::EnhancedCustomShapeParameter &rParameter, const sal_Int32 nValue)
 
static void SetEnhancedCustomShapeHandleParameter (css::drawing::EnhancedCustomShapeParameter &rParameter, const sal_Int32 nPara, const bool bIsSpecialValue, bool bHorz)
 
static SAL_DLLPRIVATE bool ConvertSequenceToEnhancedCustomShape2dHandle (const css::beans::PropertyValues &rHandleProperties, EnhancedCustomShape2d::Handle &rDestinationHandle)
 
static SAL_DLLPRIVATE void SwapStartAndEndArrow (SdrObject *pObj)
 
- Static Public Member Functions inherited from SfxItemSet
static const T * GetItem (const SfxItemSet *pItemSet, sal_uInt16 nWhich, bool bSearchInParent)
 
static const T * GetItem (const SfxItemSet *pItemSet, TypedWhichId< T > nWhich, bool bSearchInParent)
 

Private Member Functions

SAL_DLLPRIVATE bool SetAdjustValueAsDouble (const double &rValue, const sal_Int32 nIndex)
 
SAL_DLLPRIVATE sal_Int32 GetLuminanceChange (sal_uInt32 nIndex) const
 
SAL_DLLPRIVATE Color GetColorData (const Color &rFillColor, sal_uInt32 nIndex, double dBrightness) const
 
SAL_DLLPRIVATE void AdaptObjColor (SdrPathObj &rObj, double dBrightness, const SfxItemSet &rCustomShapeSet, sal_uInt32 &nColorIndex, sal_uInt32 nColorCount)
 
SAL_DLLPRIVATE Point GetPoint (const css::drawing::EnhancedCustomShapeParameterPair &, const bool bScale=true, const bool bReplaceGeoSize=false) const
 
SAL_DLLPRIVATE basegfx::B2DPoint GetPointAsB2DPoint (const css::drawing::EnhancedCustomShapeParameterPair &, const bool bScale=true, const bool bReplaceGeoSize=false) const
 
SAL_DLLPRIVATE void CreateSubPath (sal_Int32 &rSrcPt, sal_Int32 &rSegmentInd, std::vector< std::pair< SdrPathObj *, double > > &rObjectList, bool bLineGeometryNeededOnly, bool bSortFilledObjectsToBack, sal_Int32 nIndex)
 
SAL_DLLPRIVATE SdrObjectCreatePathObj (bool bLineGeometryNeededOnly)
 
SAL_DLLPRIVATE void ApplyShapeAttributes (const SdrCustomShapeGeometryItem &rItem)
 
SAL_DLLPRIVATE void SetPathSize (sal_Int32 nIndex=0)
 

Private Attributes

SdrObjCustomShapemrSdrObjCustomShape
 
MSO_SPT eSpType
 
sal_Int32 nCoordLeft
 
sal_Int32 nCoordTop
 
sal_Int32 nCoordWidthG
 
sal_Int32 nCoordHeightG
 
sal_Int32 nCoordWidth
 
sal_Int32 nCoordHeight
 
tools::Rectangle aLogicRect
 
double fXScale
 
double fYScale
 
double fXRatio
 
double fYRatio
 
bool bOOXMLShape
 
sal_Int32 nXRef
 
sal_Int32 nYRef
 
sal_uInt32 nColorData
 
css::uno::Sequence< OUString > seqEquations
 
std::vector< std::shared_ptr< EnhancedCustomShape::ExpressionNode > > vNodesSharedPtr
 
std::vector< EquationResultvEquationResults
 
css::uno::Sequence< css::drawing::EnhancedCustomShapeSegment > seqSegments
 
css::uno::Sequence< css::drawing::EnhancedCustomShapeParameterPair > seqCoordinates
 
css::uno::Sequence< css::drawing::EnhancedCustomShapeTextFrame > seqTextFrames
 
css::uno::Sequence< css::drawing::EnhancedCustomShapeParameterPair > seqGluePoints
 
css::uno::Sequence< css::drawing::EnhancedCustomShapeAdjustmentValue > seqAdjustmentValues
 
css::uno::Sequence< css::beans::PropertyValuesseqHandles
 
css::uno::Sequence< css::awt::Size > seqSubViewSize
 
bool const bFilled: 1
 
bool const bStroked: 1
 
bool bFlipH
 
bool bFlipV
 
sal_Int32 nRotateAngle
 

Additional Inherited Members

- Protected Member Functions inherited from SfxItemSet
virtual void Changed (const SfxPoolItem &rOld, const SfxPoolItem &rNew)
 
void PutDirect (const SfxPoolItem &rItem)
 
virtual const SfxPoolItemPutImpl (const SfxPoolItem &, sal_uInt16 nWhich, bool bPassingOwnership)
 

Detailed Description

Definition at line 77 of file EnhancedCustomShape2d.hxx.

Constructor & Destructor Documentation

EnhancedCustomShape2d::EnhancedCustomShape2d ( SdrObjCustomShape rSdrObjCustomShape)
EnhancedCustomShape2d::~EnhancedCustomShape2d ( )
overridevirtual

Definition at line 627 of file EnhancedCustomShape2d.cxx.

Member Function Documentation

void EnhancedCustomShape2d::AdaptObjColor ( SdrPathObj rObj,
double  dBrightness,
const SfxItemSet rCustomShapeSet,
sal_uInt32 &  nColorIndex,
sal_uInt32  nColorCount 
)
private
void EnhancedCustomShape2d::AppendEnhancedCustomShapeEquationParameter ( OUString &  rParameter,
const sal_Int32  nPara,
const bool  bIsSpecialValue 
)
static
void EnhancedCustomShape2d::ApplyGluePoints ( SdrObject pObj)
void EnhancedCustomShape2d::ApplyShapeAttributes ( const SdrCustomShapeGeometryItem rItem)
private
bool EnhancedCustomShape2d::ConvertSequenceToEnhancedCustomShape2dHandle ( const css::beans::PropertyValues rHandleProperties,
EnhancedCustomShape2d::Handle rDestinationHandle 
)
static
SdrObject * EnhancedCustomShape2d::CreateLineGeometry ( )

Definition at line 3014 of file EnhancedCustomShape2d.cxx.

References CreateObject().

SdrObject * EnhancedCustomShape2d::CreateObject ( bool  bLineGeometryNeededOnly)
SdrObject * EnhancedCustomShape2d::CreatePathObj ( bool  bLineGeometryNeededOnly)
private
void EnhancedCustomShape2d::CreateSubPath ( sal_Int32 &  rSrcPt,
sal_Int32 &  rSegmentInd,
std::vector< std::pair< SdrPathObj *, double > > &  rObjectList,
bool  bLineGeometryNeededOnly,
bool  bSortFilledObjectsToBack,
sal_Int32  nIndex 
)
private
double EnhancedCustomShape2d::GetAdjustValueAsDouble ( const sal_Int32  nIndex) const

Definition at line 854 of file EnhancedCustomShape2d.cxx.

References seqAdjustmentValues, and Value.

Referenced by GetParameter(), and SetHandleControllerPosition().

Color EnhancedCustomShape2d::GetColorData ( const Color rFillColor,
sal_uInt32  nIndex,
double  dBrightness 
) const
private
double EnhancedCustomShape2d::GetEnumFunc ( const EnhancedCustomShape::ExpressionFunct  eVal) const
OUString EnhancedCustomShape2d::GetEquation ( const sal_uInt16  nFlags,
sal_Int32  nPara1,
sal_Int32  nPara2,
sal_Int32  nPara3 
)
static
double EnhancedCustomShape2d::GetEquationValueAsDouble ( const sal_Int32  nIndex) const
bool EnhancedCustomShape2d::GetHandlePosition ( const sal_uInt32  nIndex,
Point rReturnPosition 
) const
sal_uInt32 EnhancedCustomShape2d::GetHdlCount ( ) const

Definition at line 1123 of file EnhancedCustomShape2d.cxx.

References seqHandles.

Referenced by GetHandlePosition(), and SetHandleControllerPosition().

const tools::Rectangle& EnhancedCustomShape2d::GetLogicRect ( ) const
inline

Definition at line 192 of file EnhancedCustomShape2d.hxx.

sal_Int32 EnhancedCustomShape2d::GetLuminanceChange ( sal_uInt32  nIndex) const
private

Definition at line 1027 of file EnhancedCustomShape2d.cxx.

References nColorData.

Referenced by AdaptObjColor(), and GetColorData().

void EnhancedCustomShape2d::GetParameter ( double &  rParameterReturnValue,
const css::drawing::EnhancedCustomShapeParameter &  ,
const bool  bReplaceGeoWidth,
const bool  bReplaceGeoHeight 
) const
Point EnhancedCustomShape2d::GetPoint ( const css::drawing::EnhancedCustomShapeParameterPair &  rPair,
const bool  bScale = true,
const bool  bReplaceGeoSize = false 
) const
private
basegfx::B2DPoint EnhancedCustomShape2d::GetPointAsB2DPoint ( const css::drawing::EnhancedCustomShapeParameterPair &  rPair,
const bool  bScale = true,
const bool  bReplaceGeoSize = false 
) const
private

Definition at line 924 of file EnhancedCustomShape2d.cxx.

References fXScale, fYScale, GetParameter(), nCoordLeft, and nCoordTop.

Referenced by CreateSubPath(), and GetPoint().

SAL_DLLPRIVATE sal_Int32 EnhancedCustomShape2d::GetRotateAngle ( ) const
inline

Definition at line 186 of file EnhancedCustomShape2d.hxx.

tools::Rectangle EnhancedCustomShape2d::GetTextRect ( ) const
SAL_DLLPRIVATE bool EnhancedCustomShape2d::IsFlipHorz ( ) const
inline

Definition at line 185 of file EnhancedCustomShape2d.hxx.

SAL_DLLPRIVATE bool EnhancedCustomShape2d::IsFlipVert ( ) const
inline

Definition at line 184 of file EnhancedCustomShape2d.hxx.

bool EnhancedCustomShape2d::SetAdjustValueAsDouble ( const double &  rValue,
const sal_Int32  nIndex 
)
private

Definition at line 911 of file EnhancedCustomShape2d.cxx.

References seqAdjustmentValues.

Referenced by SetHandleControllerPosition().

void EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter ( css::drawing::EnhancedCustomShapeParameter &  rParameter,
const sal_Int32  nPara,
const bool  bIsSpecialValue,
bool  bHorz 
)
static

Definition at line 392 of file EnhancedCustomShape2d.cxx.

Referenced by lcl_ShapePropertiesFromDFF().

void EnhancedCustomShape2d::SetEnhancedCustomShapeParameter ( css::drawing::EnhancedCustomShapeParameter &  rParameter,
const sal_Int32  nValue 
)
static
bool EnhancedCustomShape2d::SetHandleControllerPosition ( const sal_uInt32  nIndex,
const css::awt::Point &  rPosition 
)

Definition at line 1467 of file EnhancedCustomShape2d.cxx.

References aLogicRect, Any, EnhancedCustomShape2d::Handle::aPolar, EnhancedCustomShape2d::Handle::aPosition, EnhancedCustomShape2d::Handle::aRadiusRangeMaximum, EnhancedCustomShape2d::Handle::aRadiusRangeMinimum, EnhancedCustomShape2d::Handle::aXRangeMaximum, EnhancedCustomShape2d::Handle::aXRangeMinimum, EnhancedCustomShape2d::Handle::aYRangeMaximum, EnhancedCustomShape2d::Handle::aYRangeMinimum, bFlipH, bFlipV, bOOXMLShape, ConvertSequenceToEnhancedCustomShape2dHandle(), basegfx::fTools::equalZero(), F_PI18000, F_PI2, fXScale, fYScale, GetAdjustValueAsDouble(), SdrTextObj::GetGeoStat(), GetHdlCount(), tools::Rectangle::GetHeight(), SdrObject::GetMergedItem(), GetParameter(), tools::Rectangle::GetWidth(), lcl_getAngleInOOXMLUnit(), lcl_getRadiusDistance(), lcl_getXAdjustmentValue(), lcl_getYAdjustmentValue(), tools::Rectangle::Left(), Point::Move(), mrSdrObjCustomShape, nCoordHeight, nCoordLeft, nCoordTop, nCoordWidth, EnhancedCustomShape2d::Handle::nFlags, EnhancedCustomShape2d::Handle::nRefAngle, EnhancedCustomShape2d::Handle::nRefR, EnhancedCustomShape2d::Handle::nRefX, EnhancedCustomShape2d::Handle::nRefY, nRotateAngle, GeoStat::nTan, POLAR, basegfx::rad2deg(), RADIUS_RANGE_MAXIMUM, RADIUS_RANGE_MINIMUM, RANGE_X_MAXIMUM, RANGE_X_MINIMUM, RANGE_Y_MAXIMUM, RANGE_Y_MINIMUM, REFANGLE, REFR, REFX, REFY, RotatePoint(), SAL_MAX_INT32, SDRATTR_CUSTOMSHAPE_GEOMETRY, seqAdjustmentValues, seqHandles, SetAdjustValueAsDouble(), SdrObject::SetMergedItem(), Point::setX(), Point::setY(), ShearPoint(), SWITCHED, tools::Rectangle::Top(), Point::X(), and Point::Y().

Referenced by EnhancedCustomShapeHandle::setControllerPosition().

void EnhancedCustomShape2d::SetPathSize ( sal_Int32  nIndex = 0)
private
void EnhancedCustomShape2d::SwapStartAndEndArrow ( SdrObject pObj)
static

Member Data Documentation

tools::Rectangle EnhancedCustomShape2d::aLogicRect
private
bool const EnhancedCustomShape2d::bFilled
private

Definition at line 120 of file EnhancedCustomShape2d.hxx.

Referenced by CreateSubPath(), and GetEnumFunc().

bool EnhancedCustomShape2d::bFlipH
private
bool EnhancedCustomShape2d::bFlipV
private
bool EnhancedCustomShape2d::bOOXMLShape
private
bool const EnhancedCustomShape2d::bStroked
private

Definition at line 121 of file EnhancedCustomShape2d.hxx.

Referenced by GetEnumFunc().

MSO_SPT EnhancedCustomShape2d::eSpType
private
double EnhancedCustomShape2d::fXRatio
private

Definition at line 92 of file EnhancedCustomShape2d.hxx.

Referenced by GetEnumFunc(), GetParameter(), and SetPathSize().

double EnhancedCustomShape2d::fXScale
private
double EnhancedCustomShape2d::fYRatio
private

Definition at line 93 of file EnhancedCustomShape2d.hxx.

Referenced by GetEnumFunc(), GetParameter(), and SetPathSize().

double EnhancedCustomShape2d::fYScale
private
SdrObjCustomShape& EnhancedCustomShape2d::mrSdrObjCustomShape
private
sal_uInt32 EnhancedCustomShape2d::nColorData
private
sal_Int32 EnhancedCustomShape2d::nCoordHeight
private
sal_Int32 EnhancedCustomShape2d::nCoordHeightG
private

Definition at line 85 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyShapeAttributes(), and SetPathSize().

sal_Int32 EnhancedCustomShape2d::nCoordLeft
private
sal_Int32 EnhancedCustomShape2d::nCoordTop
private
sal_Int32 EnhancedCustomShape2d::nCoordWidth
private
sal_Int32 EnhancedCustomShape2d::nCoordWidthG
private

Definition at line 84 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyShapeAttributes(), and SetPathSize().

sal_Int32 EnhancedCustomShape2d::nRotateAngle
private
sal_Int32 EnhancedCustomShape2d::nXRef
private

Definition at line 97 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyShapeAttributes(), GetEnumFunc(), and SetPathSize().

sal_Int32 EnhancedCustomShape2d::nYRef
private

Definition at line 98 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyShapeAttributes(), GetEnumFunc(), and SetPathSize().

css::uno::Sequence< css::drawing::EnhancedCustomShapeAdjustmentValue > EnhancedCustomShape2d::seqAdjustmentValues
private
css::uno::Sequence< css::drawing::EnhancedCustomShapeParameterPair> EnhancedCustomShape2d::seqCoordinates
private

Definition at line 113 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyShapeAttributes(), CreatePathObj(), and CreateSubPath().

css::uno::Sequence< OUString > EnhancedCustomShape2d::seqEquations
private
css::uno::Sequence< css::drawing::EnhancedCustomShapeParameterPair> EnhancedCustomShape2d::seqGluePoints
private

Definition at line 115 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyGluePoints(), and ApplyShapeAttributes().

css::uno::Sequence< css::beans::PropertyValues > EnhancedCustomShape2d::seqHandles
private
css::uno::Sequence< css::drawing::EnhancedCustomShapeSegment > EnhancedCustomShape2d::seqSegments
private

Definition at line 112 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyShapeAttributes(), CreatePathObj(), and CreateSubPath().

css::uno::Sequence< css::awt::Size > EnhancedCustomShape2d::seqSubViewSize
private

Definition at line 118 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyShapeAttributes(), and SetPathSize().

css::uno::Sequence< css::drawing::EnhancedCustomShapeTextFrame > EnhancedCustomShape2d::seqTextFrames
private

Definition at line 114 of file EnhancedCustomShape2d.hxx.

Referenced by ApplyShapeAttributes(), and GetTextRect().

std::vector< EquationResult > EnhancedCustomShape2d::vEquationResults
private

Definition at line 110 of file EnhancedCustomShape2d.hxx.

Referenced by EnhancedCustomShape2d(), and GetEquationValueAsDouble().

std::vector< std::shared_ptr< EnhancedCustomShape::ExpressionNode > > EnhancedCustomShape2d::vNodesSharedPtr
private

Definition at line 109 of file EnhancedCustomShape2d.hxx.

Referenced by EnhancedCustomShape2d(), and GetEquationValueAsDouble().


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