pango and gtkmathview

Dear pango community,

this is a sort of follow-up to the "Pando and MathML" mail of Felix
Breuer on February 13 that has got no answer.

I'm considering porting gtkmathview
(, a GTK+ widget for displaying and
interacting with MathML markup) to GTK+2. As part of this effort, I'd
like to take advantage of pango high-level functionalities for text
rendering. Currently I'm using a fairly complex font management system
designed by myself, which is both incomplete and poorly performant.

Before redesigning the system, however, I'd like to  better understand
what are the necessary steps, and if pango can provide all the
functionalities we need. I understand that pango is for displaying
Unicode strings in the most general sense, and in fact MathML documents
are made of Unicode characters. The main aspects that make mathematics
peculiar can be summarize as follows:

(1) in some contexts characters need to be stretched vertically or
horizontally to span a given height or width. The typical examples are
parentheses around expressions, horizontal braces, variable-size accents
like tilde or hat

(2) the occasional need of precise metrics information, such as side
bearings of glyphs, or the italic correction

Although my knowledge of pango is currently very limited, I'd be
surprised to hear that these functionalities, (1) in particular, are
already provided and in fact I'm ready to undertake the development of a
specific pango module that addresses them (although help would be
welcome and highly appreciated). Just I'd like to know if it is at all
possible to fit these functionalities in pango architecture. The only
thing I can think of for (1) is to give attributes to a particular
character saying how much it should stretch, or something similar. Maybe
there is a better approach. As for (2), is there a way to accommodate
extra-metrics requests that do not map on the current pango API?

-- luca

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]