20#ifndef INCLUDED_VCL_TABCTRL_HXX
21#define INCLUDED_VCL_TABCTRL_HXX
23#include <config_options.h>
38#define TAB_APPEND (sal_uInt16(0xFFFF))
39#define TAB_PAGE_NOTFOUND (sal_uInt16(0xFFFF))
60 SAL_DLLPRIVATE
ImplTabItem* ImplGetItem( sal_uInt16 nId )
const;
65 SAL_DLLPRIVATE
void ImplChangeTabPage( sal_uInt16 nId, sal_uInt16 nOldId );
66 SAL_DLLPRIVATE
bool ImplPosCurTabPage();
67 virtual void ImplActivateTabPage(
bool bNext );
68 SAL_DLLPRIVATE
void ImplShowFocus();
72 SAL_DLLPRIVATE
bool ImplHandleKeyEvent(
const KeyEvent& rKeyEvent );
77 using Window::ImplInit;
83 SAL_DLLPRIVATE
Size ImplCalculateRequisition(sal_uInt16& nHeaderHeight)
const;
89 virtual void dispose()
override;
94 virtual void Resize()
override;
105 bool DeactivatePage();
109 void SetTabPageSizePixel(
const Size& rSize );
111 void InsertPage( sal_uInt16 nPageId,
const OUString& rText,
113 void RemovePage( sal_uInt16 nPageId );
115 void SetPageEnabled(sal_uInt16 nPageId,
bool bEnable =
true);
116 void SetPageVisible(sal_uInt16 nPageId,
bool bVisible =
true);
118 sal_uInt16 GetPagePos( sal_uInt16 nPageId )
const;
119 sal_uInt16 GetPageCount()
const;
120 sal_uInt16 GetPageId( sal_uInt16 nPos )
const;
121 sal_uInt16 GetPageId(
const Point& rPos)
const;
122 sal_uInt16 GetPageId(
const OUString& rName )
const;
125 sal_uInt16 GetCurPageId()
const;
127 void SelectTabPage( sal_uInt16 nPageId );
129 void SetTabPage(sal_uInt16 nPageId,
TabPage* pPage);
130 TabPage* GetTabPage( sal_uInt16 nPageId )
const;
132 void SetPageText( sal_uInt16 nPageId,
const OUString& rText );
133 OUString
const & GetPageText( sal_uInt16 nPageId )
const;
135 void SetHelpText( sal_uInt16 nPageId,
const OUString& rText );
136 const OUString&
GetHelpText( sal_uInt16 nPageId )
const;
138 void SetPageName( sal_uInt16 nPageId,
const OUString& rName )
const;
139 OUString GetPageName( sal_uInt16 nPageId )
const;
147 void SetPageImage( sal_uInt16 nPageId,
const Image& rImage );
162 virtual Size calculateRequisition()
const;
163 void setAllocation(
const Size &rAllocation);
165 std::vector<sal_uInt16> GetPageIDs()
const;
171 virtual bool set_property(
const OUString &rKey,
const OUString &rValue)
override;
178class UNLESS_MERGELIBS(VCL_DLLPUBLIC) NotebookbarTabControlBase :
public TabControl,
179 public NotebookbarContextControl
183 ~NotebookbarTabControlBase()
override;
188 void SetToolBox(
ToolBox* pToolBox );
189 ToolBox* GetToolBox() {
return m_pShortcuts; }
193 static sal_uInt16 GetHeaderHeight();
200 bool bLastContextWasSupported;
203 static sal_uInt16 m_nHeaderHeight;
virtual const Color & GetCanonicalTextColor(const StyleSettings &_rStyle) const
virtual bool EventNotify(NotifyEvent &rNEvt) override
virtual void StateChanged(StateChangedType nStateChange) override
virtual void Resize() override
virtual Size GetOptimalSize() const override
virtual const vcl::Font & GetCanonicalFont(const StyleSettings &_rStyle) const
virtual void dispose() override
This is intended to be used to clear any locally held references to other Window-subclass objects.
A widget used to choose from a list of items and which has no entry.
This implements Widget Layout-based notebook-like menu bar.
Some things multiple-inherit from VclAbstractDialog and OutputDevice, so we need to use virtual inher...
void SetDeactivatePageHdl(const Link< TabControl *, bool > &rLink)
virtual Size calculateRequisition() const
Link< TabControl *, bool > maDeactivateHdl
DECL_DLLPRIVATE_LINK(ImplWindowEventListener, VclWindowEvent &, void)
std::unique_ptr< ImplTabCtrlData > mpTabCtrlData
DECL_DLLPRIVATE_LINK(ImplListBoxSelectHdl, ListBox &, void)
virtual void dispose() override
This is intended to be used to clear any locally held references to other Window-subclass objects.
virtual void ImplActivateTabPage(bool bNext)
virtual bool ImplPlaceTabs(tools::Long nWidth)
Link< TabControl *, void > maActivateHdl
void SetActivatePageHdl(const Link< TabControl *, void > &rLink)
virtual void RequestHelp(const HelpEvent &rHEvt)
void SetHelpText(const OUString &rHelpText)
virtual void SetSizePixel(const Size &rNewSize)
virtual void Command(const CommandEvent &rCEvt)
virtual void queue_resize(StateChangedType eReason=StateChangedType::Layout)
virtual void MouseButtonDown(const MouseEvent &rMEvt)
void SetAccessibleDescription(const OUString &rDescr)
virtual void KeyInput(const KeyEvent &rKEvt)
virtual void Paint(vcl::RenderContext &rRenderContext, const tools::Rectangle &rRect)
const OUString & GetHelpId() const
virtual bool PreNotify(NotifyEvent &rNEvt)
void SetAccessibleName(const OUString &rName)
virtual void DumpAsPropertyTree(tools::JsonWriter &)
Dumps itself and potentially its children to a property tree, to be written easily to JSON.
virtual void DataChanged(const DataChangedEvent &rDCEvt)
OUString GetAccessibleName() const
virtual void SetPosPixel(const Point &rNewPos)
virtual bool set_property(const OUString &rKey, const OUString &rValue)
virtual void SetPosSizePixel(const Point &rNewPos, const Size &rNewSize)
OUString GetAccessibleDescription() const
SAL_DLLPRIVATE void ImplInit(vcl::Window *pParent, WinBits nStyle, SystemParentData *pSystemParentData)
const OUString & GetHelpText() const
virtual FactoryFunction GetUITestFactory() const
void SetHelpId(const OUString &)
virtual void SetCurPageId(const OUString &rName) override
std::function< std::unique_ptr< UIObject >(vcl::Window *)> FactoryFunction
WinBits const WB_STDTABCONTROL