I saw several messages and answers on how to get the size of the terminal in the number of columns and rows. Can I get the size of the terminal, or equivalently, the font size used in the terminal, in pixels?
(I wrote equivalently because the terminal width [px] = font width [px] * number of columns, or this is what I mean by terminal width.)
I am looking for a method that works with python 2 on linux, but I appreciate answers that only work with python 3. Thanks!
source
share