LibreOffice Module sw (master) 1
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
SwXMLTextImportHelper Class Reference

#include <xmltexti.hxx>

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

Public Member Functions

 SwXMLTextImportHelper (const css::uno::Reference< css::frame::XModel > &rModel, SvXMLImport &rImport, const css::uno::Reference< css::beans::XPropertySet > &rInfoSet, bool bInsertM, bool bStylesOnlyM, bool bBlockM, bool bOrganizerM)
 
virtual ~SwXMLTextImportHelper () override
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertOLEObject (SvXMLImport &rImport, const OUString &rHRef, const OUString &rStyleName, const OUString &rTableName, sal_Int32 nWidth, sal_Int32 nHeight) override
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertOOoLink (SvXMLImport &rImport, const OUString &rHRef, const OUString &rStyleName, const OUString &rTableName, sal_Int32 nWidth, sal_Int32 nHeight) override
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertApplet (const OUString &rName, const OUString &rCode, bool bMayScript, const OUString &rHRef, sal_Int32 nWidth, sal_Int32 nHeight) override
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertPlugin (const OUString &rMimeType, const OUString &rHRef, sal_Int32 nWidth, sal_Int32 nHeight) override
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertFloatingFrame (const OUString &rName, const OUString &rHRef, const OUString &rStyleName, sal_Int32 nWidth, sal_Int32 nHeight) override
 
virtual void endAppletOrPlugin (const css::uno::Reference< css::beans::XPropertySet > &rPropSet, std::map< const OUString, OUString > &rParamMap) override
 
virtual bool IsInHeaderFooter () const override
 
virtual void RedlineAdd (const OUString &rType, const OUString &rId, const OUString &rAuthor, const OUString &rComment, const css::util::DateTime &rDateTime, bool bMergeLastPara) override
 
virtual css::uno::Reference< css::text::XTextCursor > RedlineCreateText (css::uno::Reference< css::text::XTextCursor > &rOldCursor, const OUString &rId) override
 merge last paragraph More...
 
virtual void RedlineSetCursor (const OUString &rId, bool bStart, bool bIsOutsideOfParagraph) override
 ID used to RedlineAdd() call. More...
 
virtual void RedlineAdjustStartNodeCursor () override
 
virtual void SetShowChanges (bool bShowChanges) override
 
virtual void SetRecordChanges (bool bRecordChanges) override
 
virtual void SetChangesProtectionKey (const css::uno::Sequence< sal_Int8 > &rKey) override
 
- Public Member Functions inherited from XMLTextImportHelper
 XMLTextImportHelper (css::uno::Reference< css::frame::XModel > const &rModel, SvXMLImport &rImport, bool const bInsertMode=false, bool const bStylesOnlyMode=false, bool const bProgress=false, bool const bBlockMode=false, bool const bOrganizerMode=false)
 
virtual ~XMLTextImportHelper () override
 
void dispose ()
 
void SetCursor (const css::uno::Reference< css::text::XTextCursor > &rCursor)
 
void ResetCursor ()
 
void SetAutoStyles (SvXMLStylesContext *pStyles)
 
SvXMLImportContextCreateTextChildContext (SvXMLImport &rImport, sal_Int32 nElement, const css::uno::Reference< css::xml::sax::XFastAttributeList > &xAttrList, XMLTextType eType=XMLTextType::Shape)
 
css::uno::Reference< css::text::XText > & GetText ()
 
css::uno::Reference< css::text::XTextCursor > & GetCursor ()
 
css::uno::Reference< css::text::XTextRange > & GetCursorAsRange ()
 
bool IsInsertMode () const
 
bool IsStylesOnlyMode () const
 
bool IsBlockMode () const
 
bool IsOrganizerMode () const
 
bool IsProgress () const
 
OUString ConvertStarFonts (const OUString &rChars, const OUString &rStyleName, sal_uInt8 &rFlags, bool bPara, SvXMLImport &rImport) const
 
void InsertString (const OUString &rChars)
 
void InsertString (std::u16string_view rChars, bool &rIgnoreLeadingSpace)
 
void DeleteParagraph ()
 
void InsertControlCharacter (sal_Int16 nControl)
 
void InsertTextContent (css::uno::Reference< css::text::XTextContent > const &xContent)
 
OUString SetStyleAndAttrs (SvXMLImport const &rImport, const css::uno::Reference< css::text::XTextCursor > &rCursor, const OUString &rStyleName, bool bPara, bool bOutlineLevelAttrFound=false, sal_Int8 nOutlineLevel=-1, bool bSetListAttrs=true, bool bOutlineContentVisible=true)
 
void FindOutlineStyleName (OUString &rStyleName, sal_Int8 nOutlineLevel)
 
void AddOutlineStyleCandidate (const sal_Int8 nOutlineLevel, const OUString &rStyleName)
 
void SetOutlineStyles (bool bSetEmpty)
 
void SetHyperlink (SvXMLImport const &rImport, const css::uno::Reference< css::text::XTextCursor > &rCursor, const OUString &rHRef, const OUString &rName, const OUString &rTargetFrameName, const OUString &rStyleName, const OUString &rVisitedStyleName, XMLEventsImportContext *pEvents)
 
void SetRuby (SvXMLImport const &rImport, const css::uno::Reference< css::text::XTextCursor > &rCursor, const OUString &rStyleName, const OUString &rTextStyleName, const OUString &rText)
 
sal_Int32 GetDataStyleKey (const OUString &sStyleName, bool *pIsSystemLanguage=nullptr)
 
const SvxXMLListStyleContextFindAutoListStyle (const OUString &rName) const
 
XMLPropStyleContextFindAutoFrameStyle (const OUString &rName) const
 
XMLPropStyleContextFindSectionStyle (const OUString &rName) const
 
XMLPropStyleContextFindPageMaster (const OUString &rName) const
 
XMLPropStyleContextFindAutoCharStyle (const OUString &rName) const
 
XMLPropStyleContextFindDrawingPage (OUString const &rName) const
 
const css::uno::Reference< css::container::XNameContainer > & GetParaStyles () const
 
const css::uno::Reference< css::container::XNameContainer > & GetTextStyles () const
 
const css::uno::Reference< css::container::XNameContainer > & GetNumberingStyles () const
 
const css::uno::Reference< css::container::XNameContainer > & GetFrameStyles () const
 
const css::uno::Reference< css::container::XNameContainer > & GetPageStyles () const
 
const css::uno::Reference< css::container::XNameContainer > & GetCellStyles () const
 
const css::uno::Reference< css::container::XIndexReplace > & GetChapterNumbering () const
 
bool HasFrameByName (const OUString &rName) const
 
bool IsDuplicateFrame (const OUString &sName, sal_Int32 nX, sal_Int32 nY, sal_Int32 nWidth, sal_Int32 nHeight) const
 
void StoreLastImportedFrameName (const OUString &rName)
 
void ClearLastImportedTextFrameName ()
 
void ConnectFrameChains (const OUString &rFrmName, const OUString &rNextFrmName, const css::uno::Reference< css::beans::XPropertySet > &rFrmPropSet)
 
rtl::Reference< SvXMLImportPropertyMapper > const & GetParaImportPropertySetMapper () const
 
rtl::Reference< SvXMLImportPropertyMapper > const & GetTextImportPropertySetMapper () const
 
rtl::Reference< SvXMLImportPropertyMapper > const & GetSectionImportPropertySetMapper () const
 
rtl::Reference< SvXMLImportPropertyMapper > const & GetRubyImportPropertySetMapper () const
 
SvI18NMapGetRenameMap ()
 
void InsertBookmarkStartRange (const OUString &sName, const css::uno::Reference< css::text::XTextRange > &rRange, OUString const &i_rXmlId, std::shared_ptr< ::xmloff::ParsedRDFaAttributes > &i_rpRDFaAttributes)
 
bool FindAndRemoveBookmarkStartRange (const OUString &sName, css::uno::Reference< css::text::XTextRange > &o_rRange, OUString &o_rXmlId, std::shared_ptr< ::xmloff::ParsedRDFaAttributes > &o_rpRDFaAttributes)
 
void pushFieldCtx (const OUString &name, const OUString &type)
 
css::uno::Reference< css::text::XFormField > popFieldCtx ()
 
void addFieldParam (const OUString &name, const OUString &value)
 
void setCurrentFieldParamsTo (css::uno::Reference< css::text::XFormField > const &xFormField)
 
::std::pair< OUString, OUString > getCurrentFieldType () const
 
css::uno::Reference< css::text::XTextRange > getCurrentFieldStart () const
 
bool hasCurrentFieldSeparator () const
 
bool hasCurrentFieldCtx () const
 
void InsertFootnoteID (const OUString &sXMLId, sal_Int16 nAPIId)
 
void ProcessFootnoteReference (const OUString &sXMLId, const css::uno::Reference< css::beans::XPropertySet > &xPropSet)
 
void InsertSequenceID (const OUString &sXMLId, const OUString &sName, sal_Int16 nAPIId)
 
void ProcessSequenceReference (const OUString &sXMLId, const css::uno::Reference< css::beans::XPropertySet > &xPropSet)
 
bool IsInFrame () const
 
virtual bool IsInHeaderFooter () const
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertOLEObject (SvXMLImport &rImport, const OUString &rHRef, const OUString &rStyleName, const OUString &rTblName, sal_Int32 nWidth, sal_Int32 nHeight)
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertOOoLink (SvXMLImport &rImport, const OUString &rHRef, const OUString &rStyleName, const OUString &rTblName, sal_Int32 nWidth, sal_Int32 nHeight)
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertApplet (const OUString &rName, const OUString &rCode, bool bMayScript, const OUString &rHRef, sal_Int32 nWidth, sal_Int32 nHeight)
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertPlugin (const OUString &rMimeType, const OUString &rHRef, sal_Int32 nWidth, sal_Int32 nHeight)
 
virtual css::uno::Reference< css::beans::XPropertySetcreateAndInsertFloatingFrame (const OUString &rName, const OUString &rHRef, const OUString &rStyleName, sal_Int32 nWidth, sal_Int32 nHeight)
 
virtual void endAppletOrPlugin (const css::uno::Reference< css::beans::XPropertySet > &rPropSet, ::std::map< const OUString, OUString > &rParamMap)
 
virtual void RedlineAdd (const OUString &rType, const OUString &rId, const OUString &rAuthor, const OUString &rComment, const css::util::DateTime &rDateTime, bool bMergeLastParagraph)
 
virtual css::uno::Reference< css::text::XTextCursor > RedlineCreateText (css::uno::Reference< css::text::XTextCursor > &rOldCursor, const OUString &rId)
 
virtual void RedlineSetCursor (const OUString &rId, bool bStart, bool bIsOutsideOfParagraph)
 
virtual void RedlineAdjustStartNodeCursor ()
 
virtual void SetShowChanges (bool bShowChanges)
 
virtual void SetRecordChanges (bool bRecordChanges)
 
virtual void SetChangesProtectionKey (const css::uno::Sequence< sal_Int8 > &rProtectionKey)
 
OUString const & GetOpenRedlineId () const
 
void SetOpenRedlineId (OUString const &rId)
 
void ResetOpenRedlineId ()
 
void SetInsideDeleteContext (bool const bNew)
 
bool IsInsideDeleteContext () const
 
SvXMLImport & GetXMLImport ()
 
XMLTextListsHelperGetTextListHelper ()
 
void PushListContext ()
 
void PopListContext ()
 
void SetCellParaStyleDefault (OUString const &rNewValue)
 
OUString const & GetCellParaStyleDefault () const
 
void AddCrossRefHeadingMapping (OUString const &rFrom, OUString const &rTo)
 
void MapCrossRefHeadingFieldsHorribly ()
 
void setBookmarkAttributes (OUString const &bookmark, bool hidden, OUString const &condition)
 
bool getBookmarkHidden (OUString const &bookmark) const
 
const OUString & getBookmarkCondition (OUString const &bookmark) const
 

Protected Member Functions

virtual SvXMLImportContextCreateTableChildContext (SvXMLImport &rImport, sal_Int32 nElement, const css::uno::Reference< css::xml::sax::XFastAttributeList > &xAttrList) override
 
- Protected Member Functions inherited from XMLTextImportHelper
virtual SvXMLImportContextCreateTableChildContext (SvXMLImport &rImport, sal_Int32 nElement, const css::uno::Reference< css::xml::sax::XFastAttributeList > &xAttrList)
 
XMLPropertyBackpatcher< sal_Int16 > & GetFootnoteBP ()
 
XMLPropertyBackpatcher< sal_Int16 > & GetSequenceIdBP ()
 
XMLPropertyBackpatcher< OUString > & GetSequenceNameBP ()
 

Private Attributes

XMLRedlineImportHelperm_pRedlineHelper
 

Additional Inherited Members

- Static Public Member Functions inherited from XMLTextImportHelper
static SvXMLImportPropertyMapperCreateShapeExtPropMapper (SvXMLImport &)
 
static SvXMLImportPropertyMapperCreateParaExtPropMapper (SvXMLImport &)
 
static SvXMLImportPropertyMapperCreateParaDefaultExtPropMapper (SvXMLImport &)
 
static SvXMLImportPropertyMapperCreateTableDefaultExtPropMapper (SvXMLImport &)
 
static SvXMLImportPropertyMapperCreateTableRowDefaultExtPropMapper (SvXMLImport &)
 
static SvXMLImportPropertyMapperCreateTableCellExtPropMapper (SvXMLImport &)
 
static SvXMLImportPropertyMapperCreateDrawingPageExtPropMapper (SvXMLImport &)
 

Detailed Description

Definition at line 27 of file xmltexti.hxx.

Constructor & Destructor Documentation

◆ SwXMLTextImportHelper()

SwXMLTextImportHelper::SwXMLTextImportHelper ( const css::uno::Reference< css::frame::XModel > &  rModel,
SvXMLImport &  rImport,
const css::uno::Reference< css::beans::XPropertySet > &  rInfoSet,
bool  bInsertM,
bool  bStylesOnlyM,
bool  bBlockM,
bool  bOrganizerM 
)

Definition at line 136 of file xmltexti.cxx.

References m_pRedlineHelper.

◆ ~SwXMLTextImportHelper()

SwXMLTextImportHelper::~SwXMLTextImportHelper ( )
overridevirtual

Definition at line 151 of file xmltexti.cxx.

References m_pRedlineHelper.

Member Function Documentation

◆ createAndInsertApplet()

uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertApplet ( const OUString &  rName,
const OUString &  rCode,
bool  bMayScript,
const OUString &  rHRef,
sal_Int32  nWidth,
sal_Int32  nHeight 
)
overridevirtual

◆ createAndInsertFloatingFrame()

uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertFloatingFrame ( const OUString &  rName,
const OUString &  rHRef,
const OUString &  rStyleName,
sal_Int32  nWidth,
sal_Int32  nHeight 
)
overridevirtual

◆ createAndInsertOLEObject()

uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertOLEObject ( SvXMLImport &  rImport,
const OUString &  rHRef,
const OUString &  rStyleName,
const OUString &  rTableName,
sal_Int32  nWidth,
sal_Int32  nHeight 
)
overridevirtual

Reimplemented from XMLTextImportHelper.

Definition at line 195 of file xmltexti.cxx.

References aBuffer, aName, Any, aServiceMap, comphelper::EmbeddedObjectContainer::CreateUniqueObjectName(), SwXTextEmbeddedObject::CreateXTextEmbeddedObject(), CTF_OLE_DRAW_ASPECT, CTF_OLE_VIS_AREA_HEIGHT, CTF_OLE_VIS_AREA_LEFT, CTF_OLE_VIS_AREA_TOP, CTF_OLE_VIS_AREA_WIDTH, XMLTextImportHelper::FindAutoFrameStyle(), SwIterator< TElementType, TSource, eMode >::First(), Get(), SwDoc::GetAttrPool(), SvGlobalName::GetByteSequence(), SwFormat::GetContent(), SwFormatContent::GetContentIdx(), SwOLEObj::GetCurrentPersistName(), XMLTextImportHelper::GetCursor(), SwDoc::GetDfltGrfFormatColl(), IDocumentDrawModelAccess::GetDrawModel(), comphelper::EmbeddedObjectContainer::GetEmbeddedObject(), SfxObjectShell::GetEmbeddedObjectContainer(), SvXMLStyleContext::GetFamily(), SwDoc::getIDocumentContentOperations(), SwDoc::getIDocumentDrawModelAccess(), SvXMLStylesContext::GetImportPropertyMapper(), SwNodeIndex::GetIndex(), SwNodeIndex::GetNodes(), SwOLEObj::GetObject(), SwNode::GetOLENode(), SwOLENode::GetOLEObj(), SwDoc::GetPersist(), XMLPropStyleContext::GetProperties(), XMLTextImportHelper::GetRenameMap(), tools::Rectangle::GetSize(), SfxObjectShell::GetStorage(), XMLPropStyleContext::GetStyles(), comphelper::OStorageHelper::GetTemporaryStorage(), XMLTextImportHelper::GetXMLImport(), i, comphelper::InitPropertySequence(), IDocumentContentOperations::InsertEmbObject(), IDocumentContentOperations::InsertOLE(), XMLTextImportHelper::IsInsertMode(), lcl_GetOLENode(), lcl_putHeightAndWidth(), lcl_setObjectVisualArea(), XMLPropertyState::maValue, XMLPropertyState::mnIndex, nCount, SwIterator< TElementType, TSource, eMode >::Next(), nPos, SAL_WARN_IF, SwOLENode::SetChartTableName(), tools::Rectangle::setHeight(), SwOLENode::SetOLESizeInvalid(), tools::Rectangle::SetPosX(), tools::Rectangle::SetPosY(), svt::EmbeddedObjectRef::SetViewAspect(), tools::Rectangle::setWidth(), xFactory, and XML_TEXT_RENAME_TYPE_TABLE.

◆ createAndInsertOOoLink()

uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertOOoLink ( SvXMLImport &  rImport,
const OUString &  rHRef,
const OUString &  rStyleName,
const OUString &  rTableName,
sal_Int32  nWidth,
sal_Int32  nHeight 
)
overridevirtual

◆ createAndInsertPlugin()

uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertPlugin ( const OUString &  rMimeType,
const OUString &  rHRef,
sal_Int32  nWidth,
sal_Int32  nHeight 
)
overridevirtual

◆ CreateTableChildContext()

SvXMLImportContext * SwXMLTextImportHelper::CreateTableChildContext ( SvXMLImport &  rImport,
sal_Int32  nElement,
const css::uno::Reference< css::xml::sax::XFastAttributeList > &  xAttrList 
)
overrideprotectedvirtual

Reimplemented from XMLTextImportHelper.

Definition at line 165 of file xmltexti.cxx.

◆ endAppletOrPlugin()

void SwXMLTextImportHelper::endAppletOrPlugin ( const css::uno::Reference< css::beans::XPropertySet > &  rPropSet,
std::map< const OUString, OUString > &  rParamMap 
)
overridevirtual

◆ IsInHeaderFooter()

bool SwXMLTextImportHelper::IsInHeaderFooter ( ) const
overridevirtual

Reimplemented from XMLTextImportHelper.

Definition at line 173 of file xmltexti.cxx.

References XMLTextImportHelper::GetCursor(), SwDoc::IsInHeaderFooter(), and SAL_WARN_IF.

◆ RedlineAdd()

void SwXMLTextImportHelper::RedlineAdd ( const OUString &  rType,
const OUString &  rId,
const OUString &  rAuthor,
const OUString &  rComment,
const css::util::DateTime &  rDateTime,
bool  bMergeLastPara 
)
overridevirtual
Parameters
rIdredline type (insert, del,... )
rAuthoruse to identify this redline
rCommentname of the author
rDateTimeredline comment
bMergeLastParadate+time

Reimplemented from XMLTextImportHelper.

Definition at line 924 of file xmltexti.cxx.

References XMLRedlineImportHelper::Add(), and m_pRedlineHelper.

◆ RedlineAdjustStartNodeCursor()

void SwXMLTextImportHelper::RedlineAdjustStartNodeCursor ( )
overridevirtual

◆ RedlineCreateText()

uno::Reference< XTextCursor > SwXMLTextImportHelper::RedlineCreateText ( css::uno::Reference< css::text::XTextCursor > &  rOldCursor,
const OUString &  rId 
)
overridevirtual

merge last paragraph

Parameters
rIdneeded to get the document

Reimplemented from XMLTextImportHelper.

Definition at line 939 of file xmltexti.cxx.

References XMLRedlineImportHelper::CreateRedlineTextSection(), and m_pRedlineHelper.

◆ RedlineSetCursor()

void SwXMLTextImportHelper::RedlineSetCursor ( const OUString &  rId,
bool  bStart,
bool  bIsOutsideOfParagraph 
)
overridevirtual

ID used to RedlineAdd() call.

Parameters
bStartID used to RedlineAdd() call
bIsOutsideOfParagraphstart or end Cursor

Reimplemented from XMLTextImportHelper.

Definition at line 953 of file xmltexti.cxx.

References XMLTextImportHelper::GetCursor(), m_pRedlineHelper, and XMLRedlineImportHelper::SetCursor().

◆ SetChangesProtectionKey()

void SwXMLTextImportHelper::SetChangesProtectionKey ( const css::uno::Sequence< sal_Int8 > &  rKey)
overridevirtual

Reimplemented from XMLTextImportHelper.

Definition at line 989 of file xmltexti.cxx.

References m_pRedlineHelper, and XMLRedlineImportHelper::SetProtectionKey().

◆ SetRecordChanges()

void SwXMLTextImportHelper::SetRecordChanges ( bool  bRecordChanges)
overridevirtual

Reimplemented from XMLTextImportHelper.

Definition at line 983 of file xmltexti.cxx.

References m_pRedlineHelper, and XMLRedlineImportHelper::SetRecordChanges().

◆ SetShowChanges()

void SwXMLTextImportHelper::SetShowChanges ( bool  bShowChanges)
overridevirtual

Reimplemented from XMLTextImportHelper.

Definition at line 977 of file xmltexti.cxx.

References m_pRedlineHelper, and XMLRedlineImportHelper::SetShowChanges().

Member Data Documentation

◆ m_pRedlineHelper

XMLRedlineImportHelper* SwXMLTextImportHelper::m_pRedlineHelper
private

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