Hi everyone,

I'm trying to build an error console for Squiggle, something like what
firefox has, as part of my GSoC project. Currently, error handling is
quite basic and any exception thrown is displayed in a dialog-box with
the option to see the detailed stack-trace. However, under-certain
circumstances, it may be possible to recover from the error, log it
and continue execution. Or, if there is an error in the SVG document
being parsed, it may make more sense to simply issue a warning, ignore
the faulty element and continue with the rest of the document.
Comments in the document could be displayed as messages (which would
show the extent of the document that has been parsed and could be used
during debugging). Displaying errors and warnings in a separate,
normally-hidden dialog would make Squiggle more tolerant towards
markup errors and would be a useful feature to have.

I looked up the source code (Batik-1.7 source snapshot) and found that
the exceptions are displayed using the
org.apache.batik.util.gui.JErrorPane class. It is not possible to
simply replace this class with another as the information passed to it
is insufficient. For parsing errors, the console would also need the
Document being parsed. The console would then show a hyperlink which
would open a window to edit the document on being clicked.

Also, in order to tolerate errors in the document, they must be
handled as close to the place where they are being parsed as possible
i.e. we cannot throw exceptions which are propagated too high-up where
the whole process is simply aborted. To achieve this, I believe one
will have to look at the parsing process and for each element, guess
possible errors (incorrect or missing values), assume default values
if it happens and continue to the next token.

Any help/ideas on this would be highly appreciated. I've also created
a simple GUI for the error console. A screen-shot is attached.

Cameron: How do I submit code for the project? Do you have a separate
branch for this where I can directly commit, or should I submit
patches to you for review?

Thanks!

Jasleen

<<attachment: error-console.png>>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to