Здравствуйте, Hippopotamus, Вы писали:
H>хотел уменьшить размер шрифта static-элемента диалога
H>не получилось
Из описания CreateFont():
nHeight
[in] Specifies the height, in logical units, of the font's character cell or character. The character height value (also known as the em height) is the character cell height value minus the internal-leading value. The font mapper interprets the value specified in nHeight in the following manner.
> 0 The font mapper transforms this value into device units and matches it against the cell height of the available fonts.
0 The font mapper uses a default height value when it searches for a match.
< 0 The font mapper transforms this value into device units and matches its absolute value against the character height of the available fonts.
For all height comparisons, the font mapper looks for the largest font that does not exceed the requested size.
This mapping occurs when the font is used for the first time.
For the MM_TEXT mapping mode, you can use the following formula to specify a height for a font with a specified point size:
nHeight = -MulDiv(PointSize, GetDeviceCaps(hDC, LOGPIXELSY), 72);
Все вышепроцитированное учитываете?
Здравствуйте, v_a_n_e_k, Вы писали:
___>Попробуй поставить вместо шрифта "MS Sans Serif" шрифт "Microsoft Sans Serif", т.к. последний TrueType
Изменение шрифта на TrueType помогло.
Покапал еще в этом направлении и получилось:
"растерные шрифты масштабируются только в сторону увеличения"
из MSDN:
For example, when using raster fonts...If the logical font has a height of 8 and there is no font shorter than 10, the font with a height of 10 is chosen.
A raster font is sometimes also called a bitmap font, because each character is stored as a bitmap pixel pattern. Each raster font is designed for a specific aspect ratio and character size. Windows can create larger character sizes from GDI raster fonts by simply duplicating rows or columns of pixels. However, this can be done in integral multiples only and within certain limits. For this reason, GDI raster fonts are termed "nonscalable" fonts. They cannot be expanded or compressed to an arbitrary size
Спасибо.