Print/Print Preview

Print/Print Preview

Post by Kendall Schmid » Mon, 24 Nov 1997 04:00:00



I am trying to use Print Preview in an MFC app to display a graphic image
(drawn via GDI calls). The image is being drawn correctly but it is _very_
small (the problem).

What do I need to do to get the image to fill the print preview sheet?

I suspect that I have to do some type of conversion from screen resolution
to printer resolution before drawning the image in preview (as well as
print) mode.

Kendall Schmidt

 
 
 

Print/Print Preview

Post by Bert Edin » Tue, 25 Nov 1997 04:00:00


Change the mapping mode, use DPtoLP conversion.
Look at the scribble tutorial supplied with VC, enlarge the printed image.
For better understanding, buy the book "Programming Windows 95 with MFC"
from Jeff Prosise,
microsoft press, it is like "Petzold for MFC"

Good luck,
Bert Eding
.


>I am trying to use Print Preview in an MFC app to display a graphic image
>(drawn via GDI calls). The image is being drawn correctly but it is _very_
>small (the problem).

>What do I need to do to get the image to fill the print preview sheet?

>I suspect that I have to do some type of conversion from screen resolution
>to printer resolution before drawning the image in preview (as well as
>print) mode.

>Kendall Schmidt



 
 
 

1. Printing / Print Preview problems

Hi All,
   I'm having a couple printing problems.

   The first is a general question: why does using Regions to set the
clipping region seem to cause major problems? These include confusing
the MFC Print Preview architecture, and more importantly, causing a loss
of GDI Resources (which are not lost by the same code when drawing
to the screen).

   The second problem concerns Print Preview. My drawing is large
enough to require logical coordinates > 32K, which are too large to
use in calls to SetViewportOrg and IntersectClipRgn. My solution has
been to use OffsetViewportOrg and OffsetClipRgn repeatedly until the
values are < 32K. This seems to work when printing, but not when
Previewing. For instance, if I Offset the clipping region down 5K,
the top 1/3 of the page shows empty, and it will draw below the bottom
of the page.

   Does anyone have any info/answers to these problems? Any and all help
is greatly appreciated.


2. Lynx/Pine Wish List

3. HELP!!!! MFC PRINT/PRINT PREVIEW

4. Sendmail hangs under HP-UX 10.10

5. Print/Print Preview

6. Milan

7. print/print preview for bitmaps

8. How OpenGl calcs light?

9. Rich Edit Control Printing Problem (like the print preview problem)

10. Automated RTF printing & non-editable print preview

11. Printing and Print Preview discrepency

12. Print and Print Preview

13. Print and print preview problem (ASSERT error when allocating GDI font resource in OnBeginPrinting)