diff options
author | Peter Hofmann <scm@uninformativ.de> | 2014-06-14 12:59:11 +0200 |
---|---|---|
committer | Peter Hofmann <scm@uninformativ.de> | 2014-06-14 13:00:04 +0200 |
commit | 61013e58b980b940e0434250318faa6ed084892b (patch) | |
tree | 44c1ee3cdc7bff02b9e52a50c6cca2e53446b3a4 | |
parent | b3af9d52dcc487da95410a0db4f90851b526621a (diff) | |
download | lariza-61013e58b980b940e0434250318faa6ed084892b.tar.gz |
Go back to Gtk2 for flash support
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | README | 5 | ||||
-rw-r--r-- | sn.c | 8 |
3 files changed, 10 insertions, 5 deletions
@@ -3,7 +3,7 @@ CFLAGS += -Wall -Wextra -O3 sn: sn.c $(CC) $(CFLAGS) $(LDFLAGS) \ -o $@ $< \ - `pkg-config --cflags --libs gtk+-3.0 webkitgtk-3.0` + `pkg-config --cflags --libs gtk+-2.0 webkit-1.0` clean: rm -f sn @@ -1,7 +1,7 @@ sn - sonst nix ============== -This is a minimalistic web browser using Gtk3 and WebKit. "Sonst nix" is +This is a minimalistic web browser using Gtk2 and WebKit. "Sonst nix" is german and translates roughly to "nothing else". sn is simple and meant to stay simple. @@ -10,6 +10,7 @@ Features: - A WebKit viewport - Global content zoom - Pluggability into suckless' tabbed + - Support for Flash and Java Planned features: @@ -36,4 +37,4 @@ Literature API references: - http://webkitgtk.org/reference/webkitgtk/stable/index.html - - https://developer.gnome.org/gtk3/stable/index.html + - https://developer.gnome.org/gtk2/stable/index.html @@ -2,7 +2,7 @@ #include <stdlib.h> #include <gtk/gtk.h> -#include <gtk/gtkx.h> +#include <gdk/gdkx.h> #include <webkit/webkit.h> @@ -113,9 +113,13 @@ sn_new_client(const gchar *uri) c->win = gtk_plug_new(embed); } + /* When using Gtk2, sn only shows a white area when run in suckless' + * tabbed. It appears we need to set a default window size for this + * to work. This is not needed when using Gtk3. */ + gtk_window_set_default_size(GTK_WINDOW(c->win), 1024, 768); + g_signal_connect(G_OBJECT(c->win), "destroy", G_CALLBACK(sn_destroy_client), c); - gtk_window_set_has_resize_grip(GTK_WINDOW(c->win), FALSE); gtk_window_set_title(GTK_WINDOW(c->win), "sn"); c->web_view = webkit_web_view_new(); |