Skip to content

Commit

Permalink
Fix $show-print-page-numbers and $show-braille-page-numbers
Browse files Browse the repository at this point in the history
see #10
  • Loading branch information
bertfrees committed Apr 14, 2016
1 parent 807a4f3 commit 9a5a5e6
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 12 deletions.
32 changes: 21 additions & 11 deletions src/main/resources/css/default.scss
Original file line number Diff line number Diff line change
Expand Up @@ -23,24 +23,34 @@
@page frontmatter:right {
margin-bottom: 1;
@bottom-center {
content: string(running-footer);
content: string(running-footer);
}
}

@page bodymatter:right {
margin-bottom: 1;
@bottom-left {
content: "" string(print-page);
/* change to the following when string() supports it: */
/* content: "_" string(print-page, start-spread) "/" string(print-page, last-on-spread); */
/* this translates _x/ (single print page) as _x and _x/y (range) as a fraction: */
/* text-transform: print-page; */
}
@bottom-center {
content: string(running-footer);
content: string(running-footer);
}
}

@if $show-print-page-numbers {
@page bodymatter:right {
@bottom-left {
content: "" string(print-page);
/* change to the following when string() supports it: */
/* content: "_" string(print-page, start-spread) "/" string(print-page, last-on-spread); */
/* this translates _x/ (single print page) as _x and _x/y (range) as a fraction: */
/* text-transform: print-page; */
}
}
@bottom-right {
content: counter(page);
}

@if $show-braille-page-numbers {
@page bodymatter:right {
@bottom-right {
content: counter(page);
}
}
}

Expand Down
4 changes: 3 additions & 1 deletion src/test/xprocspec/test_dtbook-to-pef.xprocspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
xmlns:sbs="http://www.sbs.ch"
script="http://www.sbs.ch/pipeline/modules/braille/dtbook-to-pef.xpl">

<x:scenario label="list-numbering" pending="TODO: disable page numbers with option">
<x:scenario label="list-numbering">
<x:call step="sbs:dtbook-to-pef">
<x:input port="source">
<x:document type="inline">
Expand All @@ -25,6 +25,8 @@
</x:document>
</x:input>
<x:option name="contraction-grade" select="0"/>
<x:option name="show-print-page-numbers" select="false()"/>
<x:option name="show-braille-page-numbers" select="false()"/>
<x:option name="pef-output-dir" select="concat($temp-dir,'output-dir/list-numbering/')"/>
<x:option name="temp-dir" select="concat($temp-dir,'temp-dir/')"/>
</x:call>
Expand Down

0 comments on commit 9a5a5e6

Please sign in to comment.