texlive[42420] Build/source/texk/dvipsk: dvipsk: add a new option to
commits+kakuto at tug.org
commits+kakuto at tug.org
Wed Nov 2 00:23:20 CET 2016
Revision: 42420
http://tug.org/svn/texlive?view=revision&revision=42420
Author: kakuto
Date: 2016-11-02 00:23:20 +0100 (Wed, 02 Nov 2016)
Log Message:
-----------
dvipsk: add a new option to tweak special papersize
Modified Paths:
--------------
trunk/Build/source/texk/dvipsk/ChangeLog
trunk/Build/source/texk/dvipsk/dospecial.c
trunk/Build/source/texk/dvipsk/dvips.c
trunk/Build/source/texk/dvipsk/dvips.help
trunk/Build/source/texk/dvipsk/protos.h
trunk/Build/source/texk/dvipsk/resident.c
Modified: trunk/Build/source/texk/dvipsk/ChangeLog
===================================================================
--- trunk/Build/source/texk/dvipsk/ChangeLog 2016-11-01 20:15:08 UTC (rev 42419)
+++ trunk/Build/source/texk/dvipsk/ChangeLog 2016-11-01 23:23:20 UTC (rev 42420)
@@ -1,3 +1,9 @@
+2016-11-01 Akira Kakuto <kakuto at fuk.kindai.ac.jp>
+
+ * dospecial.c, dvips.c, dvips.help, protos.h, resident.c:
+ Add a new option -L* Last special papersize wins.
+ dvips -L0 ... gives the old behavior.
+
2016-10-30 Karl Berry <karl at tug.org>
* output.c (INVALID_EPOCH_VALUE): define as (time_t) -1,
Modified: trunk/Build/source/texk/dvipsk/dospecial.c
===================================================================
--- trunk/Build/source/texk/dvipsk/dospecial.c 2016-11-01 20:15:08 UTC (rev 42419)
+++ trunk/Build/source/texk/dvipsk/dospecial.c 2016-11-01 23:23:20 UTC (rev 42420)
@@ -434,7 +434,7 @@
p += 9;
while (*p == '=' || *p == ' ')
p++;
- if (hpapersize == 0 || vpapersize == 0) {
+ if (lastpsizwins || hpapersize == 0 || vpapersize == 0) {
if (landscape) {
error(
"both landscape and papersize specified: ignoring landscape");
Modified: trunk/Build/source/texk/dvipsk/dvips.c
===================================================================
--- trunk/Build/source/texk/dvipsk/dvips.c 2016-11-01 20:15:08 UTC (rev 42419)
+++ trunk/Build/source/texk/dvipsk/dvips.c 2016-11-01 23:23:20 UTC (rev 42420)
@@ -137,6 +137,7 @@
integer hh, vv; /* horizontal and vertical pixel positions */
Boolean noomega = 0; /* Omega extensions are enabled */
Boolean noptex = 0; /* pTeX extensions are enabled */
+Boolean lastpsizwins = 1; /* if 1, last \special{papersize=w,h} wins */
/*-----------------------------------------------------------------------*
* The PATH definitions cannot be defined on the command line because so many
@@ -281,7 +282,7 @@
"-i* Separate file per section",
"-j* Download fonts partially",
"-k* Print crop marks -K* Pull comments from inclusions",
-"-l # Last page",
+"-l # Last page -L* Last special papersize wins",
"-m* Manual feed -M* Don't make fonts",
"-mode s Metafont device name",
"-n # Maximum number of pages -N* No structured comments",
@@ -1011,6 +1012,9 @@
case 'K' :
removecomments = (*p != '0');
break;
+case 'L' :
+ lastpsizwins = (*p != '0');
+ break;
case 'U' :
nosmallchars = (*p != '0');
break;
Modified: trunk/Build/source/texk/dvipsk/dvips.help
===================================================================
--- trunk/Build/source/texk/dvipsk/dvips.help 2016-11-01 20:15:08 UTC (rev 42419)
+++ trunk/Build/source/texk/dvipsk/dvips.help 2016-11-01 23:23:20 UTC (rev 42420)
@@ -14,7 +14,7 @@
-i* Separate file per section
-j* Download fonts partially
-k* Print crop marks -K* Pull comments from inclusions
--l # Last page
+-l # Last page -L* Last special papersize wins
-m* Manual feed -M* Don't make fonts
-mode s Metafont device name
-n # Maximum number of pages -N* No structured comments
Modified: trunk/Build/source/texk/dvipsk/protos.h
===================================================================
--- trunk/Build/source/texk/dvipsk/protos.h 2016-11-01 20:15:08 UTC (rev 42419)
+++ trunk/Build/source/texk/dvipsk/protos.h 2016-11-01 23:23:20 UTC (rev 42420)
@@ -303,6 +303,7 @@
extern integer hh, vv;
extern Boolean noomega;
extern Boolean noptex;
+extern Boolean lastpsizwins;
extern const char *infont;
#ifndef KPATHSEA
extern char *tfmpath;
Modified: trunk/Build/source/texk/dvipsk/resident.c
===================================================================
--- trunk/Build/source/texk/dvipsk/resident.c 2016-11-01 20:15:08 UTC (rev 42419)
+++ trunk/Build/source/texk/dvipsk/resident.c 2016-11-01 23:23:20 UTC (rev 42420)
@@ -673,6 +673,9 @@
case 'K':
removecomments = (was_inline[1] != '0');
break;
+case 'L':
+ lastpsizwins = (was_inline[1] != '0');
+ break;
case 'U':
nosmallchars = (was_inline[1] != '0');
break;
More information about the tex-live-commits
mailing list