Step 1: Approach
Compare with a related compound whose oxidation state is easy to recall.
Step 2: Build it from $\text{XeF}_6$
In $\text{XeF}_6$ the xenon is $+6$ (six F atoms at $-1$ each). Replacing two F atoms by one O atom keeps the charge balance because $2\times(-1)=-2$ is exactly what one oxygen supplies.
Step 3: Direct sum
\[ (+6) + (-2) + 4(-1) = 0 \]
So the neutral molecule is balanced when Xe is $+6$. Option (D) is correct.
Final Answer:
Xe is in the +6 oxidation state in $\text{XeOF}_4$, option (D).
\[ \boxed{+6} \]