MySQL Workbench  6.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
mforms::Wizard Class Reference

#include <wizard.h>

Inheritance diagram for mforms::Wizard:
mforms::Form mforms::View

Public Member Functions

 Wizard (Form *owner)
 
virtual ~Wizard ()
 
virtual void set_title (const std::string &title)
 Sets the title of the window. More...
 
virtual void run ()
 
virtual void close ()
 set_content should place view as a wizard's current page. More...
 
virtual void set_content (View *view)
 Sets the content view of the window. More...
 
void set_heading (const std::string &text)
 1st char of each step title must be . for executed tasks, * for current and - for not executed More...
 
void set_step_list (const std::vector< std::string > &steps)
 
void set_allow_cancel (bool flag)
 
void set_allow_back (bool flag)
 
void set_allow_next (bool flag)
 
void set_show_extra (bool flag)
 
void set_extra_caption (const std::string &caption)
 
void set_next_caption (const std::string &caption="")
 
- Public Member Functions inherited from mforms::Form
 Form (Form *owner, FormFlag flag=(FormFlag)(FormResizable|FormMinimizable))
 Constructor. More...
 
virtual ~Form ()
 
virtual void center ()
 Centers the window in the screen. More...
 
virtual void flush_events ()
 Iterate over all events that were queuedand flush them, results in faster gui updates or faster signal calls. More...
 
void set_release_on_close (bool flag)
 Sets whether the window must be automatically released when closed. More...
 
boost::signals2::signal< void()> * signal_closed ()
 Signal sent when the user clicks the close button in the window. More...
 
boost::signals2::signal< void()> * signal_activated ()
 Signal sent when the window becomes the active window. More...
 
boost::signals2::signal< void()> * signal_deactivated ()
 
void activated ()
 
void deactivated ()
 
bool is_active ()
 
void was_closed ()
 
- Public Member Functions inherited from mforms::View
virtual ~View ()
 
virtual void set_managed ()
 
Viewfind_subview (const std::string &name)
 
bool contains_subview (View *subview)
 
void clear_subviews ()
 
void set_name (const std::string &name)
 
void set_tooltip (const std::string &text)
 
void set_font (const std::string &fontDescription)
 
std::string get_name ()
 
void set_parent (View *parent)
 
Viewget_parent () const
 
Formget_parent_form () const
 
virtual int get_width ()
 
virtual int get_height ()
 
virtual int get_preferred_width ()
 
virtual int get_preferred_height ()
 
virtual int get_x ()
 
virtual int get_y ()
 
virtual void set_position (int x, int y)
 
virtual void set_size (int width, int height)
 
std::pair< int, int > client_to_screen (int x, int y)
 
std::pair< int, int > screen_to_client (int x, int y)
 
void show (bool flag=true)
 Show/hide view. More...
 
bool is_shown ()
 Check whenever view is visible. More...
 
bool is_fully_visible ()
 Returns true if the view and all it's parents are visible. More...
 
void set_enabled (bool flag)
 Enable view so user can interact with it. More...
 
bool is_enabled ()
 Check whenever view is enabled. More...
 
void set_needs_repaint ()
 Mark view to be repainted with next iteration. More...
 
virtual void relayout ()
 
virtual void set_layout_dirty (bool value)
 
virtual bool is_layout_dirty ()
 
void suspend_layout ()
 Freeze gui updates for this view. More...
 
void resume_layout ()
 Resume gui updates for this view. More...
 
void set_front_color (const std::string &color)
 Set view foreground color. More...
 
std::string get_front_color ()
 Get view foreground color. More...
 
void set_back_color (const std::string &color)
 Set view background color. More...
 
std::string get_back_color ()
 Get view background color. More...
 
virtual std::string get_string_value ()
 Get string value from the view if it's holding some. More...
 
virtual int get_int_value ()
 Get int value from the view if it's holding some. More...
 
virtual bool get_bool_value ()
 Get bool value from the view if it's holding some. More...
 
virtual void focus ()
 Causes view to have keyboard focus. More...
 
void register_drop_formats (DropDelegate *target, const std::vector< std::string > &drop_formats)
 Enables or disables the ability to accept a drag/drop operation (internal or from outside) based on drop_formats. More...
 
DragOperation do_drag_drop (DragDetails details, const std::string &text)
 Starts an internal drag/drop operation with the given text/data and blocks until that op is finished. More...
 
DragOperation do_drag_drop (DragDetails details, void *data, const std::string &format)
 
void focus_changed ()
 
virtual void resize ()
 Triggered by the platform layers when the size of the view changes. More...
 
boost::signals2::signal< void()> * signal_resized ()
 

Protected Attributes

boost::signals2::signal< void()> _back_signal
 
boost::signals2::signal< void()> _next_signal
 
boost::signals2::signal< void()> _extra_signal
 
- Protected Attributes inherited from mforms::View
ViewImplPtrs * _view_impl
 
View_parent
 
std::vector< std::pair< View
*, bool > > 
_subviews
 

Private Member Functions

 Wizard ()
 
 Wizard (Form *owner, FormFlag flag)
 
virtual bool run_modal (Button *accept, Button *cancel)
 Shows the window as a modal window. More...
 
virtual void show_modal (Button *accept, Button *cancel)
 Deprecated. More...
 
virtual void end_modal (bool result)
 Ends a modal session started with run_modal() More...
 

Private Attributes

WizardImplPtrs * _wizard_impl
 
View_content
 

Additional Inherited Members

- Static Public Member Functions inherited from mforms::Form
static Formmain_form ()
 Used to specify the main form to the Form() constructor. More...
 
- Protected Member Functions inherited from mforms::Form
 Form ()
 
- Protected Member Functions inherited from mforms::View
 View ()
 
void cache_view (View *sv)
 
virtual void remove_from_cache (View *sv)
 
int get_subview_index (View *sv)
 
Viewget_subview_at_index (int index)
 
virtual void set_back_image (const std::string &path, Alignment alignment)
 

Detailed Description

Definition at line 54 of file wizard.h.

Constructor & Destructor Documentation

mforms::Wizard::Wizard ( )
private
mforms::Wizard::Wizard ( Form owner,
FormFlag  flag 
)
inlineprivate

Definition at line 65 of file wizard.h.

65 {}
mforms::Wizard::Wizard ( Form owner)
virtual mforms::Wizard::~Wizard ( )
virtual

Member Function Documentation

virtual void mforms::Wizard::close ( )
virtual

set_content should place view as a wizard's current page.

Note: When view is 0, then content should be removed

Reimplemented from mforms::Form.

virtual void mforms::Wizard::end_modal ( bool  result)
inlineprivatevirtual

Ends a modal session started with run_modal()

This function is automatically called if accept and cancel buttons are given to run_modal.

Parameters
result- the result to be returned by run_modal

Reimplemented from mforms::Form.

Definition at line 68 of file wizard.h.

68 {}
virtual void mforms::Wizard::run ( )
virtual
virtual bool mforms::Wizard::run_modal ( Button accept,
Button cancel 
)
inlineprivatevirtual

Shows the window as a modal window.

Parameters
accept- a button to be used as the default accept button (ie when user presses Return key) or None
cancel- button to be used as cancel button (ie when user presses Escape key) or None

Reimplemented from mforms::Form.

Definition at line 66 of file wizard.h.

66 { return false; }
void mforms::Wizard::set_allow_back ( bool  flag)
void mforms::Wizard::set_allow_cancel ( bool  flag)
void mforms::Wizard::set_allow_next ( bool  flag)
virtual void mforms::Wizard::set_content ( View view)
virtual

Sets the content view of the window.

Usually a layouting container, such as a Box or a Table.

Reimplemented from mforms::Form.

void mforms::Wizard::set_extra_caption ( const std::string &  caption)
void mforms::Wizard::set_heading ( const std::string &  text)

1st char of each step title must be . for executed tasks, * for current and - for not executed

void mforms::Wizard::set_next_caption ( const std::string &  caption = "")
void mforms::Wizard::set_show_extra ( bool  flag)
void mforms::Wizard::set_step_list ( const std::vector< std::string > &  steps)
virtual void mforms::Wizard::set_title ( const std::string &  title)
virtual

Sets the title of the window.

Reimplemented from mforms::Form.

virtual void mforms::Wizard::show_modal ( Button accept,
Button cancel 
)
inlineprivatevirtual

Deprecated.

Reimplemented from mforms::Form.

Definition at line 67 of file wizard.h.

67 {}

Member Data Documentation

boost::signals2::signal<void ()> mforms::Wizard::_back_signal
protected

Definition at line 118 of file wizard.h.

View* mforms::Wizard::_content
private

Definition at line 59 of file wizard.h.

boost::signals2::signal<void ()> mforms::Wizard::_extra_signal
protected

Definition at line 120 of file wizard.h.

boost::signals2::signal<void ()> mforms::Wizard::_next_signal
protected

Definition at line 119 of file wizard.h.

WizardImplPtrs* mforms::Wizard::_wizard_impl
private

Definition at line 58 of file wizard.h.


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