Code

Avoid crashing when profile is missing. Addresses main symptom of bug #437927.
[inkscape.git] / src / application / application.h
1 /** @file
2  * @brief  The top level class for managing the application.
3  */
4 /* Authors:
5  *   Bryce W. Harrington <bryce@bryceharrington.org>
6  *   Ralf Stephan <ralf@ark.in-berlin.de>
7  *
8  * Copyright (C) 2005 Authors
9  *
10  * Released under GNU GPL.  Read the file 'COPYING' for more information.
11  */
13 #ifndef INKSCAPE_APPLICATION_APPLICATION_H
14 #define INKSCAPE_APPLICATION_APPLICATION_H
16 #include <glib/gtypes.h>
18 namespace Gtk {
19 class Main;
20 }
22 namespace Inkscape {
23 namespace NSApplication {
24 class AppPrototype;
26 class Application
27 {
28 public:
29     Application(int argc, char **argv, bool use_gui=true, bool new_gui=false);
30     virtual ~Application();
32     gchar const *homedir() const;
34     gint run();
36     static bool getUseGui();
37     static bool getNewGui();
38     static void exit();
39     
40 protected:
41     Application(Application const &);
42     Application& operator=(Application const &);
44     gint            _argc;
45     char           **_argv;
46     AppPrototype   *_app_impl;
48     mutable gchar  *_path_home;
49 };
51 } // namespace NSApplication
52 } // namespace Inkscape
54 #endif /* !INKSCAPE_APPLICATION_APPLICATION_H */
56 /*
57   Local Variables:
58   mode:c++
59   c-file-style:"stroustrup"
60   c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
61   indent-tabs-mode:nil
62   fill-column:99
63   End:
64 */
65 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :