TiddlyWiki uses XPCOM on Firefox to access various libraries that were
originally intended for use by Firefox extensions. It turns out that
Firefox allows access to these APIs for local files if the user grants
access:
https://developer.mozilla.org/en/Code_snippets/File_I%2F%2FO
These APIs are not available in WebKit, and so I wouldn't expect them
to be available on Zetakey.
> Also, a friend of mine claimed that some browsers can use the "save
> as" function to save TW since they keep the current DOM for saving
> documents. Although even in this case saving throught "save as" can
> work not with the current TW (for instance, some things can be stored
> not in the DOM elements, I guess), after some tweaking it may work.
Firefox is the only browser I know that uses a snapshot of the current
DOM for file/save. You are right that with some tweaking TiddlyWiki
could be adjusted to allow allow saving in that way.
> So, what do you think (first, it's interesting to hear what do you
> know about technical details since I can have messed the things up)?
The best approach at the moment to getting TiddlyWiki saving locally
on a mobile device seems to be to create skinny wrappers around the
platform's native webview control. There are Android, iPhone and iPad
apps that exploit this technique to let you run and save any
TiddlyWiki document:
https://market.android.com/details?id=de.mgsimon.android.andtidwiki
http://itunes.apple.com/gb/app/twmobile/id381945222?mt=8
http://itunes.apple.com/gb/app/twedit/id409607956?mt=8
Cheers
Jeremy
--
Jeremy Ruston
mailto:jer...@osmosoft.com
http://www.tiddlywiki.com
A webview control is a component available on some mobile platforms
that lets programmers incorporate the functionality of a web browser
into their applications. The iPhone/iPad and Android both provide an
instance of WebKit for this purpose. I believe that Windows Mobile 5
has a Pocket Internet Explorer ActiveX control along the same lines.
The wrapper application is a native application (.net in the case of
windows mobile) that uses the webview control to host a TiddlyWiki
file. It needs some form of communication into the webview control in
order to take over the "save" functionality; as far as I know all the
controls allow this by letting hosts intercept specially constructed
links navigated within the browser.
>> FireFox is NOT Webkit-based
>
> Oops. Now I know this :) probably I misread something in Wikipedia.
>
>> then transcribed back into HTML syntax when the file is saved
>
> As I understand this can be handled by adding a "semi-save" function
> which would write the state from the store object into DOM, but as
> long
>
>> Firefox is the only browser [I know] that uses a snapshot of the current DOM for file/save
>
> is true this is of no use. And
>
>> character-set conversions, discarding of comments, collapsing of whitespace, etc
>
> makes also some problems, especially character-set conversions.
>
> One more question: what do you know guys about the Local Storage? I
> mean, should it be hidden by browser from manual access? Developers
> say that Zetakey implements Local Storage so I wonder if the work on
> handheld can be done in the following manner: I work with TW, and the
> alternations are kept in Local Storage. Than I copy my Local Storage
> content from handheld to computer, apply some saving engine there, et
> voila - here I have a TiddlyWiki, like as if I saved changes on the
> mobile device.
It's not possible to transfer local storage content between
browsers/computers. So, it would let you persist changes made to a
TiddlyWiki document, but those changes would be tied to that browser.
It's more like a cache than a real storage mechanism.
Cheers
Jeremy
>
> --
> You received this message because you are subscribed to the Google Groups "TiddlyWikiDev" group.
> To post to this group, send email to tiddly...@googlegroups.com.
> To unsubscribe from this group, send email to tiddlywikide...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/tiddlywikidev?hl=en.