If $A=\Gamma(X,O_X)$ and $Spec(A)=X$ then $Spec(A)=X$ as schemes. Let $X$ be a scheme and $A$ a commutative Ring. Assume that we have an isomorphism $A \rightarrow \Gamma (X, O_X)$ and the induced map $X \rightarrow Spec(A)$ is a homeomorphism.

Question: Is it true that then X is isomorphic to $Spec(A)$ as schemes?

I would suspect this to be true. I tried to check this on the stalks but we only have for each $\mathfrak{p} \subset A$ that $O_{X,x}=A_\mathfrak{p}=\Gamma(X,O_X)_\mathfrak{p}$. Unfortunately we dont know that the ring on the RHS is actually the stalk of $X$.
 A: Here's one way to conclude (there might be simpler ways):
The morphism of schemes $X\to Spec(A)$ is a homeomorphism. By Lemma 28.44.2 here it is then an affine morphism. Since the target is affine, this implies that $X$ itself is affine, and then you're done.
A: Let us identify the underlying topological spaces of $X$ and $\operatorname{Spec}(A)$ and write $O_A$ for the structure sheaf of $\operatorname{Spec}(A)$.  So we have a topological space $X$ with two different sheaves of rings $O_X$ and $O_A$ that make it a scheme, with a map $O_A\to O_X$.  We will show that $O_X$ is a quasicoherent $O_A$-module.
Fix a point $x\in X$.  Take an $O_X$-affine open neighborhood $V$ of $x$; say $(V,O_X|_V)$ is isomorphic to $\operatorname{Spec}(B)$ for some ring $B$.  The composition $V\to X\to\operatorname{Spec}(A)$ induces a homomorphism $\varphi:A\to B$.  Now take an element $a\in A$ such that the distinguished open set $U=D(a)\subseteq\operatorname{Spec}(A)$ satisfies $x\in U\subseteq V$.  Note that the distinguished open subset $D(\varphi(a))\subseteq \operatorname{Spec}(B)=V$ has the same points as $D(a)$.  We conclude that $U$ is an open neighborhood of $x$ which is affine as a subscheme of both $X$ and $\operatorname{Spec}(A)$.  It follows that $O_X|_U$ is a quasicoherent $O_A|_U$-module: this is just the fact that if $f:Y\to Z$ is a map of affine schemes, $f_*O_Y$ is quasicoherent.
Since quasicoherence is a local property and $x\in X$ was arbitrary, we conclude that $O_X$ is a quasicoherent $O_A$-module.  Since $\operatorname{Spec}(A)$ is affine, this means it is determined by its global sections, so the assumption that $O_A\to O_X$ is an isomorphism on global sections implies it is an isomorphism of sheaves.  It follows that $X\to \operatorname{Spec}(A)$ is an isomorphism of schemes.
(Incidentally, the real work in this argument is being hidden in the (nontrivial!) fact that every quasicoherent sheaf on $\operatorname{Spec}(A)$ is determined by its global sections (i.e., that sheaves on affine schemes that are locally induced by modules are globally induced by modules).)
