Feeding
\documentclass{article}
\pagestyle{empty}
%\usepackage[slantedGreek,subscriptcorrection]{newtx}% this is what I use with many of other packages in a non-minimal example.
%% Text skips with glue being half of the value of the argument (cf. http://tex.stackexchange.com/q/657443, http://tex.stackexchange.com/a/657448, and http://tex.stackexchange.com/a/672701):
\newcommand{\flexibleHSkip}[1]{%
\hskip#1
plus.5\dimexpr\ifdim #1<0pt -\fi#1\relax
minus.5\dimexpr\ifdim #1<0pt -\fi#1\relax
\relax
}
\begin{document}\noindent
Consider the set \(Y\). Let \ldots\\
Consider the set \(Y\)\flexibleHSkip{-.1em}. \flexibleHSkip{.1em}Let \ldots\\
Consider the set \(Y\)\flexibleHSkip{-.1em}.\flexibleHSkip{.1em} Let \ldots\\
Consider the set \(Y\), and let \ldots\\
Consider the set \(Y\)\flexibleHSkip{-.1em}, \flexibleHSkip{.1em}and let \ldots\\
Consider the set \(Y\)\flexibleHSkip{-.1em},\flexibleHSkip{.1em} and let \ldots
\end{document}
to pdflatex
yields
with standard fonts (Computer Modern) and
with NewTX. The versions with the reduced space between π and the punctuation mark seem better to me (and, hopefully, to you). The macro \flexibleHSkip{β¦}
allows for stretching and shrinking to allow for prettier lines and paragraphs; if you don't care, you can use simple \hskip-.1em
and \hskip.1em
instead, for instance.
If we manually reduce white space before punctuation and add white space after punctuation, which version is correctβ’, i.e., causes less issues (I might imagine that line breaking could be hypothetically affected):
\flexibleHSkip{-.1em}PunctuationSymbol\flexibleHSkip{.1em}
or\flexibleHSkip{-.1em}PunctuationSymbol \flexibleHSkip{.1em}
. In other words, what should be the order of the regular space symbol\flexibleHSkip{.1em}
after the punctuation mark?How to get better spacing between βπβ and [β.β or β,β] automatically, without manual space deletions and insertions in the source document?