Bug 491211 - Icons remain left-aligned after changing the system language to Arabic
Summary: Icons remain left-aligned after changing the system language to Arabic
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Task Manager and Icons-Only Task Manager widgets (show other bugs)
Version: master
Platform: Other Linux
: NOR normal
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords: regression, rtl
Depends on:
Blocks:
 
Reported: 2024-08-03 09:54 UTC by 0773377
Modified: 2024-08-07 17:44 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 6.1.5
Sentry Crash Report:


Attachments
picofthebug (2.84 MB, image/png)
2024-08-03 09:54 UTC, 0773377
Details
left (1.51 MB, image/png)
2024-08-03 14:46 UTC, 0773377
Details
bottom (1.66 MB, image/png)
2024-08-03 14:48 UTC, 0773377
Details
RTL panel with icons on the right (379.29 KB, image/png)
2024-08-03 15:24 UTC, cwo
Details
problem fixed (2.82 MB, image/png)
2024-08-03 16:06 UTC, 0773377
Details

Note You need to log in before you can comment on or make changes to this bug.
Description 0773377 2024-08-03 09:54:23 UTC
Created attachment 172241 [details]
picofthebug

Once i change the system language to arabic icons move to left side of the panel, tried with openSUSE, kde neon, now fedora.

Operating System: Fedora Linux 40
KDE Plasma Version: 6.1.3
KDE Frameworks Version: 6.4.0
Qt Version: 6.7.2
Kernel Version: 6.9.12-200.fc40.x86_64 (64-bit)
Graphics Platform: Wayland
Comment 1 cwo 2024-08-03 13:17:48 UTC
Arabic is a right-to-left language, and the panel adapts to this by changing its orientation as well.

If you prefer a different arrangement, you can reorder the icons by right-clicking the panel and selecting "Show panel configuration".
Comment 2 cwo 2024-08-03 13:22:05 UTC
Ah sorry, I now see what you mean, the Icon-only task manager should be reversed as well. I apologize.

You can configure this by right-clicking the task manager, selecting "Configure Icon Only Task Manager", clicking the behavior tab, and changing the bottom option.

The system should probably automatically do this in RTL mode if it doesn't already. Did you install the system with Arabic language as the default, or did you first run it in English, then selected Arabic language as your user?
Comment 3 0773377 2024-08-03 14:11:02 UTC
i tried every solution possible Configure Icon Only Task Manager swapping remove add new panel with out any lock.

if i change task Manager left or right like in gnome its normal but if i make it up or down it become like this with free space at right.

i install the system in English, then selected Arabic language.

Thanks!
Comment 4 cwo 2024-08-03 14:28:50 UTC
(In reply to 0773377 from comment #3)
> if i change task Manager left or right like in gnome its normal but if i
> make it up or down it become like this with free space at right.

Can you be a bit more precise what you mean with "make it up or down"? Are you talking about a vertical panel?
Comment 5 0773377 2024-08-03 14:36:13 UTC
sorry, yes the position of vertical panel.
Comment 6 cwo 2024-08-03 14:39:40 UTC
(In reply to 0773377 from comment #5)
> sorry, yes the position of vertical panel.

Your screenshot shows a horizontal panel (and here selecting "New tasks appear to the right" should work. Can you show the bug on a vertical panel, so that I can better understand what exactly you mean?
Comment 7 0773377 2024-08-03 14:46:39 UTC
Created attachment 172246 [details]
left
Comment 8 0773377 2024-08-03 14:48:12 UTC
Created attachment 172247 [details]
bottom
Comment 9 0773377 2024-08-03 14:52:42 UTC
(In reply to cwo from comment #6)
> (In reply to 0773377 from comment #5)
> > sorry, yes the position of vertical panel.
> 
> Your screenshot shows a horizontal panel (and here selecting "New tasks
> appear to the right" should work. Can you show the bug on a vertical panel,
> so that I can better understand what exactly you mean?

im sorry im trying my best here. I apologize.
i added 2 pictures.

Thank you so much for your help.
really appreciate it.
Comment 10 cwo 2024-08-03 15:24:22 UTC
Created attachment 172250 [details]
RTL panel with icons on the right

Thank you for the pictures.

I'm still not quite sure what you want unfortunately - to my non-arabic eyes the vertical panel (i.e. "left" screenshot) looks good.

If you're asking about the screenshot "bottom", try the following: 

1) Set the task manager to "new tasks appear on the left" (right-click the task manager > Configure … > Behavior > ). This reverses the order of the icons, so that they are right-to-left.

2) Right-click the panel > Show panel configuration >  Add spacer (this it the button in the header of the small window that shows up, the button with the two small rectangles and a black thing in between, next to the button with the + sign). A bit of the panel will now be empty and highlighted. You can move this area to the left of the task manager simply by dragging it.

If I do that (with plasmashell manually set to RTL order as I use an English locale), I get the attached arrangement, which I think is what you want , but correct me if I didn't understand you yet.
Comment 11 0773377 2024-08-03 16:06:21 UTC
Created attachment 172252 [details]
problem fixed
Comment 12 0773377 2024-08-03 16:06:32 UTC
(In reply to cwo from comment #10)
> Created attachment 172250 [details]
> RTL panel with icons on the right
> 
> Thank you for the pictures.
> 
> I'm still not quite sure what you want unfortunately - to my non-arabic eyes
> the vertical panel (i.e. "left" screenshot) looks good.
> 
> If you're asking about the screenshot "bottom", try the following: 
> 
> 1) Set the task manager to "new tasks appear on the left" (right-click the
> task manager > Configure … > Behavior > ). This reverses the order of the
> icons, so that they are right-to-left.
> 
> 2) Right-click the panel > Show panel configuration >  Add spacer (this it
> the button in the header of the small window that shows up, the button with
> the two small rectangles and a black thing in between, next to the button
> with the + sign). A bit of the panel will now be empty and highlighted. You
> can move this area to the left of the task manager simply by dragging it.
> 
> If I do that (with plasmashell manually set to RTL order as I use an English
> locale), I get the attached arrangement, which I think is what you want ,
> but correct me if I didn't understand you yet.

Adding spacer fix the problem completely, evertything looks good.

I would like to point out the ive tried kde 6 when it was released, i didnt have this problem at all.
in past days ive tried opensuse, kde neon, fedora with the last kde plasma fresh install update and change it to arabic all of them have this proplem.

Thank you your help :)
Comment 13 cwo 2024-08-03 16:10:23 UTC
Good to know that you got it fixed.

When you tried it before with Plasma 6, did you install it directly in Arabic or did you also install it first in English, then switch to Arabic?
Comment 14 0773377 2024-08-03 16:38:32 UTC
(In reply to cwo from comment #13)
> Good to know that you got it fixed.
> 
> When you tried it before with Plasma 6, did you install it directly in
> Arabic or did you also install it first in English, then switch to Arabic?

install it first in English, then switch to Arabic.
Comment 15 cwo 2024-08-03 16:46:10 UTC
OK, thanks for the information. I'm leaving this bug report open so that someone more familiar with how this part of the system is supposed to work can comment on whether there may be a regression here, or something that should be fixed.
Comment 16 Nate Graham 2024-08-06 19:54:27 UTC
With a panel in its default settings, I can reproduce the issue with `LANG=ar_OM plasmashell --replace` or `LANG=ar_AR plasmashell --replace. Basically, the Task Manager icons remain left-aligned when they should be right-aligned.
Comment 17 Nate Graham 2024-08-06 19:59:19 UTC
This appears to have been at least partially caused by https://invent.kde.org/plasma/plasma-desktop/-/commit/d1b33d1a9dc872e9a2af042152d6ab5ed2617e4e.

There also seems to be a pre-existing bug in the layout direction calculation. I'm investigating.
Comment 18 Nate Graham 2024-08-06 20:04:02 UTC
Correction: LANGUAGE=ar_AR, not LANG=ar_AR
Comment 19 Nate Graham 2024-08-06 20:17:41 UTC
Found it. Patch incoming.
Comment 20 Bug Janitor Service 2024-08-06 20:23:28 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-desktop/-/merge_requests/2421
Comment 21 Nate Graham 2024-08-07 17:18:53 UTC
Git commit bc603c59d7ca85dbbd3c688e773de096a3186cc3 by Nate Graham.
Committed on 07/08/2024 at 16:46.
Pushed by ngraham into branch 'master'.

applets/taskmanager: fix task list RTL alignment

LayoutMirroring needed to be enabled when needed here.
FIXED-IN: 6.1.5

M  +2    -0    applets/taskmanager/package/contents/ui/main.qml

https://invent.kde.org/plasma/plasma-desktop/-/commit/bc603c59d7ca85dbbd3c688e773de096a3186cc3
Comment 22 Nate Graham 2024-08-07 17:44:58 UTC
Git commit 420930e11886c1902f94ed1b5c8d0a60f0c29543 by Nate Graham.
Committed on 07/08/2024 at 17:19.
Pushed by ngraham into branch 'Plasma/6.1'.

applets/taskmanager: fix task list RTL alignment

LayoutMirroring needed to be enabled when needed here.
FIXED-IN: 6.1.5


(cherry picked from commit bc603c59d7ca85dbbd3c688e773de096a3186cc3)

Co-authored-by: Nate Graham <nate@kde.org>

M  +2    -0    applets/taskmanager/package/contents/ui/main.qml

https://invent.kde.org/plasma/plasma-desktop/-/commit/420930e11886c1902f94ed1b5c8d0a60f0c29543