Bug 257643 - OSD sometimes misplaces the font and the font's "shadow"
Summary: OSD sometimes misplaces the font and the font's "shadow"
Status: RESOLVED FIXED
Alias: None
Product: amarok
Classification: Applications
Component: Notifications (show other bugs)
Version: 2.6-git
Platform: Debian unstable Linux
: NOR normal
Target Milestone: ---
Assignee: Amarok Developers
URL:
Keywords:
: 260370 263058 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-11-22 21:13 UTC by micu
Modified: 2013-03-02 22:17 UTC (History)
8 users (show)

See Also:
Latest Commit:
Version Fixed In: 2.8


Attachments
A part of a screenshot showing the issue (104.25 KB, image/png)
2010-11-22 21:13 UTC, micu
Details
2.4.0 screenshot (166.35 KB, image/png)
2011-01-16 14:09 UTC, Piotr Mitas
Details
font settings dialog (77.64 KB, image/png)
2011-01-16 16:55 UTC, Piotr Mitas
Details
It still happens with Amarok version >= 2.4 (602.45 KB, image/png)
2011-01-17 16:11 UTC, micu
Details
my fonts configuration dialog (83.15 KB, image/png)
2011-01-17 16:28 UTC, micu
Details

Note You need to log in before you can comment on or make changes to this bug.
Description micu 2010-11-22 21:13:27 UTC
Created attachment 53640 [details]
A part of a screenshot showing the issue

Version:           2.3.2 (using KDE 4.5.3) 
OS:                Linux

See the attached picture. Could be a raster (http://www.micuintus.de/2010/09/03/how-to-drastically-boost-up-your-kde-4-performance-by-using-the-qt-raster-rendering-engine/) issue but AFAIR this also happens with native Qt rendering.

I run aptosid with newer KDE SC packages from http://qt-kde.debian.net/
Amarok comes from Debian experimental.


Reproducible: Sometimes




OS: Linux (x86_64) release 2.6.36-0.slh.8-aptosid-amd64
Compiler: cc
Comment 1 Myriam Schweingruber 2010-11-23 02:05:23 UTC
AFAIK this is already solved in 2.4-git, see also bug 195186 which is related. Feel free to reopen this report if you can reproduce it with Amarok 2.4 or later.
Comment 2 Myriam Schweingruber 2011-01-14 12:49:38 UTC
*** Bug 263058 has been marked as a duplicate of this bug. ***
Comment 3 Piotr Mitas 2011-01-16 13:18:37 UTC
Hi,

I've just seen this bug in 2.4, so it's not fixed at all. Also, I don't see any option to reopen the bug here.
Comment 4 Kevin Funk 2011-01-16 14:00:29 UTC
Please tell us how to reproduce this,

does it always appear at the same OSD text? If yes, please tell us your current OSD settings and OSD text so we can reproduce locally and fix this.

Thanks

PS: Can't REOPEN this bug either for some reason, marking it as UNCONFIRMED for now.
Comment 5 Piotr Mitas 2011-01-16 14:07:40 UTC
Yes, it happens alway at the same OSD text. I noticed it happens even with the
OSD preview. I'll attach a screenshot
Comment 6 Piotr Mitas 2011-01-16 14:09:35 UTC
Created attachment 56092 [details]
2.4.0 screenshot
Comment 7 Kevin Funk 2011-01-16 14:17:07 UTC
Okay, thanks a lot.

Can't reproduce with my font settings.
Additonally, I need your KDE settings for "general font" and DPI settings. Maybe that's it.
Comment 8 Piotr Mitas 2011-01-16 14:22:57 UTC
Yes, that's it. I was using Verdana font, and when I switched to default font the problem went away. 

As for DPI settings, in case you still need them: where can I find them?
Comment 9 Kevin Funk 2011-01-16 16:26:52 UTC
Sorry, still can't reproduce at all. Tried with Verdana and multiple sizes. Could you please post a screenshot of the KDE font settings dialog (system settings)?
Comment 10 Piotr Mitas 2011-01-16 16:55:26 UTC
Created attachment 56095 [details]
font settings dialog

Sure. Here it is.
Comment 11 micu 2011-01-17 16:11:18 UTC
Created attachment 56128 [details]
It still happens with Amarok version >= 2.4
Comment 12 micu 2011-01-17 16:28:55 UTC
Created attachment 56130 [details]
my fonts configuration dialog

My .fonts.conf follows below.

My conjecture that it could be a raster engine issue seems more and more plausible to me: I didn't have this issue anymore for a long time, but today I switched back to the Qt raster engine (as it is much faster; I dropped raster for a while because it consumes more main memory), and I had this bug again with Amarok 2.4.0 (fresh from the Debian sid repos) — see my prev. attachement.

Piotr, do you have the Qt raster engine enabled?

Anyways, here comes my .fonts.conf:

<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
 <match target="font">
  <edit mode="assign" name="rgba">
   <const>rgb</const>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="hinting">
   <bool>true</bool>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="hintstyle">
   <const>hintmedium</const>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="lcdfilter">
   <const>lcddefault</const>
  </edit>
 </match>
 <match target="font">
  <test compare="not_eq" name="slant" qual="any">
   <const>roman</const>
  </test>
  <test compare="less" name="weight">
   <const>medium</const>
  </test>
  <edit mode="assign" name="hintstyle">
   <const>hintslight</const>
  </edit>
 </match>
 <match target="font">
  <test compare="more_eq" name="size" qual="any">
   <double>14</double>
  </test>
  <edit mode="assign" name="hintstyle">
   <const>hintslight</const>
  </edit>
 </match>
 <match target="font">
  <test compare="more_eq" name="pixelsize" qual="any">
   <double>16</double>
  </test>
  <edit mode="assign" name="hintstyle">
   <const>hintslight</const>
  </edit>
 </match>
 <dir>~/.fonts</dir>
 <match target="font">
  <edit mode="assign" name="antialias">
   <bool>true</bool>
  </edit>
 </match>
</fontconfig>
Comment 13 Myriam Schweingruber 2011-06-04 12:16:10 UTC
This is an automated message from the triager:

Amarok 2.4.1 has been released on May 8 already. Could you please upgrade and test if you can still reproduce this bug?

Without feedback within a month we will close this bug as resolved.

Thank you for your understanding.
Comment 14 micu 2011-06-14 10:29:14 UTC
(In reply to comment #13)
> This is an automated message from the triager:


I am very sorry, but this still happens with Amarok version 2.4.1 (@KDE 4.6.3).
Comment 15 Myriam Schweingruber 2011-06-14 19:02:48 UTC
Thank you for the feedback.
Comment 16 Thomas Frenzel 2012-01-19 18:10:52 UTC
I hit this bug in 2.5.0. As a workaround I changed the OSD text color in Amarok settings to something (black in my case) that made the shadow color appear very similar to the OSD background color (whitish). The bug still occurs, but it's not that noticeable as before. So for someone willing to debug this, I suggest setting the OSD text color to the background color, so the thick shadow will be visible clearly.
Comment 17 Adria 2012-06-25 20:36:30 UTC
Hi, I am on latest 2.5-GIT and still have the same issue.

It happens always setting the font scale from 110% to 121%, both included.

Can you reproduce it?
Comment 18 Mayank Madan 2012-11-30 09:37:26 UTC
Cannot reproduce it in 2.6-git
Comment 19 Myriam Schweingruber 2012-11-30 10:46:01 UTC
(In reply to comment #18)
> Cannot reproduce it in 2.6-git

Still reproducible when changing the font size to 121%, as suggested in the previous comment.
Comment 20 Ralf Engels 2013-02-02 11:23:30 UTC
I think I know the reason.
It happens in cases when the shadow text (which is a little bit larger) get's linebreaks at different positions than the normal text.

I have no idea how this could be easily fixed.
Comment 21 Ralf Engels 2013-02-03 19:18:39 UTC
*** Bug 260370 has been marked as a duplicate of this bug. ***
Comment 22 Ralf Engels 2013-02-03 21:30:53 UTC
Git commit 6f0eada9fcc1403eb7416dded9df69a9602dab7a by Ralf Engels.
Committed on 03/02/2013 at 22:06.
Pushed by rengels into branch 'master'.

Fix: OSD sometimes misplaces the font and the font's "shadow"

Make sure that shadow and actual text are exactly painted in the same
way.
FIXED-IN: 2.8

M  +12   -8    src/widgets/Osd.cpp
M  +3    -0    src/widgets/Osd.h

http://commits.kde.org/amarok/6f0eada9fcc1403eb7416dded9df69a9602dab7a
Comment 23 Mark Kretschmann 2013-03-02 22:17:46 UTC
Git commit 93d422211ac1a5e218db21936163c6eba0cc7a02 by Mark Kretschmann.
Committed on 02/03/2013 at 23:01.
Pushed by markey into branch 'master'.

Fix shadow rendering in On-Screen-Display.

The shadow was sometimes rendered in the wrong place. This happened
due to word wrap, which got triggered because the shadow text is a bit larger
than the regular text.

M  +3    -3    src/widgets/Osd.cpp

http://commits.kde.org/amarok/93d422211ac1a5e218db21936163c6eba0cc7a02