|
|
17e065 |
diff -up enscript-1.6.5.1/lib/simple.hdr.wrap_header enscript-1.6.5.1/lib/simple.hdr
|
|
|
17e065 |
--- enscript-1.6.5.1/lib/simple.hdr.wrap_header 2009-01-24 21:59:34.000000000 +0100
|
|
|
17e065 |
+++ enscript-1.6.5.1/lib/simple.hdr 2010-05-21 13:04:28.070346832 +0200
|
|
|
17e065 |
@@ -3,6 +3,10 @@
|
|
|
17e065 |
% Copyright (c) 1995 Markku Rossi.
|
|
|
17e065 |
% Author: Markku Rossi <mtr@iki.fi>
|
|
|
17e065 |
%
|
|
|
17e065 |
+% Modified: Chris Josefy, USA, MAY 2006
|
|
|
17e065 |
+% + Added line wrapping to header to work more like AIX enscript
|
|
|
17e065 |
+% + This assumes that one does not change the header font size from the default
|
|
|
17e065 |
+% + This also assumes that the line only wraps once
|
|
|
17e065 |
|
|
|
17e065 |
%
|
|
|
17e065 |
% This file is part of GNU Enscript.
|
|
|
17e065 |
@@ -24,6 +28,7 @@
|
|
|
17e065 |
% -- code follows this line --
|
|
|
17e065 |
%Format: fmodstr $D{%a %b %d %H:%M:%S %Y}
|
|
|
17e065 |
%Format: pagenumstr $V$%
|
|
|
17e065 |
+%HeaderHeight: 44
|
|
|
17e065 |
|
|
|
17e065 |
/do_header { % print default simple header
|
|
|
17e065 |
gsave
|
|
|
17e065 |
@@ -39,10 +44,23 @@
|
|
|
17e065 |
d_header_w user_header_right_str stringwidth pop sub 5 sub
|
|
|
17e065 |
0 moveto user_header_right_str show
|
|
|
17e065 |
} {
|
|
|
17e065 |
- 5 0 moveto fname show
|
|
|
17e065 |
- 45 0 rmoveto fmodstr show
|
|
|
17e065 |
- 45 0 rmoveto pagenumstr show
|
|
|
17e065 |
- } ifelse
|
|
|
17e065 |
+ fname length fmodstr length add pagenumstr length add 95 6 idiv add d_header_w 6 idiv le{
|
|
|
17e065 |
+ 5 0 moveto fname show
|
|
|
17e065 |
+ 45 0 rmoveto fmodstr show
|
|
|
17e065 |
+ 45 0 rmoveto pagenumstr show
|
|
|
17e065 |
+ } {
|
|
|
17e065 |
+ 5 0 moveto fmodstr show
|
|
|
17e065 |
+ 45 0 rmoveto pagenumstr show
|
|
|
17e065 |
+ fname length d_header_w 6 idiv idiv 1 add 10 mul 5 exch moveto
|
|
|
17e065 |
+ 1 1 fname length d_header_w 6 idiv idiv
|
|
|
17e065 |
+ {
|
|
|
17e065 |
+ dup fname exch 1 sub d_header_w 6 idiv mul d_header_w 6 idiv getinterval show
|
|
|
17e065 |
+ 5 exch 10 mul fname length d_header_w 6 idiv idiv 1 add 10 mul exch sub moveto
|
|
|
17e065 |
+ } for
|
|
|
17e065 |
+ 5 10 moveto
|
|
|
17e065 |
+ fname fname length d_header_w 6 idiv idiv d_header_w 6 idiv mul dup fname length exch sub getinterval show
|
|
|
17e065 |
+ }ifelse
|
|
|
17e065 |
+ }ifelse
|
|
|
17e065 |
|
|
|
17e065 |
grestore
|
|
|
17e065 |
} def
|