Skip to content

Commit 356b9c3

Browse files
committed
Removed tabbar, workgroups2, auto-complete. Added company mode, persp-mode. Updated ein.
1 parent ccfe764 commit 356b9c3

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+10781
-6486
lines changed

appearance.el

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
1-
;; Taken from https://github.com/jimeh/.emacs.d and edited by me.
1+
;;----------------------- Cursor ------------------------
2+
(setq-default cursor-type 'hollow)
23

4+
;; Taken from https://github.com/jimeh/.emacs.d and edited by me.
35
;; Disable splash page
46
(setq inhibit-startup-message t)
57

8+
;;----------------------- Fonts ------------------------
69
;; Set the default font
710
;; Large
811
(set-face-attribute 'default nil :family "Inconsolata" :height 110)
@@ -13,6 +16,8 @@
1316
;; (set-face-attribute 'default nil :family "Menlo" :height 100)
1417
;; (set-face-attribute 'default nil :family "Inconsolata" :height 110)
1518

19+
20+
;;----------------------- Theme ------------------------
1621
;; Change the appearance in GUI and terminal frames
1722
(add-to-list 'load-path "~/.emacs.d/themes")
1823
(add-to-list 'custom-theme-load-path "~/.emacs.d/themes")
@@ -233,6 +238,8 @@
233238

234239
;; Cursor
235240
(blink-cursor-mode t)
241+
; Never stop blinking the cursor. Default: stop after 10 blinks.
242+
(setq blink-cursor-blinks 0)
236243
(setq initial-frame-alist
237244
(cons '(cursor-type . bar) (copy-alist initial-frame-alist)))
238245
(setq default-frame-alist
@@ -264,3 +271,44 @@
264271
;; (let ((my-linum-current-line-number (line-number-at-pos)))
265272
;; ad-do-it))
266273
;; (ad-activate 'linum-update)
274+
275+
;;----------------------- White space Mode ----------------------
276+
;; display only tails of lines longer than 110 columns, tabs and
277+
;; trailing white spaces
278+
(require 'whitespace)
279+
(setq whitespace-line-column 110)
280+
(setq-default whitespace-style '(face tabs trailing lines-tail))
281+
282+
;; face for long lines' tails
283+
(set-face-attribute 'whitespace-line nil
284+
:background "#31191f"
285+
:foreground "yellow"
286+
:weight 'bold)
287+
288+
;; face for Tabs
289+
(set-face-attribute 'whitespace-tab nil
290+
:background "#31191f"
291+
:foreground "yellow"
292+
:weight 'bold)
293+
;; face for spaces
294+
(set-face-attribute 'whitespace-trailing nil
295+
:background "#31191f"
296+
:foreground "yellow"
297+
:weight 'bold)
298+
299+
;; Customize Whitespace Characters
300+
;; - Newline: \u00AC = ¬
301+
;; - Tab: \u2192 = →
302+
;; \u00BB = »
303+
;; \u25B6 = ▶
304+
(setq whitespace-display-mappings
305+
(quote ((newline-mark ?\n [?\u00AC ?\n] [?$ ?\n])
306+
(tab-mark ?\t [?\u2192 ?\t] [?\u00BB ?\t] [?\\ ?\t]))))
307+
308+
(setq whitespace-style
309+
(quote (face tabs trailing space-before-tab newline
310+
indentation space-after-tab tab-mark newline-mark
311+
empty)))
312+
313+
;; activate minor whitespace mode for all files.
314+
(global-whitespace-mode t)

conf.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
; Allow files to end with a blank line
4242
(setq require-final-newline t)
4343

44-
;;-----------------------= Mouse ----------------------------
44+
;;------------------------ Mouse ----------------------------
4545

4646
; Enable the mouse in a regular terminal
4747
(cond (window-system

init.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,4 +55,4 @@
5555
;; If you edit it by hand, you could mess it up, so be careful.
5656
;; Your init file should contain only one such instance.
5757
;; If there is more than one, they won't work right.
58-
'(org-hide ((((background light)) (:foreground "black")) (((background dark)) (:foreground "black")))))
58+
'(org-hide ((((background light)) (:foreground "DarkSlateGray")) (((background dark)) (:foreground "DarkSlateGray")))))

looks.el

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
1-
;;---------------------- Formato -----------------------
1+
;;----------------------- Cursor ------------------------
2+
(setq cursor-type "box")
3+
4+
;;----------------------- Fonst ------------------------
25

36
; Font size, type, position, etc...
47
;; (setq default-frame-alist
58
;; '(
6-
;; (font . "-*-lucidatypewriter-*-*-*-*-14-140-*-*-*-*-*")
7-
;; (frame-title-format '("%b"))
8-
;; ))
9+
;; (font . "-*-lucidatypewriter-*-*-*-*-14-140-*-*-*-*-*")
10+
;; (frame-title-format '("%b"))
11+
;; ))
912
(set-default-font "Inconsolata-11")
1013

1114
;;------------------ Emacs Colors ----------------------
@@ -18,6 +21,8 @@
1821
(set-mouse-color "black") ; Mouse color
1922
(set-cursor-color "blue") ; Cursor color
2023

24+
;;------------------------ Misc Things -----------------------
25+
2126
; Use color highlighting if supported
2227
(global-font-lock-mode t)
2328
; Let parentheses be closed

modes.el

Lines changed: 0 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,51 +1,6 @@
11
;;------------------------- Markdown Mode -----------------------
22
(autoload 'markdown-mode "markdown-mode" "Major mode for editing Markdown files" t)
33

4-
;;----------------------- White space Mode ----------------------
5-
6-
;; display only tails of lines longer than 80 columns, tabs and
7-
;; trailing white spaces
8-
(require 'whitespace)
9-
(setq whitespace-line-column 110)
10-
(setq-default whitespace-style '(face tabs trailing lines-tail))
11-
12-
;; face for long lines' tails
13-
(set-face-attribute 'whitespace-line nil
14-
:background "#31191f"
15-
:foreground "yellow"
16-
:weight 'bold)
17-
18-
;; face for Tabs
19-
(set-face-attribute 'whitespace-tab nil
20-
:background "#31191f"
21-
:foreground "yellow"
22-
:weight 'bold)
23-
;; face for spaces
24-
(set-face-attribute 'whitespace-trailing nil
25-
:background "#31191f"
26-
:foreground "yellow"
27-
:weight 'bold)
28-
29-
;; Customize Whitespace Characters
30-
;; - Newline: \u00AC = ¬
31-
;; - Tab: \u2192 = →
32-
;; \u00BB = »
33-
;; \u25B6 = ▶
34-
(setq whitespace-display-mappings
35-
(quote ((newline-mark ?\n [?\u00AC ?\n] [?$ ?\n])
36-
(tab-mark ?\t [?\u2192 ?\t] [?\u00BB ?\t] [?\\ ?\t]))))
37-
38-
(setq whitespace-style
39-
(quote (face tabs trailing space-before-tab newline
40-
indentation space-after-tab tab-mark newline-mark
41-
empty)))
42-
43-
;; activate minor whitespace mode for all files.
44-
(global-whitespace-mode t)
45-
46-
;(add-hook 'js-mode-hook 'whitespace-mode)
47-
48-
494
;;-------------------------- CC Mode ---------------------------
505
; Changes that apply to all C-like languages such as java, objective-c and awk.
516
(add-hook 'c-mode-common-hook

plugins.el

Lines changed: 42 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,6 @@
4848

4949
(global-set-key (kbd "C-x g") 'magit-status)
5050

51-
;;--------------------- Key Chords -----------------------
52-
;; (require 'key-chord)
53-
;; (key-chord-define-global "fg" 'forward-word)
54-
;; (key-chord-define-global "df" 'backward-word)
55-
;; (key-chord-define-global "hj" 'undo)
56-
;; (key-chord-mode 1)
57-
5851
;;------------------- Switch Window ----------------------
5952
(require 'switch-window)
6053
(global-set-key (kbd "C-x o") 'switch-window)
@@ -117,80 +110,60 @@
117110
(define-key helm-gtags-mode-map (kbd "C-c <") 'helm-gtags-previous-history)
118111
(define-key helm-gtags-mode-map (kbd "C-c >") 'helm-gtags-next-history)
119112

120-
;;-------------------- Workgroups ------------------------
121-
(require 'workgroups2)
122-
;; Prefix key
123-
(setq wg-prefix-key (kbd "C-c w"))
124-
(setq wg-session-file "~/.emacs.d/.workgroups")
125-
;; Keyboard shortcuts - load, save, switch
126-
(global-set-key (kbd "<pause>") 'workgroups-mode)
127-
(global-set-key (kbd "C-<pause>") 'wg-save-session)
128-
(global-set-key (kbd "s-z") 'wg-switch-to-workgroup)
129-
(global-set-key (kbd "s-/") 'wg-switch-to-previous-workgroup)
130-
(set-face-attribute 'wg-brace-face nil :inherit font-lock-builtin-face :weight 'normal :height 0.8)
131-
(set-face-attribute 'wg-divider-face nil :inherit font-lock-builtin-face :weight 'normal :height 0.8)
132-
(set-face-attribute 'wg-mode-line-face nil :weight 'thin :height 0.8)
133-
; When using emacs as a daemon, do not load the WGs automatically.
134-
;(setq wg-use-default-session-file nil)
135-
;; Do not start it by default.
136-
;(workgroups-mode 1)
137-
138-
;;----------------------- IDO ---------------------------
139-
;; (require 'ido)
140-
;; (ido-mode)
141-
;; ;; Display ido results vertically, rather than horizontally.
142-
;; (require 'ido-vertical-mode)
143-
;; (ido-vertical-mode 1)
144-
;; ;; Use ido completion in projectile.
145-
;; (setq projectile-completion-system 'ido)
113+
;;-------------------- persp-mode ------------------------
114+
(require 'persp-mode)
115+
(global-set-key (kbd "<pause>") 'persp-mode)
116+
(global-set-key (kbd "s-z") 'persp-switch)
117+
; Location where perspectives are stored.
118+
(setq persp-save-dir "/home/boy/.emacs.d/.persp/")
119+
; Load the auto saved perpectives as soon as persp-mode is activated.
120+
(setq persp-auto-resume-time 0.1)
146121

147122
;;------------------ Maximize Window --------------------
148-
;(require 'maxframe)
149-
;(setq mf-max-width 1920)
150-
;(add-hook 'window-setup-hook 'maximize-frame t)
151123
(add-to-list 'initial-frame-alist '(fullscreen . maximized))
152-
;(add-to-list 'default-frame-alist '(fullscreen . maximized))
153124

154125
;;-------------------- Yasnippet ------------------------
155126
(add-to-list 'load-path "~/.emacs.d/plugins/yasnippet")
156127
(require 'yasnippet)
157128
;(yas-reload-all)
158129
(yas-global-mode 1)
159130
; Display a popup for the available options.
160-
(add-to-list 'load-path "~/.emacs.d/plugins/auto-complete/lib/popup")
161-
(require 'popup)
162-
; Add some shotcuts in popup menu mode
163-
(define-key popup-menu-keymap (kbd "M-n") 'popup-next)
164-
(define-key popup-menu-keymap (kbd "TAB") 'popup-next)
165-
(define-key popup-menu-keymap (kbd "<tab>") 'popup-next)
166-
(define-key popup-menu-keymap (kbd "<backtab>") 'popup-previous)
167-
(define-key popup-menu-keymap (kbd "M-p") 'popup-previous)
168-
169-
(defun yas-popup-isearch-prompt (prompt choices &optional display-fn)
170-
(when (featurep 'popup)
171-
(popup-menu*
172-
(mapcar
173-
(lambda (choice)
174-
(popup-make-item
175-
(or (and display-fn (funcall display-fn choice))
176-
choice)
177-
:value choice))
178-
choices)
179-
:prompt prompt
180-
;; start isearch mode immediately
181-
:isearch t
182-
)))
183-
(setq yas-prompt-functions '(yas-popup-isearch-prompt yas-no-prompt))
184-
;; (add-hook 'js-mode-hook
185-
;; '(lambda ()
186-
;; (yas-minor-mode)))
131+
;; (add-to-list 'load-path "~/.emacs.d/plugins/auto-complete/lib/popup")
132+
;; (require 'popup)
133+
;; ; Add some shotcuts in popup menu mode
134+
;; (define-key popup-menu-keymap (kbd "M-n") 'popup-next)
135+
;; (define-key popup-menu-keymap (kbd "TAB") 'popup-next)
136+
;; (define-key popup-menu-keymap (kbd "<tab>") 'popup-next)
137+
;; (define-key popup-menu-keymap (kbd "<backtab>") 'popup-previous)
138+
;; (define-key popup-menu-keymap (kbd "M-p") 'popup-previous)
139+
140+
;; (defun yas-popup-isearch-prompt (prompt choices &optional display-fn)
141+
;; (when (featurep 'popup)
142+
;; (popup-menu*
143+
;; (mapcar
144+
;; (lambda (choice)
145+
;; (popup-make-item
146+
;; (or (and display-fn (funcall display-fn choice))
147+
;; choice)
148+
;; :value choice))
149+
;; choices)
150+
;; :prompt prompt
151+
;; ;; start isearch mode immediately
152+
;; :isearch t
153+
;; )))
154+
;; (setq yas-prompt-functions '(yas-popup-isearch-prompt yas-no-prompt))
155+
156+
;;---------------------- Company Mode----------------------
157+
(add-to-list 'load-path "~/.emacs.d/plugins/company-mode")
158+
(require 'company)
159+
(add-hook 'after-init-hook 'global-company-mode)
187160

188161
;;--------------------- Auto Complete----------------------
189-
(add-to-list 'load-path "~/.emacs.d/plugins/auto-complete")
190-
(require 'auto-complete-config)
191-
(add-to-list 'ac-dictionary-directories "~/.emacs.d/plugins/auto-complete/dict")
192-
(setq ac-comphist-file "~/.emacs.d/plugins/auto-complete/ac-comphist.dat")
193-
(ac-config-default)
162+
;; (add-to-list 'load-path "~/.emacs.d/plugins/auto-complete")
163+
;; (require 'auto-complete-config)
164+
;; (add-to-list 'ac-dictionary-directories "~/.emacs.d/plugins/auto-complete/dict")
165+
;; (setq ac-comphist-file "~/.emacs.d/plugins/auto-complete/ac-comphist.dat")
166+
;; (ac-config-default)
194167
; set the trigger key so that it can work together with yasnippet on tab key,
195168
; if the word exists in yasnippet, pressing tab will cause yasnippet to
196169
; activate, otherwise, auto-complete will
@@ -200,14 +173,3 @@
200173

201174
;;-------------------- Smooth Scroll ----------------------
202175
(require 'smooth-scrolling)
203-
204-
;;----------------------- Tabbar --------------------------
205-
206-
;; (cond (window-system
207-
;; (require 'tabbar)
208-
;; (tabbar-mode 1)
209-
;; (global-set-key [(control shift up)] 'tabbar-backward-group)
210-
;; (global-set-key [(control shift down)] 'tabbar-forward-group)
211-
;; (global-set-key [(control shift left)] 'tabbar-backward)
212-
;; (global-set-key [(control shift right)] 'tabbar-forward)
213-
;; ))

0 commit comments

Comments
 (0)