Thank you; you should put this on a wiki or a blog somewhere. If you don&#39;t have time, I would gladly do that for you (and of course put your name on it.) This is some really good writing, and I really appreciate the work. It&#39;s easy to lose track of historical context amongst all of the ones and zeros.<div>
<br></div><div>Thank you.</div><div><br><div class="gmail_quote">On Sun, Aug 30, 2009 at 3:43 AM, K. K. Subramaniam <span dir="ltr">&lt;<a href="mailto:subbukk@gmail.com">subbukk@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">On Saturday 29 Aug 2009 8:48:18 pm Juan Vuletich wrote:<br>
&gt; I&#39;ll have time for this on Monday. I guess the first thing to do is to<br>
&gt; understand what is the correct font for &#39;12 point&#39;. I mean, the correct<br>
&gt; ascent/descent and line grid, and the correct shape of the glyphs. Some<br>
&gt; specification of mean kerning / length of strings would be nice too.<br>
</div>In traditional typography, the point referred to the size of the metal block<br>
used to carve shapes (glyphs).  The size of a Point depended on<br>
regional/political affiliations :-). Anglo-american point was about 72.27 points<br>
to an inch. Not all shapes would be contained within its metal block base.<br>
Some (see g in the picture <a href="http://ilovetypography.com/2008/03/23/sunday-type-
bright-type/" target="_blank">http://ilovetypography.com/2008/03/23/sunday-type-<br>
bright-type/</a>) would also extend (kern) beyond its base. String length would be<br>
the sum of metal block widths. The sum of shape widths in a run of characters<br>
could differ from the string length due to kerns.<br>
<br>
Digital typography uses co-ordinate grids instead of a metal block. It defines<br>
Point (aka DTP point or Postscript point) as 1/72th of an inch. Grid size<br>
varies for different fonts. TTF uses grids of 512, 1024 or 2048. The point size<br>
used in font names are &#39;design size&#39;. i.e. a modern 12pt TTF contains glyphs<br>
drawn inside a 2048x2048 grid that will *look like* a 12pt metal typeface when<br>
scaled to various digital canvases like a 96dpi screen or 1200 dpi printer.<br>
<br>
Though we continue using the term &#39;glyph&#39; (carving), images are computed on<br>
the grid using a &#39;pictal&#39; process and then scaled to the target canvas. A<br>
Truetype font is actually a bytecode program interpreted by a font engine<br>
(e.g. Freetype) to scale glyphs at run time. Internally, glyphs are defined in<br>
terms of lines and curves in a grid (called em-square) of size 512, 1024 or<br>
2048. Given a canvas (dpi, depth), a glyph code and a point size &quot;hint&quot;, the<br>
font engine will scale a glyph and tweak them using &#39;hints&#39; expressed in<br>
bytecodes. For instance, stretching a &#39;(&#39; vertically may scale only the middle<br>
part and leave the tips alone. The o in &quot;xo&quot; will slightly overshoot x for<br>
good visual flow.<br>
<br>
However, aesthetic rendering requires a context and a run of characters. The<br>
spacing between one character to the next is dictated by kern and direction.<br>
Sometimes, adjacent glyphs may coalesce into a more compact or even different<br>
shape (e.g. ffi) called a ligature. Runs are handled by a text rendering engine<br>
(e.g. Pango, Qt, ghostscript). Of course, the ligated glyph shape should exist<br>
in the font.<br>
<br>
Squeak&#39;s text printing algorithms only consider boxes and kerns - no<br>
ligatures, no hyphenation, no direction. Building a true multilingual layout<br>
engine is a non-trivial task. Mac and Wintel have only one shaping engine<br>
while Linux has multiple options (Pango, Qt, ICU, m17n, Graphite). Pango and<br>
Qt are widely used. Squeak should be able detect and load shaping engines on<br>
the fly on Linux or allow command line options to pick a wrapper plugin.<br>
<br>
There is also the blue plane approach proposed in FoNC paper - treat text<br>
boxes like graphic objects. A Font engine is just a specialized vector graphic<br>
editor that avoids intensive geometric computations by caching precomputed<br>
shapes in a glyph table. Allow graphic objects to have class level editors.<br>
Then when a glyph is missing for a character code, open a glyph editor and<br>
allow a new shape to be defined on the fly or imported from a public font<br>
definition file. Beats displaying $?.<br>
<br>
Subbu<br>
<br>
</blockquote></div><br><br clear="all"><br>-- <br>Ron<br>
</div>