Development Topics > GDI Printing > GDI Printing Directives

XORIGIN, YORIGIN

Reviewed January 2011

//XORIGIN, ###

//YORIGIN, ###

These commands define the minimum offset from the top left physical corner of the paper to the 0,0 print position (in twips—--i.e., 1440 per inch).

A-Shell and APEX will operate on the LARGER of the (a) XORIGIN,YORIGIN values and (b) the physical margin as defined by the printer driver. So in other words, if you set them each to 360, you should get at least 1/4" top/left margin, even on printers (like some image printers, PDF printers, and even APEX itself) that don't have any built-in physical margin limitation. This can be very useful in reducing the alignment fluctuations between different printer models caused by differing hardware paper margins.

XORIGIN and YORIGIN must appear within the top eight lines of a printfile and before any printable text. Both XORIGIN and YORIGIN have a Printer Init File Equivalent.

 

History

2011 January, A-Shell build 1202: Added to GDI Printing Directives.