[upstream] Recent menu botches file names

Bug #1008277 reported by Edwin Lee
38
This bug affects 6 people
Affects Status Importance Assigned to Milestone
LibreOffice
Fix Released
Low
libreoffice (Ubuntu)
Fix Released
Low
Unassigned

Bug Description

Ubuntu 12.04 64-bit
Libreoffice
  (not sure about what package to check for version, so I just checked core:
    -> dpkg -s libreoffice-core | grep -i version
    Version: 1:3.5.3-0ubuntu1
  )

I have file names that have underscore characters. On the recent menu, these are all removed, probably as the string gets sanitized for other special characters. However, there's no real reason to remove underscores, that I know of anyway.

Expected:
  All file names to be displayed as they exist on the system

Actual:
  Underscores are removed...haven't checked other characters

Revision history for this message
Björn Michaelsen (bjoern-michaelsen) wrote :

Edwin, the issue you are reporting is an upstream one and it would be nice if somebody having it could send the bug to the developers of the software by following the instructions at http://wiki.documentfoundation.org/BugReport . If you have done so, please tell us the number of the upstream bug (or the link), so we can add a bugwatch that will inform us about the status. Thanks in advance.

Changed in libreoffice (Ubuntu):
importance: Undecided → Low
status: New → Incomplete
summary: - Recent menu botches file names
+ [upstream] Recent menu botches file names
Revision history for this message
In , Edwin Lee (leeed2001) wrote :

Ubuntu 12.04
LibreOffice 3.5.3.2
Build ID 350m1 (Build 2)

Using Draw, the recent file menu botches file names with underscores:
figure_Partitions.odg is shown as:
figurePartitions.odg

Although not a big deal, it seems like it is unnecessary to sanitize the file paths of special characters just to display in the recent menu.

I have only tried in Draw, and with the underscore character.

I originally filed in Ubuntu: https://bugs.launchpad.net/bugs/1008277, and was directed upstream.

Revision history for this message
Edwin Lee (leeed2001) wrote :
penalvch (penalvch)
Changed in df-libreoffice:
importance: Undecided → Unknown
status: New → Unknown
Changed in libreoffice (Ubuntu):
status: Incomplete → New
tags: added: likely-dup
tags: added: amd64 precise
Changed in df-libreoffice:
importance: Unknown → Medium
status: Unknown → New
Revision history for this message
In , hashemmasoud (wraithlike) wrote :

(In reply to comment #0)
Works for me:
Version 3.6.1.2 (Build ID: e29a214) Slackware Linux 13.37

Underscores in filename appear in the list of "Recent Documents".
Please re-open if you think otherwise.

Changed in df-libreoffice:
status: New → Invalid
Revision history for this message
In , Edwin Lee (leeed2001) wrote :

Created attachment 73119
Visualization of Problem

I filed this bug originally a while back, and it was marked as invalid. Just today, I noticed that I am still encountering the problem.

I am still on Ubuntu, 64-bit. Now I am running 12.10, and LibreOffice is at Version 3.6.2.2 (Build ID: 360m1 (Build:2))

The filenames are still being goofed in the Recent Menu. I have attached an image. For example, I commonly have files named:

figure_XYDimensions.png
figure_SomethingElse.png

In the recent menu, the underscores are gone. And (this may help narrow down the problem) when the recent menu is first shown, the filenames are plain, but as I hover over that menu, the underscores appear as an underline to the letter following their original position. This hints that the underscore is perhaps being interpreted as the shortcut for that menu item.

This happens in the core LibreOffice, not just when a single instance (calc, draw, etc.) is open.

Let me know if I can provide any further details, I know it isn't a serious issue, but it seems like it may be a simple fix to just *not* process recent file underscores as shortcut identifiers.

Thanks!!

Revision history for this message
In , Edwin Lee (leeed2001) wrote :

It has been a while since this was opened, but the exact problem is still occurring for me. I have updated my info (versions, etc.) and provided more information of the problem in comment #2, and also uploaded a screenshot of the problem.

Changed in df-libreoffice:
status: Invalid → Confirmed
Revision history for this message
In , Tine-emrich-y (tine-emrich-y) wrote :

I reproduced the bug with version 3.6.4.3 (Build ID: 360m1 (Build:3)) on an Ubuntu system (12.10, 64 bit).
On my windows machine (win7, 64 bit, libreoffice Version 3.6.4.3 (Build ID: 2ef5aff)) the bug didn't occur.

Building the latest version from source (4.1.0.0.alpha0+ (Build ID: b3e64c3708fa19a87a0df31f6dbc4ea4753b23d)) the bug is gone.

It seems to be fixed but I don't know exactly in which version. Should the ticket remain open?

Revision history for this message
Adolfo Jayme Barrientos (fitojb) wrote :

IMHO it's a GTK+ problem. I recall this being a problem in the Network Menu and was fixed there (LP: #903200, #739490), but it can happen in other apps as well.

Revision history for this message
In , mucku (dereinsameberg) wrote :

*** Bug 60715 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Simon Anders (sanders) wrote :

Bug still appears in LibreOffice 4.0.2.

Note, by the way, that only the _first_ underscore in a file name gets mangled. It seems that the GUI toolkit misinterprets the underscore as a hot-key marker.

Revision history for this message
In , Vstuart-foote (vstuart-foote) wrote :

From OP of bug 60715:
>Problem description: The Recent Documents list removes underscores "_" from the >filename and shows the filenames without them. Writer, Impress and Calc do this, >so it is probably the same for all.
>
>Operating System: Ubuntu
>Version: 3.6.4.3 release

Appears to have affected more than just Draw -- adjusting component to UI. LibreOffice repo rpm installs of 3.6.6 and 4.0.2 work for me on Fedora 18 with GNOME 3 or LXDE. Since so far only reported on Ubuntu 12.04 & 12.10 - is this a Unity or possibly a GTK+ issue?

@Simon Anders - details please of your OS build and source of LibreOffice 4.0.2? Are you on an Ubuntu install?

Revision history for this message
In , Vstuart-foote (vstuart-foote) wrote :

Adjusting summary replacing "sanitizes" with "removes underscore" as more more precise description of issue--and only because it will help when searching issues.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in gtk+3.0 (Ubuntu):
status: New → Confirmed
Changed in libreoffice (Ubuntu):
status: New → Confirmed
Revision history for this message
In , Samuel Mehrbrodt (sam92) wrote :

This seems to be an Unity issue, it doesn't appear in the usual menus, only in the Unity Global menu.

Please report the problem there.

Changed in df-libreoffice:
status: Confirmed → Won't Fix
Revision history for this message
In , Björn Michaelsen (bjoern-michaelsen) wrote :

Unity integration is part of upstream code, not a vendor patch, so reopening.

(and yes, reproducable in 4.1.2~rc3 on saucy)

Changed in df-libreoffice:
importance: Medium → Low
status: Won't Fix → Confirmed
Revision history for this message
In , Björn Michaelsen (bjoern-michaelsen) wrote :

Marking this as an challenging Easy Hack.

The translation from LibreOffice vcl to gtks menumodel happens around here:

http://opengrok.libreoffice.org/xref/core/vcl/unx/gtk/window/gtksalmenu.cxx#302

Revision history for this message
In , Björn Michaelsen (bjoern-michaelsen) wrote :

CCing developer list to Easy Hacks missing this.

affects: gtk+3.0 (Ubuntu) → ubuntu
affects: ubuntu → unity-gtk-module (Ubuntu)
Revision history for this message
In , Michaël Lefevre (lefevre00) wrote :

LibreOffice 4.1.3.2 (1:4.1.3-0ubuntu1)
Ubuntu 13.10

The problem is stil present and I found the following precision :
- work normaly under Gnome 3.8
- reproduce on Unity, only in the global menu.

The problem's not present in the welcoming splash screen when you start LibreOffice with plain new file, even when running in Unity.
I don't know if the same code used in both menu.

cf : http://opengrok.libreoffice.org/xref/core/framework/source/uielement/recentfilesmenucontroller.cxx#130

GTK used to consider undescore as mnemonic to give shorcut access in the menu.

Revision history for this message
In , Z-jbf-faure (z-jbf-faure) wrote :

I confirm the problem on my own build of LibreOffice 4.2.4.0.0+ under Ubuntu 13.10 x86-64.

Best regards. JBF

Revision history for this message
In , Michaël Lefevre (lefevre00) wrote :

While loolikng at https://bugzilla.redhat.com/show_bug.cgi?id=963307 , maybe we could escape the underscope in the filename.

But this bug doesn't not appear while running a plain Gnome session (tested). So I wonder if such a workaround is really worth it. Isn't there a way to fix Unity integration somewhere else ?

Revision history for this message
In , Michaël Lefevre (lefevre00) wrote :

Ok, found another interesting point.

https://bugs.launchpad.net/ubuntu/+source/unity-gtk-module/+bug/1260777

If anybody running bleeding edge trusty Ubuntu could try ?

Revision history for this message
In , Michaël Lefevre (lefevre00) wrote :

Just tested with 14.04 having unity-gtk-* package at version 0.0.0+14.04.20140319.
This hasn't fix this bug.

Revision history for this message
In , Samuel Mehrbrodt (sam92) wrote :
Revision history for this message
In , Z-jbf-faure (z-jbf-faure) wrote :

(In reply to comment #18)
> Fixed with
> http://cgit.freedesktop.org/libreoffice/core/commit/
> ?id=f6bcdc5ae6da9cb9b13bdc3551bef917d8b0362d

Thank you very much for this fix. Do you plan to backport it to 4.2 branch ?

Best regards. JBF

Revision history for this message
In , Libreoffice-commits (libreoffice-commits) wrote :

Samuel Mehrbrodt committed a patch related to this issue.
It has been pushed to "libreoffice-4-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=d6bc8ed3356d88231cca0306790f300517b7fae2&h=libreoffice-4-2

fdo#50672 Escape underscores in menus for unity

It will be available in LibreOffice 4.2.4.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds
Affected users are encouraged to test the fix and report feedback.

Revision history for this message
In , Samuel Mehrbrodt (sam92) wrote :

> Thank you very much for this fix. Do you plan to backport it to 4.2 branch ?

You're welcome. I didn't plan this, but now it has happened :)

Revision history for this message
In , Z-jbf-faure (z-jbf-faure) wrote :

(In reply to comment #21)
> > Thank you very much for this fix. Do you plan to backport it to 4.2 branch ?
>
> You're welcome. I didn't plan this, but now it has happened :)

And it works :-)
Thank you very much !

Best regards. JBF

Changed in df-libreoffice:
status: Confirmed → Fix Released
Revision history for this message
In , Björn Michaelsen (bjoern-michaelsen) wrote :

(In reply to comment #21)
> You're welcome. I didn't plan this, but now it has happened :)

Hi Samuel,

thank you very much for this fix, it was always on my agenda, but with such a low prio that I unfortunately never got to it. Ill make sure it'll be in Ubuntu Trusty on release.

Best, Bjoern

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package libreoffice - 1:4.2.3~rc3-0ubuntu1

---------------
libreoffice (1:4.2.3~rc3-0ubuntu1) trusty; urgency=medium

  * apply fix for recent file menu (LP: #1008277)
  * bump version for new upstream rc
  * we dont care for stderr in the autopkgtest configure
 -- Bjoern Michaelsen <email address hidden> Sat, 05 Apr 2014 13:34:25 +0200

Changed in libreoffice (Ubuntu):
status: Confirmed → Fix Released
no longer affects: unity-gtk-module (Ubuntu)
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.