wyc
wyc

Reputation: 55283

Why the font DejaVu Sans Mono looks different in (G)Vim and Emacs?

I think the line-spacing is different in both editors.

How can I set the font in Vim to look like in Emacs?

Emacs

enter image description here

.emacs:

== Default Font ====

;; Font family
(set-default-font "DejaVu Sans Mono")

;; Font size 
(set-face-attribute 'default nil :height 100)

Vim

enter image description here

.vimrc:

" set default font
set guifont=DejaVu\ Sans\ Mono\ 10

Upvotes: 4

Views: 4790

Answers (1)

Roger Wang
Roger Wang

Reputation: 1376

emacs GUI is using libxft to render fonts, while GVim uses gtk/pango. There could be difference with font hinting.

Upvotes: 6

Related Questions