xtd 0.2.0
status_bar_without_panels.cpp

demonstrates the use of xtd::forms::tool_bar component.

Windows

macOS

Gnome

#include <xtd/drawing/system_colors>
#include <xtd/forms/application>
#include <xtd/forms/form>
#include <xtd/forms/status_bar>
using namespace xtd;
using namespace xtd::forms;
namespace status_bar_without_panels_example {
class form1 : public form {
public:
form1() {
size({400, 250});
text("Status bar without panels example");
mouse_click += [&](object& sender, const mouse_event_args& e) {
status_bar1.text(string::format("Mouse click at location : {}", e.location()));
};
status_bar1.parent(*this);
status_bar1.back_color(drawing::system_colors::control());
status_bar1.text("Click anywhere on the client form...");
}
private:
forms::status_bar status_bar1;
};
}
auto main() -> int {
application::run(status_bar_without_panels_example::form1 {});
}
static xtd::drawing::color control()
Gets a xtd::drawing::color structure that is the face color of a 3-D element.
static void run()
Begins running a standard application message loop on the current thread, without a form.
Represents a window or dialog box that makes up an application's user interface.
Definition form.hpp:54
Provides data for the xtd::forms::control::mouse_up, xtd::forms::control::mouse_down,...
Definition mouse_event_args.hpp:34
Represents a Windows status bar control.
Definition status_bar.hpp:48
size_t size
Represents a size of any object in bytes.
Definition size.hpp:23
@ e
The E key.
Definition console_key.hpp:96
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition texts.hpp:217
Contains classes that represent ASCII and Unicode character encodings; abstract base classes for conv...
Definition basic_string_builder.hpp:16
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8