69 Commits

Author SHA1 Message Date
Enno Boland (tox) c00ee3eb78 changing SETPROP()-macro 2009-10-30 13:38:14 +01:00
Enno Boland (tox) c30a95c635 quoting fix reported by Evan Gates. 2009-10-28 22:22:20 +01:00
Enno Boland (tox) ae42cfde8f sorting functions alphabetical. 2009-10-28 20:43:30 +01:00
Enno Boland (tox) 9d4953691d some polishing. 2009-10-28 19:27:11 +01:00
Enno Boland (tox) 54c73ca84d removed warning when closing a surf-window. 2009-10-28 17:33:31 +01:00
Enno Boland (tox) 4501408808 displaying progress before pagetitle. 2009-10-28 12:17:15 +01:00
Enno Boland (tox) 742fc7fac1 adding automatic download for not supported files. 2009-10-27 08:26:21 +01:00
Enno Boland (tox) a9d733bd9f fixing downloads based on Evan Gates' patch. 2009-10-27 08:11:44 +01:00
Enno Boland (tox) 1d019cf8af Adding Evan Gates' patch. 2009-10-26 22:02:21 +01:00
Enno Boland (tox) f347b9f336 moving reloadcookie() call 2009-10-26 22:01:44 +01:00
Enno Boland (tox) b29a8f5356 cleaning up config.mk 2009-10-26 16:54:33 +01:00
Enno Boland (tox) 05fbb4ab76 Adding Lorenzo Bollas hints patch. 2009-10-21 15:52:36 +02:00
Enno Boland (tox) c82fff2dd3 using geturi() where possible. 2009-10-21 10:06:55 +02:00
Enno Boland (tox) b483f49b20 next version is 0.3 2009-10-21 10:06:21 +02:00
Enno Boland (tox) 87563c7e9d fixing config.def.h 2009-10-21 09:25:09 +02:00
Enno Boland (tox) 9557e7b769 replacing ignore_once with ignorexprop 2009-10-21 08:35:58 +02:00
Enno Boland (tox) 52a9c8ca52 removing comments. 2009-10-20 23:54:37 +02:00
Enno Boland (tox) e0a8f381b9 forgot to add config.def.h 2009-10-20 23:49:37 +02:00
Enno Boland (tox) 50192577ee replacing gtk-textentrys with dmenu 2009-10-20 23:46:54 +02:00
Enno Boland (tox) 60dd7545d3 small fix 2009-10-20 20:58:18 +02:00
Enno Boland (tox) c38404fd0b small cleanups 2009-10-20 20:52:43 +02:00
Enno Boland (tox) 31441e93f7 adding autozoom lock when site is already zoomed. 2009-10-20 20:49:33 +02:00
Enno Boland (tox) 92afa03d80 adding autozoom for small windows 2009-10-20 20:34:13 +02:00
Enno Boland (tox) f277dbd3d2 using another way to handle cookies. 2009-10-20 19:51:14 +02:00
Enno Boland (tox) 54b93a2dd6 Backed out changeset 7a57a0a8dbc6 2009-10-20 18:57:08 +02:00
Enno Boland (tox) 72e01b2544 reformating 2009-10-20 14:11:08 +02:00
Enno Boland (tox) 0835ea2124 Trying a different cookie handling system. 2009-10-20 14:10:21 +02:00
Enno Boland (tox) 75cc43047f changing some labels in submenu. 2009-10-20 14:09:37 +02:00
Enno Boland (tox) 9dc703aff3 whitespace fix. 2009-10-17 20:54:11 +02:00
Enno Boland (tox) ca10af0783 typo fix 2009-10-17 20:33:27 +02:00
Enno Boland (tox) 2cfbcbdf71 updating manpage. 2009-10-17 15:17:58 +02:00
Enno Boland (tox) 9a3c483893 using events for changing cookies 2009-10-17 13:19:21 +02:00
Enno Boland (tox) e9ee0940b7 Sessioncookies made persistant. 2009-10-17 12:41:40 +02:00
Enno Boland (tox) 8eb2392442 Added tag 0.2 for changeset a5db79d487c8 2009-10-17 09:23:28 +02:00
Enno Boland (tox) bdfa30bf33 fixing double calling functions from contextmenu. 2009-10-17 08:57:23 +02:00
Enno Boland (tox) 5ac31995a3 implementing cookie persistance with multiple processes. 2009-10-17 08:38:46 +02:00
Enno Boland (tox) 3657813fec removed builtin unfinished cookie handling. 2009-10-17 07:50:10 +02:00
Enno Boland (tox) 7ffdcd756c small typo 2009-10-16 16:34:05 +02:00
Enno Boland (tox) 2eafff0e8b using char instead of gchar. 2009-10-16 16:33:18 +02:00
Enno Boland (tox) b298d889de implementing user defined context menu 2009-10-16 15:35:11 +02:00
Enno Boland (tox) e3690dffed renaming newproc to newwindow; make it usable within keys; begin implementing contextmenu 2009-10-16 14:19:25 +02:00
Enno Boland (tox) f62505a47a changing char to gchar where possible; unifing WebKitWebView variable naming 2009-10-16 14:03:39 +02:00
Enno Boland (tox) 7e86ea553f improving urlbar hiding. 2009-10-16 10:55:05 +02:00
Enno Boland (tox) 17bbc1a3cc creating new process when opening new window if possible. 2009-10-15 16:31:49 +02:00
Enno Boland (tox) 533c8e5b35 better useragent string (for google-* and stuff) 2009-10-14 19:05:01 +02:00
Enno Boland (tox) d97b8adfde changing useragent. 2009-10-14 16:28:00 +02:00
Enno Boland (tox) 24bbd6be02 uncommenting source() 2009-10-14 15:19:00 +02:00
Enno Boland (tox) fe87a88954 removing loadfile. readding later in a simpler way. 2009-10-13 23:22:25 +02:00
Enno Boland (tox) 95a6bfcc03 removing debug output 2009-10-13 22:02:06 +02:00
Enno Boland (tox) 499a497b4e fixing stupidy bug. 2009-10-13 22:01:19 +02:00
Enno Boland (tox) 029dac1504 fixing memoryleak. 2009-10-13 21:58:35 +02:00
Enno Boland (tox) 0d28cf7458 making config-files configurable in config.h 2009-10-13 21:52:43 +02:00
Enno Boland (tox) 92cb8792e1 small whitespacefix. 2009-10-13 20:10:43 +02:00
Enno Boland (tox) 04173f6661 hooking onloadfunctions should be done by script.js. 2009-10-07 15:00:20 +02:00
Enno Boland (tox) d3d32fd6c7 commenting. 2009-09-21 19:28:39 +02:00
Enno Boland (tox) a3e1e27762 typo 2009-09-21 03:27:20 +02:00
Enno Boland (tox) 2e9af54363 reformating 2009-09-17 13:03:58 +02:00
Enno Boland (tox) 25b9ae3ce4 applied patch from arg. thanks :) 2009-09-17 01:09:00 +02:00
Enno Boland (tox) d2a4436123 next version is 0.2 2009-09-16 10:18:08 +02:00
Enno Boland (tox) 65e09f7b03 auto creation of script.js 2009-09-16 10:12:27 +02:00
Enno Boland (tox) e9d4da3030 adding user.js support. 2009-09-16 10:06:21 +02:00
Enno Boland (tox) 0e3ac7f3b0 usercss works again. 2009-09-13 16:15:28 +02:00
Enno Boland (tox) a2da3b7eef Added tag 0.1.2 for changeset bffb0c3c2341 2009-09-11 09:39:43 +02:00
Enno Boland (tox) 0ece786d3f next will be 0.1.2 2009-09-11 09:39:36 +02:00
Enno Boland (tox) 2f639aede5 Makefile fixing 2009-09-11 09:38:53 +02:00
Enno Boland (tox) f400f0d56f Adding README file. 2009-09-11 08:18:09 +02:00
Enno Boland (tox) 44511e2549 unfocus should return false; renaming cookie-file. 2009-09-11 08:12:08 +02:00
Enno Boland (tox) 38a098c81d surf embeds now itself into another window. 2009-09-11 07:21:18 +02:00
Enno Boland (tox) c023780eda Added tag 0.1.1 for changeset 3ef997607115 2009-09-10 23:36:54 +02:00
7 changed files with 537 additions and 364 deletions
+3
View File
@@ -1,3 +1,6 @@
d8628fc93353faa411c9fc7eef82d11a84d26ae2 0.1 d8628fc93353faa411c9fc7eef82d11a84d26ae2 0.1
d8628fc93353faa411c9fc7eef82d11a84d26ae2 0.1 d8628fc93353faa411c9fc7eef82d11a84d26ae2 0.1
9c8ebcf54061112b5979742b403de26fc94007ff 0.1 9c8ebcf54061112b5979742b403de26fc94007ff 0.1
3ef997607115303fe93873b592d152f0ec186f77 0.1.1
bffb0c3c23410ac7f260d167f4b9771497fc1127 0.1.2
a5db79d487c85615be2ecf30815c6b4977e88000 0.2
+1 -1
View File
@@ -35,7 +35,7 @@ clean:
dist: clean dist: clean
@echo creating dist tarball @echo creating dist tarball
@mkdir -p surf-${VERSION} @mkdir -p surf-${VERSION}
@cp -R LICENSE Makefile config.mk \ @cp -R LICENSE Makefile config.mk config.def.h README \
surf.1 ${SRC} surf-${VERSION} surf.1 ${SRC} surf-${VERSION}
@tar -cf surf-${VERSION}.tar surf-${VERSION} @tar -cf surf-${VERSION}.tar surf-${VERSION}
@gzip surf-${VERSION}.tar @gzip surf-${VERSION}.tar
+25
View File
@@ -0,0 +1,25 @@
surf - simple webkit-based browser
==================================
surf is a simple Web browser based on WebKit/GTK+.
Requirements
------------
In order to build surf you need GTK+ and Webkit/GTK+ header files.
Installation
------------
Edit config.mk to match your local setup (surf is installed into
the /usr/local namespace by default).
Afterwards enter the following command to build and install surf (if
necessary as root):
make clean install
Running surf
------------
run
surf [URL]
+41 -26
View File
@@ -1,32 +1,47 @@
/* modifier 0 means no modifier */ /* modifier 0 means no modifier */
static gchar *progress = "#FF0000"; static char *useragent = "Mozilla/5.0 (X11; U; Linux; en-us) AppleWebKit/531.2+ (KHTML, like Gecko, surf-"VERSION") Safari/531.2+";
static gchar *progress_trust = "#00FF00"; static char *progress = "#FF0000";
static char *progress_trust = "#00FF00";
static char *stylefile = ".surf/style.css";
static char *scriptfile = ".surf/script.js";
static char *cookiefile = ".surf/cookies.txt";
static char *dldir = ".surf/dl";
static time_t sessiontime = 3600;
#define SETPROP(p) { .v = (char *[]){ "/bin/sh", "-c", \
"prop=\"`dmenu < /dev/null`\" &&" \
"xprop -id $1 -f $0 8s -set $0 \"$prop\"", \
p, winid, NULL } }
#define MODKEY GDK_CONTROL_MASK #define MODKEY GDK_CONTROL_MASK
static Key keys[] = { static Key keys[] = {
/* modifier keyval function arg Focus */ /* modifier keyval function arg Focus */
{ MODKEY|GDK_SHIFT_MASK,GDK_r, reload, { .b = TRUE }, ALWAYS }, { MODKEY|GDK_SHIFT_MASK,GDK_r, reload, { .b = TRUE } },
{ MODKEY, GDK_r, reload, { .b = FALSE }, ALWAYS }, { MODKEY, GDK_r, reload, { .b = FALSE } },
{ MODKEY, GDK_g, showurl, { 0 }, ALWAYS }, { MODKEY|GDK_SHIFT_MASK,GDK_p, print, { 0 } },
{ MODKEY, GDK_slash, showsearch, { 0 }, ALWAYS }, { MODKEY, GDK_p, clipboard, { .b = TRUE } },
{ 0, GDK_Escape, hidesearch, { 0 }, ALWAYS }, { MODKEY, GDK_y, clipboard, { .b = FALSE } },
{ 0, GDK_Escape, hideurl, { 0 }, ALWAYS }, { MODKEY|GDK_SHIFT_MASK,GDK_j, zoom, { .i = -1 } },
{ MODKEY|GDK_SHIFT_MASK,GDK_p, print, { 0 }, ALWAYS }, { MODKEY|GDK_SHIFT_MASK,GDK_k, zoom, { .i = +1 } },
{ MODKEY, GDK_p, clipboard, { .b = TRUE }, BROWSER }, { MODKEY|GDK_SHIFT_MASK,GDK_i, zoom, { .i = 0 } },
{ MODKEY, GDK_y, clipboard, { .b = FALSE }, BROWSER }, { MODKEY, GDK_l, navigate, { .i = +1 } },
{ MODKEY|GDK_SHIFT_MASK,GDK_j, zoom, { .i = -1 }, BROWSER }, { MODKEY, GDK_h, navigate, { .i = -1 } },
{ MODKEY|GDK_SHIFT_MASK,GDK_k, zoom, { .i = +1 }, BROWSER }, { MODKEY, GDK_j, scroll, { .i = +1 } },
{ MODKEY|GDK_SHIFT_MASK,GDK_i, zoom, { .i = 0 }, BROWSER }, { MODKEY, GDK_k, scroll, { .i = -1 } },
{ MODKEY, GDK_l, navigate, { .i = +1 }, BROWSER }, { 0, GDK_Escape, stop, { 0 } },
{ MODKEY, GDK_h, navigate, { .i = -1 }, BROWSER }, { MODKEY, GDK_o, source, { 0 } },
{ MODKEY, GDK_j, scroll, { .i = +1 }, BROWSER }, { MODKEY, GDK_g, spawn, SETPROP("_SURF_URI") },
{ MODKEY, GDK_k, scroll, { .i = -1 }, BROWSER }, { MODKEY, GDK_slash, spawn, SETPROP("_SURF_FIND") },
{ 0, GDK_Escape, stop, { 0 }, BROWSER }, { MODKEY, GDK_n, find, { .b = TRUE } },
{ MODKEY, GDK_o, source, { 0 }, BROWSER }, { MODKEY|GDK_SHIFT_MASK,GDK_n, find, { .b = FALSE } },
{ MODKEY, GDK_n, searchtext, { .b = TRUE }, BROWSER|SEARCHBAR },
{ MODKEY|GDK_SHIFT_MASK,GDK_n, searchtext, { .b = FALSE }, BROWSER|SEARCHBAR },
{ 0, GDK_Return, searchtext, { .b = TRUE }, SEARCHBAR },
{ GDK_SHIFT_MASK, GDK_Return, searchtext, { .b = FALSE }, SEARCHBAR },
{ 0, GDK_Return, loaduri, { .v = NULL }, URLBAR },
{ 0, GDK_Return, hideurl, { 0 }, URLBAR },
}; };
static Item items[] = {
{ "Back", navigate, { .i = -1 } },
{ "Forward", navigate, { .i = +1 } },
{ "New Window", newwindow, { .v = NULL } },
{ "Reload", reload, { .b = FALSE } },
{ "Stop", stop, { 0 } },
{ "Paste URI", clipboard, { .b = TRUE } },
{ "Copy URI", clipboard, { .b = FALSE } },
{ "Download", download, { 0 } },
};
+3 -5
View File
@@ -1,5 +1,5 @@
# surf version # surf version
VERSION = 0.1.1 VERSION = 0.3
# Customize below to fit your system # Customize below to fit your system
@@ -17,10 +17,8 @@ LIBS = -L/usr/lib -lc ${GTKLIB} -lgthread-2.0
# flags # flags
CPPFLAGS = -DVERSION=\"${VERSION}\" CPPFLAGS = -DVERSION=\"${VERSION}\"
#CFLAGS = -std=c99 -pedantic -Wall -Os ${INCS} ${CPPFLAGS} CFLAGS = -std=c99 -pedantic -Wall -Os ${INCS} ${CPPFLAGS}
CFLAGS = -std=c99 -pedantic -Wall -Werror -O0 ${INCS} ${CPPFLAGS} LDFLAGS = -s ${LIBS}
#LDFLAGS = -s ${LIBS}
LDFLAGS = ${LIBS}
# Solaris # Solaris
#CFLAGS = -fast ${INCS} -DVERSION=\"${VERSION}\" #CFLAGS = -fast ${INCS} -DVERSION=\"${VERSION}\"
+21
View File
@@ -33,6 +33,21 @@ Walks back the history.
.B Ctrl\-l .B Ctrl\-l
Walks forward the history. Walks forward the history.
.TP .TP
.B Ctrl\-k
Scrolls page upwards.
.TP
.B Ctrl\-j
Scrolls page downwards.
.TP
.B Ctrl\-Shift\-k
Zooms page in.
.TP
.B Ctrl\-Shift\-j
Zooms page out
.TP
.B Ctrl\-Shift\-i
Resets Zoom
.TP
.B Ctrl\-/ .B Ctrl\-/
Opens the search-bar. Opens the search-bar.
.TP .TP
@@ -42,6 +57,9 @@ Opens the URL-bar.
.B Ctrl\-p .B Ctrl\-p
Loads URI from primary selection. Loads URI from primary selection.
.TP .TP
.B Ctrl\-Shift\-p
Calls Printpage Dialog.
.TP
.B Ctrl\-r .B Ctrl\-r
Reloads the website. Reloads the website.
.TP .TP
@@ -50,6 +68,9 @@ Reloads the website without using cache.
.TP .TP
.B Ctrl\-y .B Ctrl\-y
Copies current URI to primary selection. Copies current URI to primary selection.
.TP
.B Ctrl\-o
show the sourcecode of the current page.
.SH SEE ALSO .SH SEE ALSO
.BR dmenu(1) .BR dmenu(1)
.BR xprop(1) .BR xprop(1)
+443 -332
View File
File diff suppressed because it is too large Load Diff