swift
Public Types | Signals | Public Member Functions | List of all members
SwiftGuiStd Class Reference

swift GUI More...

Inheritance diagram for SwiftGuiStd:
[legend]

Public Types

enum  MainPageIndex { MainPageInfoArea = 0 , MainPageLogin = 1 , MainPageInternals = 2 , MainPageInvisible = 3 }
 Main page indexes. More...
 
- Public Types inherited from swift::gui::CEnableForFramelessWindow
enum  WindowMode { WindowNormal , WindowFrameless , WindowTool }
 Window modes.
 

Signals

void currentMainInfoAreaChanged (const QWidget *currentWidget)
 Main info area has changed. More...
 

Public Member Functions

 SwiftGuiStd (WindowMode windowMode, QWidget *parent=nullptr)
 Constructor.
 
virtual ~SwiftGuiStd ()
 Destructor.
 
- Public Member Functions inherited from swift::misc::CIdentifiable
const CIdentifieridentifier () const
 Get identifier.
 
void setIdentifier (const CIdentifier &identifier)
 Set identifier, allows to set an external identifier.
 
bool isMyIdentifier (const CIdentifier &otherIdentifier) const
 My identifier?
 
- Public Member Functions inherited from swift::gui::CEnableForFramelessWindow
 CEnableForFramelessWindow (WindowMode mode, bool isMainApplicationWindow, const char *framelessPropertyname, QWidget *correspondingWidget)
 Constructor. More...
 
virtual ~CEnableForFramelessWindow ()
 Destructor.
 
 CEnableForFramelessWindow (const CEnableForFramelessWindow &)=delete
 Copy constructor.
 
CEnableForFramelessWindowoperator= (const CEnableForFramelessWindow &)=delete
 Copy assignment operator.
 
void setMode (WindowMode mode)
 Window mode.
 
virtual void setFrameless (bool frameless)
 Framless.
 
bool isFrameless () const
 Frameless?
 
bool isMainApplicationWindow () const
 Is main application, explicitly set.
 
void alwaysOnTop (bool onTop)
 Always on top?
 
void activate ()
 Activates the window.
 
QWidget * getWidget () const
 Corresponding QMainWindow.
 
- Public Member Functions inherited from swift::gui::IMainWindowAccess
virtual ~IMainWindowAccess ()
 Destructor.
 
 IMainWindowAccess ()
 Ctor.
 
 IMainWindowAccess (const IMainWindowAccess &)=delete
 Copy constructor.
 
IMainWindowAccessoperator= (const IMainWindowAccess &)=delete
 Copy assignment operator.
 
virtual bool displayInStatusBar (const swift::misc::CStatusMessage &message)
 Display in status bar.
 
virtual bool displayInOverlayWindow (const swift::misc::CStatusMessage &message, std::chrono::milliseconds timeout=std::chrono::milliseconds(0))
 Display in overlay window.
 
virtual bool displayInOverlayWindow (const swift::misc::CStatusMessageList &messages, std::chrono::milliseconds timeout=std::chrono::milliseconds(0))
 Display in overlay window.
 
virtual bool displayInOverlayWindow (const QString &html, std::chrono::milliseconds timeout=std::chrono::milliseconds(0))
 Display in overlay window.
 

Protected Member Functions

QMainWindow events
virtual void mouseMoveEvent (QMouseEvent *event)
 
virtual void mousePressEvent (QMouseEvent *event)
 
virtual void mouseReleaseEvent (QMouseEvent *event)
 
virtual void closeEvent (QCloseEvent *event)
 
virtual void changeEvent (QEvent *event)
 
QAction * getWindowMinimizeAction (QObject *parent)
 Get a minimize action which minimizes the window. More...
 
QAction * getWindowNormalAction (QObject *parent)
 Get a minimize action which minimizes the window. More...
 
QAction * getToggleWindowVisibilityAction (QObject *parent)
 Get a minimize action which minimizes the window. More...
 
QAction * getToggleStayOnTopAction (QObject *parent)
 Get a minimize action which minimizes the window. More...
 
- Protected Member Functions inherited from swift::misc::CIdentifiable
 CIdentifiable (const QString &objectName)
 Use literal based object name.
 
 CIdentifiable (QObject *nameProvider)
 Connect with QObject providing the name.
 
 CIdentifiable ()
 Construct without a name.
 
 ~CIdentifiable ()
 Destructor.
 
 CIdentifiable (const CIdentifiable &)=default
 Copy constructor.
 
CIdentifiableoperator= (const CIdentifiable &)=default
 Copy assignment operator.
 
- Protected Member Functions inherited from swift::gui::CEnableForFramelessWindow
virtual void windowFlagsChanged ()
 Can be used as notification if window mode changes.
 
void addFramelessSizeGripToStatusBar (QStatusBar *statusBar)
 Resize grip handle.
 
void hideFramelessSizeGripInStatusBar ()
 Resize grip handle.
 
void setWindowAttributes (WindowMode mode)
 Attributes. More...
 
void setDynamicProperties (bool frameless)
 Set dynamic properties such as frameless.
 
QHBoxLayout * addFramelessCloseButton (QMenuBar *menuBar)
 Close button for frameless windows.
 
void toolToNormalWindow ()
 Remove tool and add desktop window.
 
void normalToToolWindow ()
 Remove desktop and add tool window.
 
bool isToolWindow () const
 Tool window.
 
bool handleMousePressEvent (QMouseEvent *event)
 Mouse press, required for frameless window.
 
bool handleMouseMoveEvent (QMouseEvent *event)
 Mouse moving, required for frameless window.
 
bool handleChangeEvent (QEvent *event)
 Mouse window change event.
 
void showMinimizedModeChecked ()
 Check mode and then show minimized.
 
void showNormalModeChecked ()
 Check mode and then show normal.
 

Additional Inherited Members

- Static Public Member Functions inherited from swift::gui::CEnableForFramelessWindow
static WindowMode stringToWindowMode (const QString &s)
 String to window mode.
 
static const QString & windowModeToString (WindowMode m)
 String to window mode.
 
- Static Protected Member Functions inherited from swift::gui::CEnableForFramelessWindow
static Qt::WindowFlags modeToWindowFlags (WindowMode mode)
 Translate mode.
 
- Protected Attributes inherited from swift::gui::CEnableForFramelessWindow
QPoint m_framelessDragPosition
 position, if moving is handled with frameless window
 
QSize m_moveSize
 size when moved (in frameless window)
 
QPushButton * m_framelessCloseButton = nullptr
 close button
 
WindowMode m_windowMode = WindowNormal
 Window mode,. More...
 
WindowMode m_originalWindowMode = WindowNormal
 mode when initialized
 
bool m_isMainApplicationWindow = false
 is this the main application window (only 1)?
 
QWidget * m_widget = nullptr
 corresponding window or dock widget
 
QSizeGrip * m_framelessSizeGrip = nullptr
 size grip object
 
QByteArray m_framelessPropertyName
 property name for frameless widgets
 
int m_windowFrameSizeW = -1
 window frame width
 
int m_windowFrameSizeH = -1
 window frame height
 
- Protected Attributes inherited from swift::gui::IMainWindowAccess
components::CLogComponentm_mwaLogComponent = nullptr
 the log component if any
 
CManagedStatusBarm_mwaStatusBar = nullptr
 status bar if any
 
COverlayMessagesFramem_mwaOverlayFrame = nullptr
 overlay messages if any
 

Detailed Description

swift GUI

Definition at line 58 of file swiftguistd.h.

Member Enumeration Documentation

◆ MainPageIndex

Main page indexes.

Remarks
keep the values in sync with the real tab indexes

Definition at line 70 of file swiftguistd.h.

Member Function Documentation

◆ changeEvent()

void SwiftGuiStd::changeEvent ( QEvent *  event)
protectedvirtual

Definition at line 178 of file swiftguistd.cpp.

◆ closeEvent()

void SwiftGuiStd::closeEvent ( QCloseEvent *  event)
protectedvirtual

Definition at line 146 of file swiftguistd.cpp.

◆ currentMainInfoAreaChanged

void SwiftGuiStd::currentMainInfoAreaChanged ( const QWidget *  currentWidget)
signal

Main info area has changed.

Remarks
using widget pointer allows the component itself to identify if it is current

◆ getToggleStayOnTopAction()

QAction * SwiftGuiStd::getToggleStayOnTopAction ( QObject *  parent)
protected

Get a minimize action which minimizes the window.

Actions for navigator

Definition at line 210 of file swiftguistd.cpp.

◆ getToggleWindowVisibilityAction()

QAction * SwiftGuiStd::getToggleWindowVisibilityAction ( QObject *  parent)
protected

Get a minimize action which minimizes the window.

Actions for navigator

Definition at line 201 of file swiftguistd.cpp.

◆ getWindowMinimizeAction()

QAction * SwiftGuiStd::getWindowMinimizeAction ( QObject *  parent)
protected

Get a minimize action which minimizes the window.

Actions for navigator

Definition at line 183 of file swiftguistd.cpp.

◆ getWindowNormalAction()

QAction * SwiftGuiStd::getWindowNormalAction ( QObject *  parent)
protected

Get a minimize action which minimizes the window.

Actions for navigator

Definition at line 192 of file swiftguistd.cpp.

◆ mouseMoveEvent()

void SwiftGuiStd::mouseMoveEvent ( QMouseEvent *  event)
protectedvirtual

Definition at line 91 of file swiftguistd.cpp.

◆ mousePressEvent()

void SwiftGuiStd::mousePressEvent ( QMouseEvent *  event)
protectedvirtual

Definition at line 96 of file swiftguistd.cpp.

◆ mouseReleaseEvent()

void SwiftGuiStd::mouseReleaseEvent ( QMouseEvent *  event)
protectedvirtual

Definition at line 101 of file swiftguistd.cpp.


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