How do i calculate the font so that
text fits in the given rectangle ??
I mean how do i fill the LOGFONT
structure so that text fits into a
given rectangle ?
Text should get resized ...
it should not clipped.
Printable View
How do i calculate the font so that
text fits in the given rectangle ??
I mean how do i fill the LOGFONT
structure so that text fits into a
given rectangle ?
Text should get resized ...
it should not clipped.
Use check the text extent CDC::GetTextExtent() or CDC::GetOutputTextExtent(), setting different font sizes until it fits the available width. You can also use CDC::DrawText to wrap text within a rectangle...
Dave