Skip to content

Commit

Permalink
[register] Delay post-ime reset of the selection.
Browse files Browse the repository at this point in the history
Works around bug 798587.
  • Loading branch information
jralls committed Dec 17, 2022
1 parent 16dca1a commit 65d3546
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions gnucash/register/register-gnome/gnucash-sheet.c
Original file line number Diff line number Diff line change
Expand Up @@ -1833,6 +1833,11 @@ gnucash_sheet_key_press_event_internal (GtkWidget *widget, GdkEventKey *event)
/* Followed by the input method */
if (gtk_entry_im_context_filter_keypress (GTK_ENTRY(sheet->entry), event))
{
/* There's sometimes a timing issue when running under KDE
* Plasma where this call removes the selection. This 1ms
* sleep prevents it.
*/
usleep(1000);
/* Restore the saved cursor position in case GtkEntry's IMContext
* handlers messed with it after we set it in our insert_cb.
*/
Expand Down

0 comments on commit 65d3546

Please sign in to comment.