Monospace Font - Not really Monospace?

大憨熊 提交于 2019-12-11 02:43:30

问题


This appears to be a bug that I've found using JavaScript in Gedit (when you change the font from "Ubuntu mono" to "Monospace") and Geany so far. I have a right margin set to 80 chars, but when I type Object, prototype or any other key word bolded by the program, It adds some letter spacing that throws off the spacing just slightly.

Because of this, I have a line declaring Object that's 79 characters, but appears to be 81.5 characters. Can someone advise me on how to fix this? Is it a Text Editor setting? Is it an issue with the font itself?


回答1:


It's probably because your default monospace font doesn't have a native bold style. Just change the font. I'd suggest since you're in Linux, DejaVu Sans Mono or Liberation Mono; they'll work just fine.

Also, you'd think monospace would have a native bold style by now

If you're in Ubuntu you can download Unsettings and change the default monospace font so when you open programs that have "monospace" as font it'll be the one you chose.

Btw, this is not unique to Linux. Check out the default monospace font on a Windows cmd...



来源:https://stackoverflow.com/questions/14515185/monospace-font-not-really-monospace

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!