! 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 !
Thunar side pane width is doubled with multibyte text items
Status:
RESOLVED: FIXED
Severity:
trivial

Comments

Description Mikhail 2008-03-26 12:32:07 CET
When Thunar side pane holds multibyte text items it's minimal width is set to the twice the width of the text.

The issue reproduces in openSUSE 10.2 and 10.3 with ru_RU.KOI8-R locale and
Mandriva 2008.0 with ru_RU.UTF-8 locale. All systems run Thunar 0.9.0.
Comment 1 Christian Dywan 2008-10-20 17:24:21 CEST
I'm seeing the same when running Thunar with LANG=ja_JP.utf8, it's pretty annoying.
Comment 2 Vitaly Pashkov 2009-06-25 21:09:37 CEST
Take a look at the thunar-shortcuts-view.c file on line 307. Here's the code:
"width-chars", strlen (_("File System")),

It is not a good idea to use strlen() for checking string length encoded with multibyte encoding. The solution is (probably) to use wcswidth() to calculate the length of a string or remove this line at all and it will remove links panel width limitation.
Comment 3 Jannis Pohlmann editbugs 2009-09-18 21:44:58 CEST
*** Bug 5390 has been marked as a duplicate of this bug. ***
Comment 4 Jannis Pohlmann editbugs 2009-09-18 21:45:41 CEST
This should be fixed in git. Please re-open if it's still not working for you.

commit 10dbf54f58c1b78e2f65863212e1e2179f24e318
Author: Jannis Pohlmann <jannis@xfce.org>
Date:   Fri Sep 18 23:41:06 2009 +0200

    Use g_utf8_strlen to calculate the sidepane width. Bugs #5390 and #3965.
    
    Using strlen() for the number of characters is unrealistic when dealing
    with multibyte strings.
Comment 5 Jannis Pohlmann editbugs 2009-11-11 14:00:20 CET
*** Bug 5358 has been marked as a duplicate of this bug. ***

Bug #3965

Reported by:
Mikhail
Reported on: 2008-03-26
Last modified on: 2009-11-11
Duplicates (2):
  • 5358 Bookmarks sidebar is too wide
  • 5390 horizontal split pane limitation

People

Assignee:
Jannis Pohlmann
CC List:
4 users

Version

Version:
unspecified

Attachments

Additional information