Completed working version of justify text