aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJeffrey H. Kingston <jeff@it.usyd.edu.au>2010-09-14 20:39:50 +0000
committerJeffrey H. Kingston <jeff@it.usyd.edu.au>2010-09-14 20:39:50 +0000
commite4836c62b245d618866b6523ec2c892aeb7a76be (patch)
tree5b5269fb7affb3b20ba8fe0224705bbde98c1614 /include
parent128e9a1532ce7fa38ddc16de06d213530dc5ce15 (diff)
downloadlout-e4836c62b245d618866b6523ec2c892aeb7a76be.tar.gz
Lout 3.32.
git-svn-id: http://svn.savannah.nongnu.org/svn/lout/trunk@33 9365b830-b601-4143-9ba8-b4a8e2c3339c
Diffstat (limited to 'include')
-rw-r--r--include/README4
-rw-r--r--include/blue4
-rw-r--r--include/bluef69
-rw-r--r--include/book5
-rw-r--r--include/bookf1
-rw-r--r--include/bsf70
-rw-r--r--include/cprint4
-rw-r--r--include/cprintf67
-rw-r--r--include/doc4
-rw-r--r--include/docf2
-rw-r--r--include/dsf1
-rw-r--r--include/eiffel4
-rw-r--r--include/eiffelf69
-rw-r--r--include/haskell4
-rw-r--r--include/haskellf71
-rw-r--r--include/java4
-rw-r--r--include/javaf69
-rw-r--r--include/np4
-rw-r--r--include/npf69
-rw-r--r--include/perl4
-rw-r--r--include/perlf69
-rw-r--r--include/picture4
-rw-r--r--include/picturef1
-rw-r--r--include/python4
-rw-r--r--include/pythonf69
-rw-r--r--include/report5
-rw-r--r--include/reportf1
-rw-r--r--include/rsl4
-rw-r--r--include/rslf67
-rw-r--r--include/ruby4
-rw-r--r--include/rubyf67
-rw-r--r--include/save_graphf891
-rw-r--r--include/save_graphf.lpg899
-rw-r--r--include/slides10
-rw-r--r--include/slidesf18
-rw-r--r--include/xind1
-rw-r--r--include/xinda1
-rw-r--r--include/xindb1
38 files changed, 605 insertions, 2040 deletions
diff --git a/include/README b/include/README
index d4e5a84..a4153b6 100644
--- a/include/README
+++ b/include/README
@@ -31,6 +31,7 @@ Setup files (containing mainly lists of options settable by the user)
blue Blue
cprint C and C++
eiffel Eiffel
+ haskell Haskell
java Java
modula Modula-2 (quick hack, does not use prg2lout)
np Nonpareil
@@ -68,6 +69,7 @@ Source files containing Lout and PostScript source code for the packages
bluef Blue
cprintf C and C++
eiffelf Eiffel
+ haskellf Haskell
javaf Java
modulaf Modula-2
npf Nonpareil
@@ -100,4 +102,4 @@ Miscellaneous source files
Jeffrey H. Kingston
-30 October 2002
+20 October 2006
diff --git a/include/blue b/include/blue
index 6395b96..245e19d 100644
--- a/include/blue
+++ b/include/blue
@@ -33,6 +33,7 @@
@Use { @BlueSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
# style { varying @OrIfPlain fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -40,6 +41,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -65,6 +67,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # spacing mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -90,6 +93,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/bluef b/include/bluef
index c4fdb48..c4d4946 100644
--- a/include/bluef
+++ b/include/bluef
@@ -18,6 +18,7 @@ export @Blue
def @BlueSetup
named pipe { } # pipe through this
named numbered { No } # numbered lines?
+ named blanknumbered { Yes } # blanks numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @BlueSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -51,6 +53,7 @@ def @BlueSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -75,6 +78,7 @@ def @BlueSetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -103,23 +107,25 @@ def @BlueSetup
@A "$>"
def @Blue
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
- body @Body # filtered, see below
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
+ body @Body # filtered, see below
@Begin
def @Test # returns x unless x is dft
@@ -181,16 +187,26 @@ def @BlueSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lBlue" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lBlue" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lBlue" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lBlue" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -223,6 +239,15 @@ def @BlueSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -396,7 +421,7 @@ def @BlueSetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @Blue
diff --git a/include/book b/include/book
index 74e0a3a..a1285fc 100644
--- a/include/book
+++ b/include/book
@@ -3,7 +3,6 @@
# Lout setup file for books #
# #
# Jeffrey H. Kingston #
-# 17 September 1999 #
# #
###############################################################################
@@ -60,6 +59,9 @@
# @ListIndent { 0s } # indent of list items
# @ListRightIndent { 0s } # right indent of list items
# @ListLabelWidth { 2.00f @OrIfPlain 5s } # width allowed for list tags
+ # @ListLabelRight { No } # right-adjust list labels
+ # @ListLabelRightGap { 2s } # gap when right-adjusting
+ # @ListBreak { } # break style of list items
# @NumberSeparator { . } # separates nums like 2.3.7
# @CrossLinkFormat { @Body } # format of cross links
# @ExternalLinkFormat { @Body } # format of external links
@@ -208,6 +210,7 @@
# @IndexBTypeOrdinary { @PageNum } # Ordinary pagenum format
# @IndexBTypeMain { @B @PageNum } # Main pagenum format
# @IndexBTypeSpecial { @I @PageNum } # Special pagenum format
+ # @IndexBRangeFormat { @From--@To } # index page range format
# @IndexBColumnNumber { 2 } # index B columns (1 to 10)
# @IndexBColumnGap { 1.00c @OrIfPlain 6s } # index B column gap
# @IndexBCtd { Yes } # include (ctd.) lines
diff --git a/include/bookf b/include/bookf
index b62619c..4ae9141 100644
--- a/include/bookf
+++ b/include/bookf
@@ -4,7 +4,6 @@
# @BookSetup extension to @DocumentSetup. #
# #
# Jeffrey H. Kingston #
-# 17 September 1999 #
# #
# This package extends DocumentSetup with definitions for books. #
# #
diff --git a/include/bsf b/include/bsf
index be86f21..12b19e6 100644
--- a/include/bsf
+++ b/include/bsf
@@ -4,10 +4,6 @@
# Lout @BasicSetup package #
# #
# Jeffrey H. Kingston #
-# 5 February 1999 #
-# Modified 30 October 2002 - reorganization of colours, textures, lengths #
-# #
-# Based on the first part of the @DocumentLayout package, version 3.11. #
# #
# This package contains basic symbols used widely throughout many #
# documents, for font changes, particular characters, standard words in #
@@ -104,7 +100,8 @@ export
@InitialColour @OptimizePages @HeadingFont
@ParaGap @ParaIndent @DisplayGap @DisplayIndent @DefaultIndent
@DisplayNumStyle @WideIndent @VeryWideIndent
- @ListGap @ListIndent @ListRightIndent @ListLabelWidth
+ @ListGap @ListIndent @ListRightIndent
+ @ListLabelWidth @ListLabelRight @ListLabelRightGap @ListBreak
@NumberSeparator
@Word @Roman @UCRoman @Alpha @UCAlpha @FnBullets @FnSymbols
@@ -270,6 +267,9 @@ def @BasicSetup
named @ListIndent { 0s } # indent of list items
named @ListRightIndent{ 0s } # right indent of list items
named @ListLabelWidth { 2.0f @OrIfPlain 5s } # width allowed for list tags
+ named @ListLabelRight { No } # right align label
+ named @ListLabelRightGap { 2s } # right align gap
+ named @ListBreak { } # break style of list item
named @NumberSeparator{ . } # separates numbers like 2.3.7
import @BasicSetup
named @CrossLinkFormat
@@ -1468,26 +1468,40 @@ def @BasicSetup
named itemindent { 0c }
named rightindent { @ListRightIndent }
named labelwidth { @ListLabelWidth }
+ named labelright { @ListLabelRight }
+ named labelrightgap { @ListLabelRightGap }
named start { 1 }
+ named break { @ListBreak }
+ named colnum { 1 }
+ named colgap { 1.0c }
+ named colheight { 5.0c }
{
def @MakeList right num
{
def @NormalItem
{
+ def @Align right x
+ {
+ labelright @Case {
+ { Yes yes } @Yield { labelwidth @Wide { |1rt @OneCol { x |labelrightgap } } }
+ else @Yield x
+ }
+ }
+
|indent
labelwidth @Wide {
# @NumberMarker @Value {style num} {style num} &0io
# @NumberMarker @Value {num} {style type num} &0io
- @NumberMarker @Value {type num} {style type num} &0io
+ @NumberMarker @Value {type num} {@Align style type num} &0io
}
- |itemindent @ItemPlace |rightindent
+ |itemindent break @Break @ItemPlace |rightindent
//gap @MakeList @NotRevealed @Next num
}
def @ParagraphItem
{
@NumberMarker @Value {num} {style type num} &0io
- |indent @ParagraphItemPlace |rightindent
+ |indent break @Break @ParagraphItemPlace |rightindent
//gap @MakeList @NotRevealed @Next num
}
@@ -1519,7 +1533,45 @@ def @BasicSetup
@MakeList start // @EndListPlace
}
- @ListGalleyPlace
+ def @ColPieceTwo
+ {
+ colheight @High 50c @Wide @ListGalleyPlace ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed
+ }
+
+ def @ColPieceThree
+ {
+ colheight @High 50c @Wide @ListGalleyPlace ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed
+ }
+
+ def @ColPieceFour
+ {
+ colheight @High 50c @Wide @ListGalleyPlace ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed
+ }
+
+ def @ColPieceFive
+ {
+ colheight @High 50c @Wide @ListGalleyPlace ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed ||colgap
+ colheight @High 50c @Wide @ListGalleyPlace @NotRevealed
+ }
+
+ colnum @Case
+ {
+ 1 @Yield @ListGalleyPlace
+ 2 @Yield @ColPieceTwo
+ 3 @Yield @ColPieceThree
+ 4 @Yield @ColPieceFour
+ 5 @Yield @ColPieceFive
+ else @Yield @ListGalleyPlace
+ }
//
@ListGalley
}
diff --git a/include/cprint b/include/cprint
index 4974888..c237065 100644
--- a/include/cprint
+++ b/include/cprint
@@ -33,6 +33,7 @@
@Use { @CPSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # blanknumbered { Yes } # No, NoPrint, or Yes
# style { fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -40,6 +41,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -65,6 +67,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # varying mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -90,6 +93,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/cprintf b/include/cprintf
index 2d2e680..b31a7b3 100644
--- a/include/cprintf
+++ b/include/cprintf
@@ -18,6 +18,7 @@ export @CP
def @CPSetup
named pipe { } # pipe through this
named numbered { No } # numbered lines?
+ named blanknumbered { Yes } # blanks numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @CPSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -51,6 +53,7 @@ def @CPSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -75,6 +78,7 @@ def @CPSetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -103,22 +107,24 @@ def @CPSetup
@A "$>"
def @CP
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
body @Body # filtered, see below
@Begin
@@ -181,16 +187,26 @@ def @CPSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lC" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lC" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lC" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lC" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -223,6 +239,15 @@ def @CPSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -396,7 +421,7 @@ def @CPSetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @CP
diff --git a/include/doc b/include/doc
index 49ae1d6..4098f9b 100644
--- a/include/doc
+++ b/include/doc
@@ -3,7 +3,6 @@
# Lout setup file for ordinary documents #
# #
# Jeffrey H. Kingston #
-# 5 February 1999 #
# #
###############################################################################
@@ -61,6 +60,9 @@
# @ListIndent { 0s } # indent of list items
# @ListRightIndent { 0s } # right indent of list items
# @ListLabelWidth { 2.00f @OrIfPlain 5s } # width allowed for list tags
+ # @ListLabelRight { No } # right-adjust list labels
+ # @ListLabelRightGap { 2s } # gap when right-adjusting
+ # @ListBreak { } # break style of list items
# @NumberSeparator { . } # separates nums like 2.3.7
# @CrossLinkFormat { @Body } # format of cross links
# @ExternalLinkFormat { @Body } # format of external links
diff --git a/include/docf b/include/docf
index 38b562f..bd8e875 100644
--- a/include/docf
+++ b/include/docf
@@ -4,8 +4,6 @@
# @OrdinarySetup extension to @DocumentSetup. #
# #
# Jeffrey H. Kingston #
-# August 1994 #
-# 5 February 1999 #
# #
# This package extends DocumentSetup for ordinary documents. #
# #
diff --git a/include/dsf b/include/dsf
index 394fd1e..43a5ca1 100644
--- a/include/dsf
+++ b/include/dsf
@@ -15,6 +15,7 @@
# Version 3.16 by Jeffrey H. Kingston, May 1999. #
# Version 3.17 by Jeffrey H. Kingston, September 1999. #
# Version 3.21 by Jeffrey H. Kingston, May 2000. #
+# Minor changes in later versions undated. #
# #
# This Lout package contains the general definitions used by all types of #
# documents. It needs to be extended (see docf, reportf, bookf, slidesf, #
diff --git a/include/eiffel b/include/eiffel
index 8ce7973..e7dc0b8 100644
--- a/include/eiffel
+++ b/include/eiffel
@@ -33,6 +33,7 @@
@Use { @EiffelSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
# style { varying @OrIfPlain fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -40,6 +41,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -65,6 +67,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # spacing mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -90,6 +93,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/eiffelf b/include/eiffelf
index f456392..f5cfc67 100644
--- a/include/eiffelf
+++ b/include/eiffelf
@@ -18,6 +18,7 @@ export @Eiffel
def @EiffelSetup
named pipe { } # pipe through this first
named numbered { No } # want lines numbered?
+ named blanknumbered { Yes } # blank lines numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @EiffelSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -51,6 +53,7 @@ def @EiffelSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -75,6 +78,7 @@ def @EiffelSetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -103,23 +107,25 @@ def @EiffelSetup
@A "$>"
def @Eiffel
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
- body @Body # filtered, see below
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
+ body @Body # filtered, see below
@Begin
def @Test # returns x unless x is dft
@@ -181,16 +187,26 @@ def @EiffelSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lEiffel" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lEiffel" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lEiffel" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lEiffel" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -223,6 +239,15 @@ def @EiffelSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -396,7 +421,7 @@ def @EiffelSetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @Eiffel
diff --git a/include/haskell b/include/haskell
index 52d5448..025ab25 100644
--- a/include/haskell
+++ b/include/haskell
@@ -33,6 +33,7 @@
@Use { @HaskellSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
# style { symbol @OrIfPlain fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -40,6 +41,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -65,6 +67,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # spacing mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -90,6 +93,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/haskellf b/include/haskellf
index 8a019f2..b1064a1 100644
--- a/include/haskellf
+++ b/include/haskellf
@@ -18,6 +18,7 @@ export @Haskell
def @HaskellSetup
named pipe { } # pipe through this first
named numbered { No } # want lines numbered?
+ named blanknumbered { Yes } # blank lines numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @HaskellSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 4 } # tab interval
named fixedtabout { 4s } # tab width
@@ -54,6 +56,7 @@ def @HaskellSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 4 } # tab interval
named varyingtabout { 1.5f } # tab width
@@ -81,6 +84,7 @@ def @HaskellSetup
named symbolfont { } # font family
named symbolsize { 1f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 4 } # tab interval
named symboltabout { 1.7f } # tab width
@@ -112,24 +116,26 @@ def @HaskellSetup
@A "$>"
def @Haskell
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named braces { dft } # braces font
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
- body @Body # filtered, see below
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named braces { dft } # braces font
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
+ body @Body # filtered, see below
@Begin
def @Test # returns x unless x is dft
@@ -191,16 +197,26 @@ def @HaskellSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lHaskell" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lHaskell" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lHaskell" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lHaskell" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -233,6 +249,15 @@ def @HaskellSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -473,7 +498,7 @@ def @HaskellSetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @Haskell
diff --git a/include/java b/include/java
index 41fd1f7..4d747c0 100644
--- a/include/java
+++ b/include/java
@@ -33,6 +33,7 @@
@Use { @JavaSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
# style { fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -40,6 +41,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -65,6 +67,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # spacing mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -90,6 +93,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/javaf b/include/javaf
index fb84541..e0cf8ea 100644
--- a/include/javaf
+++ b/include/javaf
@@ -18,6 +18,7 @@ export @Java
def @JavaSetup
named pipe { } # pipe through this first
named numbered { No } # want lines numbered?
+ named blanknumbered { Yes } # blank lines numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @JavaSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -51,6 +53,7 @@ def @JavaSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -75,6 +78,7 @@ def @JavaSetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -103,23 +107,25 @@ def @JavaSetup
@A "$>"
def @Java
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
- body @Body # filtered, see below
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
+ body @Body # filtered, see below
@Begin
def @Test # returns x unless x is dft
@@ -181,16 +187,26 @@ def @JavaSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lJava" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lJava" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lJava" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lJava" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -223,6 +239,15 @@ def @JavaSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -396,7 +421,7 @@ def @JavaSetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @Java
diff --git a/include/np b/include/np
index 1ccd4bb..4e9e625 100644
--- a/include/np
+++ b/include/np
@@ -32,6 +32,7 @@
@Use { @NonpareilSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
# style { symbol @OrIfPlain fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -39,6 +40,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -64,6 +66,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # varying mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -89,6 +92,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/npf b/include/npf
index 258529d..aa2230f 100644
--- a/include/npf
+++ b/include/npf
@@ -17,6 +17,7 @@ export @Nonpareil
def @NonpareilSetup
named pipe { } # pipe through this
named numbered { No } # numbered lines?
+ named blanknumbered { Yes } # blanks numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -26,6 +27,7 @@ def @NonpareilSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -50,6 +52,7 @@ def @NonpareilSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -74,6 +77,7 @@ def @NonpareilSetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -102,23 +106,25 @@ def @NonpareilSetup
@A "$>"
def @Nonpareil
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
- body @Body # filtered, see below
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
+ body @Body # filtered, see below
@Begin
def @Test # returns x unless x is dft
@@ -180,16 +186,26 @@ def @NonpareilSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lNonpareil" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lNonpareil" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lNonpareil" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lNonpareil" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -222,6 +238,15 @@ def @NonpareilSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -395,7 +420,7 @@ def @NonpareilSetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @Nonpareil
diff --git a/include/perl b/include/perl
index 4a886f3..b2ab51f 100644
--- a/include/perl
+++ b/include/perl
@@ -51,6 +51,7 @@
@Use { @PerlSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
# style { fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -58,6 +59,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -83,6 +85,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingtabin { 8 } # tab interval
# varyingspace { lout } # spacing mode
# varyingtabout { 3f } # tab width
@@ -108,6 +111,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/perlf b/include/perlf
index 8a12ceb..28b699a 100644
--- a/include/perlf
+++ b/include/perlf
@@ -18,6 +18,7 @@ export @Perl
def @PerlSetup
named pipe { } # pipe through this
named numbered { No } # numbered lines?
+ named blanknumbered { Yes } # blanks numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @PerlSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -51,6 +53,7 @@ def @PerlSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -75,6 +78,7 @@ def @PerlSetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -103,23 +107,25 @@ def @PerlSetup
@A "$>"
def @Perl
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
- body @Body # filtered, see below
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
+ body @Body # filtered, see below
@Begin
def @Test # returns x unless x is dft
@@ -181,16 +187,26 @@ def @PerlSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lPerl" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lPerl" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lPerl" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lPerl" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -223,6 +239,15 @@ def @PerlSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -396,7 +421,7 @@ def @PerlSetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @Perl
diff --git a/include/picture b/include/picture
index ec8efc9..d81dbe5 100644
--- a/include/picture
+++ b/include/picture
@@ -3,7 +3,6 @@
# Lout setup file for stand-alone illustrations #
# #
# Jeffrey H. Kingston #
-# 5 February 1999 #
# #
###############################################################################
@@ -61,6 +60,9 @@
# @ListIndent { 0s } # indent of list items
# @ListRightIndent { 0s } # right indent of list items
# @ListLabelWidth { 2.00f @OrIfPlain 5s } # width allowed for list tags
+ # @ListLabelRight { No } # right-adjust list labels
+ # @ListLabelRightGap { 2s } # gap when right-adjusting
+ # @ListBreak { } # break style of list items
# @NumberSeparator { . } # separates nums like 2.3.7
# @CrossLinkFormat { @Body } # format of cross links
# @ExternalLinkFormat { @Body } # format of external links
diff --git a/include/picturef b/include/picturef
index 6987079..75e3140 100644
--- a/include/picturef
+++ b/include/picturef
@@ -4,7 +4,6 @@
# @IllustrationSetup extension to @DocumentSetup. #
# #
# Jeffrey H. Kingston #
-# August 1994 #
# #
# This package extends DocumentSetup for illustrations. #
# #
diff --git a/include/python b/include/python
index 9216ca5..7fbac8a 100644
--- a/include/python
+++ b/include/python
@@ -33,6 +33,7 @@
@Use { @PythonSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
# style { varying @OrIfPlain fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -40,6 +41,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -65,6 +67,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # spacing mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -90,6 +93,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/pythonf b/include/pythonf
index 712c399..c05e4f4 100644
--- a/include/pythonf
+++ b/include/pythonf
@@ -18,6 +18,7 @@ export @Python
def @PythonSetup
named pipe { } # pipe through this first
named numbered { No } # want lines numbered?
+ named blanknumbered { Yes } # blank lines numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @PythonSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -51,6 +53,7 @@ def @PythonSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -75,6 +78,7 @@ def @PythonSetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -103,23 +107,25 @@ def @PythonSetup
@A "$>" "''"
def @Python
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
- body @Body # filtered, see below
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
+ body @Body # filtered, see below
@Begin
def @Test # returns x unless x is dft
@@ -181,16 +187,26 @@ def @PythonSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lPython" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lPython" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lPython" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lPython" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -223,6 +239,15 @@ def @PythonSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -400,7 +425,7 @@ def @PythonSetup
def "''" { "''" }
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @Python
diff --git a/include/report b/include/report
index 7f2523d..0d216b8 100644
--- a/include/report
+++ b/include/report
@@ -3,8 +3,6 @@
# Lout setup file for technical reports #
# #
# Jeffrey H. Kingston #
-# 5 February 1999 #
-# 17 September 1999 #
# #
# Note: this version, released with Lout Version 3.13, is not upwardly #
# compatible with previous versions: the @Abstract symbol must now #
@@ -66,6 +64,9 @@
# @ListIndent { 0s } # indent of list items
# @ListRightIndent { 0s } # right indent of list items
# @ListLabelWidth { 2.00f @OrIfPlain 5s } # width allowed for list tags
+ # @ListLabelRight { No } # right-adjust list labels
+ # @ListLabelRightGap { 2s } # gap when right-adjusting
+ # @ListBreak { } # break style of list items
# @NumberSeparator { . } # separates nums like 2.3.7
# @CrossLinkFormat { @Body } # format of cross links
# @ExternalLinkFormat { @Body } # format of external links
diff --git a/include/reportf b/include/reportf
index ebef8b5..f8e92a3 100644
--- a/include/reportf
+++ b/include/reportf
@@ -4,7 +4,6 @@
# @ReportSetup extension to @DocumentSetup. #
# #
# Jeffrey H. Kingston #
-# August 1994 #
# #
# This package extends DocumentSetup with definitions for reports. #
# #
diff --git a/include/rsl b/include/rsl
index 3411034..a6c7928 100644
--- a/include/rsl
+++ b/include/rsl
@@ -34,6 +34,7 @@
@Use { @RSLSetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
# style { symbol @OrIfPlain fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -41,6 +42,7 @@
# fixedfont { Courier } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -66,6 +68,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # spacing mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -91,6 +94,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/rslf b/include/rslf
index 0680138..a708e3b 100644
--- a/include/rslf
+++ b/include/rslf
@@ -18,6 +18,7 @@ export @RSL
def @RSLSetup
named pipe { } # pipe through this first
named numbered { No } # want lines numbered?
+ named blanknumbered { Yes } # blank lines numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @RSLSetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -51,6 +53,7 @@ def @RSLSetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -75,6 +78,7 @@ def @RSLSetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -103,22 +107,24 @@ def @RSLSetup
@FA @A @PartialFn @Map @PartialMap @IntChoice @ExtChoice @InfList @Interlock "$>"
def @RSL
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
body @Body # filtered, see below
@Begin
@@ -181,16 +187,26 @@ def @RSLSetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lRSL" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lRSL" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lRSL" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lRSL" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -223,6 +239,15 @@ def @RSLSetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -454,7 +479,7 @@ def @RSLSetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @RSL
diff --git a/include/ruby b/include/ruby
index 6a82b55..c5895a0 100644
--- a/include/ruby
+++ b/include/ruby
@@ -33,6 +33,7 @@
@Use { @RubySetup
# pipe { } # pipe source through this
# numbered { No } # No, Yes, or a line number
+ # numberedblanks { Yes } # No or Yes
style { fixed @OrIfPlain fixed } # fixed, varying, or symbol
# the following options apply when style is "fixed"
@@ -40,6 +41,7 @@
# fixedfont { LetterGothic } # font family
# fixedsize { -1.0p } # font size
# fixedline { 1.0vx } # line-space
+ # fixedblanklinescale { 1.0 } # blank-line scale
# fixedspace { lout } # spacing mode
# fixedtabin { 8 } # tab interval
# fixedtabout { 8s } # tab width
@@ -65,6 +67,7 @@
# varyingfont { } # font family
# varyingsize { 1.0f } # font size
# varyingline { 1.0vx } # line-space
+ # varyingblanklinescale { 1.0 } # blank-line scale
# varyingspace { lout } # spacing mode
# varyingtabin { 8 } # tab interval
# varyingtabout { 3f } # tab width
@@ -90,6 +93,7 @@
# symbolfont { } # font family
# symbolsize { 1.0f } # font size
# symbolline { 1.0vx } # line-space
+ # symbolblanklinescale { 1.0 } # blank-line scale
# symbolspace { lout } # spacing mode
# symboltabin { 8 } # tab interval
# symboltabout { 3f } # tab width
diff --git a/include/rubyf b/include/rubyf
index e7f607a..1d30c54 100644
--- a/include/rubyf
+++ b/include/rubyf
@@ -18,6 +18,7 @@ export @Ruby
def @RubySetup
named pipe { } # pipe through this first
named numbered { No } # want lines numbered?
+ named blanknumbered { Yes } # blank lines numbered?
named style
named @OrIfPlain left x right y
{ @BackEnd @Case { PlainText @Yield y else @Yield x } }
@@ -27,6 +28,7 @@ def @RubySetup
named fixedfont { Courier }# font family
named fixedsize { -1.0p } # font size
named fixedline { 1.0vx } # line-space
+ named fixedblanklinescale { 1.0 } # blank-line scale
named fixedspace { lout } # spacing mode
named fixedtabin { 8 } # tab interval
named fixedtabout { 8s } # tab width
@@ -51,6 +53,7 @@ def @RubySetup
named varyingfont { } # font family
named varyingsize { 1.0f } # font size
named varyingline { 1.0vx } # line-space
+ named varyingblanklinescale { 1.0 } # blank-line scale
named varyingspace { lout } # spacing mode
named varyingtabin { 8 } # tab interval
named varyingtabout { 3f } # tab width
@@ -75,6 +78,7 @@ def @RubySetup
named symbolfont { } # font family
named symbolsize { 1.0f } # font size
named symbolline { 1.0vx } # line-space
+ named symbolblanklinescale { 1.0 } # blank-line scale
named symbolspace { lout } # spacing mode
named symboltabin { 8 } # tab interval
named symboltabout { 3f } # tab width
@@ -103,22 +107,24 @@ def @RubySetup
@A "$>"
def @Ruby
- named style { style } # style
- named numbered { numbered } # want numbered lines?
- named pipe { pipe } # pipe through this first
- named font { dft } # font family
- named size { dft } # font size
- named line { dft } # line-space
- named space { dft } # spacing mode
- named tabin { dft } # tab interval
- named tabout { dft } # tab width
- named identifiers { dft } # ident. font
- named keywords { dft } # keyword font
- named operators { dft } # operator font
- named numbers { dft } # number font
- named strings { dft } # string font
- named comments { dft } # comment font
- named linenumbers { dft } # line numbers font
+ named style { style } # style
+ named numbered { numbered } # want numbered lines?
+ named blanknumbered { blanknumbered } # numbered blank lines?
+ named pipe { pipe } # pipe through this first
+ named font { dft } # font family
+ named size { dft } # font size
+ named line { dft } # line-space
+ named blanklinescale { dft } # blank-line scale
+ named space { dft } # spacing mode
+ named tabin { dft } # tab interval
+ named tabout { dft } # tab width
+ named identifiers { dft } # ident. font
+ named keywords { dft } # keyword font
+ named operators { dft } # operator font
+ named numbers { dft } # number font
+ named strings { dft } # string font
+ named comments { dft } # comment font
+ named linenumbers { dft } # line numbers font
body @Body # filtered, see below
@Begin
@@ -181,16 +187,26 @@ def @RubySetup
}
}
+ def wantblanknumbered
+ {
+ blanknumbered @Case {
+ { No no } @Yield "-M"
+ { NoPrint noprint } @Yield "-N"
+ { Yes yes } @Yield ""
+ }
+ }
+
pipe @Case {
"" @Yield {
- "prg2lout -r -lRuby" wantnumbered -i{@FilterIn}
- -o{@FilterOut} -e{@FilterErr}
+ "prg2lout -r -lRuby" wantblanknumbered wantnumbered
+ -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
-t{@InitTab} -T{@InitTabWidth}
}
else @Yield {
"cat" @FilterIn "|" pipe "|"
- "prg2lout -r -lRuby" wantnumbered -o{@FilterOut}
- -e{@FilterErr} -t{@InitTab} -T{@InitTabWidth}
+ "prg2lout -r -lRuby" wantblanknumbered wantnumbered
+ -o{@FilterOut} -e{@FilterErr}
+ -t{@InitTab} -T{@InitTabWidth}
}
}
}
@@ -223,6 +239,15 @@ def @RubySetup
}
+ def @InitBLS
+ {
+ blanklinescale @Test
+ iffixed { fixedblanklinescale }
+ ifvarying { varyingblanklinescale }
+ ifsymbol { symbolblanklinescale }
+ }
+
+
def @InitSpace
{
space @Test
@@ -399,7 +424,7 @@ def @RubySetup
{ @InitFontFamily Base @InitSize } @Font @InitSpace @Space
- { @InitLine lines nohyphen } @Break @Body
+ { @InitLine lines nohyphen "blanklinescale" @InitBLS } @Break @Body
@End @Ruby
diff --git a/include/save_graphf b/include/save_graphf
deleted file mode 100644
index 8bb9d05..0000000
--- a/include/save_graphf
+++ /dev/null
@@ -1,891 +0,0 @@
-
-###############################################################################
-# #
-# Lout @Graph package for drawing graphs (Version 1.0) #
-# #
-# Version 1.0 by Jeffrey H. Kingston, December 1993. #
-# #
-# This package draws graphs, the statistical kind not the graph-theoretical #
-# kind. See the User's Guide (Advanced Graphics) for user info. #
-# #
-###############################################################################
-
-@SysInclude { graphf.etc } # @GraphMath
-@SysInclude { lengths } # @LoutLengths
-@SysInclude { coltex } # @ColourCommand and @TextureCommand
-@SysPrependGraphic { graphf.lpg }
-
-
-def @GraphObj
- left p
- named margin { 0c }
- named adj { 0 0 }
- right x
-{
- @BackEnd @Case {
- PostScript @Yield {
- @Null & # kills previous white space
- @HContract @VContract {
- //0io ||0io @HContract @VContract
- { p "trpoint translate" adj "translate gsave" // "grestore" }
- @Graphic { //margin ||margin x ||margin //margin }
- ||0io //0io
- }
- }
-# VT: PDF does nothing
- PDF @Yield {
- @Null & # kills previous white space
- @HContract @VContract {
- //0io ||0io @HContract @VContract
- { "% @GraphObj UNIMPLEMENTED" }
- @Graphic { //margin ||margin x ||margin //margin }
- ||0io //0io
- }
- }
- }
-}
-
-def @GraphCross
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath 0 0 moveto xsize ysize lineto 0 ysize moveto"
- "xsize 0 lineto [] 0 setdash stroke"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
- { "n [] 0 d 0 0 m __xsize __ysize l 0 __ysize m __xsize 0 l S"}
- # uses S because PostScript version does NOT use closepath
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphPlus
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath xmark 0 moveto xmark ysize lineto 0 ymark moveto"
- "xsize ymark lineto [] 0 setdash stroke"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
- { "n [] 0 d __xmark 0 m __xmark __ysize l 0 __ymark m __xsize __ymark l S"}
- # uses S because PostScript version does NOT use closepath
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphSquare
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath 0 0 moveto xsize 0 lineto xsize ysize lineto"
- "0 ysize lineto closepath [] 0 setdash stroke"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
- {"n [] 0 d 0 0 __xsize __ysize re s"}
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphFilledSquare
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath 0 0 moveto xsize 0 lineto xsize ysize lineto"
- "0 ysize lineto closepath gsave [] 0 setdash stroke grestore fill"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
- {"n [] 0 d 0 0 __xsize __ysize re b"}
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphDiamond
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath 0 ymark moveto xmark 0 lineto xsize ymark lineto"
- "xmark ysize lineto closepath [] 0 setdash stroke"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
- {"n [] 0 d 0 __ymark m __xmark 0 l __xsize __ymark l __xmark __ysize l s"}
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphFilledDiamond
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath 0 ymark moveto xmark 0 lineto xsize ymark lineto"
- "xmark ysize lineto closepath gsave [] 0 setdash stroke grestore fill"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
- {"n [] 0 d 0 __ymark m __xmark 0 l __xsize __ymark l __xmark __ysize l b"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphCircle
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath xmark ymark xmark 0 360 arc"
- "[] 0 setdash stroke"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
-#
-# draw a circle whose centre is at (xmark, ymark) and whose radius is xmark units;
-#
-# for curveto to work, we need to calculate the control points of the Bezier curve
-# as well as move the pen to the correct initial point. The circle is drawn as two
-# arcs of 180 degrees
-#
-# pt0 = (xmark + xmark, ymark)
-# pt1 = (xmark + xmark, ymark + 4/3 * xmark)
-# pt2 = (0, ymark + 4/3 * xmark)
-# pt3 = (0, ymark)
-#
-# pt0 = (0, ymark)
-# pt1 = (0, ymark - 4/3 * xmark)
-# pt2 = (xmark + xmark, ymark - 4/3 * xmark)
-# pt3 = (xmark + xmark, ymark)
-#
- {"n [] 0 d"
- "__mul(2, __xmark) __ymark m"
- "__mul(2, __xmark) __add(__ymark, __div(__mul(4, __xmark), 3))" # pt1
- "0 __add(__ymark, __div(__mul(4, __xmark), 3))" # pt2
- "0 __ymark c" # pt3
-
- "0 __sub(__ymark, __div(__mul(4, __xmark), 3))" # pt1
- "__mul(2, __xmark) __sub(__ymark, __div(__mul(4, __xmark), 3))" # pt2
- "__mul(2, __xmark) __ymark c S" # pt3
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphFilledCircle
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
- PostScript @Yield {
- @HContract @VContract
- { "newpath xmark ymark xmark 0 360 arc"
- "gsave [] 0 setdash stroke grestore fill"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
-#
-# draw a filled circle whose centre is at (xmark, ymark) and whose radius is xmark units;
-#
-# for curveto to work, we need to calculate the control points of the Bezier curve
-# as well as move the pen to the correct initial point. The circle is drawn as two
-# arcs of 180 degrees
-#
-# pt0 = (xmark + xmark, ymark)
-# pt1 = (xmark + xmark, ymark + 4/3 * xmark)
-# pt2 = (0, ymark + 4/3 * xmark)
-# pt3 = (0, ymark)
-#
-# pt0 = (0, ymark)
-# pt1 = (0, ymark - 4/3 * xmark)
-# pt2 = (xmark + xmark, ymark - 4/3 * xmark)
-# pt3 = (xmark + xmark, ymark)
-#
-# Note: this is not a strict translation because there is a setdash bracketed by
-# gsave/grestore in the above PostScript but there is no closepath before it;
-# but in PDF, it is not possible to execute a setdash within a path definition.
-#
- {"n [] 0 d"
- "__mul(2, __xmark) __ymark m"
- "__mul(2, __xmark) __add(__ymark, __div(__mul(4, __xmark), 3))" # pt1
- "0 __add(__ymark, __div(__mul(4, __xmark), 3))" # pt2
- "0 __ymark c" # pt3
-
- "0 __sub(__ymark, __div(__mul(4, __xmark), 3))" # pt1
- "__mul(2, __xmark) __sub(__ymark, __div(__mul(4, __xmark), 3))" # pt2
- "__mul(2, __xmark) __ymark c b" # pt3
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphTriangle
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath 0 0 moveto xsize 0 lineto xmark ysize 1.25 mul lineto"
- "closepath [] 0 setdash stroke"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
- {"n [] 0 d 0 0 m __xsize 0 l __xmark __mul(__ysize, 1.25) l s"}
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphFilledTriangle
- import @LoutLengths named symbolsize { 0.15f }
-{
- @BackEnd @Case {
-
- PostScript @Yield {
- @HContract @VContract
- { "newpath 0 0 moveto xsize 0 lineto xmark ysize 1.25 mul lineto"
- "closepath gsave [] 0 setdash stroke grestore fill"
- }
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- PDF @Yield {
- @HContract @VContract
- {"n [] 0 d 0 0 m __xsize 0 l __xmark __mul(__ysize, 1.25) l h b"}
- @Graphic
- {symbolsize @High symbolsize @Wide ^| symbolsize @Wide ^/ symbolsize @High}
- }
-
- }
-}
-
-def @GraphNoLine
- import @PSLengths named dashlength { 0.2f }
- import @PSLengths named linewidth { "currentlinewidth" }
- import @LoutLengths named length { 1.0f }
-{
- length @Wide {}
-}
-
-def @GraphSolid
- import @PSLengths named dashlength { 0.2f }
- import @PSLengths named linewidth { "currentlinewidth" }
- import @LoutLengths named length { 1.0f }
-{
- @BackEnd @Case {
- PostScript @Yield {
- @HContract @VContract
- { "xsize 0 lgraphdict begin newpath 0 0 moveto lineto"
- "/linewidth" linewidth "def xsize" dashlength "solid end"
- } @Graphic { length @Wide }
- }
-# VT: PDF does nothing
- PDF @Yield {
- @HContract @VContract
- { "% @GraphSolid UNIMPLEMENTED" } @Graphic { length @Wide }
- }
- }
-}
-
-def @GraphDashed
- import @PSLengths named dashlength { 0.2f }
- import @PSLengths named linewidth { "currentlinewidth" }
- import @LoutLengths named length { 1.0f }
-{
- @BackEnd @Case {
- PostScript @Yield {
- @HContract @VContract
- { "xsize 0 lgraphdict begin newpath 0 0 moveto lineto"
- "/linewidth" linewidth "def xsize" dashlength "dashed end"
- } @Graphic { length @Wide }
- }
-# VT: PDF does nothing
- PDF @Yield {
- @HContract @VContract
- { "% @GraphDashed UNIMPLEMENTED" } @Graphic { length @Wide }
- }
- }
-}
-
-def @GraphDotted
- import @PSLengths named dashlength { 0.2f }
- import @PSLengths named linewidth { "currentlinewidth" }
- import @LoutLengths named length { 1.0f }
-{
- @BackEnd @Case {
- PostScript @Yield {
- @HContract @VContract
- { "xsize 0 lgraphdict begin newpath 0 0 moveto lineto"
- "/linewidth" linewidth "def xsize" dashlength "dotted end"
- } @Graphic { length @Wide }
- }
-# VT: PDF does nothing
- PDF @Yield {
- @HContract @VContract
- { "% @GraphDotted UNIMPLEMENTED" } @Graphic { length @Wide }
- }
- }
-}
-
-def @GraphDotDashed
- import @PSLengths named dashlength { 0.2f }
- import @PSLengths named linewidth { "currentlinewidth" }
- import @LoutLengths named length { 1.0f }
-{
- @BackEnd @Case {
- PostScript @Yield {
- @HContract @VContract
- { "xsize 0 lgraphdict begin newpath 0 0 moveto lineto"
- "/linewidth" linewidth "def xsize" dashlength "dotdashed end"
- } @Graphic { length @Wide }
- }
-# VT: PDF does nothing
- PDF @Yield {
- @HContract @VContract
- { "% @GraphDotDashed UNIMPLEMENTED" } @Graphic { length @Wide }
- }
- }
-}
-
-def @GraphDotDotDashed
- import @PSLengths named dashlength { 0.2f }
- import @PSLengths named linewidth { "currentlinewidth" }
- import @LoutLengths named length { 1.0f }
-{
- @BackEnd @Case {
- PostScript @Yield {
- @HContract @VContract
- { "xsize 0 lgraphdict begin newpath 0 0 moveto lineto"
- "/linewidth" linewidth "def xsize" dashlength "dotdotdashed end"
- } @Graphic { length @Wide }
- }
-# VT: PDF does nothing
- PDF @Yield {
- @HContract @VContract
- { "% @GraphDotDotDashed UNIMPLEMENTED" } @Graphic { length @Wide }
- }
- }
-}
-
-def @GraphDotDotDotDashed
- import @PSLengths named dashlength { 0.2f }
- import @PSLengths named linewidth { "currentlinewidth" }
- import @LoutLengths named length { 1.0f }
-{
- @BackEnd @Case {
- PostScript @Yield {
- @HContract @VContract
- { "xsize 0 lgraphdict begin newpath 0 0 moveto lineto"
- "/linewidth" linewidth "def xsize" dashlength "dotdotdotdashed end"
- } @Graphic { length @Wide }
- }
-# VT: PDF does nothing
- PDF @Yield {
- @HContract @VContract
- { "% @GraphDotDotDotDashed UNIMPLEMENTED" } @Graphic { length @Wide }
- }
- }
-}
-
-
-export @Data
-def @Graph
- named save { no }
- named style { frame }
- import @LoutLengths named width { 6.0c }
- import @LoutLengths named height { 4.0c }
- import @PSLengths named xextra { "none" }
- import @PSLengths named yextra { "none" }
- named xdecreasing { no }
- named ydecreasing { no }
- named leftcaption { }
- named rightcaption { }
- named abovecaption { }
- named belowcaption { }
- import @LoutLengths named leftgap { 1.5c }
- import @LoutLengths named rightgap { 0.5c }
- import @LoutLengths named abovegap { 0.5c }
- import @LoutLengths named belowgap { 0.5c }
- named hidecaptions { yes }
- named objects
- named @NW
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "xsize neg ysize" } margin { margin } x }
- named @SW
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "xsize neg 0" } margin { margin } x }
- named @SE
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "0 0" } margin { margin } x }
- named @NE
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "0 ysize" } margin { margin } x }
- named @W
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "xsize neg ysize 2 div" } margin { margin } x }
- named @S
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "xsize neg 2 div 0" } margin { margin } x }
- named @E
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "0 ysize 2 div" } margin { margin } x }
- named @N
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "xsize neg 2 div ysize" } margin { margin } x }
- named @CTR
- import @GraphMath named at { 0 0 }
- import @LoutLengths named margin { 0.3f }
- right x
- { at @GraphObj adj { "xsize neg 2 div ysize 2 div" } margin {margin} x }
- {}
- named xorigin named none { "false" } { none }
- named yorigin named none { "false" } { none }
- named xlog named none { "0" } { none }
- named ylog named none { "0" } { none }
- named points named none { "none" } { none }
- named pairs named none { "none" } { none }
- named colour color named none { "none" } { none }
- named paint named none { "none" } { none }
- import @TextureImport named texture { solid }
- named xmin named none { "false" } { none }
- named xmax named none { "false" } { none }
- named ymin named none { "false" } { none }
- named ymax named none { "false" } { none }
- named xticksep named none { "0" } { none }
- named yticksep named none { "0" } { none }
- named rticksep named none { "0" } { none }
- import @GraphMath named xticks
- named none { "false" }
- named auto { "false" }
- named "@" { " lgen" }
- named "^" { "^" }
- { false }
- import @GraphMath named yticks
- named none { "false" }
- named auto { "false" }
- named "@" { " lgen" }
- named "^" { "^" }
- { false }
- import @GraphMath named rticks
- named none { "false" }
- named auto { "false" }
- named "@" { " lgen" }
- named "^" { "^" }
- { }
- import @PSLengths named xticklength { 0.5f }
- import @PSLengths named yticklength { 0.5f }
- import @PSLengths named rticklength { 0.5f }
- named dataformat { xandy }
- import @PSLengths named dashlength { 0.2f }
- import @PSLengths named linewidth { "currentlinewidth" }
- import @PSLengths named symbolsize { 0.15f }
- body @Body
-@Begin
-
- def @Above
- {
- abovecaption @Case {
- "" @Yield {}
- else @Yield @OneCol { ||0.5rt clines @Break abovecaption || //abovegap }
- }
- }
-
- def @Below
- {
- belowcaption @Case {
- "" @Yield {}
- else @Yield @OneCol { //belowgap ||0.5rt clines @Break belowcaption || }
- }
- }
-
- def @Left
- {
- leftcaption @Case {
- "" @Yield {}
- else @Yield @OneCol @OneRow {
- { //0.5rt @OneRow clines @Break leftcaption // } ^||leftgap }
- }
- }
-
- def @Right
- {
- rightcaption @Case {
- "" @Yield {}
- else @Yield @OneCol @OneRow {
- ||rightgap { //0.5rt @OneRow lines @Break rightcaption // } }
- }
- }
-
- def @ZeroWidth
- right x
- {
- hidecaptions @Case {
- { No no } @Yield x
- { Yes yes } @Yield @OneCol { ||0io x ||0io }
- }
- }
-
- def @AddCaptions right x
- {
- def belowextra
- {
- xticks @Case {
- "" @Yield { 0i }
- else @Yield { 1.7f }
- }
- }
-
- @HContract @VContract
- {
- | @Above |
- / @ZeroWidth @Left | &0.5rt x | @ZeroWidth @Right
- /belowextra | @Below |
- }
- }
-
- export pi e sqrt abs ceiling floor truncate round cos sin atan exp log rand
- "*" "/" idiv mod "-" "-0" "-1" "-2" "-3" "-4" "-5" "-6" "-7" "-8"
- "-9" "-." "+" "=" "!=" "<" "<=" ">" ">=" not and xor or
- if xloop yloop zloop
-
- def @Data
- named points named none { "none" } { points }
- named pairs named none { "none" } { pairs }
- named colour color named none { "none" } { colour }
- named paint named none { "none" } { paint }
- import @TextureImport named texture { texture }
- import @PSLengths named dashlength { dashlength }
- import @PSLengths named linewidth { linewidth }
- import @PSLengths named symbolsize { symbolsize }
- named dataformat { dataformat }
- body data
- {
- def pi { "3.14159" }
- def e { "2.71828" }
- def sqrt precedence 40 right y { y "sqrt" }
- def abs precedence 40 right y { y "abs" }
- def ceiling precedence 40 right y { y "ceiling" }
- def floor precedence 40 right y { y "floor" }
- def truncate precedence 40 right y { y "truncate" }
- def round precedence 40 right y { y "round" }
- def cos precedence 40 right y { y "cos" }
- def sin precedence 40 right y { y "sin" }
- def atan precedence 39 left x right y { x y "atan" }
- def exp precedence 38 left x right y { x y "exp" }
- def log precedence 37 left x right y { x y "dolog" }
- def rand precedence 36 left x right y { x y "dorand" }
- def "*" precedence 35 left x right y { x y "mul" }
- def "/" precedence 34 left x right y { x y "div" }
- def idiv precedence 34 left x right y { x y "idiv" }
- def mod precedence 34 left x right y { x y "mod" }
- def "-" precedence 33 left x right y
- { x @Case { "" @Yield {y "neg"} else @Yield { x y "sub" } } }
- def "-0" { "-0" }
- def "-1" { "-1" }
- def "-2" { "-2" }
- def "-3" { "-3" }
- def "-4" { "-4" }
- def "-5" { "-5" }
- def "-6" { "-6" }
- def "-7" { "-7" }
- def "-8" { "-8" }
- def "-9" { "-9" }
- def "-." { "-." }
- def "+" precedence 32 left x right y
- { x @Case { "" @Yield { y } else @Yield { x y "add" } } }
- def "=" precedence 30 left x right y { x y "eq" }
- def "!=" precedence 30 left x right y { x y "ne" }
- def "<" precedence 30 left x right y { x y "lt" }
- def "<=" precedence 30 left x right y { x y "le" }
- def ">" precedence 30 left x right y { x y "gt" }
- def ">=" precedence 30 left x right y { x y "ge" }
- def not precedence 25 right y { y "not" }
- def and precedence 24 left x right y { x y "and" }
- def xor precedence 23 left x right y { x y "xor" }
- def or precedence 22 left x right y { x y "or" }
- def if
- named cond { true }
- named then {}
- named else {}
- { cond "{" then "} {" else "} ifelse" }
- def xloop
- named from { 0 }
- named to { 0 }
- named by { 1 }
- named do named x { "xval" } {}
- { from by to "{ /xval exch def" do "} for" }
- def yloop
- named from { 0 }
- named to { 0 }
- named by { 1 }
- named do named y { "yval" } {}
- { from by to "{ /yval exch def" do "} for" }
- def zloop
- named from { 0 }
- named to { 0 }
- named by { 1 }
- named do named z { "zval" } {}
- { from by to "{ /zval exch def" do "} for" }
-
- def @IfPt
- left no
- right yes
- {
- points @Case {
- none @Yield no
- else @Yield yes
- }
- }
-
- def @Points
- {
- points @Case {
- none @Yield ""
- plus @Yield "plus"
- cross @Yield "cross"
- square @Yield "square"
- filledsquare @Yield "filledsquare"
- diamond @Yield "diamond"
- filleddiamond @Yield "filleddiamond"
- circle @Yield "circle"
- filledcircle @Yield "filledcircle"
- triangle @Yield "triangle"
- filledtriangle @Yield "filledtriangle"
- }
- }
-
- def @Pairs
- {
- pairs @Case {
- none @Yield {}
- solid @Yield { "linesetup solid" @IfPt "ilinesetup solid" }
- dashed @Yield { "linesetup cdashed" @IfPt "ilinesetup dashed" }
- dotted @Yield { "linesetup dotted" @IfPt "ilinesetup dotted" }
- dotdashed @Yield { "linesetup dotcdashed" @IfPt
- "ilinesetup dotdashed" }
- dotdotdashed @Yield { "linesetup dotdotcdashed" @IfPt
- "ilinesetup dotdotdashed" }
- dotdotdotdashed @Yield { "linesetup dotdotdotcdashed" @IfPt
- "ilinesetup dotdotdotdashed" }
- surfacexhisto @Yield { "surfacexhisto" }
- surfaceyhisto @Yield { "surfaceyhisto" }
- xhisto @Yield { "xhisto" }
- yhisto @Yield { "yhisto" }
- filledxhisto @Yield { "filledxhisto" }
- filledyhisto @Yield { "filledyhisto" }
- }
- }
-
- def @DataFormat
- {
- dataformat @Case {
- xandy @Yield xandy
- swapxandy @Yield swapxandy
- yonly @Yield yonly
- xonly @Yield xonly
- }
- }
-
- def @Paint
- {
- paint @Case {
- { none no No } @Yield "false"
- { yes Yes } @Yield "true"
- }
- }
-
- "[ [" data "]" dataformat
- "{" @Points "}"
- "{" @Pairs "}"
- "{ /dashlength" dashlength "def"
- " /linewidth" linewidth "def" @ColourCommand colour
- " /symbolsize" symbolsize "def }"
- "{" @Paint "}"
- "{" texture "}"
- "]"
- }
-
- def @Style
- {
- style @Case {
- frame @Yield { "framestyle" }
- none @Yield { "nonestyle" }
- axes @Yield { "axesstyle" }
- }
- }
-
- def @XExtra
- {
- xextra @Case {
- "none" @Yield {
- style @Case {
- frame @Yield { "0.5 cm" }
- none @Yield { "0" }
- axes @Yield { "0" }
- }
- }
- else @Yield xextra
- }
- }
-
- def @YExtra
- {
- yextra @Case {
- "none" @Yield {
- style @Case {
- frame @Yield { "0.5 cm" }
- none @Yield { "0" }
- axes @Yield { "0" }
- }
- }
- else @Yield yextra
- }
- }
-
- def @XDecreasing
- {
- xdecreasing @Case {
- { No no } @Yield "false"
- { Yes yes } @Yield "true"
- }
- }
-
- def @YDecreasing
- {
- ydecreasing @Case {
- { No no } @Yield "false"
- { Yes yes } @Yield "true"
- }
- }
-
- @AddCaptions width @Wide height @High
- @BackEnd @Case {
- PostScript @Yield {
- {
- "grestore"
- save @Case { { Yes yes } @Yield "save" else @Yield {} }
- "gsave xsize ysize lgraphdict begin /ysize exch def /xsize exch def"
- "/alldata [" @Body "] def"
- xticksep "[" xticks "] 0 alldata" xmin xmax xlog
- @XExtra @XDecreasing xorigin xticklength "xset"
- yticksep "[" yticks "] 1 alldata" ymin ymax ylog
- @YExtra @YDecreasing yorigin yticklength "yset"
-
- rticks @Case {
-
- "" @Yield "norset"
-
- else @Yield {
- rticksep "[" rticks "] 1 alldata" ymin ymax ylog
- @YExtra @YDecreasing yorigin rticklength "rset"
- }
- }
-
- "rundata" @Style // "end"
- save @Case { { Yes yes } @Yield "restore" else @Yield {} }
- } @Graphic { //1rt objects }
- }
- PDF @Yield { {"% @Graph UNIMPLEMENTED"} @Graphic { //1rt objects } }
- }
-
-@End @Graph
diff --git a/include/save_graphf.lpg b/include/save_graphf.lpg
deleted file mode 100644
index 5546586..0000000
--- a/include/save_graphf.lpg
+++ /dev/null
@@ -1,899 +0,0 @@
-%%BeginResource: procset LoutGraphPrependGraphic
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% %
-% PostScript @SysPrependGraphic file for @Graph (Version 1.0) %
-% %
-% Version 1.0 by Jeffrey H. Kingston, December 1993. %
-% swapxandy added September 2001 by JHK. %
-% %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-errordict begin
- /handleerror
- {
- { /Times-Roman findfont 8 pt scalefont setfont
- 0 setgray 4 pt 4 pt moveto
- $error /errorname get
- dup lgraphdict exch known
- { lgraphdict exch get }
- { 30 string cvs } ifelse
- show
- ( Command: ) show
- $error /command get 30 string cvs show
- } stopped {} if
- showpage stop
- } def
-end
-
-/lgraphdict 200 dict def
-lgraphdict begin
-
-% error messages
-/dictfull (dictfull error) def
-/dictstackoverflow (dictstackoverflow error) def
-/execstackoverflow (execstackoverflow error: expression too complex?) def
-/limitcheck (limitcheck error: graph too complex or too large?) def
-/syntaxerror (syntaxerror error: syntax error in text of graph?) def
-/typecheck (typecheck error: syntax error in text of graph?) def
-/undefined (undefined error: unknown or misspelt symbol?) def
-/rangecheck (rangecheck error: undefined expression (e.g. divide by zero)?) def
-/VMError (VMError error: run out of memory?) def
-
-% random number between x and y inclusive: x y dorand num
-/dorand { 1 index sub 1 add rand exch mod add } def
-
-% log to given base: base num dolog num
-/dolog { ln exch ln div } def
-
-% maximum of two numbers: <num> <num> max <num>
-/max { 2 copy gt { pop } { exch pop } ifelse } def
-
-% add two points: <point> <point> padd <point>
-/padd { exch 3 1 roll add 3 1 roll add exch } def
-
-% subtract first point from second: <point> <point> psub <point>
-/psub { 3 2 roll sub 3 1 roll exch sub exch } def
-
-% distance between two points: <point> <point> distance <length>
-/distance { psub dup mul exch dup mul add sqrt } def
-
-% point at angle and distance: <point> <length> <angle> atangle <point>
-/atangle { 2 copy cos mul 3 1 roll sin mul padd } def
-
-% angle from one point to another: <point> <point> angle <angle>
-/angle { psub 2 copy 0 eq exch 0 eq and {pop} {exch atan} ifelse } def
-
-
-% set up for line
-% - linesetup <length> <dashlength>
-/linesetup
-{ newpath
- xcurr ycurr trpoint xprev yprev trpoint
- 4 copy moveto lineto distance dashlength
-} def
-
-% set up for icon-avoiding line
-% - ilinesetup <length> <dashlength>
-/ilinesetup
-{ newpath
- xprev yprev trpoint xcurr ycurr trpoint 4 copy
- 4 copy angle symbolsize 1.5 mul exch 4 2 roll pop pop atangle
- 6 2 roll 4 2 roll
- 4 copy angle symbolsize 1.5 mul exch 4 2 roll pop pop atangle
- 4 copy moveto lineto distance dashlength
-} def
-
-
-% stroke a solid line: <length> <dashlength> solid -
-/solid
-{ pop pop [] 0 setdash linewidth setlinewidth stroke
-} def
-
-% stroke a dashed line: <length> <dashlength> dashed -
-/dashed
-{ 2 copy 2 mul le 1 index 0 le or
- { exch pop 1 pt max [ exch dup ] 0 setdash }
- { dup [ exch 4 2 roll 2 copy div
- 1 sub 2 div ceiling dup 4 1 roll
- 1 add mul sub exch div ] 0 setdash
- } ifelse linewidth setlinewidth stroke
-} def
-
-% stroke a cdashed line: <length> <dashlength> cdashed -
-/cdashed
-{ 2 copy le 1 index 0 le or
- { exch pop 1 pt max [ exch dup ] dup 0 get 2 div setdash }
- { dup [ 4 2 roll exch 2 copy exch div
- 2 div ceiling div 1 index sub
- ] exch 2 div setdash
- } ifelse linewidth setlinewidth stroke
-} def
-
-% stroke a dotted line: <length> <dashlength> dotted -
-/dotted
-{ 2 copy le 1 index 0 le or
- { exch pop 1 pt max [ exch 0 exch ] 0 setdash }
- { 1 index exch div ceiling div 0.99999 mul
- [ 0 3 2 roll ] 0 setdash
- } ifelse gsave 1 setlinecap linewidth setlinewidth stroke grestore newpath
-} def
-
-% stroke a noline line: <length> <dashlength> noline -
-/noline
-{ pop pop
-} def
-
-% scale array elements by factor: <array> <factor> scalearray <array>
-/scalearray
-{
- [ exch 3 2 roll
- { exch dup 3 1 roll mul exch } forall
- pop ]
-} def
-
-% sum array elements: <array> sumarray <number>
-/sumarray
-{
- 0 exch { add } forall
-} def
-
-% begin a more complex line: <length> <dashlength> linebegin -
-/linebegin
-{
- % (Entering linebegin) 2 debugprint
- 20 dict begin
- /dashlen exch 1 pt max def
- /len exch def
- /gap dashlen def
- /halfgap dashlen 2 div def
- /dash dashlen def
- /halfdash dashlen 2 div def
- /dot 0 def
- % (Leaving linebegin) 0 debugprint
-} def
-% end a more complex line: <linecap> <cycle> <startpos> <stoppos> lineend -
-/lineend
-{
- % (Entering lineend) 3 debugprint
- /stoppos exch def
- /startpos exch def
- /cycle exch def
- /linecap exch def
- /stopposlen stoppos sumarray def
- /startposlen startpos sumarray def
- /cyclelen cycle sumarray def
- /effectivelen len startposlen add stopposlen sub def
- effectivelen 0 gt cyclelen 0 gt and
- {
- /repeats effectivelen cyclelen div ceiling def
- /factor len repeats cyclelen mul startposlen sub stopposlen add div def
- cycle factor scalearray startposlen factor mul setdash
- linecap setlinecap stroke
- } if
- end
- % (Leaving lineend) 0 debugprint
-} def
-
-% stroke a dotdashed line: <length> <dashlength> dotdashed -
-/dotdashed
-{
- linebegin
- 1 [dash gap dot gap] [] [dash]
- lineend
-} def
-
-% stroke a dotcdashed line: <length> <dashlength> dotcdashed -
-/dotcdashed
-{
- linebegin
- 1 [dash gap dot gap] [halfdash] [halfdash]
- lineend
-} def
-
-% stroke a dotdotdashed line: <length> <dashlength> dotdotdashed -
-/dotdotdashed
-{
- linebegin
- 1 [dash gap dot gap dot gap] [] [dash]
- lineend
-} def
-
-% stroke a dotdotcdashed line: <length> <dashlength> dotdotcdashed -
-/dotdotcdashed
-{
- linebegin
- 1 [dash gap dot gap dot gap] [halfdash] [halfdash]
- lineend
-} def
-
-% stroke a dotdotdotdashed line: <length> <dashlength> dotdotdotdashed -
-/dotdotdotdashed
-{
- linebegin
- 1 [dash gap dot gap dot gap dot gap] [] [dash]
- lineend
-} def
-
-% stroke a dotdotdotcdashed line: <length> <dashlength> dotdotdotcdashed -
-/dotdotdotcdashed
-{
- linebegin
- 1 [dash gap dot gap dot gap dot gap] [halfdash] [halfdash]
- lineend
-} def
-
-
-% stroke a y histogram: - yhisto -
-/yhisto
-{ xprev yleft trpoint yextra sub moveto
- xprev yprev trpoint lineto
- xcurr yprev trpoint lineto
- xcurr yleft trpoint yextra sub lineto
- linewidth setlinewidth stroke
-} def
-
-% stroke an x histogram: - xhisto -
-/xhisto
-{ xleft yprev trpoint exch xextra sub exch moveto
- xcurr yprev trpoint lineto
- xcurr ycurr trpoint lineto
- xleft ycurr trpoint exch xextra sub exch lineto
- linewidth setlinewidth stroke
-} def
-
-% stroke a surface y histogram: - surfaceyhisto -
-/surfaceyhisto
-{ firstpair
- { xprev yleft trpoint yextra sub moveto
- xprev yprev trpoint lineto
- }
- { xprev yprev trpoint moveto
- } ifelse
- xcurr yprev trpoint lineto
- lastpair
- { xcurr yleft trpoint yextra sub lineto
- }
- { xcurr ycurr trpoint lineto
- } ifelse
- linewidth setlinewidth stroke
-} def
-
-% stroke a surface x histogram: - surfacexhisto -
-/surfacexhisto
-{ firstpair
- { xleft yprev trpoint exch xextra sub exch moveto
- }
- { xprev yprev trpoint moveto
- } ifelse
- xcurr yprev trpoint lineto
- xcurr ycurr trpoint lineto
- lastpair
- { xleft ycurr trpoint exch xextra sub exch lineto
- } if
- linewidth setlinewidth stroke
-} def
-
-% % pre-texture versions
-% % stroke a filled y histogram: - filledyhisto -
-% /filledyhisto
-% {
-% linewidth setlinewidth
-% xprev yleft trpoint exch currentlinewidth 2 div add exch yextra sub moveto
-% xprev yprev trpoint exch currentlinewidth 2 div add exch lineto
-% xcurr yprev trpoint exch currentlinewidth 2 div sub exch lineto
-% xcurr yleft trpoint exch currentlinewidth 2 div sub exch yextra sub lineto
-% closepath fill
-% } def
-
-% % stroke a filled x histogram: - filledxhisto -
-% /filledxhisto
-% {
-% linewidth setlinewidth
-% xleft yprev trpoint currentlinewidth 2 div add exch xextra sub exch moveto
-% xcurr yprev trpoint currentlinewidth 2 div add lineto
-% xcurr ycurr trpoint currentlinewidth 2 div sub lineto
-% xleft ycurr trpoint currentlinewidth 2 div sub exch xextra sub exch lineto
-% closepath fill
-% } def
-
-% stroke a filled y histogram: - filledyhisto -
-/filledyhisto
-{
- linewidth setlinewidth
- xprev yleft trpoint exch currentlinewidth 1.3 mul add exch yextra sub moveto
- xprev yprev trpoint exch currentlinewidth 1.3 mul add exch lineto
- xcurr yprev trpoint exch currentlinewidth 1.3 mul sub exch lineto
- xcurr yleft trpoint exch currentlinewidth 1.3 mul sub exch yextra sub lineto
- gsave texture fill grestore stroke
-} def
-
-% stroke a filled x histogram: - filledxhisto -
-/filledxhisto
-{
- linewidth setlinewidth
- xleft yprev trpoint currentlinewidth 1.3 mul add exch xextra sub exch moveto
- xcurr yprev trpoint currentlinewidth 1.3 mul add lineto
- xcurr ycurr trpoint currentlinewidth 1.3 mul sub lineto
- xleft ycurr trpoint currentlinewidth 1.3 mul sub exch xextra sub exch lineto
- gsave texture fill grestore stroke
-} def
-
-
-% cross: show a small cross
-/cross
-{ newpath
- xcurr ycurr trpoint moveto
- symbolsize neg symbolsize neg rmoveto
- symbolsize 2 mul symbolsize 2 mul rlineto
- 0 symbolsize -2 mul rmoveto
- symbolsize -2 mul symbolsize 2 mul rlineto
- [] 0 setdash stroke
-} def
-
-% plus: show a small plus
-/plus
-{ newpath
- xcurr ycurr trpoint moveto
- symbolsize neg 0 rmoveto
- symbolsize 2 mul 0 rlineto
- symbolsize neg symbolsize neg rmoveto
- 0 symbolsize 2 mul rlineto
- [] 0 setdash stroke
-} def
-
-% square: show a small square
-/square
-{ newpath
- xcurr ycurr trpoint moveto
- symbolsize neg symbolsize neg rmoveto
- symbolsize 2 mul 0 rlineto
- 0 symbolsize 2 mul rlineto
- symbolsize -2 mul 0 rlineto
- closepath [] 0 setdash stroke
-} def
-
-% filledsquare: show a small filled square
-/filledsquare
-{ newpath
- xcurr ycurr trpoint moveto
- symbolsize neg symbolsize neg rmoveto
- symbolsize 2 mul 0 rlineto
- 0 symbolsize 2 mul rlineto
- symbolsize -2 mul 0 rlineto
- closepath gsave [] 0 setdash stroke grestore fill
-} def
-
-% diamond: show a small diamond
-/diamond
-{ newpath
- xcurr ycurr trpoint moveto
- symbolsize neg 0 rmoveto
- symbolsize symbolsize neg rlineto
- symbolsize symbolsize rlineto
- symbolsize neg symbolsize rlineto
- closepath [] 0 setdash stroke
-} def
-
-% filleddiamond: show a small filled diamond
-/filleddiamond
-{ newpath
- xcurr ycurr trpoint moveto
- symbolsize neg 0 rmoveto
- symbolsize symbolsize neg rlineto
- symbolsize symbolsize rlineto
- symbolsize neg symbolsize rlineto
- closepath gsave [] 0 setdash stroke grestore fill
-} def
-
-% circle: show a small circle
-/circle
-{ newpath
- xcurr ycurr trpoint symbolsize 0 360 arc [] 0 setdash stroke
-} def
-
-% filledcircle: show a small filled circle
-/filledcircle
-{ newpath
- xcurr ycurr trpoint symbolsize 0 360 arc gsave [] 0 setdash stroke grestore fill
-} def
-
-% triangle: show a small triangle
-/triangle
-{ newpath
- xcurr ycurr trpoint moveto
- 0 symbolsize 1.5 mul rmoveto
- symbolsize neg symbolsize -2.5 mul rlineto
- symbolsize 2 mul 0 rlineto
- closepath [] 0 setdash stroke
-} def
-
-% filledtriangle: show a small filled triangle
-/filledtriangle
-{ newpath
- xcurr ycurr trpoint moveto
- 0 symbolsize 1.5 mul rmoveto
- symbolsize neg symbolsize -2.5 mul rlineto
- symbolsize 2 mul 0 rlineto
- closepath gsave [] 0 setdash stroke grestore fill
-} def
-
-
-%plog: like log only with a base, and protected from failing if <= 0
-% base x plog res
-/plog { dup 0 le { pop pop 0 } { ln exch ln div } ifelse } def
-
-% xtr: transform one x value logarithmically if xlog > 1
-% <num> xtr <num>
-/xtr
-{ xlog 1 gt
- { xlog exch plog
- } if
-} def
-
-% ytr: transform one y value logarithmically if ylog > 1
-% <num> ytr <num>
-/ytr
-{ ylog 1 gt
- { ylog exch plog
- } if
-} def
-
-
-% trpoint: transform (x, y) in graph space into (x', y') in print space
-% x y trpoint x' y'
-/trpoint
-{ exch xtr xdecr { trxmax exch sub } { trxmin sub } ifelse
- trxmax trxmin sub div xwidth mul xextra add
-
- exch ytr ydecr { trymax exch sub } { trymin sub } ifelse
- trymax trymin sub div ywidth mul yextra add
-} def
-
-
-% yonly: interpolate x values 1, 2, ... into data
-% [ data ] yonly [ newdata ]
-/yonly
-{ dup /tmp exch def
- length [ exch 1 exch 1 exch
- { dup tmp exch 1 sub get
- } for
- ]
-} def
-
-% xonly: interpolate y values 1, 2, ... into data
-% [ data ] yonly [ newdata ]
-/xonly
-{ dup /tmp exch def
- length [ exch 1 exch 1 exch
- { dup tmp exch 1 sub get exch
- } for
- ]
-} def
-
-% xandy: no interpolation of x or y values
-% [ data ] xandy [ data ]
-/xandy {} def
-
-% swapxandy: swap x and y values
-% [ data ] swapxandy [ data ]
-/swapxandy
-{ dup /tmp exch def
- length [ exch 2 exch 2 exch
- { dup tmp exch 1 sub get exch 2 sub tmp exch get
- } for
- ]
-} def
-
-
-% expstringwidth: calculate width of string containing optional exponent
-% <string> expstringwidth <width>
-/expstringwidth
-{ (^) search
- { exch pop stringwidth pop exch stringwidth pop 0.7 mul add }
- { stringwidth pop }
- ifelse
-} def
-
-% expstringshow: show string containing optional exponent
-% <string> expstringshow -
-/expstringshow
-{ (^) search
- { exch pop show 0 0.5 ft rmoveto
- gsave currentfont 0.7 scalefont setfont show grestore
- }
- { show
- }
- ifelse
-} def
-
-% concatenate two strings: <string> <string> strconcat <string>
-/strconcat
-{ 2 copy length exch length add string
- dup 0 4 index putinterval
- dup 3 index length 3 index putinterval
- 3 1 roll pop pop
-} def
-
-% lgen: generate one label automatically
-% num lgen num string
-/lgen { dup 20 string cvs } def
-
-% loglgen: generate one logarithmic label (with exponent)
-% <base> <exponent> loglgen <string>
-/loglgen
-{ 20 string cvs exch 20 string cvs
- (^) strconcat exch strconcat
-} def
-
-
-% printxtick: print one x tick
-% xpos printxtick -
-/printxtick
-{ newpath
- yleft trpoint moveto 0 yextra neg rmoveto
- 0 xticklength neg rlineto [] 0 setdash stroke
-} def
-
-% printxlabel: print one x label
-% (xlabel) xpos printxlabel -
-/printxlabel
-{ yleft trpoint moveto 0 yextra neg rmoveto
- 0 xticklength neg rmoveto 0 0.9 ft neg rmoveto
- xlog 1 gt { 0 0.3 ft neg rmoveto } if
- dup expstringwidth -2 div 0 rmoveto expstringshow
-} def
-
-% printytick: print one y tick
-% ypos printytick -
-/printytick
-{ newpath
- xleft exch trpoint moveto xextra neg 0 rmoveto
- yticklength neg 0 rlineto [] 0 setdash stroke
-} def
-
-% printylabel: print one y label
-% (ylabel) ypos printylabel -
-/printylabel
-{ xleft exch trpoint moveto xextra neg 0 rmoveto
- yticklength neg 0 rmoveto -0.3 ft -0.3 ft rmoveto
- dup expstringwidth neg 0 rmoveto expstringshow
-} def
-
-% printrtick: print one r tick
-% ypos printrtick -
-/printrtick
-{ newpath
- xright exch trpoint moveto xextra 0 rmoveto
- rticklength 0 rlineto [] 0 setdash stroke
-} def
-
-% printrlabel: print one r label
-% (rlabel) ypos printrlabel -
-/printrlabel
-{ xright exch trpoint moveto xextra 0 rmoveto
- rticklength 0 rmoveto 0.3 ft -0.3 ft rmoveto
- expstringshow
-} def
-
-% printticks: print ticks and labels
-% /tickproc /labelproc [ tickandlabeldata ] min printticks -
-/printticks
-{ /prev exch def
- { dup type dup dup /integertype eq exch /realtype eq or
- { pop dup /prev exch def 2 index cvx exec
- }
- { /stringtype eq
- { prev 2 index cvx exec
- }
- { pop
- } ifelse
- } ifelse
- } forall
- pop pop
-} def
-
-
-% printxaxistick: print one x axis tick
-% xpos printxaxistick -
-/printxaxistick
-{ newpath
- yaxis trpoint moveto 0 xticklength -2 div rmoveto
- 0 xticklength rlineto [] 0 setdash stroke
-} def
-
-% printxaxislabel: print one x axis label
-% (xlabel) xpos printxaxislabel -
-/printxaxislabel
-{ yaxis trpoint moveto
- 0 xticklength -2 div rmoveto 0 0.9 ft neg rmoveto
- xlog 1 gt { 0 0.3 ft neg rmoveto } if
- dup expstringwidth -2 div 0 rmoveto expstringshow
-} def
-
-% printyaxistick: print one y axis tick
-% ypos printyaxistick -
-/printyaxistick
-{ newpath
- xaxis exch trpoint moveto
- yticklength -2 div 0 rmoveto
- yticklength 0 rlineto [] 0 setdash stroke
-} def
-
-% printyaxislabel: print one y axis label
-% (ylabel) ypos printyaxislabel -
-/printyaxislabel
-{ xaxis exch trpoint moveto
- yticklength -2 div 0 rmoveto -0.3 ft -0.3 ft rmoveto
- dup expstringwidth neg 0 rmoveto expstringshow
-} def
-
-
-% <val> minmax -
-% perform minv := min(minv, val); maxv := max(maxv, val)
-% allowing for the possibility of minv, maxv, val being false (undefined)
-/minmax
-{ dup false eq
- { pop }
- { minv false eq
- { dup /minv exch def /maxv exch def }
- { dup minv lt
- { /minv exch def }
- { dup maxv gt
- { /maxv exch def }
- { pop }
- ifelse
- } ifelse
- } ifelse
- } ifelse
-} def
-
-% <ticks> ticksundef <ticks> <bool>
-% returns true iff the ticks array is undefined (one false entry)
-/ticksundef
-{ dup length 1 eq
- { dup 0 get false eq
- }
- { false }
- ifelse
-} def
-
-% <number> integral <boolean>
-% true if the number has an integral value
-/integral { dup round eq } def
-
-% ticksep ticks xory alldata minval maxval axis base ticksandlimits ticks min max base
-% ticksandlimits: sort out value of x or y ticks and limits and log base
-/ticksandlimits
-{ /base exch def
- /minv false def
- /maxv false def
-
- % min and max of user-supplied minval, maxval, and axis
- minmax minmax minmax
-
- % min and max of data points
- { 0 get dup dup length 1 sub 3 index exch 2 exch
- { get minmax dup
- } for pop pop
- } forall
- pop dup
-
- % min and max of tick values
- { dup type /stringtype eq
- { pop } { minmax } ifelse
- } forall
-
- % fix minv and maxv if undefined (false) or equal
- minv false eq
- { /minv -1 def /maxv 1 def }
- { minv maxv eq
- { minv 0 lt
- { /minv 2 minv mul def /maxv 0 def
- }
- { minv 0 eq
- { /minv -1 def /maxv 1 def
- }
- { /minv 0 def /maxv 2 maxv mul def
- } ifelse
- } ifelse
- } if
- } ifelse
-
- % invent ticks if undefined
- ticksundef
- { pop /ticksep exch def
-
- % if base is reasonable and minv is positive, logarithmic ticks
- base 1 gt minv 0 gt and
- {
- % get integral log of minv and maxv
- /logminv base minv plog floor cvi def
- /logmaxv base maxv plog ceiling cvi def
-
- % if minv close to base, make it 1; reset minv and maxv
- logminv 1 eq logmaxv 4 ge and { /logminv 0 def } if
- /minv base logminv exp def
- /maxv base logmaxv exp def
-
- % ticks := [ base**logminv, ... , base**logmaxv ]
- [ logminv 1 logmaxv
- { dup base exch exp
- exch base exch loglgen
- } for
- ]
- }
- { % non-logarithmic ticks
- {
- % fix tick separation if undefined (0) or too small
- /base 0 def
- /delta maxv minv sub def
- ticksep delta 30 div le
- { /ticksep 10 delta log 1 sub ceiling exp def
- ticksep delta 2 div ge
- { /ticksep ticksep 2 div def }
- { ticksep delta 5 div lt
- { /ticksep 2 ticksep mul def
- } if
- } ifelse
- } if
-
- % adjust minv and maxv to be multiples of ticksep
- /minv minv ticksep div floor ticksep mul def
- /maxv maxv ticksep div ceiling ticksep mul def
- /delta maxv minv sub def
-
- % if minv or maxv near zero, move to zero and redo
- minv ticksep eq
- { /minv 0 def }
- { maxv ticksep neg eq { /maxv 0 def } { exit } ifelse
- } ifelse
- } loop
-
- % if minv, maxv, and ticksep are all integral, set "makeint" to true
- /makeint minv integral maxv integral ticksep integral and and def
-
- % ticks := [ minv, minv+ticksep, ... , maxv ]
- [ 0 1 delta ticksep div round
- { ticksep mul minv add makeint { cvi } if lgen }
- for
- ]
- } ifelse
- }
- { exch pop
- } ifelse
- minv maxv base
-} def
-
-% xset: set up all data for x axis, including limits and ticks
-% xticksep xticks 0 alldata xmin xmax xlog xextra xdecr xaxis xticklength xset -
-/xset
-{ /xticklength exch def
- /xaxis exch def
- /xdecr exch def
- /xextra exch def
- xaxis exch ticksandlimits
- /xlog exch def /xmax exch def /xmin exch def /xticks exch def
- /xleft xdecr { xmax } { xmin } ifelse def
- /xright xdecr { xmin } { xmax } ifelse def
- /xwidth xsize xextra 2 mul sub def
- /trxmin xmin xtr def /trxmax xmax xtr def
-} def
-
-% yset: set up all data for y axis, including limits and yticks
-% yticksep yticks 0 alldata ymin ymax ylog yextra ydecr yaxis yticklength yset -
-/yset
-{ /yticklength exch def
- /yaxis exch def
- /ydecr exch def
- /yextra exch def
- yaxis exch ticksandlimits
- /ylog exch def /ymax exch def /ymin exch def /yticks exch def
- /yleft ydecr { ymax } { ymin } ifelse def
- /yright ydecr { ymin } { ymax } ifelse def
- /ywidth ysize yextra 2 mul sub def
- /trymin ymin ytr def /trymax ymax ytr def
-} def
-
-% rset: set up all data for y axis (again), but including limits and rticks
-% rticksep rticks 0 alldata ymin ymax ylog yextra ydecr yaxis rticklength rset -
-/rset
-{ /rticklength exch def
- /yaxis exch def
- /ydecr exch def
- /yextra exch def
- yaxis exch ticksandlimits
- /ylog exch def /ymax exch def /ymin exch def /rticks exch def
- /yleft ydecr { ymax } { ymin } ifelse def
- /yright ydecr { ymin } { ymax } ifelse def
- /ywidth ysize yextra 2 mul sub def
- /trymin ymin ytr def /trymax ymax ytr def
-} def
-
-% norset: set up data for no rticks
-% - norset -
-/norset
-{ /rticklength 0 def
- /rticks [] def
-} def
-
-% framestyle: print a frame around the graph
-/framestyle
-{ 0 0 moveto xsize 0 lineto xsize ysize lineto
- 0 ysize lineto closepath stroke
- /printxtick /printxlabel xticks xleft printticks
- /printytick /printylabel yticks ymin printticks
- /printrtick /printrlabel rticks ymin printticks
-} def
-
-% nonestyle: print nothing around the graph
-/nonestyle
-{
-} def
-
-% axesstyle: print axes for the graph (unless axis values missing)
-/axesstyle
-{
- xaxis false eq yaxis false eq or
- { framestyle }
- { xaxis yaxis trpoint dup 0 exch moveto xsize exch lineto
- dup 0 moveto ysize lineto stroke
- /printxaxistick /printxaxislabel xticks xleft printticks
- /printyaxistick /printyaxislabel yticks ymin printticks
- } ifelse
-} def
-
-% rundata: run all data sets
-/rundata
-{ alldata
- { gsave
- dup dup dup dup dup
- 5 get /texture exch def
- 4 get /dopaint exch def
- 3 get /initrun exch def
- 2 get /pairs exch def
- 1 get /points exch def
- 0 get /data exch def
- dopaint
- { data length 4 ge
- {
- gsave
- initrun
- newpath
- data 0 get ymin trpoint yextra sub moveto
- 0 2 data length 2 sub
- { dup 1 add
- data exch get /ycurr exch def
- data exch get /xcurr exch def
- xcurr ycurr trpoint lineto
- } for
- data dup length 2 sub get ymin trpoint yextra sub lineto
- closepath texture fill
- grestore
- } if
- } if
- initrun
- data length 2 ge
- {
- /xcurr data 0 get def
- /ycurr data 1 get def
- points
- data length 4 ge
- { 2 2 data length 2 sub
- { /xprev xcurr def
- /yprev ycurr def
- dup dup 2 eq /firstpair exch def
- data length 2 sub eq /lastpair exch def
- dup 1 add
- data exch get /ycurr exch def
- data exch get /xcurr exch def
- pairs
- points
- } for
- } if
- } if
- grestore
- } forall
-} def
-
-end
-%%EndResource
diff --git a/include/slides b/include/slides
index b3fb95c..14de206 100644
--- a/include/slides
+++ b/include/slides
@@ -3,7 +3,6 @@
# Lout setup file for overhead transparencies #
# #
# Jeffrey H. Kingston #
-# 5 February 1999 #
# #
###############################################################################
@@ -63,6 +62,9 @@
# @ListIndent { 0s } # indent of list items
# @ListRightIndent { 0s } # right indent of list items
# @ListLabelWidth { 2.00f @OrIfPlain 5s } # width allowed for list tags
+ # @ListLabelRight { No } # right-adjust list labels
+ # @ListLabelRightGap { 2s } # gap when right-adjusting
+ # @ListBreak { } # break style of list items
# @NumberSeparator { . } # separates nums like 2.3.7
# @CrossLinkFormat { @Body } # format of cross links
# @ExternalLinkFormat { @Body } # format of external links
@@ -332,7 +334,11 @@
# @OverheadNumbers { Arabic } # kind of overhead numbers
# @FirstOverheadNumber { 1 } # first overhead num
# @TitlePageFont { Helvetica Base 1.5f } # title page font
- # @LectureHeadingFont { Bold 1.20f } # lecture head font
+ # @AboveTitleGap { 0.5i } # gap above title
+ # @AboveAuthorGap { 1.0i } # gap above author
+ # @AboveInstitutionGap { 0.5i } # gap above inst
+ # @AboveDateLineGap { 0.5i } # gap above date
+ # @LectureHeadingFont { Bold 1.2f } # lecture head font
# @LectureHeadingBreak { clines 1.2fx nohyphen } # lecture head break
# @LectureHeadingFormat { @Centre number @DP @Centre title @DP }
# @AboveLectureGap { 3.0f } # gap above lec head
diff --git a/include/slidesf b/include/slidesf
index 5194ff6..a0d69bd 100644
--- a/include/slidesf
+++ b/include/slidesf
@@ -4,7 +4,6 @@
# @OverheadSetup extension to @DocumentSetup. #
# #
# Jeffrey H. Kingston #
-# August 1994 #
# #
# This package extends DocumentSetup with definitions for overheads. #
# #
@@ -22,7 +21,11 @@ def @OverheadSetup
named @OverheadNumbers { Arabic }
named @FirstOverheadNumber { 1 }
named @TitlePageFont { Helvetica Base }
- named @LectureHeadingFont { Bold 1.20f }
+ named @AboveTitleGap { 0.5i }
+ named @AboveAuthorGap { 1.0i }
+ named @AboveInstitutionGap { 0.5i }
+ named @AboveDateLineGap { 0.5i }
+ named @LectureHeadingFont { Bold 1.2f }
named @LectureHeadingBreak { 1.2fx nohyphen }
named @LectureHeadingFormat
left number right title { @Centre number @DP @Centre title @DP }
@@ -149,11 +152,12 @@ def @OverheadSetup
{
@TitlePageFont @Font @InitialBreak @Break
@InitialSpace @Space clines @Break {
- //0.5i |0.5rt 1.5f @Font @InitialBreak @Break
- @InitialSpace @Space clines @Break @Title |
- //1i |0.5rt clines @Break @Author |
- //0.5i |0.5rt clines @Break @I @Institution |
- //0.5i @DatePart
+ //0.5i
+ //@AboveTitleGap |0.5rt 1.5f @Font @InitialBreak @Break
+ @InitialSpace @Space clines @Break @Title |
+ //@AboveAuthorGap |0.5rt clines @Break @Author |
+ //@AboveInstitutionGap |0.5rt clines @Break @I @Institution |
+ //@AboveDateLineGap @DatePart
}
}
diff --git a/include/xind b/include/xind
deleted file mode 100644
index aeade1e..0000000
--- a/include/xind
+++ /dev/null
@@ -1 +0,0 @@
- # @IndexRangeFormat { @From--@To } # index page range format
diff --git a/include/xinda b/include/xinda
deleted file mode 100644
index c27301b..0000000
--- a/include/xinda
+++ /dev/null
@@ -1 +0,0 @@
- # @IndexARangeFormat { @From--@To } # index page range format
diff --git a/include/xindb b/include/xindb
deleted file mode 100644
index 32583e8..0000000
--- a/include/xindb
+++ /dev/null
@@ -1 +0,0 @@
- # @IndexBRangeFormat { @From--@To } # index page range format