[Tex/LaTex] Left-aligned display math mode

horizontal alignmentmath-modeplain-textex-core

How could one achieve, as primitively as possible, left-aligned display math so that \abovedisplayshortskip would still work as intended?

It is my understanding that one can achieve left-alignment via an immediate \halign inside display math mode, but this makes (again, in my understanding) it occupy the whole width of the display, and hence makes it impossible for there to be \abovedisplayshortskip (or \belowditto).

Here is what I have now:

Some text $$\displaylines{\kern2\parindent % i.e. \halign
  a + b = c
\hfill}$$ and so continues the paragraph. Until
\bye

Best Answer

My first thought (you didn't wait long enough to get my answer) was to set the math left aligned in an \hbox that was shorter than the \displaywidth by twice the indentation value:

\newdimen\mydisplayboxwidth
\newdimen\mydisplayindent
\mydisplayindent 2\parindent % 
\noindent OK:
$$\mydisplayboxwidth\displaywidth
  \advance\mydisplayboxwidth-2\mydisplayindent
  \hbox to \mydisplayboxwidth
    {$\mathsurround0pt \displaystyle a + b = c$\hss}
\eqno(1)$$
and so continues the paragraph.
\bye
Related Question