Peter Hofmann [Sat, 8 Apr 2017 10:23:52 +0000 (12:23 +0200)]
README: Remove note about Flash and Java
This was relevant some years ago. Today, Flash is dying quickly and I
don't even care about Java anymore. On top of that, support for these
two things never was a feature of lariza but of WebKit.
Peter Hofmann [Sat, 11 Mar 2017 16:32:22 +0000 (17:32 +0100)]
Call ensure_uri_scheme() before sending message to socket
The main process and the process that sends the message might have
different working directories. As a result, the main process might not
be able to detect "foo.html" as a file when called as "lariza foo.html".
It would appear that it's illegal to call gtk_level_bar_set_value() with
a value of 0. Or, and that's just as likely, I don't understand how a
GtkLevelBar is supposed to work. You don't even have to call
gtk_level_bar_set_value() at all, since 0 is the default value of such a
bar.
All of this doesn't really matter, though, since GtkEntry has a built-in
progress bar that we can use.
Peter Hofmann [Fri, 27 Jan 2017 17:15:30 +0000 (18:15 +0100)]
Change search prefix to ":/"
I want to change ensure_uri_scheme() so it automatically adds "file://"
if we're dealing with a valid local file path. However, this clashes
with "/" as a search prefix.
Peter Hofmann [Sat, 30 Jul 2016 06:24:52 +0000 (08:24 +0200)]
Look for web extensions in ~/.config/lariza/web_extensions
~/.local/share isn't really an appropriate place because it's meant to
contain "data", possibly written by the application.
Usually, lariza's web extensions (.so files) are not placed in your home
directory anyway. Instead, they are installed somewhere in /usr. The
home directory only contains symlinks. So, in a way, those symlinks can
be considered "configuration items". Hence, ~/.config is where they
should live.
Peter Hofmann [Sat, 29 Aug 2015 14:23:03 +0000 (16:23 +0200)]
Retab
For years, I've been using a tab size of 4. This, however, conflicts
with the idea of limiting the line length: You can only limit the line
length in a meaningful way if you're using the default tab size of 8.
But 8 is a huge waste of space...
So let's just do this. Retab to 4 spaces and limit the line length to
about 80 characters.
Peter Hofmann [Sat, 29 Aug 2015 10:49:53 +0000 (12:49 +0200)]
GtkBox: Don't manually specify a padding
This might look good on my display, but on a display with a different
DPI value, it's probably garbage. Specifying space in pixels is
meaningless today.
Yes, this applies to the level bar and the window size as well. I have
not yet found a better way to control those, though.
Peter Hofmann [Mon, 5 Jan 2015 19:05:35 +0000 (20:05 +0100)]
Implement a simple certificate trust store
The WebKit1 version of lariza simply ignored certificate errors. I could
have turned off validation in WebKit2 as well, but I wanted to try to do
it right. :-)
Peter Hofmann [Thu, 1 Jan 2015 08:31:42 +0000 (09:31 +0100)]
The WebKit2 port is "read for use"
Addressing the issues mentioned in the README:
- I'm using it every day and I haven't found any more bugs (in lariza).
- "View source" mode is still not implemented. However, I don't see any
other way than re-downloading the current weg page and showing the
results in some to-be-written widget that displays text (+ HTML syntax
highlighting + maybe other stuff). That's quite a lot of overhead for
a rarely used feature, so I decided to drop it.
- That "annoying border around the WebView widget" is related to my gtk
theme (upstream "Raleigh"). Adwaita, the current GTK+ 3 default theme,
does not have that border.
tl;dr: The WebKit2 port is as ready as it can get and it's "more bug
free" than the WebKit1 version.
Peter Hofmann [Sun, 14 Dec 2014 13:15:04 +0000 (14:15 +0100)]
Quickfix for crashes when downloads start
Every new window added download_handle_start() as a signal handler to
the global WebKitWebContext. This is wrong anway, because the signal
handler sets the destination path; this should not be done multiple
times.
The actual crash happened when a window was closed and *then* a download
started. The window's signal handler still existed with a pointer to the
window's "struct Client". This struct, however, is now free'd and
invalid. Hence the crash.
To get rid of the crashes, only add the signal handler once. Sad thing
is, this makes the "status" level bar useless: It would only work for
the very first window ever created -- if it still existed. If that
window has been closed as well, we would still crash. Thus, remove
"status" completely.
We'll have to find a new way to announce the start of a download.
Peter Hofmann [Sat, 9 Aug 2014 16:25:30 +0000 (18:25 +0200)]
Minor improvement to changed_download_progress()
I checked WebKit's source code: webkit_download_get_destination_uri()
never returns NULL in lariza. It's because we set the destination URI in
the signal handler for the download request.
If g_filename_from_uri() really returned NULL for some reason, then it'd
be just plain wrong to announce the "suggested file name", because we
might be saving the download ... somewhere else. I doubt this function
ever returns NULL in lariza, though, but you never know.
So, now, the download manager will correctly show the URI if the
destination URI is "unknown".
Peter Hofmann [Fri, 4 Jul 2014 15:19:36 +0000 (17:19 +0200)]
Mod1 + d closes the download manager
While Mod1 + q is consistent with the main window, it also poses the
risk of accidentally closing the main window. With Mod1 + d it's more
like a "toggle the download manager".