* can emacs do this
@ 2015-01-15 7:24 Rusi
2015-01-15 7:57 ` Pascal J. Bourguignon
` (3 more replies)
0 siblings, 4 replies; 9+ messages in thread
From: Rusi @ 2015-01-15 7:24 UTC (permalink / raw)
To: help-gnu-emacs
Here is a vi plugin to show python with more unicode-goodness than the default
https://github.com/yawaramin/vim-cute-python
Specifically here is a syntax file
https://github.com/yawaramin/vim-cute-python/blob/moresymbols/after/syntax/python.vim
What facilities of emacs can be used for this?
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: can emacs do this
2015-01-15 7:24 can emacs do this Rusi
@ 2015-01-15 7:57 ` Pascal J. Bourguignon
2015-01-15 14:10 ` Drew Adams
2015-01-15 15:25 ` Ted Zlatanov
2015-01-15 8:01 ` Charles Philip Chan
` (2 subsequent siblings)
3 siblings, 2 replies; 9+ messages in thread
From: Pascal J. Bourguignon @ 2015-01-15 7:57 UTC (permalink / raw)
To: help-gnu-emacs
Of course.
Any question starting by "Can emacs do …" has a positive answer. So
what's the purpose of asking?
> What facilities of emacs can be used for this?
Just use emacs, there's no need for anything special!
(defun √ (x) (sqrt x))
(√ 42) --> 6.48074069840786
(defmacro λ (λ-list &rest body) `(lambda ,λ-list ,@body))λ
(mapcar (λ (x) (* x x)) '(1 2 3 4)) --> (1 4 9 16)
There's also an alternative, where emacs displays eg. λ when there is
lambda in the file:
http://www.emacswiki.org/emacs/PrettySymbol
http://www.emacswiki.org/emacs/PrettyGreek
--
__Pascal Bourguignon__ http://www.informatimago.com/
“The factory of the future will have only two employees, a man and a
dog. The man will be there to feed the dog. The dog will be there to
keep the man from touching the equipment.” -- Carl Bass CEO Autodesk
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: can emacs do this
2015-01-15 7:24 can emacs do this Rusi
2015-01-15 7:57 ` Pascal J. Bourguignon
@ 2015-01-15 8:01 ` Charles Philip Chan
2015-01-15 14:22 ` Stefan Monnier
[not found] ` <mailman.17951.1421331793.1147.help-gnu-emacs@gnu.org>
3 siblings, 0 replies; 9+ messages in thread
From: Charles Philip Chan @ 2015-01-15 8:01 UTC (permalink / raw)
To: help-gnu-emacs
[-- Attachment #1: Type: text/plain, Size: 700 bytes --]
On 15 Jan 2015, rustompmody@gmail.com wrote:
> Here is a vi plugin to show python with more unicode-goodness than the
> default
>
> https://github.com/yawaramin/vim-cute-python
>
> Specifically here is a syntax file
> https://github.com/yawaramin/vim-cute-python/blob/moresymbols/after/syntax/python.vim
>
> What facilities of emacs can be used for this?
Personally, I use pretty-mode:
https://github.com/akatov/pretty-mode
However, there are many different options:
http://www.emacswiki.org/emacs/PrettySymbol
Charles
--
Running Windows on a Pentium is like having a brand new Porsche but only
be able to drive backwards with the handbrake on.
(Unknown source)
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 180 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: can emacs do this
2015-01-15 7:24 can emacs do this Rusi
2015-01-15 7:57 ` Pascal J. Bourguignon
2015-01-15 8:01 ` Charles Philip Chan
@ 2015-01-15 14:22 ` Stefan Monnier
[not found] ` <mailman.17951.1421331793.1147.help-gnu-emacs@gnu.org>
3 siblings, 0 replies; 9+ messages in thread
From: Stefan Monnier @ 2015-01-15 14:22 UTC (permalink / raw)
To: help-gnu-emacs
> What facilities of emacs can be used for this?
The standard facility for that in recent Emacsen is
`prettify-symbols-mode', which you can set up with something like
(add-hook 'python-mode-hook
(lambda ()
(setq-local prettify-symbols-alist
'(("lambda" . ?λ)
("math.sqrt" . ?√)
("math.pi" . ?π)
("sum" . ?Σ)))
(prettify-symbols-mode 1)))
– Stefan
^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <mailman.17951.1421331793.1147.help-gnu-emacs@gnu.org>]
end of thread, other threads:[~2015-01-15 23:41 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-15 7:24 can emacs do this Rusi
2015-01-15 7:57 ` Pascal J. Bourguignon
2015-01-15 14:10 ` Drew Adams
2015-01-15 15:25 ` Ted Zlatanov
2015-01-15 8:01 ` Charles Philip Chan
2015-01-15 14:22 ` Stefan Monnier
[not found] ` <mailman.17951.1421331793.1147.help-gnu-emacs@gnu.org>
2015-01-15 17:27 ` Rusi
2015-01-15 17:52 ` Dan Espen
2015-01-15 23:41 ` Alexis
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).