X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=InterfaceQT4%2Fcompoparam.py;h=5d2235999dcdcaf26d78363757315704bbe713f2;hb=f1fe188d679966c43c6e965bde6d63bd89451262;hp=5c637496c84361fe7403013d74d7b9c3265cbb21;hpb=d41b1c52d0c35b655f6feabfe816a3c541f3a92a;p=tools%2Feficas.git diff --git a/InterfaceQT4/compoparam.py b/InterfaceQT4/compoparam.py index 5c637496..5d223599 100644 --- a/InterfaceQT4/compoparam.py +++ b/InterfaceQT4/compoparam.py @@ -1,4 +1,22 @@ # -*- coding: utf-8 -*- +# Copyright (C) 2007-2013 EDF R&D +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# +# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +# """ Ce module contient les classes permettant de définir les objets graphiques représentant un objet de type PARAMETRE, cad le panneau et l'item de l'arbre @@ -6,7 +24,8 @@ """ # import modules Python -import string +import string, types +from Extensions.i18n import tr # import modules EFICAS from Editeur import Objecttreeitem @@ -15,7 +34,7 @@ import typeNode class Node(browser.JDCNode,typeNode.PopUpMenuNodePartiel): - def getPanel(self): + def getPanel2(self): """ """ from monParamPanel import MonParamPanel @@ -25,6 +44,9 @@ class Node(browser.JDCNode,typeNode.PopUpMenuNodePartiel): typeNode.PopUpMenuNodePartiel.createPopUpMenu(self) self.menu.removeAction(self.Documentation) + def doPaste(self,node_selected): + return None + class PARAMTreeItem(Objecttreeitem.ObjectTreeItem): @@ -69,6 +91,11 @@ class PARAMTreeItem(Objecttreeitem.ObjectTreeItem): Ce texte est tronqué à 25 caractêres """ texte=self.object.nom+"="+str(self.object.valeur) + if type(self.object.valeur) == types.ListType : + texte=self.nom+' = [' + for l in self.object.valeur : + texte=texte+str(l) +"," + texte=texte[0:-1]+']' texte = string.split(texte,'\n')[0] if len(texte) < 25 : return texte @@ -116,7 +143,7 @@ class PARAMTreeItem(Objecttreeitem.ObjectTreeItem): """ Retourne le fr associé au paramêtre, cad la bulle d'aide pour EFICAS """ - return "Définition d'un paramêtre" + return tr("Definition d'un parametre") import Extensions.parametre treeitem =PARAMTreeItem