author | Oleksandr Gavenko <gavenkoa@gmail.com> |
Wed, 12 May 2010 19:03:48 +0300 | |
changeset 397 | c743dacafbce |
parent 394 | 03d8b85ff815 |
parent 396 | 3414288e4a61 |
child 398 | 47a3e4de976e |
child 399 | d61236d0cd38 |
permissions | -rw-r--r-- |
348
c154331ffb7c
Set fill-column for file.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
347
diff
changeset
|
1 |
;; -*- mode: lisp; coding: utf-8; fill-column: 78 -*- |
6 | 2 |
;; |
279
fd6164dfec82
Update copyright statement and year.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
272
diff
changeset
|
3 |
;; Written by Oleksandr Gavenko <gavenkoa@gmail.com>, 2008-2010. |
6 | 4 |
;; |
121 | 5 |
;; This file formed from parts and ideas from many sites/docs and |
110
6b6e3f8cb371
Set copyright notice.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
109
diff
changeset
|
6 |
;; placed in public domain. |
6b6e3f8cb371
Set copyright notice.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
109
diff
changeset
|
7 |
;; |
302
e93ff9360a51
Point to README from config file.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
299
diff
changeset
|
8 |
;; Config file for GNU Emacs. |
83
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
9 |
;; |
351
e30e4bd7e85e
Small spell correction.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
348
diff
changeset
|
10 |
;; For load order see README. |
0 | 11 |
|
12 |
;; ====================================================================== |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
13 |
;; debugging. |
0 | 14 |
|
175
a505ab71060a
Make comment shorter.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
174
diff
changeset
|
15 |
;; Shut off message buffer by setting nil. |
252
330b4cdfaddf
Increase log message count.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
251
diff
changeset
|
16 |
(setq message-log-max 512) |
0 | 17 |
|
18 |
;; Set the debug option to enable a backtrace when a problem occurs. |
|
19 |
(setq debug-on-error nil) ; t/nil |
|
20 |
||
333
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
21 |
;; ---------------------------------------------------------------------- |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
22 |
;; mode groups |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
23 |
|
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
24 |
(defvar my-devel-mode-list |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
25 |
'(sh-mode script-mode java-mode c-mode |
376
d4f1dcfdafe6
Added emacs-lisp to my devel mode list.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
375
diff
changeset
|
26 |
makefile-mode makefile-gmake-mode python-mode |
d4f1dcfdafe6
Added emacs-lisp to my devel mode list.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
375
diff
changeset
|
27 |
lisp-mode emacs-lisp-mode) |
333
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
28 |
"List of development modes.") |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
29 |
|
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
30 |
(defvar my-devel-mode-hook-list |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
31 |
'(sh-mode-hook script-mode-hook java-mode-hook c-mode-hook |
376
d4f1dcfdafe6
Added emacs-lisp to my devel mode list.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
375
diff
changeset
|
32 |
makefile-mode-hook makefile-gmake-mode-hook python-mode-hook |
d4f1dcfdafe6
Added emacs-lisp to my devel mode list.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
375
diff
changeset
|
33 |
lisp-mode-hook emacs-lisp-mode-hook) |
333
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
34 |
"List of development mode hooks.") |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
35 |
|
391
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
36 |
(defvar my-scroll-margin-mode-hook-list |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
37 |
'( |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
38 |
vc-dir-mode-hook |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
39 |
recentf-dialog-mode-hook |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
40 |
org-agenda-grid-mode-hook ; XXX for this item not worked! |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
41 |
log-view-mode-hook |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
42 |
diff-mode-hook |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
43 |
) |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
44 |
"List of mode hooks for enabling scroll margin.") |
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
45 |
|
333
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
46 |
(defvar my-text-mode-list |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
47 |
'(outline-mode text-mode) |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
48 |
"List of text modes.") |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
49 |
|
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
50 |
(defvar my-text-mode-hook-list |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
51 |
'(outline-mode-hook text-mode-hook) |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
52 |
"List of text mode hooks.") |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
53 |
|
0 | 54 |
;; ====================================================================== |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
55 |
;; appearance. |
0 | 56 |
|
362
f4bd431ad549
By default start from user home directory (HOME point to it).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
361
diff
changeset
|
57 |
(setq default-directory "~/") |
f4bd431ad549
By default start from user home directory (HOME point to it).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
361
diff
changeset
|
58 |
|
370
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
59 |
;; To maximize frame on full screen, not work with Windows Emacs 21.4. |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
60 |
;; And maked different height with Emacs 22.3 and 23.1. |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
61 |
;; (setq initial-frame-alist '((fullscreen . fullboth))) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
62 |
|
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
63 |
;; Next code work with Emacs 21.4, 22.3, 23.1. |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
64 |
(when window-system |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
65 |
(let ( |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
66 |
(px (display-pixel-width)) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
67 |
(py (display-pixel-height)) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
68 |
(fx (frame-char-width)) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
69 |
(fy (frame-char-height)) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
70 |
tx ty |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
71 |
) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
72 |
;; Next formulas discovered empiric on Windows host with default font. |
373
bdf2522ad35c
On Debian with font 7x13 right part of windows go out of display border.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
372
diff
changeset
|
73 |
(setq tx (- (/ px fx) 7)) |
370
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
74 |
(setq ty (- (/ py fy) 4)) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
75 |
(setq initial-frame-alist '((top . 0) (left . 0))) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
76 |
(add-to-list 'initial-frame-alist (cons 'width tx)) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
77 |
(add-to-list 'initial-frame-alist (cons 'height ty)) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
78 |
) ) |
378a4dc8ea1c
Maximize frame on full screen.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
369
diff
changeset
|
79 |
|
151 | 80 |
(menu-bar-mode -1) |
81 |
(tool-bar-mode -1) |
|
372
32b54537dd10
Code ported to work with Emac 21.4. Mainly problems in undefi8ned functions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
371
diff
changeset
|
82 |
(when (>= emacs-major-version 22) (tooltip-mode -1)) |
151 | 83 |
(scroll-bar-mode 1) |
0 | 84 |
|
338
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
85 |
(setq frame-title-format "Emacs - %b") |
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
86 |
|
363
17df92226b5a
Set default-header-line-format.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
362
diff
changeset
|
87 |
(setq default-header-line-format nil) |
17df92226b5a
Set default-header-line-format.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
362
diff
changeset
|
88 |
;; (setq default-mode-line-format nil) |
17df92226b5a
Set default-header-line-format.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
362
diff
changeset
|
89 |
|
364
3d18cfe179cc
Set default fringe and margin width.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
363
diff
changeset
|
90 |
(setq default-left-fringe-width nil) |
3d18cfe179cc
Set default fringe and margin width.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
363
diff
changeset
|
91 |
(setq default-right-fringe-width nil) |
3d18cfe179cc
Set default fringe and margin width.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
363
diff
changeset
|
92 |
(setq default-left-margin-width nil) |
3d18cfe179cc
Set default fringe and margin width.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
363
diff
changeset
|
93 |
(setq default-right-margin-width nil) |
3d18cfe179cc
Set default fringe and margin width.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
363
diff
changeset
|
94 |
|
365
913375395214
No spasing between text lines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
364
diff
changeset
|
95 |
(setq default-line-spacing nil) |
913375395214
No spasing between text lines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
364
diff
changeset
|
96 |
|
366
223c01e1a084
Don't truncate long lines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
365
diff
changeset
|
97 |
(setq default-truncate-lines nil) |
223c01e1a084
Don't truncate long lines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
365
diff
changeset
|
98 |
|
338
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
99 |
;; show column & line numbers in status bar |
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
100 |
(setq column-number-mode t) |
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
101 |
(setq line-number-mode t) |
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
102 |
|
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
103 |
;; Also useful such format: (setq display-time-format " %H:%M %d-%m-%y ") |
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
104 |
(setq display-time-24hr-format t) |
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
105 |
(setq display-time-default-load-average nil) |
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
106 |
(display-time) ; display-time-mode |
ebf88f988c37
Move some appearance related switch together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
337
diff
changeset
|
107 |
|
0 | 108 |
(if window-system |
218
1a48dde2dfa3
See what I am typing immediately (for keystroke in minibuffer).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
217
diff
changeset
|
109 |
;; For graphical environment. |
0 | 110 |
(progn |
111 |
(set-background-color "white") |
|
112 |
(set-foreground-color "black") |
|
113 |
(set-cursor-color "brown") |
|
331
7515e5a6b3b9
Added set-mouse-color example.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
329
diff
changeset
|
114 |
;; (set-mouse-color "white") |
248 | 115 |
(setq cursor-type 'box) ; box, hollow, bar, hbar |
0 | 116 |
;;(setq blink-matching-delay 0.01) |
243
739a19c76dcc
Always blink cursor.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
242
diff
changeset
|
117 |
(blink-cursor-mode 1) |
0 | 118 |
;; (set-face-font 'default "7x14") |
119 |
) |
|
218
1a48dde2dfa3
See what I am typing immediately (for keystroke in minibuffer).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
217
diff
changeset
|
120 |
;; For tty. |
0 | 121 |
(progn |
122 |
) |
|
123 |
) |
|
124 |
||
218
1a48dde2dfa3
See what I am typing immediately (for keystroke in minibuffer).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
217
diff
changeset
|
125 |
;; See what I am typing immediately (for keystroke in minibuffer). |
1a48dde2dfa3
See what I am typing immediately (for keystroke in minibuffer).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
217
diff
changeset
|
126 |
(setq echo-keystrokes 0.2) |
1a48dde2dfa3
See what I am typing immediately (for keystroke in minibuffer).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
217
diff
changeset
|
127 |
|
85 | 128 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
129 |
;; silent runing. |
85 | 130 |
|
131 |
;; (setq inhibit-splash-screen t) ; nonexist on 21.4.1 |
|
132 |
(setq inhibit-startup-message t) |
|
133 |
||
361
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
134 |
;; ---------------------------------------------------------------------- |
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
135 |
;; whitespaces. |
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
136 |
|
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
137 |
(setq default-indicate-empty-lines t) |
368
a9c688c1b85f
More verbose buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
366
diff
changeset
|
138 |
(setq default-indicate-buffer-boundaries 'left) |
361
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
139 |
|
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
140 |
(setq-default show-trailing-whitespace t) |
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
141 |
|
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
142 |
(setq next-line-add-newlines nil) |
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
143 |
|
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
144 |
;; See also 'mode-require-final-newline'. |
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
145 |
(add-hook 'text-mode-hook (lambda () (setq require-final-newline nil))) |
9dbe92b8b329
Added indicate-buffer-boundaries.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
360
diff
changeset
|
146 |
|
85 | 147 |
;; ====================================================================== |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
148 |
;; gnu serv, server. |
85 | 149 |
|
150 |
;; (load "~/emacs/bin/gnuserv/gnuserv.el") |
|
151 |
;; (require 'gnuserv) |
|
152 |
;; (setq gnuserv-frame (selected-frame)) |
|
153 |
||
372
32b54537dd10
Code ported to work with Emac 21.4. Mainly problems in undefi8ned functions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
371
diff
changeset
|
154 |
(when (>= emacs-major-version 22) |
394
03d8b85ff815
Do not load server.el for Emacs 21.x.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
393
diff
changeset
|
155 |
(require 'server) |
03d8b85ff815
Do not load server.el for Emacs 21.x.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
393
diff
changeset
|
156 |
(when (and (= emacs-major-version 23) (=> emacs-minor-version 1) (=< emacs-minor-version 2) (equal window-system 'w32)) |
03d8b85ff815
Do not load server.el for Emacs 21.x.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
393
diff
changeset
|
157 |
(defun server-ensure-safe-dir (dir) "Noop" t)) ; Suppress error directory ~/.emacs.d/server is unsafe on windows. |
03d8b85ff815
Do not load server.el for Emacs 21.x.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
393
diff
changeset
|
158 |
(server-start) |
03d8b85ff815
Do not load server.el for Emacs 21.x.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
393
diff
changeset
|
159 |
) |
85 | 160 |
|
161 |
;; (desktop-load-default) |
|
162 |
;; (desktop-read) |
|
163 |
||
0 | 164 |
;; ====================================================================== |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
165 |
;; standart/general settings. |
0 | 166 |
|
336
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
167 |
(if (boundp 'confirm-kill-emacs) |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
168 |
(setq confirm-kill-emacs 'yes-or-no-p)) |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
169 |
|
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
170 |
;; Try to speed things up, especially in VM. |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
171 |
(setq gc-cons-threshold 2000000) |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
172 |
|
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
173 |
;; Don't beep in my headphones! |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
174 |
(setq ring-bell-function '(lambda () "Empty ring-bell-function." nil)) |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
175 |
(setq visible-bell t) ; With default ring-bell-function in text terminal |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
176 |
; revert screen if press [end] or [home] |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
177 |
|
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
178 |
;; Prompt before evaluating local bits of lisp. This stops people |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
179 |
;; putting things at the end of files which delete all your files! |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
180 |
(setq enable-local-variables t |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
181 |
enable-local-eval 1) |
a252995f7d6b
Move general getting into one place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
335
diff
changeset
|
182 |
|
0 | 183 |
(setq kill-whole-line t) |
184 |
||
102
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
185 |
(setq view-read-only t) |
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
186 |
|
171
2f2aae1d394c
Set read-quoted-char-radix.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
169
diff
changeset
|
187 |
(setq read-quoted-char-radix 16) |
2f2aae1d394c
Set read-quoted-char-radix.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
169
diff
changeset
|
188 |
|
344
b7d0989d9472
generic-define-* before (require 'generic-x) allow load all useful extra modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
342
diff
changeset
|
189 |
;; generic-define-* before (require 'generic-x) allow load all useful extra modes. |
b7d0989d9472
generic-define-* before (require 'generic-x) allow load all useful extra modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
342
diff
changeset
|
190 |
(setq generic-define-mswindows-modes t) |
b7d0989d9472
generic-define-* before (require 'generic-x) allow load all useful extra modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
342
diff
changeset
|
191 |
(setq generic-define-unix-modes t) |
341
84db44766351
Remove bat-file-mode as it present in generic-x.el.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
339
diff
changeset
|
192 |
(require 'generic-x) |
84db44766351
Remove bat-file-mode as it present in generic-x.el.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
339
diff
changeset
|
193 |
|
345
90b5ae643a6d
Move code to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
344
diff
changeset
|
194 |
;; The following commands are usually disabled by default. Enable them... |
90b5ae643a6d
Move code to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
344
diff
changeset
|
195 |
(put 'eval-expression 'disabled nil) |
90b5ae643a6d
Move code to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
344
diff
changeset
|
196 |
(put 'downcase-region 'disabled nil) |
90b5ae643a6d
Move code to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
344
diff
changeset
|
197 |
(put 'upcase-region 'disabled nil) |
90b5ae643a6d
Move code to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
344
diff
changeset
|
198 |
(put 'narrow-to-page 'disabled nil) |
90b5ae643a6d
Move code to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
344
diff
changeset
|
199 |
(put 'narrow-to-region 'disabled nil) |
90b5ae643a6d
Move code to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
344
diff
changeset
|
200 |
(put 'scroll-left 'disabled nil) |
90b5ae643a6d
Move code to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
344
diff
changeset
|
201 |
|
35
691635158df5
More pretty buffer switch and naming.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
34
diff
changeset
|
202 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
203 |
;; switching, creating, selecting buffers. |
244
5db897a3f1cd
buffer-menu better then buffer-list, but ibuffer much better.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
243
diff
changeset
|
204 |
|
34 | 205 |
(iswitchb-mode 1) |
122
680d4677e3fe
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
121
diff
changeset
|
206 |
(setq iswitchb-buffer-ignore nil) |
680d4677e3fe
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
121
diff
changeset
|
207 |
(mapc (lambda (arg) (add-to-list 'iswitchb-buffer-ignore arg)) |
680d4677e3fe
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
121
diff
changeset
|
208 |
'("^ " |
680d4677e3fe
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
121
diff
changeset
|
209 |
"^\*Buffer" |
680d4677e3fe
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
121
diff
changeset
|
210 |
"^\*Completions\*" |
123
7c1f68e5b898
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
122
diff
changeset
|
211 |
"^\*tramp" |
7c1f68e5b898
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
122
diff
changeset
|
212 |
"^\*Dired log\*" |
7c1f68e5b898
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
122
diff
changeset
|
213 |
"^\*Help\*" |
122
680d4677e3fe
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
121
diff
changeset
|
214 |
"^\*Quail Completions\*" |
123
7c1f68e5b898
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
122
diff
changeset
|
215 |
"^\*Disabled Command\*" |
7c1f68e5b898
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
122
diff
changeset
|
216 |
"^\*vc\*" |
7c1f68e5b898
Extend innore buffers by iswitch.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
122
diff
changeset
|
217 |
)) |
34 | 218 |
|
35
691635158df5
More pretty buffer switch and naming.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
34
diff
changeset
|
219 |
(require 'uniquify) |
691635158df5
More pretty buffer switch and naming.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
34
diff
changeset
|
220 |
(setq uniquify-buffer-name-style 'post-forward) |
691635158df5
More pretty buffer switch and naming.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
34
diff
changeset
|
221 |
|
244
5db897a3f1cd
buffer-menu better then buffer-list, but ibuffer much better.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
243
diff
changeset
|
222 |
;; buffer-menu better then buffer-list, but ibuffer much better. |
5db897a3f1cd
buffer-menu better then buffer-list, but ibuffer much better.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
243
diff
changeset
|
223 |
(global-set-key "\C-x\C-b" 'ibuffer) |
35
691635158df5
More pretty buffer switch and naming.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
34
diff
changeset
|
224 |
|
0 | 225 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
226 |
;; scrolling. |
0 | 227 |
|
339
4e131c57a0ef
With scroll-step 3 when go down it scroll one line but if up - 3 so set
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
338
diff
changeset
|
228 |
(defvar my-scroll-margin 4) |
4e131c57a0ef
With scroll-step 3 when go down it scroll one line but if up - 3 so set
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
338
diff
changeset
|
229 |
|
127 | 230 |
(setq-default |
339
4e131c57a0ef
With scroll-step 3 when go down it scroll one line but if up - 3 so set
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
338
diff
changeset
|
231 |
scroll-step 1 |
4e131c57a0ef
With scroll-step 3 when go down it scroll one line but if up - 3 so set
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
338
diff
changeset
|
232 |
scroll-conservatively my-scroll-margin |
127 | 233 |
scroll-preserve-screen-position t |
234 |
) |
|
235 |
||
333
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
236 |
;; Set margin only for desired modes! Do not frustrate calendar any more. |
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
237 |
(make-variable-buffer-local 'scroll-margin) |
339
4e131c57a0ef
With scroll-step 3 when go down it scroll one line but if up - 3 so set
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
338
diff
changeset
|
238 |
(mapc (lambda (hook) (add-hook hook (lambda nil (setq scroll-margin my-scroll-margin)))) |
372
32b54537dd10
Code ported to work with Emac 21.4. Mainly problems in undefi8ned functions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
371
diff
changeset
|
239 |
;; TODO its good invoke delete-dups for list, but delete-dups not exist in Emacs 21.4 |
391
09cfea42153e
Added list of mode hooks for enabling scroll margin.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
389
diff
changeset
|
240 |
(append my-text-mode-hook-list my-devel-mode-hook-list my-scroll-margin-mode-hook-list) ) |
333
14b07ca8335a
Set margin only for desired modes! Do not frustrate calendar any more.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
332
diff
changeset
|
241 |
|
127 | 242 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
243 |
;; searching. |
254
51b47da56551
Highlight on search and repalce.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
253
diff
changeset
|
244 |
|
217
1c42ba3ac4ba
Case insensitive search. Group search customization together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
216
diff
changeset
|
245 |
(setq case-fold-search t) |
1c42ba3ac4ba
Case insensitive search. Group search customization together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
216
diff
changeset
|
246 |
|
254
51b47da56551
Highlight on search and repalce.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
253
diff
changeset
|
247 |
(setq query-replace-highlight t) ; highlight during query |
51b47da56551
Highlight on search and repalce.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
253
diff
changeset
|
248 |
(setq search-highlight t) ; highlight incremental search |
51b47da56551
Highlight on search and repalce.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
253
diff
changeset
|
249 |
|
217
1c42ba3ac4ba
Case insensitive search. Group search customization together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
216
diff
changeset
|
250 |
;; ---------------------------------------------------------------------- |
1c42ba3ac4ba
Case insensitive search. Group search customization together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
216
diff
changeset
|
251 |
;; *Occur* |
1c42ba3ac4ba
Case insensitive search. Group search customization together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
216
diff
changeset
|
252 |
(global-set-key [f7] 'occur) ; Key binding as in mc |
1c42ba3ac4ba
Case insensitive search. Group search customization together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
216
diff
changeset
|
253 |
|
1c42ba3ac4ba
Case insensitive search. Group search customization together.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
216
diff
changeset
|
254 |
;; ---------------------------------------------------------------------- |
356
fd1af7a494de
Added key binding for rgrep.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
355
diff
changeset
|
255 |
;; grep, find. |
357
84c8c5f03fd4
Correct grep command.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
356
diff
changeset
|
256 |
|
84c8c5f03fd4
Correct grep command.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
356
diff
changeset
|
257 |
;; Assume that we have GNU grep, so -H available. |
84c8c5f03fd4
Correct grep command.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
356
diff
changeset
|
258 |
(setq grep-command "grep -nH ") |
358
a6fb477c0e19
Assume that we have GNU grep, so -H available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
357
diff
changeset
|
259 |
;; Assume that we have GNU grep, so -H available. |
a6fb477c0e19
Assume that we have GNU grep, so -H available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
357
diff
changeset
|
260 |
(setq grep-template "grep <C> -nH <R> <F>") |
357
84c8c5f03fd4
Correct grep command.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
356
diff
changeset
|
261 |
(setq grep-find-command "find . '(' -name .svn -o -name CVS -o -name .hg -o -name _darcs -o -name .git ')' -prune -o -type f -name '*' -print0 | xargs -0 -e grep -nH ") |
360
88e4e74c0b6c
Set grep-find-template.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
359
diff
changeset
|
262 |
;; This pattern oriented to POSIX like sh shell and availability of GNU grep for -H option. |
88e4e74c0b6c
Set grep-find-template.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
359
diff
changeset
|
263 |
(setq grep-find-template "find . <X> -type f <F> -exec grep <C> -nH <R> {} \\;") |
357
84c8c5f03fd4
Correct grep command.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
356
diff
changeset
|
264 |
;; Do not set t because some grep do not has --color options. |
84c8c5f03fd4
Correct grep command.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
356
diff
changeset
|
265 |
(setq grep-highlight-matches nil) |
84c8c5f03fd4
Correct grep command.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
356
diff
changeset
|
266 |
(setq grep-use-null-device nil) |
375
1b3ff20c9d5b
Option for find-dired.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
372
diff
changeset
|
267 |
;; For find-dired. |
382
bebb0803780f
Don't override find-ls-option in case of Windows and when cmdproxy used.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
380
diff
changeset
|
268 |
;; (setq find-ls-option '("-exec ls -ld {} \\;" . "-ld")) |
357
84c8c5f03fd4
Correct grep command.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
356
diff
changeset
|
269 |
|
356
fd1af7a494de
Added key binding for rgrep.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
355
diff
changeset
|
270 |
(global-set-key [M-f7] 'rgrep) |
fd1af7a494de
Added key binding for rgrep.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
355
diff
changeset
|
271 |
|
fd1af7a494de
Added key binding for rgrep.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
355
diff
changeset
|
272 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
273 |
;; syntax highlighting. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
274 |
|
0 | 275 |
(setq font-lock-maximum-decoration t) |
395
c7f6eb04626d
Port to Emacs 32.2 (in 'global-font-lock-mode' error - Wrong number of arguments).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
391
diff
changeset
|
276 |
(global-font-lock-mode 1) |
0 | 277 |
|
278 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
279 |
;; highlight selected text. |
64
54ef0d72488f
More pretty with selecting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
63
diff
changeset
|
280 |
|
145
b1fdfc950089
More correct code for pc-select.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
144
diff
changeset
|
281 |
;; 1/-1, when the mark is active, the region is highlighted. |
b1fdfc950089
More correct code for pc-select.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
144
diff
changeset
|
282 |
(transient-mark-mode 1) |
64
54ef0d72488f
More pretty with selecting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
63
diff
changeset
|
283 |
(delete-selection-mode 1) ; 1/-1 |
80
bfc8c3d03527
Correct code to remove warning in *Messages* when loading .emacs-my.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
79
diff
changeset
|
284 |
|
298
9fdaecd9336d
Remove duplicated comments.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
297
diff
changeset
|
285 |
;; Order of next items is important, (assignment must done before pc-selection-mode enabled). |
145
b1fdfc950089
More correct code for pc-select.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
144
diff
changeset
|
286 |
(require 'pc-select) |
298
9fdaecd9336d
Remove duplicated comments.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
297
diff
changeset
|
287 |
(setq pc-select-selection-keys-only t) ; To avoid some key bindings as F6, etc. |
9fdaecd9336d
Remove duplicated comments.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
297
diff
changeset
|
288 |
(setq pc-select-meta-moves-sexps t) |
372
32b54537dd10
Code ported to work with Emac 21.4. Mainly problems in undefi8ned functions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
371
diff
changeset
|
289 |
(cond |
32b54537dd10
Code ported to work with Emac 21.4. Mainly problems in undefi8ned functions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
371
diff
changeset
|
290 |
((= emacs-major-version 21) (pc-selection-mode)) |
32b54537dd10
Code ported to work with Emac 21.4. Mainly problems in undefi8ned functions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
371
diff
changeset
|
291 |
((>= emacs-major-version 22) (pc-selection-mode 1)) |
32b54537dd10
Code ported to work with Emac 21.4. Mainly problems in undefi8ned functions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
371
diff
changeset
|
292 |
) |
64
54ef0d72488f
More pretty with selecting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
63
diff
changeset
|
293 |
|
146
506d2883199f
kill/yank func also use/update CLIPBOARD selsction on X window.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
145
diff
changeset
|
294 |
(when (eq window-system 'x) |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
295 |
(setq x-select-enable-clipboard t) ; for Emacs 21.2.1 and newer |
146
506d2883199f
kill/yank func also use/update CLIPBOARD selsction on X window.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
145
diff
changeset
|
296 |
) |
64
54ef0d72488f
More pretty with selecting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
63
diff
changeset
|
297 |
|
54ef0d72488f
More pretty with selecting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
63
diff
changeset
|
298 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
299 |
;; highlighting current line. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
300 |
|
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
301 |
(when window-system |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
302 |
(custom-set-faces '(hl-line ((t (:inherit highlight :background "light yellow"))))) |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
303 |
(global-hl-line-mode 1) |
0 | 304 |
) |
305 |
||
306 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
307 |
;; paren, braces. |
0 | 308 |
|
309 |
(show-paren-mode 1) ; Parenthesis matching via highlighting. |
|
310 |
(setq show-paren-style (quote parenthesis)) |
|
311 |
||
312 |
;; ====================================================================== |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
313 |
;; keyboard, mouse. |
0 | 314 |
|
52
b0b45dae5d8c
Now C-\ switch to win type keyboard layout.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
51
diff
changeset
|
315 |
;; cyrillic-jcuken for 567 is :,. |
b0b45dae5d8c
Now C-\ switch to win type keyboard layout.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
51
diff
changeset
|
316 |
;; russian-computer for 567 is %^& |
113
78dfaf5e7f04
cyrillic-jcuken is more pretty input method!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
112
diff
changeset
|
317 |
(setq default-input-method 'cyrillic-jcuken) |
52
b0b45dae5d8c
Now C-\ switch to win type keyboard layout.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
51
diff
changeset
|
318 |
|
0 | 319 |
;; (pc-bindings-mode) ; Myself define keybinding, see |
320 |
||
321 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
322 |
;; completition. |
226
14a0e2402d66
partial-completion-mode cause bug in read-file-name with Emacs v22.3.1 (but not with v23.1).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
225
diff
changeset
|
323 |
|
14a0e2402d66
partial-completion-mode cause bug in read-file-name with Emacs v22.3.1 (but not with v23.1).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
225
diff
changeset
|
324 |
;; partial-completion-mode cause bug in read-file-name with Emacs v22.3.1 (but not with v23.1). |
14a0e2402d66
partial-completion-mode cause bug in read-file-name with Emacs v22.3.1 (but not with v23.1).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
225
diff
changeset
|
325 |
;; read-file-name used in rgrep, so I disable partial-completion-mode. |
227
cc94c73ddf20
To disable mode use -1 instead nil.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
226
diff
changeset
|
326 |
(partial-completion-mode -1) ; For example, M-x p-c-m expands to M-x partial-completion-mode |
0 | 327 |
|
328 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
329 |
;; mouse. |
0 | 330 |
|
331 |
;; Scroll Bar gets dragged by mouse butn 1 |
|
332 |
(global-set-key [vertical-scroll-bar down-mouse-1] 'scroll-bar-drag) |
|
333 |
;; Paste at point NOT at cursor |
|
151 | 334 |
(setq mouse-yank-at-point t) |
0 | 335 |
(mouse-wheel-mode 1) |
336 |
||
337 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
338 |
;; key binding, short-keys. |
0 | 339 |
|
340 |
(global-set-key [home] 'beginning-of-line) |
|
341 |
(global-set-key [end] 'end-of-line) |
|
342 |
(global-set-key [C-home] 'beginning-of-buffer) |
|
343 |
(global-set-key [C-end] 'end-of-buffer) |
|
344 |
(global-set-key [C-delete] 'kill-word) |
|
345 |
(global-set-key [delete] 'delete-char) |
|
346 |
;; (global-set-key [backspace] 'backward-delete-char-untabify) ; not work properly in *info* mode |
|
347 |
||
348 |
;; setting some f[1-12] keys |
|
349 |
(global-set-key [f1] 'help) |
|
350 |
(global-set-key [f2] 'save-buffer) |
|
2
98c662ae8707
Incremental search by F3, decr by S-F3 now. Impruved grep-find search.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
1
diff
changeset
|
351 |
;; (global-set-key [xxx] 'ediff-buffers) |
0 | 352 |
(global-set-key [f4] 'ispell-buffer) |
134
a071b60e4339
Set key binding to rename buffer.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
125
diff
changeset
|
353 |
(global-set-key [S-f6] 'rename-buffer) |
0 | 354 |
(global-set-key [f8] 'kill-this-buffer) |
355 |
(global-set-key [M-f4] 'save-buffers-kill-emacs) |
|
18
91626ebef652
Added hotkey for wrap long line.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
17
diff
changeset
|
356 |
(global-set-key [f6] 'toggle-truncate-lines) |
0 | 357 |
|
358 |
;; frames, windows manipulation, switch buffers |
|
359 |
(global-set-key [?\C-x right] 'next-buffer) |
|
360 |
(global-set-key [?\C-x left] 'previous-buffer) |
|
361 |
||
187
3a0f6acd7e2b
I usually mistype "C-x C-f" to "C-x d" or "C-x C-d", correct this.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
186
diff
changeset
|
362 |
;; I usually mistype "C-x C-f" to "C-x d" or "C-x C-d", so always use find-file, |
3a0f6acd7e2b
I usually mistype "C-x C-f" to "C-x d" or "C-x C-d", correct this.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
186
diff
changeset
|
363 |
;; because when file if directory find-file load dired, if regular file open it. |
3a0f6acd7e2b
I usually mistype "C-x C-f" to "C-x d" or "C-x C-d", correct this.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
186
diff
changeset
|
364 |
(global-set-key (kbd "C-x C-f") 'find-file) |
3a0f6acd7e2b
I usually mistype "C-x C-f" to "C-x d" or "C-x C-d", correct this.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
186
diff
changeset
|
365 |
(global-set-key (kbd "C-x C-d") 'find-file) |
3a0f6acd7e2b
I usually mistype "C-x C-f" to "C-x d" or "C-x C-d", correct this.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
186
diff
changeset
|
366 |
(global-set-key (kbd "C-x d") 'find-file) |
8
c33aa66ebb2e
Added highlight for TODO, FIXME, tabs etc.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
7
diff
changeset
|
367 |
|
0 | 368 |
(global-set-key (kbd "\e\eg") 'goto-line) |
369 |
(global-set-key (kbd "\e\er") 'query-replace-regexp) |
|
370 |
||
81
0ce6eaf6f26c
Disable C-z, it ugly.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
80
diff
changeset
|
371 |
;; Disable C-z, it ugly. |
0ce6eaf6f26c
Disable C-z, it ugly.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
80
diff
changeset
|
372 |
(if window-system (global-set-key (kbd "C-z") 'nil)) |
0ce6eaf6f26c
Disable C-z, it ugly.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
80
diff
changeset
|
373 |
|
0 | 374 |
;; (global-set-key [language-change] 'ignore) |
375 |
||
376 |
;; ====================================================================== |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
377 |
;; coding system, charset, locale, lang. |
80
bfc8c3d03527
Correct code to remove warning in *Messages* when loading .emacs-my.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
79
diff
changeset
|
378 |
|
162
0ac8d1f4304d
Emacs 23.1 no longer need codepage-setup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
157
diff
changeset
|
379 |
;; Emacs 23.1 no longer need codepage-setup. |
0ac8d1f4304d
Emacs 23.1 no longer need codepage-setup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
157
diff
changeset
|
380 |
(when (<= emacs-major-version 22) |
0ac8d1f4304d
Emacs 23.1 no longer need codepage-setup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
157
diff
changeset
|
381 |
(codepage-setup 866) |
0ac8d1f4304d
Emacs 23.1 no longer need codepage-setup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
157
diff
changeset
|
382 |
(codepage-setup 1251) |
0ac8d1f4304d
Emacs 23.1 no longer need codepage-setup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
157
diff
changeset
|
383 |
) |
0 | 384 |
|
53 | 385 |
;; Comment because prefer-coding-system will be ignored. |
386 |
;; (setq-default coding-system-for-read 'cp1251-dos) |
|
387 |
;; (setq-default coding-system-for-write 'cp1251-dos) |
|
0 | 388 |
|
389 |
;; (setq locale-coding-system 'cp1251-dos) |
|
390 |
;; (set-terminal-coding-system 'cp1251) |
|
391 |
;; (set-keyboard-coding-system 'cp1251) |
|
392 |
||
393 |
(prefer-coding-system 'koi8-r-dos) |
|
394 |
(prefer-coding-system 'utf-16-le) |
|
395 |
(prefer-coding-system 'cp866-dos) |
|
4
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
396 |
|
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
397 |
(modify-coding-system-alist 'file "\\.el" 'iso-2022-7bit) |
192
8b4811c64ec4
Correct copy/paste coding in windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
191
diff
changeset
|
398 |
(cond |
106
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
399 |
((equal window-system 'w32) ; also (string-equal system-type "windows-nt") |
4
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
400 |
(progn |
372
32b54537dd10
Code ported to work with Emac 21.4. Mainly problems in undefi8ned functions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
371
diff
changeset
|
401 |
(set-selection-coding-system 'utf-16-le-dos) |
106
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
402 |
(prefer-coding-system 'utf-8-unix) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
403 |
(prefer-coding-system 'cp1251-dos) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
404 |
)) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
405 |
((equal window-system 'x) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
406 |
(progn |
4
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
407 |
(prefer-coding-system 'cp1251-dos) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
408 |
(prefer-coding-system 'utf-8-unix) |
259
b6c514e81d2c
ctext-with-extensions is alias for ctext-with-extensions.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
256
diff
changeset
|
409 |
(setq selection-coding-system 'compound-text-with-extensions) |
106
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
410 |
(setq x-select-request-type '(UTF8_STRING COMPOUND_TEXT TEXT STRING)) |
4
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
411 |
(modify-coding-system-alist 'process ".*" 'utf-8-unix) |
106
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
412 |
)) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
413 |
(t |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
414 |
(progn |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
415 |
;; (set-selection-coding-system 'utf-8-unix) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
416 |
(prefer-coding-system 'cp1251-dos) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
417 |
(prefer-coding-system 'utf-8-unix) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
418 |
(modify-coding-system-alist 'process ".*" 'utf-8-unix) |
0591d06cf752
Решил проблему copy/paste в X. Решил проблему поиска в UTF-8 буфере.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
419 |
)) |
4
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
420 |
) |
0 | 421 |
|
422 |
;; XXXXXXXXXXXXXXXXXXXXXXXX |
|
423 |
||
424 |
;; To open from command line file, which names has extended opcode |
|
425 |
;; (set-file-name-coding-system 'cp1251) |
|
426 |
||
52
b0b45dae5d8c
Now C-\ switch to win type keyboard layout.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
51
diff
changeset
|
427 |
;; (set-language-environment "Russian") ; XXX not used as set default coding system to koi8-r. |
0 | 428 |
|
240
77b01720a256
Enable image if supported.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
239
diff
changeset
|
429 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
430 |
;; dired. |
241
78cbd4c692ee
Added dired settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
240
diff
changeset
|
431 |
|
78cbd4c692ee
Added dired settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
240
diff
changeset
|
432 |
(setq dired-dwim-target t) |
78cbd4c692ee
Added dired settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
240
diff
changeset
|
433 |
;; dangerous |
78cbd4c692ee
Added dired settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
240
diff
changeset
|
434 |
;; (setq |
78cbd4c692ee
Added dired settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
240
diff
changeset
|
435 |
;; dired-recursive-copies 'top |
78cbd4c692ee
Added dired settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
240
diff
changeset
|
436 |
;; dired-recursive-deletes 'top) |
78cbd4c692ee
Added dired settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
240
diff
changeset
|
437 |
|
326
ded53e19d23a
Enable 'a' command in dired.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
303
diff
changeset
|
438 |
(put 'dired-find-alternate-file 'disabled nil) ; Enable 'a' command. |
ded53e19d23a
Enable 'a' command in dired.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
303
diff
changeset
|
439 |
|
241
78cbd4c692ee
Added dired settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
240
diff
changeset
|
440 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
441 |
;; compression, archive. |
240
77b01720a256
Enable image if supported.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
239
diff
changeset
|
442 |
|
0 | 443 |
(require 'jka-compr) ; Automatic decompression, hooks for tar-mode. |
444 |
(if (fboundp 'auto-compression-mode) |
|
445 |
(auto-compression-mode 1)) |
|
446 |
||
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
447 |
(modify-coding-system-alist 'file "\\.\\(war\\|ear\\|sar\\|egg\\)\\'" 'no-conversion) |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
448 |
|
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
449 |
(add-to-list 'auto-mode-alist '("\\.\\(war\\|ear\\|sar\\|egg\\)\\'" . archive-mode)) |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
450 |
|
0 | 451 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
452 |
;; image. |
240
77b01720a256
Enable image if supported.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
239
diff
changeset
|
453 |
|
77b01720a256
Enable image if supported.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
239
diff
changeset
|
454 |
(when (fboundp 'auto-image-file-mode) |
77b01720a256
Enable image if supported.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
239
diff
changeset
|
455 |
(auto-image-file-mode 1)) |
77b01720a256
Enable image if supported.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
239
diff
changeset
|
456 |
|
77b01720a256
Enable image if supported.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
239
diff
changeset
|
457 |
;; ---------------------------------------------------------------------- |
0 | 458 |
;; *Recentf* |
109
75b4bf140e73
Prevent TRAMP to login on remote host when loading.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
108
diff
changeset
|
459 |
|
0 | 460 |
(require 'recentf) |
109
75b4bf140e73
Prevent TRAMP to login on remote host when loading.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
108
diff
changeset
|
461 |
;; Prevent TRAMP to login on remote host when loading. |
75b4bf140e73
Prevent TRAMP to login on remote host when loading.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
108
diff
changeset
|
462 |
;; Its take time and ask passwords! |
75b4bf140e73
Prevent TRAMP to login on remote host when loading.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
108
diff
changeset
|
463 |
(setq recentf-auto-cleanup 'never) |
0 | 464 |
(recentf-mode t) |
465 |
(setq recentf-max-saved-items 200) |
|
466 |
(global-set-key (kbd "\e\eq") 'recentf-open-files) |
|
467 |
||
468 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
469 |
;; revert buffer. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
470 |
|
0 | 471 |
(global-set-key [f5] 'revert-buffer) |
472 |
(setq revert-without-query (quote (".*"))) |
|
473 |
(setq auto-revert-interval 2) |
|
474 |
||
475 |
;; ====================================================================== |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
476 |
;; convenient. |
0 | 477 |
|
230
b34c94fa13d9
Added func to calculate region length.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
229
diff
changeset
|
478 |
(defun reglen() |
b34c94fa13d9
Added func to calculate region length.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
229
diff
changeset
|
479 |
"Show region length." |
b34c94fa13d9
Added func to calculate region length.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
229
diff
changeset
|
480 |
(interactive) |
b34c94fa13d9
Added func to calculate region length.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
229
diff
changeset
|
481 |
(message "%s" (- (region-end) (region-beginning)))) |
b34c94fa13d9
Added func to calculate region length.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
229
diff
changeset
|
482 |
|
0 | 483 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
484 |
;; minibuffer. |
153
a03216c9fa8c
Delete dust. Correct 'completion-ignored-extensions' list.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
152
diff
changeset
|
485 |
|
0 | 486 |
(require 'icomplete) ; Interactive completion in minibuffer. |
153
a03216c9fa8c
Delete dust. Correct 'completion-ignored-extensions' list.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
152
diff
changeset
|
487 |
(icomplete-mode 1) |
0 | 488 |
|
228
f55559c1ce8e
Do not redefine completion-ignored-extensions, instead append new values.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
227
diff
changeset
|
489 |
(mapc (lambda (ext) (add-to-list 'completion-ignored-extensions ext)) |
f55559c1ce8e
Do not redefine completion-ignored-extensions, instead append new values.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
227
diff
changeset
|
490 |
'( |
f55559c1ce8e
Do not redefine completion-ignored-extensions, instead append new values.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
227
diff
changeset
|
491 |
".class" "~" ".aux" |
f55559c1ce8e
Do not redefine completion-ignored-extensions, instead append new values.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
227
diff
changeset
|
492 |
".o" ".obj" ".map" ".lib" ".lo" ".la" ".a" ".bin" ".exe" |
f55559c1ce8e
Do not redefine completion-ignored-extensions, instead append new values.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
227
diff
changeset
|
493 |
;; Place dir at end to appear at the start of completion-ignored-extensions. |
f55559c1ce8e
Do not redefine completion-ignored-extensions, instead append new values.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
227
diff
changeset
|
494 |
"CVS/" ".hg/" ".svn/" ".git/" ".bzr/" |
f55559c1ce8e
Do not redefine completion-ignored-extensions, instead append new values.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
227
diff
changeset
|
495 |
) ) |
0 | 496 |
|
497 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
498 |
;; music. |
0 | 499 |
(setq gnus-audio-au-player "winamp.exe" |
500 |
gnus-audio-directory "D:\\music" |
|
501 |
gnus-audio-wav-player "winamp.exe") |
|
502 |
||
97
fe4102cad849
Open egg files as archive.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
92
diff
changeset
|
503 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
504 |
;; browser. |
98
5223817dad90
Use mozilla browser. Not tested for Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
97
diff
changeset
|
505 |
|
138
90fda97adcb1
Setup browse-url func for linux and windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
120
diff
changeset
|
506 |
(cond |
90fda97adcb1
Setup browse-url func for linux and windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
120
diff
changeset
|
507 |
((equal window-system 'w32) |
90fda97adcb1
Setup browse-url func for linux and windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
120
diff
changeset
|
508 |
(setq browse-url-browser-function 'browse-url-default-windows-browser)) |
90fda97adcb1
Setup browse-url func for linux and windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
120
diff
changeset
|
509 |
(t |
90fda97adcb1
Setup browse-url func for linux and windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
120
diff
changeset
|
510 |
(setq browse-url-browser-function 'browse-url-mozilla))) |
98
5223817dad90
Use mozilla browser. Not tested for Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
97
diff
changeset
|
511 |
|
0 | 512 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
513 |
;; calendar. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
514 |
|
0 | 515 |
;; (setq mark-holidays-in-calendar t) |
516 |
;; (setq all-christian-calendar-holidays t) |
|
517 |
;; (setq calendar-date-display-form (quote ((format "%04s-%02d-%02d" year (string-to-int month) (string-to-int day))))) |
|
518 |
;; (setq calendar-time-display-form (quote (24-hours ":" minutes (if time-zone " (") time-zone (if time-zone ")")))) |
|
49
71cec5d9c60f
Set week start with Monday.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
48
diff
changeset
|
519 |
(setq calendar-week-start-day 1) |
71cec5d9c60f
Set week start with Monday.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
48
diff
changeset
|
520 |
(setq european-calendar-style t) |
0 | 521 |
|
522 |
;; ====================================================================== |
|
523 |
;; |
|
524 |
;; STANDARD HOOKS |
|
525 |
||
526 |
(add-hook 'write-file-hooks 'time-stamp) |
|
527 |
||
528 |
;; ====================================================================== |
|
7
8eae4300e86f
Перебил сочетание клавиш C-x C-d для вызова dired, вместо dir-list.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
6
diff
changeset
|
529 |
;; *auto-fill* |
0 | 530 |
|
102
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
531 |
(setq-default fill-column 78) |
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
532 |
|
335
748c6e05fe87
Use common value for fill-column.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
334
diff
changeset
|
533 |
(defvar my-fill-column 100 |
748c6e05fe87
Use common value for fill-column.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
334
diff
changeset
|
534 |
"I use greater value then 78 for comment in prog source.") |
748c6e05fe87
Use common value for fill-column.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
334
diff
changeset
|
535 |
|
148
7df64d2c9f3d
Remove unused key binding. Added more docs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
147
diff
changeset
|
536 |
;; By default used American convention - sentence and with two spaces. Change |
7df64d2c9f3d
Remove unused key binding. Added more docs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
147
diff
changeset
|
537 |
;; it to one space. Has affect on filling and M-a, M-e commands. |
102
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
538 |
(setq sentence-end-double-space nil) |
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
539 |
|
0 | 540 |
;; Turn on auto-fill mode |
541 |
(add-hook 'html-mode-hook 'turn-on-auto-fill) |
|
102
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
542 |
(add-hook 'text-mode-hook 'turn-on-auto-fill) |
0 | 543 |
|
544 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
545 |
;; unknown. |
0 | 546 |
|
233
dbef8d59a7c1
Remove old unknow desire function.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
232
diff
changeset
|
547 |
;; browse-url mailcrypt gnus message sendmail bbdb pilot bibtex eiffel-mode emacs-w3m |
dbef8d59a7c1
Remove old unknow desire function.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
232
diff
changeset
|
548 |
;; eudc filladapt hugs-mode mpg123 php-mode ps-print |
dbef8d59a7c1
Remove old unknow desire function.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
232
diff
changeset
|
549 |
;; chord-mode - edit guitar music |
dbef8d59a7c1
Remove old unknow desire function.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
232
diff
changeset
|
550 |
;; discography - variant of BibTeX mode for discographies |
0 | 551 |
|
367
58e70956523a
Set cacl digit grouping.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
366
diff
changeset
|
552 |
;; ---------------------------------------------------------------------- |
58e70956523a
Set cacl digit grouping.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
366
diff
changeset
|
553 |
;; cacl, calculator. |
58e70956523a
Set cacl digit grouping.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
366
diff
changeset
|
554 |
|
58e70956523a
Set cacl digit grouping.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
366
diff
changeset
|
555 |
(setq-default calc-group-digits t) |
58e70956523a
Set cacl digit grouping.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
366
diff
changeset
|
556 |
(setq-default calc-group-char "'") |
58e70956523a
Set cacl digit grouping.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
366
diff
changeset
|
557 |
|
0 | 558 |
;; ====================================================================== |
346 | 559 |
;; TeX, LaTeX. |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
560 |
|
0 | 561 |
(setq tex-run-command "initex") |
562 |
||
346 | 563 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
564 |
;; AUC TeX. |
0 | 565 |
|
566 |
;(add-hook 'LaTeX-mode-hook 'LaTeX-install-toolbar) |
|
567 |
;; (setq TeX-parse-self t) ; Enable parse on load. |
|
568 |
;; (setq TeX-auto-save t) ; Enable parse on save. |
|
347
ae8ed6d33e90
Dont prompt for master file.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
346
diff
changeset
|
569 |
;; Query for master file. If you often use \include or \input, you should make AUCTEX aware of the |
ae8ed6d33e90
Dont prompt for master file.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
346
diff
changeset
|
570 |
;; multi-file document structure. |
ae8ed6d33e90
Dont prompt for master file.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
346
diff
changeset
|
571 |
(setq-default TeX-master nil) |
0 | 572 |
|
573 |
;(setq TeX-PDF-mode t) |
|
574 |
;(setq TeX-interactive-mode t) |
|
575 |
;(setq TeX-source-specials-mode 1) |
|
576 |
||
577 |
;;; some more menu entries in the command list: |
|
578 |
;;; see tex-mik.el from package auctex: %v is defined in tex-mik.el |
|
579 |
;;; other variables are defined in tex.el from auctex |
|
580 |
;;; the meaning of some auctex-varibles: |
|
581 |
;symbols defined in tex.el and tex-mik.el: |
|
582 |
;%b name slave tex-file %t name master tex-file |
|
583 |
;%d dvi-file %f ps-file |
|
584 |
;%l "latex --src-specials" |
|
585 |
;%n line number %p printcommand %q "lpq" |
|
586 |
;%r (TeX-style-check TeX-print-style) |
|
587 |
;%s master-file-name without extention |
|
588 |
;%v yap command view line |
|
589 |
;(eval-after-load "tex" |
|
590 |
; '(progn |
|
591 |
; (add-to-list 'TeX-command-list |
|
9 | 592 |
; (list "->PS landscape for pdf" |
593 |
; "dvips %d -N0 -Ppdf -G0 -T 297mm,210mm -o %f " |
|
594 |
; 'TeX-run-command nil t)) |
|
0 | 595 |
; (add-to-list 'TeX-command-list |
9 | 596 |
; (list "All Texify run-viewer" |
597 |
; "texify --tex-opt=--src --run-viewer --clean %s.tex" |
|
598 |
; 'TeX-run-command nil t)))) |
|
0 | 599 |
|
346 | 600 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
601 |
;; Reftex activation (Reftex is included with Emacs 21.1). |
0 | 602 |
|
603 |
;; (autoload 'reftex-mode "reftex" "RefTeX Minor Mode" t) |
|
604 |
;; (autoload 'turn-on-reftex "reftex" "RefTeX Minor Mode" nil) |
|
605 |
;; (autoload 'reftex-citation "reftex-cite" "Make citation" nil) |
|
606 |
;; (autoload 'reftex-index-phrase-mode "reftex-index" "Phrase mode" t) |
|
607 |
;; (add-hook 'LaTeX-mode-hook 'turn-on-reftex) ; with AUCTeX LaTeX mode |
|
608 |
;; (add-hook 'latex-mode-hook 'turn-on-reftex) ; with Emacs latex mode |
|
609 |
||
346 | 610 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
611 |
;; PreviewLatex. |
0 | 612 |
|
613 |
;(load "preview-latex.el" nil t t) |
|
614 |
||
615 |
;(add-hook 'LaTeX-mode-hook #'LaTeX-preview-setup) |
|
616 |
;(autoload 'LaTeX-preview-setup "preview") |
|
617 |
||
618 |
;; ====================================================================== |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
619 |
;; Info. |
0 | 620 |
|
323
7a7dc2befa99
Because of Debian policy documentation covered by FDL license with invariant sections not allowed in packet
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
322
diff
changeset
|
621 |
;; Because of Debian policy documentation covered by FDL license with invariant sections not allowed in packet |
324 | 622 |
;; repository tree. So it must be installed manually. My usual configuration is install user local software |
323
7a7dc2befa99
Because of Debian policy documentation covered by FDL license with invariant sections not allowed in packet
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
322
diff
changeset
|
623 |
;; into ~/usr DISTDIR. |
7a7dc2befa99
Because of Debian policy documentation covered by FDL license with invariant sections not allowed in packet
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
322
diff
changeset
|
624 |
(unless (getenv "INFOPATH") |
7a7dc2befa99
Because of Debian policy documentation covered by FDL license with invariant sections not allowed in packet
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
322
diff
changeset
|
625 |
(setenv "INFOPATH" "~/usr/share/info:")) |
7a7dc2befa99
Because of Debian policy documentation covered by FDL license with invariant sections not allowed in packet
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
322
diff
changeset
|
626 |
|
0 | 627 |
;; ====================================================================== |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
628 |
;; man, woman. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
629 |
|
156
55aed5f25591
Added customisation for woman.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
143
diff
changeset
|
630 |
(setq woman-use-own-frame nil) |
55aed5f25591
Added customisation for woman.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
143
diff
changeset
|
631 |
(setq woman-fill-frame t) |
55aed5f25591
Added customisation for woman.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
143
diff
changeset
|
632 |
|
55aed5f25591
Added customisation for woman.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
143
diff
changeset
|
633 |
;; ====================================================================== |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
634 |
;; shell, sh, bash. |
0 | 635 |
|
202
a89804893475
Remove duplicated string.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
200
diff
changeset
|
636 |
;; Setup Emacs to run bash as its primary shell. |
0 | 637 |
;; (setq binary-process-input t) |
638 |
;; (setq shell-file-name "bash") |
|
639 |
;; (setq shell-command-switch "-c") |
|
640 |
;; (setenv "SHELL" shell-file-name) |
|
641 |
||
359
ee15316c1126
By default use sh as shell interpretator on Windows, thus Cygwin or MSYS
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
358
diff
changeset
|
642 |
(defvar my-use-windows-shell nil |
ee15316c1126
By default use sh as shell interpretator on Windows, thus Cygwin or MSYS
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
358
diff
changeset
|
643 |
"If t 'cmdproxy.exe' will be used as shell. Affect on M-x shell like |
ee15316c1126
By default use sh as shell interpretator on Windows, thus Cygwin or MSYS
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
358
diff
changeset
|
644 |
commands. If nil, 'sh' will be used." ) |
ee15316c1126
By default use sh as shell interpretator on Windows, thus Cygwin or MSYS
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
358
diff
changeset
|
645 |
|
207 | 646 |
(when (eq window-system 'w32) ; may require Cygwin or MSYS |
388
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
647 |
(if my-use-windows-shell |
389 | 648 |
(progn |
388
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
649 |
;; Restore shell name if user set SHELL env var for Cygwin/MSYS. |
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
650 |
(setq shell-file-name (concat exec-directory "cmdproxy.exe")) |
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
651 |
;; Here is workaround: when explicit-shell-file-name is "bash" and shell-file-name is "cmdproxy.exe" |
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
652 |
;; find-dired incorrect quote args (in shell-quote-argument (w32-shell-name) return "bash", but |
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
653 |
;; shell-command used shell-file-name which value "cmdproxy.exe"). So I put additional space in pattern to |
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
654 |
;; prevent quoting. |
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
655 |
(setq find-ls-option '("-exec ls -ld {} ;" . "-ld")) |
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
656 |
) |
389 | 657 |
(progn |
388
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
658 |
;; Use shell from Cygwin/MinGW. |
390 | 659 |
(setq shell-file-name "bash") |
388
c7a4c56c60ec
Set shell under Windows to Cygwin/MSYS sh.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
387
diff
changeset
|
660 |
) |
359
ee15316c1126
By default use sh as shell interpretator on Windows, thus Cygwin or MSYS
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
358
diff
changeset
|
661 |
) |
229
0a42b3480404
Use bash as primary shell.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
228
diff
changeset
|
662 |
;; (setq explicit-shell-file-name "bash") |
211
a07b53a7b415
Don't cd to home dir by C-x shell (removed "--login" switch from args).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
208
diff
changeset
|
663 |
(setq explicit-bash-args '("-i")) |
a07b53a7b415
Don't cd to home dir by C-x shell (removed "--login" switch from args).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
208
diff
changeset
|
664 |
(setq explicit-sh-args '("-i")) |
a07b53a7b415
Don't cd to home dir by C-x shell (removed "--login" switch from args).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
208
diff
changeset
|
665 |
) |
1
30e99e01ddc4
add auto-mode-alist for bat-files and load mercurial
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
0
diff
changeset
|
666 |
|
0 | 667 |
;; ====================================================================== |
387
7340a863ae23
Fix spelling settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
385
diff
changeset
|
668 |
;; spell, ispell, aspell. |
0 | 669 |
|
387
7340a863ae23
Fix spelling settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
385
diff
changeset
|
670 |
;; Settings for spelling done in '.emacs-autogen'. |
0 | 671 |
;(add-hook 'text-mode-hook 'flyspell-mode) |
672 |
;(setq flyspell-default-dictionary "russianw") |
|
673 |
;(setq flyspell-delay '1) |
|
674 |
||
675 |
;; ====================================================================== |
|
67
33caed66cee4
Set align for org-mode tags.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
66
diff
changeset
|
676 |
;; GTD, PIM, organize, todo mode. |
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
677 |
|
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
678 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
679 |
;; org-mode. |
79
f80cd58e09cb
Use buildin and installed version of org-mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
78
diff
changeset
|
680 |
|
108
1559bb79bdd1
Enable org mode for >= emacs22.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
107
diff
changeset
|
681 |
(if (>= emacs-major-version 22) |
1559bb79bdd1
Enable org mode for >= emacs22.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
107
diff
changeset
|
682 |
(progn |
1559bb79bdd1
Enable org mode for >= emacs22.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
107
diff
changeset
|
683 |
(require 'org) |
1559bb79bdd1
Enable org mode for >= emacs22.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
107
diff
changeset
|
684 |
)) |
1559bb79bdd1
Enable org mode for >= emacs22.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
107
diff
changeset
|
685 |
|
295 | 686 |
;; XXX org-todo-keywords '((sequence "TODO" "START" "|" "DONE")) for org-version 4.67c |
687 |
;; XXX (setq org-todo-keywords '("TODO" "START" "DONE")) for org-version 6.05b |
|
79
f80cd58e09cb
Use buildin and installed version of org-mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
78
diff
changeset
|
688 |
(if (or (featurep 'org) (featurep 'org-install)) |
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
689 |
(progn |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
690 |
(add-to-list 'auto-mode-alist '("\\.org$" . org-mode)) |
66
661801050393
Store all org-mode file in .gtd dirs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
65
diff
changeset
|
691 |
(setq org-directory (expand-file-name "~/.gtd")) |
661801050393
Store all org-mode file in .gtd dirs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
65
diff
changeset
|
692 |
(setq org-default-notes-file (expand-file-name "~/.gtd/notes")) |
385
f0e9718ec640
View in org agenda TODOs for one month in future.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
384
diff
changeset
|
693 |
(setq org-agenda-ndays 31 |
74
55deb80345ab
Some enhancement for org-mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
73
diff
changeset
|
694 |
org-deadline-warning-days 7 |
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
695 |
org-agenda-show-all-dates t |
329
83096ccf1367
Set org-agenda-format-date.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
303
diff
changeset
|
696 |
org-agenda-format-date "%Y-%m-%d, %A %e %B" |
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
697 |
org-agenda-skip-deadline-if-done t |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
698 |
org-agenda-skip-scheduled-if-done t |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
699 |
org-agenda-start-on-weekday nil |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
700 |
org-reverse-note-order t |
74
55deb80345ab
Some enhancement for org-mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
73
diff
changeset
|
701 |
org-hide-leading-stars t |
67
33caed66cee4
Set align for org-mode tags.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
66
diff
changeset
|
702 |
org-tags-column 64 |
33caed66cee4
Set align for org-mode tags.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
66
diff
changeset
|
703 |
) |
69
754d413dcff2
Aded global key binding for GTD.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
68
diff
changeset
|
704 |
(define-key global-map "\C-ca" 'org-agenda) |
66
661801050393
Store all org-mode file in .gtd dirs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
65
diff
changeset
|
705 |
(setq org-agenda-files '("~/.gtd/todo.org")) )) |
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
706 |
|
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
707 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
708 |
;; remember-mode. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
709 |
|
380 | 710 |
(if (or (featurep 'remember) (fboundp 'remember)) |
68 | 711 |
(progn |
712 |
(setq remember-annotation-functions '(org-remember-annotation)) |
|
713 |
(setq remember-handler-functions '(org-remember-handler)) |
|
714 |
(add-hook 'remember-mode-hook 'org-remember-apply-template) |
|
69
754d413dcff2
Aded global key binding for GTD.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
68
diff
changeset
|
715 |
(define-key global-map "\C-cr" 'org-remember) |
68 | 716 |
(setq org-remember-templates |
76
3b9b47be4951
With one item emacs do not prompt choose template.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
75
diff
changeset
|
717 |
;; With one item emacs do not prompt choose template. |
70
e0962e157772
Correct path to GTD files.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
69
diff
changeset
|
718 |
'((?t "* TODO %?" "~/.gtd/todo.org") |
76
3b9b47be4951
With one item emacs do not prompt choose template.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
75
diff
changeset
|
719 |
;; (?j "* %^{topic}\n %T\n" "~/.gtd/journal.org") |
72
03586585c558
Move customization to right place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
70
diff
changeset
|
720 |
)) |
03586585c558
Move customization to right place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
70
diff
changeset
|
721 |
(setq |
03586585c558
Move customization to right place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
70
diff
changeset
|
722 |
org-remember-store-without-prompt t |
03586585c558
Move customization to right place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
70
diff
changeset
|
723 |
) )) |
68 | 724 |
|
725 |
;; ---------------------------------------------------------------------- |
|
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
726 |
;; TODO, XXX, FIXME highlight. |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
727 |
;; Show blanks and FIXME |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
728 |
;; http://www.emacswiki.org/cgi-bin/wiki/EightyColumnRule |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
729 |
|
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
730 |
(defface my-tab-face |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
731 |
'((t :background "gray")) |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
732 |
"Face for showing TABs." |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
733 |
:group 'basic-faces) |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
734 |
|
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
735 |
(defface my-conflict-face |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
736 |
'((t :background "pink" :foreground "red" :weight bold)) |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
737 |
"Font for showing conflicts." |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
738 |
:group 'basic-faces) |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
739 |
|
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
740 |
(add-hook 'font-lock-mode-hook (function (lambda () |
232
ea69943781db
Simplify expression.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
231
diff
changeset
|
741 |
(when (member major-mode my-devel-mode-list) |
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
742 |
(font-lock-add-keywords nil |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
743 |
'( |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
744 |
("\t+" 0 'my-tab-face t) |
322
b1bd2648b826
'my-todo-face' deleted. Standard 'font-lock-warning-face' used instead.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
303
diff
changeset
|
745 |
("\\<\\(FIXME:?\\|XXX:?\\|TODO:?\\)\\>" 1 'font-lock-warning-face t) |
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
746 |
("\\(=\\{7,\\}\\|<\\{7,\\}\\|>\\{7,\\}\\)" 1 'my-conflict-face t) |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
747 |
)))))) |
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
748 |
|
284
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
749 |
;; (dolist (mode '(c-mode |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
750 |
;; java-mode |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
751 |
;; cperl-mode |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
752 |
;; html-mode-hook |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
753 |
;; css-mode-hook |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
754 |
;; emacs-lisp-mode)) |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
755 |
;; (font-lock-add-keywords mode |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
756 |
;; '(("\\(XXX\\|FIXME\\|TODO\\)" |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
757 |
;; 1 font-lock-warning-face prepend)))) |
bf5829d9bbf7
Another way to register TODO highlighting.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
280
diff
changeset
|
758 |
|
48
5aa6729514f6
Add customize for org mode. Place todo higlight вместе с org mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
47
diff
changeset
|
759 |
;; ====================================================================== |
83
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
760 |
;; communication |
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
761 |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
762 |
;; ---------------------------------------------------------------------- |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
763 |
;; jabber. |
83
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
764 |
|
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
765 |
(when (featurep 'jabber) |
215 | 766 |
(setq |
767 |
jabber-history-enabled t |
|
768 |
jabber-use-global-history nil |
|
769 |
jabber-backlog-number 15 |
|
770 |
jabber-backlog-days 30 |
|
771 |
jabber-alert-presence-message-function (lambda (who oldstatus newstatus statustext) nil) |
|
772 |
) |
|
83
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
773 |
) |
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
774 |
|
214
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
775 |
(setq my-chat-prompt "[%t] %n>\n") |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
776 |
(when (featurep 'jabber) |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
777 |
(setq |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
778 |
jabber-chat-foreign-prompt-format my-chat-prompt |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
779 |
jabber-chat-local-prompt-format my-chat-prompt |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
780 |
jabber-groupchat-prompt-format my-chat-prompt |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
781 |
jabber-muc-private-foreign-prompt-format "[%t] %g/%n>\n" |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
782 |
) |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
783 |
) |
f4234e15d891
Fix prompt format (prompt and text stay on two line, not one).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
211
diff
changeset
|
784 |
|
182
8a8bf4f3e7c2
Correctly set fsm var.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
181
diff
changeset
|
785 |
;; fsm used in emacs jabber |
8a8bf4f3e7c2
Correctly set fsm var.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
181
diff
changeset
|
786 |
(when (featurep 'fsm) |
8a8bf4f3e7c2
Correctly set fsm var.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
181
diff
changeset
|
787 |
(setq fsm-debug nil) ; Disable *fsm-debug* buffer. |
8a8bf4f3e7c2
Correctly set fsm var.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
181
diff
changeset
|
788 |
) |
83
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
789 |
|
142
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
790 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
791 |
;; rcirc. |
142
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
792 |
|
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
793 |
;; Turn on logging everything to a special buffer, for debugging. |
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
794 |
;; (setq rcirc-debug-flag t) |
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
795 |
|
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
796 |
(add-hook 'rcirc-mode-hook (lambda () (rcirc-track-minor-mode 1))) |
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
797 |
(setq rcirc-time-format "%H:%M ") |
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
798 |
(defun rcirc-handler-301 (process cmd sender args) |
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
799 |
"/away message handler.") |
adfc0c678483
Basic customisation for rcirc.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
141
diff
changeset
|
800 |
|
239
408ebfd38be3
Set default erc encoding to utf-8 because on Windows I have default coding - cp1251.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
238
diff
changeset
|
801 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
802 |
;; erc. |
239
408ebfd38be3
Set default erc encoding to utf-8 because on Windows I have default coding - cp1251.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
238
diff
changeset
|
803 |
|
377
3e8792ee03cc
Take off noise message from erc in notify.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
376
diff
changeset
|
804 |
;; Take off noise message. |
3e8792ee03cc
Take off noise message from erc in notify.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
376
diff
changeset
|
805 |
(setq erc-track-exclude-types '("JOIN" "PART" "QUIT" "NICK" "MODE")) |
3e8792ee03cc
Take off noise message from erc in notify.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
376
diff
changeset
|
806 |
|
3e8792ee03cc
Take off noise message from erc in notify.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
376
diff
changeset
|
807 |
(setq erc-current-nick-highlight-type 'nick-or-keyword) |
3e8792ee03cc
Take off noise message from erc in notify.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
376
diff
changeset
|
808 |
(setq erc-track-use-faces t) |
3e8792ee03cc
Take off noise message from erc in notify.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
376
diff
changeset
|
809 |
|
239
408ebfd38be3
Set default erc encoding to utf-8 because on Windows I have default coding - cp1251.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
238
diff
changeset
|
810 |
(setq erc-server-coding-system 'utf-8) |
408ebfd38be3
Set default erc encoding to utf-8 because on Windows I have default coding - cp1251.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
238
diff
changeset
|
811 |
|
83
d2eaf2ed6d1c
Added basic jabber customization.
gavenkoa@gavenko.bifit.int
parents:
82
diff
changeset
|
812 |
;; ====================================================================== |
363
17df92226b5a
Set default-header-line-format.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
362
diff
changeset
|
813 |
;; VCS, version control, cvs, svn, mercurial, hg, bazaar, bzr, git, fossil. |
0 | 814 |
|
30
762d326dca54
Now .emacs only contain emacs custom settings and load my lisp code from separate file.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
29
diff
changeset
|
815 |
(if (equal window-system 'w32) |
762d326dca54
Now .emacs only contain emacs custom settings and load my lisp code from separate file.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
29
diff
changeset
|
816 |
(progn |
762d326dca54
Now .emacs only contain emacs custom settings and load my lisp code from separate file.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
29
diff
changeset
|
817 |
(modify-coding-system-alist 'process "cvs" '(cp1251-dos . cp1251-dos)) |
762d326dca54
Now .emacs only contain emacs custom settings and load my lisp code from separate file.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
29
diff
changeset
|
818 |
(modify-coding-system-alist 'process "svn" '(cp866-dos . cp1251-dos)) |
762d326dca54
Now .emacs only contain emacs custom settings and load my lisp code from separate file.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
29
diff
changeset
|
819 |
)) |
0 | 820 |
|
821 |
;; (setq-default vc-svn-register-switches "--encoding cp1251") |
|
822 |
(setq-default vc-svn-register-switches nil) |
|
823 |
||
19
a8e7a6e94341
Теперь белый фон для annotated.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
18
diff
changeset
|
824 |
(if window-system |
163
f9b21d24bbf4
Change color map for vc (C-x v g).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
162
diff
changeset
|
825 |
(progn |
325
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
826 |
(setq |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
827 |
vc-annotate-very-old-color "#0b5b20" |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
828 |
vc-annotate-background "white" |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
829 |
vc-annotate-color-map |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
830 |
'( |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
831 |
(20 . "#EE0000") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
832 |
(40 . "#E0800D") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
833 |
(60 . "#D3001A") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
834 |
(80 . "#C68027") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
835 |
(100 . "#B90034") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
836 |
(120 . "#AB8042") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
837 |
(140 . "#9E004F") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
838 |
(160 . "#91805C") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
839 |
(180 . "#840069") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
840 |
(200 . "#778077") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
841 |
(220 . "#690084") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
842 |
(240 . "#5C8091") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
843 |
(260 . "#4F009E") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
844 |
(280 . "#4280AB") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
845 |
(300 . "#3400B9") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
846 |
(320 . "#2780C6") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
847 |
(340 . "#1A00D3") |
9b2144595e57
Set value to vc-annotate-* by 'setq', with 'custom-set-variables' in always
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
324
diff
changeset
|
848 |
(360 . "#0D80E0"))) |
163
f9b21d24bbf4
Change color map for vc (C-x v g).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
162
diff
changeset
|
849 |
) |
19
a8e7a6e94341
Теперь белый фон для annotated.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
18
diff
changeset
|
850 |
) |
a8e7a6e94341
Теперь белый фон для annotated.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
18
diff
changeset
|
851 |
|
91 | 852 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
853 |
;; psvn. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
854 |
|
197
2abcea5b91db
Added settings for psvn.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
192
diff
changeset
|
855 |
(setq svn-status-verbose t) |
2abcea5b91db
Added settings for psvn.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
192
diff
changeset
|
856 |
(setq svn-status-hide-unmodified t) |
2abcea5b91db
Added settings for psvn.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
192
diff
changeset
|
857 |
|
2abcea5b91db
Added settings for psvn.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
192
diff
changeset
|
858 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
859 |
;; DVC. |
91 | 860 |
|
861 |
(when (featurep 'dvc-emacs) |
|
862 |
(setq dvc-tips-enabled nil) |
|
863 |
) |
|
864 |
||
0 | 865 |
;; ====================================================================== |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
866 |
;; devel, prog, programming. |
0 | 867 |
|
868 |
(add-to-list 'auto-mode-alist '("\\.cu$" . c-mode)) |
|
869 |
||
172
fcea80b465b9
Comment customisation.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
167
diff
changeset
|
870 |
(setq-default comment-style (quote indent)) |
fcea80b465b9
Comment customisation.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
167
diff
changeset
|
871 |
(setq-default comment-column 44) |
335
748c6e05fe87
Use common value for fill-column.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
334
diff
changeset
|
872 |
(setq-default comment-fill-column my-fill-column) |
54 | 873 |
|
337
17e3c74b7c22
Use variable my-devel-mode-hook-list so easy adds new devel modes in one
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
336
diff
changeset
|
874 |
(mapc (lambda (hook) (add-hook hook (lambda () (setq fill-column my-fill-column)) )) |
17e3c74b7c22
Use variable my-devel-mode-hook-list so easy adds new devel modes in one
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
336
diff
changeset
|
875 |
my-devel-mode-hook-list) |
201
8531f8af6528
Allow long line coment in c/lisp code.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
200
diff
changeset
|
876 |
|
0 | 877 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
878 |
;; diff, patch. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
879 |
|
0 | 880 |
(setq diff-switches "-u") |
881 |
||
882 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
883 |
;; indenting. |
0 | 884 |
|
885 |
(setq standard-indent 4) |
|
886 |
(setq c-basic-offset 4) |
|
22
8ca8997d9f1d
Определил размер отступа для sh-mode.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
21
diff
changeset
|
887 |
(setq sh-basic-offset 2) |
0 | 888 |
(setq sgml-basic-offset 4) |
889 |
||
890 |
;; TAB (tab settings) |
|
891 |
(setq-default tab-width 4) |
|
253
7cb6ff8a9a75
Translate comment to English.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
252
diff
changeset
|
892 |
(setq-default indent-tabs-mode nil) ; spaces instead of tabs by default |
0 | 893 |
(setq tab-always-indent t) |
894 |
(setq c-tab-always-indent t) |
|
188
e36736f245fd
Start tab-stop-list with zero.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
162
diff
changeset
|
895 |
(let ( (line-width 400) i ) |
e36736f245fd
Start tab-stop-list with zero.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
162
diff
changeset
|
896 |
(setq i (* (ceiling line-width 4) 4)) |
73
73e42aa11b3c
Correct initial asigned with nil.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
72
diff
changeset
|
897 |
(setq tab-stop-list nil) |
188
e36736f245fd
Start tab-stop-list with zero.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
162
diff
changeset
|
898 |
(while (>= i 0) |
e36736f245fd
Start tab-stop-list with zero.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
162
diff
changeset
|
899 |
(setq tab-stop-list (cons i tab-stop-list)) |
e36736f245fd
Start tab-stop-list with zero.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
162
diff
changeset
|
900 |
(setq i (- i 4)))) |
0 | 901 |
|
902 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
903 |
;; diff. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
904 |
|
0 | 905 |
(setq ediff-diff-options "") |
906 |
||
907 |
;; ---------------------------------------------------------------------- |
|
908 |
;; *Compile* |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
909 |
|
0 | 910 |
(setq compile-auto-highlight t |
911 |
compile-command "make ") |
|
912 |
;; compilation window shall scroll down if not 0 |
|
913 |
(setq compilation-scroll-output 1) |
|
914 |
||
28
b05bcec107fd
Correct coding (aotu determine CR/LF).
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
27
diff
changeset
|
915 |
;; My funny error messages. |
295 | 916 |
;; XXX нужно реализовать через hook. |
20
fde58d93c047
Добавил подсветку для output-файлов cl в compile-mode.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
19
diff
changeset
|
917 |
(require 'compile) |
38
90354c640342
Prevent error on debian from non-exist `compilation-error-regexp-alist-alist'.
sasha@rocky
parents:
36
diff
changeset
|
918 |
(add-to-list 'compilation-error-regexp-alist '("^\\( +\\[csc\\] \\|\\)\\(.*\\)(\\([0-9]*\\),\\([0-9]*\\)):" 2 3 4)) |
90354c640342
Prevent error on debian from non-exist `compilation-error-regexp-alist-alist'.
sasha@rocky
parents:
36
diff
changeset
|
919 |
(add-to-list 'compilation-error-regexp-alist '("^ *\\(.*\\)(\\([0-9]*\\)) +:" 1 2)) |
185
9c2934c3d8ca
Parsing KEIL compiler error.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
183
diff
changeset
|
920 |
(add-to-list 'compilation-error-regexp-alist '("^\"?\\([^\"]*\\)\"?,\\([0-9]*\\) .*\\[.*\\]: " 1 2)) ; KEIL compiler |
38
90354c640342
Prevent error on debian from non-exist `compilation-error-regexp-alist-alist'.
sasha@rocky
parents:
36
diff
changeset
|
921 |
;; (add-to-list 'compilation-mode-font-lock-keywords '("\\(/[Oo][Uu][Tt]:[^ ]+\\)" . 1)) |
90354c640342
Prevent error on debian from non-exist `compilation-error-regexp-alist-alist'.
sasha@rocky
parents:
36
diff
changeset
|
922 |
;; (add-to-list 'compilation-mode-font-lock-keywords '("[ ]\\(/F[oe][^ ]+\\)" . 1)) |
0 | 923 |
|
924 |
;; ---------------------------------------------------------------------- |
|
303 | 925 |
;; windows inf files for driver installing |
926 |
||
288
5009c3f4afef
Windows inf files for installing drivers.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
285
diff
changeset
|
927 |
(add-to-list 'auto-mode-alist '("\\.inf\\'" . conf-mode)) |
5009c3f4afef
Windows inf files for installing drivers.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
285
diff
changeset
|
928 |
|
5009c3f4afef
Windows inf files for installing drivers.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
285
diff
changeset
|
929 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
930 |
;; makefile, make. |
196
154d8ebf534b
Added matches for makefile-gmake-mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
192
diff
changeset
|
931 |
|
154d8ebf534b
Added matches for makefile-gmake-mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
192
diff
changeset
|
932 |
(add-to-list 'auto-mode-alist '("\\(Makefile\\|Makefile\\..+\\)\\'" . makefile-gmake-mode)) |
154d8ebf534b
Added matches for makefile-gmake-mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
192
diff
changeset
|
933 |
|
154d8ebf534b
Added matches for makefile-gmake-mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
192
diff
changeset
|
934 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
935 |
;; asm, assembler. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
936 |
|
36
4261883ccdb6
Use C-style comment in asm files.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
35
diff
changeset
|
937 |
;; (setq-default asm-comment-char 59) |
4261883ccdb6
Use C-style comment in asm files.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
35
diff
changeset
|
938 |
(add-hook 'asm-mode-hook '(lambda () (setq comment-start "/*") (setq comment-end "*/")) t) |
0 | 939 |
|
186
8c74e1ac4da1
Added association for IAR asm file.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
185
diff
changeset
|
940 |
(add-to-list 'auto-mode-alist '("\\.\\([sS]79\\|[sS]\\)\\'" . asm-mode)) |
8c74e1ac4da1
Added association for IAR asm file.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
185
diff
changeset
|
941 |
|
176
69d65b8a0a25
Added example for unset-key.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
175
diff
changeset
|
942 |
;; (add-hook 'asm-mode-hook '(lambda () (local-unset-key ":"))) |
69d65b8a0a25
Added example for unset-key.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
175
diff
changeset
|
943 |
;; (add-hook 'asm-mode-hook '(lambda () (local-set-key ":" ":"))) |
69d65b8a0a25
Added example for unset-key.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
175
diff
changeset
|
944 |
|
0 | 945 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
946 |
;; linker. |
272
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
947 |
|
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
948 |
(when (fboundp 'iar-linker-config-mode) |
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
949 |
(add-to-list 'auto-mode-alist '("\\.icf\\'" . iar-linker-config-mode)) |
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
950 |
) |
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
951 |
(when (fboundp 'iar4-linker-config-mode) |
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
952 |
(add-to-list 'auto-mode-alist '("\\.xcl\\'" . iar4-linker-config-mode)) |
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
953 |
) |
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
954 |
|
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
955 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
956 |
;; lisp. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
957 |
|
0 | 958 |
(setq list-command-history-max 256) |
959 |
||
960 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
961 |
;; C, c-mode, C++, c++-mode. |
173
04b974b118c2
cc-mode customisations.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
172
diff
changeset
|
962 |
|
0 | 963 |
(setq c-echo-syntactic-information-p t) |
173
04b974b118c2
cc-mode customisations.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
172
diff
changeset
|
964 |
(add-hook 'c-mode-common-hook |
04b974b118c2
cc-mode customisations.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
172
diff
changeset
|
965 |
(lambda () |
04b974b118c2
cc-mode customisations.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
172
diff
changeset
|
966 |
;; Automatically inserte newlines after special characters such as brace, comma, semi-colon, and colon. |
04b974b118c2
cc-mode customisations.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
172
diff
changeset
|
967 |
(c-toggle-auto-newline -1) |
04b974b118c2
cc-mode customisations.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
172
diff
changeset
|
968 |
;; Delete all preceding whitespace by DEL. |
04b974b118c2
cc-mode customisations.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
172
diff
changeset
|
969 |
(c-toggle-hungry-state -1) |
04b974b118c2
cc-mode customisations.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
172
diff
changeset
|
970 |
)) |
0 | 971 |
|
972 |
(defconst my-c-style |
|
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
973 |
'((c-tab-always-indent . t) |
0 | 974 |
(c-comment-only-line-offset . 4) |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
975 |
(c-hanging-braces-alist |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
976 |
. ( |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
977 |
(brace-list-open) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
978 |
(substatement-open after) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
979 |
)) |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
980 |
(c-hanging-colons-alist |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
981 |
. ( |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
982 |
(access-label after) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
983 |
(case-label after) |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
984 |
(inher-intro) |
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
985 |
(label after) |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
986 |
(member-init-intro before) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
987 |
)) |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
988 |
(c-cleanup-list |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
989 |
. ( |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
990 |
defun-close-semi |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
991 |
empty-defun-braces |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
992 |
scope-operator |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
993 |
)) |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
994 |
(c-offsets-alist |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
995 |
. ( |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
996 |
(arglist-close . c-lineup-arglist) |
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
997 |
(arglist-cont-nonempty . ++) |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
998 |
(arglist-intro . ++) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
999 |
(block-open . 0) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
1000 |
(case-label . 0) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
1001 |
(comment-intro . 0) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
1002 |
(func-decl-cont . ++) |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
1003 |
(inexpr-class . 0) |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
1004 |
(inline-open . 0) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
1005 |
(knr-argdecl-intro . -) |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
1006 |
(label . 0) |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
1007 |
(statement-block-intro . +) |
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
1008 |
(statement-cont . ++) |
129
23d028bad418
More regular indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
128
diff
changeset
|
1009 |
(substatement-open . 0) |
131
bd2400a18295
Practice alphabetical order.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
130
diff
changeset
|
1010 |
)) |
0 | 1011 |
(c-echo-syntactic-information-p . t)) |
1012 |
"My C Programming Style") |
|
1013 |
||
128
5a3df58678d2
Switch from c-initialization-hook to c-mode-common-hook because otherwise
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
127
diff
changeset
|
1014 |
(add-hook 'c-mode-common-hook |
5a3df58678d2
Switch from c-initialization-hook to c-mode-common-hook because otherwise
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
127
diff
changeset
|
1015 |
(lambda () (c-add-style "my" my-c-style t))) |
179
77fdd4bce6c8
c++-mode and objc-mode use "my" style.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
178
diff
changeset
|
1016 |
(setq c-default-style '((java-mode . "my") (c-mode . "my") (csharp-mode . "my") (c++-mode . "my") (objc-mode . "my") (other . "my"))) |
0 | 1017 |
|
1018 |
;; ---------------------------------------------------------------------- |
|
341
84db44766351
Remove bat-file-mode as it present in generic-x.el.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
339
diff
changeset
|
1019 |
;; bat file, batch, loaded from 'generic-x.el'. |
272
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
1020 |
|
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
1021 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1022 |
;; nsis-mode. |
272
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
1023 |
|
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
1024 |
(when (fboundp 'nsis-mode) |
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
1025 |
(add-to-list 'auto-mode-alist '("\\.\\(nsi\\|nsh\\)\\'" . nsis-mode)) |
f7fba93f4028
Enable file association for myself defined modes.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
266
diff
changeset
|
1026 |
) |
204
4545865a64c3
Move bat file mode code.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
203
diff
changeset
|
1027 |
|
4545865a64c3
Move bat file mode code.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
203
diff
changeset
|
1028 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1029 |
;; *csharp*, c-sharp. |
204
4545865a64c3
Move bat file mode code.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
203
diff
changeset
|
1030 |
|
0 | 1031 |
(autoload 'csharp-mode "csharp-mode" "Major mode for editing C# code." t) |
1032 |
(add-to-list 'auto-mode-alist '("\\.cs$" . csharp-mode)) |
|
1033 |
||
1034 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1035 |
;; java. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1036 |
|
0 | 1037 |
;; Update the Emacs load-path to include the path to |
1038 |
;; the JDE and its require packages. This code assumes |
|
1039 |
;; that you have installed the packages in the emacs/site |
|
1040 |
;; subdirectory of your home directory. |
|
1041 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/semantic")) |
|
1042 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/speedbar")) |
|
1043 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/elib-1.0")) |
|
1044 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/eieio")) |
|
1045 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/jde-2.3.5.1/lisp")) |
|
1046 |
||
1047 |
;; Load CEDET |
|
1048 |
;; (load-file "~/emacs/site/common/cedet.el") |
|
1049 |
;; Enabling SEMANTIC minor modes. See semantic/INSTALL for more ideas. |
|
1050 |
;; (semantic-load-enable-code-helpers) |
|
1051 |
||
1052 |
;; If you want Emacs to defer loading the JDE until you open a |
|
1053 |
;; Java file, edit the following line |
|
1054 |
;; (setq defer-loading-jde nil) |
|
1055 |
;; to read: |
|
1056 |
;; |
|
1057 |
;; (setq defer-loading-jde t) |
|
1058 |
;; |
|
1059 |
||
1060 |
;; (if defer-loading-jde |
|
1061 |
;; (progn |
|
1062 |
;; (autoload 'jde-mode "jde" "JDE mode." t) |
|
1063 |
;; (add-to-list 'auto-mode-alist '("\\.java\\'" . jde-mode)) |
|
1064 |
;; (require 'jde))) |
|
1065 |
||
1066 |
||
1067 |
;; Sets the basic indentation for Java source files |
|
1068 |
;; to two spaces. |
|
1069 |
;; (defun my-jde-mode-hook () |
|
1070 |
;; (setq c-basic-offset 2)) |
|
1071 |
||
1072 |
;; (add-hook 'jde-mode-hook 'my-jde-mode-hook) |
|
1073 |
||
1074 |
;; (require 'jde) |
|
1075 |
||
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1076 |
;; ---------------------------------------------------------------------- |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1077 |
;; ECB. |
0 | 1078 |
|
102
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
1079 |
(setq ecb-tip-of-the-day nil) |
0 | 1080 |
;; (add-to-list 'load-path "~/emacs/site/ecb-2.32") |
1081 |
;; (require 'ecb) |
|
1082 |
||
102
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
1083 |
;; (global-set-key (kbd "\e\eE") 'ecb-activate) |
0 | 1084 |
|
104
e921a5d906ca
Use highlighting on sgml modes!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
1085 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1086 |
;; html. |
104
e921a5d906ca
Use highlighting on sgml modes!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
1087 |
|
e921a5d906ca
Use highlighting on sgml modes!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
1088 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1089 |
;; xml. |
104
e921a5d906ca
Use highlighting on sgml modes!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
1090 |
|
e921a5d906ca
Use highlighting on sgml modes!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
1091 |
;; ---------------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1092 |
;; psgml. |
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1093 |
|
245 | 1094 |
(setq sgml-set-face t) ; for highlighting in sgml |
104
e921a5d906ca
Use highlighting on sgml modes!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
102
diff
changeset
|
1095 |
|
0 | 1096 |
;; ====================================================================== |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1097 |
;; printing. |
0 | 1098 |
|
1099 |
;; Use Notepad to print plain text files to the default Windows printer |
|
1100 |
;(setq lpr-command "notepad") |
|
1101 |
;(setq lpr-headers-switches '("/p")) ; \ mis-use these |
|
1102 |
;(setq lpr-switches nil) ; / two variables |
|
9 | 1103 |
;(setq printer-name nil) ; notepad takes the default |
0 | 1104 |
;(setq lpr-printer-switch "/P") ;; run notepad as batch printer |
1105 |
;; |
|
295 | 1106 |
|
1107 |
;; ---------------------------------------------------------------------- |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1108 |
;; printing to file. |
295 | 1109 |
|
0 | 1110 |
;(setq printer-name "~/myprint.txt") |
1111 |
;(setq ps-printer-name nil) |
|
1112 |
;(setq ps-print-header nil) |
|
1113 |
;;; some more menu entries in the command list: |
|
1114 |
;;; see tex-mik.el from package auctex: %v is defined in tex-mik.el |
|
1115 |
;;; other variables are defined in tex.el from auctex |
|
1116 |
;;; the meaning of some auctex-varibles: |
|
1117 |
;symbols defined in tex.el and tex-mik.el: |
|
1118 |
;%b name slave tex-file %t name master tex-file |
|
1119 |
;%d dvi-file %f ps-file |
|
1120 |
;%l "latex --src-specials" |
|
1121 |
;%n line number %p printcommand %q "lpq" |
|
1122 |
;%r (TeX-style-check TeX-print-style) |
|
1123 |
;%s master-file-name without extention |
|
1124 |
;%v yap command view line |
|
1125 |
;(eval-after-load "tex" |
|
1126 |
; '(progn |
|
1127 |
; (add-to-list 'TeX-command-list |
|
9 | 1128 |
; (list "->PS landscape for pdf" |
1129 |
; "dvips %d -N0 -Ppdf -G0 -T 297mm,210mm -o %f " |
|
1130 |
; 'TeX-run-command nil t)) |
|
0 | 1131 |
; (add-to-list 'TeX-command-list |
9 | 1132 |
; (list "All Texify run-viewer" |
1133 |
; "texify --tex-opt=--src --run-viewer --clean %s.tex" |
|
1134 |
; 'TeX-run-command nil t)))) |
|
0 | 1135 |
|
102
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
1136 |
;; ---------------------------------------------------------------- |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1137 |
;; SQL. |
102
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
1138 |
|
25585e240b4a
Move customization from .emacs (custom-set-variables) to .emacs-my. Remove duplication.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
101
diff
changeset
|
1139 |
(setq sql-password "") |
0 | 1140 |
|
1141 |
;; ====================================================================== |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1142 |
;; backuping. |
0 | 1143 |
|
75
cd964a1d58b9
Use backup for files.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
74
diff
changeset
|
1144 |
(setq |
328
c770f75a351f
Set make-backup-files.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
327
diff
changeset
|
1145 |
make-backup-files t |
147 | 1146 |
backup-by-copying t ; don't clobber symlinks |
75
cd964a1d58b9
Use backup for files.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
74
diff
changeset
|
1147 |
backup-directory-alist '(("." . "~/.backup")) ; don't litter my fs tree |
82
1a705650ca56
Delete excess backup versions silently, else it prompt to delete ~/.recentf.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
81
diff
changeset
|
1148 |
delete-old-versions t ; delete excess backup versions silently |
75
cd964a1d58b9
Use backup for files.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
74
diff
changeset
|
1149 |
kept-old-versions 1 ; store first original version |
cd964a1d58b9
Use backup for files.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
74
diff
changeset
|
1150 |
kept-new-versions 3 ; store last 3 version |
cd964a1d58b9
Use backup for files.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
74
diff
changeset
|
1151 |
version-control t) ; use versioned backups |
0 | 1152 |
|
150 | 1153 |
;; ====================================================================== |
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1154 |
;; auto save. |
150 | 1155 |
|
1156 |
(setq auto-save-default t) |
|
1157 |
;; If nil autosave to different than original to buffer file. |
|
1158 |
(setq auto-save-visited-file-name nil) |
|
1159 |
;; Note: if you kill unsaved file auto save file not deleted. |
|
1160 |
(setq delete-auto-save-files t) |
|
0 | 1161 |
|
1162 |
;; ====================================================================== |
|
296
e502c69ab80a
Make header name like tags, separated by comma and ended on period.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
295
diff
changeset
|
1163 |
;; user info. |
17
4f97bf9a25d5
Удалил строки, содержащие абсолютные пути в windows.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
16
diff
changeset
|
1164 |
|
51 | 1165 |
(setq user-full-name "Oleksandr Gavenko") |
1166 |
(setq user-mail-address "gavenkoa@gmail.com") |
|
1167 |
(setenv "ORGANIZATION" (concat user-full-name " <" user-mail-address ">")) |
|
0 | 1168 |
|
250
ef1c7269280f
Show different messages on statup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
249
diff
changeset
|
1169 |
(add-hook 'emacs-startup-hook |
ef1c7269280f
Show different messages on statup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
249
diff
changeset
|
1170 |
(lambda () |
ef1c7269280f
Show different messages on statup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
249
diff
changeset
|
1171 |
(let ( (mgs-list '("Welcome to emacs, the thermonuclear editor." |
ef1c7269280f
Show different messages on statup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
249
diff
changeset
|
1172 |
"You enter to Out Space. Emacs on." |
ef1c7269280f
Show different messages on statup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
249
diff
changeset
|
1173 |
"Nice day for Emacsing!")) ) |
ef1c7269280f
Show different messages on statup.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
249
diff
changeset
|
1174 |
(message (nth (random (length mgs-list)) mgs-list))))) |
0 | 1175 |
|
1176 |
;; End loading... |