Salome HOME
Documentation and code minor corrections
[modules/adao.git] / src / daEficas / prefs_ADAO.py.in
1 # -*- coding: utf-8 -*-
2 #
3 # Copyright (C) 2008-2018 EDF R&D
4 #
5 # This file is part of SALOME ADAO module
6 #
7 # This library is free software; you can redistribute it and/or
8 # modify it under the terms of the GNU Lesser General Public
9 # License as published by the Free Software Foundation; either
10 # version 2.1 of the License.
11 #
12 # This library is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15 # Lesser General Public License for more details.
16 #
17 # You should have received a copy of the GNU Lesser General Public
18 # License along with this library; if not, write to the Free Software
19 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
20 #
21 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 #
23 # Author: Jean-Philippe Argaud, jean-philippe.argaud@edf.fr, EDF R&D
24
25 import os, sys
26
27 # print "import des prefs de Adao"
28 #
29 # Configuration de Eficas
30 # =======================
31 #
32 # INSTALLDIR, repIni est obligatoire
33 INSTALLDIR = "@EFICAS_DIR@"
34 sys.path.insert(0,INSTALLDIR)
35 #
36 # Positionnee a repin au debut, mise a jour dans configuration
37 repIni=os.path.dirname(os.path.abspath(__file__))
38 #
39 # Sert comme directory initial des QFileDialog
40 initialdir=os.environ["PWD"]
41 #
42 # Traductions et codages
43 #
44 # Codage des strings qui accepte les accents (en remplacement de 'ascii')
45 # encoding='utf-8'
46 #
47 # ===== Specifique : pour la 8_3_0 et suivantes 8_x ! Enlever pour les 9_x ! JPA
48 if sys.version.split()[0] < '3':
49     # ===== Specifique : redefinition de l'encoding avant le Python 3 ! JPA
50     reload(sys)
51     sys.setdefaultencoding('utf-8')
52     # ===== Specifique : pour les suivantes 8_x ! Enlever pour les 9_x ! JPA
53     # 19/05/2017 : Redefinition du hook de "sys" present dans <GUI/src/SUITApp/SUITApp_init_python.cxx>
54     def _custom_except_hook(exc_type, exc_value, exc_traceback):
55         import sys
56         sys.__excepthook__(exc_type, exc_value, exc_traceback)
57         pass
58     sys.excepthook = _custom_except_hook
59     del _custom_except_hook, sys
60 # ===== Fin specifique ===================================================== JPA
61 #
62 # Indique la langue du catalogue utilisee pour les chaines d'aide : fr ou ang
63 # lang = 'fr'
64 # Traduction des labels de boutons ou autres
65 translatorFichier = os.environ["ADAO_ROOT_DIR"] + "/share/salome/resources/adao/adao" # Ce nom sera complete par EFICAS avec _<LANG>.qm
66 #
67 # Pilotage des sous-fenetres d'EFICAS
68 closeAutreCommande = True
69 closeFrameRechercheCommande = True
70 closeEntete = True
71 closeArbre = True
72 taille = 800
73 nombreDeBoutonParLigne = 2
74