#include <gcu/application.h>
Public Member Functions | |
Application (string name, string datadir=DATADIR, char const *help_name=NULL, char const *icon_name=NULL) | |
void | OnHelp (string s="") |
bool | HasHelp () |
string & | GetName () |
virtual GtkWindow * | GetWindow () |
virtual bool | FileProcess (const gchar *filename, const gchar *mime_type, bool bSave, GtkWindow *window, Document *pDoc=NULL) |
char const * | GetCurDir () |
void | SetCurDir (char const *dir) |
void | OnBug (char *uri=PACKAGE_BUGREPORT) |
void | OnWeb (char *uri="http://gchemutils.nongnu.org/") |
bool | HasMailAgent () |
bool | HasWebBrowser () |
void | AddDocument (Document *Doc) |
void | RemoveDocument (Document *Doc) |
virtual void | NoMoreDocsEvent () |
Protected Attributes | |
string | WebBrowser |
string | MailAgent |
set< Document * > | m_Docs |
Definition at line 42 of file application.h.
gcu::Application::Application | ( | string | name, | |
string | datadir = DATADIR , |
|||
char const * | help_name = NULL , |
|||
char const * | icon_name = NULL | |||
) |
name,: | the name of the application. | |
datadir,: | where data for the application are stored. | |
help_name,: | the name to use for the help file (with .xml extension). If NULL, the name strng is used. | |
icon_name,: | the name to use for the default icon of all windows. If NULL, the help_name or name parameters will be used. |
virtual bool gcu::Application::FileProcess | ( | const gchar * | filename, | |
const gchar * | mime_type, | |||
bool | bSave, | |||
GtkWindow * | window, | |||
Document * | pDoc = NULL | |||
) | [inline, virtual] |
filename,: | the uri of the file. | |
mime-type,: | the mime type of the file if known. | |
bSave,: | true if saving, and false if loading. | |
window,: | the current top level window. | |
pDoc,: | an optional document. |
Definition at line 95 of file application.h.
char const* gcu::Application::GetCurDir | ( | ) | [inline] |
string& gcu::Application::GetName | ( | ) | [inline] |
Definition at line 75 of file application.h.
virtual GtkWindow* gcu::Application::GetWindow | ( | ) | [inline, virtual] |
Definition at line 80 of file application.h.
bool gcu::Application::HasHelp | ( | ) |
void gcu::Application::OnHelp | ( | string | s = "" |
) |
s,: | an optional tag in the help file. Displays the help file using the file browser retrieved from GConf using the "/desktop/gnome/applications/help_viewer/exec" key. If a tag is given, it will be added to the help uri. For an application named "myapp" and a tag "mytag", the uri will be: helpfilename::myapp-mytag. |
void gcu::Application::SetCurDir | ( | char const * | dir | ) |
dir,: | the path to the new current directory. |