Gnus development mailing list
 help / color / mirror / Atom feed
* Group highlighting
@ 1997-02-27 15:59 Jens Lautenbacher
  1997-03-01  0:01 ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 4+ messages in thread
From: Jens Lautenbacher @ 1997-02-27 15:59 UTC (permalink / raw)




Hi,

There seem to be some inconsitencies with the way groups lines are
highlighted. 

As far as I see there are two incompatible ways to do this:

a) using custom gnus-face-x fonts in the gnus-group-line-format.

b) by a call to gnus-group-highlight-line, which is on by default, and
   which uses gnus-group-highlight to see how a particular line should
   be highlighted.

The problem is that first a) is done and then, if it is selected, b).
But b) overwrites any (face) changes done by a).

But I would like to have both the same time. a) for colouring e.g. the
number of articles or methods and b) for the group name. One should do:

Restrict b) on a certain part of the group line, e.q. by some new spec
one could give to gnus-group-line-format. This would be the cleanest
approach IMHO, but I don't know how to do this... :-( 

Another possibility would go along the following I tried:

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

<removing gnus-group-highlight-line from gnus-group-update-hook>

I defined gnus-face-7

(setq gnus-face-7 '(progn
		     (let ((list gnus-group-highlight) elem)
		       (while (not (eval (car (setq elem (pop list))))))
		       (setq res (cdr elem)))))


I set Gnus Group Line Format to  %M%S%p%P%5y: %7{%(%g%)%}%l\n

I changed gnus-face-face-function:

(defun gnus-face-face-function (form type)
  (let (elem)
    `(gnus-put-text-property
    (point) (progn ,@form (point))
    'face ',(if (symbolp
		 (setq elem
		       (symbol-value (intern (format "gnus-face-%d" type)))))
		elem
	      (eval elem)))))
-----------------------------------------

and hoped that this would work, but nada, it didn't because all the
variables defined in the gnus-group-highlight list are not defiend
when the format spec is evaluated.

Maybe one could also fix this. Anyways it would be a good idea IMHO to
make the change to gnus-face-face-function allowing for forms instead
of just faces.

   Jens


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

end of thread, other threads:[~1997-03-01  3:20 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-02-27 15:59 Group highlighting Jens Lautenbacher
1997-03-01  0:01 ` Lars Magne Ingebrigtsen
1997-03-01  1:58   ` Jens Lautenbacher
1997-03-01  3:20     ` Lars Magne Ingebrigtsen

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 NNTP newsgroup(s).