aboutsummaryrefslogtreecommitdiffstats
path: root/include/eiffelf
diff options
context:
space:
mode:
Diffstat (limited to 'include/eiffelf')
-rw-r--r--include/eiffelf69
1 files changed, 47 insertions, 22 deletions
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