Added font choosing logic for osx and linux