gnome-system-tools: mnemonic/accelerator shows as underscore instead of underline, and does not register with keyboard

Bug #404767 reported by xtknight
36
This bug affects 4 people
Affects Status Importance Assigned to Milestone
GST
Expired
Low
GTK+
Fix Released
Medium
gnome-system-tools (Ubuntu)
Fix Released
Low
Unassigned

Bug Description

This is a bug in several applications.

On Karmic, I'm seeing buttons that have an underscore instead of an underline for the accelerator key. It's more obvious what I'm talking about by looking at the screenshots I posted.

It happens only on certain buttons, but on those certain buttons it happens consistently. I don't know why. And the accelerator is actually broken on the keyboard when this happens, as well. Underlined accelerators work fine, but underscored accelerators are not even registered on the keyboard.

Revision history for this message
xtknight (xt-knight) wrote :

Look at "_Unlock" button.

Revision history for this message
xtknight (xt-knight) wrote :

Look at "Find _Next" button.

description: updated
Revision history for this message
Sebastien Bacher (seb128) wrote :

Thank you for your bug report, not sure if that's a gtk issue or a bug in those softwars

Changed in gtk+2.0 (Ubuntu):
importance: Undecided → Low
status: New → Confirmed
Revision history for this message
Atanas Atanasov (thenasko) wrote :

I can confirm the problem too. It is interesting that the underscore accelerator works sometimes. I have not been able to find a rule when this happens.

Revision history for this message
Stefan Lesicnik (stefanlsd) wrote :

Hi,

I just did a fresh Karmic Alpha 3 install and noticed this bug in Xchat. The network list shows C_onnect. I checked the upstream source and .po files and contacted upstream who confirmed this is correct behaviour, and suggested the problem must be in the gtk stack somewhere.

LANG=en_US.UTF-8

Interestingly, all the other accelerators on that same form display and function as expected.

Revision history for this message
Sebastien Bacher (seb128) wrote :

the issue is a bug in those softwares not using use_underline, reassigning to gnome-system-tools for the users-admin issue open new bugs about other softwares

affects: gtk+2.0 (Ubuntu) → gnome-system-tools (Ubuntu)
Revision history for this message
xtknight (xt-knight) wrote :

Yup. To fix it, edit src/common/gst-polkit-button.c under gnome-system-tools:

line ~262
 return g_object_new (GST_TYPE_POLKIT_BUTTON,
        "action", action,
        "label", label,
        "use-underline", TRUE, /* add this to fix the problem */
        NULL);

Revision history for this message
xtknight (xt-knight) wrote :

This debdiff fixes all the programs in gnome-system-tools and gnome-network-admin. They use this common file to make the PolicyKit Unlock button.

description: updated
summary: - gtk: mnemonic/accelerator shows as underscore instead of underline, and
- does not register with keyboard
+ various: mnemonic/accelerator shows as underscore instead of underline,
+ and does not register with keyboard
xtknight (xt-knight)
summary: - various: mnemonic/accelerator shows as underscore instead of underline,
- and does not register with keyboard
+ gnome-system-tools: mnemonic/accelerator shows as underscore instead of
+ underline, and does not register with keyboard
Revision history for this message
Atanas Atanasov (thenasko) wrote :

I just noticed that Epiphany's "Clear history" dialog has the same problem.

Revision history for this message
xtknight (xt-knight) wrote :

Atanas Atanasov:

See Bug 407596

Revision history for this message
xtknight (xt-knight) wrote :

Umm we're absolutely sure this is a bug in each individual package, right?

Something must have changed in gtk that caused use-underline to be false by default. I don't know what would have caused all these packages to suddenly have problems.

Anyway if you see any other problems please open another bug and link me to it, or alert me to the program, and I'll post a debdiff for it.

xtknight (xt-knight)
Changed in gst:
status: New → Invalid
Changed in gtk:
status: Unknown → New
Revision history for this message
Sebastien Bacher (seb128) wrote :

thank you for your work there

Changed in gnome-system-tools (Ubuntu):
status: Confirmed → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gnome-system-tools - 2.27.2-0ubuntu2

---------------
gnome-system-tools (2.27.2-0ubuntu2) karmic; urgency=low

  * debian/patches/84_polkit-btn-use-underline.patch:
    - Enable "use-underline" for polkit button so that accelerator
    works. (LP: #404767)

 -- Andy Matteson <email address hidden> Fri, 31 Jul 2009 10:58:37 -0400

Changed in gnome-system-tools (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

Hey, what's the joke here? Why did you add this patch to the Ubuntu package of the gnome-system-tools without even reporting it upstream? If we're sure that's the right thing to do, I'd have committed it in a few hours!

Now, could you make the status of this bug clearer? The GTK+ upstream bug is not explicit about what could have changed WRT default behavior of underline. And to me, PolicyKit should allow us to create such buttons without tuning the "use-underline" option at all.

Changed in gst:
importance: Undecided → Unknown
status: Invalid → Unknown
Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

OK, the problem has nothing to do with PolicyKit. That's only a change in GTK+ that affects the internals of g-s-t. I guess your patch (or something similar) is the way to go upstream, if we're sure the new default will stay.

Changed in gst:
status: Unknown → Incomplete
Revision history for this message
xtknight (xt-knight) wrote :

Milan:

I did report this upstream in gtk.
http://bugzilla.gnome.org/show_bug.cgi?id=590656

There's bugs in xchat, epiphany-browser, and gnome-applets too. All these apps suddenly being broken seemed like gtk to me. The reply I got was that there was a fix for gtk and glade that should have fixed it. I did not have time to test this on my machine. Therefore I didn't report it in GST yet. Also, I don't think another bug report is needed, maybe only a modification to the original one if the bug wasn't *actually* in GTK?

As to why Ubuntu posted my fix I don't know. I don't have that power. It wasn't my intention until it was cleared up whether the bug was in gtk or each individual program. And at this point I still don't know why this isn't in gtk?

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

So your fix is the right one, but in the meantime we've moved to PolicyKit1, which allows us to replace that button with their stock unlock button. So that will be fixed in the upcoming 2.27.3, and you'll be able to drop the patch (which won't apply anyway). Thanks for your interest!

Changed in gtk:
importance: Unknown → Medium
status: New → Fix Released
Changed in gst:
importance: Unknown → Low
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.