1

I'm using tabbing environment in a regular context but I'm trying at the same time to align the first line of tabbing with the context. For the moment, this is my MWE:

\documentclass{article}

\begin{document}
Les Égyptiens disent :
\begin{tabbing}
  Vie, \= prospérité, santé. \\
  \> \emph{Ankh}, \= \emph{wadj}, \emph{seneb}.\\
  \>\> 𓋹𓍑𓋴.
\end{tabbing}

\end{document}

And here is the corresponding rendering (do not care about the hieroglyphic characters, it doesn’t matter at all):

Get render

As you see, the whole table goes in a new line, when I try to make it still in the baseline of the paragraph. Something like that would be preferable:

Expected render

The goal it’s just to align Ankh with Prospérité and the first hieroglyphic character with wadj. If it’s possible to do it without tabbing environment, it’s also fine :)

One last precision: if the tabbing part reach the right margin, it should not break line, it has to be printed on the margin. The whole block shouldn’t be break.

So, how to get the expected rendering?

1
  • Can't you put it this in a 2x2 table, where you use only 3 fields? The reason for this behavior is likely, that the environment inserts vskips. And vskips create paragraph breaks. Another solution would be to put everything into a parbox. You should add some blind text around your example, so we can see, what you want to achieve. Commented Apr 28, 2022 at 5:40

2 Answers 2

2

You can use \vtop and deactivate \trivlist and \vskip inside the group of \vtop:

\documentclass{article}

\begin{document}

Les Égyptiens disent :
\vtop{\def\trivlist#1\relax{}\def\vskip{\skip0=}
  \begin{tabbing}
    Vie, \= prospérité, santé. \\
    \> \emph{Ankh}, \= \emph{wadj}, \emph{seneb}.\\
    \>\> xx.
  \end{tabbing}
}

\end{document}
2

I'm not sure of what you would like to achieve, but here are a couple of examples with tabularray.

I wrote "hieroglyphic" instead of the hieroglyphic itself just to show the alignment.

\documentclass{article}
\usepackage{tabularray}
\begin{document}
    I'm not sure if you want something like this:
    
    Les Égyptiens disent :
    \begin{tblr}{colspec={lll}, baseline=t, colsep=2pt}
        Vie, & \SetCell[c=2]{l}prospérité, santé. &\\
        & \emph{Ankh}, & \emph{wadj}, \emph{seneb}.\\
        && hieroglyphic.
    \end{tblr}
    
    or something like this:
    
    Les Égyptiens disent :
    \begin{tblr}{colspec={lll}, baseline=t, colsep=2pt}
        Vie, & prospérité, santé. \\
        & \emph{Ankh}, & \emph{wadj}, \emph{seneb}.\\
        && hieroglyphic.
    \end{tblr}
    
\end{document}

enter image description here

2
  • I was expecting the first solution you suggest. Your solution work so as @wipet’s one. So, I hesitate and finaly choose @wipet’s one because in general I prefer solutions with less new code. BTW your solutions still good.
    – fauve
    Commented Apr 28, 2022 at 15:28
  • 1
    @fauve Thank you and don't worry! You are free to accept the solution you prefer!
    – CarLaTeX
    Commented Apr 28, 2022 at 15:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .