Skip to content

Commit

Permalink
Todo dialog. Added field for Notes (ical DESCRIPTION element). This h…
Browse files Browse the repository at this point in the history
…as meant expanding the dialog, and so tabs have been added more advanced settings.
  • Loading branch information
semiprime committed Sep 11, 2023
1 parent f0cf8b2 commit dcf522d
Show file tree
Hide file tree
Showing 6 changed files with 244 additions and 72 deletions.
4 changes: 2 additions & 2 deletions docs/Usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ Usage is intended to be intuitive, but a few things are worth noting:

* Hint: To convert To-dos into Events, or vice-versa, cut & paste them.

* In the "Notes" field in the Event dialog, shift(or ctrl)+enter gives
a new line (just enter will confirm the dialog).
* In the "Notes" field in the Event and Todo dialogs, shift(or ctrl)+enter
gives a new line (just enter will confirm the dialog).

* Setting alarms is currently under development and testing is welcome.
(Note: sounding/displaying/sending alarms will be the job of a
Expand Down
17 changes: 10 additions & 7 deletions docs/known_issues.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ Major
* Several event properties are not implemented (attendees, url,
user tags, attachments, etc.)

* Many todo item properties are not implemented (details, start date,
user tags, timed-but-undated (use daily repeating?), etc.)
* Many todo item properties are not implemented (start date, user tags,
timed-but-undated (use daily repeating?), etc.)

* Todo items can only be sorted by priority - add sort by duedate,
by status, manual...
Expand Down Expand Up @@ -217,9 +217,12 @@ Minor
* In untranslated languages, there can be some awkward mixing of languages
of fixed and generated content (e.g. "2. to last Sonntag of month")

* Newline behaviour in Notes field in Event dialog is not user-friendly.
Possible improvements: display a note in the field when it is empty;
a config option to swap with/without-modifier behaviours.
* Newline behaviour in the Notes field in Event and Todo dialogs is not
user-friendly. Possible improvements: display a note in the field when it
is empty; a config option to swap with/without-modifier behaviours.

* There are accelerators to go to Time/Repeats/Alarm... subtabs for Event
editing. The same should exist for Todo editing.

* In code, various places marked with '!!' indicating known bugs or
temporary/placeholder implementations.
Expand Down Expand Up @@ -251,8 +254,8 @@ Cosmetic
* In Event dialog, Repeats tab, "Repeat until" label doesn't seem to align
quite correctly with the field content.

* In Event dialog, in Notes field, the scroll-bar does not go to the border:
there is a 1-pixel gap.
* In Event and Todo dialogs, in Notes field, the scrollbar does not go to
the border: there is a 1-pixel gap.

Testing
-------
Expand Down
190 changes: 143 additions & 47 deletions pygenda/glade/dialog_todo.glade
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">end</property>
<property name="label" translatable="yes">Due date:</property>
<property name="label" translatable="yes">Status:</property>
<style>
<class name="llabel"/>
</style>
Expand All @@ -189,72 +189,168 @@
</packing>
</child>
<child>
<object class="GtkBox">
<object class="GtkComboBoxText" id="combo_todo_status">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="active">0</property>
<items>
<item translatable="yes">None</item>
<item id="NEEDS-ACTION" translatable="yes">Action required</item>
<item id="IN-PROCESS" translatable="yes">In progress</item>
<item id="COMPLETED" translatable="yes">Completed</item>
<item id="CANCELLED" translatable="yes">Cancelled</item>
</items>
</object>
<packing>
<property name="left-attach">1</property>
<property name="top-attach">3</property>
</packing>
</child>
<child>
<object class="GtkNotebook" id="dialogtodo_tabs">
<property name="visible">True</property>
<property name="can-focus">True</property>
<child>
<object class="GtkSwitch" id="switch_todo_duedate">
<!-- n-columns=2 n-rows=1 -->
<object class="GtkGrid">
<property name="visible">True</property>
<property name="can-focus">False</property>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">end</property>
<property name="label" translatable="yes">Due date:</property>
<style>
<class name="llabel"/>
</style>
</object>
<packing>
<property name="left-attach">0</property>
<property name="top-attach">0</property>
</packing>
</child>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="can-focus">False</property>
<child>
<object class="GtkSwitch" id="switch_todo_duedate">
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="halign">start</property>
<property name="valign">center</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkRevealer" id="revealer_duedate">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="transition-type">none</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
<property name="left-attach">1</property>
<property name="top-attach">0</property>
</packing>
</child>
</object>
</child>
<child type="tab">
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="halign">start</property>
<property name="valign">center</property>
<property name="can-focus">False</property>
<property name="label" translatable="yes">Dates/Times</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">0</property>
<property name="tab-fill">False</property>
</packing>
</child>
<child>
<object class="GtkRevealer" id="revealer_duedate">
<!-- n-columns=2 n-rows=1 -->
<object class="GtkGrid">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="transition-type">none</property>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">end</property>
<property name="valign">start</property>
<property name="label" translatable="yes">Notes:</property>
<style>
<class name="llabel"/>
</style>
</object>
<packing>
<property name="left-attach">0</property>
<property name="top-attach">0</property>
</packing>
</child>
<child>
<object class="GtkScrolledWindow">
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<property name="hscrollbar-policy">never</property>
<property name="vscrollbar-policy">always</property>
<property name="shadow-type">in</property>
<property name="kinetic-scrolling">False</property>
<property name="overlay-scrolling">False</property>
<child>
<object class="GtkTextView" id="textview_dialogtodo_notes">
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="wrap-mode">word-char</property>
<property name="accepts-tab">False</property>
<signal name="focus-in-event" handler="notes_focusin" swapped="no"/>
<signal name="focus-out-event" handler="notes_focusout" swapped="no"/>
<signal name="key-press-event" handler="notes_keypress" swapped="no"/>
</object>
</child>
<style>
<class name="longtextentry"/>
</style>
</object>
<packing>
<property name="left-attach">1</property>
<property name="top-attach">0</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
<property name="left-attach">1</property>
<property name="top-attach">3</property>
</packing>
</child>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">end</property>
<property name="label" translatable="yes">Status:</property>
<style>
<class name="llabel"/>
</style>
<child type="tab">
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="label" translatable="yes">Details</property>
</object>
<packing>
<property name="position">1</property>
<property name="tab-fill">False</property>
</packing>
</child>
</object>
<packing>
<property name="left-attach">0</property>
<property name="top-attach">4</property>
</packing>
</child>
<child>
<object class="GtkComboBoxText" id="combo_todo_status">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="active">0</property>
<items>
<item translatable="yes">None</item>
<item id="NEEDS-ACTION" translatable="yes">Action required</item>
<item id="IN-PROCESS" translatable="yes">In progress</item>
<item id="COMPLETED" translatable="yes">Completed</item>
<item id="CANCELLED" translatable="yes">Cancelled</item>
</items>
</object>
<packing>
<property name="left-attach">1</property>
<property name="top-attach">4</property>
<property name="width">2</property>
</packing>
</child>
</object>
Expand Down
Binary file modified pygenda/locale/fr/LC_MESSAGES/pygenda.mo
Binary file not shown.
32 changes: 18 additions & 14 deletions pygenda/locale/fr/LC_MESSAGES/pygenda.po
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ msgid ""
msgstr ""
"Project-Id-Version: Pygenda\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-09-09 23:32+0200\n"
"PO-Revision-Date: 2023-09-09 23:32+0200\n"
"POT-Creation-Date: 2023-09-11 23:13+0200\n"
"PO-Revision-Date: 2023-09-11 23:13+0200\n"
"Last-Translator: Matthew Lewis <pygenda@semiprime.com>\n"
"Language: fr\n"
"MIME-Version: 1.0\n"
Expand Down Expand Up @@ -78,7 +78,7 @@ msgstr "Date/heure de fin :"
msgid "Duration:"
msgstr "Durée :"

#: pygenda_dialog_entryprops.py:131 glade/dialog_todo.glade:181
#: pygenda_dialog_entryprops.py:131 glade/dialog_todo.glade:224
msgid "Due date:"
msgstr "Date limite :"

Expand Down Expand Up @@ -170,11 +170,11 @@ msgid "Repeats:"
msgstr "Répétition :"

#: pygenda_dialog_entryprops.py:197 glade/dialog_event.glade:946
#: glade/dialog_todo.glade:231
#: glade/dialog_todo.glade:181
msgid "Status:"
msgstr "Statut :"

#: pygenda_dialog_entryprops.py:217 pygenda_dialog_event.py:420
#: pygenda_dialog_entryprops.py:217 pygenda_dialog_event.py:405
# Added by hand - not detected by gettext
msgid "Audio"
msgstr "Audio"
Expand Down Expand Up @@ -304,7 +304,7 @@ msgstr "Modifier évènement"

#: pygenda_dialog_event.py:1179 glade/dialog_event.glade:397
#: glade/dialog_event.glade:691 glade/dialog_event.glade:964
#: glade/dialog_todo.glade:159 glade/dialog_todo.glade:248
#: glade/dialog_todo.glade:159 glade/dialog_todo.glade:198
msgid "None"
msgstr "Rien"

Expand All @@ -328,11 +328,11 @@ msgstr "Resultats de recherche"
msgid "No results found"
msgstr "Pas d’entrées trouvées"

#: pygenda_dialog_todo.py:116
#: pygenda_dialog_todo.py:143
msgid "New To-do"
msgstr "Nouvelle tâche"

#: pygenda_dialog_todo.py:127
#: pygenda_dialog_todo.py:154
msgid "Edit To-do"
msgstr "Modifier tâche"

Expand Down Expand Up @@ -527,19 +527,19 @@ msgstr "Lieu :"
msgid "Tentative"
msgstr "Provisoire"

#: glade/dialog_event.glade:966 glade/dialog_todo.glade:252
#: glade/dialog_event.glade:966 glade/dialog_todo.glade:202
msgid "Cancelled"
msgstr "Annulé"

#: glade/dialog_event.glade:967
msgid "Confirmed"
msgstr "Confirmé"

#: glade/dialog_event.glade:980
#: glade/dialog_event.glade:980 glade/dialog_todo.glade:292
msgid "Notes:"
msgstr "Notes :"

#: glade/dialog_event.glade:1030
#: glade/dialog_event.glade:1030 glade/dialog_todo.glade:342
msgid "Details"
msgstr "Détails"

Expand Down Expand Up @@ -567,18 +567,22 @@ msgstr "1 (la plus haute)"
msgid "9 (Lowest)"
msgstr "9 (la plus basse)"

#: glade/dialog_todo.glade:249
#: glade/dialog_todo.glade:199
msgid "Action required"
msgstr "Action requise"

#: glade/dialog_todo.glade:250
#: glade/dialog_todo.glade:200
msgid "In progress"
msgstr "En cours"

#: glade/dialog_todo.glade:251
#: glade/dialog_todo.glade:201
msgid "Completed"
msgstr "Achevé"

#: glade/dialog_todo.glade:275
msgid "Dates/Times"
msgstr "Dates/Heures"

#: glade/main.glade:53
msgid "_File"
msgstr "_Fichier"
Expand Down
Loading

0 comments on commit dcf522d

Please sign in to comment.