RE: Pages per Sheet setting for open printing to pdf

2011-12-16 Thread gmcrev

Thanks for the reply Jacquelin.
However I was using revPrintText to print HtmlText via open printing to pdf.
I would like to pdf print the equivalent of 2 A4 pages on 1 A4 sheet.
Any ideas how this would work?

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Pages per Sheet setting for open printing to pdf

2011-12-16 Thread J. Landman Gay

On 12/16/11 2:55 AM, gmcrev wrote:

Thanks for the reply Jacquelin.
However I was using revPrintText to print HtmlText via open printing to
pdf.
I would like to pdf print the equivalent of 2 A4 pages on 1 A4 sheet.
Any ideas how this would work?


I haven't done much with that command, but you could try setting the 
printScale to 0.5 before you print. That should scale the output by 
half. It may not give what you want though, since the width of the text 
block may also be half. Experiment.


It's possible to do what you want, but probably not using the rev 
library calls. For custom print output the usual way is to handle the 
entire process yourself. The rev library is convenient for quick 
printouts, but its script just uses commands that are available in the 
engine and which you can use yourself. (The script snippet I posted 
could be easily changed to open printing to pdf, btw.)


I'll readily admit that printing in LiveCode is a pain, but you can do 
just about anything with it if you're willing to script everything. The 
usual method is to create a printing substack that is never shown, but 
serves as a template for printouts. The template contains fields and any 
other objects that need to print. A script opens the template invisibly, 
repeatedly fills the fields with text (or in this case, htmlText,) 
prints the template card, and repeats until printing is finished.


--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Pages per Sheet setting for open printing to pdf

2011-12-15 Thread J. Landman Gay

On 12/15/11 8:28 PM, gmcrev wrote:

I am wondering whether it would be useful to request for a new command
that would set the number of pages per sheet for printing.
ie. 2 A4 pages would be reduced and printed on 1 A4 page. I can't seem
to find any livecode commands to do this.


You can use the into rect form of the print command:

print this card into l,r,t,b -- put some pixel numbers there

Printing into a specified rectangle automatically scales the card image 
to fit. You'd need to calculate the rectangles that encompass the top 
half and the bottom half. Then open printing, print one card into the 
top rect, the second card into the bottom rect, then print a break. The 
break forces a new page. Pseudo-sorta-code:


put 18,18,594,374 into tTopRect
put 18,380,594,752 into tBottomRect
open printing -- with dialog, if you want
print card 1 into tTopRect
print card 2 into tBottomRect
print break
-- repeat that for each pair of cards
close printing

--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode