diff options
author | CoprDistGit <infra@openeuler.org> | 2024-08-05 01:53:11 +0000 |
---|---|---|
committer | CoprDistGit <infra@openeuler.org> | 2024-08-05 01:53:11 +0000 |
commit | cc847bd3b5d21d10a63988be57476459efda578e (patch) | |
tree | 9ba49480f0dd3676f46efa3238daaba7aeb5ece0 /enscript-wrap_header.patch | |
parent | b3f04ac391953a8b9e41503329460248a49fe14a (diff) |
automatic import of enscriptopeneuler24.03_LTS
Diffstat (limited to 'enscript-wrap_header.patch')
-rw-r--r-- | enscript-wrap_header.patch | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/enscript-wrap_header.patch b/enscript-wrap_header.patch new file mode 100644 index 0000000..c251f6d --- /dev/null +++ b/enscript-wrap_header.patch @@ -0,0 +1,50 @@ +diff -up enscript-1.6.5.1/lib/simple.hdr.wrap_header enscript-1.6.5.1/lib/simple.hdr +--- enscript-1.6.5.1/lib/simple.hdr.wrap_header 2009-01-24 21:59:34.000000000 +0100 ++++ enscript-1.6.5.1/lib/simple.hdr 2010-05-21 13:04:28.070346832 +0200 +@@ -3,6 +3,10 @@ + % Copyright (c) 1995 Markku Rossi. + % Author: Markku Rossi <mtr@iki.fi> + % ++% Modified: Chris Josefy, USA, MAY 2006 ++% + Added line wrapping to header to work more like AIX enscript ++% + This assumes that one does not change the header font size from the default ++% + This also assumes that the line only wraps once + + % + % This file is part of GNU Enscript. +@@ -24,6 +28,7 @@ + % -- code follows this line -- + %Format: fmodstr $D{%a %b %d %H:%M:%S %Y} + %Format: pagenumstr $V$% ++%HeaderHeight: 44 + + /do_header { % print default simple header + gsave +@@ -39,10 +44,23 @@ + d_header_w user_header_right_str stringwidth pop sub 5 sub + 0 moveto user_header_right_str show + } { +- 5 0 moveto fname show +- 45 0 rmoveto fmodstr show +- 45 0 rmoveto pagenumstr show +- } ifelse ++ fname length fmodstr length add pagenumstr length add 95 6 idiv add d_header_w 6 idiv le{ ++ 5 0 moveto fname show ++ 45 0 rmoveto fmodstr show ++ 45 0 rmoveto pagenumstr show ++ } { ++ 5 0 moveto fmodstr show ++ 45 0 rmoveto pagenumstr show ++ fname length d_header_w 6 idiv idiv 1 add 10 mul 5 exch moveto ++ 1 1 fname length d_header_w 6 idiv idiv ++ { ++ dup fname exch 1 sub d_header_w 6 idiv mul d_header_w 6 idiv getinterval show ++ 5 exch 10 mul fname length d_header_w 6 idiv idiv 1 add 10 mul exch sub moveto ++ } for ++ 5 10 moveto ++ fname fname length d_header_w 6 idiv idiv d_header_w 6 idiv mul dup fname length exch sub getinterval show ++ }ifelse ++ }ifelse + + grestore + } def |