delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/08/25/06:42:09

Date: Mon, 25 Aug 1997 13:41:44 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: djgpp AT delorie DOT com
Subject: Re: Syntax-help in emacs
Message-ID: <Pine.SUN.3.91.970825134107.3327H-100000@is>
MIME-Version: 1.0

On Mon, 25 Aug 1997, Paul Derbyshire wrote:

> >With Emacs, the question isn't whether there *is* a way--of course
> >there is--but *how* ;-).
> 
> hehe... thanks... And the other question is, has someone already invented
> this, and if so how do you get a copy, if not how the devil do you 
> program it?

True.  Some hints:

	Use apropos (C-h a) and grep to find what's in the lisp
subdirectory.

	Get the Lisp Directory and the associated commands to search it 
(the URL should be in the Emacs FAQ).  This is a data-base of 
user-written extensions to Emacs.

	Post a question to gnu.emacs.help (or write to 
help-gnu-emacs AT prep DOT ai DOT mit DOT edu, if you cannot access that group).  There 
are a few people there (not me, of course) who will give you very good 
advice.

> (And considering that after a few hours of fiddling and reading mountains
> of dox I was able to alter the .emacs to set my own colors for syntax
> highlighting and my own ccmode indents, I don't think I did TOO badly...
> not to mention, remap a few keys to match common DOS/RHIDE editing, alt-f4
> to kill a window, ^V for paste (yank), f3 or ^L for repeat search and so
> on...)

You are doing just fine, congratulations.

> >(autoload 'find-tag-tag "etags")
> >(autoload 'Info-find-node "info")
> 
> I think these must be to load the named function from the named .el file?

Either .el or .elc (the latter is byte-compiled and runs faster).

> Can that do C++ and other stuff as well?

You need to write something similar for C++-mode that looks into the 
appropriate C++ info files (iostream, libgpp etc.).

> Has anyone even written any info for C++, iostreams, STL, and so forth

Not that I know of.

> or for that matter for C and C++ atomics like while {}?

I have never seen an Info file about C or C++ as a *language*.  Until 
such a thing gets written, you cannot look it up.

> >It prompts with the word at point as the default.  Press RET if that's
> >what you want, or type another function name and press RET.
> 
> Is there a way to get the RET automatic?

Yes, you can, by changing the code a bit.  But do you really need that?  
I find it very useful to get a chance at what my Golem thinks I need to 
know before it jumps into the blue.  A single RET is not too much, after 
all.

> perhaps a second version of the
> defun above, maybe for C-f1 and M-f1 as described above? Then C-f1 is an
> immediate info screen, M-f1 is a lookup prompt.

Well, why won't you try writing this?

> Yeah. But there are no man pages in DOS, and nobody saw fit to put any in
> the emacs distribution... :-)

I've added this to my _emacs when John posted it, so the next DJGPP 
distribution will have it in the _emacs.xmpl file.

> >If you want to program in ELisp, I suggest to get the Emacs Lisp
> >reference (elisp-manual-NN.MM.tar.gz from GNU ftp sites).  You don't
> >need to read it in its entirety (it's HUGE), but searching through it
> >always helps me find what I want.
> 
> What if you have no linux, and can't unjar and ungzip this format of
> archive?

Use DJTAR.  It is excellent for these tasks.  You should have no problems 
installing ELisp manual with DJTAR.  There might be some .texi files that
will make trouble, but you can just skip them (press RET when DJTAR 
prompts for an alternative filename), because all you need is the .info-* 
files.

(Btw, for the record: I don't have Linux on my machines.  I do everything 
either in DOS or Windows 3.X/9X.)

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019