From d8aec8f55b90dd7e50d69c307cee17c358b1f5a9 Mon Sep 17 00:00:00 2001 From: tatiana Date: Tue, 26 Jan 2010 19:15:01 +0000 Subject: [PATCH] ADD: User manual --- .gitattributes | 1 + docs/user_guide_invesalius3a.pdf | Bin 0 -> 7559529 bytes invesalius/constants.py | 2 ++ invesalius/gui/frame.py | 16 +++++++++++++++- samples/Cranium.inv3 | Bin 14604711 -> 0 bytes 5 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 docs/user_guide_invesalius3a.pdf diff --git a/.gitattributes b/.gitattributes index e6274cb..0501f9b 100644 --- a/.gitattributes +++ b/.gitattributes @@ -14,6 +14,7 @@ docs/devel/example_singleton.py -text docs/devel/example_singleton_pubsub.py -text docs/devel/sendmessages.txt -text docs/devel/subscribes.txt -text +docs/user_guide_invesalius3a.pdf -text i18n/de.po -text i18n/el.po -text i18n/en.po -text diff --git a/docs/user_guide_invesalius3a.pdf b/docs/user_guide_invesalius3a.pdf new file mode 100644 index 0000000..ef0fe94 Binary files /dev/null and b/docs/user_guide_invesalius3a.pdf differ diff --git a/invesalius/constants.py b/invesalius/constants.py index f8110be..73881b4 100644 --- a/invesalius/constants.py +++ b/invesalius/constants.py @@ -254,6 +254,7 @@ REDUCE_IMAGEDATA_QUALITY = 0 ICON_DIR = os.path.abspath(os.path.join('..', 'icons')) SAMPLE_DIR = os.path.abspath(os.path.join('..', 'samples')) +DOC_DIR = os.path.abspath(os.path.join('..', 'docs')) ID_TO_BMP = {VOL_FRONT: [_("Front"), os.path.join(ICON_DIR, "view_front.png")], @@ -409,6 +410,7 @@ ID_PRINT_SCREENSHOT, ID_EXIT] = [wx.NewId() for number in range(10)] [wx.NewId() for number in range(3)] ID_ABOUT = wx.NewId() +ID_START = wx.NewId() #--------------------------------------------------------- STATE_DEFAULT = 1000 diff --git a/invesalius/gui/frame.py b/invesalius/gui/frame.py index 4aeb568..4368799 100755 --- a/invesalius/gui/frame.py +++ b/invesalius/gui/frame.py @@ -248,6 +248,20 @@ class Frame(wx.Frame): # self.OnExit(evt) elif id == const.ID_ABOUT: self.ShowAbout() + elif id == const.ID_START: + self.GettingStarted() + + def GettingStarted(self): + #if sys.platform == 'win32': + # os.filestart() + #else: + # os.system("/usr/bin/xdg-open %s" % nome_file) + + import webbrowser + path = os.path.join(const.DOC_DIR, "user_guide_invesalius3a.pdf") + webbrowser.open(path) + + def ShowAbout(self): dlg.ShowAboutDialog(self) @@ -358,7 +372,7 @@ class MenuBar(wx.MenuBar): # HELP help_menu = wx.Menu() - help_menu.Append(105, _("Getting Started...")) + help_menu.Append(const.ID_START, _("Getting Started...")) #help_menu.Append(108, "User Manual...") help_menu.AppendSeparator() help_menu.Append(const.ID_ABOUT, _("About...")) diff --git a/samples/Cranium.inv3 b/samples/Cranium.inv3 index 71591fe..1ad95ee 100644 Binary files a/samples/Cranium.inv3 and b/samples/Cranium.inv3 differ -- libgit2 0.21.2