Re: [dev] [surf] [PATCH] add per-site user styles

From: Christoph Lohmann <>
Date: Wed, 07 Jan 2015 21:38:09 +0100


On Wed, 07 Jan 2015 21:38:09 +0100 Markus Teich <> wrote:
> since the css domain selectors do not work in webkit, another approach needs to
> be taken to support custom css for specific sites. In config.h there is now a
> list of regexes and corresponding css filenames. When a page is loaded and
> userstyles are active, the first entry that matches the uri is used as
> user-stylesheet-uri. The old static stylesheet is removed but can still be used
> by installing a default rule matching any site at the end of the list.

I’m sorry for the late reply, but I had to first think of it to make it
cope with two goals:
1.) Make usable for surf.
2.) Don't interfere with the commandline options.

You are removing the possibility to enforce some userstyle on the com‐
mandline, which I don’t like.

Such a patch should include tools to make the scripts be‐
ing easily addable to surf. I would need to parse the comments and then
add it to the .surf/userstyles folder. The question is, if it’s enough
to handle all of it in the custom javascript file, which won’t work when
Javascript is turned off or your array in config.h is really needed.


Christoph Lohmann

Received on Wed Jan 07 2015 - 21:38:09 CET

This archive was generated by hypermail 2.3.0 : Wed Jan 07 2015 - 21:48:08 CET