|
RADLib
RADical C++ application framework
|
Dock layout model for IDE-style tools. More...
#include <RADAppKit.h>
Inheritance diagram for RADUi::DockLayoutModel:
Collaboration diagram for RADUi::DockLayoutModel:Public Member Functions | |
| const std::vector< DockPanel > & | panels () const |
| Returns panel descriptors. More... | |
| void | setPanels (std::vector< DockPanel > panels) |
| Replaces panel descriptors. More... | |
| void | addPanel (DockPanel panel) |
| Adds one panel. More... | |
| bool | setVisible (const std::string &id, bool visible) |
| Shows or hides panel by id. More... | |
| bool | select (const std::string &id) |
| Selects panel by id and deselects siblings in the same area. More... | |
| bool | setSize (const std::string &id, double size) |
| Sets preferred panel size by id. More... | |
| RADCore::RADJsonValue | toJson () const |
| Serializes panel layout. More... | |
| void | fromJson (const RADCore::RADJsonValue &value) |
| Restores panel layout. More... | |
Public Member Functions inherited from RADCore::RADObject | |
| RADObject () | |
| Creates a RADObject bound to the current thread. More... | |
| virtual | ~RADObject () |
| Disconnects tracked event links and releases lifetime token. More... | |
| void | registerLink (const ConnectionRecord &record) |
| Registers a connection for cleanup when this object is destroyed. More... | |
| std::thread::id | threadId () const |
| Returns the thread id this object is currently associated with. More... | |
| EventLoop * | associatedEventLoop () const |
| Returns the associated event loop, if any. More... | |
| ThreadAffinity | threadAffinity () const |
| Returns both thread id and associated loop atomically. More... | |
| std::weak_ptr< void > | lifetimeToken () const |
| Returns a weak token used to drop queued callbacks after destruction. More... | |
| void | moveToThread (std::thread::id tId, EventLoop *loop=nullptr) |
| Moves the object's affinity to tId and optional loop. More... | |
Public Attributes | |
| RADCore::Event< void() > | changed |
| Raised when panel state changes. More... | |
Dock layout model for IDE-style tools.
| void RADUi::DockLayoutModel::addPanel | ( | DockPanel | panel | ) |
Adds one panel.
| void RADUi::DockLayoutModel::fromJson | ( | const RADCore::RADJsonValue & | value | ) |
Restores panel layout.
| const std::vector<DockPanel>& RADUi::DockLayoutModel::panels | ( | ) | const |
Returns panel descriptors.
| bool RADUi::DockLayoutModel::select | ( | const std::string & | id | ) |
Selects panel by id and deselects siblings in the same area.
| void RADUi::DockLayoutModel::setPanels | ( | std::vector< DockPanel > | panels | ) |
Replaces panel descriptors.
| bool RADUi::DockLayoutModel::setSize | ( | const std::string & | id, |
| double | size | ||
| ) |
Sets preferred panel size by id.
| bool RADUi::DockLayoutModel::setVisible | ( | const std::string & | id, |
| bool | visible | ||
| ) |
Shows or hides panel by id.
| RADCore::RADJsonValue RADUi::DockLayoutModel::toJson | ( | ) | const |
Serializes panel layout.
| RADCore::Event<void () > RADUi::DockLayoutModel::changed |
Raised when panel state changes.