Hacker Newsnew | comments | show | ask | jobs | submitlogin
terhechte 420 days ago | link | parent

I love vim but for some tasks (Clojure, Scala) it seems emacs is the better option, so I've recently tried to switch over to emacs + evil for these tasks. However: While my MacVim (and terminal vim) looks quite beautiful these days, due to all these splendid plugins and color themes (powerline etc) that I installed, I have to say that emacs looks awful. I did search Github for nice Emacs configs that make it look more pleasant (just using Solarized doesn't cut it for me) but I couldn't find any.

Does anyone have tips for nice emacs configurations that make it look a lot more beautiful?

Edit: My current vim looks like this (opened random old files) http://appventure.me/vim.png



manish_gill 420 days ago | link

My GVim: http://i.imgur.com/5nH37zy.png

My Emacs: http://i.imgur.com/SNTZL6i.png

At first, Emacs font rendering felt weird to me, but some tweaking made it look slick. I use the ir-black theme with the Monaco for powerline font. Here's my config: https://github.com/mgill25/dotfiles/blob/master/emacs

-----

klibertp 420 days ago | link

I see NERDTree on your GVIM screenshot, yet no equivalent in Emacs. I don't know about you, but I missed NERDTree very much, so I looked at speedbar in Emacs. Unfortunately, out of the box it displays as another WM-level window (frame in Emacs parlance), but I managed to beat it into shape with: http://www.emacswiki.org/emacs/SrSpeedbar

Speedbar is good, because not only looks like NERDTree, it also displays summary of file contents (for programming: functions, classes, imports, etc.) if you want.

-----

manish_gill 420 days ago | link

Thanks. I'll give it a try. I do miss NERDTree in Emacs, but so far, I've only been tinkering around with it, and still use vim for long sessions. :)

-----

klibertp 420 days ago | link

I try to move on to Emacs as my full time editor/IDE, but so far I failed, and I've been trying for several weeks now. The problem is that I put years of tinkering into my VIM to make it almost exactly as I need it. This means that I won't switch until Emacs has at least very similar number of customizations, macros, plugins, etc. And making this from scratch takes time. The only positive in this is that I already know what I want, so hopefully it'll take shorter than for the first time :)

-----

lord_quas 419 days ago | link

The reason to move to emacs is exactly because it has far more customizations available than vim does. Emacs' nerd tree equivalent is called undo tree, and its fantastic.

http://www.emacswiki.org/emacs/UndoTree

-----

johncoltrane 419 days ago | link

No. NERDTree is file explorer, it has nothing to do with Emacs's UndoTree. The "equivalent" of UndoTree in Vim world would be Gundo.

-----

terhechte 420 days ago | link

Thanks! That looks way better than my current emacs! Will try it out

-----

tikhonj 420 days ago | link

Emacs has its own version of powerline. You can turn off most of the annoying frills like the menu bar, the scroll bars, the toolbar and the fringe. You can also use a nice typeface (I'm very partial to Deja-vu Sans Mono) and a nice color scheme (I like blackboard).

I think the final result looks rather good: http://jelv.is/emacs-blackboard.png and http://jelv.is/emacs-demo.png.

-----

terhechte 420 days ago | link

That looks nice, do you have the config for that available somewhere? Thanks!

-----

tikhonj 420 days ago | link

My actual .emacs file has a ton of things unrelated to this, so here are the relevant bits:

    ;; Make the window simpler
    (tool-bar-mode -1)
    (scroll-bar-mode -1)
    (menu-bar-mode -1)
    (fringe-mode 0)
Powerline and the color theme are installed separately. You can get powerline using the new package manager through M-x package-list-packages. You might have to configure some additional package sources first:

    (require 'package)
    (add-to-list 'package-archives 
                 '("marmalade" . "http://marmalade-repo.org /packages/"))
    (add-to-list 'package-archives
                 '("melpa" . "http://melpa.milkbox.net/packages/"))
    (package-initialize)
You can then run powerline using

    (require 'powerline)
It might take a little more configuration to get the powerline colors matching to what you want. You can also customize the shape of the separator: it doesn't have to be an arrow.

Unfortunately, the blackboard theme in the package manager is using the old color-theme package which has been made obsolete with Emacs 24. You should use the version ported to the new and improved theming mechanism[1].

[1]: https://github.com/don9z/blackboard-theme

Download that and put it in ~/.emacs.d/themes. Now you can set it up with:

    (setq custom-theme-directory "~/.emacs.d/themes/")
    (setq custom-safe-themes t)
    (load-theme 'blackboard)
I hope that helps.

-----

terhechte 420 days ago | link

Thanks, fantastic! Will try it out!

-----

ericssmith 420 days ago | link

You might like color-theme-sunburst.el based on your screenshot.

-----

koalaman 419 days ago | link

I recently started using ujelly https://github.com/marktran/color-theme-ujelly which looks similar as well.

-----

cguo 419 days ago | link

How do you install/load it in emacs? I moved the .el file into .emacs.d/themes, but (load-theme 'ujelly) didn't work like it did for blackboard.

-----

tikhonj 418 days ago | link

Just based on the name, it looks like that file uses the old color-theme-mode instead of the new theming facilities. You'll either have to find a different version, port it over (I don't know how much effort that would take) or just use color-theme-mode.el again, which is a little annoying.

-----

ericssmith 417 days ago | link

Something like this ...

(require 'color-theme) (color-theme-initialize) (load-file "~/.emacs.d/themes/color-theme-sunburst.el")

-----

nieve 420 days ago | link

I don't know if this is what you're thinking of when you say beautiful, but I'm pretty happy with my current setup: http://i.imgur.com/m6cIbd0.png

It's basically a slightly tweaked version of color-theme-zenburn with rainbow-delimiters mode, (setq font-lock-maximum-decoration t), and modeline tweaks from http://emacs-fu.blogspot.com/2011/08/customizing-mode-line.h...

-----

terhechte 420 days ago | link

Thanks, that looks nice, do you happen to have your config available somewhere?

-----

nieve 420 days ago | link

I think this is everything you'll need and it seems to work without the rest of my emacs config, but you can also submit an issue or email me as kate on tupl.es (and yes, that's a horrible DB joke) if you have trouble and don't want to continue the discussion here.

https://github.com/katenym/emacs-visual-tweaks

-----

nieve 420 days ago | link

I don't have it up and it's scattered through different parts of my config, but I'm happy to extract those bits and toss it up as a gist in an hour or so when coffee kicks in.

-----

bitserf 420 days ago | link

Which font are you using? I can't quite place it.

-----

swah 420 days ago | link

Not him, but maybe its Ubuntu?

-----

nieve 420 days ago | link

(Her actually.) It's M+ 1mn Light (M+ fonts, Type 1, monospace). I think the whole family is attractive & readable and for programming on OS X I wanted something with a lighter font weight (it's got 5) to compensate for OS X's overly heavy rendering of light text on dark backgrounds. For Linux/BSD terms I tend to use either the medium weight or use monofur.

Samples: http://mplus-fonts.sourceforge.jp/mplus-outline-fonts/design... Design: http://mplus-fonts.sourceforge.jp/mplus-outline-fonts/index-... Bitmap font which I havent used: http://mplus-fonts.sourceforge.jp/mplus-bitmap-fonts/design/...

-----

bitserf 420 days ago | link

Awesome, thank you! Spent 30 minutes this morning running through Identifont with no luck :)

Think I prefer prefer the look of the regular weight on high DPI though:

Regular: http://cl.ly/image/0r3B1M3C2a0I Light: http://cl.ly/image/2Q1s0m1a0z3R

-----

nieve 420 days ago | link

You're welcome. I never think of it as an obscure font family so I didn't list it, but I guess it's not so well known. I can see what you mean about high-dpi though Regular is still a bit too heavy for my tastes, I've just spent too many years on linux terminals that render light-on-dark much lighter. I run at 12-14pt in iTerm2 on a low res 13" mbp, so that may make a big difference as well.

-----

swah 418 days ago | link

That looks a lot like Pragmata Pro.

-----

espadrine 420 days ago | link

Not Ubuntu. The middle vertical bar in the m would be shorter.

I'm wondering what font this is, too.

-----

olgeni 420 days ago | link

> I have to say that emacs looks awful

I thought pretty much the same, until I recompiled it using Athena widgets, which brought it back to its intended glory.

-----

mietek 420 days ago | link

Can you share a screenshot?

-----

alexott 420 days ago | link

What do you want to achieve? "Beautiful" is very different for different people :-)

I'm using my own color scheme (example, https://img-fotki.yandex.ru/get/3314/ottalex.5/0_23992_5fbf7...). If you want, you can grab my configs from https://github.com/alexott/emacs-configs/ (mac os x-specific parts in rc/emacs-rc-local-flash.el)

-----

justinhj 420 days ago | link

I quite like the cyberpunk color theme. Wondered if it was a bit gimmicky at first, but it has stuck. http://imgur.com/eRnb1uL https://github.com/n3mo/cyberpunk-theme.el

-----

terhechte 420 days ago | link

My current vim looks like this, I rather like it dark etc

http://appventure.me/vim.png

-----

gexla 420 days ago | link

Did you try Emacs in the terminal? If Vim looks good in your terminal, then Emacs should be about the same.

-----

tephra 420 days ago | link

What is your current config?

Looks like you want global-linum-mode to get line numbering. then to remove tool, menu and scroll bars do (tool-bar-mode -1) (menu-bar-mode -1) (scroll-bar-mode -1)

-----

claudius 420 days ago | link

I found global-linum-mode to be rather slow in large files, unfortunately. Are there better alternatives that show the number for each line? At the moment, I’m using column-number-mode to see the current line/column in the status bar, but I’m not too happy with it.

-----

npsimons 420 days ago | link

I know it's probably a personal preference thing, but do you really need line numbers? I've never missed them. Even if I'm not jumping to a compile error (or grep result, etc) with M-g n, I can always go to a particular line with M-g g, or show what line the cursor is on with what-line. I've also got flymake next and previous warnings mapped to similar keys.

-----

derengel 420 days ago | link

Where can I find that vim color theme? Did you had to do anything special on a 256 color terminal to make it work?

-----

terhechte 420 days ago | link

The config is on my github.com/terhechte can't look it up right now I'm on a wedding, color scheme is jellybeans :)

-----




Guidelines | FAQ | Lists | Bookmarklet | DMCA | News News | Bugs and Feature Requests | Y Combinator | Apply | Library | Contact

Search: