Hi I would like to make a cheat sheet and the contents are inside the boxes for each topic. I would that the width will be fix but the height will automatically adjust based on the length of the content and if it exceeds the page length it will continue to the next column. How can I do this?
Asked
Active
Viewed 1,299 times
6
lockstep
- 250,273
Don Thomas Reyes
- 73
- 4
-
Welcome! One possibility might be something like https://tex.stackexchange.com/questions/333338/typesetting-a-poster-with-content-boxes-flowing-through-columns/384672#384672 The boxes themselves wont break across columns though, but it's not entirely clear to me if you need that. – Torbjørn T. Aug 21 '17 at 11:05
-
I think flowfram was designed to handle this. – StrongBad Aug 21 '17 at 15:04
2 Answers
7
Another solution with tcolorbox, but with its new from version 4.10 poster library.
This library allows to flexibly place different boxes over an array structure. It's possible to say a certain column and/or row, but also make reference to other boxes. It's even possible to break a long tcolorbox in fragments placed over a sequence of places where text flows.
\documentclass{article}
\usepackage[a4paper,landscape]{geometry}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[most]{tcolorbox}
\usepackage{lipsum}
\begin{document}
\pagestyle{empty}
\begin{tcbposter}[
coverage ={spread},
poster = {%showframe,
columns=3, rows=3,},
boxes = {colframe=black, colback=white, enhanced, attach boxed title to top left={xshift=5mm, yshift*=-\tcboxedtitleheight/2},
boxed title style={colback=black, sharp corners}}
]
\posterbox[adjusted title=Biblioteca Random XYZ]{name=A,column=1,below=top}{\lipsum[1]}
\posterbox[adjusted title=Biblioteca Random XYZ]{name=B,column=1,below=A}{\lipsum[2]}
\posterbox[adjusted title=Biblioteca Random XYZ]{name=D,column=3,above=bottom}{\lipsum[2]}
\posterbox[adjusted title=Biblioteca Random XYZ]{name=C,
sequence=1 between B and bottom then
2 between top and bottom then
3 between top and D}{\lipsum[3-8]}
\end{tcbposter}
\end{document}
Ignasi
- 136,588
5
If you really need that the content continues in the next column, you could do it like this (I didn't fine tune the values, e.g. 9cm is not exact):
Create a content document with a paperwidth of 1/3 of your sheet with boxes which use the breakable key of tcolorbox:
\documentclass{article}
\usepackage{geometry}
\geometry{paperheight=21cm,paperwidth=9cm,margin=2mm}
\usepackage[many]{tcolorbox}
\usepackage{lipsum}
\tcbset{breakable}
\begin{document}\pagestyle{empty}
\begin{tcolorbox}[title=Stuff 1]
\lipsum[1]
\end{tcolorbox}
\begin{tcolorbox}[title=Stuff 2]
\lipsum[2]
\end{tcolorbox}
\begin{tcolorbox}[title=Stuff 3]
\lipsum[3]
\end{tcolorbox}
\begin{tcolorbox}[title=Stuff 4]
\lipsum[4]
\end{tcolorbox}
\begin{tcolorbox}[title=Stuff 5]
\lipsum[5]
\end{tcolorbox}
\begin{tcolorbox}[title=Stuff 6]
\lipsum[6]
\end{tcolorbox}
\end{document}
Include this document with pdfpages or as graphicx in another one in 3x1 layout:
\documentclass{article}
\usepackage{geometry}
\geometry{paper=a4paper,landscape}
\usepackage{pdfpages}
\begin{document}
\includepdf[pages=-,nup=3x1]{content}
\end{document}
Ulrike Fischer
- 327,261

