Step by step solution of an Indefinite Integral
Since $1+\log^2x$ is squared and appears in the denominator, we might try an antiderivative of something over $1+\log^2x$ because of the quotient rule: $$\frac d{dx}\frac f{1+\log^2x}=\frac{f'(1+\log^2x)-f((2/x)\log x)}{(1+\log^2x)^2}$$ The numerator contains only $\log$s, so $f$ must cancel the $\frac1x$ of $\frac2x\log x$. So $f$ might be $x$; we check and it works, and the answer is $$\frac x{1+\log^2x}+K$$
we have a result $$\int e^x(f(x)+f'(x))=e^x f(x)+c \tag 1$$ this ie very easy to prove by intgration by parts. You have already done the difficult part of splitting the integral to $$\int e^t\left(\frac{1}{t^2+1}-\frac{2t}{{(t^2+1)}^2}\right)dt $$Now if $$f(t)=\frac{1}{t^2+1} \implies f'(t)= \frac{-2t}{{(t^2+1)}^2}$$ which is of form (1).......