Commit 15a011e0879842f1eab6a89bbb5a608be1906607

Authored by tatiana
1 parent 22ac2c8f

ENH: Error messages are being saved into file when InVesalius is runned from win exe

invesalius/gui/dialogs.py
  1 +#!/usr/bin/env python
  2 +# -*- coding: UTF-8 -*-
1 #-------------------------------------------------------------------------- 3 #--------------------------------------------------------------------------
2 # Software: InVesalius - Software de Reconstrucao 3D de Imagens Medicas 4 # Software: InVesalius - Software de Reconstrucao 3D de Imagens Medicas
3 # Copyright: (C) 2001 Centro de Pesquisas Renato Archer 5 # Copyright: (C) 2001 Centro de Pesquisas Renato Archer
@@ -455,15 +457,14 @@ def ShowAboutDialog(parent): @@ -455,15 +457,14 @@ def ShowAboutDialog(parent):
455 info = wx.AboutDialogInfo() 457 info = wx.AboutDialogInfo()
456 info.Name = "InVesalius" 458 info.Name = "InVesalius"
457 info.Version = "3.0 - Beta 1" 459 info.Version = "3.0 - Beta 1"
458 - info.Copyright = _("(c) 2007-2010 Center for Information Technology Renato Archer") 460 + info.Copyright = _("(c) 2007-2010 Renato Archer Information Technology Centre")
459 info.Description = wordwrap( 461 info.Description = wordwrap(
460 _("InVesalius is a software for medical imaging 3D reconstruction. ")+\ 462 _("InVesalius is a software for medical imaging 3D reconstruction. ")+\
461 _("Its input is a sequency of DICOM 2D image files acquired with CT or MR.\n\n")+\ 463 _("Its input is a sequency of DICOM 2D image files acquired with CT or MR.\n\n")+\
462 _("The software also allows generating correspondent STL files,")+\ 464 _("The software also allows generating correspondent STL files,")+\
463 _("so the user can print 3D physical models of the patient's anatomy ")+\ 465 _("so the user can print 3D physical models of the patient's anatomy ")+\
464 _("using Rapid Prototyping."), 350, wx.ClientDC(parent)) 466 _("using Rapid Prototyping."), 350, wx.ClientDC(parent))
465 - info.WebSite = ("http://www.softwarepublico.gov.br/",  
466 - "InVesalius Community") 467 + info.WebSite = ("http://svn.softwarepublico.gov.br/trac/invesalius")
467 info.License = _("GNU GPL (General Public License) version 2") 468 info.License = _("GNU GPL (General Public License) version 2")
468 469
469 #info.Translators = "" 470 #info.Translators = ""
@@ -472,6 +473,11 @@ def ShowAboutDialog(parent): @@ -472,6 +473,11 @@ def ShowAboutDialog(parent):
472 "Paulo Henrique Junqueira Amorim", 473 "Paulo Henrique Junqueira Amorim",
473 "Thiago Franco de Moraes"] 474 "Thiago Franco de Moraes"]
474 #info.DocWriters = 475 #info.DocWriters =
  476 + info.Translators = ["Alex P. Natsios (GR)",
  477 + "Andreas Loupasakis (GR)",
  478 + "Dimitris Glezos (GR)",
  479 + u"Frédéric Lopez (FR)",
  480 + "Nikos Korkakakis (GR)"]
475 481
476 # Then we call wx.AboutBox giving its info object 482 # Then we call wx.AboutBox giving its info object
477 wx.AboutBox(info) 483 wx.AboutBox(info)
invesalius/invesalius.py
@@ -238,9 +238,10 @@ if __name__ == '__main__': @@ -238,9 +238,10 @@ if __name__ == '__main__':
238 if not os.path.isdir(dirpath): 238 if not os.path.isdir(dirpath):
239 os.makedirs(dirpath) 239 os.makedirs(dirpath)
240 240
241 - # Set system standard error output to file  
242 - path = os.path.join(dirpath, "stderr.log")  
243 - sys.stderr = open(path, "w") 241 + if sys.frozen == "windows_exe":
  242 + # Set system standard error output to file
  243 + path = os.path.join(dirpath, "stderr.log")
  244 + sys.stderr = open(path, "w")
244 245
245 # Add current directory to PYTHONPATH, so other classes can 246 # Add current directory to PYTHONPATH, so other classes can
246 # import modules as they were on root invesalius folder 247 # import modules as they were on root invesalius folder