22 #include <osl/diagnose.h>
38 sal_Int32 nStt, sal_Int32 nEnd )
41 , m_pTextNode( nullptr )
54 const auto nWhich = rHint.
GetWhich();
59 RES_FMT_CHG != nWhich,
"sw.core",
"SwTextCharFormat::TriggerNodeUpdate: unknown hint type");
78 const sal_Int32 i_nStart,
const sal_Int32 i_nEnd )
95 sal_Int32 nStart, sal_Int32 nEnd )
99 , m_pTextNode( nullptr )
100 , m_bVisited(
false )
101 , m_bVisitedValid(
false )
129 OSL_ENSURE(
false,
"<SwTextINetFormat::GetCharFormat()> - missing character format at hyperlink attribute");
163 if (rHint.
GetId() != SfxHintId::SwLegacyModify)
166 const auto nWhich = pLegacy->
GetWhich();
169 "SwTextINetFormat::SwClientNotify: unknown hint.");
189 sal_Int32 nStart, sal_Int32 nEnd )
193 , m_pTextNode( nullptr )
204 if (rHint.
GetId() != SfxHintId::SwLegacyModify)
207 const auto nWhich = pLegacy->
GetWhich();
211 && (
RES_FMT_CHG == nWhich),
"sw.core",
"SwTextRuby::SwClientNotify(): unknown legacy hint");
229 if( !rFormat.
GetText().isEmpty() )
233 const sal_uInt16
nId = rStr.isEmpty()
249 :
const_cast<SwDoc&
>(rDoc).getIDocumentStylePoolAccess().GetCharFormatFromPool( nId );
253 const_cast<SwDoc&
>(rDoc).getIDocumentState().ResetModified();
254 const_cast<SwDoc&
>(rDoc).SetOle2Link( aOle2Lnk );
271 sal_Int32
const i_nStart,
272 sal_Int32
const i_nEnd,
273 bool const i_bIsCopy)
277 OSL_ENSURE(i_pTargetTextNode,
"cannot copy Meta without target node");
278 i_rAttr.
DoCopy(i_rTargetDocManager, *i_pTargetTextNode);
285 const sal_Int32 i_nStart,
const sal_Int32 i_nEnd )
virtual SwCharFormat * GetCharFormatFromPool(sal_uInt16 nId)=0
static SwTextMeta * CreateTextMeta(::sw::MetaFieldManager &i_rTargetDocManager, SwTextNode *const i_pTargetTextNode, SwFormatMeta &i_rAttr, sal_Int32 const i_nStart, sal_Int32 const i_nEnd, bool const i_bIsCopy)
bool GetInfo(SfxPoolItem const &rInfo) const
void Add(SwClient *pDepend)
void SetDontExpand(bool bDontExpand)
SwCharFormat * GetCharFormat()
SwTextCharFormat(SwFormatCharFormat &rAttr, sal_Int32 nStart, sal_Int32 nEnd)
sal_uInt16 GetWhich() const
virtual ~SwTextINetFormat() override
bool isCHRATR(const sal_uInt16 nWhich)
constexpr TypedWhichId< SwFormatChg > RES_FMT_CHG(162)
virtual void SwClientNotify(const SwModify &, const SfxHint &) override
void SetHasDummyChar(const bool bFlag)
void TriggerNodeUpdate(const sw::LegacyModifyHint &)
for hanging TextFormatCollections somewhere else (Outline-Numbering!)
SwTextAttrNesting(SfxPoolItem &i_rAttr, const sal_Int32 i_nStart, const sal_Int32 i_nEnd)
void SetOle2Link(const Link< bool, void > &rLink)
const SwTextNode & GetTextNode() const
Get and set TextNode pointer.
bool IsPoolUserFormat(sal_uInt16 nId)
virtual const sal_Int32 * GetEnd() const override
end position
virtual void SwClientNotify(const SwModify &, const SfxHint &) override
virtual ~SwTextRuby() override
virtual ~SwTextAttrNesting() override
void SetNesting(const bool bFlag)
A wrapper around SfxPoolItem to store the start position of (usually) a text portion, with an optional end.
IDocumentStylePoolAccess const & getIDocumentStylePoolAccess() const
const Link< bool, void > & GetOle2Link() const
bool IsVisitedURL(std::u16string_view rURL)
sal_Int32 GetStart() const
bool IsVisitedValid() const
void TriggerNodeUpdate(const sw::LegacyModifyHint &)
SwTextMeta(SwFormatMeta &i_rAttr, const sal_Int32 i_nStart, const sal_Int32 i_nEnd)
void ChgTextNode(SwTextNode *const pNode)
SwTextRuby(SwFormatRuby &rAttr, sal_Int32 nStart, sal_Int32 nEnd)
void SetVisited(bool bNew)
virtual bool IsModified() const =0
Changes of document?
void SetCharFormatAttr(bool bFlag)
constexpr TypedWhichId< SwAttrSetChg > RES_ATTRSET_CHG(163)
IDocumentState const & getIDocumentState() const
constexpr TypedWhichId< SwAutoFormatGetDocNode > RES_AUTOFMT_DOCNODE(173)
SwNodes & GetNodes()
Node is in which nodes-array/doc?
void SetVisitedValid(bool bNew)
bool IsProtect() const
Is node in something that is protected (range, frame, table cells ...
const SwTextNode & GetTextNode() const
void SetDontExpandStartAttr(bool bFlag)
SwCharFormat * FindCharFormatByName(const OUString &rName) const
SwTextNode is a paragraph in the document model.
#define SAL_WARN_IF(condition, area, stream)
virtual bool GetInfo(SfxPoolItem &rInfo) const override
SwTextINetFormat(SwFormatINetFormat &rAttr, sal_Int32 nStart, sal_Int32 nEnd)
const SfxPoolItem & GetAttr() const
virtual ~SwTextCharFormat() override
virtual bool GetInfo(SfxPoolItem &rInfo) const override
SwCharFormat * GetCharFormat()
void SetLockExpandFlag(bool bFlag)
const SwFormatRuby & GetRuby() const
constexpr TypedWhichId< SwPtrMsgPoolItem > RES_OBJECTDYING(RES_MSG_BEGIN)
const SwFormatINetFormat & GetINetFormat() const
virtual ~SwTextMeta() override
bool m_bDetectedRangeSegmentation false
virtual void ResetModified()=0