The Gnome Chemistry Utils  0.14.0
Public Member Functions | List of all members
gcp::Tools Class Reference

#include <tools.h>

Inheritance diagram for gcp::Tools:
gcugtk::Dialog gcugtk::UIBuilder gcu::Dialog

Public Member Functions

 Tools (Application *App)
virtual ~Tools ()
void Show (bool visible)
void AddToolbar (std::string &name)
void SetUIManager (gcugtk::UIManager *manager)
void SetPage (Tool *tool, int i)
void OnSelectTool (Tool *tool)
void RegisterTool (GtkWidget *w)
void OnElementChanged (int Z)
void SetElement (int Z)
void OnHelp ()
- Public Member Functions inherited from gcugtk::Dialog
 Dialog (Application *App, char const *filename, const char *windowname, char const *domainname, gcu::DialogOwner *owner=NULL, void(*extra_destroy)(gpointer)=NULL, gpointer data=NULL) throw (std::runtime_error)
virtual ~Dialog ()
virtual void Destroy ()
virtual bool Apply ()
virtual void Closed ()
GtkWindow * GetWindow ()
void Present ()
void SetTransientFor (GtkWindow *window)
- Public Member Functions inherited from gcugtk::UIBuilder
 UIBuilder (char const *filename, char const *domain) throw (std::runtime_error)
virtual ~UIBuilder ()
GtkWidget * GetWidget (char const *wname)
GtkWidget * GetRefdWidget (char const *wname)
GObject * GetObject (char const *name)
GtkBuilder * GetBuilder (void) const
- Public Member Functions inherited from gcu::Dialog
 Dialog (Application *App, const char *windowname, DialogOwner *owner=NULL) throw (std::runtime_error)
void SetRealName (char const *name, DialogOwner *owner) throw (std::runtime_error)
std::string & GetWindowName ()
ApplicationGetApp (void)

Additional Inherited Members

- Protected Member Functions inherited from gcugtk::Dialog
bool GetNumber (GtkEntry *Entry, double *x, CheckType c=NoCheck, double min=0, double max=0)
- Protected Attributes inherited from gcugtk::Dialog
GtkWindow * dialog

Detailed Description

class Tools gcp/tools.h The GChemPaint tools box. Only one instance should be created.

Definition at line 43 of file tools.h.

Constructor & Destructor Documentation

gcp::Tools::Tools ( Application App)
Parameters
Appthe GChemPaint Application.

Builds the tools box for the application.

virtual gcp::Tools::~Tools ( )
virtual

The destructor.

Member Function Documentation

void gcp::Tools::AddToolbar ( std::string &  name)
Parameters
namethe new toolbar name.

Addsa new toolbar.

void gcp::Tools::OnElementChanged ( int  Z)
Parameters
Zthe new current atomic number.

Called by the framework when the current atomic number has changed.

void gcp::Tools::OnHelp ( )

Called by the framework when the Help button is clicked.

void gcp::Tools::OnSelectTool ( Tool tool)
Parameters
toola Tool.

Called by the framwork when the Tool is selected. If the Tool has an option box, it becomes the active notebook page after being created if necessary.

void gcp::Tools::RegisterTool ( GtkWidget *  w)
Parameters
wthe tool widget, generally a button.

Registers the Tool corresponding to the widget. The widget name is used to retrieve the Tool from the application using gcp::Application::GetTool().

void gcp::Tools::SetElement ( int  Z)
Parameters
Zthe new current atomic number.

Called by the framework when the user choose a new current atomic number using the Mendeleiev table widget.

void gcp::Tools::SetPage ( Tool tool,
int  i 
)
Parameters
toolthe Tool for which an options page has been added.
ithe rank of the page in the notebook.

Registers the new option box for the tool, so that the widget is created only once when the tool is first selected.

void gcp::Tools::SetUIManager ( gcugtk::UIManager manager)
Parameters
managera gcu::UIManager.

Sets the gcugtk::UIManager associated to the user interface of the tools box.

void gcp::Tools::Show ( bool  visible)
Parameters
visiblewhether the tools box should be visible.

Shows or hides the tools box.


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