From: pascale.noyret Date: Fri, 27 Apr 2018 15:05:55 +0000 (+0200) Subject: divers chgts pour MT X-Git-Tag: V8_5_0rc2a2~3^2~3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=9ac334705d7317e18f97ba8043aa5dcc8dd8f618;p=modules%2Feficas.git divers chgts pour MT --- diff --git a/InterfaceQT4/browser.py b/InterfaceQT4/browser.py index dea6627f..abcda7b0 100644 --- a/InterfaceQT4/browser.py +++ b/InterfaceQT4/browser.py @@ -343,7 +343,7 @@ class JDCNode(QTreeWidgetItem,GereRegles): def afficheCeNiveau(self): - print ('afficheCeNiveau pour ', self.item.nom, self.item.getLabelText()) + #print ('afficheCeNiveau pour ', self.item.nom, self.item.getLabelText()) for indiceWidget in range(self.editor.widgetCentraleLayout.count()): widget=self.editor.widgetCentraleLayout.itemAt(indiceWidget) self.editor.widgetCentraleLayout.removeItem(widget) @@ -678,6 +678,9 @@ class JDCNode(QTreeWidgetItem,GereRegles): #print ("onValid pour ", self.item.nom) if self.JESUISOFF==1 : return if hasattr(self,'fenetre') and self.fenetre: + print (self.fenetre) + print (self) + print (dir(self)) try : self.fenetre.setValide() except : diff --git a/InterfaceQT4/configuration.py b/InterfaceQT4/configuration.py index fe3ad7f6..8110fd46 100644 --- a/InterfaceQT4/configuration.py +++ b/InterfaceQT4/configuration.py @@ -127,7 +127,9 @@ class configBase(object): self.differencieSiDefaut=False self.typeDeCata='Python' self.dumpXSD=False + self.withXSD=False self.afficheIhm=True + self.closeParenthese=False diff --git a/InterfaceQT4/monWidgetCommande.py b/InterfaceQT4/monWidgetCommande.py index 25fbd3df..af6d84a1 100644 --- a/InterfaceQT4/monWidgetCommande.py +++ b/InterfaceQT4/monWidgetCommande.py @@ -91,7 +91,7 @@ class MonWidgetCommande(Ui_WidgetCommande,Groupe): if hasattr(self,'LENom'): self.LENom.returnPressed.connect(self.nomChange) - if self.editor.code in ['Adao','ADAO'] and self.editor.maConfiguration.closeFrameRechercheCommande==True : + if self.editor.code in ['Adao','ADAO'] or self.editor.maConfiguration.closeFrameRechercheCommande==True : self.frameAffichage.close() if self.editor.code in ['CARMELCND',] : self.closeAutreCommande() diff --git a/InterfaceQT4/monWidgetNiveauFact.py b/InterfaceQT4/monWidgetNiveauFact.py index 2bfc28e7..52940e08 100644 --- a/InterfaceQT4/monWidgetNiveauFact.py +++ b/InterfaceQT4/monWidgetNiveauFact.py @@ -30,6 +30,7 @@ from desWidgetNiveauFact import Ui_WidgetNiveauFact from InterfaceQT4.groupe import Groupe from PyQt5.QtWidgets import QWidget +from PyQt5.QtGui import QIcon from Extensions.i18n import tr @@ -44,10 +45,12 @@ class MonWidgetNiveauFact(Ui_WidgetNiveauFact,Groupe): """ def __init__(self,node,editor,definition,obj): self.listeAffichageWidget=[] + self.listeBoutonAChanger=[] Groupe.__init__(self,node,editor,None,definition,obj,1,self) from InterfaceQT4 import composimp if isinstance(self.node ,composimp.Node): widget=self.node.getPanelGroupe(self,self.maCommande) + self.listeBoutonAChanger.append(widget.RBValide) self.afficheOptionnel() self.inhibe=False @@ -160,7 +163,15 @@ class MonWidgetNiveauFact(Ui_WidgetNiveauFact,Groupe): self.monOptionnel.titre(self.obj.nom) self.monGroupe=self.monOptionnel.afficheOptionnel(liste,liste_rouge,self) + def setValide(self): + Groupe.setValide(self) + for bouton in self.listeBoutonAChanger: + couleur=self.node.item.getIconName() + monIcone = QIcon(self.repIcon+"/" + couleur + ".png") + bouton.setIcon(monIcone) class MonWidgetNiveauFactTableau(MonWidgetNiveauFact): def __init__(self,node,editor,definition,obj): MonWidgetNiveauFact.__init__(self,node,editor,definition,obj) + + diff --git a/InterfaceQT4/monWidgetPlusieursTuple.py b/InterfaceQT4/monWidgetPlusieursTuple.py index a4022dc6..ace27ef0 100644 --- a/InterfaceQT4/monWidgetPlusieursTuple.py +++ b/InterfaceQT4/monWidgetPlusieursTuple.py @@ -173,14 +173,11 @@ class TupleCustom2(QWidget,Ui_Tuple2,TupleCustom): def __init__(self,tailleTuple,parent,parentQt,index): #------------------- TupleCustom.__init__(self,tailleTuple,parent,parentQt,index) + if self.parentQt.editor.maConfiguration.closeParenthese : + self.label_5.close() + self.label_7.close() + -#------------------------------------------------- -class TupleCustom3(QWidget,Ui_Tuple3,TupleCustom): -#------------------------------------------------- - def __init__(self,tailleTuple,parent,parentQt,index): - #----------------------------------------------------- - TupleCustom. __init__(self,tailleTuple,parent,parentQt,index) - #------------------------------------------------- class TupleCustom3(QWidget,Ui_Tuple3,TupleCustom): #------------------------------------------------- @@ -236,6 +233,9 @@ class TupleCustom10(QWidget,Ui_Tuple10,TupleCustom): def __init__(self,tailleTuple,parent,parentQt,index): #------------------- TupleCustom.__init__(self,tailleTuple,parent,parentQt,index) + if self.parentQt.editor.maConfiguration.closeParenthese : + self.label_5.close() + self.label_7.close() diff --git a/InterfaceQT4/monWidgetSimpTuple.py b/InterfaceQT4/monWidgetSimpTuple.py index 0764c245..b75a5676 100644 --- a/InterfaceQT4/monWidgetSimpTuple.py +++ b/InterfaceQT4/monWidgetSimpTuple.py @@ -79,7 +79,7 @@ class MonWidgetSimpTuple(Feuille): else : s=s+'"' courant.setText(s) texteValeur+=str(courant.text()) - print (texteValeur) + #print (texteValeur) if i+1 != self.nbValeurs : texteValeur+=',' validite,commentaire=self.politique.recordValeur(texteValeur) if not validite:self.editor.afficheInfos(commentaire+" "+str(self.objSimp.definition.validators.typeDesTuples),Qt.red)