xtd 0.2.0
Loading...
Searching...
No Matches
xtd::forms::debug_message_box Class Reference
Inheritance diagram for xtd::forms::debug_message_box:
xtd::static_object

Definition

Displays a dialog box and write debug.

Header
#include <xtd/forms/debug_message_box>
Namespace
xtd::forms
Library
xtd.forms
Appearance
Windows macOS Gnome
Light  
 
 
 
 
 
Dark  
 
 
 
 
 
Examples
The following code example demonstrates the use of debug_message_box dialog.
#define DEBUG
#include <xtd/forms/application>
#include <xtd/forms/button>
#include <xtd/forms/debug_form>
#include <xtd/forms/debug_message_box>
#include <xtd/forms/form>
#include <xtd/startup>
using namespace xtd::forms;
class form_main : public form {
public:
form_main() {
button_.parent(*this);
button_.location({10, 10});
button_.text("Error...");
button_.click += [&] {
debug_message_box::show(*this, "An unknown process error occured.");
};
}
static auto main() {
auto df = debug_form {};
application::run(form_main {});
}
private:
button button_;
};
startup_(form_main::main);
Represents a Windows button control.
Definition button.h:49
virtual drawing::point location() const noexcept
Gets the coordinates of the upper-left corner of the control relative to the upper-left corner of its...
Represents a form that displays debug form. This class cannot be inherited.
Definition debug_form.h:36
Represents a window or dialog box that makes up an application's user interface.
Definition form.h:54
control & parent(const control &value) override
Sets the parent container of the control.
#define startup_(main_method)
Defines the entry point to be called when the application loads. Generally this is set either to the ...
Definition startup.h:175
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition xtd_about_box.h:12

Public Static Methods

static xtd::forms::dialog_result show (const xtd::string &text)
 Displays a message box and write debug with specified text.
 
static xtd::forms::dialog_result show (const xtd::forms::iwin32_window &owner, const xtd::string &text)
 Displays a message box in front of the specified window and write debug with specified text.
 

Member Function Documentation

◆ show() [1/2]

static xtd::forms::dialog_result xtd::forms::debug_message_box::show ( const xtd::string text)
inlinestatic

Displays a message box and write debug with specified text.

Parameters
textThe text to display in the message box.

◆ show() [2/2]

static xtd::forms::dialog_result xtd::forms::debug_message_box::show ( const xtd::forms::iwin32_window owner,
const xtd::string text 
)
inlinestatic

Displays a message box in front of the specified window and write debug with specified text.

Parameters
ownerAn implementation of iwin32_window that will own the modal dialog box.
textThe text to display in the message box.

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