annotate base/XmlExportable.h @ 115:90ade4fa63be

* Fix serious failure to reload "imported" (i.e. all non-derived non-main) models from .sv file * Give a short playback duration to notes with formal duration of 0 or 1 * Show crosshairs on spectrogram even when there is another layer on top (if it isn't opaque) * Always paste to the same time in the layer as the cut/copy was from, rather than to the playback pointer -- less flexible, but more predictable and less annoying. We probably need a way to get the old behaviour if pasting from somewhere else in the future (e.g. from a text file), but we can't do that yet anyway * Use a compound operation for dragging and resizing selections, so as to ensure a single undo operation works * Use a note model as the target for feature extraction plugins that output variable samplerate data with more than one value per feature * Avoid possible crashes in cut/paste if a layer proves to have no model
author Chris Cannam
date Thu, 11 May 2006 11:35:46 +0000
parents ea730e3f9ace
children 0f37e92e1782
rev   line source
Chris@49 1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
Chris@3 2
Chris@3 3 /*
Chris@52 4 Sonic Visualiser
Chris@52 5 An audio file viewer and annotation editor.
Chris@52 6 Centre for Digital Music, Queen Mary, University of London.
Chris@52 7 This file copyright 2006 Chris Cannam.
Chris@3 8
Chris@52 9 This program is free software; you can redistribute it and/or
Chris@52 10 modify it under the terms of the GNU General Public License as
Chris@52 11 published by the Free Software Foundation; either version 2 of the
Chris@52 12 License, or (at your option) any later version. See the file
Chris@52 13 COPYING included with this distribution for more information.
Chris@3 14 */
Chris@3 15
Chris@3 16 #ifndef _XML_EXPORTABLE_H_
Chris@3 17 #define _XML_EXPORTABLE_H_
Chris@3 18
Chris@3 19 #include <QString>
Chris@3 20 #include <QColor>
Chris@3 21
Chris@3 22 class XmlExportable
Chris@3 23 {
Chris@3 24 public:
Chris@27 25 virtual ~XmlExportable() { }
Chris@27 26
Chris@3 27 virtual QString toXmlString(QString indent = "",
Chris@3 28 QString extraAttributes = "") const = 0;
Chris@3 29
Chris@3 30 static QString encodeEntities(QString);
Chris@3 31
Chris@3 32 static QString encodeColour(QColor);
Chris@4 33
Chris@85 34 static int getObjectExportId(const void *); // thread-safe
Chris@3 35 };
Chris@3 36
Chris@3 37 #endif