[Ur] A direction for Ur/Web

Karn Kallio tierpluspluslists at gmail.com
Sun Mar 27 14:42:19 EDT 2011


> > Well, some similar fuzzy brainstorming that has occurred to me before:
> > To have safely "tweakable" themes Ur/Web could represent them as types in
> > some way.  That probably means Ur/Web will have to represent CSS too. 
> > To naturally support user changes of themes at run time then probably
> > implies that Ur/Web will need more support for dependent types, to allow
> > expressions of a theme type depending on a value coming from a user.
> 
> Why is linking to an alternate style sheet not enough to effect such a
> change?  This is completely supported even in the most recent official
> Ur/Web release.
> 

I assume safely tweakable themes require some sort of guarantee that there is 
at least a minimum level of correspondence between the CSS and the XHTML.  The 
current mechanism of linking to a style sheet provides no guarantees on the 
CSS content of that style sheet; indeed, the style sheet may not even contain 
valid CSS.  Of course Ur/Web supports theming, but I don't think it currently 
supports *safe* theming.  Control of CSS class attributes via style helps but 
leaves too much underspecified to be safe (in my opinion).

> If you want any more than this, then major changes to the
> language/compiler would be required, since the present support is based
> essentially on whole-program compilation.

Yes, certainly, but I guess it could be a "future direction" for Ur/Web.  



More information about the Ur mailing list