open printing with dialog -- Windows equiv?

J. Landman Gay jacque at hyperactivesw.com
Thu Dec 23 14:43:34 EST 2004


On 12/22/04 3:27 PM, Frank D. Engel, Jr. wrote:

> The biggest issue (perhaps the only one left) with XP printing is that 
> text at the right edge of a field does not print.  In other words, the 
> field is x units wide, Rev allows the line of text to be x+y units wide, 
> and the extra y pixels get cut off instead of wrapped.  The field is 
> multiline and other lines below that one do exist.
> 
> In W2K (the real manifestation of what some people thought Y2K would be 
> ... though an overall improvement over its predecessors, I think), the 
> printouts show extra blank lines in the middle of a field, some lines 
> wrap prematurely after a word or two, and so forth.

I spent 2 days of unbillable time trying to get a decent printout from a 
Windows box. I never could get it quite right.

The problem you are describing is due to the differences between Windows 
printing fonts and display fonts. For some unfathomable reason, MS 
decided to give printing fonts different metrics than the equivalent 
display font (printing fonts are generally larger) so that when you 
print, the edges of the field cut off the ends of the lines.

In my stack, after days of messing with formatForPrinting (turn it off, 
turn it on, open, close, twiddle twiddle,) I finally just left 
formatForPrinting set to false permanently, and used MS Sans Serif as 
the printing field font -- this font seems to pretty much match its own 
screen metrics and printed okay. Or maybe I set the printing field one 
font size smaller than what I was aiming for; I can't remember now.

This printing business on Windows really needs an overhaul. You might 
want to look at the revPrintField script as it does overcome some of the 
problems. If it is possible for you to pass your data field to that 
library handler, it might be easier in the long run.

-- 
Jacqueline Landman Gay         |     jacque at hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com


More information about the use-livecode mailing list