Determining outerplanarity using segment graphs