Can we step back a bit? What's your motivation behind this plugin? If
your goal is to fix bad data from site translators, then the site
translators should just be fixed. If your goal is to allow tags in the
UI to be entered with a delimiter, then either the plugin should enable
that or you should submit a patch to Zotero core that does so. Fixing
this post-save isn't a very good solution.
We don't have callbacks like that, so that's not really an option.
But to step back yet again, why do you want to be able to enter tags
with a delimiter? Why does the delimiter have to be a semicolon and not,
say, a newline, so that it split up multiple tags pasted in (which seems
like the only reason this should be necessary)?
Will S Mon, Oct 24, 2011 at 3:17 PM
> With a newline, you would have to type out the tags in a separate
> window and then copy them rather than type them into the little tag
> entry box and copy them,
That would WFM: I'd rather do the tags in an editor and then cut'n'paste, since I also
> like to put a lot of descriptive tags on the entries in
> my library and there is a lot overlap between entries so it's
> annoying to type them all in over and over. I'd also like to add a
> way to grab all of the tags on an item (to the clipboard if
> possible) so that they can be pasted to another item.
+1
> Part of the annoyance with adding the tags is that there is a
> half-second to second pause after I hit enter each time I add a tag
> to an entry.
Ditto.
FWIW, Tom Roche <Tom_...@pobox.com>
So I'd recommend submitting a patch that will use newlines as delimiters
in tags pasted into the right-hand pane.
> I'd also like to add
> a way to grab all of the tags on an item (to the clipboard if
> possible) so that they can be pasted to another item. I think that
> this should not be too hard to do with a plugin.
This could be done, but we'd need a UI for it. (The nice part of the
above change is that it could be done without any UI changes.)
> Part of the
> annoyance with adding the tags is that there is a half-second to
> second pause after I hit enter each time I add a tag to an entry. I
> think that this is because my library is pretty big. It'd still be
> good to be able to add delimited tags even if I didn't have this pause.
Right, I figured that was part of the motivation, but that alone isn't
reason enough for a delimiter (and is the reason I'm concerned only with
handling copy/paste). That just means tag adding needs to be optimized
further. In the meantime, note that you may get faster adds with the tag
selector closed. 3.0b might also speed this up over 2.1.10.
https://github.com/willsALMANJ/zotero
To enter multiple tags, you just paste a string of tags separated by
newlines (\n, \r\n, or \r) and they are all added to the item.
Entering multiple creators is similar but a little more complicated.
You can enter multiple creators by pasting a string of creator names
separated by newlines (\n, \r\n, or \r) into the author name field
(either the name field in full name mode or the last name in "last
name, first name" mode). Creator names can either be entered as a
single name or as the last name and the first name separated by \t
(tab).
There is one other subtle difference between entering tags and
creators. For tags, if you select an existing tag and paste the new
tags into the textbox, that existing tag is overwritten by the newly
entered tags. For creators, if you select an existing creator and
paste a list of creators into the textbox, the new creators are all
inserted into the creator list before that selected creator and no
creators are overwritten. This difference between tags and creators
came about because tags are always resorted to be alphabetical whereas
creator lists have a definite order.
If anyone has an opinion about any of the above, could you please let
me know? I will submit a pull request soon, but I imagine it won't
get looked at right away, so I would like to make sure that the most
desirable version of the patch is submitted the first time.
Also, I created a small plugin for Zotero that adds two options to the
popup menu that appears when you right-click on an item in Zotero:
"Copy creators to clipboard" and "Copy tags to clipboard". Selecting
these items copies the creators/tags of the selected item to the
clipboard in the appropriate format for pasting into another item.
The plugin can be downloaded here:
https://github.com/willsALMANJ/Zutilo