Fit Width

PDF-XChange Drivers API (only) V4/V5
This Forum is for the use of Software Developers requiring help and assistance for Tracker Software's PDF-XChange Printer Drivers SDK (only) - VERSION 4 & 5 - Please use the PDF-Tools SDK Forum for Library DLL assistance.

Moderators: TrackerSupp-Daniel, Tracker Support, Vasyl-Tracker Dev Team, Sean - Tracker, Chris - Tracker Supp, Tracker Supp-Stefan

Post Reply
norbertjurkiewicz84
User
Posts: 10
Joined: Tue Oct 19, 2010 4:04 pm

Fit Width

Post by norbertjurkiewicz84 » Mon Mar 07, 2011 11:14 pm

How can I get the driver to scale the data to fit within the width of the page size?

User avatar
Tracker Supp-Stefan
Site Admin
Posts: 14159
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: Fit Width

Post by Tracker Supp-Stefan » Tue Mar 08, 2011 1:04 pm

Hello norbertjurkiewicz84,

You can specify the Page size in the driver (or let it set it as needed based on what the application that sends the print information needs), but the scaling, and what will be passed to the driver for printing is up to the application starting the print process.

Best,
Stefan

norbertjurkiewicz84
User
Posts: 10
Joined: Tue Oct 19, 2010 4:04 pm

Re: Fit Width

Post by norbertjurkiewicz84 » Tue Mar 08, 2011 2:13 pm

Is there a way to rescale a printed document page using the PDF Tools?

User avatar
Tracker Supp-Stefan
Site Admin
Posts: 14159
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: Fit Width

Post by Tracker Supp-Stefan » Tue Mar 08, 2011 3:07 pm

Hello norbertjurkiewicz84,

As far as I am aware - nope.
You will need to pass the contents to our printing driver and tell the printing application to "Fit Printer Margins", and then set up the desired page size in the drivers.

Best,
Stefan

norbertjurkiewicz84
User
Posts: 10
Joined: Tue Oct 19, 2010 4:04 pm

Re: Fit Width

Post by norbertjurkiewicz84 » Fri Mar 18, 2011 7:49 pm

Is this something that will be implemented. Most PDF Printers and printer drivers have a scaling option that will take a page that was sent and scale it to a user specified percentage of the original before placing it on the canvas? For example, check out primo.

I saw that there is a scaling option but it doesn't scale the whole input that was sent to the printer but the already cutoff data.

What happens to the text that gets cut off the page? Is it lost?


Thanks.

norbertjurkiewicz84
User
Posts: 10
Joined: Tue Oct 19, 2010 4:04 pm

Re: Fit Width

Post by norbertjurkiewicz84 » Fri Mar 18, 2011 8:41 pm

Playing around with the print driver property page, I found that if I adjust the Page Size to something larger than the standard 8.5 by 11 I can get my contents to get completely placed on the page. Changing the sheet size does not affect this.

Is there a way to adjust the Page Size setting via the COM object. So far I can only adjust the SheetSize.

Ivan - Tracker Software
Site Admin
Posts: 3630
Joined: Thu Jul 08, 2004 10:36 pm
Location: Vancouver Island - Canada
Contact:

Re: Fit Width

Post by Ivan - Tracker Software » Mon Mar 21, 2011 11:51 pm

Yes, there is such a way - as yet undocumented.

To set the paper size you have to set it's index to "DevMode.PapSize" option:

Code: Select all

printer->Option["DevMode.PapSize"] = 9; // to setup A4 as paper size.
if you wish to set a custom paper size you have to use the following code:

Code: Select all

printer->Option["DevMode.PapSize"] = 256; // to use custom paper size
printer->Option["DevMode.CWidth"] = pwidth; // width of the page in tenths of millimeters
printer->Option["DevMode.CHeight"] = pheight; // height of the page in tenths of millimeters
To specify page orientation, use

Code: Select all

printer->Option["DevMode.Orientation"] = 1; // 1 for portrait, 2 for landscape
Please note, to take effect, you have to call printer->ApplyOptions(0).

Hope that helps
Tracker Software (Project Director)

When attaching files to any message - please ensure they are archived and posted as a .ZIP, .RAR or .7z format - or they will not be posted - thanks.

Post Reply