Use Qt for int locale

This commit is contained in:
Veronica Berglyd Olsen
2024-10-28 19:53:25 +01:00
parent c6a22e2d96
commit d987246062
6 changed files with 64 additions and 5 deletions
+4 -1
View File
@@ -29,6 +29,7 @@ import logging
from pathlib import Path
from time import time
from novelwriter import CONFIG
from novelwriter.common import formatTimeStamp
from novelwriter.constants import nwHtmlUnicode
from novelwriter.core.project import NWProject
@@ -257,7 +258,9 @@ class ToHtml(Tokenizer):
pages = len(self._pages)
for doc, field in self._usedFields:
if doc >= 0 and doc < pages and (value := self._counts.get(field)) is not None:
self._pages[doc] = self._pages[doc].replace(f"{{{{{field}}}}}", f"{value:n}")
self._pages[doc] = self._pages[doc].replace(
f"{{{{{field}}}}}", CONFIG.localInt(value)
)
# Add footnotes
if self._usedNotes: