After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 659129 - space alone triggers autocompletion
space alone triggers autocompletion
Status: RESOLVED DUPLICATE of bug 611089
Product: gnome-latex
Classification: Other
Component: general
2.2.x
Other Linux
: Normal major
: unspecified
Assigned To: LaTeXila maintainer(s)
LaTeXila maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2011-09-15 08:09 UTC by Tanguy Ortolo
Modified: 2011-09-16 15:31 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Tanguy Ortolo 2011-09-15 08:09:53 UTC
For some reason my LaTeXila now displays the autocompletion dialog each time I press the space key. This is mostly annoying because it makes it impossible to type spaces except by copying and pasting them! I see no option that could explain that in dconf…
Comment 1 Tanguy Ortolo 2011-09-15 08:20:12 UTC
I tried removing .local/share/latexila, .config/latexila and resetting all the dconf keys associated with LaTeXila: no change.
Comment 2 Tanguy Ortolo 2011-09-15 08:58:05 UTC
I tried with a user that never used LaTeXila, same problem. It does not seem to depend on the user configuration, although I do not understand why I did not have this problem before.
Comment 3 Tanguy Ortolo 2011-09-15 09:26:13 UTC
I tried with a freshly compiled from source LaTeXila, same problem. It does not seem to depend on the Debian packaging.
Comment 4 Sébastien Wilmet 2011-09-15 13:07:24 UTC
Thanks for reporting this bug. Another user reported it by mail. He was using Synapse (gnome-do like):

https://launchpad.net/synapse-project

He set the synapse shortcut as Ctrl+space, and after that he had this bug with latexila. Change the synapse shortcut didn't fix this bug.

If there is no problem with the 2.0 version, I see only two commits that can be the guilty:

1d424b7 Completion: Ctrl+space shortcut added to the menu
d88bbff Completion: use (un)block_interactive()

But this is most probably the first one. Try to revert it, or go to its previous commit.
Comment 5 Tanguy Ortolo 2011-09-15 14:45:46 UTC
I shall try that right now. I have just tried using 2.0, this problem disappears.
Comment 6 Tanguy Ortolo 2011-09-15 15:03:50 UTC
The culprit is 1d424b7. Reverting it solves the problem (and removes the menu entry of course)

d88bbff is innocent.
Comment 7 Sébastien Wilmet 2011-09-15 15:25:20 UTC
OK, thanks for this information.

I can obviously revert the commit and fix this bug, but I prefer to understand how to reproduce it, and fix it correctly (it's maybe a bug in GtkSourceView or another module).

Do you have another program installed that uses Ctrl+space as a global shortcut for the desktop, like synapse or gnome-do can do?

The unique purpose of adding the menu entry was to document the Ctrl+space shortcut. I think that nobody will go to the menu to activate the completion… So if I really need to remove the menu entry, I can simply write a new Mallard documentation page about the completion.
Comment 8 Tanguy Ortolo 2011-09-15 15:51:42 UTC
I use no desktop environment and my window manager (awesome) does not use such a shortcut, so the answer is no. :-)

Plus it happens too in the session of a newly created user using GNOME.
Comment 9 Sébastien Wilmet 2011-09-15 16:10:48 UTC
Since I don't have this bug, it's maybe related to GtkSourceView or GTK+. What's your versions of these modules?

I have (on gentoo) gtk+ 2.24.4 and gtksourceview 2.10.5.
Comment 10 Tanguy Ortolo 2011-09-15 20:24:42 UTC
GTK+ 2.24.4 too, GtkSourceView 2.10.4.
Comment 11 Sébastien Wilmet 2011-09-15 21:35:44 UTC
The only changes between GSV 2.10.4 and 2.10.5 are translation updates.

What is strange is that you didn't have this bug before. So it's maybe an update of another package. Can you see which packages have been updated recently on your system? And if you see something that can be in relation with this bug, try to downgrade it.
Comment 12 Sébastien Wilmet 2011-09-15 22:47:49 UTC
I tried synapse 0.2.6 with Ctrl+space to activate it, and the space in latexila is still working correctly.
Comment 13 Tanguy Ortolo 2011-09-16 09:31:09 UTC
When I install or upgrade a Debian package it is first downloaded to a cache directory and then unpacked. The cache directory is only cleaned when I ask for it.

I looked in this cache directory to find what packages were newer than four days and dependencies of LaTeXila: I found glib, gdk-pixbuf and gee. I installed older versions, but this bug remained…

I am experiencing this bug on two Debian amd64 installations, so I think that, for the Debian package, I shall just introduce a patch reverting this commit until we find a better way to solve that.
Comment 14 Tanguy Ortolo 2011-09-16 09:34:09 UTC
This is keymap-related. It happens when I am using the keymap fr-oss but not with fr-latin9 for instance:
    $ setxkbmap fr latin9
    $ latexila --new-document
        # no problem
    $ setxkbmap fr oss
        # space alone triggers the completion menu
Comment 15 Tanguy Ortolo 2011-09-16 11:35:51 UTC
It is specifically linked to the fact that the keymap fr(oss) inherits from nbsp(level4nl) which defines the space key as LOCAL_EIGHT_LEVEL, bearing the symbols space, no-break space in combination with Shift + AltGr and narrow no-break space in combination with Shift + Ctrl_Right.

When one uses fr-oss but overrides the space key mapping by using an option such as nbsp:level3n, this bug disappears:
    $ setxkbmap -layout fr -variant oss -option nbsp:level3n
    $ latexila --new-document
        # no problem
Comment 16 Sébastien Wilmet 2011-09-16 14:18:58 UTC
Thank you very much for your analyze. I can reproduce the bug.

So it's probably a bug in GTK+, more specifically the gtk_accelerator_parse() function.

I'm searching whether the bug has already been reported, or fixed in more recent versions than GTK+ 2.24.4.
Comment 17 Sébastien Wilmet 2011-09-16 15:31:21 UTC

*** This bug has been marked as a duplicate of bug 611089 ***