Vincent van Ravesteijn - TNW schrieb:
Is there a way to access the metrics?
1. You can store all the asc en desc of the cells in CellData. This can
be done in InsetTabular::metrics. This is now also done for the rows.
(cell_info[row][col].asc = ...).
2. Or, maybe you can call something like this:
text_ = cellInset(cell)->text();
TextMetrics & tm = pi.base.bv->textMetrics(&text_);
I'll try both.
p.s. I still don't understand how exactly dim.asc is calculated. Where
in the code is this done?
Well. Have a look in the code then :S ?
Well, that's the point. I did this intensively several times but the
tabular code simply miss any comment. MSCV comes with a beautiful search
engine but when it comes to search more than one file I have to use a
desktop search. But even this brings often no results.
LyX's sourcecode needs much more comments. Especially the metrics and
drawing business is nowhere documented. (This is not your fault, just a
comment to "release some steam", as we say in Germany.)
InsetTabular::metrics() calls InsetText::metrics() which calls
TextMetrics::metrics() which calls ParagraphMetrics::ascent()...
Thanks for the hint.
regards Uwe