[tomboy-list] Note Attachments
dylanmccall at gmail.com
Fri Mar 28 00:09:27 PDT 2008
Regarding copying vs. linking vs. moving, I believe the drag and drop
information handles this already. You can set action to something along
the lines of gdk.action_move, gdk.action_copy, gdk.action_link, etc.
(thinking in Python since it's the only one I've worked on dnd stuff
With that in mind, I think the best action here would be for Tomboy to
handle dropped files based on that, although I must admit to not being
very well versed on the depths of that stuff. Otherwise, unexpected
behaviours could occur...
Granted, some actions likely would not fit well with syncing, but many
programs foolishly ignore that thing altogether.
On Thu, 2008-03-27 at 21:33 -0400, Jeff Tickle wrote:
> Hey everyone,
> I'd like to get some comments on Note Attachments. This has been in
> the pipe for a little while, and will be pretty crucial for a 1.0
> release, as we discussed on IRC today.
> For the uninitiated, an attachment is a file that is attached to a
> note. The best way I can explain is with use cases:
> If you drag an image onto a note, the image would be copied into
> ~/.tomboy, and if you synced the note using Conduit, the image would
> go with the note. Any edits to the original image would not be
> reflected in the note, unless you replaced the old attachment with the
> new image.
> If you use the Sketching plugin to draw on a note, right now, nothing
> is saved. With a standard Attachments API, Sketching could create a
> file in ~/.Tomboy that holds the binary data representing the sketch.
> This would be synced with the note. Any changes WOULD be reflected in
> the note, because edits happen *within* Tomboy.
> Any addin would be able to create Attachments. Right now, the primary
> focus is on images, but I'd like to make it extensible to fit any
> needs that might come along. I'm not really thinking so much about
> attaching things like documents (.odt or whatever), rather those would
> be linked to within a note and synced separately using Conduit,
> outside of Tomboy. I talked to Sandy about this in IRC and he agrees
> that it would be a nightmare to track changes to the document, and
> that this probably isn't a major use-case anyway.
> Here's what I've come up with for the HOW to implement it:
> Each note that has an attachment gets a ~/.tomboy/[GUID]/ directory.
> Any attachments could be stored in here, either with their original
> names (in the case of an attached image) or something that makes sense
> to the responsible add-in (in the case of a Sketching).
> The note itself is still stored in ~/.tomboy/[GUID].note, so we don't
> break compatibility as bad.
> A NoteAttachment class, which would contain information about
> individual attachments. I think this would really be an extension of
> the NoteTag class, any thoughts here? The main reason I think it
> would need to be its own class is so that any syncing back-end (which
> I honestly know little about) would have some abstract methods to call
> to do any packaging necessary for syncing the attachments. There may
> be more reasons for or against a NoteAttachment class.
> Any thoughts? I haven't written any code yet, but this is pretty much
> what I have to start from right now.
> Tomboy-list mailing list
> Tomboy-list at lists.beatniksoftware.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.beatniksoftware.com/pipermail/tomboy-list-beatniksoftware.com/attachments/20080328/ebcd1f8f/attachment.pgp
More information about the Tomboy-list