author | insilmaril |
Wed Jul 13 10:22:14 2005 +0000 (2005-07-13) | |
changeset 127 | ebfc893dde31 |
parent 95 | f688a9913724 |
child 160 | 72cc3873306a |
permissions | -rw-r--r-- |
insilmaril@0 | 1 |
#ifndef MAINWINDOW_H |
insilmaril@0 | 2 |
#define MAINWINDOW_H |
insilmaril@0 | 3 |
|
insilmaril@0 | 4 |
#include <qpopupmenu.h> |
insilmaril@0 | 5 |
#include <qmainwindow.h> |
insilmaril@0 | 6 |
#include <qtextedit.h> |
insilmaril@0 | 7 |
#include <qintdict.h> |
insilmaril@0 | 8 |
#include <qcanvas.h> |
insilmaril@0 | 9 |
#include <qlineedit.h> |
insilmaril@0 | 10 |
#include <qaction.h> |
insilmaril@0 | 11 |
#include <qcursor.h> |
insilmaril@0 | 12 |
#include <qtabwidget.h> |
insilmaril@0 | 13 |
#include <qmap.h> |
insilmaril@0 | 14 |
|
insilmaril@0 | 15 |
#include "xml.h" |
insilmaril@0 | 16 |
#include "texteditor.h" |
insilmaril@0 | 17 |
#include "mapeditor.h" |
insilmaril@0 | 18 |
#include "findwindow.h" |
insilmaril@0 | 19 |
|
insilmaril@0 | 20 |
class Main : public QMainWindow |
insilmaril@0 | 21 |
{ |
insilmaril@0 | 22 |
Q_OBJECT |
insilmaril@0 | 23 |
|
insilmaril@0 | 24 |
public: |
insilmaril@0 | 25 |
Main(QWidget* parent=0, const char* name=0, WFlags f=0); |
insilmaril@0 | 26 |
~Main(); |
insilmaril@0 | 27 |
void loadCmdLine(); |
insilmaril@0 | 28 |
void statusMessage (const QString &); |
insilmaril@0 | 29 |
|
insilmaril@0 | 30 |
public slots: |
insilmaril@0 | 31 |
void fileNew(); |
insilmaril@0 | 32 |
|
insilmaril@0 | 33 |
protected: |
insilmaril@0 | 34 |
void closeEvent( QCloseEvent* ); |
insilmaril@0 | 35 |
|
insilmaril@0 | 36 |
private: |
insilmaril@0 | 37 |
void setupFileActions(); |
insilmaril@0 | 38 |
void setupEditActions(); |
insilmaril@0 | 39 |
void setupFormatActions(); |
insilmaril@0 | 40 |
void setupViewActions(); |
insilmaril@89 | 41 |
void setupModeActions(); |
insilmaril@0 | 42 |
void setupWindowActions(); |
insilmaril@0 | 43 |
void setupFlagActions(); |
insilmaril@0 | 44 |
void setupSettingsActions(); |
insilmaril@0 | 45 |
void setupTestActions(); |
insilmaril@0 | 46 |
void setupHelpActions(); |
insilmaril@0 | 47 |
void setupContextMenus(); |
insilmaril@0 | 48 |
void setupLastMapsMenu(); |
insilmaril@0 | 49 |
void hideEvent (QHideEvent * ); |
insilmaril@0 | 50 |
void showEvent (QShowEvent * ); |
insilmaril@0 | 51 |
bool reallyWriteDirectory(const QString&); |
insilmaril@0 | 52 |
QString browseDirectory(const QString&); |
insilmaril@0 | 53 |
MapEditor* currentMapEditor() const; |
insilmaril@0 | 54 |
|
insilmaril@0 | 55 |
private slots: |
insilmaril@0 | 56 |
void newView(); |
insilmaril@0 | 57 |
void editorChanged(QWidget*); |
insilmaril@0 | 58 |
|
insilmaril@0 | 59 |
void fileLoad(QString ,const LoadMode &); |
insilmaril@0 | 60 |
void fileLoad(const LoadMode &); |
insilmaril@0 | 61 |
void fileLoad(); |
insilmaril@0 | 62 |
void fileLoadLast(int); |
insilmaril@0 | 63 |
void fileSave(const SaveMode & ); |
insilmaril@0 | 64 |
void fileSave(); |
insilmaril@0 | 65 |
void fileSaveAs(const SaveMode &); |
insilmaril@0 | 66 |
void fileSaveAs(); |
insilmaril@0 | 67 |
void fileImportDir(); |
insilmaril@0 | 68 |
void fileExportXML(); |
insilmaril@0 | 69 |
void fileExportHTML(); |
insilmaril@0 | 70 |
void fileExportXHTML(); |
insilmaril@0 | 71 |
void fileExportImage(int); |
insilmaril@0 | 72 |
void fileExportASCII(); |
insilmaril@0 | 73 |
void fileCloseMap(); |
insilmaril@0 | 74 |
void filePrint(); |
insilmaril@0 | 75 |
void fileExitVYM(); |
insilmaril@0 | 76 |
|
insilmaril@0 | 77 |
void editUndo(); |
insilmaril@0 | 78 |
void editRedo(); |
insilmaril@0 | 79 |
void editCopy(); |
insilmaril@0 | 80 |
void editPaste(); |
insilmaril@0 | 81 |
void editCut(); |
insilmaril@0 | 82 |
void editOpenFindWindow(); |
insilmaril@0 | 83 |
void editFind(QString); |
insilmaril@0 | 84 |
void editFindChanged(); |
insilmaril@0 | 85 |
public slots: |
insilmaril@0 | 86 |
void editOpenURL(); |
insilmaril@0 | 87 |
private slots: |
insilmaril@0 | 88 |
void editURL(); |
insilmaril@0 | 89 |
void editHeading2URL(); |
insilmaril@0 | 90 |
void editBugzilla2URL(); |
insilmaril@0 | 91 |
void editVymLink(); |
insilmaril@0 | 92 |
public slots: |
insilmaril@0 | 93 |
void editOpenVymLink(); |
insilmaril@0 | 94 |
private slots: |
insilmaril@0 | 95 |
void editDeleteVymLink(); |
insilmaril@0 | 96 |
void editMapInfo(); |
insilmaril@0 | 97 |
void editMoveUp(); |
insilmaril@0 | 98 |
void editMoveDown(); |
insilmaril@0 | 99 |
void editToggleScroll(); |
insilmaril@0 | 100 |
void editUnScrollAll(); |
insilmaril@0 | 101 |
void editHeading(); |
insilmaril@0 | 102 |
void editNewBranch(); |
insilmaril@98 | 103 |
void editNewBranchHere(); |
insilmaril@0 | 104 |
void editNewBranchAbove(); |
insilmaril@0 | 105 |
void editNewBranchBelow(); |
insilmaril@0 | 106 |
void editImportAdd(); |
insilmaril@0 | 107 |
void editImportReplace(); |
insilmaril@0 | 108 |
void editSaveBranch(); |
insilmaril@98 | 109 |
void editRemoveBranchHere(); |
insilmaril@98 | 110 |
void editRemoveChilds(); |
insilmaril@0 | 111 |
void editDeleteSelection(); |
insilmaril@0 | 112 |
void editUpperBranch(); |
insilmaril@0 | 113 |
void editLowerBranch(); |
insilmaril@0 | 114 |
void editLeftBranch(); |
insilmaril@0 | 115 |
void editRightBranch(); |
insilmaril@0 | 116 |
void editFirstBranch(); |
insilmaril@0 | 117 |
void editLastBranch(); |
insilmaril@0 | 118 |
void editLoadImage(); |
insilmaril@0 | 119 |
void editSaveImage(int); |
insilmaril@0 | 120 |
void editToggleFloatExport(); |
insilmaril@95 | 121 |
void editFollowXLink (int); |
insilmaril@95 | 122 |
void editEditXLink (int); |
insilmaril@0 | 123 |
|
insilmaril@0 | 124 |
void formatSelectColor(); |
insilmaril@0 | 125 |
void formatPickColor(); |
insilmaril@0 | 126 |
void colorChanged(QColor); |
insilmaril@0 | 127 |
void formatColorItem(); |
insilmaril@0 | 128 |
void formatColorBranch(); |
insilmaril@0 | 129 |
void formatLinkStyleLine(); |
insilmaril@0 | 130 |
void formatLinkStyleParabel(); |
insilmaril@0 | 131 |
void formatLinkStylePolyLine(); |
insilmaril@0 | 132 |
void formatLinkStylePolyParabel(); |
insilmaril@0 | 133 |
void formatSelectBackColor(); |
insilmaril@0 | 134 |
void formatSelectLinkColor(); |
insilmaril@0 | 135 |
void formatToggleLinkColorHint(); |
insilmaril@0 | 136 |
void formatFrameNone(); |
insilmaril@0 | 137 |
void formatFrameRectangle(); |
insilmaril@0 | 138 |
|
insilmaril@0 | 139 |
void viewZoomReset(); |
insilmaril@0 | 140 |
void viewZoomIn(); |
insilmaril@0 | 141 |
void viewZoomOut(); |
insilmaril@0 | 142 |
|
insilmaril@89 | 143 |
void modModeColor(); |
insilmaril@89 | 144 |
void modModeLink(); |
insilmaril@89 | 145 |
|
insilmaril@0 | 146 |
public slots: |
insilmaril@0 | 147 |
bool settingsPDF(); |
insilmaril@0 | 148 |
bool settingsURL(); |
insilmaril@0 | 149 |
|
insilmaril@0 | 150 |
void windowToggleNoteEditor(); |
insilmaril@0 | 151 |
private slots: |
insilmaril@0 | 152 |
void windowNextEditor(); |
insilmaril@0 | 153 |
void windowPreviousEditor(); |
insilmaril@0 | 154 |
void windowShowNoteEditor(); |
insilmaril@0 | 155 |
void windowHideNoteEditor(); |
insilmaril@0 | 156 |
|
insilmaril@0 | 157 |
void standardFlagChanged(); |
insilmaril@0 | 158 |
|
insilmaril@0 | 159 |
void testFunction(); |
insilmaril@0 | 160 |
void testShowClipboard(); |
insilmaril@0 | 161 |
|
insilmaril@0 | 162 |
void helpDoc(); |
insilmaril@0 | 163 |
void helpAbout(); |
insilmaril@0 | 164 |
void helpAboutQT(); |
insilmaril@0 | 165 |
|
insilmaril@0 | 166 |
private: |
insilmaril@0 | 167 |
QCanvas* canvas; |
insilmaril@0 | 168 |
QTabWidget *tabWidget; |
insilmaril@0 | 169 |
FindWindow *findWindow; |
insilmaril@0 | 170 |
QStringList lastMaps; |
insilmaril@0 | 171 |
int maxLastMaps; |
insilmaril@0 | 172 |
QString lastFileDir; |
insilmaril@0 | 173 |
}; |
insilmaril@0 | 174 |
|
insilmaril@0 | 175 |
|
insilmaril@0 | 176 |
#endif |
insilmaril@0 | 177 |