Bug: losing focus in ledger

Jack ostroffjh at users.sourceforge.net
Mon Dec 21 16:10:10 GMT 2020


On 12/21/20 10:48 AM, Peter wrote:
> On 21/12/2020 16:03, Jack wrote:
>> On Sonntag, 20. Dezember 2020 22:18:12 CET Jack wrote:
>>> On 2020.12.20 10:59, Ivan Perez wrote:
>>>>> I'm using KMM KMyMoney-5.1.0-eb19959-x86_64.AppImage and the 
>>>>> ledger is
>>>>> losing the focus on the transaction I am working on when I switch
>>>>> desktops
>>>>> and come back.
>>>>>
>>>>> This is a problem as I often need to switch desktops to check other
>>>>> info
>>>>> against KMM.
>>>>>
>>>>> Info:
>>>>> - Version: KMyMoney-5.1.0-eb19959-x86_64.AppImage.
>>>>> - OS: Ubuntu 18.04
>>>>> - Desktop: Gnome (Flashback Metacity)
>>>>>
>>>>> Steps:
>>>>> - Open a ledger with many transactions.
>>>>> - Click on a transaction near the beginning (top of the list).
>>>>> - Go to a different desktop (click on desktop switcher or via
>>>>> keyboard).
>>>>> - Return to desktop where KMM is.
>>>>>
>>>>> What happens:
>>>>> - The focus is back on the last transaction in the ledger.
>>>>>
>>>>> What should happen:
>>>>> - The focus should remain where it was.
>>>> Hello Ivan,
>>>>
>>>> I haven't actually tried this myself yet, but I'd be more tempted to
>>>> blame the Window Manager.  Can you test with any other app which also
>>>> has lots of things on the window which might get focus?  Can you also
>>>> try it with some other View which has multiple items displayed and see
>>>> if the focus changes.  Also, what happens if you edit a transaction 
>>>> and
>>>> then switch  desktops?  Are you still in edit mode with focus on the
>>>> same field, or has something changed?  All just things to get more
>>>> information to help focus in on the problem.
>>> In case Ivan means KMyMoney's view selector by 'desktop' then it is 
>>> true.
>>> Switching desktops or activities (both KDE/plasma contstructs) this 
>>> does
>>> not affect the selection of a transaction, at least not for me and 
>>> maybe
>>> many others.
>> Since me mentioned "Desktop switcher" I thought he meant the window 
>> manager's virtual or multiple desktop feature.  Actually, Ivan could 
>> also try just switching focus to a different application and then 
>> back as yet another test.
>
> I don't want to hijack the thread but I can confirm this behaviour. 
> When for example reconciling an account I have a pdf of the statement 
> on a different workspace to kmm, on returning to kmm focus goes to the 
> last entry. If I have the pdf side by side with kmm on the same 
> workspace focus remains on the last selected entry when switching 
> between them.
>
> KMM version 5.0.3
> OS LMDE 4
> Desktop Cinnamon

I also confirm this.  KMM 5.1.0, Artix Linux, KDE Frameworks 5.77.0, Qt 
5.15.2, KDE Plasma 5.20.4.

If I select a transaction, then switching desktops away and back changes 
focus to the last transaction on the ledger.  If I edit the transaction 
(ledger lens) then switch away and back, the same transaction is still 
open for editing.  However, on cancelling the edit, focus immediately 
switches to the last transaction instead of staying on the edited 
transaction.  As Thomas said, switching views within KMM also resets the 
focus, but that seems expected.

It seems not to be specific to one WM/DE, so I don't have any good idea 
how to troubleshoot further.



More information about the KMyMoney mailing list