diff -r 717b72b32420 -r 8bb085c59cd2 Graphics/UMLClassDiagram.py --- a/Graphics/UMLClassDiagram.py Wed Sep 05 19:19:16 2012 +0200 +++ b/Graphics/UMLClassDiagram.py Wed Sep 05 20:07:02 2012 +0200 @@ -24,10 +24,11 @@ """ Class implementing a dialog showing a UML like class diagram. """ - def __init__(self, file, parent=None, name=None, noAttrs=False): + def __init__(self, project, file, parent=None, name=None, noAttrs=False): """ Constructor + @param project reference to the project object @param file filename of a python module to be shown (string) @param parent parent widget of the view (QWidget) @param name name of the view widget (string) @@ -36,7 +37,12 @@ self.file = file self.noAttrs = noAttrs - UMLDialog.__init__(self, self.file, parent) + pname = project.getProjectName() + if pname and project.isProjectSource(self.file): + name = "{0}: {1}".format(pname, project.getRelativePath(self.file)) + else: + name = self.file + UMLDialog.__init__(self, name, parent) if not name: self.setObjectName("UMLClassDiagram")