Debug, Doc: Add windows title translate.

This commit is contained in:
Pierre-Antoine Rouby committed 2024-02-12 14:16:12 +01:00
1 parent 8895d0d565
commit 87fcf1c610
2 files changed
+10 -4

No files matched your search

+7 -3
View File
@@ -21,7 +21,7 @@ import sys
import logging
import subprocess
from PyQt5.QtCore import QUrl
from PyQt5.QtCore import QUrl, QCoreApplication
from PyQt5.QtGui import QDesktopServices
from PyQt5.QtWidgets import QApplication, QWidget, QVBoxLayout, QAction
from PyQt5.QtWebEngineWidgets import QWebEngineView, QWebEngineSettings
@@ -30,10 +30,11 @@ from View.Tools.PamhyrWindow import PamhyrWindow
logger = logging.getLogger()
_translate = QCoreApplication.translate
class DocWindow(PamhyrWindow):
_pamhyr_ui = "WebView"
_pamhyr_name = "Doc"
_pamhyr_name = "Documentation"
@classmethod
def _path_file(cls, filename):
@@ -55,8 +56,11 @@ class DocWindow(PamhyrWindow):
def __init__(self, filename=None,
study=None, config=None,
parent=None):
title = _translate("Documentation", "Documentation")
title += f" - {filename}"
super(DocWindow, self).__init__(
title=self._pamhyr_name,
title=title,
study=study,
config=config,
options=[],