* man pages in c-mode
@ 2007-05-30 21:02 Hadron
2007-05-30 22:47 ` David Hansen
0 siblings, 1 reply; 2+ messages in thread
From: Hadron @ 2007-05-30 21:02 UTC (permalink / raw)
To: help-gnu-emacs
I thought this might turn my man page display into c-mode. It
doesnt. What must I do?
(defun jump-man-page ()
(interactive)
(manual-entry (current-word))
(c-mode)
)
Note that I call manual-entry in "aggressive" mode meaning that
manual-entry puts the man page into another buffer and sets focus
there. I can then manually set c-mode with no problem using
M-x c-mode
But how to do it from my function which is bound to a function key?
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: man pages in c-mode
2007-05-30 21:02 man pages in c-mode Hadron
@ 2007-05-30 22:47 ` David Hansen
0 siblings, 0 replies; 2+ messages in thread
From: David Hansen @ 2007-05-30 22:47 UTC (permalink / raw)
To: help-gnu-emacs
On Wed, 30 May 2007 23:02:38 +0200 Hadron wrote:
> I thought this might turn my man page display into c-mode. It
> doesnt. What must I do?
>
> (defun jump-man-page ()
> (interactive)
> (manual-entry (current-word))
> (c-mode)
> )
(let ((Man-mode-hook (push #'c-mode Man-mode-hook)))
(manual-entry "fprintf"))
may work but i doubt it's a good idea. Note that at least on my system
every man page starts with "Linux Programmer's Manual" and font-lock
isn't happy about the `''.
David
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-05-30 22:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-30 21:02 man pages in c-mode Hadron
2007-05-30 22:47 ` David Hansen
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).