Salome HOME
legere difference ds VARIABLES_TO_BE...
[tools/eficas.git] / Adao / configuration_Adao.py
1 # -*- coding: utf-8 -*-
2 #
3 # Copyright (C) 2008-2016 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: André Ribes, andre.ribes@edf.fr, EDF R&D
24
25 """
26     Ce module sert pour charger les paramètres de configuration d'EFICAS
27 """
28 # Modules Python
29 # print "passage dans la surcharge de configuration pour Adao"
30 import os, sys, string, types, re
31 import traceback
32 from daUtils.qtversion import useQT5
33 if useQT5:
34     from PyQt5.QtGui  import *
35 else:
36     from PyQt4.QtGui  import *
37
38 # Modules Eficas
39 from Editeur import utils
40 from InterfaceQT4 import configuration
41
42 # Classe de base permettant de lire, afficher
43 # et sauvegarder les fichiers utilisateurs
44 class CONFIG(configuration.CONFIG_BASE):
45
46   def __init__(self,appli,repIni):
47
48     #self.labels_eficas = ['lang']
49     self.labels_eficas=['lang','rep_cata','catalogues','closeAutreCommande','closeFrameRechercheCommande','closeEntete','taille']
50     configuration.CONFIG_BASE.__init__(self,appli,repIni)
51
52     self.rep_user = os.environ["HOME"]
53     self.appli   = appli
54     self.code    = appli.code
55     # self.lang    = "fr"
56     self.rep_ini = repIni
57     self.rep_mat=" " # Compatbilite Aster
58     self.savedir      = self.rep_user
59     self.generator_module = "generator_adao"
60     self.convert_module = "convert_adao"
61
62     # Format des catalogues...
63     # (code, version, catalogue, formatIn, formatOut)
64     # Il faut les mettre dans un tuple
65     self.catalogues = (("ADAO", "V0", os.path.join(self.rep_ini, 'ADAO_Cata_V0.py'), "adao"),)
66
67 def make_config(appli,rep):
68
69     return CONFIG(appli,rep)
70
71 def make_config_style(appli,rep):
72
73     return None