13 #ifndef MAGICSMOKE_TICKETEDIT_H
14 #define MAGICSMOKE_TICKETEDIT_H
16 #include <QMainWindow>
18 #include <QItemDelegate>
49 void parseTemplate(QByteArray);
65 void loadExampleData();
67 void saveTemplate(QFile&);
69 void saveXmlPart(QIODevice&);
80 QWidget *
createEditor(QWidget *,
const QStyleOptionViewItem &,
81 const QModelIndex &)
const;
84 const QModelIndex &)
const ;
86 const QModelIndex &)
const {editor->setGeometry(option.rect);}
void openFile()
shows a file open dialog and then opens the selected file
Definition: ticketedit.cpp:425
void updateEditorGeometry(QWidget *editor, const QStyleOptionViewItem &option, const QModelIndex &) const
Definition: ticketedit.h:85
QWidget * createEditor(QWidget *, const QStyleOptionViewItem &, const QModelIndex &) const
Definition: ticketedit.cpp:536
void setModelData(QWidget *, QAbstractItemModel *, const QModelIndex &) const
Definition: ticketedit.cpp:640
An editor for ticket templates.
Definition: ticketedit.h:25
void loadFile(QString)
loads a template file, this is a helper for openFile and download
Definition: ticketedit.cpp:290
Definition: ticketedit.h:73
void setEditorData(QWidget *, const QModelIndex &) const
Definition: ticketedit.cpp:573
MTicketEditor(QWidget *parent=0, Qt::WindowFlags f=0)
instantiates the editor
Definition: ticketedit.cpp:149
void saveFileAs()
asks for a new file name
Definition: ticketedit.cpp:452
MTELabelDelegate(MTicketEditor *parent)
Definition: ticketedit.h:78
void saveFile()
saves the file - if it is local, otherwise calls saveFileAs
Definition: ticketedit.cpp:435