comp.lang.ada
 help / color / mirror / Atom feed
* HELP!!!! How do you modify the font-lock-mode for ada-mode!!
@ 1994-12-08 21:57 Al Niessner III
  1994-12-09 21:49 ` Rolf Ebert
  1994-12-10  5:07 ` HELP!!!! How do you modify the font-lock-mode for ada-mode!! Cyrille Comar
  0 siblings, 2 replies; 5+ messages in thread
From: Al Niessner III @ 1994-12-08 21:57 UTC (permalink / raw)




PLEASE HELP!!
I am a newbie at this emacs game and am having an extreamly difficult time modify
it to do what I need.  I am using the GNU Emacs 19.28.1 (I installed it Wednesday).
I can get the font-lock-mode (minor) to work with c-mode, lisp-mode, and some other
major modes but I can't get it to work with ada-mode!!!!  I've tried hooks and global
variables and soon will take the flame throwers approach.  All I need is a simple
example which demonstates how to take three or four Ada reserved words put them in
the CORRECT font-lock-keywords list as to make them a specific face (ie the face
font-lock-keyword-face.  I know this is the default face for the list BUT PLEASE put
the font face in the command and don't let it be hidden by the default value).  I
just learned lisp (Wednesday) so I don't even rate a user of the language yet so 
PLEASE make it simple.

What I would really like is a GNU Ada 9x mode which utilizes the font-lock-mode
already if thats outthere.

I cannot use lucid emacs for various resons.

Please send all information to my email because I don't normally subscribe to these
groups and I cross posted it to several related groups.  Thanks in advance and sorry
if I posted were I shouldn't have.


Al Niessner III
email:  afniii@hades.arl.psu.edu
voice:  (814) 865-0968






^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: HELP!!!! How do you modify the font-lock-mode for ada-mode!!
  1994-12-08 21:57 HELP!!!! How do you modify the font-lock-mode for ada-mode!! Al Niessner III
@ 1994-12-09 21:49 ` Rolf Ebert
  1994-12-20 17:50   ` ada-mode problems David D. Shochat
  1994-12-10  5:07 ` HELP!!!! How do you modify the font-lock-mode for ada-mode!! Cyrille Comar
  1 sibling, 1 reply; 5+ messages in thread
From: Rolf Ebert @ 1994-12-09 21:49 UTC (permalink / raw)
  To: afniii

>>>>> "Al" == Al Niessner <afniii@hades.arl.psu.edu> writes:

Al> PLEASE HELP!!  I am a newbie at this emacs game and am having an
Al> extreamly difficult time modify it to do what I need.  I am
Al> using the GNU Emacs 19.28.1 (I installed it Wednesday).  I can
Al> get the font-lock-mode (minor) to work with c-mode, lisp-mode,
Al> and some other major modes but I can't get it to work with
Al> ada-mode!!!!  I've tried hooks and global variables and soon
Al> will take the flame throwers approach.  All I need is a simple
Al> example which demonstates how to take three or four Ada reserved
Al> words put them in the CORRECT font-lock-keywords list as to make
Al> them a specific face (ie the face font-lock-keyword-face.  I
Al> know this is the default face for the list BUT PLEASE put the
Al> font face in the command and don't let it be hidden by the
Al> default value).  I just learned lisp (Wednesday) so I don't even
Al> rate a user of the language yet so PLEASE make it simple.

Al> What I would really like is a GNU Ada 9x mode which utilizes the
Al> font-lock-mode already if thats outthere.

You should get emacs-ada-mode-2.8 at cs.nyu.edu:/pub/gnat.  It is an
ada9x(*) mode and has full support for font-lock.  Version 2.10 was posted
to gnu.emacs sources a while ago. An archive of that group is on
wuarchive.wustl.edu. 

Al> I cannot use lucid emacs for various resons.

You don't need to, but you can.  With some patches Ada Mode works with
XEmacs (lemacs) as well (patches will be integrated in the next release)

Al> Please send all information to my email because I don't normally
Al> subscribe to these groups and I cross posted it to several
Al> related groups.  Thanks in advance and sorry if I posted were I
Al> shouldn't have.

You shouldn't have posted to gnu.emacs.sources. That's posting sources
only.  You can ask for help on gnu.emacs.help.

Al> Al Niessner III email: afniii@hades.arl.psu.edu voice: (814)
Al> 865-0968

BTW, as you use Emacs for programming Ada, use Emacs for composing
massages as well...


	Rolf


--
Rolf Ebert			Beratung fuer Energiesysteme und Informatik
Erich Kaestner Str. 17               Conseil en Energetique et Informatique
D - 80796 Muenchen        (Team Ada)               Tel.: +49-89-30.77.88.00
Germany                                            Fax.: +49-89-30.77.91.00
-- 
Rolf Ebert			Beratung fuer Energiesysteme und Informatik
Erich Kaestner Str. 17               Conseil en Energetique et Informatique
D - 80796 Muenchen        (Team Ada)               Tel.: +49-89-30.77.88.00
Germany                                            Fax.: +49-89-30.77.91.00



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: HELP!!!! How do you modify the font-lock-mode for ada-mode!!
  1994-12-08 21:57 HELP!!!! How do you modify the font-lock-mode for ada-mode!! Al Niessner III
  1994-12-09 21:49 ` Rolf Ebert
@ 1994-12-10  5:07 ` Cyrille Comar
  1 sibling, 0 replies; 5+ messages in thread
From: Cyrille Comar @ 1994-12-10  5:07 UTC (permalink / raw)


afniii@hades.arl.psu.edu (Al Niessner III) writes:
: 
: 
: PLEASE HELP!!

will try...
: 
: What I would really like is a GNU Ada 9x mode which utilizes the 
: font-lock-mode already if thats outthere.

you are lucky , such a mode exists, uses Font-lock-mode by default and does
many other amazing things... 
take a (ftp) look at cs.nyu.edu
in pub/gnat
Cyrille
-- 
------------------------------------------------------------------------
Cyrille Comar,                                  E-mail: comar@cs.nyu.edu
Gnat Project                                    US phone: (212) 998-3489




^ permalink raw reply	[flat|nested] 5+ messages in thread

* ada-mode problems
  1994-12-09 21:49 ` Rolf Ebert
@ 1994-12-20 17:50   ` David D. Shochat
  1994-12-21 21:11     ` Dirk Zoller
  0 siblings, 1 reply; 5+ messages in thread
From: David D. Shochat @ 1994-12-20 17:50 UTC (permalink / raw)


I too am having trouble with ada-mode. I have:
GNAT 2.0 on Solaris 2.3
emacs 19.28
ada-mode 2.8 from cs.nyu.edu /pub/gnat
I'm using the sample .emacs from the manual essentially
unchanged (except for loading the .el files from the
directory where I unloaded the tar file).

Some things do seem to work (e.g. indentation). But when I try to
use the compile command from the Ada menu, I just get a "make -k"
prompt in the minibuffer. I tried changing it to gcc -c, but then
it didn't insert the file name. The manual claims there's a variable
compilation-insert-name which is presumably set to t by default,
but when I searched compile.el, there was no such variable. Also,
it is undefined. 

Another problem: ada-auto-case is set to t, but I can't seem to
get it to change case "as I type". The buffer is definitely in
Ada mode (says Ada at the bottom, Ada menu appears).

I suppose I need to learn a lot more about emacs to resolve
all of this, but I'd appreciate any help.

David Shochat  dshochat@logicon.com



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: ada-mode problems
  1994-12-20 17:50   ` ada-mode problems David D. Shochat
@ 1994-12-21 21:11     ` Dirk Zoller
  0 siblings, 0 replies; 5+ messages in thread
From: Dirk Zoller @ 1994-12-21 21:11 UTC (permalink / raw)


Hello,


David D. Shochat (dshochat@kaiwan009.kaiwan.com) wrote:
: emacs 19.28
: ada-mode 2.8 from cs.nyu.edu /pub/gnat

I use the same versions and are relatively happy.

: Some things do seem to work (e.g. indentation).
Not perfectly. It gets confused after a use statement inside a package body.
E.g.
	package body blabla is
	   package int_io is new integer_io (integer);
	   use int_io;

now the indentation is completely different from what it would be
without the use clause.

: But when I try to
: use the compile command from the Ada menu, I just get a "make -k"
: prompt in the minibuffer. I tried changing it to gcc -c, but then
: it didn't insert the file name.

I suspect you are on the wrong trail here. It would be better if you
could rely on make to know how to make an executable from Ada sources.
Unfortunately you can't yet.

If you have a C-source xyz.c and want to have the executable xyz then
you can simply say make xyz. That's why emacs suggests the "make -k"
command line.

I use the following Makefile to achieve a similar effect with ada
sources too. It declares a few new "pattern rules" (works only with
GNU-make).

=======================================================================
#
# Makefile --- Makefile for GNU-make, make executables from Ada sources
#

# for OS/2 use:
O       = .obj
E       = .exe

# for Unices use:
ifdef HOSTNAME # a variable only defined in unix
O       = .o
E       = 
endif

CC      = gcc
ADAC    = $(CC)
GF      = -O2 -fomit-frame-pointer
BF      = -s

%.ali %$O : %.ads %.adb
		$(ADAC) -c $(GF) $*.adb

%.ali %$O : %.adb
		$(ADAC) -c $(GF) $<

%.s : %.adb
		$(ADAC) -S $(GF) $< -o $@

%$O : %.c
		$(CC) -c $(CFLAGS) $< -o $@

%.s : %.c
		$(CC) -S $(CFLAGS) $< -o $@

%$E : %.ali %$O
		gnatbl $(BF) $< -o $@
=======================================================================
(Don't cut/paste this text from an xterm, the tabs are important!)

Note that this Makefile doesn't contain any target. You can include it
in your Makefiles and add targets or simply say "make target" when
there is a target.adb source.

There are a few rules to build executables from multiple sources. The
dependency is chained using the *.ali files GNAT produces along with
the objects.

What more good ideas on using make with GNAT do you have?

Dirk
---
duz@roxi.rz.fht-mannheim.de <Dirk Zoller>



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1994-12-21 21:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1994-12-08 21:57 HELP!!!! How do you modify the font-lock-mode for ada-mode!! Al Niessner III
1994-12-09 21:49 ` Rolf Ebert
1994-12-20 17:50   ` ada-mode problems David D. Shochat
1994-12-21 21:11     ` Dirk Zoller
1994-12-10  5:07 ` HELP!!!! How do you modify the font-lock-mode for ada-mode!! Cyrille Comar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox