On 18/07/14 15:56, Charles Campbell wrote:
Tony Mechelynck wrote:
On 17/07/14 21:55, Bram Moolenaar wrote:

Charles Campbell wrote:

The following line, when in a buffer that vim is displaying:

||||m=⎣ℜ(b-a)⎦=1~1026

has the "script R" displayed correctly when the cursor is swept over it
from right to left,
but the "script R" is displayed incorrectly when the cursor is swept
over it from left to right.

I'm using:

Scientific Linux 6.5 (Carbon)
vim 7.4.372
set guifont=Monospace\ Bold\ 12
configure --with-features=huge  --enable-gui=gtk2 --enable-perlinterp
--enable-pythoninterp --enable-cscope

Looks like a problem with the font: the character is wider than the
display cell.  Thus when drawing the character to the right of the
"script R" it erases the rightmost pixels of it.


Reminds me of a problem I've had in the past with a totally different
font, and without doublewidth.

Once upon a time I used Lucida (Lucida Console on Windows, Lucida
Typewriter on Linux: I still used both platforms then); then I noticed
that in bold Cyrillic I had the problem described: sweeping the cursor
over the text made it look wrong when swept in one direction, right
when swept in the opposite direction.

On closer look, the bold Cyrillic glyphs of the Lucida font were
apparently constructed by superimposing the unbold glyphs with a copy
of themselves shifted laterally by one pixel, and thus the bold glyphs
were one pixel wider than the normal-weight glyphs (and than the
declared glyph-width of the font), which gvim "didn't like".

So I found a different font (Bitstream Vera Sans Mono) which doesn't
have this problem, and can AFAICT display Latin and Cyrillic with or
without bold or italic (or, of course, underlined) with no problem.


Dr. Chip, maybe you can find a different font, which has the glyph but
not the problem? It may require some trial and error.
I've been through all the fonts that have "mono" in their names on my
system; each of them has the same problem that Luxi Mono has. Most of
the rest look like they use double-spacing: i e .  t h e y r e s e m b l
e  t h i s; although that does mean that the R shows up completely. I'll
probably just make do with having that R look like an F most of the time.

Thanks!
Chip Campbell


Some monospace fonts don't have "mono" in their names, but something like "console" or "typewriter". Or even "consol" with a different ending.

And as ZyX noted in his post near this point of the thread, when some glyph is not found in the current font, gvim *for GTK2* (and no other gvim flavours) looks for it in other fonts (hopefully of approximately the same size) until it finds one. Firefox and SeaMonkey (which, on Linux, also use GTK2 and Pango) do the same.

See also under ":help guifontwide-gtk2" what Pango/Xft does when the 'guifontwide' option is empty (GTK2 only).

And as noted under ":help E236", in GTK2 (and only in GTK2) you can set 'guifont' to a proportional font, but it will look ugly, with letters like I i l "floating" in a lot of white space, and letters like M m "cramped" like an obese person in a (single) subway seat at rush hour.


Best regards,
Tony.
--
There are more things in heaven and earth,
Horatio, than are dreamt of in your philosophy.
                -- Wm. Shakespeare, "Hamlet"

--
--
You received this message from the "vim_dev" 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

--- You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui