Index colors
Is it possible to color the message index lines according to message status? I see where a pattern can be used, and some testing show the author or subject as valid pattern matches, maybe a way to adjust the pattern to read the status tag? -- William Guynes
Re: Index colors
Is it possible to color the message index lines according to message status? Do you know about settings like: color index brightcyan default ~P ...or are you talking about something else? msg24187/pgp0.pgp Description: PGP signature
Re: Index colors
Sorry, i just realized i misinterpreted your meaning of status .. what specific attributes are you looking for? I presume you've already read through http://mutt.org/doc/manual/manual-4.html#patterns msg24188/pgp0.pgp Description: PGP signature
Re: Index colors
On Mon, Feb 04, 2002 at 03:34:39PM -0500, Mike Schiraldi wrote: [snip!] I presume you've already read through http://mutt.org/doc/manual/manual-4.html#patterns Ack! The definition of patterns has just taken on a whole new meaning. Yeah, this is what I meant. -- William Guynes
Re: Changing Index Colors
On Fri, Mar 02, 2001 at 09:48:53AM +1100, Murray Maxwell Dancey wrote: How can I make new messages to me one color, and new messages in general another color? I also want old messages to me to be yet another color. Im trying... color indexcyandefault "(~p) ~N" color indexbrightcyan default "~p" color indexgreen default "~N" color indexbrightgreen default "~O" color indexred default "~D" What I think you are failing on is order. As this is written it will first match ~p + ~N and then ~p only and as such you will never get any brightcyan. -- This session is secured by OpenSSH.
Changing Index Colors
How can I make new messages to me one color, and new messages in general another color? I also want old messages to me to be yet another color. Im trying... color indexcyandefault "(~p) ~N" color indexbrightcyan default "~p" color indexgreen default "~N" color indexbrightgreen default "~O" color indexred default "~D" thanks, -- Murray Maxwell Dancey, [EMAIL PROTECTED] icq. 106790920
Re: Changing Index Colors
* Murray Maxwell Dancey [EMAIL PROTECTED] [010301 23:51]: How can I make new messages to me one color, and new messages in general another color? I also want old messages to me to be yet another color. # messages to me (requires $alternates) color index cyan default ~p # new messages color index red default ~N # old messages to me color index green default "~p ~O" chris -- christian r. mollsthe rain descended, [EMAIL PROTECTED] and the floods came
Re: index colors
On Fri, Dec 03, 1999 at 12:57:44PM +0200, Marius Gedminas wrote: [...] Let's add another one: 4) Q: Can Mutt color different parts of the header like it can do with the body (color body foo bar regexp)? A: No. (3) is very similar to (4) and could be accomplished like this: color header color2 ... ^Subject:.*$ color header-part color1 ... ^Subject: color header-part color3 ... my@email\.address # to show it's more # powerful ;) Would result in this: Subject: foo bar [EMAIL PROTECTED] baz color1 color3 Everything else is in color2. It would be pretty easy to implement. I think. A patch is attached. This looks great! How does one go about applying patches to FreeBSD "ports"? Though I know how to apply diffs, I understand the port system only enough to type "make" followed by "make install". (It is so easy!) But with my limited knowledge of the details of the process, I don't know how to insert an external diff into the mix. Is this even a question that has a general answer? Carl
Re: index colors
On Thu, Dec 02, 1999 at 04:05:49PM -0600, Jeremy Blosser wrote: Subject: this is the subject ^^^ this is highlighted This is yet another concept from the ones discussed above. Just so we keep track of what's being talked about, there have been 3 color issues mentioned so far: 1) Q: Can Mutt color different parts of the same line different colors in the message index? A: No. 2) Q: Can Mutt color different headers different colors in the pager? A: Yes. and now we have: 3) Q: Can Mutt color different parts of the same header line different colors in the pager? A: No. Let's add another one: 4) Q: Can Mutt color different parts of the header like it can do with the body (color body foo bar regexp)? A: No. (3) is very similar to (4) and could be accomplished like this: color header color2 ... ^Subject:.*$ color header-part color1 ... ^Subject: color header-part color3 ... my@email\.address # to show it's more # powerful ;) Would result in this: Subject: foo bar [EMAIL PROTECTED] baz color1 color3 Everything else is in color2. It would be pretty easy to implement. I think. A patch is attached. Well, maybe not that easy. The problem is that MT_COLOR_HEADER overloads syntax[0].color for its default color. And continuation lines use syntax[0].first/last for their own purposes. I added a new field to the syntax_t structure (int def_color) to overcome the first problem. And I think the second is not really a problem because continuation lines are already successfully used with syntax chunks in the body. However I'm not sure if these two lines are needed for anything else besides providing default color for MT_COLOR_HEADER: pager.c line 306 (after applying my patch), function append_line: (lineInfo[n+1].syntax)[0].color = (lineInfo[n].syntax)[0].color; pager.c line 713, function resolve_types: (lineInfo[n].syntax)[0].color = (lineInfo[n-1].syntax)[0].color; A patch is included (against vanilla mutt-1.1.1i). This is my first try to hack mutt, so I'd appreciate comments. I should have probably subscribed to mutt-dev before sending patches, but this one was not planned. After writing "it would be pretty easy to implement", I decided to check if this was really so ;) Marius Gedminas -- I doubt, therefore I might be. diff -urN mutt-1.1.1.orig/color.c mutt-1.1.1/color.c --- mutt-1.1.1.orig/color.c Wed Jul 7 00:40:25 1999 +++ mutt-1.1.1/color.c Fri Dec 3 12:47:47 1999 @@ -29,6 +29,7 @@ int ColorQuoteUsed; int ColorDefs[MT_COLOR_MAX]; COLOR_LINE *ColorHdrList = NULL; +COLOR_LINE *ColorHdrPartList = NULL; COLOR_LINE *ColorBodyList = NULL; COLOR_LINE *ColorIndexList = NULL; @@ -82,6 +83,7 @@ { "tilde", MT_COLOR_TILDE }, { "markers", MT_COLOR_MARKERS }, { "header", MT_COLOR_HEADER }, + { "hdrpart", MT_COLOR_HDRPART }, { "body",MT_COLOR_BODY }, { "message", MT_COLOR_MESSAGE }, { "attachment", MT_COLOR_ATTACHMENT }, @@ -679,7 +681,8 @@ /* extract a regular expression if needed */ - if (object == MT_COLOR_HEADER || object == MT_COLOR_BODY || object == MT_COLOR_INDEX) + if (object == MT_COLOR_HEADER || object == MT_COLOR_HDRPART || + object == MT_COLOR_BODY || object == MT_COLOR_INDEX) { if (!MoreArgs (s)) { @@ -714,6 +717,8 @@ if (object == MT_COLOR_HEADER) r = add_pattern (ColorHdrList, buf-data, 0, fg, bg, attr, err,0); + else if (object == MT_COLOR_HDRPART) +r = add_pattern (ColorHdrPartList, buf-data, 1, fg, bg, attr, err, 0); else if (object == MT_COLOR_BODY) r = add_pattern (ColorBodyList, buf-data, 1, fg, bg, attr, err, 0); else if (object == MT_COLOR_INDEX) diff -urN mutt-1.1.1.orig/doc/manual.sgml.head mutt-1.1.1/doc/manual.sgml.head --- mutt-1.1.1.orig/doc/manual.sgml.headThu Sep 23 23:01:43 1999 +++ mutt-1.1.1/doc/manual.sgml.head Fri Dec 3 12:47:37 1999 @@ -949,8 +949,9 @@ itembody (match em/regexp/ in the body of messages) itembold (hiliting bold patterns in the body of messages) itemerror (error messages printed by Mutt) -itemheader (match em/regexp/ in the message header) +itemheader (match em/regexp/ in the message header; highlight whole line) itemhdrdefault (default color of the message header in the pager) +itemhdrpart (match em/regexp/ in the message header) itemindex (match em/pattern/ in the message index) itemindicator (arrow or bar used to indicate the current item in a menu) itemmarkers (the ``+'' markers at the beginning of wrapped lines in the pager) diff -urN mutt-1.1.1.orig/doc/muttrc.man.head mutt-1.1.1/doc/muttrc.man.head --- mutt-1.1.1.orig/doc/muttrc.man.head Wed Aug 18 08:54:13 1999 +++ mutt-1.1.1/doc/muttrc.man.head Fri Dec 3 12:47:47 1999 @@ -132,8 +132,8 @@ If your
Re: index colors
On Wed, Dec 01, 1999 at 04:44:17PM -0500, Subba Rao wrote: : :Is there anyway to get different colors in the index for "From" and "Subject" ? Use the regexp stuff in "color". This is what I use in my muttrc: color header magenta default ^(Subject|To|Date|From): -- Eugene Lee [EMAIL PROTECTED]
Re: index colors
Eugene Lee [EMAIL PROTECTED] wrote: Is there anyway to get different colors in the index for "From" and "Subject" ? color header magenta default ^(Subject|To|Date|From): That colorizes the headers in the pager, but I think he was asking about the index display. Such as, can the "From" address and the "Subject" portions of the display, be put in different colors? The answer is NO. This has been lovingly termed "the rainbow effect," as far as features that users think that they want. I believe that, long ago, someone did implement this in an old version of Mutt, and he reported that it looked awful. So it was never folded into Mutt. -- David DeSimone | "The doctrine of human equality reposes on this: [EMAIL PROTECTED] | that there is no man really clever who has not Hewlett-Packard | found that he is stupid." -- Gilbert K. Chesterson UX WTEC Engineer |PGP: 5B 47 34 9F 3B 9A B0 0D AB A6 15 F1 BB BE 8C 44
Re: index colors
On Thu, Dec 02, 1999 at 12:17:55PM -0600, David DeSimone wrote: Eugene Lee [EMAIL PROTECTED] wrote: Is there anyway to get different colors in the index for "From" and "Subject" ? color header magenta default ^(Subject|To|Date|From): That colorizes the headers in the pager, but I think he was asking about the index display. Such as, can the "From" address and the "Subject" portions of the display, be put in different colors? The answer is NO. This has been lovingly termed "the rainbow effect," as far as features that users think that they want. I believe that, long ago, someone did implement this in an old version of Mutt, and he reported that it looked awful. So it was never folded into Mutt. This is my number one desired feature for mutt. In an old MUA of my own design, the actual subject part of the "Subject:" line was highlighted instead of the whole line. Like so: Subject: this is the subject ^^^ this is highlighted I much prefer this as it draws your eye to the data you want to see, not the label for the data. It seems like this could be handled with regular expressions that designated how to highlight only part of the match. Like this, for example, ^Subject: ((.*))$ where the "match" is only the part of the target which matches the expression between the double parentheses. This might have other uses as as well. Carl P.S. Thanks all for such a great mail reader!
Re: index colors
Carl Cotner [[EMAIL PROTECTED]] wrote: On Thu, Dec 02, 1999 at 12:17:55PM -0600, David DeSimone wrote: Eugene Lee [EMAIL PROTECTED] wrote: Is there anyway to get different colors in the index for "From" and "Subject" ? color header magenta default ^(Subject|To|Date|From): That colorizes the headers in the pager, but I think he was asking about the index display. Such as, can the "From" address and the "Subject" portions of the display, be put in different colors? The answer is NO. This has been lovingly termed "the rainbow effect," as far as features that users think that they want. I believe that, long ago, someone did implement this in an old version of Mutt, and he reported that it looked awful. So it was never folded into Mutt. This is my number one desired feature for mutt. In an old MUA of my own design, the actual subject part of the "Subject:" line was highlighted instead of the whole line. Like so: Subject: this is the subject ^^^ this is highlighted This is yet another concept from the ones discussed above. Just so we keep track of what's being talked about, there have been 3 color issues mentioned so far: 1) Q: Can Mutt color different parts of the same line different colors in the message index? A: No. 2) Q: Can Mutt color different headers different colors in the pager? A: Yes. and now we have: 3) Q: Can Mutt color different parts of the same header line different colors in the pager? A: No. (1) and (3) are related since they both deal with coloring a single line multiple colors, but they apply to different contexts and aren't the same thing. (3) could be done with regexps, as noted, but (1) couldn't really... it would have to be specified per index field. -- Jeremy Blosser | [EMAIL PROTECTED] | http://jblosser.firinn.org/ -+-+-- "If Microsoft can change and compete on quality, I've won." -- L. Torvalds PGP signature
index colors
Is there anyway to get different colors in the index for "From" and "Subject" ? I have added this to my .muttrc: color indicator white blue # index color markers reddefault# index color message white blue # index The color remain default. Subba Rao [EMAIL PROTECTED] http://pws.prserv.net/truemax/