Text measure and flow layout utility