So far, I've always been writing \forall\, x\in X\colon \varphi(x), and, if I really wished to have better spacing and line breaking in narrow linewidth, \forall\penalty1\mskip3mu plus1.5mu minus1.5mu x\penalty2\mskip-2mu plus1mu minus1mu\in\penalty2\mskip-2mu plus1mu minus1mu X\colon\penalty1 \varphi(x).
However, https://tex.stackexchange.com/a/676323 made me think that the default \colon of amsmath might not be intended for the usage within quantified expressions. In testmath.pdf I don't see ∃ at all, and ∀ is used only in a post position, i.e., in formulas of the form “(x) ∀ x”. So it might hypothetically be the case that the creators of amsmath have never thought of the usage “∀ ∈ : (x)”.
Also, when a line ends right after the colon in text mode, e.g., in $∀ ∈ :\\(x)$ or when the line randomly happens to end after the colon in $∀ ∈ :\penalty1 (x)$ , the output has some horizontal space between : and the right margin.
So what's the best™ default spacing around the colon in quantified formulas such as
∀ ∈ : ()
or, for the sake of a longer example,
∀ ∈ , ∈ , ∈ : ₁ ∧ ₂ ⇒ ₁ ∧ ₂
(where the precedence is as in https://alchemy.cs.washington.edu/user-manual/4_1First_Order_Logic.html) and how to express it in LaTeX when amsmath (or another package which makes \colon behave similar to that of amsmath, say, NewTX, or unicode-math + TeX Gyre Termes Math) is in use?
\penaltydo, apart from adding a feasible line break point, which is clearly not wanted? And is anybody forcing you to use\colon? – egreg Feb 24 '23 at 21:37\forall, am I right? – egreg Feb 24 '23 at 21:39