50#include <com/sun/star/frame/XModel.hpp>
51#include <com/sun/star/lang/NoSupportException.hpp>
52#include <com/sun/star/lang/WrappedTargetRuntimeException.hpp>
53#include <com/sun/star/rdf/Statement.hpp>
54#include <com/sun/star/rdf/URI.hpp>
55#include <com/sun/star/rdf/URIs.hpp>
56#include <com/sun/star/rdf/XLiteral.hpp>
57#include <com/sun/star/rdf/XRepositorySupplier.hpp>
58#include <com/sun/star/lang/DisposedException.hpp>
99 uno::Reference<uno::XInterface>
const xThis(
m_wThis);
104 lang::EventObject
const ev(xThis);
105 std::unique_lock aGuard(
m_Mutex);
111 if(rHint.
GetId() == SfxHintId::Dying)
143 xMark->m_pImpl->m_wThis = xMark.get();
150 return "SwXReferenceMark";
159uno::Sequence< OUString > SAL_CALL
163 "com.sun.star.text.TextContent",
164 "com.sun.star.text.ReferenceMark"
170template<
typename T>
struct NotContainedIn
172 std::vector<T>
const& m_rVector;
173 explicit NotContainedIn(std::vector<T>
const& rVector)
174 : m_rVector(rVector) { }
175 bool operator() (T
const& rT) {
176 return std::find(m_rVector.begin(), m_rVector.end(), rT)
195 const bool bForceExpandHints( !bMark && pCursor && pCursor->
IsAtEndOfMeta() );
201 std::vector<SwTextAttr *> oldMarks;
221 std::vector<SwTextAttr *>
const newMarks(
224 std::vector<SwTextAttr *>::const_iterator
const iter(
225 std::find_if(newMarks.begin(), newMarks.end(),
226 NotContainedIn<SwTextAttr *>(oldMarks)));
227 assert(newMarks.end() != iter);
228 if (newMarks.end() != iter)
243 throw uno::RuntimeException(
244 "SwXReferenceMark::InsertRefMark(): cannot insert attribute",
nullptr);
259 throw uno::RuntimeException();
262 OTextCursorHelper* pCursor =
dynamic_cast<OTextCursorHelper*
>(xTextRange.get());
263 SwDoc *
const pDocument =
264 pRange ? &pRange->
GetDoc() : (pCursor ? pCursor->GetDoc() :
nullptr);
267 throw lang::IllegalArgumentException();
274 m_pImpl->m_bIsDescriptor =
false;
278uno::Reference< text::XTextRange > SAL_CALL
287 if (pNewMark && (pNewMark ==
m_pImpl->m_pMarkFormat))
290 m_pImpl->m_pMarkFormat->GetTextRefMark();
296 std::optional<SwPaM> pPam;
297 if ( pTextMark->
End() )
298 pPam.emplace( rTextNode, *pTextMark->
End(),
301 pPam.emplace( rTextNode, pTextMark->
GetStart());
304 *
m_pImpl->m_pDoc, *pPam->Start(), pPam->End());
318 if (pNewMark && (pNewMark ==
m_pImpl->m_pMarkFormat))
321 m_pImpl->m_pMarkFormat->GetTextRefMark();
327 const sal_Int32 nStt = pTextMark->
GetStart();
328 const sal_Int32 nEnd = pTextMark->
End()
332 SwPaM aPam( rTextNode, nStt, rTextNode, nEnd );
333 m_pImpl->m_pDoc->getIDocumentContentOperations().DeleteAndJoin( aPam );
337 else if (
m_pImpl->m_bIsDescriptor)
344 const uno::Reference< lang::XEventListener > & xListener)
347 std::unique_lock aGuard(
m_pImpl->m_Mutex);
348 m_pImpl->m_EventListeners.addInterface(aGuard, xListener);
352 const uno::Reference< lang::XEventListener > & xListener)
355 std::unique_lock aGuard(
m_pImpl->m_Mutex);
356 m_pImpl->m_EventListeners.removeInterface(aGuard, xListener);
365 throw uno::RuntimeException();
381 ||
m_pImpl->m_pDoc->GetRefMark(rName))
383 throw uno::RuntimeException();
387 if ((rName !=
m_pImpl->m_sMarkName)
388 && pCurMark && (pCurMark ==
m_pImpl->m_pMarkFormat))
392 m_pImpl->m_pMarkFormat->GetTextRefMark();
398 const sal_Int32 nStt = pTextMark->
GetStart();
399 const sal_Int32 nEnd = pTextMark->
End()
403 SwPaM aPam( rTextNode, nStt, rTextNode, nEnd );
405 m_pImpl->m_pDoc->getIDocumentContentOperations().DeleteAndJoin( aPam );
410 m_pImpl->InsertRefMark( aPam,
nullptr );
417uno::Reference< beans::XPropertySetInfo > SAL_CALL
422 static uno::Reference< beans::XPropertySetInfo > xRef =
431 throw lang::IllegalArgumentException();
441 throw beans::UnknownPropertyException(rPropertyName);
448 const uno::Reference< beans::XPropertyChangeListener >& )
450 OSL_FAIL(
"SwXReferenceMark::addPropertyChangeListener(): not implemented");
455 const uno::Reference< beans::XPropertyChangeListener >& )
457 OSL_FAIL(
"SwXReferenceMark::removePropertyChangeListener(): not implemented");
462 const uno::Reference< beans::XVetoableChangeListener >& )
464 OSL_FAIL(
"SwXReferenceMark::addVetoableChangeListener(): not implemented");
469 const uno::Reference< beans::XVetoableChangeListener >& )
471 OSL_FAIL(
"SwXReferenceMark::removeVetoableChangeListener(): not implemented");
481 virtual void PrepareForAttach(uno::Reference< text::XTextRange > & xRange,
482 const SwPaM & rPam)
override;
484 virtual bool CheckForOwnMemberMeta(
const SwPaM & rPam,
const bool bAbsorb)
override;
488 virtual uno::Reference< text::XTextCursor >
489 CreateCursor()
override;
502 virtual uno::Sequence< sal_Int8 > SAL_CALL
503 getImplementationId()
override;
506 virtual uno::Reference< text::XTextCursor > SAL_CALL
507 createTextCursor()
override;
508 virtual uno::Reference< text::XTextCursor > SAL_CALL
509 createTextCursorByRange(
510 const uno::Reference< text::XTextRange > & xTextPosition)
override;
525 dynamic_cast<SwXText*
>(m_rMeta.GetParentText().get()));
526 return pParent ? pParent->GetStartNode() :
nullptr;
529void SwXMetaText::PrepareForAttach( uno::Reference<text::XTextRange> & xRange,
533 xRange =
static_cast<text::XWordCursor*
>(
538bool SwXMetaText::CheckForOwnMemberMeta(
const SwPaM & rPam,
const bool bAbsorb)
540 return m_rMeta.CheckForOwnMemberMeta(rPam, bAbsorb);
543uno::Reference< text::XTextCursor > SwXMetaText::CreateCursor()
545 uno::Reference< text::XTextCursor > xRet;
549 sal_Int32 nMetaStart;
552 m_rMeta.SetContentRange(pTextNode, nMetaStart, nMetaEnd) );
556 xRet =
static_cast<text::XWordCursor*
>(
563uno::Sequence<sal_Int8> SAL_CALL
564SwXMetaText::getImplementationId()
566 return css::uno::Sequence<sal_Int8>();
570uno::Reference< text::XTextCursor > SAL_CALL
571SwXMetaText::createTextCursor()
573 return CreateCursor();
576uno::Reference< text::XTextCursor > SAL_CALL
577SwXMetaText::createTextCursorByRange(
578 const uno::Reference<text::XTextRange> & xTextPosition)
580 const uno::Reference<text::XTextCursor> xCursor( CreateCursor() );
581 xCursor->gotoRange(xTextPosition,
false);
608 uno::Reference<text::XText> xParentText,
609 std::unique_ptr<TextRangeList_t const> pPortions)
614 ,
m_xText(new SwXMetaText(rDoc, rThis))
620 inline const ::sw::Meta*
GetMeta()
const;
636 m_pTextPortions.reset();
637 if(rHint.
GetId() != SfxHintId::Dying && rHint.
GetId() != SfxHintId::Deinitializing)
640 m_bIsDisposed =
true;
642 m_xText->Invalidate();
643 uno::Reference<uno::XInterface>
const xThis(m_wThis);
648 lang::EventObject
const ev(xThis);
649 std::unique_lock aGuard(m_Mutex);
650 m_EventListeners.disposeAndClear(aGuard, ev);
659 uno::Reference<text::XText>
const& xParentText,
660 std::unique_ptr<TextRangeList_t const> pPortions)
661 :
m_pImpl( new
SwXMeta::Impl(*this, *pDoc, pMeta, xParentText,
std::move(pPortions)) )
681 xMeta->m_pImpl->m_wThis = xMeta.get();
687 uno::Reference<text::XText>
const& i_xParent,
688 std::unique_ptr<TextRangeList_t const> && pPortions)
700 xMeta->m_pImpl->m_pTextPortions = std::move(pPortions);
702 if (xMeta->m_pImpl->m_xParentText.get() != i_xParent.get())
704 SAL_WARN(
"sw.uno",
"SwXMeta with different parent?");
705 xMeta->m_pImpl->m_xParentText.set(i_xParent);
713 SAL_WARN_IF(!pTextNode,
"sw.uno",
"CreateXMeta: no text node?");
714 if (!pTextNode) {
return nullptr; }
715 uno::Reference<text::XText> xParentText(i_xParent);
716 if (!xParentText.is())
719 SAL_WARN_IF(!pTextAttr,
"sw.uno",
"CreateXMeta: no text attr?");
720 if (!pTextAttr) {
return nullptr; }
721 const SwPosition aPos(*pTextNode, pTextAttr->GetStart());
724 if (!xParentText.is()) {
return nullptr; }
728 std::move(pPortions))
730 std::move(pPortions));
734 xMeta->m_pImpl->m_wThis = xMeta.get();
739 SwTextNode *& rpNode, sal_Int32 & rStart, sal_Int32 & rEnd )
const
752 rEnd = *pTextAttr->
End();
763 sal_Int32 nMetaStart;
765 const bool bSuccess(
SetContentRange(pTextNode, nMetaStart, nMetaEnd) );
766 OSL_ENSURE(bSuccess,
"no pam?");
768 throw lang::DisposedException();
771 if (&pStartPos->
GetNode() != pTextNode)
773 throw lang::IllegalArgumentException(
774 "trying to insert into a nesting text content, but start "
775 "of text range not in same paragraph as text content",
778 bool bForceExpandHints(
false);
782 if ((nStartPos < nMetaStart) || (nStartPos > nMetaEnd))
784 throw lang::IllegalArgumentException(
785 "trying to insert into a nesting text content, but start "
786 "of text range not inside text content",
789 else if (nStartPos == nMetaEnd)
791 bForceExpandHints =
true;
796 if (&pEndPos->
GetNode() != pTextNode)
798 throw lang::IllegalArgumentException(
799 "trying to insert into a nesting text content, but end "
800 "of text range not in same paragraph as text content",
806 if ((nEndPos < nMetaStart) || (nEndPos > nMetaEnd))
808 throw lang::IllegalArgumentException(
809 "trying to insert into a nesting text content, but end "
810 "of text range not inside text content",
813 else if (nEndPos == nMetaEnd)
815 bForceExpandHints =
true;
818 return bForceExpandHints;
834uno::Sequence< OUString > SAL_CALL
838 "com.sun.star.text.TextContent",
839 "com.sun.star.text.InContentMetadata"
846 uno::Reference< lang::XEventListener>
const & xListener )
849 std::unique_lock aGuard(
m_pImpl->m_Mutex);
850 m_pImpl->m_EventListeners.addInterface(aGuard, xListener);
855 uno::Reference< lang::XEventListener>
const & xListener )
858 std::unique_lock aGuard(
m_pImpl->m_Mutex);
859 m_pImpl->m_EventListeners.removeInterface(aGuard, xListener);
869 m_pImpl->m_pTextPortions.reset();
871 std::unique_lock aGuard(
m_pImpl->m_Mutex);
872 m_pImpl->m_EventListeners.disposeAndClear(aGuard, ev);
874 m_pImpl->m_xText->Invalidate();
876 else if (!
m_pImpl->m_bIsDisposed)
879 sal_Int32 nMetaStart;
882 OSL_ENSURE(bSuccess,
"no pam?");
886 SwPaM aPam( *pTextNode, nMetaStart - 1, *pTextNode, nMetaEnd );
891 assert(
m_pImpl->m_bIsDisposed);
898 const sal_uInt16 i_nWhich)
904 throw lang::DisposedException();
908 throw uno::RuntimeException(
909 "SwXMeta::attach(): already attached",
914 OTextCursorHelper *
const pCursor(
dynamic_cast<OTextCursorHelper*
>(i_xTextRange.get()));
915 if (!pRange && !pCursor)
917 throw lang::IllegalArgumentException(
918 "SwXMeta::attach(): argument not supported type",
923 pRange ? &pRange->
GetDoc() : pCursor->GetDoc());
926 throw lang::IllegalArgumentException(
927 "SwXMeta::attach(): argument has no SwDoc",
938 const bool bForceExpandHints(pTextCursor && pTextCursor->
IsAtEndOfMeta());
944 const std::shared_ptr< ::sw::Meta> pMeta( (
RES_TXTATR_META == i_nWhich)
945 ? std::make_shared< ::sw::Meta>(
nullptr )
946 : std::shared_ptr< ::sw::Meta>(
950 SwTextAttr *
const pTextAttr( pMeta->GetTextAttr() );
953 throw lang::IllegalArgumentException(
954 "SwXMeta::attach(): cannot create meta: range invalid?",
959 OSL_FAIL(
"meta inserted, but has no text attribute?");
960 throw uno::RuntimeException(
961 "SwXMeta::attach(): cannot create meta",
966 m_pImpl->m_pMeta = pMeta.get();
967 m_pImpl->StartListening(pMeta->GetNotifier());
968 pMeta->SetXMeta(
this);
972 m_pImpl->m_bIsDescriptor =
false;
982uno::Reference< text::XTextRange > SAL_CALL
989 throw lang::DisposedException();
993 throw uno::RuntimeException(
994 "SwXMeta::getAnchor(): not inserted",
999 sal_Int32 nMetaStart;
1001 const bool bSuccess(
SetContentRange(pTextNode, nMetaStart, nMetaEnd));
1002 OSL_ENSURE(bSuccess,
"no pam?");
1005 throw lang::DisposedException(
1006 "SwXMeta::getAnchor(): not attached",
1016uno::Reference< text::XText > SAL_CALL
1022uno::Reference< text::XTextRange > SAL_CALL
1026 return m_pImpl->m_xText->getStart();
1029uno::Reference< text::XTextRange > SAL_CALL
1033 return m_pImpl->m_xText->getEnd();
1040 return m_pImpl->m_xText->getString();
1047 return m_pImpl->m_xText->setString(rString);
1051uno::Reference< text::XTextCursor > SAL_CALL
1055 return m_pImpl->m_xText->createTextCursor();
1058uno::Reference< text::XTextCursor > SAL_CALL
1060 const uno::Reference<text::XTextRange> & xTextPosition)
1063 return m_pImpl->m_xText->createTextCursorByRange(xTextPosition);
1068 const OUString& rString,
sal_Bool bAbsorb)
1071 return m_pImpl->m_xText->insertString(xRange, rString, bAbsorb);
1076 sal_Int16 nControlCharacter,
sal_Bool bAbsorb)
1079 return m_pImpl->m_xText->insertControlCharacter(xRange, nControlCharacter,
1086 const uno::Reference<text::XTextContent> & xContent,
sal_Bool bAbsorb)
1089 return m_pImpl->m_xText->insertTextContent(xRange, xContent, bAbsorb);
1094 const uno::Reference< text::XTextContent > & xContent)
1097 return m_pImpl->m_xText->removeTextContent(xContent);
1101uno::Reference< uno::XInterface > SAL_CALL
1106 sal_Int32 nMetaStart;
1108 bool const bSuccess(
SetContentRange(pTextNode, nMetaStart, nMetaEnd) );
1109 OSL_ENSURE(bSuccess,
"no pam?");
1110 if (!bSuccess) {
throw lang::DisposedException(); }
1114 uno::Reference<text::XTextContent>
const xRet(
1123 throw lang::NoSupportException(
"setting parent not supported", *
this);
1136 return m_pImpl->m_pMeta !=
nullptr;
1140uno::Reference< container::XEnumeration > SAL_CALL
1147 throw lang::DisposedException();
1151 throw uno::RuntimeException(
1152 "createEnumeration(): not inserted",
1157 sal_Int32 nMetaStart;
1159 const bool bSuccess(
SetContentRange(pTextNode, nMetaStart, nMetaEnd));
1160 OSL_ENSURE(bSuccess,
"no pam?");
1162 throw lang::DisposedException();
1164 SwPaM aPam(*pTextNode, nMetaStart);
1166 if (!
m_pImpl->m_pTextPortions)
1192 return pShell ? pShell->
GetModel() :
nullptr;
1204 uno::Reference<text::XText>
const& xParentText,
1205 std::unique_ptr<TextRangeList_t const> pPortions)
1208 assert(
dynamic_cast< ::
sw::MetaField*
>(pMeta) &&
"SwXMetaField created for wrong hint!");
1224 return "SwXMetaField";
1233uno::Sequence< OUString > SAL_CALL
1237 "com.sun.star.text.TextContent",
1238 "com.sun.star.text.TextField",
1239 "com.sun.star.text.textfield.MetadataField"
1246 uno::Reference< lang::XEventListener>
const & xListener )
1253 uno::Reference< lang::XEventListener>
const & xListener )
1271uno::Reference< text::XTextRange > SAL_CALL
1278uno::Reference< beans::XPropertySetInfo > SAL_CALL
1283 static uno::Reference< beans::XPropertySetInfo > xRef(
1291 const OUString& rPropertyName,
const uno::Any& rValue)
1298 throw lang::DisposedException();
1300 if ( rPropertyName ==
"NumberFormat" )
1302 sal_Int32 nNumberFormat(0);
1303 if (rValue >>= nNumberFormat)
1308 else if ( rPropertyName ==
"IsFixedLanguage" )
1318 throw beans::UnknownPropertyException(rPropertyName);
1329 throw lang::DisposedException();
1333 if ( rPropertyName ==
"NumberFormat" )
1338 else if ( rPropertyName ==
"IsFixedLanguage" )
1344 throw beans::UnknownPropertyException(rPropertyName);
1353 const uno::Reference< beans::XPropertyChangeListener >& )
1355 OSL_FAIL(
"SwXMetaField::addPropertyChangeListener(): not implemented");
1361 const uno::Reference< beans::XPropertyChangeListener >& )
1363 OSL_FAIL(
"SwXMetaField::removePropertyChangeListener(): not implemented");
1369 const uno::Reference< beans::XVetoableChangeListener >& )
1371 OSL_FAIL(
"SwXMetaField::addVetoableChangeListener(): not implemented");
1377 const uno::Reference< beans::XVetoableChangeListener >& )
1379 OSL_FAIL(
"SwXMetaField::removeVetoableChangeListener(): not implemented");
1382static uno::Reference<rdf::XURI>
const&
1385 static uno::Reference< uno::XComponentContext > xContext(
1386 ::comphelper::getProcessComponentContext());
1387 static uno::Reference< rdf::XURI > xOdfPrefix(
1388 rdf::URI::createKnown(xContext, rdf::URIs::ODF_PREFIX),
1389 uno::UNO_SET_THROW);
1390 static uno::Reference< rdf::XURI > xOdfSuffix(
1391 rdf::URI::createKnown(xContext, rdf::URIs::ODF_SUFFIX),
1392 uno::UNO_SET_THROW);
1393 static uno::Reference< rdf::XURI > xOdfShading(
1394 rdf::URI::createKnown(xContext, rdf::URIs::LO_EXT_SHADING),
1395 uno::UNO_SET_THROW);
1398 case rdf::URIs::ODF_PREFIX:
1400 case rdf::URIs::ODF_SUFFIX:
1409 uno::Reference<rdf::XRepository>
const & xRepository,
1410 uno::Reference<rdf::XResource>
const & xMetaField,
1411 uno::Reference<rdf::XURI>
const & xPredicate)
1413 const uno::Reference<container::XEnumeration> xEnum(
1414 xRepository->getStatements(xMetaField, xPredicate,
nullptr),
1415 uno::UNO_SET_THROW);
1416 while (xEnum->hasMoreElements()) {
1417 rdf::Statement stmt;
1418 if (!(xEnum->nextElement() >>= stmt)) {
1419 throw uno::RuntimeException();
1421 const uno::Reference<rdf::XLiteral> xObject(stmt.Object,
1423 if (!xObject.is())
continue;
1424 if (xEnum->hasMoreElements()) {
1425 SAL_INFO(
"sw.uno",
"ignoring other odf:Prefix/odf:Suffix statements");
1427 return xObject->getValue();
1434 const uno::Reference<frame::XModel>& xModel,
1435 const uno::Reference<rdf::XMetadatable>& xMetaField,
1436 OUString *
const o_pPrefix, OUString *
const o_pSuffix, OUString *
const o_pShadingColor)
1439 const uno::Reference<rdf::XRepositorySupplier> xRS(
1440 xModel, uno::UNO_QUERY_THROW);
1441 const uno::Reference<rdf::XRepository> xRepo(
1442 xRS->getRDFRepository(), uno::UNO_SET_THROW);
1443 const uno::Reference<rdf::XResource> xMeta(
1444 xMetaField, uno::UNO_QUERY_THROW);
1453 if (o_pShadingColor)
1457 }
catch (uno::RuntimeException &) {
1459 }
catch (
const uno::Exception &) {
1461 throw lang::WrappedTargetRuntimeException(
"getPrefixAndSuffix: exception",
nullptr, anyEx);
1483 return prefix + content + suffix;
virtual bool DeleteAndJoin(SwPaM &, SwDeleteFlags flags=SwDeleteFlags::Default)=0
complete delete of a given PaM
virtual bool InsertPoolItem(const SwPaM &rRg, const SfxPoolItem &, const SetAttrMode nFlags=SetAttrMode::DEFAULT, SwRootFrame const *pLayout=nullptr, SwTextAttr **ppNewTextAttr=nullptr)=0
Insert an attribute.
css::uno::Reference< css::beans::XPropertySetInfo > const & getPropertySetInfo() const
css::uno::Reference< css::frame::XModel3 > GetModel() const
bool StartListening(SvtBroadcaster &rBroadcaster)
IDocumentContentOperations const & getIDocumentContentOperations() const
::sw::MetaFieldManager & GetMetaFieldManager()
SwDocShell * GetDocShell()
SwTextNode * GetTextNode()
Inline methods from Node.hxx.
SwNodes & GetNodes()
Node is in which nodes-array/doc?
PaM is Point and Mark: a selection of the document model.
const SwPosition * GetMark() const
SwNode & GetPointNode() const
const SwPosition * End() const
const SwPosition * GetPoint() const
const SwPosition * Start() const
bool HasMark() const
A PaM marks a selection if Point and Mark are distinct positions.
Starts a section of nodes in the document model.
A wrapper around SfxPoolItem to store the start position of (usually) a text portion,...
const SwFormatRefMark & GetRefMark() const
const sal_Int32 * End() const
sal_Int32 GetStart() const
SwTextNode is a paragraph in the document model.
std::vector< SwTextAttr * > GetTextAttrsAt(sal_Int32 const nIndex, sal_uInt16 const nWhich) const
get the innermost text attributes covering position nIndex.
SwTextAttr * GetTextAttrForCharAt(const sal_Int32 nIndex, const sal_uInt16 nWhich=RES_TXTATR_END) const
get the text attribute at position nIndex which owns the dummy character CH_TXTATR_* at that position...
const SwTextNode & GetTextNode() const
const SfxItemPropertySet * GetPropertySet(sal_uInt16 PropertyId)
unotools::WeakReference< SwXReferenceMark > m_wThis
void InsertRefMark(SwPaM &rPam, SwXTextCursor const *const pCursor)
Impl(SwDoc *const pDoc, SwFormatRefMark *const pRefMark)
virtual void Notify(const SfxHint &) override
const SwFormatRefMark * m_pMarkFormat
::comphelper::OInterfaceContainerHelper4< css::lang::XEventListener > m_EventListeners
virtual OUString SAL_CALL getName() override
virtual css::uno::Reference< css::text::XTextRange > SAL_CALL getAnchor() override
virtual ~SwXReferenceMark() override
virtual void SAL_CALL setName(const OUString &rName) override
virtual void SAL_CALL setPropertyValue(const OUString &rPropertyName, const css::uno::Any &rValue) override
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
virtual void SAL_CALL dispose() override
static rtl::Reference< SwXReferenceMark > CreateXReferenceMark(SwDoc &rDoc, SwFormatRefMark *pMarkFormat)
virtual void SAL_CALL removePropertyChangeListener(const OUString &rPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &xListener) override
::sw::UnoImplPtr< Impl > m_pImpl
virtual void SAL_CALL removeEventListener(const css::uno::Reference< css::lang::XEventListener > &xListener) override
virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo() override
SwXReferenceMark(SwDoc *const pDoc, SwFormatRefMark *const pMark)
virtual void SAL_CALL removeVetoableChangeListener(const OUString &rPropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &xListener) override
virtual void SAL_CALL addEventListener(const css::uno::Reference< css::lang::XEventListener > &xListener) override
virtual void SAL_CALL attach(const css::uno::Reference< css::text::XTextRange > &xTextRange) override
virtual void SAL_CALL addPropertyChangeListener(const OUString &rPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &xListener) override
virtual sal_Bool SAL_CALL supportsService(const OUString &rServiceName) override
virtual css::uno::Any SAL_CALL getPropertyValue(const OUString &rPropertyName) override
virtual OUString SAL_CALL getImplementationName() override
virtual void SAL_CALL addVetoableChangeListener(const OUString &rPropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &xListener) override
bool IsAtEndOfMeta() const
void disposeAndClear(::std::unique_lock<::std::mutex > &rGuard, const css::lang::EventObject &rEvt)
virtual void SAL_CALL acquire() SAL_NOEXCEPT SAL_OVERRIDE
virtual void SAL_CALL release() SAL_NOEXCEPT SAL_OVERRIDE
css::uno::Type const & get()
static SwNode * GetStartNode(SwOutlineNodes const *pOutlNds, int nOutlineLevel, SwOutlineNodes::size_type *nOutl)
constexpr TypedWhichId< SwFormatMeta > RES_TXTATR_METAFIELD(49)
constexpr TypedWhichId< SwFormatRefMark > RES_TXTATR_REFMARK(RES_TXTATR_WITHEND_BEGIN)
constexpr TypedWhichId< SwFormatMeta > RES_TXTATR_META(48)
#define SAL_WARN_IF(condition, area, stream)
#define SAL_WARN(area, stream)
#define SAL_INFO(area, stream)
uno::Reference< text::XTextContent > GetNestedTextContent(SwTextNode const &rTextNode, sal_Int32 const nIndex, bool const bParent)
OUString getString(const Any &_rAny)
bool CPPUHELPER_DLLPUBLIC supportsService(css::lang::XServiceInfo *implementation, rtl::OUString const &name)
Any SAL_CALL getCaughtException()
uno::Reference< text::XText > CreateParentXText(SwDoc &rDoc, const SwPosition &rPos)
bool XTextRangeToSwPaM(SwUnoInternalPaM &rToFill, const uno::Reference< text::XTextRange > &xTextRange, ::sw::TextRangeMode const eMode)
bool GetDefaultTextContentValue(css::uno::Any &rAny, std::u16string_view rPropertyName, sal_uInt16 nWID=0)
Marks a position in the document model.
sal_Int32 GetContentIndex() const
Reference< XModel > xModel
@ FORCEHINTEXPAND
Force hint expand (only matters for hints with CH_TXTATR).
SwUnoPropertyMapProvider aSwMapProvider
#define PROPERTY_MAP_PARAGRAPH_EXTENSIONS
#define PROPERTY_MAP_METAFIELD
static OUString lcl_getPrefixOrSuffix(uno::Reference< rdf::XRepository > const &xRepository, uno::Reference< rdf::XResource > const &xMetaField, uno::Reference< rdf::XURI > const &xPredicate)
void getPrefixAndSuffix(const uno::Reference< frame::XModel > &xModel, const uno::Reference< rdf::XMetadatable > &xMetaField, OUString *const o_pPrefix, OUString *const o_pSuffix, OUString *const o_pShadingColor)
static uno::Reference< rdf::XURI > const & lcl_getURI(const sal_Int16 eKnown)