28#include <tools/datetime.hxx>
36#include <com/sun/star/drawing/TextFitToSizeType.hpp>
60 class SdrContourTextPrimitive2D;
61 class SdrPathTextPrimitive2D;
62 class SdrBlockTextPrimitive2D;
63 class SdrAutoFitTextPrimitive2D;
64 class SdrStretchTextPrimitive2D;
65 class SdrChainedTextPrimitive2D;
69 class AnimationEntryList;
73 class ViewInformation2D;
78 class SdrTableRtfExporter;
79 class SdrTableRTFParser;
112 virtual std::unique_ptr<SdrObjUserData>
Clone(
SdrObject* pObj1)
const override;
117 class CustomShapeProperties;
118 class CellProperties;
127 friend class sdr::table::Cell;
145 return mpEditingOutliner;
177 maRectangle = rRectangle;
187 maRectangle.
Move(nXDelta, nYDelta);
231 bool mbIsUnchainableClone =
false;
270 SVX_DLLPRIVATE void ImpSetupDrawOutlinerForPaint(
bool bContourFrame,
276 void ImpAutoFitText(
SdrOutliner& rOutliner )
const;
277 void ImpAutoFitText(
SdrOutliner& rOutliner,
const Size& rShapeSize,
bool bIsVerticalWriting )
const;
278 void autoFitTextForCompatibility(
SdrOutliner& rOutliner,
const Size& rShapeSize,
bool bIsVerticalWriting)
const;
286 static void AppendFamilyToStyleName(OUString& styleName,
SfxStyleFamily family);
289 static SfxStyleFamily ReadFamilyFromStyleName(std::u16string_view styleName);
292 bool ImpCanConvTextToCurve()
const;
295 void ImpSetTextStyleSheetListeners();
296 static void ImpSetCharStretching(
SdrOutliner& rOutliner,
const Size& rTextSize,
const Size& rShapeSize,
Fraction& rFitXCorrection);
298 void ImpCheckShear();
300 void ImpSetTextEditParams()
const;
306 virtual std::unique_ptr<SdrObjGeoData>
NewGeoData()
const override;
314 virtual void AdaptTextMinSize();
350 void SetTextLink(
const OUString& rFileName,
const OUString& rFilterName);
351 void ReleaseTextLink();
352 bool IsLinkedText()
const {
return m_pPlusData !=
nullptr && GetLinkUserData() !=
nullptr; }
353 bool ReloadLinkedText(
bool bForceLoad);
354 bool LoadText(
const OUString& rFileName, rtl_TextEncoding eCharSet);
356 virtual bool AdjustTextFrameWidthAndHeight(
tools::Rectangle& rR,
bool bHgt =
true,
bool bWdt =
true)
const;
357 virtual bool NbcAdjustTextFrameWidthAndHeight(
bool bHgt =
true,
bool bWdt =
true);
358 virtual bool AdjustTextFrameWidthAndHeight();
362 bool IsAutoFit()
const;
364 bool IsFitToSize()
const;
370 bool IsChainable()
const;
371 bool GetPreventChainable()
const;
377 virtual bool HasText()
const override;
382 virtual SdrText* getActiveText()
const;
391 virtual bool IsReallyEdited()
const;
394 virtual void setActiveText( sal_Int32 nIndex );
397 virtual sal_Int32 CheckTextHit(
const Point& rPnt)
const;
400 void NbcSetText(
const OUString& rStr);
401 void SetText(
const OUString& rStr);
407 void FitFrameToTextSize();
409 double GetFontScale()
const;
410 double GetSpacingScale()
const;
423 virtual bool IsAutoGrowHeight()
const;
426 virtual bool IsAutoGrowWidth()
const;
430 css::drawing::TextFitToSizeType GetFitToSize()
const;
434 virtual bool IsFontwork()
const;
437 bool IsHideContour()
const;
440 bool IsContourTextFrame()
const;
459 bool HasTextColumnsNumber()
const;
460 sal_Int16 GetTextColumnsNumber()
const;
461 void SetTextColumnsNumber(sal_Int16 nColumns);
462 bool HasTextColumnsSpacing()
const;
463 sal_Int32 GetTextColumnsSpacing()
const;
464 void SetTextColumnsSpacing(sal_Int32 nSpacing);
521 bool CanCreateEditOutlinerParaObject()
const;
526 virtual bool CalcFieldValue(
const SvxFieldItem& rField, sal_Int32 nPara, sal_uInt16 nPos,
527 bool bEdit, std::optional<Color>& rpTxtColor, std::optional<Color>& rpFldColor, std::optional<FontLineStyle>& rpFldLineStyle, OUString& rRet)
const;
565 virtual bool IsVerticalWriting()
const;
566 virtual void SetVerticalWriting(
bool bVertical);
567 bool IsTopToBottom()
const;
570 virtual void onEditOutlinerStatusEvent(
EditStatus* pEditStatus );
573 void onChainingEvent();
594 void RemoveOutlinerCharacterAttribs(
const std::vector<sal_uInt16>& rCharWhichIds );
601 void SetTextAnimationAllowed(
bool bNew);
606 void SetObjectItemNoBroadcast(
const SfxPoolItem& rItem);
607 double GetCameraZRotation()
const;
612 void impDecomposeContourTextPrimitive(
616 void impDecomposePathTextPrimitive(
620 void impDecomposeBlockTextPrimitive(
624 void impDecomposeAutoFitTextPrimitive(
628 void impDecomposeStretchTextPrimitive(
632 void impDecomposeChainedTextPrimitive(
636 void impHandleChainingEventsDuringDecomposition(
SdrOutliner &rOutliner)
const;
644 static void impDecomposeBlockTextPrimitiveDirect(
655 static bool HasTextImpl(
SdrOutliner const * pOutliner );
659 friend class ::SdrTextObjTest;
The transformation of a rectangle into a polygon, by using angle parameters from GeoStat.
virtual std::unique_ptr< SdrObjUserData > Clone(SdrObject *pObj1) const override
rtl_TextEncoding meCharSet
tools::SvRef< ImpSdrObjTextLink > mpLink
ImpSdrObjTextLinkUserData()
virtual ~ImpSdrObjTextLinkUserData() override
virtual std::unique_ptr< sdr::properties::BaseProperties > CreateObjectSpecificProperties() override
All geometrical data of an arbitrary object for use in undo/redo.
User data of a drawing object, e.g.
virtual bool BckCreate(SdrDragStat &rStat)
virtual void RecalcSnapRect()
Snap is not done on the BoundRect but if possible on logic coordinates (i.e.
virtual Degree100 GetShearAngle(bool bVertical=false) const
virtual rtl::Reference< SdrObject > DoConvertToPolyObj(bool bBezier, bool bAddText) const
virtual Degree100 GetRotateAngle() const
virtual bool HasText() const
virtual void NbcSetOutlinerParaObject(std::optional< OutlinerParaObject > pTextObject)
virtual rtl::Reference< SdrObject > getFullDragClone() const
virtual void NbcSetLogicRect(const tools::Rectangle &rRect)
virtual void NbcResize(const Point &rRef, const Fraction &xFact, const Fraction &yFact)
virtual OUString TakeObjNamePlural() const
virtual bool BegCreate(SdrDragStat &rStat)
Every object must be able to create itself interactively.
virtual basegfx::B2DPolyPolygon TakeXorPoly() const
The Xor-Polygon is required by the View to drag the object.
virtual void RestoreGeoData(const SdrObjGeoData &rGeo)
virtual basegfx::B2DPolyPolygon TakeCreatePoly(const SdrDragStat &rDrag) const
Polygon dragged by the user when creating the object.
virtual OutlinerParaObject * GetOutlinerParaObject() const
virtual sal_uInt32 GetSnapPointCount() const
snap to special points of an Object (polygon points, center of circle)
virtual void handlePageChange(SdrPage *pOldPage, SdrPage *pNewPage)
virtual void SaveGeoData(SdrObjGeoData &rGeo) const
virtual bool MovCreate(SdrDragStat &rStat)
virtual void NbcSetSnapRect(const tools::Rectangle &rRect)
virtual void NbcMirror(const Point &rRef1, const Point &rRef2)
virtual void NbcShear(const Point &rRef, Degree100 nAngle, double tn, bool bVShear)
virtual std::unique_ptr< sdr::contact::ViewContact > CreateObjectSpecificViewContact()
virtual bool HasTextEdit() const
virtual void TRSetBaseGeometry(const basegfx::B2DHomMatrix &rMatrix, const basegfx::B2DPolyPolygon &rPolyPolygon)
virtual PointerStyle GetCreatePointer() const
get the cursor/pointer that signals creating this object
virtual OUString getSpecialDragComment(const SdrDragStat &rDrag) const
virtual SdrObjKind GetObjIdentifier() const
virtual rtl::Reference< SdrObject > CloneSdrObject(SdrModel &rTargetModel) const =0
virtual sal_uInt32 GetHdlCount() const
Via GetHdlCount the number of Handles can be retrieved.
virtual basegfx::B2DPolyPolygon TakeContour() const
contour for TextToContour
virtual void NbcReformatText()
virtual OUString TakeObjNameSingul() const
virtual void AddToHdlList(SdrHdlList &rHdlList) const
virtual bool applySpecialDrag(SdrDragStat &rDrag)
virtual bool EndCreate(SdrDragStat &rStat, SdrCreateCmd eCmd)
virtual void BrkCreate(SdrDragStat &rStat)
tools::Rectangle ImpDragCalcRect(const SdrDragStat &rDrag) const
virtual bool hasSpecialDrag() const
The standard transformations (Move,Resize,Rotate,Mirror,Shear) are taken over by the View (TakeXorPol...
virtual std::unique_ptr< SdrObjGeoData > NewGeoData() const
A derived class must override these 3 methods if it has own geometric data that must be saved for Und...
virtual Point GetSnapPoint(sal_uInt32 i) const
virtual bool TRGetBaseGeometry(basegfx::B2DHomMatrix &rMatrix, basegfx::B2DPolyPolygon &rPolyPolygon) const
virtual void NbcMove(const Size &rSiz)
The methods Move, Resize, Rotate, Mirror, Shear, SetSnapRect and SetLogicRect call the corresponding ...
virtual void TakeObjInfo(SdrObjTransformInfoRec &rInfo) const
virtual const tools::Rectangle & GetLogicRect() const
virtual void NbcRotate(const Point &rRef, Degree100 nAngle, double sn, double cs)=0
A SdrPage contains exactly one SdrObjList and a description of the physical page dimensions (size / m...
void SetTextEditOutliner(SdrOutliner *pOutl)
const Point & GetTextEditOffset() const
tools::Rectangle const & getRectangle() const
bool IsTextEditActive() const
void moveRectangle(sal_Int32 nXDelta, sal_Int32 nYDelta)
void SetTextEditOffset(const Point &rNew)
bool IsInEditMode() const
SdrOutliner * mpEditingOutliner
void moveRectanglePosition(sal_Int32 nX, sal_Int32 nY)
tools::Rectangle maRectangle
bool mbTextAnimationAllowed
rtl::Reference< SdrText > mxText
bool IsLinkedText() const
bool mbDisableAutoWidthOnDragging
SdrObjKind GetTextKind() const
virtual bool IsSdrTextObj() const final
void setRectangleSize(sal_Int32 nWidth, sal_Int32 nHeight)
const GeoStat & GetGeoStat() const
void SetDisableAutoWidthOnDragging(bool bOn)
SVX_DLLPRIVATE SdrOutliner * GetTextEditOutliner() const
void setRectangle(tools::Rectangle const &rRectangle)
void ForceOutlinerParaObject(OutlinerMode nOutlMode)
This interface provides access to text object(s) in an SdrObject.
virtual sal_Int32 getTextCount() const =0
Return the number of texts available for this object.
virtual SdrText * getText(sal_Int32 nIndex) const =0
Return the nth available text.
virtual void SetText(const OUString &rStr) override
TextVerticalAdjust GetTextVerticalAdjust(sal_Int32 nToken)
float GetTextSize(std::u16string_view sValue)
SdrTextAniKind
Animation type for text frame.
@ OutlineText
TitleText, special text object for StarDraw.
constexpr const sal_uInt16 SDRUSERDATA_OBJTEXTLINK
#define SVXCORE_DLLPUBLIC