X-Git-Url: https://git.danieliu.xyz/?p=surf.git;a=blobdiff_plain;f=config.def.h;h=9bdbe0ca1f55a9df4c3d1e824ffb2b1130dea6bb;hp=e4f82a18096f0a45e26b66079cc28c6a8d361e63;hb=c870098b82f1dfc3cd59cd8c90cea580bd01cb47;hpb=11b34c08146928754ade63b285ba861f0be6a416 diff --git a/config.def.h b/config.def.h index e4f82a1..9bdbe0c 100644 --- a/config.def.h +++ b/config.def.h @@ -3,11 +3,14 @@ static int surfuseragent = 1; /* Append Surf version to default WebKit user static char *fulluseragent = ""; /* Or override the whole user agent string */ static char *scriptfile = "~/.surf/script.js"; static char *styledir = "~/.surf/styles/"; +static char *certdir = "~/.surf/certificates/"; static char *cachedir = "~/.surf/cache/"; static char *cookiefile = "~/.surf/cookies.txt"; /* Webkit default features */ static Parameter defconfig[ParameterLast] = { + SETB(AcceleratedCanvas, 1), + SETB(Certificate, 0), SETB(CaretBrowsing, 0), SETV(CookiePolicies, "@Aa"), SETB(DiskCache, 1), @@ -20,14 +23,16 @@ static Parameter defconfig[ParameterLast] = { SETB(JavaScript, 1), SETB(KioskMode, 0), SETB(LoadImages, 1), + SETB(MediaManualPlay, 0), SETB(Plugins, 1), SETV(PreferredLanguages, ((char *[]){ NULL })), SETB(RunInFullscreen, 0), SETB(ScrollBars, 1), SETB(ShowIndicators, 1), + SETB(SiteQuirks, 1), SETB(SpellChecking, 0), SETV(SpellLanguages, ((char *[]){ "en_US", NULL })), - SETB(StrictSSL, 0), + SETB(StrictTLS, 1), SETB(Style, 1), SETF(ZoomLevel, 1.0), }; @@ -39,6 +44,9 @@ static UriParameters uriparams[] = { }, }, }; +/* default window size: width, height */ +static int winsize[] = { 800, 600 }; + static WebKitFindOptions findopts = WEBKIT_FIND_OPTIONS_CASE_INSENSITIVE | WEBKIT_FIND_OPTIONS_WRAP_AROUND; @@ -84,11 +92,20 @@ static WebKitFindOptions findopts = WEBKIT_FIND_OPTIONS_CASE_INSENSITIVE | * The iteration will stop at the first match, beginning at the beginning of * the list. */ -static SiteStyle styles[] = { +static SiteSpecific styles[] = { /* regexp file in $styledir */ { ".*", "default.css" }, }; +/* certificates */ +/* + * Provide custom certificate for urls + */ +static SiteSpecific certs[] = { + /* regexp file in $certdir */ + { "://suckless\\.org/", "suckless.org.crt" }, +}; + #define MODKEY GDK_CONTROL_MASK /* hotkeys */ @@ -139,7 +156,6 @@ static Key keys[] = { { MODKEY|GDK_SHIFT_MASK, GDK_KEY_a, togglecookiepolicy, { 0 } }, { 0, GDK_KEY_F11, togglefullscreen, { 0 } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_o, toggleinspector, { 0 } }, - { MODKEY|GDK_SHIFT_MASK, GDK_KEY_m, togglestyle, { 0 } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_c, toggle, { .i = CaretBrowsing } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_f, toggle, { .i = FrameFlattening } }, @@ -148,6 +164,7 @@ static Key keys[] = { { MODKEY|GDK_SHIFT_MASK, GDK_KEY_i, toggle, { .i = LoadImages } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_v, toggle, { .i = Plugins } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_b, toggle, { .i = ScrollBars } }, + { MODKEY|GDK_SHIFT_MASK, GDK_KEY_t, toggle, { .i = StrictTLS } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_m, toggle, { .i = Style } }, };