Advertisement
Guest User

Untitled

a guest
Aug 28th, 2015
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.19 KB | None | 0 0
  1. documentclass{article}
  2. usepackage[paperheight=3in,paperwidth=5in]{geometry}
  3. usepackage{lipsum}
  4. usepackage{tcolorbox}
  5. newcounter{footnotecount} % Define counter
  6.  
  7. begin{document}
  8.  
  9. % The footnote is placed on the page where you place this:
  10. My global footnote is defined herefootnote{label{name}This is my global footnote.}
  11. % The label is required to refer to the footnote.
  12.  
  13. % Now, save your footnote counter before making any colorbox, because footnote counters are local for every box
  14. setcounter{footnotecount}{value{footnote}}% Store footnote counter
  15.  
  16. begin{tcolorbox}
  17. % Load the counter and refer to your global footnote
  18. setcounter{footnote}{value{footnotecount}}
  19. Second reference to global footnotefootnotemark[ref{name}]
  20. begin{tcolorbox}
  21. % It's still possible to use local footnotes, which by default (conveniently) uses letters in the tcolorbox environment
  22. A local footnotefootnote{This is a local footnote}
  23.  
  24. setcounter{footnote}{value{footnotecount}}
  25. Third reference to global footnotefootnotemark[ref{name}]
  26.  
  27. % Another local footnote, not disturbed by the counter of the global footnote:
  28. A local footnotefootnote{This is my second local footnote}
  29. end{tcolorbox}
  30. end{tcolorbox}
  31.  
  32. end{document}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement