View previous topic :: View next topic |
Author |
Message |
miqorz Veteran
Joined: 04 Apr 2004 Posts: 1170 Location: Pissing into the wind.
|
Posted: Fri Aug 20, 2004 3:55 am Post subject: Emacs users. |
|
|
I'm a long time vim user.. But I wan't to give emacs a fair chance..
But I can't figure out two things..
How can I get it to be colorful, and how can I use the File menu and stuff ? (Using emacs -nw)
You can see what I'm tallking about in this screenshot.
http://vico.kleinplanet.de/fonts/2003-02-25-224317_433x501_scrot.png
I know that's jed but it still shows what I'm talking about.
I've tried googling this but as usual it left me more confused. |
|
Back to top |
|
|
Athas Guru
Joined: 04 Sep 2003 Posts: 394 Location: Brøndby, Denmark
|
|
Back to top |
|
|
untiefe Apprentice
Joined: 12 Jan 2004 Posts: 230 Location: the nonexisting Bielefeld, Germany
|
Posted: Fri Aug 20, 2004 7:36 am Post subject: |
|
|
Hi!
I don't know about the file menu (I just know all keybord-shortcuts I need) but to get everything colorful, you have to set the font-lock-mode. I just post my .emacs file, so you can see what to set. There is some part for writing ebuilds in color and for auctex as well (emerge =app-emacs/auctex) and for the html-helper (but I never wrote an ebuild for that - its still on my ToDo-list )
Code: |
;; Are we running XEmacs or Emacs?
(defvar running-xemacs (string-match "XEmacs\\|Lucid" emacs-version))
;; Set up the keyboard so the delete key on both the regular keyboard
;; and the keypad delete the character under the cursor and to the right
;; under X, instead of the default, backspace behavior.
(global-set-key [delete] 'delete-char)
(global-set-key [kp-delete] 'delete-char)
;; Turn on font-lock mode for Emacs
(cond ((not running-xemacs)
(global-font-lock-mode t)
))
;; Visual feedback on selections
(setq-default transient-mark-mode t)
;; Stop at the end of the file, not just add lines
(setq next-line-add-newlines nil)
;; automatischer Zeilenumbruch im Text-Modus nach 72 Zeichen
(setq default-major-mode 'text-mode)
(setq text-mode-hook
'(lambda nil
(setq fill-column 72)
(auto-fill-mode 1)))
;; AUC-TeX (make sure to install the emacs/auctex package)
(load "/usr/share/emacs/site-lisp/site-gentoo")
; highlight matching parentheses next to cursor
(require 'paren)
(show-paren-mode t)
;; Always ask if file should end with a newline
(setq-default require-final-newline "ask")
;; defining stuff for ebuild-editing
(defun ebuild-mode ()
(shell-script-mode)
(sh-set-shell "bash")
(make-local-variable 'tab-width)
(setq tab-width 4))
(setq auto-mode-alist (cons '("\\.ebuild\\'" . ebuild-mode) auto-mode-alist))
(setq auto-mode-alist (cons '("\\.eclass\\'" . ebuild-mode) auto-mode-alist))
;; load html-helper-mode
;; -> put html-helper-mode.el in: /usr/share/emacs/site-lisp/
(autoload 'html-helper-mode "html-helper-mode" "Yay HTML" t)
(setq auto-mode-alist (cons '("\\.html$" . html-helper-mode) auto-mode-alist))
(setq auto-mode-alist (cons '("\\.htm$" . html-helper-mode) auto-mode-alist))
(setq auto-mode-alist (cons '("\\.wml$" . html-helper-mode) auto-mode-alist))
|
_________________ "I'm an angel bored like hell
And you're a devil meaning well"
:: Cardigans - You're The Storm ::
glcu - gentoo linux cron update (full featured semi-automatic updates via cron) |
|
Back to top |
|
|
miqorz Veteran
Joined: 04 Apr 2004 Posts: 1170 Location: Pissing into the wind.
|
Posted: Fri Aug 20, 2004 8:05 am Post subject: |
|
|
Athas wrote: |
For the menu, just press F10. |
Hmm.. That doesn't seem to work.. |
|
Back to top |
|
|
allucid Veteran
Joined: 02 Nov 2002 Posts: 1314 Location: atlanta
|
Posted: Fri Aug 20, 2004 5:33 pm Post subject: |
|
|
oddly enough I am a long time emacs user starting to explore vim in more detail.
I don't use the menu much in emacs but when I need to I access it with M-`
Note that this is a different method of accessing the menu than what is shown in your screenshot. you have to use jed to have pull down menus.
add this to your .emacs for basic syntax highlighting:
Code: | (setq font-lock-maximum-decoration t)
(global-font-lock-mode t) |
|
|
Back to top |
|
|
|