LibreOffice Module sc (master) 1
Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
ScNameDlg Class Reference

#include <namedlg.hxx>

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

Public Member Functions

 ScNameDlg (SfxBindings *pB, SfxChildWindow *pCW, weld::Window *pParent, ScViewData &rViewData, const ScAddress &aCursorPos, std::map< OUString, ScRangeName > *pRangeMap=nullptr)
 
virtual ~ScNameDlg () override
 
virtual void SetReference (const ScRange &rRef, ScDocument &rDoc) override
 
virtual bool IsRefInputMode () const override
 
virtual void SetActive () override
 
virtual void Close () override
 
void GetRangeNames (std::map< OUString, ScRangeName > &rRangeMap)
 
void SetEntry (const OUString &rName, const OUString &rScope)
 
- Public Member Functions inherited from ScAnyRefDlgController
 ScAnyRefDlgController (SfxBindings *rt1, SfxChildWindow *rt2, weld::Window *rt3, const OUString &rt4, const OString &rt5)
 
- Public Member Functions inherited from ScRefHdlrControllerImpl< SfxModelessDialogController >
 ScRefHdlrControllerImpl (weld::Window *pParent, const OUString &rUIXMLDescription, const OString &rID, const SfxItemSet *pArg, SfxBindings *pB)
 
 ScRefHdlrControllerImpl (SfxBindings *pB, SfxChildWindow *pCW, weld::Window *pParent, const OUString &rUIXMLDescription, const OString &rID)
 
- Public Member Functions inherited from SfxModelessDialogController
virtual ~SfxModelessDialogController () override
 
void Initialize (SfxChildWinInfo const *pInfo)
 
bool IsClosing () const
 
virtual void Close () override
 
virtual void EndDialog (int nResponse) override
 
virtual void Activate () override
 
virtual void Deactivate () override
 
virtual void ChildWinDispose () override
 
virtual void FillInfo (SfxChildWinInfo &) const
 
SfxBindingsGetBindings () const
 
- Public Member Functions inherited from SfxDialogController
 SfxDialogController (weld::Widget *pParent, const OUString &rUIFile, const OString &rDialogId)
 
virtual void Activate ()
 
virtual void Deactivate ()
 
virtual void ChildWinDispose ()
 
virtual void Close ()
 
virtual void EndDialog (int nResponse)
 
- Public Member Functions inherited from ScRefHandler
 ScRefHandler (SfxDialogController &rController, SfxBindings *pB, bool bBindRef)
 
virtual ~ScRefHandler () COVERITY_NOEXCEPT_FALSE override
 
virtual void SetReference (const ScRange &rRef, ScDocument &rDoc) override=0
 
virtual void AddRefEntry () override
 
virtual bool IsRefInputMode () const override
 
virtual bool IsTableLocked () const override
 
virtual bool IsDocAllowed (SfxObjectShell *pDocSh) const override
 
virtual void ShowReference (const OUString &rStr) override
 
virtual void HideReference (bool bDoneRefMode=true) override
 
virtual void ToggleCollapsed (formula::RefEdit *pEdit, formula::RefButton *pButton) override
 
virtual void ReleaseFocus (formula::RefEdit *pEdit) override
 
virtual void ViewShellChanged () override
 
void SwitchToDocument ()
 
virtual void SetActive () override=0
 
bool EnterRefMode ()
 
bool LeaveRefMode ()
 
bool CanInputDone (bool bForced)
 

Protected Member Functions

virtual void RefInputDone (bool bForced=false) override
 
- Protected Member Functions inherited from SfxModelessDialogController
 SfxModelessDialogController (SfxBindings *, SfxChildWindow *pChildWin, weld::Window *pParent, const OUString &rUIXMLDescription, const OString &rID)
 
- Protected Member Functions inherited from ScRefHandler
void disposeRefHandler ()
 
bool DoClose (sal_uInt16 nId)
 
void SetDispatcherLock (bool bLock)
 
virtual void RefInputStart (formula::RefEdit *pEdit, formula::RefButton *pButton=nullptr) override
 
virtual void RefInputDone (bool bForced=false) override
 
bool ParseWithNames (ScRangeList &rRanges, std::u16string_view rStr, const ScDocument &pDoc)
 

Private Types

typedef std::map< OUString, ScRangeNameRangeNameContainer
 

Private Member Functions

void Init ()
 
void UpdateChecks (const ScRangeData *pData)
 
void ShowOptions (const ScRangeNameLine &rLine)
 
bool IsNameValid ()
 
bool IsFormulaValid ()
 
void CheckForEmptyTable ()
 
ScRangeNameGetRangeName (const OUString &rScope)
 
void AddPushed ()
 
void RemovePushed ()
 
void ScopeChanged ()
 
void NameModified ()
 
void SelectionChanged ()
 
 DECL_LINK (OkBtnHdl, weld::Button &, void)
 
 DECL_LINK (CancelBtnHdl, weld::Button &, void)
 
 DECL_LINK (AddBtnHdl, weld::Button &, void)
 
 DECL_LINK (RemoveBtnHdl, weld::Button &, void)
 
 DECL_LINK (EdModifyHdl, weld::Entry &, void)
 
 DECL_LINK (RefEdModifyHdl, formula::RefEdit &, void)
 
 DECL_LINK (EdModifyCheckBoxHdl, weld::Toggleable &, void)
 
 DECL_LINK (AssignGetFocusHdl, formula::RefEdit &, void)
 
 DECL_LINK (SelectionChangedHdl_Impl, weld::TreeView &, void)
 
 DECL_LINK (ScopeChangedHdl, weld::ComboBox &, void)
 

Private Attributes

const OUString maGlobalNameStr
 
const OUString maErrInvalidNameStr
 
const OUString maErrNameInUse
 
const OUString maStrMultiSelect
 
OUString maStrInfoDefault
 
ScViewDatamrViewData
 
ScDocumentmrDoc
 
const ScAddress maCursorPos
 
bool mbDataChanged
 
bool mbCloseWithoutUndo
 
RangeNameContainer m_RangeMap
 
std::unique_ptr< weld::Entrym_xEdName
 
std::unique_ptr< weld::Labelm_xFtAssign
 
std::unique_ptr< formula::RefEditm_xEdAssign
 
std::unique_ptr< formula::RefButtonm_xRbAssign
 
std::unique_ptr< weld::ComboBoxm_xLbScope
 
std::unique_ptr< weld::CheckButtonm_xBtnPrintArea
 
std::unique_ptr< weld::CheckButtonm_xBtnColHeader
 
std::unique_ptr< weld::CheckButtonm_xBtnCriteria
 
std::unique_ptr< weld::CheckButtonm_xBtnRowHeader
 
std::unique_ptr< weld::Buttonm_xBtnAdd
 
std::unique_ptr< weld::Buttonm_xBtnDelete
 
std::unique_ptr< weld::Buttonm_xBtnOk
 
std::unique_ptr< weld::Buttonm_xBtnCancel
 
std::unique_ptr< weld::Labelm_xFtInfo
 
std::unique_ptr< ScRangeManagerTablem_xRangeManagerTable
 

Additional Inherited Members

- Public Types inherited from ScRefHdlrControllerImpl< SfxModelessDialogController >
enum  
 
- Static Public Member Functions inherited from ScRefHandler
static bool CanInputStart (const formula::RefEdit *pEdit)
 

Detailed Description

Definition at line 32 of file namedlg.hxx.

Member Typedef Documentation

◆ RangeNameContainer

Definition at line 49 of file namedlg.hxx.

Constructor & Destructor Documentation

◆ ScNameDlg()

ScNameDlg::ScNameDlg ( SfxBindings pB,
SfxChildWindow pCW,
weld::Window pParent,
ScViewData rViewData,
const ScAddress aCursorPos,
std::map< OUString, ScRangeName > *  pRangeMap = nullptr 
)

◆ ~ScNameDlg()

ScNameDlg::~ScNameDlg ( )
overridevirtual

Definition at line 96 of file namedlg.cxx.

Member Function Documentation

◆ AddPushed()

void ScNameDlg::AddPushed ( )
private

◆ CheckForEmptyTable()

void ScNameDlg::CheckForEmptyTable ( )
private

◆ Close()

void ScNameDlg::Close ( )
overridevirtual

◆ DECL_LINK() [1/10]

ScNameDlg::DECL_LINK ( AddBtnHdl  ,
weld::Button ,
void   
)
private

◆ DECL_LINK() [2/10]

ScNameDlg::DECL_LINK ( AssignGetFocusHdl  ,
formula::RefEdit ,
void   
)
private

◆ DECL_LINK() [3/10]

ScNameDlg::DECL_LINK ( CancelBtnHdl  ,
weld::Button ,
void   
)
private

◆ DECL_LINK() [4/10]

ScNameDlg::DECL_LINK ( EdModifyCheckBoxHdl  ,
weld::Toggleable ,
void   
)
private

◆ DECL_LINK() [5/10]

ScNameDlg::DECL_LINK ( EdModifyHdl  ,
weld::Entry ,
void   
)
private

◆ DECL_LINK() [6/10]

ScNameDlg::DECL_LINK ( OkBtnHdl  ,
weld::Button ,
void   
)
private

◆ DECL_LINK() [7/10]

ScNameDlg::DECL_LINK ( RefEdModifyHdl  ,
formula::RefEdit ,
void   
)
private

◆ DECL_LINK() [8/10]

ScNameDlg::DECL_LINK ( RemoveBtnHdl  ,
weld::Button ,
void   
)
private

◆ DECL_LINK() [9/10]

ScNameDlg::DECL_LINK ( ScopeChangedHdl  ,
weld::ComboBox ,
void   
)
private

◆ DECL_LINK() [10/10]

ScNameDlg::DECL_LINK ( SelectionChangedHdl_Impl  ,
weld::TreeView ,
void   
)
private

◆ GetRangeName()

ScRangeName * ScNameDlg::GetRangeName ( const OUString &  rScope)
private

Definition at line 280 of file namedlg.cxx.

References m_RangeMap, maGlobalNameStr, and STR_GLOBAL_RANGE_NAME.

Referenced by IsNameValid(), NameModified(), RemovePushed(), and ShowOptions().

◆ GetRangeNames()

void ScNameDlg::GetRangeNames ( std::map< OUString, ScRangeName > &  rRangeMap)

Definition at line 448 of file namedlg.cxx.

References m_RangeMap.

◆ Init()

void ScNameDlg::Init ( void  )
private

◆ IsFormulaValid()

bool ScNameDlg::IsFormulaValid ( )
private

◆ IsNameValid()

bool ScNameDlg::IsNameValid ( )
private

◆ IsRefInputMode()

bool ScNameDlg::IsRefInputMode ( ) const
overridevirtual

Reimplemented from ScRefHandler.

Definition at line 146 of file namedlg.cxx.

References m_xEdAssign.

◆ NameModified()

void ScNameDlg::NameModified ( )
private

◆ RefInputDone()

void ScNameDlg::RefInputDone ( bool  bForced = false)
overrideprotectedvirtual

Reimplemented from ScRefHandler.

Definition at line 151 of file namedlg.cxx.

References m_xEdAssign, and ScRefHandler::RefInputDone().

Referenced by SetActive().

◆ RemovePushed()

void ScNameDlg::RemovePushed ( )
private

◆ ScopeChanged()

void ScNameDlg::ScopeChanged ( )
private

Definition at line 443 of file namedlg.cxx.

References NameModified().

◆ SelectionChanged()

void ScNameDlg::SelectionChanged ( )
private

◆ SetActive()

void ScNameDlg::SetActive ( )
overridevirtual

Implements ScRefHandler.

Definition at line 206 of file namedlg.cxx.

References m_xEdAssign, and RefInputDone().

◆ SetEntry()

void ScNameDlg::SetEntry ( const OUString &  rName,
const OUString &  rScope 
)

◆ SetReference()

void ScNameDlg::SetReference ( const ScRange rRef,
ScDocument rDoc 
)
overridevirtual

◆ ShowOptions()

void ScNameDlg::ShowOptions ( const ScRangeNameLine rLine)
private

◆ UpdateChecks()

void ScNameDlg::UpdateChecks ( const ScRangeData pData)
private

Member Data Documentation

◆ m_RangeMap

RangeNameContainer ScNameDlg::m_RangeMap
private

Definition at line 51 of file namedlg.hxx.

Referenced by Close(), GetRangeName(), GetRangeNames(), Init(), and ScNameDlg().

◆ m_xBtnAdd

std::unique_ptr<weld::Button> ScNameDlg::m_xBtnAdd
private

Definition at line 64 of file namedlg.hxx.

Referenced by Init().

◆ m_xBtnCancel

std::unique_ptr<weld::Button> ScNameDlg::m_xBtnCancel
private

Definition at line 67 of file namedlg.hxx.

Referenced by Init().

◆ m_xBtnColHeader

std::unique_ptr<weld::CheckButton> ScNameDlg::m_xBtnColHeader
private

Definition at line 60 of file namedlg.hxx.

Referenced by CheckForEmptyTable(), Init(), NameModified(), SelectionChanged(), and UpdateChecks().

◆ m_xBtnCriteria

std::unique_ptr<weld::CheckButton> ScNameDlg::m_xBtnCriteria
private

Definition at line 61 of file namedlg.hxx.

Referenced by CheckForEmptyTable(), Init(), NameModified(), SelectionChanged(), and UpdateChecks().

◆ m_xBtnDelete

std::unique_ptr<weld::Button> ScNameDlg::m_xBtnDelete
private

Definition at line 65 of file namedlg.hxx.

Referenced by CheckForEmptyTable(), Init(), and SelectionChanged().

◆ m_xBtnOk

std::unique_ptr<weld::Button> ScNameDlg::m_xBtnOk
private

Definition at line 66 of file namedlg.hxx.

Referenced by Init().

◆ m_xBtnPrintArea

std::unique_ptr<weld::CheckButton> ScNameDlg::m_xBtnPrintArea
private

Definition at line 59 of file namedlg.hxx.

Referenced by CheckForEmptyTable(), Init(), NameModified(), SelectionChanged(), and UpdateChecks().

◆ m_xBtnRowHeader

std::unique_ptr<weld::CheckButton> ScNameDlg::m_xBtnRowHeader
private

Definition at line 62 of file namedlg.hxx.

Referenced by CheckForEmptyTable(), Init(), NameModified(), SelectionChanged(), and UpdateChecks().

◆ m_xEdAssign

std::unique_ptr<formula::RefEdit> ScNameDlg::m_xEdAssign
private

◆ m_xEdName

std::unique_ptr<weld::Entry> ScNameDlg::m_xEdName
private

Definition at line 53 of file namedlg.hxx.

Referenced by CheckForEmptyTable(), Init(), IsNameValid(), NameModified(), and SelectionChanged().

◆ m_xFtAssign

std::unique_ptr<weld::Label> ScNameDlg::m_xFtAssign
private

Definition at line 54 of file namedlg.hxx.

Referenced by ScNameDlg().

◆ m_xFtInfo

std::unique_ptr<weld::Label> ScNameDlg::m_xFtInfo
private

Definition at line 69 of file namedlg.hxx.

Referenced by IsFormulaValid(), IsNameValid(), NameModified(), and ScNameDlg().

◆ m_xLbScope

std::unique_ptr<weld::ComboBox> ScNameDlg::m_xLbScope
private

Definition at line 57 of file namedlg.hxx.

Referenced by CheckForEmptyTable(), Init(), IsNameValid(), NameModified(), and SelectionChanged().

◆ m_xRangeManagerTable

std::unique_ptr<ScRangeManagerTable> ScNameDlg::m_xRangeManagerTable
private

◆ m_xRbAssign

std::unique_ptr<formula::RefButton> ScNameDlg::m_xRbAssign
private

Definition at line 56 of file namedlg.hxx.

Referenced by CheckForEmptyTable(), ScNameDlg(), and SelectionChanged().

◆ maCursorPos

const ScAddress ScNameDlg::maCursorPos
private

Definition at line 43 of file namedlg.hxx.

Referenced by Init(), IsFormulaValid(), and NameModified().

◆ maErrInvalidNameStr

const OUString ScNameDlg::maErrInvalidNameStr
private

Definition at line 36 of file namedlg.hxx.

Referenced by IsNameValid().

◆ maErrNameInUse

const OUString ScNameDlg::maErrNameInUse
private

Definition at line 37 of file namedlg.hxx.

Referenced by IsNameValid().

◆ maGlobalNameStr

const OUString ScNameDlg::maGlobalNameStr
private

Definition at line 35 of file namedlg.hxx.

Referenced by GetRangeName(), and Init().

◆ maStrInfoDefault

OUString ScNameDlg::maStrInfoDefault
private

Definition at line 39 of file namedlg.hxx.

Referenced by IsNameValid(), NameModified(), and ScNameDlg().

◆ maStrMultiSelect

const OUString ScNameDlg::maStrMultiSelect
private

Definition at line 38 of file namedlg.hxx.

Referenced by SelectionChanged().

◆ mbCloseWithoutUndo

bool ScNameDlg::mbCloseWithoutUndo
private

Definition at line 47 of file namedlg.hxx.

Referenced by AddPushed(), and Close().

◆ mbDataChanged

bool ScNameDlg::mbDataChanged
private

Definition at line 45 of file namedlg.hxx.

Referenced by Close(), NameModified(), RemovePushed(), and SetEntry().

◆ mrDoc

ScDocument& ScNameDlg::mrDoc
private

Definition at line 42 of file namedlg.hxx.

Referenced by Init(), IsFormulaValid(), IsNameValid(), NameModified(), and ScNameDlg().

◆ mrViewData

ScViewData& ScNameDlg::mrViewData
private

Definition at line 41 of file namedlg.hxx.

Referenced by Close().


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