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