Re: Plain TeX: Aligning to an earlier centered line's ends
David Carlisle <[email protected]> Wed, 7 Jan 2026 14:39:09 +0000
| Newsgroups | gmane.comp.tex.texhax |
|---|---|
| Message-ID | <CAEW6iOgtGGTDweZXS3hAOEGUMi_LjgyhWfs0eubBggyTzTBTjw@mail.gmail.com> |
[image: image.png]
%%%%%%%%%%%%%%%%%%%
\noindent X\dotfill X
\bigskip
\centerline{\vtop{\halign{#\cr
Left end of a centered line; its right end.\cr
Aligned to L\hfil\cr
\hfil Aligned to period.\cr
}}}
\bigskip
\noindent X\dotfill X
\bye
%%%%%%%%%%%%%%%%%%%%%
David
On Wed, 7 Jan 2026 at 14:18, Suresh Govindachar via texhax <[email protected]>
wrote:
> Hello,
>
> A page has a centered line (via "\centerline{}"): "Left end of a
> centered line; its right end."
>
> The line below that, "Aligned to L", needs to be left-aligned to "L" of
> the centered line.
>
> The line below that, "Aligned to period.", needs to be right-aligned to
> "." of the centered line.
>
> How exactly to achieve this (create a hbox to the size of the centered
> line, center this hbox, insert the text inside this hbox with hss on the
> right for left-alignment and hss on the left for right alignment)?
>
>
image.png
(image/png, 7.3 KB) - not displayed