Update references to Qt5 and PyQt5
This commit is contained in:
+2
-2
@@ -45,8 +45,8 @@ contributions are listed on the project's Members page.
|
||||
|
||||
The following libraries are dependencies of novelWriter:
|
||||
|
||||
* **Qt5** by Qt Company
|
||||
* **PyQt5** by Riverbank Computing
|
||||
* **Qt6** by Qt Company
|
||||
* **PyQt6** by Riverbank Computing
|
||||
* **Enchant** by Dom Lachowicz
|
||||
* **PyEnchant** by Dimitri Merejkowsky
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ documentation.
|
||||
|
||||
## Implementation
|
||||
|
||||
novelWriter is written with Python 3 (3.10+) using Qt5 and PyQt5 (5.15 only), and is released on
|
||||
novelWriter is written with Python 3 (3.10+) using Qt6 and PyQt6 (6.0+), and is released on
|
||||
Linux, Windows and macOS. It can in principle run on any Operating System that also supports Qt,
|
||||
PyQt and Python.
|
||||
|
||||
|
||||
@@ -36,12 +36,11 @@ Everything else is handled with standard Python libraries.
|
||||
|
||||
The following Python packages are needed to run all features of novelWriter:
|
||||
|
||||
* ``PyQt5`` – needed for connecting with the Qt5 libraries.
|
||||
* ``PyQt6`` – needed for connecting with the Qt6 libraries.
|
||||
* ``PyEnchant`` – needed for spell checking (optional).
|
||||
|
||||
PyQt/Qt must be at least 5.15.0. If you want spell checking, you must install the ``PyEnchant``
|
||||
package. The spell check library must be at least 3.0 to work with Windows. On Linux, 2.0 also
|
||||
works fine.
|
||||
If you want spell checking, you must install the ``PyEnchant`` package. The spell check library
|
||||
must be at least 3.0 to work with Windows. On Linux, 2.0 also works fine.
|
||||
|
||||
If you install from PyPi, these dependencies should be installed automatically. If you install from
|
||||
source, dependencies can still be installed from PyPi with:
|
||||
|
||||
+4
-5
@@ -18,7 +18,7 @@ When contributing translations, keep the following things in mind.
|
||||
|
||||
* For descriptive labels and dialog boxes, make sure you do _not_ change the meaning of the text
|
||||
when you translate it from English. The user must receive the same instructions or information
|
||||
regardless of language. This is improtant, otherwise the documentation will be inconsistent with
|
||||
regardless of language. This is important, otherwise the documentation will be inconsistent with
|
||||
the user interface and it will become a lot more difficult to handle user issues and questions.
|
||||
* If you think a label or description is misleading or incomplete, please file an issue report. The
|
||||
correct way to handle such changes is to change the text in the code first, which will then be
|
||||
@@ -35,7 +35,7 @@ Linguist, or updating the translations for an already existing supported languag
|
||||
|
||||
There are two areas relevant to localisation:
|
||||
|
||||
* The Qt5 GUI translation files, which consists of `nw_XX.ts` files. This is the bulk of the
|
||||
* The Qt GUI translation files, which consists of `nw_XX.ts` files. This is the bulk of the
|
||||
translation work.
|
||||
* The `project_XX.json` files. See [Project Localisation](#project-localisation) below.
|
||||
|
||||
@@ -43,7 +43,7 @@ The `XX` in the file name corresponds to the language and country code for the t
|
||||
instance `en_GB` for British English.
|
||||
|
||||
|
||||
## Qt5 GUI Localisation
|
||||
## Qt GUI Localisation
|
||||
|
||||
You will need the translation tool Qt 5 Linguist on your system.
|
||||
|
||||
@@ -89,8 +89,7 @@ For instance, the French translation uses the language code `fr_FR`, so its tran
|
||||
be `nw_fr_FR.ts`
|
||||
|
||||
Note: The `qtlupdate` command needs the `lupdate` tool provided by PyQt6, which uses the latest
|
||||
TS file format. The tool in PyQt5 generates an older file format. On Debian/Ubuntu it is provided
|
||||
by the package `pyqt6-dev-tools`.
|
||||
TS file format. On Debian/Ubuntu it is provided by the package `pyqt6-dev-tools`.
|
||||
|
||||
|
||||
### Edit the Translation File in Qt Linguist
|
||||
|
||||
@@ -117,7 +117,7 @@ def main(sysArgs: list | None = None) -> GuiMain | None:
|
||||
" --debug Print debug output. Includes --info.\n"
|
||||
" --color Add ANSI colors to log output.\n"
|
||||
" --meminfo Show memory usage information in the status bar.\n"
|
||||
" --style= Sets Qt5 style flag. Defaults to 'Fusion'.\n"
|
||||
" --style= Sets Qt style flag. Defaults to 'Fusion'.\n"
|
||||
" --config= Alternative config file.\n"
|
||||
" --data= Alternative user data path.\n"
|
||||
)
|
||||
|
||||
@@ -54,8 +54,8 @@ more contributions are listed on the project's Members page.</p>
|
||||
<p>The following libraries are dependencies of novelWriter:</p>
|
||||
|
||||
<ul>
|
||||
<li><b>Qt5</b> by Qt Company</li>
|
||||
<li><b>PyQt5</b> by Riverbank Computing</li>
|
||||
<li><b>Qt6</b> by Qt Company</li>
|
||||
<li><b>PyQt6</b> by Riverbank Computing</li>
|
||||
<li><b>Enchant</b> by Dom Lachowicz</li>
|
||||
<li><b>PyEnchant</b> by Dimitri Merejkowsky</li>
|
||||
</ul>
|
||||
|
||||
@@ -434,7 +434,7 @@ def describeFont(font: QFont) -> str:
|
||||
def fontMatcher(font: QFont) -> QFont:
|
||||
"""Make sure the font is the correct family, if possible. This
|
||||
ensures that Qt doesn't re-use another font under the hood. The
|
||||
default Qt5 font matching algorithm doesn't handle well changing
|
||||
default Qt font matching algorithm doesn't handle well changing
|
||||
application fonts at runtime.
|
||||
"""
|
||||
info = QFontInfo(font)
|
||||
|
||||
@@ -217,7 +217,7 @@ class Config:
|
||||
# System and App Information
|
||||
# ==========================
|
||||
|
||||
# Check Qt5 Versions
|
||||
# Check Qt Versions
|
||||
self.verQtString = QT_VERSION_STR
|
||||
self.verQtValue = QT_VERSION
|
||||
self.verPyQtString = PYQT_VERSION_STR
|
||||
|
||||
@@ -1021,8 +1021,8 @@ class GuiMainMenu(QMenuBar):
|
||||
self.aAboutNW.setMenuRole(QAction.MenuRole.AboutRole)
|
||||
self.aAboutNW.triggered.connect(self.mainGui.showAboutNWDialog)
|
||||
|
||||
# Help > About Qt5
|
||||
self.aAboutQt = self.helpMenu.addAction(self.tr("About Qt5"))
|
||||
# Help > About Qt
|
||||
self.aAboutQt = self.helpMenu.addAction(self.tr("About Qt"))
|
||||
self.aAboutQt.setMenuRole(QAction.MenuRole.AboutQtRole)
|
||||
self.aAboutQt.triggered.connect(self.mainGui.showAboutQtDialog)
|
||||
|
||||
|
||||
@@ -92,8 +92,8 @@ class GuiMain(QMainWindow):
|
||||
logger.info("OS: %s", CONFIG.osType)
|
||||
logger.info("Kernel: %s", CONFIG.kernelVer)
|
||||
logger.info("Host: %s", CONFIG.hostName)
|
||||
logger.info("Qt5: %s (0x%06x)", CONFIG.verQtString, CONFIG.verQtValue)
|
||||
logger.info("PyQt5: %s (0x%06x)", CONFIG.verPyQtString, CONFIG.verPyQtValue)
|
||||
logger.info("Qt: %s (0x%06x)", CONFIG.verQtString, CONFIG.verQtValue)
|
||||
logger.info("PyQt: %s (0x%06x)", CONFIG.verPyQtString, CONFIG.verPyQtValue)
|
||||
logger.info("Python: %s (0x%08x)", CONFIG.verPyString, sys.hexversion)
|
||||
logger.info("GUI Language: %s", CONFIG.guiLocale)
|
||||
|
||||
|
||||
+2
-2
@@ -543,8 +543,8 @@ def buildTranslationAssets(args: argparse.Namespace | None = None) -> None:
|
||||
try:
|
||||
subprocess.call(["lrelease", "-verbose", *srcList])
|
||||
except Exception as exc:
|
||||
print("Qt5 Linguist tools seem to be missing")
|
||||
print("On Debian/Ubuntu, install: qttools5-dev-tools pyqt5-dev-tools")
|
||||
print("Qt Linguist tools seem to be missing")
|
||||
print("On Debian/Ubuntu, install: qttools5-dev-tools")
|
||||
print(str(exc))
|
||||
sys.exit(1)
|
||||
|
||||
|
||||
@@ -3,4 +3,3 @@ flake8-pep585
|
||||
flake8-pyproject
|
||||
flake8-annotations
|
||||
isort
|
||||
pyqt5-stubs
|
||||
|
||||
+1
-1
@@ -1,2 +1,2 @@
|
||||
pyqt5>=5.15
|
||||
pyqt6>=6.0
|
||||
pyenchant>=3.0.0
|
||||
|
||||
@@ -10,7 +10,7 @@ synchronisation tools. All text is saved as plain text files with a meta data he
|
||||
project structure is stored in a single project XML file, and other meta data is primarily saved as
|
||||
JSON files.
|
||||
|
||||
The application is written with Python 3 (3.10+) using Qt5 and PyQt5 (5.10+). It is developed on
|
||||
The application is written with Python 3 (3.10+) using Qt6 and PyQt6 (5.10+). It is developed on
|
||||
Linux, but should in principle work fine on other operating systems as well as long as dependencies
|
||||
are met. It is regularly tested on Debian and Ubuntu Linux, Windows, and MacOS.
|
||||
|
||||
|
||||
@@ -18,12 +18,12 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
Dependencies
|
||||
|
||||
Qt5
|
||||
Qt6
|
||||
Copyright: Qt Company
|
||||
Website: <https://www.qt.io/>
|
||||
License: LGPL v3 <https://www.gnu.org/licenses/lgpl-3.0.html>
|
||||
|
||||
PyQt5 / PyQt5-sip
|
||||
PyQt6 / PyQt6-sip
|
||||
Copyright: Riverbank Computing
|
||||
Website: <https://www.riverbankcomputing.com/software/pyqt/>
|
||||
License: GPL v3 <https://www.gnu.org/licenses/gpl-3.0.html>
|
||||
|
||||
@@ -165,13 +165,13 @@ rm -rf share/{gtk-,}doc
|
||||
rm -rf lib/python3.1
|
||||
|
||||
# Remove web engine
|
||||
rm lib/python3.*/site-packages/PyQt5/QtWebEngine* || true
|
||||
rm -r lib/python3.*/site-packages/PyQt5/Qt/translations/qtwebengine* || true
|
||||
rm lib/python3.*/site-packages/PyQt5/Qt/resources/qtwebengine* || true
|
||||
rm -r lib/python3.*/site-packages/PyQt5/Qt/qml/QtWebEngine* || true
|
||||
rm -r lib/python3.*/site-packages/PyQt5/Qt/plugins/webview/libqtwebview* || true
|
||||
rm lib/python3.*/site-packages/PyQt5/Qt/libexec/QtWebEngineProcess* || true
|
||||
rm lib/python3.*/site-packages/PyQt5/Qt/lib/libQt5WebEngine* || true
|
||||
rm lib/python3.*/site-packages/PyQt6/QtWebEngine* || true
|
||||
rm -r lib/python3.*/site-packages/PyQt6/Qt/translations/qtwebengine* || true
|
||||
rm lib/python3.*/site-packages/PyQt6/Qt/resources/qtwebengine* || true
|
||||
rm -r lib/python3.*/site-packages/PyQt6/Qt/qml/QtWebEngine* || true
|
||||
rm -r lib/python3.*/site-packages/PyQt6/Qt/plugins/webview/libqtwebview* || true
|
||||
rm lib/python3.*/site-packages/PyQt6/Qt/libexec/QtWebEngineProcess* || true
|
||||
rm lib/python3.*/site-packages/PyQt6/Qt/lib/libQt5WebEngine* || true
|
||||
|
||||
popd || exit 1
|
||||
popd || exit 1
|
||||
|
||||
Reference in New Issue
Block a user