195 |
(looking-at glasses-uncapitalize-regexp)))) |
(looking-at glasses-uncapitalize-regexp)))) |
196 |
(overlay-put o 'invisible t) |
(overlay-put o 'invisible t) |
197 |
(overlay-put o 'after-string (downcase (match-string n)))))) |
(overlay-put o 'after-string (downcase (match-string n)))))) |
198 |
|
;; Separator change |
199 |
|
(unless (string= glasses-separator "_") |
200 |
|
(goto-char beg) |
201 |
|
(while (re-search-forward "[a-zA-Z0-9]\\(_+\\)[a-zA-Z0-9]" end t) |
202 |
|
(goto-char (match-beginning 1)) |
203 |
|
(while (eql (char-after) ?\_) |
204 |
|
(let ((o (glasses-make-overlay (point) (1+ (point))))) |
205 |
|
;; `concat' ensures the character properties won't merge |
206 |
|
(overlay-put o 'display (concat glasses-separator))) |
207 |
|
(forward-char)))) |
208 |
;; Parentheses |
;; Parentheses |
209 |
(when glasses-separate-parentheses-p |
(when glasses-separate-parentheses-p |
210 |
(goto-char beg) |
(goto-char beg) |
237 |
(let ((n (if (match-string 1) 1 2))) |
(let ((n (if (match-string 1) 1 2))) |
238 |
(replace-match "" t nil nil n) |
(replace-match "" t nil nil n) |
239 |
(goto-char (match-end n)))) |
(goto-char (match-end n)))) |
240 |
|
(unless (string= glasses-separator "_") |
241 |
|
(goto-char (point-min)) |
242 |
|
(while (re-search-forward (format "[a-zA-Z0-9]\\(%s+\\)[a-zA-Z0-9]" |
243 |
|
separator) |
244 |
|
nil t) |
245 |
|
(replace-match "_" nil nil nil 1) |
246 |
|
(goto-char (match-beginning 1)))) |
247 |
(when glasses-separate-parentheses-p |
(when glasses-separate-parentheses-p |
248 |
(goto-char (point-min)) |
(goto-char (point-min)) |
249 |
(while (re-search-forward "[a-zA-Z]_*\\( \\)\(" nil t) |
(while (re-search-forward "[a-zA-Z]_*\\( \\)\(" nil t) |