
In the above proof the following equivalence is used at the last step:
A space $M$ is connected if and only if the only open and closed subsets of $M$ are $\emptyset$ and $M$ (ie. there are no proper open and closed subsets).
However I do not understand the claim that $X$ is the completment of the open union and feel like it is non-trivial. Can someone please elaborate?