I want to make all multi-line paragraphs with indentation and all single line paragraphs without. Similar to what is described in Turn off paragraph indention for a single line.
But!
I need to auto-generate the LaTeX code, so I don't know in advance if the paragraph will be single or multi-line.
Is there any way to ask for that kind of style formatting?