Skip to content

Commit

Permalink
Prepare v4.5.1 based on novxlib v4.4.0
Browse files Browse the repository at this point in the history
- Update messages for wrong date/time entry.
  • Loading branch information
peter88213 committed Jul 20, 2024
1 parent 836d97a commit e5f049c
Show file tree
Hide file tree
Showing 14 changed files with 66 additions and 24 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Download the latest release](docs/img/download-button.png)](https://github.com/peter88213/novelibre/raw/main/dist/novelibre_v4.5.0.pyzw)
[![Download the latest release](docs/img/download-button.png)](https://github.com/peter88213/novelibre/raw/main/dist/novelibre_v4.5.1.pyzw)
[![Changelog](docs/img/changelog-button.png)](docs/changelog.md)
[![News](docs/img/news-button.png)](https://github.com/peter88213/novelibre/discussions/1)
[![Online help](docs/img/help-button.png)](https://peter88213.github.io/nvhelp-en/)
Expand Down Expand Up @@ -78,10 +78,10 @@ I use the program myself and fix errors immediately if I notice any. As far as I

### Default: Executable Python zip archive

Download the latest release [novelibre_v4.5.0.pyzw](https://github.com/peter88213/novelibre/raw/main/dist/novelibre_v4.5.0.pyzw)
Download the latest release [novelibre_v4.5.1.pyzw](https://github.com/peter88213/novelibre/raw/main/dist/novelibre_v4.5.1.pyzw)

- Launch *novelibre_v4.5.0.pyzw* by double-clicking (Windows/Linux desktop),
- or execute `python novelibre_v4.5.0.pyzw` (Windows), resp. `python3 novelibre_v4.5.0.pyzw` (Linux) on the command line.
- Launch *novelibre_v4.5.1.pyzw* by double-clicking (Windows/Linux desktop),
- or execute `python novelibre_v4.5.1.pyzw` (Windows), resp. `python3 novelibre_v4.5.1.pyzw` (Linux) on the command line.

#### Important

Expand All @@ -97,9 +97,9 @@ the zip file.

### Alternative: Zip file

The package is also available in zip format: [novelibre_v4.5.0.zip](https://github.com/peter88213/novelibre/raw/main/dist/novelibre_v4.5.0.zip)
The package is also available in zip format: [novelibre_v4.5.1.zip](https://github.com/peter88213/novelibre/raw/main/dist/novelibre_v4.5.1.zip)

- Extract the *novelibre_v4.5.0* folder from the downloaded zipfile "novelibre_v4.5.0.zip".
- Extract the *novelibre_v4.5.1* folder from the downloaded zipfile "novelibre_v4.5.1.zip".
- Move into this new folder and launch *setup.pyw* by double-clicking (Windows/Linux desktop),
- or execute `python setup.pyw` (Windows), resp. `python3 setup.pyw` (Linux) on the command line.

Expand Down
4 changes: 2 additions & 2 deletions VERSION
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[LATEST]
version = 4.5.0
download_link = https://github.com/peter88213/novelibre/raw/main/dist/novelibre_v4.5.0.pyzw
version = 4.5.1
download_link = https://github.com/peter88213/novelibre/raw/main/dist/novelibre_v4.5.1.pyzw
Binary file removed dist/novelibre_v4.5.0.pyzw
Binary file not shown.
Binary file removed dist/novelibre_v4.5.0.zip
Binary file not shown.
Binary file added dist/novelibre_v4.5.1.pyzw
Binary file not shown.
Binary file added dist/novelibre_v4.5.1.zip
Binary file not shown.
6 changes: 6 additions & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@

See the [GitHub "Features" project](https://github.com/users/peter88213/projects/14).

### v4.5.1

- Update messages for wrong date/time entry.

Based on novxlib v4.4.0

### v4.5.0

- API update: Add register/unregister methods to NvView.
Expand Down
19 changes: 14 additions & 5 deletions i18n/de.po
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
#
msgid ""
msgstr ""
"Project-Id-Version: 4.5.0\n"
"POT-Creation-Date: 2024-07-19 07:26:36\n"
"PO-Revision-Date: 2024-07-19 07:26:36\n"
"Project-Id-Version: 4.5.1\n"
"POT-Creation-Date: 2024-07-20 07:47:04\n"
"PO-Revision-Date: 2024-07-20 07:47:04\n"
"Last-Translator: Peter Triesberger\n"
"Language: de\n"
"MIME-Version: 1.0\n"
Expand Down Expand Up @@ -925,6 +925,9 @@ msgstr "Plotlinie entfernen"
msgid "Renamings"
msgstr "Umbenennungen"

msgid "Required"
msgstr "Erforderlich"

msgid "Reset chapter number when starting a new part"
msgstr "Kapitelnummerierung per Teil"

Expand Down Expand Up @@ -1195,8 +1198,8 @@ msgstr "Falsches Datum"
msgid "Wrong day"
msgstr "Falscher Tag"

msgid "Wrong entry: numbers required"
msgstr "Fehleingabe: Zahlen erforderlich"
msgid "Wrong entry: number required"
msgstr "Fehleingabe: Zahl erforderlich"

msgid "Wrong name"
msgstr "Falscher Name"
Expand All @@ -1219,6 +1222,9 @@ msgstr "XML-Gegenstandsdatei"
msgid "XML location data file"
msgstr "XML-Schauplatzdatei"

msgid "YYYY-MM-DD"
msgstr "JJJJ-MM-TT"

msgid "\"Export\" options"
msgstr "\"Export\"-Optionen"

Expand All @@ -1234,6 +1240,9 @@ msgstr "gelöscht"
msgid "elements imported"
msgstr "Elemente importiert"

msgid "hh:mm"
msgstr "hh:mm"

msgid "last saved on"
msgstr "zuletzt gespeichert:"

Expand Down
Binary file modified i18n/locale/de/LC_MESSAGES/novelibre.mo
Binary file not shown.
15 changes: 12 additions & 3 deletions i18n/messages.pot
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
#
msgid ""
msgstr ""
"Project-Id-Version: 4.5.0\n"
"POT-Creation-Date: 2024-07-19 07:26:36\n"
"Project-Id-Version: 4.5.1\n"
"POT-Creation-Date: 2024-07-20 07:47:04\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language: LANGUAGE\n"
Expand Down Expand Up @@ -932,6 +932,9 @@ msgstr ""
msgid "Renamings"
msgstr ""

msgid "Required"
msgstr ""

msgid "Reset chapter number when starting a new part"
msgstr ""

Expand Down Expand Up @@ -1202,7 +1205,7 @@ msgstr ""
msgid "Wrong day"
msgstr ""

msgid "Wrong entry: numbers required"
msgid "Wrong entry: number required"
msgstr ""

msgid "Wrong name"
Expand All @@ -1226,6 +1229,9 @@ msgstr ""
msgid "XML location data file"
msgstr ""

msgid "YYYY-MM-DD"
msgstr ""

msgid "by"
msgstr ""

Expand All @@ -1235,6 +1241,9 @@ msgstr ""
msgid "elements imported"
msgstr ""

msgid "hh:mm"
msgstr ""

msgid "last saved on"
msgstr ""

Expand Down
10 changes: 8 additions & 2 deletions src/nvlib/view/properties_window/character_view.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,10 @@ def apply_changes(self, event=None):
date.fromisoformat(birthDateStr)
except:
self._birthDate.set(self._element.birthDate)
self._ui.show_error(f'{_("Wrong date")}: "{birthDateStr}"', title=_('Input rejected'))
self._ui.show_error(
f'{_("Wrong date")}: "{birthDateStr}"\n {_("Required")}: {_("YYYY-MM-DD")}',
title=_('Input rejected')
)
else:
self._element.birthDate = birthDateStr

Expand All @@ -150,7 +153,10 @@ def apply_changes(self, event=None):
date.fromisoformat(deathDateStr)
except:
self._deathDate.set(self._element.deathDate)
self._ui.show_error(f'{_("Wrong date")}: "{deathDateStr}"', title=_('Input rejected'))
self._ui.show_error(
f'{_("Wrong date")}: "{deathDateStr}"\n {_("Required")}: {_("YYYY-MM-DD")}',
title=_('Input rejected')
)
else:
self._element.deathDate = deathDateStr

Expand Down
17 changes: 13 additions & 4 deletions src/nvlib/view/properties_window/dated_section_view.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,10 @@ def _change_day(self, event=None):
int(dayStr)
except ValueError:
self._startDay.set(self._element.day)
self._ui.show_error(f'{_("Wrong day")}: "{dayStr}"', title=_('Input rejected'))
self._ui.show_error(
f'{_("Wrong entry: number required")}.',
title=_('Input rejected')
)
else:
self._element.day = dayStr
self._element.date = None
Expand Down Expand Up @@ -239,7 +242,10 @@ def apply_changes(self, event=None):
date.fromisoformat(dateStr)
except ValueError:
self._startDate.set(self._element.date)
self._ui.show_error(f'{_("Wrong date")}: "{dateStr}"', title=_('Input rejected'))
self._ui.show_error(
f'{_("Wrong date")}: "{dateStr}"\n {_("Required")}: {_("YYYY-MM-DD")}',
title=_('Input rejected')
)
else:
self._element.date = dateStr

Expand All @@ -257,7 +263,10 @@ def apply_changes(self, event=None):
time.fromisoformat(timeStr)
except ValueError:
self._startTime.set(dispTime)
self._ui.show_error(f'{_("Wrong time")}: "{timeStr}"', title=_('Input rejected'))
self._ui.show_error(
f'{_("Wrong time")}: "{timeStr}"\n {_("Required")}: {_("hh:mm")}',
title=_('Input rejected')
)
else:
while timeStr.count(':') < 2:
timeStr = f'{timeStr}:00'
Expand Down Expand Up @@ -342,7 +351,7 @@ def apply_changes(self, event=None):
self._lastsMinutes.set(self._element.lastsMinutes)
self._lastsHours.set(self._element.lastsHours)
self._lastsDays.set(self._element.lastsDays)
self._ui.show_error(f'{_("Wrong entry: numbers required")}.', title=_('Input rejected'))
self._ui.show_error(f'{_("Wrong entry: number required")}.', title=_('Input rejected'))
elif newEntry:
self._element.lastsMinutes = lastsMinutesStr
self._element.lastsHours = lastsHoursStr
Expand Down
5 changes: 4 additions & 1 deletion src/nvlib/view/properties_window/project_view.py
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,10 @@ def apply_changes(self, event=None):
date.fromisoformat(refDateStr)
except ValueError:
self._referenceDate.set(self._element.referenceDate)
self._ui.show_error(f'{_("Wrong date")}: "{refDateStr}"', title=_('Input rejected'))
self._ui.show_error(
f'{_("Wrong date")}: "{refDateStr}"\n {_("Required")}: {_("YYYY-MM-DD")}',
title=_('Input rejected')
)
else:
self._element.referenceDate = refDateStr
if self._element.referenceWeekDay is not None:
Expand Down
2 changes: 1 addition & 1 deletion tools/build.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="novelibre" basedir=".">
<property name="version" value="4.5.0" />
<property name="version" value="4.5.1" />
<property name="test-app" value="novelibre" />

<property name="source-path" location="../src" />
Expand Down

0 comments on commit e5f049c

Please sign in to comment.