Hi Jaap, hi all.
Looking at the video, it probably looks nice to just skip the
QuickNote dialog here. Having the popup from firefox feels more
Yes, And i could provide the notebook chooser here more easely.
Not really. Expected behavior is that if you do not provide a basename
and "new_page" is set, the basename is based on the first line of the
ok. Misunderstood so.
Will be easy to provide the same commandline args as for the quicknote
dialog, without the additional interface.
Also contemplating having much more commandline options for zim, so it
is easier to interface with other applications. Probable a "--import"
to add a new page and "--append" to add to an existing page would be
logical commandline options. Then there would be no need to use the
quicknote plugin at all if you don't want the dialog.
It would certainly be clearer to implement a bookmarking behavior
calling directly Zim, without quicknote plugin. As a use case : i put a
lot of links in a zim namespace with subpages, i.e :
The 'marks' feature of the firefox plugin is for me a way to store
links in those pages in the 'bookmarks' namespace, links that are not
always relevant to keep in the Firefox bookmarks. So, at the end, i
want my plugin to be able to do the following :
- User choose the notebook to target.
- User choose the main namespace ('bookmarks') where to store the
- Click on a toolbar button ; a dialog panel allows me to define link +
comment that will be written into a defined page into that namespace.
- Call zim (or zim plugin) to append that text into the defined page
(the page is created if it not exists).
I could do that without calling zim, dealing with the filesystem
myself. I can :
(a) read ~/.config/notebooks.list to retrieve notebooks name + uri and
(b) use Firefox File API to write into an existing document in user's
home (i.e. writing into a zim notebook).
(a) is already done, as i want to choose which notebook to target, but
i hesitate to implement (b), because it could be hazardous :
* How will react Zim if another app edits or creates pages on an opened
notebook ? User will have to launch a 'update index' each time ?!
* If addon can create a notebook page, it will have to maintain the way
Zim is writing headers.
So, I think all the (b) stuff (writing content into notebook) should be
Zim prerogative. As you have mention it, it could be something like
'import' and 'append' options :
(1) Create or import a new page.
zim --import [OPTIONS] NOTEBOOK PAGE
uri=URI Uri of a page to import / create (if not
provided, creates an empty page)
(2) Append a content to a notebook page.
zim --append [OPTIONS] NOTEBOOK PAGE
text=TEXT Text to append
Mailing list: https://launchpad.net/~zim-wiki
Post to : email@example.com
Unsubscribe : https://launchpad.net/~zim-wiki
More help : https://help.launchpad.net/ListHelp