public inbox for sourcenav@sourceware.org
 help / color / mirror / Atom feed
* syntax highlighting
@ 2000-10-13 15:31 Jason Andrews
  2000-10-13 17:27 ` Ben Elliston
  0 siblings, 1 reply; 5+ messages in thread
From: Jason Andrews @ 2000-10-13 15:31 UTC (permalink / raw)
  To: sourcenav, bje

Can you explain the relationship between what is in the
share/etc/sn_prop.cfg file
specifically the -high_cmd argument for adding parsers and the info you
gave me below?
I have entered my new parser in the -brow_cmd and also the -high_cmd

I added hooks to the highlight.c  stuff you mentioned below but this
code is never
called for my parser's language.  I guess I don't see the connection
between my
flex based parser and these other flex files for syntax highlighting.
Maybe I need
something else for the -high_cmd field.

Any help is much appreciated.

Jason

--------------

Hi,

   I have integrated a new parser with sorucenav and I am looking for
   documentation on syntax highlighting.

The syntax highlighters have specific hooks into the `hyper'
interpreter.  For an example, go to the `hyper' source directory and
grep
for `ch_highlight' in highlight.c.

The idea is that an init function is called once to initialise things
and
then an entry point is called periodically whenever S-N's editor wants a

memory buffer (usually the file currently loaded into the editor) to be
scanned for highlighting information.

Such scanners are usually written using Flex.

   Any advice on where to find it or which parser to look at as an
   example is appreciated.

Take a look at hyper/*.l.

Yes, it's not as clean as it ought to be.  Highlighters should be loaded

into the interpreter dynamically.

Cheers, Ben

^ permalink raw reply	[flat|nested] 5+ messages in thread
* syntax highlighting
@ 2000-10-11  6:54 Jason Andrews
  2000-10-11 11:23 ` Ben Elliston
  0 siblings, 1 reply; 5+ messages in thread
From: Jason Andrews @ 2000-10-11  6:54 UTC (permalink / raw)
  To: sourcenav

Hi,

I have integrated a new parser with sorucenav and I am looking for
documentation on
syntax highlighting.

Any advice on where to find it or which parser to look at as an example
is appreciated.

Thanks,
Jason


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

end of thread, other threads:[~2000-10-14 18:13 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-10-13 15:31 syntax highlighting Jason Andrews
2000-10-13 17:27 ` Ben Elliston
2000-10-14 18:13   ` Jason Andrews
  -- strict thread matches above, loose matches on Subject: below --
2000-10-11  6:54 Jason Andrews
2000-10-11 11:23 ` Ben Elliston

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).