7. (1999 National High School Mathematics League Question) Given: when $x \in[0,1]$, the inequality $x^{2} \cos \theta-x(1-x)+(1-x)^{2} \cdot \sin \theta>$ 0 always holds, try to find the range of $\theta$.

Translate the above text into English, please retain the original text's line breaks and format, and output the translation result directly.
7. Transform the given inequality into
$$
(1+\sin \theta+\cos \theta) x^{2}-(1+2 \sin \theta) x+\sin \theta>0 \text {. }
$$

Let $f(x)=(1+\sin \theta+\cos \theta) x^{2}-(1+2 \sin \theta) x+\sin \theta$, then $f(x)>0$ holds for all $x$ in the closed interval $[0,1]$. This implies that $f(0)>0$ and $f(1)>0$, i.e., $f(0)=\sin \theta>0$ and $f(1)=\cos \theta>0$,

Thus, $\theta$ lies in the first quadrant, and we can assume $\theta \in\left(0, \frac{\pi}{2}\right)$. Therefore, $1+\sin \theta+\cos \theta>0$, and the quadratic function $f(x)$ opens upwards, with the axis of symmetry given by $x=\frac{1+2 \sin \theta}{2(1+\sin \theta+\cos \theta)}$. Clearly, $00$ holds for all $x$ in the closed interval $[0,1]$, it is sufficient to satisfy the condition $\Delta\frac{1}{2}$. Since $\theta \in\left(0, \frac{\pi}{2}\right)$, we have $2 \theta \in(0, \pi)$. $\frac{\pi}{6}<2 \theta<\frac{5}{6} \pi, \frac{\pi}{12}<\theta<\frac{5}{12} \pi$.
Thus, the range of $\theta$ that satisfies the condition is
$$
2 k \pi+\frac{\pi}{12}<\theta<2 k \pi+\frac{5}{12} \pi(k \in \mathbf{Z}) .
$$