initial text sort method