% SLang Script to control PDF generation, do a 2 page on one % Feed in pages: TEMPLATE PAGE1 TEMPLATE PAGE2 TEMPLATE PAGE3 ... % more S-Lang info can be found at http://www.s-lang.org % FYI: setupPage ( float translate_x, float translate_y, float rotate, float scale_x, float scale_y, int keepOnSamePage ) define pdf_page_setup(pagenum) { variable onSamePage; % first find out which setup to apply onSamePage = pagenum mod 2; if (onSamePage == 0) { setupPage(0,0,0.0,1.0,1.0,1); } else { setupPage(0,0,0.0,1.0,1.0,0); } setAnnotationPageDivider(2); % as we put 2 page on one to correct the annotations targets } % no annotations for this run define action_pdfmark(s,n) { }