JBIDE-18179: Terminal size is now correctly calculated. 

Thanks goes to Alexey Kazakov for providing the code to calculate the
font extend.