! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
"Applications Menu" title shows by default, despite unchecked box
Status:
RESOLVED: FIXED
Product:
Xfce4-panel
Component:
Applications Menu

Comments

Description Thaddaeus Tintenfisch editbugs 2015-02-14 21:53:09 CET
When adding a new "Applications Menu" to the panel, it shows a button title by default. However, in the properties dialogue, the "Show button title" checkbox is unchecked.

Simply checking and unchecking the box resolves the issue.

xfce4-panel 4.11.0
Comment 1 Daniel Wilkins 2015-02-22 07:29:43 CET
Created attachment 5977 
Don't blindly assume that the button label should be on by default

Just generated it with git diff against the current head as of today (February 21st)
Comment 2 Simon Steinbeiss editbugs 2015-03-04 12:27:59 CET
*** Bug 11641 has been marked as a duplicate of this bug. ***
Comment 3 Adam Purkrt 2015-10-25 22:00:44 CET
Though agreeably a minor bug, it is somehow confusing to the user. I've encountered it numerous times, when switching the label off after installation. Glad to see someone has been working on this.

Tried the patch. The "Properties" dialog indeed correctly reflects the visual outcome.

But I see a problem in the fact that the label becomes "off" by default. This effectively changes the default config (its final visual outcome for the user). Arguably, many (if not most) of the users are used to having the label present, and don't care whether this switch is working correctly or not.
Comment 4 Daniel Wilkins 2015-10-26 01:04:17 CET
(In reply to Adam Purkrt from comment #3)
> Though agreeably a minor bug, it is somehow confusing to the user. I've
> encountered it numerous times, when switching the label off after
> installation. Glad to see someone has been working on this.
> 
> Tried the patch. The "Properties" dialog indeed correctly reflects the
> visual outcome.
> 
> But I see a problem in the fact that the label becomes "off" by default.
> This effectively changes the default config (its final visual outcome for
> the user). Arguably, many (if not most) of the users are used to having the
> label present, and don't care whether this switch is working correctly or
> not.

Wow, this patch still applies? I figured it was just stuck languishing for forever. It'd be easy enough to swap the defaults around, I just choose to have the ui reflect the behavior that was actually happening rather than the other way around; if there's actually any interest in merging the patch I'd be happy to orient it whichever way the dev wants.
Comment 5 Adam Purkrt 2015-10-26 21:01:27 CET
(In reply to Daniel Wilkins from comment #4)
> Wow, this patch still applies? I figured it was just stuck languishing for
> forever. It'd be easy enough to swap the defaults around, I just choose to
> have the ui reflect the behavior that was actually happening rather than the
> other way around; if there's actually any interest in merging the patch I'd
> be happy to orient it whichever way the dev wants.

It might be more tricky than it seems. I applied the patch directly (to xfce4-panel-4.12.0), it works. Then I played with it, and it can be reduced to only the following single change

-  gtk_widget_show (plugin->label);
+  if (plugin->show_button_title)
+      gtk_widget_show (plugin->label);


The tricky part - for me - is that in the original source, in function "applications_menu_plugin_class_init", the "show-button-title" property is set to TRUE, yet in the end it is FALSE. So the "blind assumption" that the title (label) is on by default is perhaps not so blind. The real bug seems to be in the fact that the plugin->show_button_title is not "TRUE" even if it should be.
Comment 6 Adam Purkrt 2015-10-26 22:12:24 CET
Created attachment 6493 
xfce4-panel-applicationsmenu-show_button_title.patch

In my opinion, the bug is just a forgotten initialization of plugin->show_button_title variable. After adding the initialization in (see the one-line patch), the "Show button title" checkbox is checked upon adding the "Applications Menu" to the panel, and the title is shown as well.
Comment 7 Simon Steinbeiss editbugs 2016-07-07 00:06:13 CEST
(In reply to Adam Purkrt from comment #6)
> Created attachment 6493 
> xfce4-panel-applicationsmenu-show_button_title.patch
> 
> In my opinion, the bug is just a forgotten initialization of
> plugin->show_button_title variable. After adding the initialization in (see
> the one-line patch), the "Show button title" checkbox is checked upon adding
> the "Applications Menu" to the panel, and the title is shown as well.

After looking into the issue I agree (and in fact custom_menu also is not initialized, but for that one it doesn't matter cause the default is FALSE) and have merged and pushed the patch. Thanks Adam!

http://git.xfce.org/xfce/xfce4-panel/commit/?id=6d55c203896aa1d3c8c39d8946f229eeb9f581d3

Bug #11540

Reported by:
Thaddaeus Tintenfisch
Reported on: 2015-02-14
Last modified on: 2016-07-07
Duplicates (1):
  • 11641 Show button title not ticked by default

People

Assignee:
Nick Schermer
CC List:
4 users

Version

Version:
Unspecified

Attachments

Additional information