From 8e8a3c56c650746d4a72d6cab5f313c8040cbd18 Mon Sep 17 00:00:00 2001 From: Werner Almesberger Date: Tue, 17 Apr 2012 08:05:11 -0300 Subject: [PATCH] genex/pdf.c: changed page orientation from landscape to portrait Most components are taller than wider. --- genex/pdf.c | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/genex/pdf.c b/genex/pdf.c index 884900f..17f3ba5 100644 --- a/genex/pdf.c +++ b/genex/pdf.c @@ -29,7 +29,7 @@ static struct format { int y; } name, path, lib, comment; int comment_line_skip; -} format = { +} landscape = { .file_setup = "", .overlay_setup = "90 rotate", .comp_setup = "", @@ -39,7 +39,17 @@ static struct format { .lib = { "Courier", 12, 75 }, .comment = { "Helvetica", 12, 600 }, .comment_line_skip = 14, -}; +}, portrait = { + .file_setup = "%%Orientation: Portrait", + .overlay_setup = "0 790 translate", + .comp_setup = "-120 700 translate -90 rotate", + .left = 20, + .name = { "Helvetica-Bold", 24, 57 }, + .path = { "Helvetica-Bold", 18, 30 }, + .lib = { "Courier", 12, 75 }, + .comment = { "Helvetica", 12, 740 }, + .comment_line_skip = 14, +}, format; static int children(const struct node *node) @@ -206,6 +216,10 @@ void make_pdf(void) FILE *out; int res; + if (0) + format = landscape; + else + format = portrait; #if 0 out = popen( "gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=- -f -",