1 # -*- coding: utf-8 -*-
3 # Copyright (C) 2008-2020 EDF R&D
5 # This file is part of SALOME ADAO module
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.
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.
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
21 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
23 # Author: André Ribes, andre.ribes@edf.fr, EDF R&D
26 Ce module sert pour charger les paramètres de configuration d'EFICAS
29 # print "passage dans la surcharge de configuration pour Adao"
30 import os, sys, string, types, re
32 from PyQt5.QtGui import *
35 from InterfaceQT4 import configuration
37 # Classe de base permettant de lire, afficher
38 # et sauvegarder les fichiers utilisateurs
39 class CONFIG(configuration.configBase): # configuration.CONFIG_BASE):
41 def __init__(self,appli,repIni):
43 # self.labels_eficas = ['lang']
44 self.labels_eficas = ['lang','rep_cata','catalogues','closeAutreCommande','closeFrameRechercheCommande','closeEntete','taille']
45 configuration.configBase.__init__(self,appli,repIni)
46 #~ configuration.CONFIG_BASE.__init__(self,appli,repIni)
48 self.rep_user = os.environ["HOME"]
50 self.code = appli.code
53 self.rep_mat = " " # Compatbilite Aster
54 self.savedir = self.rep_user
55 self.generator_module = "generator_adao"
56 self.convert_module = "convert_adao"
58 # Format des catalogues...
59 # (code, version, catalogue, formatIn, formatOut)
60 # Il faut les mettre dans un tuple
61 self.catalogues = (("ADAO", "V0", os.path.join(self.rep_ini, 'ADAO_Cata_V0.py'), "adao"),)
62 # JPA 21/09/2017 : self.catalogues = (("ADAO", "V0", os.path.join(self.rep_ini, 'ADAO_Cata_V0.py'), "python", "adao"),)
64 def make_config(appli,rep):
66 return CONFIG(appli,rep)
68 def make_config_style(appli,rep):