Error Viewer extension



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello, List,

As it's nearing completion and It's Cool, I'd like to present to the
list the first original extension to grace Epiphany: the Error Viewer
extension.

The Error Viewer extension started off as a "Javascript Console" copy
from Galeon, but I took out the annoying, complicated and/or unimportant
bits and then there was nothing left, so I ended up putting in
replacement goodness. The data is presented in a GtkTreeView with pretty
little icons and very little cruft.

Next I figured this was boring. Every browser has a javascript error
console (with one obvious monopoly-driven exception, as usual). So I
added HTML validation. And I've yet to discover a tool (besides nsgmls)
that does HTML validation locally. Thus, this extension is original,
not-available-anywhere-else... and downright awesome.

The extension is available in GNOME CVS, module "epiphany-extensions."
Your Epiphany should be a somewhat current CVS version. Beyond that,
you'll need the OpenSP development headers and libraries -- libosp-dev
on Debian. To keep yourself from connecting to w3 anyway to fetch the
DTD's, you'll want local copies of the DTD's in your SGML catalogs (on
Debian, apt-get install w3c-dtd-xhtml, and I think regular HTML DTD's
will be installed along with OpenSP's libraries). If you don't have the
OpenSP headers installed, the Error Viewer will still compile and work
(at least, it *should*) but you won't have HTML Validation support.

How to use it:
- - Browse to the document you'd like to validate.
- - Choose the Tools menu (it shows up when the extension is installed, if
you've got a new enough Epiphany)
- - Choose "Validate."

What it does:
The Error Viewer does some very basic checks on the doctype and then
passes control over to OpenSP. validator.w3.org uses OpenSP too, so this
Error Viewer shows the same messages as the Validator does. I don't know
why I'd bother going to the Validator now that I can do it locally.

Caveats:
There are icky bugs I haven't solved yet. Ever since I changed the
validation to its own thread (it takes about a second), I can't remove
items from the GtkListStore without causing havoc -- so the list can
grow to infinite length unless you Clear it. Also, OpenSP seems to have
trouble returning any string longer than 200 characters, so you might
see a bit of truncation of some messages (this shouldn't matter that
much if you're used to validator.w3.org, since you already know what the
messages mean). The text can't be selected nicely, but that's a GTK bug.

Anyway, if anyone likes using Epiphany from CVS and is curious about the
new extension, I encourage him or her to try it out. If anyone has
questions or comments (or bug reports!) please let me hear them.

- --
Adam Hooper
adamh densi com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFAFvdBD7ySSW2J9egRAqjSAKCuk4kKroVMbWGzx2HkN68ZvI2ZSwCglSOr
e6kyMCyjb6J4GejGiHJUDPA=
=CeHT
-----END PGP SIGNATURE-----



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]