Patch level : 10.0 180
Files correlati : xvaga.dll Ricompilazione Demo : [ ] Commento : Corretto calcolo altezza font in stampa (carta e PDF) git-svn-id: svn://10.65.10.50/trunk@17740 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
4cd7b952fd
commit
c98f915426
@ -1635,8 +1635,17 @@ XVT_FNTID xvt_dwin_get_font(WINDOW win)
|
||||
|
||||
void xvt_dwin_get_font_metrics(WINDOW win, int *leadingp, int *ascentp, int *descentp)
|
||||
{
|
||||
CAST_TDC(win, dc);
|
||||
xvt_font_get_metrics(&dc._font, leadingp, ascentp, descentp);
|
||||
// Attenzione: non funziona la chiamate in cascata a xvt_font_get_metrics
|
||||
CAST_DC(win, dc);
|
||||
const wxString str = "Mq";
|
||||
int height, desc, lead;
|
||||
dc.GetTextExtent(str, NULL, &height, &desc, &lead);
|
||||
if (leadingp)
|
||||
*leadingp = lead;
|
||||
if (ascentp)
|
||||
*ascentp = height-lead-desc;
|
||||
if (descentp)
|
||||
*descentp = desc;
|
||||
}
|
||||
|
||||
long xvt_dwin_get_font_size_mapped(WINDOW win)
|
||||
|
Loading…
x
Reference in New Issue
Block a user