5#ifndef DCPP_I_GUI_TAB_CONTROL_HPP_INCLUDED
6#define DCPP_I_GUI_TAB_CONTROL_HPP_INCLUDED
8#include <duckcpp/core/engine/IGUIElement.hpp>
9#include <duckcpp/core/engine/SColor.hpp>
10#include <duckcpp/core/engine/IGUISkin.hpp>
Base class of all GUI elements.
Definition IGUIElement.hpp:24
EGUI_ELEMENT_TYPE getType() const
Returns the type of the gui element.
Definition IGUIElement.hpp:739
IGUIElement * Parent
Pointer to the parent.
Definition IGUIElement.hpp:996
virtual void draw()
Draws the element and its children.
Definition IGUIElement.hpp:331
GUI Environment. Used as factory and manager of all other GUI elements.
Definition IGUIEnvironment.hpp:73
A standard tab control.
Definition IGUITabControl.hpp:23
virtual dcpp::int32_kt getTabCount() const =0
Returns amount of tabs in the tabcontrol.
virtual dcpp::int32_kt getTabMaxWidth() const =0
get the maximal width of a tab
virtual bool setActiveTab(IGUITab *tab)=0
Brings a tab to front.
virtual dcpp::int32_kt addTab(IGUITab *tab)=0
Adds an existing tab.
virtual dcpp::int32_kt getTabHeight() const =0
Get the height of the tabs.
virtual dcpp::int32_kt getActiveTab() const =0
Returns which tab is currently active.
virtual dcpp::int32_kt getTabAt(dcpp::int32_kt xpos, dcpp::int32_kt ypos) const =0
get the the id of the tab at the given absolute coordinates
virtual void setTabExtraWidth(dcpp::int32_kt extraWidth)=0
Set the extra width added to tabs on each side of the text.
virtual dcpp::gui::EGUI_ALIGNMENT getTabVerticalAlignment() const =0
Get the alignment of the tabs.
virtual IGUITab * insertTab(dcpp::int32_kt idx, const wchar_t *caption, dcpp::int32_kt id=-1)=0
Insert the tab at the given index.
virtual void setTabVerticalAlignment(dcpp::gui::EGUI_ALIGNMENT alignment)=0
Set the alignment of the tabs.
virtual void setTabHeight(dcpp::int32_kt height)=0
Set the height of the tabs.
virtual IGUITab * getTab(dcpp::int32_kt idx) const =0
Returns a tab based on zero based index.
virtual dcpp::int32_kt getTabIndex(const IGUIElement *tab) const =0
For given element find if it's a tab and return it's zero-based index (or -1 for not found)
virtual bool setActiveTab(dcpp::int32_kt idx)=0
Brings a tab to front.
IGUITabControl(IGUIEnvironment *environment, IGUIElement *parent, dcpp::int32_kt id, dcpp::nub::recti rectangle)
constructor
Definition IGUITabControl.hpp:27
virtual void removeTab(dcpp::int32_kt idx)=0
Removes a tab from the tabcontrol.
virtual void clear()=0
Clears the tabcontrol removing all tabs.
virtual dcpp::int32_kt getTabExtraWidth() const =0
Get the extra width added to tabs on each side of the text.
virtual IGUITab * addTab(const wchar_t *caption, dcpp::int32_kt id=-1)=0
Adds a tab.
virtual dcpp::int32_kt insertTab(dcpp::int32_kt idx, IGUITab *tab, bool serializationMode=false)=0
Insert an existing tab.
virtual void setTabMaxWidth(dcpp::int32_kt width)=0
set the maximal width of a tab. Per default width is 0 which means "no width restriction".
A tab-page, onto which other gui elements could be added.
Definition IGUITabControl.hpp:125
virtual void setTextColor(dcpp::video::SColor c)=0
sets the color of it's text in the tab-bar
virtual dcpp::video::SColor getTextColor() const =0
gets the color of the text
virtual bool isDrawingBackground() const =0
returns true if the tab is drawing its background, false if not
virtual void setDrawBackground(bool draw=true)=0
sets if the tab should draw its background
virtual DCPP_DEPRECATED dcpp::int32_kt getNumber() const
Returns zero based index of tab if in tabcontrol.
Definition IGUITabControl.hpp:134
virtual void setBackgroundColor(dcpp::video::SColor c)=0
sets the color of the background, if it should be drawn.
IGUITab(IGUIEnvironment *environment, IGUIElement *parent, dcpp::int32_kt id, dcpp::nub::recti rectangle)
constructor
Definition IGUITabControl.hpp:129
virtual dcpp::video::SColor getBackgroundColor() const =0
returns the color of the background
Rectangle template.
Definition rect.hpp:27
Class representing a 32 bit ARGB color.
Definition SColor.hpp:317
EGUI_ALIGNMENT
Definition EGUIAlignment.hpp:15
@ EGUIET_TAB
A tab (IGUITab)
Definition EGUIElementTypes.hpp:71
@ EGUIET_TAB_CONTROL
A tab control.
Definition EGUIElementTypes.hpp:74
As of Duckcpp 1.6, position2d is a synonym for vector2d.
Definition shared_device.hpp:34
signed int int32_kt
32 bit signed variable.
Definition irrTypes.hpp:72