[Okular-devel] [PATCH] Fix rendering of DVI documents

Albert Astals Cid aacid at kde.org
Tue Oct 6 18:49:36 CEST 2009


A Dimarts, 6 d'octubre de 2009, Pino Toscano va escriure:
> Hi,
> 
> > I noticed that the rendering of DVI documents was broken exactly in
> > the same way as what I observed with PDF documents, namely, it used
> > auto-hinting which looks especially bad with TeX fonts.
> 
> (Arguable.)
> 
> > Attached is a 1-line patch that changes it. I need your permission to
> >  commit.
> 
> I'd object, see below.
> 
> > Third, the old KDVI used to not do any hinting, I'm completely sure of
> > that because I've spent hundreds of hours looking at documents in it.
> > I remember distinctly the (imho beautiful) slightly fuzzy look of the
> > TeX fonts in it, that is characteristic of non-hinted text, although
> > at that time I didn't know about hinting. That said, I used "svn
> > annotate" to see who enabled hinting in the C++ code, and it turns out
> > to be Stefan Kebekus himself in an old revision (240000-something). I
> > am puzzled about that, but I still maintain that KDVI didn't use
> > hinting on all the Linux systems that I tried. My best guess is that
> > Stefan Kebekus _thought_ that he had enabled hinting but for some
> > reason it wasn't used. I haven't investigated further as this is quite
> > intricate, and of course I only have Okular's code at hand, I haven't
> > looked at the actual KDVI code.
> 
> Given the code used by Okular to render DVI documents is taken from KDVI,
>  and (you say) that they render differently, then what I would prefer is to
>  find out what are the real changes in that regard, as opposed to change
>  values on personal liking.
> 

You are late and wrong ;-)

Late because i already commited a patch that fixes it.

Wrong because our port is incomplete, as you can see kdvi_multipage.cpp 
called[1] DVIRenderer.setPrefs that called[2] font_pool.setParameters to set 
if using hinting or not and the default was not using it[3]

Did i convice you?

Welcome to the land of the internet connected :-)

Albert

[1] http://lxr.kde.org/source/KDE/kdegraphics/kdvi/kdvi_multipage.cpp?v=3.5-
branch#225
[2] http://lxr.kde.org/source/KDE/kdegraphics/kdvi/dviRenderer.cpp?v=3.5-
branch#133
[3] 
http://websvn.kde.org/branches/KDE/3.5/kdegraphics/kdvi/kdvi.kcfg?revision=438982&view=markup


More information about the Okular-devel mailing list