Here's the text I do not understand:
Example 27 is this: Prove that $$\int_a^b x \,dx= \frac{b^2 - a^2}{2}$$
I don't understand what this means:
Notice that $g'(x) = x$, that is, $g' = f$. In other words, if $g$ is defined as the integral of $f$ by Equation 1, then $g$ turns out to be an antiderivative of $f$, at least in this case. And if we sketch the derivative of the function $g$ shown in Figure 4 by estimating slopes of tangents, we get a graph like that of $f$ in Figure 2. So we suspect that $g' = f$ in Example 1 too.
I can see why $g'(x) = x$ because $\frac{d}{dx} \frac{x^2}{2} = x$. But, why does $g' = f$? That means the derivative of $g$ is equal to $f$ right? It does not mean the antiderivative of g is equal to $f$ right?

The book assumes (temporarily, for the sake of an example), that $f(x)=x.$ (It literally says $f(t)=t,$ but that’s the same thing.) After doing the integral, we see that $g’(x)=x.$ So now we have $$g’(x)=x=f(x),$$ From which we conclude $g’$ and $f$ are the exact same function, that is, $g’=f.$
This isn’t stated as a general claim yet; at that point, the book only claims it is true “at least in this case.” But here’s what it actually says about this case:
There are no other claims about anything being a derivative or antiderivative of anything else.
Be careful how you read the symbols and don’t read “$f$” when the text says “$g$.”