def findMdiChild(self, fileName): canonicalFilePath = QtCore.QFileInfo(fileName).canonicalFilePath() for window in self.mdiarea.subWindowList(): if window.widget().currentFile() == canonicalFilePath: return window return None
def strippedName(self, fullFileName): return QtCore.QFileInfo(fullFileName).fileName()
def setCurrentFile(self, fileName): self.curFile = QtCore.QFileInfo(fileName).canonicalFilePath() self.isUntitled = False self.document().setModified(False) self.setWindowModified(False) self.setWindowTitle(self.userFriendlyCurrentFile() + '[*]')