Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
9bfff84b
Commit
9bfff84b
authored
Jun 05, 2013
by
Ted Zlatanov
Browse files
(prog-prettify-symbols) (prog-prettify-install): Update docstrings.
parent
55577e7c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
2 deletions
+13
-2
lisp/ChangeLog
lisp/ChangeLog
+5
-0
lisp/progmodes/prog-mode.el
lisp/progmodes/prog-mode.el
+8
-2
No files found.
lisp/ChangeLog
View file @
9bfff84b
2013-06-05 Teodor Zlatanov <tzz@lifelogs.com>
* progmodes/prog-mode.el (prog-prettify-symbols)
(prog-prettify-install): Update docstrings.
2013-06-05 Stefan Monnier <monnier@iro.umontreal.ca>
* simple.el: Move all the prog-mode code to prog-mode.el.
lisp/progmodes/prog-mode.el
View file @
9bfff84b
...
...
@@ -58,8 +58,8 @@ instead."
(
defcustom
prog-prettify-symbols
nil
"Whether symbols should be prettified.
When set to an alist in the form `(STRING . CHARACTER)' it
will
augment the mode's native prettify alist."
When set to an alist in the form `(
(
STRING . CHARACTER)
...)
' it
will
augment the mode's native prettify alist."
:type
'
(
choice
(
const
:tag
"No thanks"
nil
)
(
const
:tag
"Mode defaults"
t
)
...
...
@@ -96,6 +96,12 @@ Regexp match data 0 points to the chars."
(
0
(
prog--prettify-font-lock-compose-symbol
',alist
)))))))
(
defun
prog-prettify-install
(
alist
)
"Install prog-mode support to prettify symbols according to ALIST.
ALIST is in the format `((STRING . CHARACTER)...)' like
`prog-prettify-symbols'.
Internally, `font-lock-add-keywords' is called."
(
setq-local
prog-prettify-symbols-alist
alist
)
(
let
((
keywords
(
prog-prettify-font-lock-symbols-keywords
)))
(
if
keywords
(
font-lock-add-keywords
nil
keywords
))))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment