I have a question about the "windowed / short-time / short-term" Fourier transform that is somewhat perplexing me. I have now added an Addendum at the bottom, where the issue is presented more concisely through an example.
$ $
Idea of the Fourier transform
Given a "nice" function $f \colon \mathbb{R} \to \mathbb{R}$, we define the Fourier transform $\hat{f} \colon \mathbb{R} \to \mathbb{C}$ of $f$ by $$ \hat{f}(\xi) \ = \ \int_{-\infty}^\infty f(\tau)e^{-2\pi i \xi\tau} \, d\tau. $$ If we write $\hat{f}(\xi)=A_\xi e^{i\phi_\xi}$ for each $\xi > 0$, then $$ \hspace{47mm} f(\tau) \ = \ 2\int_0^\infty A_\xi\cos(2\pi\xi\tau + \phi_\xi) \, d\xi \hspace{47mm} \text{(1)} $$ for (almost) all $\tau \in \mathbb{R}$; therefore, we may naturally refer to $A_\xi$ and $\phi_\xi$ as being respectively the amplitude and initial phase associated to the frequency $\xi$.
$ $
Idea of the "windowed / short-time" Fourier transform
Now as I understand it, the windowed Fourier transform is meant to give a time-localised frequency spectrum analysis, of the following nature: At each time $t$, a complex number $\hat{f}_{\!\!\mathrm{short}}(\xi,t)$ is assigned to each frequency $\xi>0$, where the modulus and argument of $\hat{f}_{\!\!\mathrm{short}}(\xi,t)$ represent respectively the current amplitude and phase (at time $t$) of the frequency-$\xi$ sinusoidal component of $f$ locally around $t$. This is achieved by attenuating $f$ outside a small window which moves in time.
$ $
WFT at time $t=0$
Let us start by considering the amplitude and phase associated to $\xi$ at time $0$. We define a window function $g \colon \mathbb{R} \to [0,\infty)$ that is even, non-increasing on $[0,\infty)$, and rapidly decays outside some interval about $0$. Representing $f(\cdot)g(\cdot)$ as $$ \hspace{40mm} f(\tau)g(\tau) \ = \ 2\int_0^\infty A_\xi\cos(2\pi\xi\tau + \phi_\xi) \, d\xi \, , \hspace{40mm} \text{(2)} $$ we define $$ \hspace{32mm} \hat{f}_{\!\!\mathrm{short}}(\xi,0) \ = \ A_\xi e^{i\phi_\xi} \ = \ \int_{-\infty}^\infty f(\tau)g(\tau)e^{-2\pi i \xi\tau} \, d\tau. \hspace{32mm} \text{(3)} $$
$ $
WFT at time $t \neq 0$ (where my problem starts!)
We now wish extend this to localise around times $t$ other than $0$. I can think of two seemingly logical approaches, both of which end up being the same.
Approach 1. The "current amplitude and phase" should not need to make any reference to an arbitrary reference time "$t=0$"; so just do exactly the same as above, but relative to our new time $t$. In other words, representing $$ \hspace{35mm} f(\tau+t)g(\tau) \ = \ 2\int_0^\infty A_\xi\cos(2\pi\xi\tau + \phi_\xi) \, d\xi \, , \hspace{35mm} \text{(4)} $$ define $$ \hspace{27mm} \hat{f}_{\!\!\mathrm{short}}(\xi,t) \ = \ A_\xi e^{i\phi_\xi} \ = \ \int_{-\infty}^\infty f(\tau+t)g(\tau)e^{-2\pi i \xi\tau} \, d\tau. \hspace{27mm} \text{(5)} $$
Approach 2. Keeping the same function $g$, take our time-localisation window to be the function $g(\cdot - t)$ centred about $t$. Represent $$ \hspace{35mm} f(\tau)g(\tau-t) \ = \ 2\int_0^\infty A_\xi\cos(2\pi\xi\tau + \tilde{\phi}_\xi) \, d\xi. \hspace{35mm} \text{(6)} $$ In this representation, for each $\xi$ the phase at time $0$ is $\tilde{\phi}_\xi$, so the phase at time $t$ is $2\pi\xi t + \tilde{\phi}_\xi$. Hence define $$ \hspace{19mm} \hat{f}_{\!\!\mathrm{short}}(\xi,t) \ = \ A_\xi e^{i(2\pi\xi t + \tilde{\phi}_\xi)} \ = \ \int_{-\infty}^\infty f(\tau)g(\tau-t)e^{-2\pi i \xi(\tau-t)} \, d\tau. \hspace{19mm} \text{(7)} $$ Note that the integrals in $\text{(5)}$ and $\text{(7)}$ are the same, by the transformation $\tau \mapsto \tau-t$.
Actual definition of WFT. Apart from differences in convention about how $2\pi$ features in the formula for the Fourier transform, all the sources that I've encountered are unanimous in their definition for the WFT: $$ \hspace{37mm} \hat{f}_{\!\!\mathrm{short}}(\xi,t) \ = \ \int_{-\infty}^\infty f(\tau)g(\tau-t)e^{-2\pi i\xi\tau} \, d\tau. \hspace{37mm} \text{(8)} $$
Note that the only difference between $\text{(7)}$ and $\text{(8)}$ is that the factor $e^{2\pi i \xi t}$ is missing from $\text{(8)}$. In other words: In $\text{(8)}$, the argument of $\hat{f}_{\!\!\mathrm{short}}(\xi,t)$ represents what the phase of the frequency-$\xi$ component of $f$ locally around $t$ would be at time $0$ if this component were extend back that far.
Why is $\text{(8)}$ used rather than $\text{(5)}$ / $\text{(7)}$?
This seems particularly bizarre, seeing as the WFT and the wavelet transform are often presented as being directly analogous in their aim, and yet the wavelet transform formula does follow the approach of performing exactly the same calculation relative to each new time $t$.
ADDENDUM - a concrete illustration. Take the "trivial" signal $f(t)=\cos(2\pi t)$. Let $g$ be the Gaussian window function $$ g(\tau) \ = \ \frac{1}{\sqrt{2\pi}\sigma} e^{-\frac{\tau^2}{2\sigma^2}}, $$ where the parameter $\sigma>0$ represents the frequency resolution. If my calculations are correct, the standard definition $\text{(8)}$ of the windowed Fourier transform $\hat{f}_{\!\!\mathrm{short}}$ gives that at frequency $\xi=1$, $$ \hspace{23mm} \hat{f}_{\!\!\mathrm{short}}(1,t) \ = \ \tfrac{1}{2} \ + \ \tfrac{1}{2}e^{-8\pi^2\sigma^2}\!\big(\! \cos(4\pi t) - i\sin(4\pi t) \big). \hspace{23mm} \text{(9)} $$ So, as long as $\sigma$ isn't insanely small, we have that $$ \hat{f}_{\!\!\mathrm{short}}(1,t) \ \approx \ \tfrac{1}{2} \hspace{5mm} \forall \, t \in \mathbb{R}. $$ In particular, the phase assigned to frequency $1$ remains approximately $0$ for all time. However, a time-frequency representation which gives the "current" amplitude and phase at time $t$, like the wavelet transform (or like my definition (5)/(7) for the WFT), would assign a phase of $2\pi t$ at time $t$.