unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Ilya Zakharevich <nospam-abuse@ilyaz.org>
To: help-gnu-emacs@gnu.org
Subject: Re: ELisp: special read syntax for regular expressions?
Date: Sat, 12 Apr 2008 23:34:14 +0000 (UTC)	[thread overview]
Message-ID: <ftrgtm$eaj$1@agate.berkeley.edu> (raw)
In-Reply-To: mailman.10316.1208041979.18990.help-gnu-emacs@gnu.org

[A complimentary Cc of this posting was sent to
Peter Dyballa 
<Peter_Dyballa@Web.DE>], who wrote in article <mailman.10316.1208041979.18990.help-gnu-emacs@gnu.org>:

> >> Too much,

> > CPerl/Microdocs/Faces menu entry explaines which faces are used for
> > what (or see `cperl-tips-faces').  In your judgement, which constructs
> > should be "glued" together into one face?

> Separators (high-lighted? bold face?), parentheses used semantically =20
> (not as element to be matched or found), "modifiers" like s or m =20
> before and [egimosx] after the RegExp, referenced text (i.n., inside =20
> "(" and ")"), back-references, class specifications ("[:alpha:]") if =20
> not already referenced, other text.

I have no idea what you are talking about.  Currently different parts
of a REx are merged into 10 distinct groups.  Apparently, your "too
much" comment suggests that you want some of these groups merged
together.

Do not see anything like this in your reply.  Could you use complete
sentences, please?  (For convenience of other readers, I reproduce the
current doc-strings below.)

> It might be desirable to use in the from part darker shades of the =20
> colour than in the to part, i.e., <colour>3 in from and <colour>2 in =20
> to section.

Do not know what you are talking about.  Do you mean the REx part and
the substitution part?  The substitution part is just a string...

> Since GNU Emacs has a very good undo

Could not agree less...

> function it might be =20=
> 
> better to emphasise on the from part, to think better about this, to =20
> achieve on first try the desired change. (At least I have to try more =20=
> 
> than once from time to time.)

Have no clue what it is you discuss now...

> >>  =3D96 where is the RegExp
> >
> > Do not know what you mean here.
> 
> There are so many and different colours in use that I hardly can =20
> recognise any REs. I have the feeling that most lines of your =20
> examples are faulty, but I confess that I do not know all Perl =20
> RegExps by heart.

This is what the fontification is for.  There is one error; it is
highlighted...  The other stuff is highlighted in such a way that one
can always see where any escape starts and ends, so one has a better
chance to find it in the docs.

Hope this helps,
Ilya

=======================================================

In regular expressions (including character classes):
  `font-lock-string-face'	\"Normal\" stuff and non-0-length constructs
  `font-lock-constant-face':	Delimiters
  `font-lock-warning-face'	Special-cased m// and s//foo/,
				Mismatched closing delimiters, parens
				we couldn't match, misplaced quantifiers,
				unrecognized escape sequences
  `cperl-nonoverridable-face'	Modifiers, as gism in m/REx/gism
  `font-lock-type-face'		escape sequences with arguments (\\x \\23 \\p \\N)
				and others match-a-char escape sequences
  `font-lock-keyword-face'	Capturing parens, and |
  `font-lock-function-name-face' Special symbols: $ ^ . [ ] [^ ] (?{ }) (??{ })
				\"Range -\" in character classes
  `font-lock-builtin-face'	\"Remaining\" 0-length constructs, multipliers
				?+*{}, not-capturing parens, leading
				backslashes of escape sequences
  `font-lock-variable-name-face' Interpolated constructs, embedded code,
				POSIX classes (inside charclasses)
  `font-lock-comment-face'	Embedded comments


  parent reply	other threads:[~2008-04-12 23:34 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-05 11:17 ELisp: special read syntax for regular expressions? Ilya Zakharevich
2008-04-05 20:48 ` David Hansen
2008-04-06  3:18 ` Tim X
2008-05-04  1:38   ` David Combs
2008-04-06  9:35 ` Peter Dyballa
     [not found] ` <mailman.10068.1207474538.18990.help-gnu-emacs@gnu.org>
2008-04-06 21:38   ` Ilya Zakharevich
2008-04-12 23:12     ` Peter Dyballa
     [not found]     ` <mailman.10316.1208041979.18990.help-gnu-emacs@gnu.org>
2008-04-12 23:34       ` Ilya Zakharevich [this message]
2008-04-12 23:36         ` Ilya Zakharevich
2008-04-09 22:43 ` Mike Mattie
     [not found] ` <mailman.10052.1207428807.18990.help-gnu-emacs@gnu.org>
2008-04-14 23:27   ` Ilya Zakharevich
2008-04-14 23:41     ` Joost Diepenmaat
2008-04-15  1:51       ` Ilya Zakharevich
2008-04-15  4:24     ` David Hansen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='ftrgtm$eaj$1@agate.berkeley.edu' \
    --to=nospam-abuse@ilyaz.org \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).