Advertisement
Guest User

Untitled

a guest
Jun 18th, 2019
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. begin{luacode*}
  2. function doline(line)
  3. local splitpoint = string.find(line, "=")
  4. local title = line:sub(1, splitpoint-1)
  5. local description = string.gsub(line:sub(splitpoint + 1), "\par", "n")
  6. tex.print(title)
  7. for token in string.gmatch(description, "[^n]+") do
  8. tex.print("&\multicolumn{4}{p{11cm}}{" .. token .. "}\\[2pt]")
  9. end
  10. tex.print("\hline")
  11. end
  12. end{luacode*}
  13. newcommand{tabularline}[1]{%
  14. directlua{
  15. doline("luatexluaescapestring{detokenize{#1}}")
  16. }}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement