Salome HOME
Compatibility modification for EFICAS editor
[modules/adao.git] / src / daEficas / configuration_ADAO.py
1 # -*- coding: utf-8 -*-
2 # Copyright (C) 2010-2013 EDF R&D
3 #
4 # This library is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU Lesser General Public
6 # License as published by the Free Software Foundation; either
7 # version 2.1 of the License.
8 #
9 # This library is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12 # Lesser General Public License for more details.
13 #
14 # You should have received a copy of the GNU Lesser General Public
15 # License along with this library; if not, write to the Free Software
16 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
17 #
18 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
19 #
20 # Author: André Ribes, andre.ribes@edf.fr, EDF R&D
21
22 """
23     Ce module sert pour charger les paramètres de configuration d'EFICAS
24 """
25 # Modules Python
26 # print "passage dans la surcharge de configuration pour Adao"
27 import os, sys, string, types, re
28 import traceback
29 from PyQt4.QtGui  import *
30
31 # Modules Eficas
32 from Editeur import utils
33 from InterfaceQT4 import configuration
34
35 # Classe de base permettant de lire, afficher
36 # et sauvegarder les fichiers utilisateurs
37 class CONFIG(configuration.CONFIG_BASE):
38
39   def __init__(self,appli,repIni):
40
41     self.labels_eficas = ['lang']
42     configuration.CONFIG_BASE.__init__(self,appli,repIni)
43
44     self.rep_user = os.environ["HOME"]
45     self.appli   = appli
46     self.code    = appli.code
47     # self.lang    = "fr"
48     self.rep_ini = repIni
49     self.rep_mat=" " # Compatbilite Aster
50     self.savedir      = self.rep_user
51     self.generator_module = "generator_adao"
52     self.convert_module = "convert_adao"
53
54     # Format des catalogues...
55     # (code, version, catalogue, formatIn, formatOut)
56     # Il faut les mettre dans un tuple
57     self.catalogues = (("ADAO", "V0", os.path.join(self.rep_ini, 'ADAO_Cata_V0.py'), "adao"),)
58
59 def make_config(appli,rep):
60
61     return CONFIG(appli,rep)
62
63 def make_config_style(appli,rep):
64
65     return None