22#include <osl/diagnose.h>
52 const OUString& rMimeType,
const uno::Any & rValue )
56 OSL_ENSURE(
false,
"DataChanged without ContentNode" );
74 if( rValue.
hasValue() && ( rValue >>= sState ))
77 switch( sState.toInt32() )
96 bool bFrameInPaint =
false;
104 assert(pSwGrfNode &&
"Error, pSwGrfNode expected when node answers IsGrfNode() with true (!)");
116 ( GraphicType::Default != aGrf.
GetType() ||
117 GraphicType::Default != rGrfObj.
GetType() ) )
137 if ( !bUpdate || bFrameInPaint )
150 std::unique_ptr<CurrShell> pCurr;
154 Size aSz = rOrigGrfSize;
161 if (
nullptr != pFormat)
182 if( rOldAttr.
GetSize() != aCalcSz )
197 if (pAnchorNode &&
nullptr != (pTableNd = pAnchorNode->
FindTableNode()))
204 const sal_uInt16 nBrowseWidth =
208 pLayout->
Resize( nBrowseWidth,
true,
true,
242 if( bWaitForData && !
GetObj() )
244 OSL_ENSURE(
false,
"The SvxFileObject was deleted in a GetData!" );
275 SvBaseLink::Closed();
288 ((RndStdIds::FLY_AS_CHAR == rAnchor.
GetAnchorId()) ||
289 (RndStdIds::FLY_AT_CHAR == rAnchor.
GetAnchorId()) ||
290 (RndStdIds::FLY_AT_FLY == rAnchor.
GetAnchorId()) ||
291 (RndStdIds::FLY_AT_PARA == rAnchor.
GetAnchorId())))
299 OSL_ENSURE(
false,
"GetAnchor is not shadowed" );
310 return aRef->IsLinkInServer( pChkLnk );
GraphicType GetType() const
GraphicType GetType() const
virtual const SwViewShell * GetCurrentViewShell() const =0
Returns the layout set at the document.
virtual sfx2::LinkManager & GetLinkManager()=0
constexpr tools::Long Height() const
tools::Long AdjustHeight(tools::Long n)
void setWidth(tools::Long nWidth)
tools::Long AdjustWidth(tools::Long n)
void setHeight(tools::Long nHeight)
constexpr tools::Long Width() const
static OUString GetFormatMimeType(SotClipboardFormatId nFormat)
static SotClipboardFormatId GetFormatIdFromMimeType(std::u16string_view rMimeType)
sal_Int16 CalcLineSpace(SvxBoxItemLine nLine, bool bEvenIfNoLine=false, bool bAllowNegative=false) const
const Size & GetSize() const
void SetSize(const Size &rSize)
virtual void Closed() override
bool SwapIn(bool bWaitForData=false, bool bNativFormat=false)
SwContentNode * m_pContentNode
virtual bool IsInRange(SwNodeOffset nSttNd, SwNodeOffset nEndNd) const
bool IsRecursion(const SwBaseLink *pChkLnk) const
virtual ~SwBaseLink() override
virtual const SwNode * GetAnchor() const
virtual ::sfx2::SvBaseLink::UpdateResult DataChanged(const OUString &rMimeType, const css::uno::Any &rValue) override
sal_uInt16 CallEvent(SvMacroItemId nEvent, const SwCallMouseEvent &rCallEvent, bool bChkPtr=false)
IDocumentLinksAdministration const & getIDocumentLinksAdministration() const
SwEditShell const * GetEditShell() const
IDocumentLayoutAccess const & getIDocumentLayoutAccess() const
virtual Size GetTwipSize() const override
void SetGraphic(const Graphic &rGraphic)
isolated only way to set GraphicObject to allow more actions when doing so
void SetTwipSize(const Size &rSz)
const GraphicObject & GetGrfObj(bool bWait=false) const
bool IsChgTwipSize() const
bool IsFrameInPaint() const
void TriggerGraphicArrived()
bool Resize(sal_uInt16 nAbsAvail, bool bRecalc=false, bool bForce=false, sal_uLong nDelay=0)
Recalculation of table widths for available width that has been passed.
sal_uInt16 GetBrowseWidthByTable(const SwDoc &rDoc) const
Calculates available width by the table-frame or static GetBrowseWidth if no layout exists.
Base class of the Writer document model elements.
SwFrameFormat * GetFlyFormat() const
If node is in a fly return the respective format.
bool IsNoTextNode() const
SwTableNode * FindTableNode()
Search table node, in which it is.
const SwTable & GetTable() const
sal_uInt16 DecGrfsThatResize()
SwHTMLTableLayout * GetHTMLTableLayout()
static SotClipboardFormatId RegisterStatusInfoId()
bool GetGraphicFromAny(std::u16string_view rMimeType, const css::uno::Any &rValue, Graphic &rGrf, weld::Window *pParentWin)
void SetSynchron(bool bFlag)
SotClipboardFormatId GetContentType() const
SvLinkSource * GetObj() const
void GetRealObject_(bool bConnect=true)
virtual bool GetData(css::uno::Any &rData, const OUString &rMimeType, bool bSynchron=false)
weld::Window * GetFrameWeld(const SfxFrame *pFrame)
#define HTMLTABLE_RESIZE_NOW
const sal_Unicode *const aMimeType[]
void Set(SwCallEventObjectType eTyp, const SwFrameFormat *pFormat)
static bool SetGrfFlySize(const Size &rGrfSz, SwGrfNode *pGrfNd, const Size &rOrigGrfSize)
Size GetGraphicSizeTwip(const Graphic &rGraphic, vcl::RenderContext *pOutDev)