MQWindowBase class

(new in Rev4.00)

MQWindowBase class is a base class for a window and a dialog. It inherits a MQWidgetBase class.

Please refer the inherited class about member functions declared in the inherited class.

Class
MQWindowBase Constructor
~MQWindowBase Destructor
Member functions
AddChildWindow Add a child window
RemoveChildWindow Remove a child window
CreateHorizontalFrame Create a horizontal frame
CreateVerticalFrame Create a vertical frame
CreateGroupBox Create a group box
CreateTab Create a tab
CreateButton Create a button
CreateCheckBox Create a check box
CreateRadioButton Create a radio button
CreateComboBox Create a combo box
CreateListBox Create a list box
CreateLabel Create a label
CreateEdit Create an input area for a text
CreateMemo Create an input area for multiple-line text
CreateSpinBox Create an input area for an integer
CreateDoubleSpinBox Create an input area for a real number
CreateSlider Create a slider
CreateScrollBar Create a scroll bar
CreateScrollBox Create a scroll box
CreateColorPanel Create a color panel
CreatePaintBox Create a paint box
DeleteWidget Delete a widget
SetModal Set a modal status
ReleaseModal Release a modal status
IsModal Get a modal status
GetTitle Get a title
SetTitle Set a title
GetPosX Get a X position
SetPosX Set a X position
GetPosY Get a Y position
SetPosY Set a Y position
GetWindowFrame Get a window frame displaying
SetWindowFrame Set a window frame displaying
GetTitleBar Get a title bar displaying
SetTitleBar Set a title bar displaying
GetCanResize Get whether a window can resize or not
SetCanResize Set whether a window can resize or not
GetCloseButton Get a close button displaying
SetCloseButton Set a close button displaying
GetMaximizeButton Get a maximize button displaying
SetMaximizeButton Set a maximize button displaying
GetMinimizeButton Get a minimize button displaying
SetMinimizeButton Set a minimize button displaying
GetMaximized Get a maximized state
SetMaximized Set a maximized state
GetMinimized Get a minimized state
SetMinimized Set a minimized state
GetBackColor Get a background color
SetBackColor Set a background color
GetAlphaBlend Get an alpha blend value
SetAlphaBlend Set an alpha blend value

MQWindowBase::MQWindowBase();

MQWindowBase::MQWindowBase(int id);

id
A widget ID created outside the plug-in

It is a constructor.

This class cannot be created directly because 'protected' accessor is specified.


virtual MQWindowBase::~MQWindowBase();

This method is a destructor. It is defined as a virtual function.


void MQWindowBase::AddChildWindow(MQWindowBase *child);

child
A child window

It add a child window.

A child window always shows in the front of the parent window.。


void MQWindowBase::RemoveChildWindow(MQWindowBase *child);

child
A child window

It separates the child window from this parent window.

The separated window will be displayed on the desktop.


MQFrame *MQWindowBase::CreateHorizontalFrame(MQWidgetBase *parent);

parent
A parent widget
Return value
A created frame

It creates a horizontal frame as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQFrame *MQWindowBase::CreateVerticalFrame(MQWidgetBase *parent);

parent
A parent widget
Return value
A created frame

It creates a vertical frame as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQGroupBox *MQWindowBase::CreateGroupBox(MQWidgetBase *parent, const std::wstring& str = std::wstring());

parent
A parent widget
str
A group box's title
Return value
A created group box

It creates a group box as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQTab *MQWindowBase::CreateTab(MQWidgetBase *parent);

parent
A parent widget
Return value
A created tab

It creates a tab as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQButton *MQWindowBase::CreateButton(MQWidgetBase *parent, const std::wstring& str = std::wstring());

parent
A parent widget
Return value
A created button

It creates a button as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQCheckBox *MQWindowBase::CreateCheckBox(MQWidgetBase *parent, const std::wstring& str = std::wstring());

parent
A parent widget
Return value
A created check box

It creates a check box as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQRadioButton *MQWindowBase::CreateRadioButton(MQWidgetBase *parent, const std::wstring& str = std::wstring());

parent
A parent widget
Return value
A created radio button

It creates a radio button as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQComboBox *MQWindowBase::CreateComboBox(MQWidgetBase *parent);

parent
A parent widget
Return value
A created combo box

It creates a combo box as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQListBox *MQWindowBase::CreateListBox(MQWidgetBase *parent);

parent
A parent widget
Return value
A created list box

It creates a list box as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQLabel *MQWindowBase::CreateLabel(MQWidgetBase *parent, const std::wstring& str = std::wstring());

parent
A parent widget
Return value
A created label

It creates a label as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQEdit *MQWindowBase::CreateEdit(MQWidgetBase *parent, const std::wstring& str = std::wstring());

parent
A parent widget
Return value
A created edit

It creates an edit as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQMemo *MQWindowBase::CreateMemo(MQWidgetBase *parent);

parent
A parent widget
Return value
A created memo

It creates a memo as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQSpinBox *MQWindowBase::CreateSpinBox(MQWidgetBase *parent);

parent
A parent widget
Return value
A created spin box

It creates a spin box as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQDoubleSpinBox *MQWindowBase::CreateDoubleSpinBox(MQWidgetBase *parent);

parent
A parent widget
Return value
A created double spin box

It creates a double spin box as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQSlider *MQWindowBase::CreateSlider(MQWidgetBase *parent);

parent
A parent widget
Return value
A created slider

It creates a slider as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQScrollBar *MQWindowBase::CreateScrollBar(MQWidgetBase *parent);

parent
A parent widget
Return value
A created scroll bar

It creates a scroll bar as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQScrollBox *MQWindowBase::CreateScrollBox(MQWidgetBase *parent);

parent
A parent widget
Return value
A created scroll box

It creates a scroll box as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQColorPanel *MQWindowBase::CreateColorPanel(MQWidgetBase *parent);

parent
A parent widget
Return value
A created color panel

It creates a color panel as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


MQPaintBox *MQWindowBase::CreatePaintBox(MQWidgetBase *parent);

parent
A parent widget
Return value
A created paint box

It creates a paint box as a child of the specified parent widget.

The widget created by this function must be deleted by calling not 'delete' operator but DeleteWidget().


void MQWindowBase::DeleteWidget(MQWidgetBase *widget);

widget
A deleting widget

It deletes a widget created by member functions in MQWindowBase class.


void MQWindowBase::SetModal();

It sets a modal status to the window. When a window has a modal status, operations for other windows are disabled. Only operations for this window are performed.


void MQWindowBase::ReleaseModal();

It releases a modal status for the window.


bool MQWindowBase::IsModal();

Return value
A modal status

It returns whether a window has a modal status or not.


std::wstring MQWindowBase::GetTitle();

Return value
A title string

It returns a string displayed in a title bar.


void MQWindowBase::SetTitle(const std::wstring& text);

text
A title string

It specifies a string displayed in a title bar.


int MQWindowBase::GetPosX();

Return value
X position

(new in Rev4.10)

It returns a X position of a window.


void MQWindowBase::SetPosX(int value);

value
X position

(new in Rev4.10)

It specifies a X position of a window.


int MQWindowBase::GetPosY();

Return value
Y position

(new in Rev4.10)

It returns a Y position of a window.


void MQWindowBase::SetPosY(int value);

value
Y position

(new in Rev4.10)

It specifies a Y position of a window.


bool MQWindowBase::GetWindowFrame();

Return value
A window frame displaying

It returns whether a border frame of a window is displayed or not.

By Windows' specification, an actual displaying state may be different from this value depending on other states.


void MQWindowBase::SetWindowFrame(bool value);

value
A window frame displaying

It specifies whether a border frame of a window is displayed or not.


bool MQWindowBase::GetTitleBar();

Return value
A title bar displaying

It returns whether a title bar at the top of the window is displayed or not.

By Windows' specification, an actual displaying state may be different from this value depending on other states.


void MQWindowBase::SetTitleBar(bool value);

value
A title bar displaying

It specifies whether a title bar at the top of the window is displayed or not.


bool MQWindowBase::GetCanResize();

Return value
Whether a window can be resized or not

It returns whether a window can be resized or not by dragging a border frame.


void MQWindowBase::SetCanResize(bool value);

value
Whether a window can be resized or not

It specifies whether a window can be resized or not by dragging a border frame.


bool MQWindowBase::GetCloseButton();

Return value
A close button displaying

It returns whether a close button at the left-top of the window is displayed or not.

By Windows' specification, an actual displaying state may be different from this value depending on other states.


void MQWindowBase::SetCloseButton(bool value);

value
A close button displaying

It specifies whether a close button at the left-top of the window is displayed or not.


bool MQWindowBase::GetMaximizeButton();

Return value
A maximized button displaying

It returns whether a maximize button at the left-top of the window is displayed or not.

By Windows' specification, an actual displaying state may be different from this value depending on other states.


void MQWindowBase::SetMaximizeButton(bool value);

value
A maximized button displaying

It specifies whether a maximize button at the left-top of the window is displayed or not.


bool MQWindowBase::GetMinimizeButton();

Return value
A minimized button displaying

It returns whether a minimize button at the left-top of the window is displayed or not.

By Windows' specification, an actual displaying state may be different from this value depending on other states.


void MQWindowBase::SetMinimizeButton(bool value);

value
A minimized button displaying

It specifies whether a minimize button at the left-top of the window is displayed or not.


bool MQWindowBase::GetMaximized();

Return value
A window maximized state

It returns whether a window is maximized or not.


void MQWindowBase::SetMaximized(bool value);

value
A window maximized state

It specifies whether a window is maximized or not.


bool MQWindowBase::GetMinimized();

Return value
A window minimized state

It returns whether a window is minimized or not.


void MQWindowBase::SetMinimized(bool value);

value
A window minimized state

It specifies whether a window is minimized or not.


void MQWindowBase::GetBackColor(int& r, int& g, int& b);

r
Red [0:255]
g
Green [0:255]
b
Blue [0:255]

It returns a background color.


void MQWindowBase::SetBackColor(int r, int g, int b);

r
Red [0:255]
g
Green [0:255]
b
Blue [0:255]

It specifies a background color.


int MQWindowBase::GetAlphaBlend();

Return value
An alpha blend value [0:255]

It returns an alpha blend value for a semi-transparent window.


void MQWindowBase::SetAlphaBlend(int value);

value
An alpha blend value [0:255]

It specifies an alpha blend value for a semi-transparent window.