• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

sile-typesetter / sile / 9507147410

13 Jun 2024 09:40PM UTC coverage: 50.521% (-18.7%) from 69.177%
9507147410

push

github

web-flow
Merge pull request #2062 from alerque/plug-fluent-leak

Link document.language setting more closely with Fluent locale

15 of 15 new or added lines in 3 files covered. (100.0%)

3244 existing lines in 65 files now uncovered.

8586 of 16995 relevant lines covered (50.52%)

4659.09 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/packages/raiselower/init.lua
UNCOV
1
local base = require("packages.base")
×
2

UNCOV
3
local package = pl.class(base)
×
UNCOV
4
package._name = "raiselower"
×
5

6
local function raise (height, content)
UNCOV
7
   SILE.typesetter:pushHbox({
×
8
      outputYourself = function (_, typesetter, _)
UNCOV
9
         typesetter.frame:advancePageDirection(-height)
×
10
      end,
11
   })
UNCOV
12
   SILE.process(content)
×
UNCOV
13
   SILE.typesetter:pushHbox({
×
14
      outputYourself = function (_, typesetter, _)
UNCOV
15
         typesetter.frame:advancePageDirection(height)
×
16
      end,
17
   })
18
end
19

UNCOV
20
function package:registerCommands ()
×
UNCOV
21
   self:registerCommand("raise", function (options, content)
×
UNCOV
22
      local height = SU.cast("measurement", options.height)
×
UNCOV
23
      raise(height:absolute(), content)
×
UNCOV
24
   end, "Raises the contents of the command by the amount specified in the <height> option")
×
25

UNCOV
26
   self:registerCommand("lower", function (options, content)
×
UNCOV
27
      local height = SU.cast("measurement", options.height)
×
UNCOV
28
      raise(-height:absolute(), content)
×
UNCOV
29
   end, "Lowers the contents of the command by the amount specified in the <height> option")
×
30
end
31

32
package.documentation = [[
33
\begin{document}
34
If you don’t want your images, rules, or text to be placed along the baseline, you can use the \autodoc:package{raiselower} package to move them up and down.
35

36
It provides two simple commands, \autodoc:command{\raise} and \autodoc:command{\lower}, which both take a \autodoc:parameter{height=<dimension>} parameter.
37
They will respectively raise or lower their argument by the given height.
38
The raised or lowered content will not alter the height or depth of the line.
39

40
Here is some text raised by \raise[height=3pt]{three points}; here is some text lowered by \lower[height=4pt]{four points}.
41

42
The previous paragraph was generated by:
43

44
\begin[type=autodoc:codeblock]{raw}
45
Here is some text raised by \raise[height=3pt]{three points}; here is some text lowered by \lower[height=4pt]{four points}.
46
\end{raw}
47
\end{document}
UNCOV
48
]]
×
49

UNCOV
50
return package
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc