oneKelvinSmith/monokai-emacs

Font in org-mode differs from my setting

binshengliu opened this issue · 6 comments

I'm using "DejaVu Sans Mono-10" as my font, but it seems it changed after enabling monokai-theme. "Listening to music" in the image is not displayed with a monospaced font. And the line number also looks weird. Others remain what I expect.

image

Hey @lbsx,

Can you try put this in your init.el:

(setq monokai-height-plus-1 1.0
      monokai-height-plus-2 1.0
      monokai-height-plus-3 1.0
      monokai-height-plus-4 1.0
      monokai-height-minus-1 1.0)

These functions are used to scale the org-mode headers.

I tried that before. The font size is not scaled but the font family remains DejaVu Sans instead of DejaVu Sans Mono. And the line numbers are not aligned.

I found lots of settings about org-mode in monokai-theme, but I don't know how they change the font.

image

Ok, I think it's because of the variable-pitch see: bbatsov/solarized-emacs#87

Please try this:

  (setq monokai-use-variable-pitch nil)

If this helps I'll update the README and I'm considering disabling this by default because I think this has confused a few people.

It works. Thanks.

Actually I'm confused by the feature and I don't know in which situation it should to be used.

And I think it looks better if the line numbers of the headings look the same with the default monokai-height-plus-* values.

Could you please close the issue after updating the README or disabling the feature?

Yeah, I'd not realised it forced the use of a fixed width font and I don't use org-mode myself so I've not been frustrated by the weird rendering.

I'll disable it and the font resizing by default and document the use of the functions for people who still want the effect.

Thank you for pointing out the issue.

This should be fixed with fe409de.

Thanks again :)