When adding a new entry in a ledger and tabbing into the date widget, the default focus should be the day section. I have just upgraded from kmymoney 8.0 to kmymoney 8.1, and I couldn't not notice a very annoying change in the way the date widget is being handled. I have tracked the changes to this commit: https://bugs.kde.org/show_bug.cgi?id=374123 Git commit b22c965f5848642725ceb6c7ed7b22fdc296a950 Committed on 25/12/2016 Pushed by tbaumgart into branch '4.8'. Use first date section to start editing Use the first section of the date edit widget for the selected date format instead of always using the day section FIXED-IN: 4.8.1 M +12 -8 kmymoney/widgets/kmymoneydateinput.cpp M +33 -24 kmymoney/widgets/kmymoneydateinput.h When using kmymoney, most of the time is spent keying in new transactions in the ledger. For efficiency purposes, it is important to be able to do so without using the mouse, but simply and quickly tabbing from field to field. My usage pattern for some accounts is to enter about 1~2 weeks worth of transactions with a small handful of transactions for any given day, with my date format being YYYYMMDD. With KMM 4.8.0, tabbing into the date widget, the focus was on the day section by default, which suited me fine, because I am entering the transactions in chronological order and a single 'arrow up' key press allowed me to move on to the next day. Now, the focus is on the year by default, and for each transaction that occurred on the next day, I have to press 6 times the right arrow to focus on the day field and select the right day. Basically, the logic of the above 'fix' is a bit faulty as it assumes that the first section (the leftmost section) is the most useful/relevant one, whereas the day section is the most relevant. Reverting the above commit would suit me fine. Also, since we're speaking about the date selection widget, what I'd really like is to be able to move to the next month/year simply by incrementing the day part. E.g. with the focus on the day section, arrow up increments the day from 01 to 02, from 02 to 03, etc. and on the 31st of one month, to the 1st of the next month, from the 28th (or 29th) of February to the 1st of March, from the 31st of December to the 1st of January of the following year. Have the same logic applied in reverse with a arrow down key press (moving from the 1st January to the 31st of December of the previous year, from the 1st to the last day of the previous month, etc.). Do the KDE/Qt libraries have such a functionality for their date widget?
Looks like we need to introduce a new user option for data entry here as both requests exclude each other. Regarding your question "Also, since we're speaking about the date selection widget, what I'd really like is to be able to move to the next month/year simply by incrementing the day part" I found the following in our very fine documentation at https://docs.kde.org/stable4/en/extragear-office/kmymoney/reference.widgets.html#reference.widgets.datepicker : "Within the date entry widget, the left/right cursor keys can be used to switch between the day, the month, and the year fields. Using the up/down cursor keys, the value of the selected field can be incremented/decremented. The + and - keys can be used to increment/decrement a single day. Month and year boundaries are considered and incremented/decremented if necessary. Pressing T will set the date to today's date." And that +/- day inc/dec function even works if the cursor is in the year field. Maybe, that is already the function you are looking for.
Thank you Thomas. I feel your pain, when, as a developer, you face two end users with mutually exclusive requests. I am grateful for your long term contributions to this project. The +/- keys cover perfectly the second need I was describing. Thanks a lot. Next time, I'll make sure to consult the kmymoney documentation first. Sorry about that. Back to the original request about the focus on the day section of the date widget: Personally, I am fortunate enough to be using Gentoo, so having managed to find the appropriate commit (referred above), it was easy enough to produce a quick and dirty patch and re-emerge (re-compile) the package, so that on my system the focus is now back on the day section. But it helps only me and potentially other Gentoo/kmymoney users. The +/- key functionally render the feature request less important because other users may form the habit of using the +/- keys instead of the arrows. Having said that, I still prefer using the arrows, because when I key in my transactions, my fingers are already placed there (due to selecting the payee a couple of fields earlier), so I will keep my patch in place. Besides, I can't really think of a use case where focus on the year section in the widget might be more useful in a day to day use of kmymoney... It really appears to me more logical to have the default focus placed on the day, regardless of the date format used, as it used to be.
Please do not feel undue pressure for what is now a minor request, but for the record, the ideal functionality would be if the arrow up/down keys would behave as the +/- keys, i.e. if they were also incrementing/descrementing the month and year when appropriate. Then we can ignore the end of month situation and always use the same arrow keys. I am not familiar with the QT API so I don't know how much of a hassle it would be to implement. Feel free to ignore this. void KMyMoney::OldDateEdit::keyPressEvent(QKeyEvent* k) { // ... QDateEdit::keyPressEvent(k); } http://doc.qt.io/archives/qt-4.8/qdatetimeedit.html#keyPressEvent
See also https://bugs.kde.org/show_bug.cgi?id=355010 - Autofill Transaction Select Amount
The related review request is https://phabricator.kde.org/D10310
Git commit 904775b2005c888abaf869b70ab8c46f0e1e5074 by Ralf Habacker. Committed on 06/02/2018 at 20:06. Pushed by habacker into branch '4.8'. Allow the user to select the initial date cursor position in the settings dialog As default the cursor position is set to the day part of the date field. This patch contains a fix to be compilable with gcc 4.8. Related: bug 374123 FIXED-IN:4.8.2 Test Plan: compiled and tested on linux Reviewers: #kmymoney, tbaumgart Reviewed By: #kmymoney, tbaumgart Subscribers: tbaumgart Differential Revision: https://phabricator.kde.org/D10310 M +46 -0 kmymoney/dialogs/settings/ksettingsregisterdecl.ui M +9 -0 kmymoney/settings/kmymoney.kcfg M +1 -0 kmymoney/settings/kmymoneysettings.kcfgc M +12 -4 kmymoney/widgets/kmymoneydateinput.cpp https://commits.kde.org/kmymoney/904775b2005c888abaf869b70ab8c46f0e1e5074
Git commit e0e1604642ac5245d232349f7a5cf203652075af by Ralf Habacker. Committed on 06/02/2018 at 20:05. Pushed by habacker into branch '4.8'. Fix issues with multiple instances of KMyMoneySettings Calling a static method from class KMyMoneyGlobalSettings inside kmm_widgets library surprisingly creates an additional KMymoneySettings instance, which does not reflect the recent state from the setting dialog. The reason for this behavior is caused by duplicated implementations of class KMymoneySettings (kmm_config, settings) and embedding the static library kmm_config into shared libraries (kmm_mymoney, kmm_widgets and kmm_ofximport). Each embedded copy has it's own instance of class KMymoneySettings. The solution for this issue, which is done with this patch, is to remove the duplicated implementation from the settings library and to make kmm_config a shared library. This patch also renames kmm_config to kmm_settings and place it into it own subdirectory to keep in sync with 5.0 branch. Related: bug 374123 FIXED-IN:4.8.2 Test Plan: compiled on linux Reviewers: #kmymoney, tbaumgart Reviewed By: tbaumgart Subscribers: tbaumgart Differential Revision: https://phabricator.kde.org/D10322 M +10 -10 kmymoney/CMakeLists.txt M +1 -1 kmymoney/converter/CMakeLists.txt M +1 -8 kmymoney/dialogs/settings/CMakeLists.txt M +1 -1 kmymoney/models/CMakeLists.txt M +1 -1 kmymoney/mymoney/CMakeLists.txt M +1 -1 kmymoney/plugins/onlinetasks/sepa/CMakeLists.txt M +5 -5 kmymoney/reports/CMakeLists.txt A +13 -0 kmymoney/settings/CMakeLists.txt R +0 -0 kmymoney/settings/kmymoney.kcfg [from: kmymoney/kmymoney.kcfg - 100% similarity] R +2 -0 kmymoney/settings/kmymoneysettings.kcfgc [from: kmymoney/kmymoneysettings.kcfgc - 053% similarity] M +4 -4 kmymoney/widgets/CMakeLists.txt https://commits.kde.org/kmymoney/e0e1604642ac5245d232349f7a5cf203652075af