It is possible using the Rule $ P = n p, Q = n q $, $n$ any real number
and recognizing
$$ \frac{1-\cos\theta}{\sin\theta}= \frac{\sin\theta}{1+\cos\theta}\tag{0} ,$$
$$ \frac {u}{v} = \frac {p}{q} = \frac {P}{Q}=\frac {u \pm P}{v \pm Q}, $$ and entirely avoid all trigonometric calculations.
Multiply numerator and denominator by 7 and add
$$\frac{2\sec\theta +3\tan\theta+5\sin\theta-7\cos\theta+5}{2\tan\theta +3\sec\theta+5\cos\theta+7\sin\theta+8}=\frac{1-\cos\theta}{\sin\theta}=\frac{7-7 \cos\theta}{7 \sin\theta}\tag{1}$$
$$ F = \frac{2\sec\theta +3\tan\theta+5\sin\theta-2}{2\tan\theta +3\sec\theta+5\cos\theta+8} \tag{2} $$
Multiply numerator and denominator by 5 and subtract
$$\frac{2\sec\theta +3\tan\theta+5\sin\theta-7\cos\theta+5}{2\tan\theta +3\sec\theta+5\cos\theta+7\sin\theta+8}=\frac{\sin\theta}{1+\cos\theta}=\frac{5 \sin\theta}{5+5\cos\theta} \tag{3} $$
$$ F=\frac{2\sec\theta +3\tan\theta-7\cos\theta+5}{2\tan\theta +3\sec\theta +7\sin\theta+3} \tag{4}$$
Repeating the Rule by subtracting on (2) and (4)
$$ F=\frac{5 \sin \theta + 7\cos\theta-7}{5\cos\theta -7\sin\theta +5}\tag{5} $$
Repeating the rule by subtracting (2) from (3)
$$ F =\frac{5 \sin \theta + 7\cos\theta-7}{5\cos\theta -7\sin\theta +5}\tag{6} $$
which are identical.
It will be appreciated that it is simple algebra and there is no trig at all after (0) and probably that is how the problem had been set.