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

#include <fldmgr.hxx>

Collaboration diagram for SwFieldMgr:
[legend]

Public Member Functions

 SwFieldMgr (SwWrtShell *pSh=nullptr)
 
 ~SwFieldMgr ()
 
void SetWrtShell (SwWrtShell *pShell)
 
bool InsertField (SwInsertField_Data &rData)
 
void UpdateCurField (sal_uInt32 nFormat, const OUString &rPar1, const OUString &rPar2, std::unique_ptr< SwField > _pField=nullptr)
 
const OUString & GetCurFieldPar1 () const
 
const OUString & GetCurFieldPar2 () const
 
SwFieldGetCurField ()
 
void InsertFieldType (SwFieldType const &rType)
 
bool ChooseMacro (weld::Window *pDialogParent)
 
void SetMacroPath (const OUString &rPath)
 
const OUString & GetMacroPath () const
 
const OUString & GetMacroName () const
 
bool GoNextPrev (bool bNext=true, SwFieldType *pTyp=nullptr)
 
bool GoNext ()
 
bool GoPrev ()
 
bool IsDBNumeric (const OUString &rDBName, const OUString &rTableQryName, bool bIsTable, const OUString &rFieldName)
 
bool CanInsertRefMark (std::u16string_view rStr)
 
size_t GetFieldTypeCount () const
 
SwFieldTypeGetFieldType (SwFieldIds nResId, size_t nField=0) const
 
SwFieldTypeGetFieldType (SwFieldIds nResId, const OUString &rName) const
 
void RemoveFieldType (SwFieldIds nResId, const OUString &rName)
 
SwFieldTypesEnum GetCurTypeId () const
 
void GetSubTypes (SwFieldTypesEnum nId, std::vector< OUString > &rToFill)
 
sal_uInt16 GetFormatCount (SwFieldTypesEnum nTypeId, bool bHtmlMode) const
 
OUString GetFormatStr (SwFieldTypesEnum nTypeId, sal_uInt32 nFormatId) const
 
sal_uInt16 GetFormatId (SwFieldTypesEnum nTypeId, sal_uInt32 nFormatId) const
 
sal_uInt32 GetDefaultFormat (SwFieldTypesEnum nTypeId, bool bIsText, SvNumberFormatter *pFormatter)
 
void SetEvalExpFields (bool bEval)
 
void EvalExpFields (SwWrtShell *pSh)
 

Static Public Member Functions

static const SwFieldGroupRgnGetGroupRange (bool bHtmlMode, sal_uInt16 nGrpId)
 
static sal_uInt16 GetGroup (SwFieldTypesEnum nTypeId, sal_uInt16 nSubType)
 
static SwFieldTypesEnum GetTypeId (sal_uInt16 nPos)
 
static const OUString & GetTypeStr (sal_uInt16 nPos)
 
static sal_uInt16 GetPos (SwFieldTypesEnum nTypeId)
 

Private Member Functions

SAL_DLLPRIVATE LanguageType GetCurrLanguage () const
 
SAL_DLLPRIVATE css::uno::Reference< css::text::XNumberingTypeInfo > const & GetNumberingInfo () const
 

Private Attributes

SwFieldm_pCurField
 
SwWrtShellm_pWrtShell
 
OUString m_aCurPar1
 
OUString m_aCurPar2
 
OUString m_sCurFrame
 
OUString m_sMacroPath
 
OUString m_sMacroName
 
sal_uInt32 m_nCurFormat
 
bool m_bEvalExp
 
css::uno::Reference< css::text::XNumberingTypeInfo > m_xNumberingInfo
 

Detailed Description

Definition at line 100 of file fldmgr.hxx.

Constructor & Destructor Documentation

◆ SwFieldMgr()

SwFieldMgr::SwFieldMgr ( SwWrtShell pSh = nullptr)
explicit

Definition at line 368 of file fldmgr.cxx.

References GetCurField().

◆ ~SwFieldMgr()

SwFieldMgr::~SwFieldMgr ( )

Definition at line 376 of file fldmgr.cxx.

Member Function Documentation

◆ CanInsertRefMark()

bool SwFieldMgr::CanInsertRefMark ( std::u16string_view  rStr)

Definition at line 381 of file fldmgr.cxx.

References SwCursorShell::GetCursorCnt(), SwEditShell::GetRefMark(), lcl_GetShell(), and m_pWrtShell.

Referenced by InsertField().

◆ ChooseMacro()

bool SwFieldMgr::ChooseMacro ( weld::Window pDialogParent)

Definition at line 1849 of file fldmgr.cxx.

References SfxApplication::ChooseScript(), and SetMacroPath().

◆ EvalExpFields()

void SwFieldMgr::EvalExpFields ( SwWrtShell pSh)

◆ GetCurField()

SwField * SwFieldMgr::GetCurField ( )

◆ GetCurFieldPar1()

const OUString & SwFieldMgr::GetCurFieldPar1 ( ) const
inline

Definition at line 136 of file fldmgr.hxx.

Referenced by SwFieldVarPage::SubTypeHdl().

◆ GetCurFieldPar2()

const OUString & SwFieldMgr::GetCurFieldPar2 ( ) const
inline

Definition at line 137 of file fldmgr.hxx.

Referenced by SwFieldVarPage::SubTypeHdl().

◆ GetCurrLanguage()

LanguageType SwFieldMgr::GetCurrLanguage ( ) const
private

◆ GetCurTypeId()

SwFieldTypesEnum SwFieldMgr::GetCurTypeId ( ) const

Definition at line 889 of file fldmgr.cxx.

References SwField::GetTypeId(), m_pCurField, and Unknown.

Referenced by SwTextShell::Execute().

◆ GetDefaultFormat()

sal_uInt32 SwFieldMgr::GetDefaultFormat ( SwFieldTypesEnum  nTypeId,
bool  bIsText,
SvNumberFormatter pFormatter 
)

Definition at line 1889 of file fldmgr.cxx.

References Date, GetCurrLanguage(), SvNumberFormatter::GetStandardFormat(), and Time.

Referenced by SwTextShell::ExecField().

◆ GetFieldType() [1/2]

SwFieldType * SwFieldMgr::GetFieldType ( SwFieldIds  nResId,
const OUString &  rName 
) const

Definition at line 422 of file fldmgr.cxx.

References SwEditShell::GetFieldType(), lcl_GetShell(), and m_pWrtShell.

◆ GetFieldType() [2/2]

SwFieldType * SwFieldMgr::GetFieldType ( SwFieldIds  nResId,
size_t  nField = 0 
) const

◆ GetFieldTypeCount()

size_t SwFieldMgr::GetFieldTypeCount ( ) const

Definition at line 408 of file fldmgr.cxx.

References SwEditShell::GetFieldTypeCount(), lcl_GetShell(), and m_pWrtShell.

Referenced by SwView::InsertCaption().

◆ GetFormatCount()

sal_uInt16 SwFieldMgr::GetFormatCount ( SwFieldTypesEnum  nTypeId,
bool  bHtmlMode 
) const

◆ GetFormatId()

sal_uInt16 SwFieldMgr::GetFormatId ( SwFieldTypesEnum  nTypeId,
sal_uInt32  nFormatId 
) const

◆ GetFormatStr()

OUString SwFieldMgr::GetFormatStr ( SwFieldTypesEnum  nTypeId,
sal_uInt32  nFormatId 
) const

◆ GetGroup()

sal_uInt16 SwFieldMgr::GetGroup ( SwFieldTypesEnum  nTypeId,
sal_uInt16  nSubType 
)
static

◆ GetGroupRange()

const SwFieldGroupRgn & SwFieldMgr::GetGroupRange ( bool  bHtmlMode,
sal_uInt16  nGrpId 
)
static

◆ GetMacroName()

const OUString & SwFieldMgr::GetMacroName ( ) const
inline

Definition at line 147 of file fldmgr.hxx.

◆ GetMacroPath()

const OUString & SwFieldMgr::GetMacroPath ( ) const
inline

Definition at line 146 of file fldmgr.hxx.

Referenced by SwFieldFuncPage::FillItemSet(), and SwFieldFuncPage::UpdateSubType().

◆ GetNumberingInfo()

Reference< XNumberingTypeInfo > const & SwFieldMgr::GetNumberingInfo ( ) const
private

Definition at line 1917 of file fldmgr.cxx.

References m_xNumberingInfo.

Referenced by GetFormatCount().

◆ GetPos()

sal_uInt16 SwFieldMgr::GetPos ( SwFieldTypesEnum  nTypeId)
static

◆ GetSubTypes()

void SwFieldMgr::GetSubTypes ( SwFieldTypesEnum  nId,
std::vector< OUString > &  rToFill 
)

◆ GetTypeId()

SwFieldTypesEnum SwFieldMgr::GetTypeId ( sal_uInt16  nPos)
static

◆ GetTypeStr()

const OUString & SwFieldMgr::GetTypeStr ( sal_uInt16  nPos)
static

◆ GoNext()

bool SwFieldMgr::GoNext ( )
inline

Definition at line 151 of file fldmgr.hxx.

Referenced by SwFieldEditDlg::Init().

◆ GoNextPrev()

bool SwFieldMgr::GoNextPrev ( bool  bNext = true,
SwFieldType pTyp = nullptr 
)

◆ GoPrev()

bool SwFieldMgr::GoPrev ( )
inline

Definition at line 152 of file fldmgr.hxx.

Referenced by SwFieldEditDlg::Init().

◆ InsertField()

bool SwFieldMgr::InsertField ( SwInsertField_Data rData)

Definition at line 895 of file fldmgr.cxx.

References aEntries, Author, Authority, CanInsertRefMark(), Chapter, Chars, SwWrtShell::ChgDBData(), CombinedChars, ConditionalText, sfx2::cTokenSeparator, Database, DatabaseName, DatabaseNextSet, DatabaseNumberSet, DatabaseSetNumber, Date, DATE_VAR, DATEFLD, DateTime, DB_DELIM, DbNextSet, DbNumSet, DbSetNumber, DDE, IDocumentContentOperations::DeleteAndJoin(), SwCursorShell::DeleteCurrent, SwPaM::DeleteMark(), DocInfo, DocStat, DocumentInfo, DocumentStatistics, Dropdown, SwCursorShell::EndAction(), SwEditShell::EndAllAction(), ExtendedUser, ExtUser, Filename, FIXEDFLD, FMT_REF_ARY, FN_NUMBER_FORMAT, fnMoveBackward, fnMoveForward, Formel, Get, SwViewShell::GetAttrPool(), SwDBManager::GetColumnFormat(), SwUserFieldType::GetContent(), GetCurrLanguage(), SwCursorShell::GetCursor(), SwEditShell::GetDBData(), SwEditShell::GetDBManager(), SfxViewFrame::GetDispatcher(), SwViewShell::GetDoc(), SvNumberFormatter::GetEntry(), GetExp, SwEditShell::GetFieldType(), SvNumberformat::GetFormatstring(), SwFEShell::GetFrameType(), SvtUserOptions::GetID(), SwDoc::getIDocumentContentOperations(), SwPaM::GetMark(), SwEditShell::GetNumberFormatter(), SwDoc::GetNumberFormatter(), SwPaM::GetPoint(), GetRef, GetRefPage, o3tl::getToken(), comphelper::string::getTokenCount(), SwSetExpFieldType::GetType(), SwWrtShell::GetView(), SfxViewShell::GetViewFrame(), SwViewShell::GetViewOptions(), GoInContent(), nsSwGetSetExpType::GSE_FORMULA, nsSwGetSetExpType::GSE_SEQ, HiddenPara, HiddenParagraph, HiddenText, INP_VAR, Input, SwWrtShell::InsertField2(), SwEditShell::InsertFieldType(), SwEditShell::InsertURL(), Internet, SwViewOption::IsFieldName(), JumpEdit, LANGUAGE_HUNGARIAN, lcl_GetShell(), SwWrtShell::Left(), SwInsertField_Data::m_aDBColumn, SwInsertField_Data::m_aDBConnection, SwInsertField_Data::m_aDBDataSource, m_bEvalExp, SwInsertField_Data::m_bIsAutomaticLanguage, SwInsertField_Data::m_cSeparator, SwInsertField_Data::m_nFormatId, SwInsertField_Data::m_nSubType, SwInsertField_Data::m_nTypeId, SwInsertField_Data::m_oAnnotationRange, SwInsertField_Data::m_pParent, SwInsertField_Data::m_pSh, m_pWrtShell, m_sCurFrame, SwInsertField_Data::m_sPar1, SwInsertField_Data::m_sPar2, Macro, MAXLEVEL, min(), SwPaM::Move(), SwDBData::nCommandType, NextPage, nIndex, nLang, nPos, nTablePos, nToken, PageNumber, ParagraphSignature, SwTranslateHelper::PasteHTMLToPaM(), PG_NEXT, PG_PREV, PG_RANDOM, SwWrtShell::Pop(), Postit, PreviousPage, SwCursorShell::Push(), SfxItemSet::Put(), RefPageGet, RefPageSet, SwWrtShell::Right(), SAL_N_ELEMENTS, SwDBData::sCommand, Script, SwDBData::sDataSource, Sequence, Set, SwEditShell::SetAttrItem(), SwUserFieldType::SetContent(), SwSetExpFieldType::SetDelimiter(), SetExp, SwPaM::SetMark(), SwSetExpFieldType::SetOutlineLvl(), SetRef, SetRefPage, SwEditShell::SetTableBoxFormulaAttrs(), sFormula, SwEditShell::SignParagraph(), IDocumentContentOperations::SplitNode(), SwCursorShell::StartAction(), SwEditShell::StartAllAction(), SwWrtShell::StartInputFieldDlg(), comphelper::string::stripStart(), nsSwExtendedSubType::SUB_INVISIBLE, nsSwExtendedSubType::SUB_OWN_FMT, SVX_NUM_CHAR_SPECIAL, DateTime::SYSTEM, TABLE, TableOfAuthorities, TemplateName, Time, TIMEFLD, o3tl::toInt32(), type, SwEditShell::UpdateExpFields(), SwFieldType::UpdateFields(), SwEditShell::UpdateOneField(), SwEditShell::UpdateTable(), User, and xColumn.

Referenced by SwTextShell::ExecDB(), SwTextShell::ExecField(), SwTextShell::Execute(), IMPL_LINK_NOARG(), SwMailMergeLayoutPage::InsertAddressFrame(), SwFieldPage::InsertField(), SwMailMergeLayoutPage::InsertGreeting(), InsertLabEnvText(), SwWrtShell::InsertPostIt(), and lcl_InsertLabText().

◆ InsertFieldType()

void SwFieldMgr::InsertFieldType ( SwFieldType const &  rType)

Definition at line 880 of file fldmgr.cxx.

References SwEditShell::InsertFieldType(), lcl_GetShell(), and m_pWrtShell.

Referenced by SwView::InsertCaption().

◆ IsDBNumeric()

bool SwFieldMgr::IsDBNumeric ( const OUString &  rDBName,
const OUString &  rTableQryName,
bool  bIsTable,
const OUString &  rFieldName 
)

◆ RemoveFieldType()

void SwFieldMgr::RemoveFieldType ( SwFieldIds  nResId,
const OUString &  rName 
)

Definition at line 400 of file fldmgr.cxx.

References lcl_GetShell(), m_pWrtShell, and SwEditShell::RemoveFieldType().

◆ SetEvalExpFields()

void SwFieldMgr::SetEvalExpFields ( bool  bEval)
inline

Definition at line 199 of file fldmgr.hxx.

References m_bEvalExp.

◆ SetMacroPath()

void SwFieldMgr::SetMacroPath ( const OUString &  rPath)

Definition at line 1866 of file fldmgr.cxx.

References m_sMacroName, m_sMacroPath, and xFactory.

Referenced by ChooseMacro(), and SwFieldFuncPage::Reset().

◆ SetWrtShell()

void SwFieldMgr::SetWrtShell ( SwWrtShell pShell)
inline

Definition at line 124 of file fldmgr.hxx.

Referenced by SwFieldPage::SetWrtShell().

◆ UpdateCurField()

void SwFieldMgr::UpdateCurField ( sal_uInt32  nFormat,
const OUString &  rPar1,
const OUString &  rPar2,
std::unique_ptr< SwField _pField = nullptr 
)

Member Data Documentation

◆ m_aCurPar1

OUString SwFieldMgr::m_aCurPar1
private

Definition at line 105 of file fldmgr.hxx.

Referenced by GetCurField().

◆ m_aCurPar2

OUString SwFieldMgr::m_aCurPar2
private

Definition at line 106 of file fldmgr.hxx.

Referenced by GetCurField().

◆ m_bEvalExp

bool SwFieldMgr::m_bEvalExp
private

Definition at line 113 of file fldmgr.hxx.

Referenced by InsertField(), and SetEvalExpFields().

◆ m_nCurFormat

sal_uInt32 SwFieldMgr::m_nCurFormat
private

Definition at line 112 of file fldmgr.hxx.

Referenced by GetCurField().

◆ m_pCurField

SwField* SwFieldMgr::m_pCurField
private

Definition at line 103 of file fldmgr.hxx.

Referenced by GetCurField(), GetCurTypeId(), GoNextPrev(), and UpdateCurField().

◆ m_pWrtShell

SwWrtShell* SwFieldMgr::m_pWrtShell
private

◆ m_sCurFrame

OUString SwFieldMgr::m_sCurFrame
private

Definition at line 107 of file fldmgr.hxx.

Referenced by GetCurField(), and InsertField().

◆ m_sMacroName

OUString SwFieldMgr::m_sMacroName
private

Definition at line 110 of file fldmgr.hxx.

Referenced by SetMacroPath().

◆ m_sMacroPath

OUString SwFieldMgr::m_sMacroPath
private

Definition at line 109 of file fldmgr.hxx.

Referenced by SetMacroPath().

◆ m_xNumberingInfo

css::uno::Reference<css::text::XNumberingTypeInfo> SwFieldMgr::m_xNumberingInfo
private

Definition at line 117 of file fldmgr.hxx.

Referenced by GetFormatCount(), GetFormatId(), GetFormatStr(), and GetNumberingInfo().


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