Saturday, June 18, 2011

Re: Font Rendering Issues on Linux But Not Windows

Hi Tony,

On Sat, 18 Jun 2011 09:11 +0200, "Tony Mechelynck"
<antoine.mechelynck@gmail.com> wrote:
> On 17/06/11 22:02, Mathew Brown wrote:
> > Hi Tony,
> >
> > Thanks for your reply. To make sure that I'm using the exact same
> > fonts, I copied the ttf fonts used by Windows and replaced the ones on
> > Linux and then proceeded with running fc-cache. I'm still running
> > into the same problem. So why is it still working on Windows and not
> > on Linux although it is the exact same font? The only difference is
> > that I have the cDEFAULT option under Windows. Any other suggestions?
> > Thanks.
>
> Well, another difference (sometime we fail to see the most obvious) is
> that on Windows you're using a gvim with Windows GUI while on Linux
> you're using (IIUC) a gvim with GTK2 GUI. There are quite a lot of
> differences in how fonts are handled by Windows and by GTK2, and most of
> them are not in Vim code.
>
> There may or may not be other differences in your vimrc, and even if
> there aren't, some options have different defaults on both platforms.
>
> When viewing pointed Arabic text in GTK2 gvim, I don't always see it
> displayed correctly; moving the cursor over the text may correct the
> error.

This is the exact issue that I have. I also had this issue on Windows.
But as soon as I set cDEFAULT on Windows, the problem disappeared.
But moving the cursor over the text really isn't a very nice solution.
I've found that some fonts such as Courier New 12 render the Arabic
text properly without any display issues, but the font itself isn't
very pleasing or easy to read (at least the Arabic version). I'm
trying to find a solution. As a temporary work around, is there any
way that you can get the same effect as moving the cursor over the
letters again to make them display properly but without having to do
this manually? I mean is there any way to trigger this same behavior
in an easier way? Thanks.

> Could you post somewhere a screenshot of a single file as seen in your
> Windows gvim and your GTK2 gvim? For comparison, I've uploaded the
> following files to the hosting space offered by my ISP:
>
> - a simple unpointed Arabic example:
> http://users.skynet.be/antoine.mechelynck/other/salaam.txt
> http://users.skynet.be/antoine.mechelynck/other/salaam.png
>
> - the same text, but pointed, after running the cursor over every letter
> of the text in turn:
> http://users.skynet.be/antoine.mechelynck/other/salaam-rahma.txt
> http://users.skynet.be/antoine.mechelynck/other/salaam-rahma.png
>
> These screenshots were taken in gvim with GTK2, with (of course)
> 'arabic' set, and otherwise my usual vimrc, which, among others, includes
> set gfn=Bitstream\ Vera\ Sans\ Mono\ 8
>
> which is a font similar to DejaVu Sans Mono, but slightly more pleasing
> to my eye, and 20% smaller than what you use. (The Pilcrow mark is what
> I use to indicate EOL, using the 'list' and 'listchars' options.)
>
> When looking at the pointed example in SeaMonkey, which also uses GTK2,
> I notice (in the word "Allah") that the alef-wasla is borrowed from a
> different font and that the superscript-alef is left of where it ought
> to be, making the lam and heh disjoint. It looks like GTK2 has a hard
> time displaying composing characters correctly (the superscript-alef is
> a "second composing character" in a group made of lam, shadda,
> superscript-alef)
>
> السلام عليكم ورحمة الله وبركاته
> Tony.
> --
> Aquadextrous, adj.:
> Possessing the ability to turn the bathtub faucet on and off
> with your toes.
> -- Rich Hall, "Sniglets"
>
--
Mathew Brown
mathewbrown@fastmail.fm

--
http://www.fastmail.fm - The way an email service should be

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: