Web Analytics Made Easy - Statcounter
Skip to content

Class SBGWindowDock#

ClassList > SBGWindowDock

This class describes a dock window. More...

  • #include <SBGWindowDock.hpp>

Inherits the following classes: QDockWidget

Public Signals#

Type Name
signal void closed
Emitted when the dock window is closed by the user.
signal void locked (bool)
Emitted when the dock window is locked or unlocked.
signal void shown (bool)
Emitted when the dock window is shown or hidden.

Public Functions#

Type Name
SBGWindowDock (QWidget * widget, QString title, QWidget * parent, Qt::WindowFlags flags)
Constructor.
bool getCitableWindowFlag () const
Returns whether the citable window flag.
SBGWindowWidget * getEmbeddedWidget () const
Returns the embedded widget.
SBUUID getPreferencesUUID () const
Returns the UUID of preferences (static attributes), if present.
bool getSavableWindowFlag () const
Returns whether the window options can be saved.
SBCContainerUUID getUUID () const
Returns the UUID.
bool isLocked () const
Returns whether the dock window is locked.
void loadDefaultSettings ()
Loads the default settings of the window.
virtual void print (unsigned int offset=0) const
Prints some debugging information.
void saveDefaultSettings ()
Saves the default settings of the window.
void setCitableWindowFlag (bool flag)
Sets whether the citable window flag.
void setEmbeddedWidget (SBGWindowWidget * embeddedWidget)
Sets the embedded widget.
void setPreferencesUUID (const SBUUID & preferencesUUID)
Sets the UUID of preferences (static attributes), if present.
void setSavableWindowFlag (bool flag)
Sets whether the window options can be saved.
void setUUID (const SBCContainerUUID & uuid)
Sets the UUID.
virtual ~SBGWindowDock ()
Destructor.

Protected Attributes#

Type Name
SBGWindowDockData * dataPointer

Protected Functions#

Type Name
virtual void changeEvent (QEvent * event)
Handles events.
virtual bool event (QEvent * event)
Handles events.
virtual void hideEvent (QHideEvent * event)
Handles hide event.
virtual void paintEvent (QPaintEvent * event)
Handles paint event.
virtual void resizeEvent (QResizeEvent * event)
Handles resize events.
virtual void showEvent (QShowEvent * event)
Handles show event.
virtual void wheelEvent (QWheelEvent * event)
Handles mouse wheel events.

Detailed Description#

Short name: SBWindowDock

Public Signals Documentation#

signal closed#

Emitted when the dock window is closed by the user.

void SBGWindowDock::closed;


signal locked#

Emitted when the dock window is locked or unlocked.

void SBGWindowDock::locked;


signal shown#

Emitted when the dock window is shown or hidden.

void SBGWindowDock::shown;


Public Functions Documentation#

function SBGWindowDock#

Constructor.

SBGWindowDock::SBGWindowDock (
    QWidget * widget,
    QString title,
    QWidget * parent,
    Qt::WindowFlags flags
) 

Constructs a new dock window with the specified embedded widget, title, parent, and window flags.

Parameters:

  • widget The widget to embed in the dock.
  • title The title of the dock window.
  • parent The parent widget of the dock.
  • flags The window flags for the dock.

function getCitableWindowFlag#

Returns whether the citable window flag.

bool SBGWindowDock::getCitableWindowFlag () const

Returns whether the dock window is marked as citable.

Returns:

true if the dock window is citable; otherwise false.


function getEmbeddedWidget#

Returns the embedded widget.

SBGWindowWidget * SBGWindowDock::getEmbeddedWidget () const

Returns the widget embedded in this dock window.

Returns:

The embedded widget, or nullptr if none is set.


function getPreferencesUUID#

Returns the UUID of preferences (static attributes), if present.

SBUUID SBGWindowDock::getPreferencesUUID () const

Returns the UUID of the preferences associated with this dock window.

Returns:

The preferences UUID.


function getSavableWindowFlag#

Returns whether the window options can be saved.

bool SBGWindowDock::getSavableWindowFlag () const

Returns whether the dock window's options can be saved.

Returns:

true if the window options are savable; otherwise false.


function getUUID#

Returns the UUID.

SBCContainerUUID SBGWindowDock::getUUID () const

Returns the UUID of this dock window.

Returns:

The dock window's UUID.


function isLocked#

Returns whether the dock window is locked.

bool SBGWindowDock::isLocked () const

Returns whether the dock window is currently locked.

Returns:

true if the dock window is locked; otherwise false.


function loadDefaultSettings#

Loads the default settings of the window.

void SBGWindowDock::loadDefaultSettings () 

Loads the default settings for the dock window and its embedded widget, if any.


function print#

Prints some debugging information.

virtual void SBGWindowDock::print (
    unsigned int offset=0
) const

Prints debugging information about the dock window and its embedded widget.

Parameters:

  • offset The indentation offset for the printed output.

function saveDefaultSettings#

Saves the default settings of the window.

void SBGWindowDock::saveDefaultSettings () 

Saves the default settings for the dock window and its embedded widget, if any.


function setCitableWindowFlag#

Sets whether the citable window flag.

void SBGWindowDock::setCitableWindowFlag (
    bool flag
) 

Sets the citable flag for the dock window.

Parameters:

  • b true to mark the window as citable; false otherwise.

function setEmbeddedWidget#

Sets the embedded widget.

void SBGWindowDock::setEmbeddedWidget (
    SBGWindowWidget * embeddedWidget
) 

Sets the widget embedded in this dock window.

Parameters:

  • embeddedWidget The widget to embed.

function setPreferencesUUID#

Sets the UUID of preferences (static attributes), if present.

void SBGWindowDock::setPreferencesUUID (
    const SBUUID & preferencesUUID
) 

Sets the UUID of the preferences for this dock window.

Parameters:

  • preferencesUUID The UUID to assign to the preferences.

function setSavableWindowFlag#

Sets whether the window options can be saved.

void SBGWindowDock::setSavableWindowFlag (
    bool flag
) 

Sets whether the dock window's options can be saved.

Parameters:

  • b true to make the window options savable; false otherwise.

function setUUID#

Sets the UUID.

void SBGWindowDock::setUUID (
    const SBCContainerUUID & uuid
) 

Sets the UUID of this dock window.

Parameters:

  • uuid The UUID to assign to the dock window.

function ~SBGWindowDock#

Destructor.

virtual SBGWindowDock::~SBGWindowDock () 

Destroys the dock window, removing it from the manager.


Protected Attributes Documentation#

variable dataPointer#

SBGWindowDockData* SBGWindowDock::dataPointer;

Protected Functions Documentation#

function changeEvent#

Handles events.

virtual void SBGWindowDock::changeEvent (
    QEvent * event
) 

Handles generic change events; forwards to base implementation.

Parameters:

  • event The event.

function event#

Handles events.

virtual bool SBGWindowDock::event (
    QEvent * event
) 

Handles generic events; forwards to base implementation.

Parameters:

  • event The event.

Returns:

true if the event was handled; otherwise false.


function hideEvent#

Handles hide event.

virtual void SBGWindowDock::hideEvent (
    QHideEvent * event
) 

Handles hide events: saves context, default settings, and emits a hidden signal.

Parameters:

  • event The hide event.

function paintEvent#

Handles paint event.

virtual void SBGWindowDock::paintEvent (
    QPaintEvent * event
) 

Handles paint events to render the dock's background and title bar.

Parameters:

  • event The paint event.

function resizeEvent#

Handles resize events.

virtual void SBGWindowDock::resizeEvent (
    QResizeEvent * event
) 

Handles resize events and updates the dock's pixmap.

Parameters:

  • event The resize event.

function showEvent#

Handles show event.

virtual void SBGWindowDock::showEvent (
    QShowEvent * event
) 

Handles show events: emits a shown signal.

Parameters:

  • event The show event.

function wheelEvent#

Handles mouse wheel events.

virtual void SBGWindowDock::wheelEvent (
    QWheelEvent * event
) 

Handles mouse wheel events; forwards to base implementation and accepts the event.

Parameters:

  • event The wheel event.