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

sile-typesetter / sile / 13989129417

21 Mar 2025 09:42AM UTC coverage: 30.742% (-29.5%) from 60.236%
13989129417

push

github

alerque
ci(actions): Use ICU 77 for macOS builds

6144 of 19986 relevant lines covered (30.74%)

1461.24 hits per line

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

74.51
/outputters/base.lua
1
--- SILE outputter class.
2
-- @interfaces outputters
3

4
local outputter = pl.class()
10✔
5
outputter.type = "outputter"
10✔
6
outputter._name = "base"
10✔
7

8
function outputter:_init ()
10✔
9
   self.hooks = {}
10✔
10
   return self
10✔
11
end
12

13
function outputter:registerHook (category, func)
10✔
14
   if not self.hooks[category] then
×
15
      self.hooks[category] = {}
×
16
   end
17
   table.insert(self.hooks[category], func)
×
18
end
19

20
function outputter:runHooks (category, data)
10✔
21
   if not self.hooks[category] then
10✔
22
      return nil
10✔
23
   end
24
   for _, func in ipairs(self.hooks[category]) do
×
25
      data = func(self, data)
×
26
   end
27
   return data
×
28
end
29

30
function outputter.newPage () end
10✔
31

32
function outputter:abort ()
10✔
33
   return self:finish() -- unless otherwise defined
×
34
end
35

36
function outputter:finish ()
10✔
37
   self:runHooks("prefinish")
×
38
end
39

40
function outputter.getCursor () end
10✔
41

42
function outputter.setCursor (_, _, _, _) end
10✔
43

44
function outputter.setColor () end
10✔
45

46
function outputter.pushColor () end
10✔
47

48
function outputter.popColor () end
10✔
49

50
function outputter.drawHbox (_, _, _) end
10✔
51

52
function outputter.setFont (_, _) end
10✔
53

54
function outputter.drawImage (_, _, _, _, _, _) end
10✔
55

56
function outputter.getImageSize (_, _) end
10✔
57

58
function outputter.drawSVG () end
10✔
59

60
function outputter.drawRule (_, _, _, _, _) end
10✔
61

62
function outputter.debugFrame (_, _, _) end
10✔
63

64
function outputter.debugHbox (_, _, _) end
10✔
65

66
function outputter.setLinkAnchor (_, _, _) end -- Unstable API
10✔
67

68
function outputter.beginLink (_, _, _) end -- Unstable API
10✔
69

70
function outputter.endLink (_, _, _, _, _, _, _) end -- Unstable API
10✔
71

72
function outputter.setMetadata (_, _, _) end
10✔
73

74
function outputter.setBookmark (_, _, _) end
10✔
75

76
function outputter.drawRaw (_) end
10✔
77

78
function outputter:getOutputFilename ()
10✔
79
   local fname
80
   if SILE.outputFilename then
10✔
81
      fname = SILE.outputFilename
10✔
82
   elseif SILE.input.filenames[1] then
×
83
      fname = pl.path.splitext(SILE.input.filenames[1])
×
84
      if self.extension then
×
85
         fname = fname .. "." .. self.extension
×
86
      end
87
   end
88
   if not fname then
10✔
89
      SU.error("Cannot guess output filename without an input name")
×
90
   end
91
   return fname
10✔
92
end
93

94
return outputter
10✔
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

© 2026 Coveralls, Inc