[Mailman-Developers] Styling patch

A.M. Kuchling amk at amk.ca
Sat May 5 22:57:11 CEST 2007

On Sat, May 05, 2007 at 11:24:27AM -0400, Terri Oda wrote:
> Have the CSS generated by a CGI (which could then use these variables  
> if they're available).
> - extra processing for each web request
> + could lay groundwork to make it possible to change settings on a  
> per-list (or per virt-domain) basis rather than site-wide.

The extra processing may not be too bad if we set an Expires: header
on the CSS output.  I imagine most crawlers, well- or badly-behaved,
don't crawl the stylesheet linked from HTML pages.

> Use a Makefile to generate the CSS once from this file (and leave  
> note in file saying that further config is in CSS)
> + processing happens once
> - can't be applied easily as a patch, requires an actual rebuild to  
> take effect

I don't think this choice would work very well; requiring a rebuild
would break backward compatibility.  I don't know if that breakage
would be OK for Mailman 2.2 or 3, but it's surely off-limits for a 2.1

> Use a "style" attribute as well as a "class" one:
> + might make conversion from one type of settings to another easier
> - just going to look inexplicable and hackish later, potentially make  
> it more awkward to do CSS-only skins

- May also make the Python code messier; instead of generating 
  a div or span with a class attribute, it will need to generate 
  a style attribute as well.
+ On the other hand, we could skip generating the style attribute 
  if the corresponding mm_cfg setting is None.  That provides a nice path
  for people to switch from setting colours in mm_cfg to providing their
  own custom CSS.

Either the first or third choice would work for me.  I'd be inclined
to try #3 first and see how well it works; maybe it's not that messy
in practice.


More information about the Mailman-Developers mailing list