Aquamacs Customisation

sc-web-bar

I have finally gotten round to customising Aquamacs so that it opens by default with certain preferences. (Aquamacs is the default code editor used by, and packaged with, slippery chicken.)

Here’s a screen-shot:

Screen Shot 2015-12-04 at 14.11.37.png

If you want to do the same, then just copy the following code into the init file and save. It’s as easy as that! Of course, you can always hack the code to make it look however you want it to too.

The init file can be found here:

“/Applications/slippery-chicken-osx.app/Contents/Resources/sc.el”

NB: I do not know where your init file is if you are not running sc on a mac using the app. You’ll have to locate it for yourself.

;; Set the colour theme and highlighting
;; Taken from http://www.cs.berkeley.edu/~prmohan/emacs/
;; Thanks to Prashanth Mohan
(require 'color-theme)
(color-theme-initialize)
(color-theme-clarity)
(defface hl-line '((t (:background "DarkSlateGrey")))
 "Face to use for `hl-line-face'." :group 'hl-line)
(setq hl-line-face 'hl-line)
(global-hl-line-mode t) ; turn it on for all modes by default


;; Turn on line numbering
(global-linum-mode t)

;; Split the window into 2 panes, left and the right (rather
;; than up and down)
(split-window-horizontally)

;; Sizes of the new panes in 1280 x 800 display
(setq default-frame-alist 
    (add-to-list 'default-frame-alist '(width . 640)))
(setq default-frame-alist 
    (add-to-list 'default-frame-alist '(height . 400)))

;; Use the commands "control+x" followed by an arrow to 
;; navigate between panes
(global-set-key (kbd "C-x ") 'windmove-up)
(global-set-key (kbd "C-x ") 'windmove-down)
(global-set-key (kbd "C-x ") 'windmove-left)
(global-set-key (kbd "C-x ") 'windmove-right)

;; DJR - Thu 13 Oct 2016 10:55:12 BST
;; Stop Aquamacs asking to save changes each time
(custom-set-variables '(aquamacs-save-options-on-quit nil))

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s