Gets the number of selected regions.
an Text
The number of selected regions, or -1 in the case of failure.