Issue 25565 - fontspacing broken for Lucidasans when typing arabic
Summary: fontspacing broken for Lucidasans when typing arabic
Status: CLOSED DUPLICATE of issue 28576
Alias: None
Product: gsl
Classification: Code
Component: code (show other issues)
Version: 680m24
Hardware: All Linux, all
: P3 Trivial with 5 votes (vote)
Target Milestone: OOo 2.0
Assignee: hdu@apache.org
QA Contact: issues@gsl
URL:
Keywords:
Depends on:
Blocks: 27689
  Show dependency tree
 
Reported: 2004-02-16 17:34 UTC by ulf.stroehler
Modified: 2004-08-16 16:14 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description ulf.stroehler 2004-02-16 17:34:14 UTC
In src680_m23 or higher the fontspacing for Lucidasans is broken when typing arabic
For typing arabic use the following command.
(setxkbmap -rules xfree86 -layout de,ar -option grp:alt_shift_toggle)

Evaluation:
The problem seems to be related to also on the system (RH9 Shrike) available
XFonts with the name Lucidasans. These are font aliases names located in the
following files:
/usr/share/fonts/KOI8-R/75dpi/fonts.alias
/usr/X11R6/libX11/fonts/100dpi/fonts.alias
/usr/X11R6/lib/X11/fonts/75dpi/fonts.alias
Comment 1 hdu@apache.org 2004-02-17 11:29:52 UTC
accepting.
Comment 2 christof.pintaske 2004-06-17 17:16:05 UTC
cp: retargeted to Office-Later due to limited ressources
Comment 3 munzirtaha 2004-07-29 11:25:09 UTC
font spacing is broken for all fonts now when typing Arabic. OO.o is now not 
usable to the Arabs! 
 
There are two bugs alreay filed here: 
http://qa.mandrakesoft.com/show_bug.cgi?id=9664 
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=126088 
 
Whether it's freetype or OO.o is responsible this problem doesn't happen in 
kword and other apps. Just on OO.o 
 
This problem is very serious and should be marked as a bloking of 1.1.3. 
 
 
Comment 4 ulf.stroehler 2004-07-30 13:51:46 UTC
This issues seems to be more sever than I thought. Arabic documents are severly
broken. GlyphFallback seems to be not working.
Retargetting for OO.o 2.0 + cloning task for OO.o 1.1.3.
Comment 5 ulf.stroehler 2004-07-30 13:56:38 UTC
Clone of this task generated with Target OO.o 1.1.3 (issue 32353).
Comment 6 ulf.stroehler 2004-07-30 14:01:45 UTC
This issue actually prevents issue 27689 from  closing.
Comment 7 hdu@apache.org 2004-08-02 16:09:32 UTC
Several different problems get mixed up here:
1) when there are multiple versions of LucidaSans on the system and some of them
don't support Arabic this can cause a problem
2) there may be a problem in the libfreetype6-2.1.7-4mdk autohinter ( which
isn't used in libfreetype6-2.1.7-4plf)
3) glyph fallback for X11 fonts is only triggered, when font's XLFD encoding
doesn't support the requested unicodes. Especially *-iso10646-1 fonts are never
trigger glyph fallback.

I think 1) and 3) are the problems US is seeing and 2) is the problem BULBUL has.
HDU->BULBUL: does the problem still show up when you set the environment
variable SAL_AUTOHINTING_PRIORITY to 0 and restart soffice. E.g. put a line
  export SAL_AUTOHINTING_PRIORITY=0
into the soffice script...
Comment 8 ulf.stroehler 2004-08-11 17:38:12 UTC
Regarding #1):
The following workaround works for me:
- add the java provided lucida fonts to fontconfig *)
- additionaly you may remove the b&h lucida bitmap fonts from
/usr/X11R6/lib/X11/fonts/[75;100]dpi (don't forget to run mkfdir afterwards)

*) See http://pdx.freedesktop.org/%7Efontconfig/fontconfig-user.html for a
private user configuration file ".fonts.conf" in $HOME. 
You may want to change line "8" <dir>~/misc/fonts</dir> to a suitable directory
e.g. ~/.gnome2/share/fonts or ~/.kde/share/fonts.
Copy the lucida fonts there an run fc-cache for that directory.
Comment 9 munzirtaha 2004-08-12 07:44:19 UTC
I have set 
export SAL_AUTOHINTING_PRIORITY=0 
into the soffice script and still the same problems of lam-alef ligature and 
the overlapping of the letters. 
 
I would also like to point to something strange here. I installed Mandrake 
10.1beta with OO.o 1.1.2 and the Arabic letters showed properly with no 
overlapping whatever hard I tried them to overlap! ;) 
 
I then installed the arabic build made Mr. Pavel Janik in my Mandrake 10.1beta 
and the same problem shows. Now I have 1.1.2 installed from rpm which doesn't 
show the problem accompanied with to-be 1.1.3 which shows it. How can I help 
you trace it?! 
 
Regarding the multiple lucida fonts, I didn't notice any special problem in 
addition to the letters overlapping or the lam-alef ligature. Still, I tried 
what "us" suggested and nothing changed. 
 
Comment 10 pavel 2004-08-12 09:11:02 UTC
Maybe freetype bug? MDK probably uses system freetype...

Comment 11 munzirtaha 2004-08-13 23:17:39 UTC
Both my OO.o installation use the system freetype by default. 
 
$ ldd /usr/lib/openoffice/program/soffice.bin |grep freetype 
        libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0x417c0000) 
 
$ ldd OpenOffice.org1.1.3/program/soffice.bin |grep freetype 
        libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0x416f0000) 
 
I also removed OpenOffice.org1.1.3/program/filter/libfreetype.so.6 per Mr. 
Pavel Janik suggestion (on IRC) and still nothing changed 
 
If it's the freetype bug why did it affect OO.o 1.1.3 but not 1.1.2 though 
both use the same lib? 
 
The Mandrake rpm that doesn't suffer from this bug is 
OpenOffice.org-1.1.2-4mdk  
Comment 12 munzirtaha 2004-08-14 22:43:54 UTC
After some hours on IRC with Mr. Pavel Janik trying to track it, he was able 
to find the patch that fixed the fixes the issue. The problem turned to be not 
related to freetype at all. The patch was mentioned in 
http://www.openoffice.org/issues/show_bug.cgi?id=28567 
but didn't find its way to the 1.1.3 branch. Pavel now has taken care of it in 
his builds starting from build-9. You can either only download the new 
libvcl645li.so from 
ftp://ftp.linux.cz/pub/localization/OpenOffice.org/devel/1.1.3/build-9/vcllib-arabic/ 
to test. I verified it's working great! It would be nice if someone would 
explain why such a simple, one-line patch haven't been applied to all branches 
and delayed leaving us lost for many months accusing freetype? ;) 
Comment 13 pavel 2004-08-14 22:47:09 UTC
Munzir: it is not (well, it was not, because I crossmerged it) in ooo113fix2.
This doesn't mean that it won't be in 1.1.3. It could be merged in other cws
that is going to be integrated before 1.1.3 is released.

BTW - build-10 is there with the fix already included.
Comment 14 hdu@apache.org 2004-08-16 09:57:08 UTC
Setting status to Duplicate.

It seems that MDK's freetype moved the left edge of a glyph a little bit to the
left, so there was  some glyph overlap and the problem was triggered. The fix
for the "glyph overlap triggered miscalculation" is already in the SRC680
development snapshots (>=m47) and is also nominated for the next release of the
SRX645 branch... Since there were problems with the vclppbugs4 CWS there have
been delays...

*** This issue has been marked as a duplicate of 28567 ***
Comment 15 ulf.stroehler 2004-08-16 10:41:37 UTC
Again this issue needs clarification:

1) the problem munzirtaha and Pavel are discussing in here is actually issue 28567.

2) this one is about the java provided Lucida font family which currently gets
used for OO.o to display CTL text, as there is no commonly available, free CTL
font which suits the needs of OO.o.

The target of this issue is OO.o 2.0 and the Version on which the error was
reported is 680. Hence this one can never be duplicate to issue 27689. => Reopening.

The problem in this task is that 
1) the java provided fonts are not registered with fontconfig
2) although they got found and are registered in OO.o's pspfontcache the X
served Lucida fonts seem to get preferred (IMHO that's the bug HDU has to fix)
Comment 16 hdu@apache.org 2004-08-16 12:02:41 UTC
Ok, this issue is not an exact duplicate of the issue 28567, but to its OOo 2.0
clone (issue 28576 in CWS vcl22, which got integrated into SRC680m47).

The issue reported here by Bulbul and verified by Munzirtaha is indeed fixed by
the fix for issue 28576 == fix for issue 28567). The only indirectly related
problems 1) and 3) I in my comment above are something different (probably issue
27689)

> US: Hence this one can never be duplicate to issue 27689. => Reopening.
HDU: I didn't mark this issue as duplicate to issue 27689, so I don't see your
point :-)
It was marked as duplicate to issue 28576 (==issue 28567) though...

*** This issue has been marked as a duplicate of 28576 ***
Comment 17 ulf.stroehler 2004-08-16 16:14:02 UTC
Hmm, I was pretty sure that the fix for overlapping glyph clusters didn't fix
this one. But I have to admit that after outbacking the above mentioned
workaround I am now no more able to reproduce this issue with current master
workspaces already containing the fix (680_m50). The only issue remainig with
Lucidasans is that Lam Alif and probably different ligatures also produce
'rectangles' (issue 30093).

Closing dupe.