mirror of https://github.com/Chizi123/.emacs.d.git

Chizi123
2018-11-17 c4001ccd1864293b64aa37d83a9d9457eb875e70
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
;ELC
;;; Compiled
;;; in Emacs version 26.1
;;; with all optimizations.
 
;;; This file uses dynamic docstrings, first added in Emacs 19.29.
 
;;; This file does not contain utf-8 non-ASCII characters,
;;; and so can be loaded in Emacs versions earlier than 23.
 
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 
(byte-code "\300\301\302\303\304\305%\210\306\307\302\310\311\312\304\301\313\314&    \207" [custom-declare-group clean-aindent nil "Settings for 'clean-aindent-mode'" :group indent custom-declare-variable clean-aindent-is-simple-indent "Determines if indentation should use the smart language mode or simple mode" :tag "Clean auto indent is in simple mode" :type boolean] 10)
#@65 Computes the length of the line at 'clean-aindent--last-indent.
(defalias 'clean-aindent--get-indent-len #[nil "\302\212    b\210\303\210`\304 \210`Z*\207" [eol-pos clean-aindent--last-indent 0 nil beginning-of-line] 2 (#$ . 782)])
#@122 Checks if last auto-indent position was abandoned.
Verifies if cursor moved away and that the indent was left
unaltered.
(defalias 'clean-aindent--abandonedp #[nil "\205`U?\205    \302 U\205\303\207" [clean-aindent--last-indent clean-aindent--last-indent-len clean-aindent--get-indent-len t] 2 (#$ . 1022)])
#@54 Deletes the whitespaces inserted at last indentation
(defalias 'clean-aindent--trim-last-point #[nil "\212b\210\303\211\304 \210`\305\210`\306\n    \"\210\305\210\307\310    `Z\"+\207" [clean-aindent--last-indent e s 0 beginning-of-line nil delete-trailing-whitespace message "auto trimmed %d chars"] 4 (#$ . 1341)])
#@64 Checks if last pos of auto-indent was abandoned and deletes it
(defalias 'clean-aindent--check-last-point #[nil "\301 \203\302 \210\205`U?\205\303\211\207" [clean-aindent--last-indent clean-aindent--abandonedp clean-aindent--trim-last-point nil] 2 (#$ . 1665)])
#@75 Searches lines backward, finds first non-blank. Returns
indentation value
(defalias 'clean-aindent--find-indent #[nil "\212\300 \210\301 )\207" [clean-aindent--prev-line current-indentation] 1 (#$ . 1942)])
#@110 Simple auto indent. Indentation is based only on previous line
indentation, regardless of language settings.
(defalias 'clean-aindent--simple-newline-and-indent #[nil "\212\302\211\303 \210`\304\210`\305    \"\210\304\210+\306 \210\307\310 \302\"\207" [e s 0 beginning-of-line nil delete-trailing-whitespace newline indent-to clean-aindent--find-indent] 3 (#$ . 2156)])
(ad-add-advice 'newline-and-indent '(clean-aindent nil t (advice lambda nil "Advice for newline-and-indent(), implements clean auto-indent.\nRemoves unneeded whitespaces by keeping track of the place of the\nlast indentation so that they can be deleted in case the indentation was\nabandoned." (clean-aindent--check-last-point) (if clean-aindent-is-simple-indent (clean-aindent--simple-newline-and-indent) (progn ad-do-it)) (setq clean-aindent--last-indent nil) (make-local-variable 'clean-aindent--last-indent) (setq clean-aindent--last-indent (point)) (setq clean-aindent--last-indent-len (clean-aindent--get-indent-len)) (make-local-variable 'clean-aindent--last-indent-len))) 'around nil)
#@33 Computes length of current line
(defalias 'clean-aindent--get-line-len #[nil "\212\301\302!\210`\302\210`Z*\207" [pos beginning-of-line nil] 2 (#$ . 3229)])
#@25 Checks if line is empty
(defalias 'clean-aindent--line-emptyp #[nil "\212\300\301!\210`\302U?\205\303 \304U)\207" [beginning-of-line nil 1 clean-aindent--get-line-len 0] 2 (#$ . 3395)])
#@48 Move cursor to previous line, skip empty lines
(defalias 'clean-aindent--prev-line #[nil "`\301y\302U\203\303 \204`U)?\207" [c -1 0 clean-aindent--line-emptyp] 2 (#$ . 3589)])
#@89 Searches lines backward, finds the one that is indented less
than certain indentation t
(defalias 'clean-aindent--find-u-indent #[(start) "\212\302\303 \211\203\304V\203    X\203\305 \204*\207" [c start nil current-indentation 0 clean-aindent--prev-line] 2 (#$ . 3777)])
#@92 Returns true if cursor is in the leading whitespace or first
non-blank character of a line
(defalias 'clean-aindent--inside-indentp #[nil "\212`\301\302!\210\303\302w\210`X\205\304*\207" [pos beginning-of-line nil "     " t] 2 (#$ . 4064)])
#@50 Get (point) at the beginning of the current line
(defalias 'clean-aindent--line-point #[nil "\212\300 \210`)\207" [beginning-of-line] 1 (#$ . 4312)])
#@112 Moves the cursor to a certain column position.
Column position is different from char position because of TABs
(defalias 'clean-aindent--goto-column #[(col) "\301\302!\210iW\205\303 \210\202\207" [col beginning-of-line nil right-char] 2 (#$ . 4469)])
#@185 Unindents.
Bound to `M-backspace' key. Searches lines backward, finds the one that
is indented less than the current one. Unindents current line to
align with that smaller indentation
(defalias 'clean-aindent--bsunindent #[(arg) "\305 \204\n\306[!\207\307 \310 \311\n!     \\\211\nU?\205(\312\n!\210\313\n Z!,\207" [arg ln c n s clean-aindent--inside-indentp kill-word clean-aindent--line-point current-indentation clean-aindent--find-u-indent clean-aindent--goto-column backward-delete-char-untabify] 4 (#$ . 4732) "p"])
(defvar clean-aindent--last-indent nil)
(defvar clean-aindent--last-indent-len 0)
#@28 clean-aindent-mode keymap.
(defvar clean-aindent-mode--keymap (make-keymap) (#$ . 5346))
(byte-code "\301\302\303#\210\304\305\306\307\310\311\312\313\314\315\316\317& \207" [clean-aindent-mode--keymap define-key [remap backward-kill-word] clean-aindent--bsunindent custom-declare-variable clean-aindent-mode nil "Non-nil if Clean-Aindent mode is enabled.\nSee the `clean-aindent-mode' command\nfor a description of this minor mode.\nSetting this variable directly does not take effect;\neither customize it (see the info node `Easy Customization')\nor call the function `clean-aindent-mode'." :set custom-set-minor-mode :initialize custom-initialize-default :group clean-aindent :type boolean] 12)
#@704 Activates clean auto indent for function 'newline-and-indent' and
back-space unindent for M-DEL (meta-backspace).
 
clean-aindent mode is a global minor mode.
 
1. Extension of 'newline-and-indent' that keeps track of the last
auto-indent operation and, if it is abandoned, would take care to
trim down the unused white space characters.
 
2. Simple indent, if activated, where cursor is aligned with
indent of the lines above.
 
3. Backspace Unindent. Extension of M-backspace. When cursor is
in the indentation space of a line, or at the first character and
you press M-backspace it will move the entire line to be aligned
to the line above or any other that is with indentation smaller
than the current.
(defalias 'clean-aindent-mode #[(&optional arg) "\304 \305\302    \306=\203\307\302!?\202\310    !\311V\"\210\n\203/\312\313\314\315#\210\316\313!\210\317\320\321\"\210\202>\322\313\314\315#\210\316\313!\210\323\320\321\"\210\324\325\307\302!\203J\326\202K\327\"\210\330\331!\203v\332\302!\210\304 \203c\304 \232\203v\333\334\335\307\302!\203q\336\202r\337 #\210))\340 \210\307\302!\207" [#1=#:last-message arg clean-aindent-mode local current-message set-default toggle default-value prefix-numeric-value 0 ad-enable-advice newline-and-indent around clean-aindent ad-activate add-hook post-command-hook clean-aindent--check-last-point ad-disable-advice remove-hook run-hooks clean-aindent-mode-hook clean-aindent-mode-on-hook clean-aindent-mode-off-hook called-interactively-p any customize-mark-as-set "" message "Clean-Aindent mode %sabled%s" "en" "dis" force-mode-line-update] 4 (#$ . 6053) (list (or current-prefix-arg 'toggle))])
(defvar clean-aindent-mode-hook nil)
(byte-code "\301\302N\204\f\303\301\302\304#\210\305\306\307\307\211%\210\310\306!\207" [clean-aindent-mode--keymap clean-aindent-mode-hook variable-documentation put "Hook run after entering or leaving `clean-aindent-mode'.\nNo problems result if this variable is not bound.\n`add-hook' automatically binds it.  (This is true for all hook variables.)" add-minor-mode clean-aindent-mode nil provide] 6)