Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support vbox[width=...] #367

Open
simoncozens opened this issue Sep 5, 2016 · 2 comments
Open

Support vbox[width=...] #367

simoncozens opened this issue Sep 5, 2016 · 2 comments
Labels
enhancement Software improvement or feature request

Comments

@simoncozens
Copy link
Member

First \vbox should put a box into the typesetter's queue. Second, this should make two columns:

  \begin[papersize=a5]{document}
  \script[src=packages/lorem]
  \hbox{\vbox[width=60pt]{Text here will wrap \lorem}}
  \hbox{\vbox[width=60pt]{Text here will wrap \lorem}}
  \par
  \script{SILE.typesetter:debugState()}
  \end{document}
@alerque
Copy link
Member

alerque commented Sep 5, 2016

Won't this need to introduce some alignment parameters too? Sort of like display: inline-block in CSS? Or `\begin{minipage]| in TeX. If I'm understanding this correctly the same layout logic would also be useful for image positioning.

@simoncozens
Copy link
Member Author

Not really. The idea is that you put a vbox onto the horizontal list (which is supported but the output routine doesn't quite work).

Consider the following piece of plain TeX:

hello
\qquad \vbox to 20pt {\hbox to 40pt{Stuff in a}\hbox to 25pt{vbox}}
\qquad \vbox to 20pt {\hbox to 40pt{Stuff in a}\hbox to 25pt{vbox}}
\qquad world.
\end

screen shot 2016-09-05 at 16 11 55

(This is, essentially, how minipage is implemented under the hood.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Software improvement or feature request
Projects
Development

No branches or pull requests

3 participants