 |
C++Talk.NET C++ language newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Alex Chervinsky Guest
|
Posted: Wed Oct 29, 2003 2:52 pm Post subject: Printing with the given font |
|
|
Hello everybody!
I am using VC++6.0.
I want to print a text with the font OCRB, and with the symbol size
2.7 mm Height and 2.5 mm width. I use :
// 100 log units per mm for HIMETRIC mapping mode :
#define UNITS_IN_MM 100
...
strcpy(logFont.lfFaceName, "OCRB");
logFont.lfHeight = (int)( 2.7 * UNITS_IN_MM ); // =270
logFont.lfWidth = (int)( 2.54 * UNITS_IN_MM ); // =254
logFont.lfWeight = FW_NORMAL;
CFont* pFont = new CFont();
pFont->CreateFontIndirect(&logFont);
CFont* oldFont = pPrintDC->SelectObject(pFont);
...
When it have printed a text, I made the measuring. The text is wide
exactly as I set it - 25 mm for 10 symbols, but its height is only
about 2.2 mm
Then I try to set the lfHeight to 300 or even to 320, but the real
size does not change 8-|
How to set correct size ? Or which values have I to set exactly in
this case ?
Any information is greatly appreciated!
Best wishes!
|
|
| Back to top |
|
 |
Victor Bazarov Guest
|
Posted: Wed Oct 29, 2003 4:18 pm Post subject: Re: Printing with the given font |
|
|
"Alex Chervinsky" <sashko1 (AT) svitonline (DOT) com> wrote...
| Quote: | I am using VC++6.0.
I want to print a text with the font OCRB, and with the symbol size
2.7 mm Height and 2.5 mm width. I use :
// 100 log units per mm for HIMETRIC mapping mode :
[...] |
Wrong newsgroup. Please go to microsoft.public.vc.language or
comp.os.ms-windows.programmer.
Victor
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|