Commit: fonts part 2 & 3


Subject: Commit: fonts part 2 & 3
From: Dom Lachowicz (cinamod@hotmail.com)
Date: Sat Mar 17 2001 - 21:55:55 CST


Implemented parts 2 & 3 of my font changes. This will unfortunately break
non-unix platforms. For now, all you have to do is define 3 methods:

getFontAscent(), getFontDescent(), getFontHeight() all accepting a GR_Font*
argument in your graphics class. The GTK+, PS, and GnomePrint graphics
classes have been taken care of by me. I'll probably also do another
function or 2 here (getting character widths). IMHO, setFont either
shouldn't exist, or should only be used immediately before drawing a text
run.

This actually enables a fair bit of simple caching up the ladder in the Run
classes, so that setFont() doesn't get called all the time. Also cuts down
execution time on the default case (i.e. the previous font is the same as
the last one). There is still *tons* of room for optimization here, and I
plan on working on that in the upcoming week. Abi is too darn slow.
Hopefully this has made it a bit better.

Sorry for breaking your builds guys. At least this will prove once and for
all if the QNX tinderbox can turn red or now. (I've had a sneaking suspicion
that it can't :^)

Dom

CVS:----------------------------------------------------------------------
CVS: Enter Log. Lines beginning with `CVS:' are removed automatically
CVS:
CVS: Committing in .
CVS:
CVS: Modified Files:
CVS: src/af/gr/unix/gr_UnixGraphics.cpp
CVS: src/af/gr/unix/gr_UnixGraphics.h src/af/gr/xp/gr_Graphics.cpp
CVS: src/af/gr/xp/gr_Graphics.h
CVS: src/af/xap/unix/xap_UnixPSGraphics.cpp
CVS: src/af/xap/unix/xap_UnixPSGraphics.h
CVS: src/af/xap/unix/gnome/xap_UnixGnomePrintGraphics.cpp
CVS: src/af/xap/unix/gnome/xap_UnixGnomePrintGraphics.h
CVS: src/text/fmt/xp/fp_FmtMarkRun.cpp src/text/fmt/xp/fp_Run.cpp
CVS: src/text/fmt/xp/fp_Run.h src/text/fmt/xp/fp_TextRun.cpp
CVS: src/text/fmt/xp/fp_TextRun.h
CVS: ----------------------------------------------------------------------

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com



This archive was generated by hypermail 2b25 : Sat Mar 17 2001 - 21:56:03 CST