[sword-devel] HTML5 File API and SWORD modules

Troy A. Griffitts scribe at crosswire.org
Tue May 7 08:51:42 MST 2013

If it's interesting for your efforts, my plan for extending Bishop is to make the C++ engine available via Apache Cordova. This is more attractive now that Cordova has expanded beyond a exclusively a mobile platform.

Stephan <info at tetzels.de> wrote:

>Sorry for reopen this thread...
>After reading sword module files with server-side Javascript 
>(https://github.com/zefanja/node-swordjs) I was able to read the ztext 
>modules in the browser. I've used the FileAPI to read a *.bzz file (or 
>better only a part of it) and decompress the ArrayBuffer/Uint8Array
>zlib.js (https://github.com/imaya/zlib.js) to get uncompressed data.
>I don't like the idea of rewriting everything from scratch, but 
>currently there is no way to use the c++ code for a javascript 
>implentation. I've tried to port the SWFilter part with Emscripten but 
>without success. I think it is possible to port the simple filters that
>only have a processText() function, but the OSIS filters have to many 
>dependencies (like SWModule, SWMgr, VerseKey, ...).
>Another problem is (like mentioned before) how to store the module
>in a browser. There is the FileSystem API, but it is Chrome-only. 
>IndexedDB is implemented in Firefox, Chrome and IE10, but you can store
>file blobs only in Firefox and not in the other browsers. There is a 
>FileSystem API wrapper for Firefox 
>(https://github.com/ebidel/idb.filesystem.js) but with some
>What do you think about a HTML5/JS implemantion in general? How can we 
>use as much as possible code of the current library so that we don't 
>have to rewrite everything from scratch?
>I will uploaded my code as soon as I cleaned it up.
>sword-devel mailing list: sword-devel at crosswire.org
>Instructions to unsubscribe/change your settings at above page

Sent from my Android phone with K-9 Mail. Please excuse my brevity.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20130507/ccbd7cf0/attachment.html>

More information about the sword-devel mailing list