author | Oleksander Gavenko <gavenko_a@3g.ua> |
Thu, 17 Apr 2008 23:58:12 +0300 | |
changeset 6 | d1c4515c3cfa |
parent 5 | ddf0660702ec |
child 7 | 8eae4300e86f |
permissions | -rw-r--r-- |
0 | 1 |
;; -*- mode: lisp; coding: cp1251 -*- |
6 | 2 |
;; |
3 |
;; Copyright (C) 2008 by Gavenko Oleksandr |
|
4 |
;; Copyright (C) 2008 by Гавенко Алескандр |
|
5 |
;; |
|
6 |
;; ~/.emacs file for GNU Emacs 21. |
|
7 |
||
8 |
||
0 | 9 |
|
10 |
;; silent runing |
|
11 |
(setq inhibit-startup-message t) |
|
12 |
||
13 |
;; ====================================================================== |
|
14 |
;;* DEBUGGING |
|
15 |
||
16 |
;; Shut off message buffer by setting nil. Note - if you need to debug emacs, |
|
17 |
;; comment these out so you can see what's going on. |
|
18 |
(setq message-log-max 100) |
|
19 |
||
20 |
;;(add-hook 'after-init-hook |
|
21 |
;; '(lambda () (setq debug-on-error t))) |
|
22 |
;;(debug-on-entry 'command-line-1) |
|
23 |
||
24 |
;; Set the debug option to enable a backtrace when a problem occurs. |
|
25 |
(setq debug-on-error nil) ; t/nil |
|
26 |
||
27 |
;; ====================================================================== |
|
28 |
;; Load path |
|
29 |
(add-to-list 'load-path (expand-file-name "~/emacs/site-lisp")) |
|
30 |
||
31 |
;; ====================================================================== |
|
32 |
;;* GNU Serv |
|
33 |
||
34 |
;; (load "~/emacs/bin/gnuserv/gnuserv.el") |
|
35 |
;; (require 'gnuserv) |
|
36 |
;; (setq gnuserv-frame (selected-frame)) |
|
37 |
||
38 |
(server-start) |
|
39 |
||
40 |
;; Rely on dtemacs to do this, otherwise a race condition can cause |
|
41 |
;; dtemacs to fail. |
|
42 |
;;(gnuserv-start) |
|
43 |
||
44 |
;(add-to-list 'load-path (expand-file-name "~/../bin/emacs/bin/gnuserv")) |
|
45 |
;(load "e:/bin/emacs/bin/gnuserv/gnuserv.el") |
|
46 |
;(require 'gnuserv) |
|
47 |
;; if you would rather have gnuserv load files into an existing frame |
|
48 |
;(setq gnuserv-frame (selected-frame)) |
|
49 |
||
50 |
;; (desktop-load-default) |
|
51 |
;; (desktop-read) |
|
52 |
||
53 |
;; ====================================================================== |
|
54 |
;; настройка внешнего вида редактора |
|
55 |
;;* View |
|
56 |
||
57 |
; remove menu on nil |
|
58 |
(menu-bar-mode nil) ; t/nil |
|
59 |
; remove button on nil |
|
60 |
(tool-bar-mode nil) ; t/nil |
|
61 |
||
62 |
(if window-system |
|
63 |
;; Для X-window и Win |
|
64 |
(progn |
|
65 |
;; size of emacs area and position |
|
66 |
(set-frame-height (selected-frame) 52) |
|
67 |
(set-frame-width (selected-frame) 130) |
|
68 |
(set-frame-position (selected-frame) 30 15) |
|
69 |
||
70 |
;;установка цветов экрана |
|
71 |
(set-background-color "white") |
|
72 |
(set-foreground-color "black") |
|
73 |
;;установка режимов работы курсора |
|
74 |
(set-cursor-color "brown") |
|
75 |
;;(setq blink-matching-delay 0.01) |
|
76 |
;; курсор не мигает! |
|
77 |
;; (blink-cursor-mode nil) |
|
78 |
;; (set-face-font 'default "7x14") |
|
79 |
) |
|
80 |
;; Для tty |
|
81 |
(progn |
|
82 |
) |
|
83 |
) |
|
84 |
||
85 |
;; ====================================================================== |
|
86 |
;;* Standart settings |
|
87 |
||
88 |
;прикрепляет к каждому окну полоску прокрутки t/nil |
|
89 |
(scroll-bar-mode t) |
|
90 |
||
91 |
;; удаляем строку целиком |
|
92 |
(setq kill-whole-line t) |
|
93 |
||
94 |
;; show column & line numbers in status bar |
|
95 |
(setq column-number-mode t) |
|
96 |
(setq line-number-mode t) |
|
97 |
||
98 |
(load "~/.emacs-custom.el") |
|
99 |
||
100 |
;; ---------------------------------------------------------------------- |
|
101 |
;;* Scrolling |
|
102 |
||
103 |
;; гладкий скроллинг с полями |
|
104 |
;; (setq-default scroll-conservatively 70) |
|
105 |
;; (setq-default scroll-preserve-screen-position 't) |
|
106 |
;; при перемешении точка останавливается на расстоянии i строк к границе фрейма, |
|
107 |
;; далее скролиться текст |
|
108 |
;; (setq scroll-margin 2) |
|
109 |
||
110 |
;; ---------------------------------------------------------------------- |
|
111 |
;; *Text* |
|
112 |
(setq default-major-mode 'text-mode) |
|
113 |
(add-hook 'text-mode-hook 'turn-on-auto-fill) |
|
114 |
||
115 |
;; ---------------------------------------------------------------------- |
|
116 |
;; Show marked text |
|
117 |
(setq transient-mark-mode t) |
|
118 |
(setq font-lock-maximum-decoration t) |
|
119 |
;; syntax highlighting |
|
120 |
(global-font-lock-mode 1 t) |
|
121 |
||
122 |
;; ---------------------------------------------------------------------- |
|
123 |
;;* Line |
|
1
30e99e01ddc4
add auto-mode-alist for bat-files and load mercurial
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
0
diff
changeset
|
124 |
(if window-system |
0 | 125 |
(progn |
126 |
(global-hl-line-mode t) |
|
127 |
(custom-set-faces '(hl-line ((t (:inherit highlight :background "light yellow"))))) |
|
128 |
) |
|
129 |
) |
|
130 |
||
131 |
;; ---------------------------------------------------------------------- |
|
132 |
;;* Paren |
|
133 |
||
134 |
(show-paren-mode 1) ; Parenthesis matching via highlighting. |
|
135 |
;; (setq show-paren-style 'expression) ; выделять все выражение в скобках |
|
136 |
(setq show-paren-style (quote parenthesis)) |
|
137 |
||
138 |
;; ====================================================================== |
|
139 |
;;* Keyboard, mouse and selection |
|
140 |
||
141 |
(setq default-input-method 'cyrillic-jcuken) |
|
142 |
;; (pc-bindings-mode) ; Myself define keybinding, see |
|
143 |
;; Настройка выделения "как в Windows" |
|
144 |
(setq pc-select-selection-keys-only t) ; to avoid some key bindings as F6, etc |
|
145 |
(pc-selection-mode) ; This mode enables Delete Selection mode and Transient Mark mode. |
|
146 |
(transient-mark-mode t) ; t/nil, when the mark is active, the region is highlighted |
|
147 |
(delete-selection-mode t) ; t/nil |
|
148 |
||
149 |
;; ---------------------------------------------------------------------- |
|
150 |
;; Completition |
|
151 |
(partial-completion-mode t) ; For example, M-x p-c-m expands to M-x partial-completion-mode |
|
152 |
||
153 |
;; ---------------------------------------------------------------------- |
|
154 |
;; Mouse |
|
155 |
||
156 |
;; Scroll Bar gets dragged by mouse butn 1 |
|
157 |
(global-set-key [vertical-scroll-bar down-mouse-1] 'scroll-bar-drag) |
|
158 |
;; Paste at point NOT at cursor |
|
159 |
(setq mouse-yank-at-point 't) |
|
160 |
(mouse-wheel-mode 1) |
|
161 |
||
162 |
;; ---------------------------------------------------------------------- |
|
163 |
;; Key Binding (Short-keys). |
|
164 |
||
165 |
(global-set-key [home] 'beginning-of-line) |
|
166 |
(global-set-key [end] 'end-of-line) |
|
167 |
(global-set-key [C-home] 'beginning-of-buffer) |
|
168 |
(global-set-key [C-end] 'end-of-buffer) |
|
169 |
(global-set-key [C-delete] 'kill-word) |
|
170 |
(global-set-key [delete] 'delete-char) |
|
171 |
;; (global-set-key [backspace] 'backward-delete-char-untabify) ; not work properly in *info* mode |
|
172 |
||
173 |
;; setting some f[1-12] keys |
|
174 |
(global-set-key [f1] 'help) |
|
175 |
(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
|
176 |
;; (global-set-key [xxx] 'ediff-buffers) |
0 | 177 |
(global-set-key [f4] 'ispell-buffer) |
178 |
(global-set-key [f8] 'kill-this-buffer) |
|
179 |
(global-set-key [M-f4] 'save-buffers-kill-emacs) |
|
180 |
||
181 |
;; search |
|
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
|
182 |
(global-set-key [f3] 'search-forward) |
98c662ae8707
Incremental search by F3, decr by S-F3 now. Impruved grep-find search.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
1
diff
changeset
|
183 |
(global-set-key [S-f3] 'search-backward) |
0 | 184 |
;; *Occur* |
185 |
(global-set-key (kbd "\e\eo") 'occur) |
|
186 |
||
187 |
;; frames, windows manipulation, switch buffers |
|
188 |
(global-set-key [C-tab] 'other-window) |
|
189 |
(global-set-key [?\C-x right] 'next-buffer) |
|
190 |
(global-set-key [?\C-x left] 'previous-buffer) |
|
191 |
||
192 |
(global-set-key (kbd "\e\eg") 'goto-line) |
|
193 |
(global-set-key (kbd "\e\er") 'query-replace-regexp) |
|
194 |
||
195 |
;; (global-set-key [language-change] 'ignore) |
|
196 |
||
197 |
||
198 |
;; ====================================================================== |
|
199 |
;;* Coding system, charset, locale, lang. |
|
200 |
||
201 |
; Подготовка к использованию соответствующих кодовых страниц. |
|
202 |
(codepage-setup 866) |
|
203 |
(codepage-setup 1251) |
|
204 |
||
205 |
;; (setq-default coding-system-for-read 'cp1251-dos) ; comment because prefer-coding-system will be ignored |
|
206 |
;; (setq-default coding-system-for-write 'cp1251-dos) ; |
|
207 |
||
208 |
;; (setq locale-coding-system 'cp1251-dos) |
|
209 |
;; (set-terminal-coding-system 'cp1251) |
|
210 |
;; (set-keyboard-coding-system 'cp1251) |
|
211 |
||
212 |
(prefer-coding-system 'koi8-r-dos) |
|
213 |
(prefer-coding-system 'utf-16-le) |
|
214 |
(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
|
215 |
|
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
216 |
(modify-coding-system-alist 'file "\\.el" 'iso-2022-7bit) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
217 |
(if (equal window-system 'w32) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
218 |
(progn |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
219 |
(set-selection-coding-system 'cp1251) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
220 |
(prefer-coding-system 'utf-8-unix) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
221 |
(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
|
222 |
(modify-coding-system-alist 'file "\\.[ch]" '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
|
223 |
(modify-coding-system-alist 'file "[Mm]akefile.*" '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
|
224 |
) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
225 |
(progn |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
226 |
(set-selection-coding-system 'utf-8-unix) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
227 |
(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
|
228 |
(prefer-coding-system 'utf-8-unix) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
229 |
(modify-coding-system-alist 'file "\\.[ch]" 'cp1251-unix) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
230 |
(modify-coding-system-alist 'file "[Mm]akefile.*" 'cp1251-unix) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
231 |
(modify-coding-system-alist 'process ".*" 'utf-8-unix) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
232 |
) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
233 |
) |
0 | 234 |
|
235 |
;; XXXXXXXXXXXXXXXXXXXXXXXX |
|
236 |
||
237 |
;; To open from command line file, which names has extended opcode |
|
238 |
;; (set-file-name-coding-system 'cp1251) |
|
239 |
||
240 |
;; (set-language-environment "Russian") |
|
241 |
||
242 |
;; ====================================================================== |
|
243 |
;; |
|
244 |
;; NON-STANDARD VARIABLES |
|
245 |
||
246 |
(defvar emacs-base-dir |
|
247 |
(expand-file-name "~/emacs") |
|
248 |
"*Name of directory where emacs instaled.") |
|
249 |
||
250 |
;; ====================================================================== |
|
251 |
;; |
|
252 |
;; STANDARD VARIABLES |
|
253 |
||
254 |
(if (boundp 'confirm-kill-emacs) |
|
255 |
(setq confirm-kill-emacs 'yes-or-no-p)) |
|
256 |
||
257 |
;; Try to speed things up, especially in VM. |
|
258 |
(setq gc-cons-threshold 2000000) |
|
259 |
||
260 |
;; Don't beep in my headphones! |
|
261 |
;; (setq visible-bell t) ; XXX in text terminal revert screen if press [end] or [home] |
|
262 |
||
263 |
(setq ange-ftp-generate-anonymous-password |
|
264 |
user-mail-address) |
|
265 |
||
266 |
;; Prompt before evaluating local bits of lisp. This stops people |
|
267 |
;; putting things at the end of files which delete all your files! |
|
268 |
(setq enable-local-variables t |
|
269 |
enable-local-eval 1) |
|
270 |
||
271 |
;; ====================================================================== |
|
272 |
;; |
|
273 |
;; STANDARD LIBRARIES |
|
274 |
||
275 |
(require 'jka-compr) ; Automatic decompression, hooks for tar-mode. |
|
276 |
(if (fboundp 'auto-compression-mode) |
|
277 |
(auto-compression-mode 1)) |
|
278 |
||
279 |
;; ====================================================================== |
|
280 |
;;* Save |
|
281 |
(setq auto-save-default nil) |
|
282 |
||
283 |
;; ---------------------------------------------------------------------- |
|
284 |
;; *Recentf* |
|
285 |
;; Recent files in menu |
|
286 |
(require 'recentf) |
|
287 |
(recentf-mode t) |
|
288 |
(setq recentf-max-saved-items 200) |
|
289 |
(global-set-key (kbd "\e\eq") 'recentf-open-files) |
|
290 |
||
291 |
;; ---------------------------------------------------------------------- |
|
292 |
;; revert |
|
293 |
(global-set-key [f5] 'revert-buffer) |
|
294 |
(setq revert-without-query (quote (".*"))) |
|
295 |
(setq auto-revert-interval 2) |
|
296 |
||
297 |
;; ====================================================================== |
|
298 |
;;* Convenient |
|
299 |
||
300 |
;; ---------------------------------------------------------------------- |
|
301 |
;; Completion |
|
302 |
(require 'icomplete) ; Interactive completion in minibuffer. |
|
303 |
(icomplete-mode) ; Toggle incremental minibuffer completion for this Emacs session. |
|
304 |
;; может дополнять несколько слов одновременно |
|
305 |
(load "complete") |
|
306 |
(setq completion-ignored-extensions (quote ("CVS/" ".o" "~" ".bin" ".bak" ".obj" ".map" ".a" ".ln" ".blg" ".bbl" ".elc" |
|
307 |
".lof" ".glo" ".idx" ".lot" ".fmt" ".tfm" ".class" ".fas" ".lib" ".x86f" ".sparcf" |
|
308 |
".lo" ".la" ".toc" ".log" ".aux" ".cp" ".fn" ".ky" ".pg" ".tp" ".vr" ".cps" |
|
309 |
".fns" ".kys" ".pgs" ".tps" ".vrs"))) |
|
310 |
||
311 |
||
312 |
;; ---------------------------------------------------------------------- |
|
313 |
;; *grep* |
|
314 |
(setq grep-command "find . -name '*' -exec grep -nH '' {} ;" |
|
3
2a74cffeb232
Correct grep-find to ignore vcs subdir.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
2
diff
changeset
|
315 |
grep-find-command "find . -type f ! -path '*.svn*' ! -path '*CVS*' ! -path '*.hg*' -name '*' -print0 | xargs -0 -e grep -nH " |
5
ddf0660702ec
Correct work grep-find for grep then do not understand --color.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
4
diff
changeset
|
316 |
grep-highlight-matches nil ; do not set t because some grep do not has --color options |
0 | 317 |
grep-tree-command "find <D> <X> -type f <F> -print0 | xargs -0 -e grep <C> -nH <R>" |
318 |
grep-use-null-device t) |
|
319 |
(setq blink-matching-paren-on-screen t) |
|
320 |
||
321 |
;; ---------------------------------------------------------------------- |
|
322 |
;; Music |
|
323 |
(setq gnus-audio-au-player "winamp.exe" |
|
324 |
gnus-audio-directory "D:\\music" |
|
325 |
gnus-audio-wav-player "winamp.exe") |
|
326 |
||
327 |
||
328 |
;; ====================================================================== |
|
329 |
;;* TIME SETTING |
|
330 |
||
331 |
;; ---------------------------------------------------------------------- |
|
332 |
;; Time |
|
333 |
;; |
|
334 |
;; Time in 24 hour format, plus day and date. |
|
335 |
;; (setq display-time-day-and-date t |
|
336 |
;; display-time-24hr-format t |
|
337 |
;; display-time-use-mail-icon t |
|
338 |
;; display-time-day-and-date t |
|
339 |
;; display-time-mail-file nil) |
|
340 |
;; (display-time) |
|
341 |
||
342 |
;; ---------------------------------------------------------------------- |
|
343 |
;; Calendar |
|
344 |
;; (setq mark-holidays-in-calendar t) |
|
345 |
;; (setq all-christian-calendar-holidays t) |
|
346 |
;; (setq calendar-date-display-form (quote ((format "%04s-%02d-%02d" year (string-to-int month) (string-to-int day))))) |
|
347 |
;; (setq calendar-time-display-form (quote (24-hours ":" minutes (if time-zone " (") time-zone (if time-zone ")")))) |
|
348 |
;; (setq calendar-week-start-day 1) |
|
349 |
;; (setq european-calendar-style t) |
|
350 |
||
351 |
;; ====================================================================== |
|
352 |
;; |
|
353 |
;; STANDARD HOOKS |
|
354 |
||
355 |
(add-hook 'write-file-hooks 'time-stamp) |
|
356 |
||
357 |
;; ====================================================================== |
|
358 |
;;* *auto-fill* |
|
359 |
||
360 |
(setq-default fill-column 90) |
|
361 |
;; Turn on auto-fill mode |
|
362 |
(add-hook 'html-mode-hook 'turn-on-auto-fill) |
|
363 |
(global-set-key (kbd "\e\ef") 'auto-fill-mode) |
|
364 |
||
365 |
;; ---------------------------------------------------------------------- |
|
366 |
;; DESIRE |
|
367 |
||
368 |
;; (require 'desire) |
|
369 |
||
370 |
;; (add-to-list 'desire-load-path |
|
371 |
;; (expand-file-name "~/share/emacs/desire")) |
|
372 |
;; (add-to-list 'auto-mode-alist |
|
373 |
;; (cons (concat (regexp-quote desire-extension) "\\'") |
|
374 |
;; 'emacs-lisp-mode)) |
|
375 |
||
376 |
;; ---------------------------------------------------------------------- |
|
377 |
||
378 |
;; Pilot support |
|
379 |
;; (desire 'pilot) |
|
380 |
||
381 |
;; ---------------------------------------------------------------------- |
|
382 |
||
383 |
;; BBDB - Must be loaded before most other things, since other things |
|
384 |
;; may perform special configuration if BBDB is present. |
|
385 |
;; |
|
386 |
;; (desire 'bbdb "bbdb") |
|
387 |
||
388 |
;; ---------------------------------------------------------------------- |
|
389 |
;; Appointments, diary, calendar. |
|
390 |
;; |
|
391 |
;; Use "M-x calendar RET" to display the calendar and start |
|
392 |
;; appointment warnings. |
|
393 |
||
394 |
;; (desire 'appt) |
|
395 |
;; (desire 'calendar) |
|
396 |
;; (desire 'todo-mode) |
|
397 |
;; (desire 'diary "diary-lib") |
|
398 |
||
399 |
;; ---------------------------------------------------------------------- |
|
400 |
||
401 |
;; These provide options for the various message handling packages. |
|
402 |
;; (desire 'browse-url) |
|
403 |
;; (desire 'mailcrypt) |
|
404 |
;; (desire 'supercite) |
|
405 |
||
406 |
;; Message handing packages. |
|
407 |
;; (desire 'gnus) |
|
408 |
;; (desire 'message) |
|
409 |
;; (desire 'vm) |
|
410 |
;; (desire 'sendmail) |
|
411 |
||
412 |
;; ---------------------------------------------------------------------- |
|
413 |
||
414 |
;; Miscellaneous |
|
415 |
||
416 |
;; (desire 'abbrev) |
|
417 |
;; (desire 'bibtex) |
|
418 |
;; (desire 'calc) |
|
419 |
;; (desire 'cc-mode) |
|
420 |
;; (desire 'ediff) |
|
421 |
;; (desire 'eiffel-mode) |
|
422 |
;; (desire 'emacs-w3m) |
|
423 |
;; (desire 'eudc) |
|
424 |
;; (desire 'filladapt) |
|
425 |
;;;; (desire 'hugs-mode) |
|
426 |
;; (desire 'haskell-mode) |
|
427 |
;; (desire 'ispell) |
|
428 |
;; (desire 'latex) |
|
429 |
;; (desire 'lispdir) |
|
430 |
;; (desire 'mpg123) |
|
431 |
;; (desire 'php-mode) |
|
432 |
;; (desire 'ps-print) |
|
433 |
;; (desire 'psgml) |
|
434 |
;; (desire 'sh-script) |
|
435 |
;; (desire 'shell) |
|
436 |
;;; (desire 'sql-mode) |
|
437 |
;; (desire 'tex) |
|
438 |
;; (desire 'w3) |
|
439 |
||
440 |
;; ====================================================================== |
|
441 |
;; |
|
442 |
;; PERSONAL |
|
443 |
||
444 |
;; (require 'chord-mode) ; edit guitar music. |
|
445 |
;; (require 'discography) ; variant of BibTeX mode for discographies. |
|
446 |
||
447 |
;; ====================================================================== |
|
448 |
;; |
|
449 |
;; unNOVICEd commands... |
|
450 |
;; |
|
451 |
;; The following commands are usually disabled by default. Enable |
|
452 |
;; them... |
|
453 |
||
454 |
(put 'eval-expression 'disabled nil) |
|
455 |
(put 'downcase-region 'disabled nil) |
|
456 |
(put 'upcase-region 'disabled nil) |
|
457 |
(put 'narrow-to-page 'disabled nil) |
|
458 |
(put 'narrow-to-region 'disabled nil) |
|
459 |
||
460 |
;; ====================================================================== |
|
461 |
;;* TEX |
|
462 |
(setq tex-run-command "initex") |
|
463 |
||
464 |
||
465 |
;; ====================================================================== |
|
466 |
;;* AUC TeX |
|
467 |
||
468 |
;; (add-to-list 'load-path "c:/program files/emacs/site-lisp/auctex/") |
|
469 |
;; (load "tex-site") |
|
470 |
||
471 |
;(require 'tex-mik) |
|
472 |
;(add-hook 'LaTeX-mode-hook 'LaTeX-install-toolbar) |
|
473 |
;; (setq TeX-parse-self t) ; Enable parse on load. |
|
474 |
;; (setq TeX-auto-save t) ; Enable parse on save. |
|
475 |
;; (setq-default TeX-master nil) ; Query for master file. Finally, if you often use \include or \input, you should make AUCTEX aware of the multi-file document structure |
|
476 |
||
477 |
;(setq TeX-PDF-mode t) |
|
478 |
;(setq TeX-interactive-mode t) |
|
479 |
;(setq TeX-source-specials-mode 1) |
|
480 |
;(add-to-list 'load-path "c:/emacs/site-lisp/auctex/") |
|
481 |
;(load "tex-site") |
|
482 |
;(load "tex-mik") |
|
483 |
||
484 |
;;модифицируем меню |
|
485 |
;;; some more menu entries in the command list: |
|
486 |
;;; see tex-mik.el from package auctex: %v is defined in tex-mik.el |
|
487 |
;;; other variables are defined in tex.el from auctex |
|
488 |
;;; the meaning of some auctex-varibles: |
|
489 |
;symbols defined in tex.el and tex-mik.el: |
|
490 |
;%b name slave tex-file %t name master tex-file |
|
491 |
;%d dvi-file %f ps-file |
|
492 |
;%l "latex --src-specials" |
|
493 |
;%n line number %p printcommand %q "lpq" |
|
494 |
;%r (TeX-style-check TeX-print-style) |
|
495 |
;%s master-file-name without extention |
|
496 |
;%v yap command view line |
|
497 |
;(eval-after-load "tex" |
|
498 |
; '(progn |
|
499 |
; (add-to-list 'TeX-command-list |
|
500 |
; (list "->PS landscape for pdf" |
|
501 |
; "dvips %d -N0 -Ppdf -G0 -T 297mm,210mm -o %f " |
|
502 |
; 'TeX-run-command nil t)) |
|
503 |
; (add-to-list 'TeX-command-list |
|
504 |
; (list "All Texify run-viewer" |
|
505 |
; "texify --tex-opt=--src --run-viewer --clean %s.tex" |
|
506 |
; 'TeX-run-command nil t)))) |
|
507 |
||
508 |
||
509 |
;; ====================================================================== |
|
510 |
;; |
|
511 |
;; Reftex activation (Reftex is included with Emacs 21.1) |
|
512 |
||
513 |
;; (autoload 'reftex-mode "reftex" "RefTeX Minor Mode" t) |
|
514 |
;; (autoload 'turn-on-reftex "reftex" "RefTeX Minor Mode" nil) |
|
515 |
;; (autoload 'reftex-citation "reftex-cite" "Make citation" nil) |
|
516 |
;; (autoload 'reftex-index-phrase-mode "reftex-index" "Phrase mode" t) |
|
517 |
;; (add-hook 'LaTeX-mode-hook 'turn-on-reftex) ; with AUCTeX LaTeX mode |
|
518 |
;; (add-hook 'latex-mode-hook 'turn-on-reftex) ; with Emacs latex mode |
|
519 |
||
520 |
;; ====================================================================== |
|
521 |
;; |
|
522 |
;;Настройки PreviewLatex |
|
523 |
||
524 |
;(load "preview-latex.el" nil t t) |
|
525 |
||
526 |
;(add-to-list 'load-path "c:/emacs/site-lisp/previewlatex/") |
|
527 |
;(add-hook 'LaTeX-mode-hook #'LaTeX-preview-setup) |
|
528 |
;(autoload 'LaTeX-preview-setup "preview") |
|
529 |
||
530 |
||
531 |
;; ====================================================================== |
|
532 |
;; |
|
533 |
;; Info |
|
534 |
||
535 |
(require 'info) |
|
536 |
(setq Info-directory-list (list (expand-file-name "~/../bin/emacs-22.1/info"))) |
|
537 |
:; t - append at the end |
|
538 |
(add-to-list 'Info-directory-list (expand-file-name "~/../bin/MinGW/info") t) |
|
539 |
||
540 |
;; ====================================================================== |
|
541 |
;; |
|
542 |
;; SHELL |
|
543 |
||
544 |
;; If you plan to use the bash shell, add the following lines to your .emacs file: |
|
545 |
;; (setq binary-process-input t) |
|
546 |
;; (setq w32-quote-process-args ?\") |
|
547 |
;; (setq shell-file-name "bash") ;; or sh if you rename your bash executable to sh. |
|
548 |
;; (setenv "SHELL" shell-file-name) |
|
549 |
;; (setq explicit-shell-file-name shell-file-name) |
|
550 |
;; (setq explicit-sh-args '("-login" "-i")) |
|
551 |
||
552 |
;; Include the following only if you want to run |
|
553 |
;; bash as your shell. |
|
554 |
||
555 |
;; Setup Emacs to run bash as its primary shell. |
|
556 |
;; (setq shell-file-name "bash") |
|
557 |
;; (setq shell-command-switch "-c") |
|
558 |
;; (setq explicit-shell-file-name shell-file-name) |
|
559 |
;; (setenv "SHELL" shell-file-name) |
|
560 |
;; (setq explicit-sh-args '("-login" "-i")) |
|
561 |
;; (if (boundp 'w32-quote-process-args) |
|
562 |
;; (setq w32-quote-process-args ?\")) ;; Include only for MS Windows. |
|
563 |
||
564 |
;; (setq sh-shell-file "D:\\home\\cygwin\\bin\\sh.exe") |
|
565 |
;; (setq sh-shell-arg (quote ((bash) (csh . "-f") (pdksh) (ksh88) (rc . "-p") (wksh) (zsh . "-f") (sh . "-i")))) |
|
566 |
(setq explicit-bash-args (quote ("-login" "-i"))) |
|
1
30e99e01ddc4
add auto-mode-alist for bat-files and load mercurial
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
0
diff
changeset
|
567 |
|
30e99e01ddc4
add auto-mode-alist for bat-files and load mercurial
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
0
diff
changeset
|
568 |
|
0 | 569 |
(if (equal window-system 'w32) |
4
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
570 |
(progn |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
571 |
(setq auto-mode-alist |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
572 |
(append |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
573 |
(list (cons "\\.[bB][aA][tT]$" 'bat-mode)) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
574 |
;; For DOS init files |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
575 |
(list (cons "CONFIG\\." 'bat-mode)) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
576 |
(list (cons "AUTOEXEC\\." 'bat-mode)) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
577 |
auto-mode-alist)) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
578 |
(require 'bat-mode) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
579 |
) |
46543c097be0
Transfer changer from .eamcs_unix, add case for w32 or other system.
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
3
diff
changeset
|
580 |
) |
0 | 581 |
|
582 |
;; ====================================================================== |
|
583 |
;; |
|
584 |
;; Spell |
|
585 |
||
586 |
;(setq ispell-dictionary "russianw"); default dictionary |
|
587 |
;(setq ispell-local-dictionary "russianw"); default dictionary |
|
588 |
;(add-hook 'text-mode-hook 'flyspell-mode) |
|
589 |
;(setq flyspell-default-dictionary "russianw") |
|
590 |
;(setq flyspell-delay '1) |
|
591 |
;; (setq ispell-local-dictionary-alist |
|
592 |
;; '((nil ; default (english.aff) |
|
593 |
;; "[A-Za-z]" "[^A-Za-z]" "[']" nil ("-B") nil iso-8859-1) |
|
594 |
;; ("UK-xlg" ; english large version |
|
595 |
;; "[A-Za-z]" "[^A-Za-z]" "[']" nil ("-B" "-d" "UK-xlg") nil iso-8859-1) |
|
596 |
;; ("US-xlg" ; american large version |
|
597 |
;; "[A-Za-z]" "[^A-Za-z]" "[']" nil ("-B" "-d" "US-xlg") nil iso-8859-1) |
|
598 |
;; ) |
|
599 |
;; ) |
|
600 |
||
601 |
;; ====================================================================== |
|
602 |
;; VCS, version control, cvs, svn. |
|
603 |
||
604 |
(modify-coding-system-alist 'process "cvs" '(cp1251-dos . cp1251-dos)) |
|
605 |
(modify-coding-system-alist 'process "svn" '(cp866-dos . cp1251-dos)) |
|
606 |
||
607 |
;; (setq-default vc-svn-register-switches "--encoding cp1251") |
|
608 |
(setq-default vc-svn-register-switches nil) |
|
609 |
||
1
30e99e01ddc4
add auto-mode-alist for bat-files and load mercurial
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
0
diff
changeset
|
610 |
(require 'mercurial) |
30e99e01ddc4
add auto-mode-alist for bat-files and load mercurial
Oleksander Gavenko <gavenko_a@3g.ua>
parents:
0
diff
changeset
|
611 |
|
0 | 612 |
;; ====================================================================== |
613 |
;;* Devel, prog |
|
614 |
||
615 |
(add-to-list 'auto-mode-alist '("\\.cu$" . c-mode)) |
|
616 |
||
617 |
(setq-default show-trailing-whitespace t) |
|
618 |
;; (add-hook 'c-mode-hook '(lambda () |
|
619 |
;; (setq show-trailing-whitespace t))) |
|
620 |
||
621 |
;; ---------------------------------------------------------------------- |
|
622 |
;;* Diff, patch |
|
623 |
;; (add-hook 'diff-mode-hook '(lambda () |
|
624 |
;; (setq show-trailing-whitespace t)) nil t) |
|
625 |
(setq diff-switches "-u") |
|
626 |
||
627 |
;; ---------------------------------------------------------------------- |
|
628 |
;; Indent |
|
629 |
||
630 |
(setq standard-indent 4) |
|
631 |
(setq c-basic-offset 4) |
|
632 |
(setq sgml-basic-offset 4) |
|
633 |
||
634 |
;; TAB (tab settings) |
|
635 |
(setq-default tab-width 4) |
|
636 |
(setq-default indent-tabs-mode nil) ; t - будут вставляться \t |
|
637 |
(setq tab-always-indent t) |
|
638 |
(setq tab-stop-list (quote (0 4 8 12 16 20 24 28 32 36 40))) |
|
639 |
(setq c-tab-always-indent t) |
|
640 |
||
641 |
(setq comment-style (quote indent)) |
|
642 |
||
643 |
;; ---------------------------------------------------------------------- |
|
644 |
;; Diff. |
|
645 |
(setq ediff-diff-options "") |
|
646 |
||
647 |
;; ---------------------------------------------------------------------- |
|
648 |
;; *Compile* |
|
649 |
(setq compile-auto-highlight t |
|
650 |
compile-command "make ") |
|
651 |
;; compilation window shall scroll down if not 0 |
|
652 |
(setq compilation-scroll-output 1) |
|
653 |
||
654 |
||
655 |
;; ---------------------------------------------------------------------- |
|
656 |
;; asm |
|
657 |
(setq-default asm-comment-char 0) |
|
658 |
||
659 |
||
660 |
;; ---------------------------------------------------------------------- |
|
661 |
;; LISP |
|
662 |
(setq list-command-history-max 256) |
|
663 |
||
664 |
;; ---------------------------------------------------------------------- |
|
665 |
;; C, c-lang |
|
666 |
(setq c-echo-syntactic-information-p t) |
|
667 |
||
668 |
(defconst my-c-style |
|
669 |
'((c-tab-always-indent . t) |
|
670 |
(c-comment-only-line-offset . 4) |
|
671 |
(c-hanging-braces-alist . ((substatement-open after) |
|
672 |
(brace-list-open))) |
|
673 |
(c-hanging-colons-alist . ((member-init-intro before) |
|
674 |
(inher-intro) |
|
675 |
(case-label after) |
|
676 |
(label after) |
|
677 |
(access-label after))) |
|
678 |
(c-cleanup-list . (scope-operator |
|
679 |
empty-defun-braces |
|
680 |
defun-close-semi)) |
|
681 |
(c-offsets-alist . ((arglist-intro . ++) |
|
682 |
(arglist-close . c-lineup-arglist) |
|
683 |
(arglist-cont-nonempty . ++) |
|
684 |
(statement-block-intro . +) |
|
685 |
(inline-open . 0) |
|
686 |
(inexpr-class . 0) |
|
687 |
(statement-cont . ++) |
|
688 |
(label . 0) |
|
689 |
(substatement-open . 0) |
|
690 |
(case-label . 0) |
|
691 |
(block-open . 0) |
|
692 |
(comment-intro . 0) |
|
693 |
(knr-argdecl-intro . -))) |
|
694 |
(c-echo-syntactic-information-p . t)) |
|
695 |
"My C Programming Style") |
|
696 |
||
697 |
;; (objc-mode . "my-mode") (c++-mode . "cc-mode") |
|
698 |
(add-hook 'c-initialization-hook (lambda () |
|
699 |
(c-add-style "my" my-c-style t))) |
|
700 |
(setq c-default-style '((java-mode . "my") (c-mode . "my") (csharp-mode . "my") (other . "my"))) |
|
701 |
||
702 |
;; Customizations for all modes in CC Mode. |
|
703 |
;; (defun my-c-mode-common-hook () |
|
704 |
;; ;; add my personal style and set it for the current buffer |
|
705 |
;; (c-add-style "PERSONAL" my-c-style t) |
|
706 |
;; ;; other customizations |
|
707 |
;; (setq tab-width 8 |
|
708 |
;; ;; this will make sure spaces are used instead of tabs |
|
709 |
;; indent-tabs-mode nil) |
|
710 |
;; ;; we like auto-newline and hungry-delete |
|
711 |
;; (c-toggle-auto-hungry-state 1) |
|
712 |
;; ;; key bindings for all supported languages. We can put these in |
|
713 |
;; ;; c-mode-base-map because c-mode-map, c++-mode-map, objc-mode-map, |
|
714 |
;; ;; java-mode-map, idl-mode-map, and pike-mode-map inherit from it. |
|
715 |
;; (define-key c-mode-base-map "\C-m" 'c-context-line-break)) |
|
716 |
||
717 |
;; (add-hook 'c-mode-common-hook 'my-c-mode-common-hook) |
|
718 |
||
719 |
;; ---------------------------------------------------------------------- |
|
720 |
;; *Csharp* |
|
721 |
(require 'cc-mode) |
|
722 |
(autoload 'csharp-mode "csharp-mode" "Major mode for editing C# code." t) |
|
723 |
(add-to-list 'auto-mode-alist '("\\.cs$" . csharp-mode)) |
|
724 |
||
725 |
;; ---------------------------------------------------------------------- |
|
726 |
;; *Java* |
|
727 |
;; Update the Emacs load-path to include the path to |
|
728 |
;; the JDE and its require packages. This code assumes |
|
729 |
;; that you have installed the packages in the emacs/site |
|
730 |
;; subdirectory of your home directory. |
|
731 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/semantic")) |
|
732 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/speedbar")) |
|
733 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/elib-1.0")) |
|
734 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/eieio")) |
|
735 |
;; (add-to-list 'load-path (expand-file-name "~/emacs/site/jde-2.3.5.1/lisp")) |
|
736 |
||
737 |
;; Load CEDET |
|
738 |
;; (load-file "~/emacs/site/common/cedet.el") |
|
739 |
;; Enabling SEMANTIC minor modes. See semantic/INSTALL for more ideas. |
|
740 |
;; (semantic-load-enable-code-helpers) |
|
741 |
||
742 |
;; If you want Emacs to defer loading the JDE until you open a |
|
743 |
;; Java file, edit the following line |
|
744 |
;; (setq defer-loading-jde nil) |
|
745 |
;; to read: |
|
746 |
;; |
|
747 |
;; (setq defer-loading-jde t) |
|
748 |
;; |
|
749 |
||
750 |
;; (if defer-loading-jde |
|
751 |
;; (progn |
|
752 |
;; (autoload 'jde-mode "jde" "JDE mode." t) |
|
753 |
;; (add-to-list 'auto-mode-alist '("\\.java\\'" . jde-mode)) |
|
754 |
;; (require 'jde))) |
|
755 |
||
756 |
||
757 |
;; Sets the basic indentation for Java source files |
|
758 |
;; to two spaces. |
|
759 |
;; (defun my-jde-mode-hook () |
|
760 |
;; (setq c-basic-offset 2)) |
|
761 |
||
762 |
;; (add-hook 'jde-mode-hook 'my-jde-mode-hook) |
|
763 |
||
764 |
;; (require 'jde) |
|
765 |
||
766 |
;; ******************** |
|
767 |
;; ECB |
|
768 |
;; ******************* |
|
769 |
||
770 |
;; load ECB |
|
771 |
;; (add-to-list 'load-path "~/emacs/site/ecb-2.32") |
|
772 |
;; (require 'ecb) |
|
773 |
||
774 |
;; load ECB |
|
775 |
;(add-to-list 'load-path "~/emacs/site/ecb-2.32") |
|
776 |
;(require 'ecb) |
|
777 |
;'(ecb-options-version "2.32") |
|
778 |
;'(ecb-wget-setup (quote cons)) |
|
779 |
;(global-set-key (kbd "\e\eE") 'ecb-activate) |
|
780 |
||
781 |
;; ====================================================================== |
|
782 |
;;* Printing |
|
783 |
||
784 |
;; Use Notepad to print plain text files to the default Windows printer |
|
785 |
;(setq lpr-command "notepad") |
|
786 |
;(setq lpr-headers-switches '("/p")) ; \ mis-use these |
|
787 |
;(setq lpr-switches nil) ; / two variables |
|
788 |
;(setq printer-name nil) ; notepad takes the default |
|
789 |
;(setq lpr-printer-switch "/P") ;; run notepad as batch printer |
|
790 |
;; |
|
791 |
;;Печать через prfile32 |
|
792 |
;(setq lpr-command "c:/program files/printfile/prfile32.exe") |
|
793 |
;(setq lpr-headers-switches '("/p")) |
|
794 |
;(setq lpr-switches '("/q")) |
|
795 |
;(setq lpr-add-switches nil) |
|
796 |
;(setq printer-name nil) |
|
797 |
;; |
|
798 |
;;Печать в файл |
|
799 |
;(setq printer-name "~/myprint.txt") |
|
800 |
;(setq ps-printer-name nil) |
|
801 |
;(setq ps-print-header nil) |
|
802 |
;;модифицируем меню |
|
803 |
;;; some more menu entries in the command list: |
|
804 |
;;; see tex-mik.el from package auctex: %v is defined in tex-mik.el |
|
805 |
;;; other variables are defined in tex.el from auctex |
|
806 |
;;; the meaning of some auctex-varibles: |
|
807 |
;symbols defined in tex.el and tex-mik.el: |
|
808 |
;%b name slave tex-file %t name master tex-file |
|
809 |
;%d dvi-file %f ps-file |
|
810 |
;%l "latex --src-specials" |
|
811 |
;%n line number %p printcommand %q "lpq" |
|
812 |
;%r (TeX-style-check TeX-print-style) |
|
813 |
;%s master-file-name without extention |
|
814 |
;%v yap command view line |
|
815 |
;(eval-after-load "tex" |
|
816 |
; '(progn |
|
817 |
; (add-to-list 'TeX-command-list |
|
818 |
; (list "->PS landscape for pdf" |
|
819 |
; "dvips %d -N0 -Ppdf -G0 -T 297mm,210mm -o %f " |
|
820 |
; 'TeX-run-command nil t)) |
|
821 |
; (add-to-list 'TeX-command-list |
|
822 |
; (list "All Texify run-viewer" |
|
823 |
; "texify --tex-opt=--src --run-viewer --clean %s.tex" |
|
824 |
; 'TeX-run-command nil t)))) |
|
825 |
||
826 |
||
827 |
;; ====================================================================== |
|
828 |
;; |
|
829 |
;; Установка режима CUA - все как в Windows |
|
830 |
;; поддержка Ctr-c,v,x,d как в windows через пакет CUA |
|
831 |
||
832 |
;; версия 21.3 |
|
833 |
||
834 |
;(require 'cua) |
|
835 |
;(CUA-mode t) |
|
836 |
;;установка режимов работы курсора через CUA |
|
837 |
;(setq CUA-mode-normal-cursor-color "black") |
|
838 |
;(setq CUA-mode-overwrite-cursor-color "red") |
|
839 |
;(setq CUA-mode-read-only-cursor-color "green") |
|
840 |
;(CUA-keypad-mode 'numeric t); доп.клавиатура - цифры |
|
841 |
;(CUA-keypad-mode 'prefix t); доп.клавиатура - префиксы регистров (М-2) |
|
842 |
||
843 |
;; версия 21.3.50 и старше |
|
844 |
||
845 |
;(require 'cua-base) |
|
846 |
;(cua-mode t) |
|
847 |
;;установка режимов работы курсора через CUA |
|
848 |
;(setq cua-normal-cursor-color "black") |
|
849 |
;(setq cua-overwrite-cursor-color "red") |
|
850 |
;(setq cua-read-only-cursor-color "green") |
|
851 |
||
852 |
||
853 |
;; ====================================================================== |
|
854 |
;;* Backup |
|
855 |
||
856 |
;; (setq |
|
857 |
;; backup-by-copying t ; don't clobber symlinks |
|
858 |
;; backup-directory-alist |
|
859 |
;; '(("." . "~/backup")) ; don't litter my fs tree |
|
860 |
;; delete-old-versions t |
|
861 |
;; kept-new-versions 6 |
|
862 |
;; kept-old-versions 2 |
|
863 |
;; version-control t) ; use versioned backups |
|
864 |
;(setq version-control t);нумерованный бэкап - 2 первых и 2 последних |
|
865 |
;(setq delete-old-versions t);удаление промежуточных бэкапов |
|
866 |
||
867 |
||
868 |
;; ====================================================================== |
|
869 |
;; Start off in "C:/home" dir. |
|
870 |
(cd "~/") |
|
871 |
(setq my-author-name (getenv "USER")) |
|
872 |
(setq user-full-name (getenv "USER")) |
|
873 |
||
874 |
(message ".emacs loaded OK.") |
|
875 |
||
876 |
;; |
|
877 |
;; End loading... |