diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2022-09-18 20:19:47 +0900 | 
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2022-09-18 20:39:48 +0900 | 
| commit | a80a494efee7979c28ab1090734270e5c0515352 (patch) | |
| tree | 1cdaee39e3e5a2b32c171f8389b29b15c519c607 /src/MainWindow.h | |
| parent | 14f7e49438caa24af81a0d7d7864ce71d96791e4 (diff) | |
| download | universal-indent-gui-tqt-a80a494efee7979c28ab1090734270e5c0515352.tar.gz universal-indent-gui-tqt-a80a494efee7979c28ab1090734270e5c0515352.zip | |
Added main window menubar GUI. The logic of each action has not been implemented yet.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'src/MainWindow.h')
| -rw-r--r-- | src/MainWindow.h | 35 | 
1 files changed, 17 insertions, 18 deletions
| diff --git a/src/MainWindow.h b/src/MainWindow.h index acb399a..e0d9320 100644 --- a/src/MainWindow.h +++ b/src/MainWindow.h @@ -20,7 +20,8 @@  #ifndef MAINWINDOW_H  #define MAINWINDOW_H -#include <tqmainwindow.h> +#include "MainWindowBase.h" +#include "ntqobjectdefs.h"  /// #include  "UiGuiSettings.h"  ///  @@ -33,7 +34,6 @@  /// namespace Ui  /// {  /// 	class ToolBarWidget; -/// 	class MainWindowUi;  /// }  ///   /// class TQLabel; @@ -44,9 +44,9 @@  /// class QsciScintilla; -class MainWindow : public TQMainWindow +class MainWindow : public MainWindowBase  { -///--Q_OBJECT +	TQ_OBJECT  	public:  		//! Constructor @@ -61,11 +61,11 @@ class MainWindow : public TQMainWindow  ///-- 		void closeEvent(TQCloseEvent *event);  ///-- 		bool eventFilter(TQObject *obj, TQEvent *event);  ///--  -///-- 	private slots: -///-- 		void openSourceFileDialog(TQString fileName = ""); -///-- 		bool saveasSourceFileDialog(TQAction *chosenEncodingAction = NULL); +	private slots: +		void openSourceFileDialog(TQString fileName = ""); +		bool saveSourceFile(); +		bool saveasSourceFileDialog(TQAction *chosenEncodingAction = NULL);  ///-- 		void saveAsOtherEncoding(TQAction *chosenEncodingAction); -///-- 		bool saveSourceFile();  ///-- 		void callIndenter();  ///-- 		void updateSourceView();  ///-- 		void turnHighlightOnOff(bool turnOn); @@ -74,20 +74,18 @@ class MainWindow : public TQMainWindow  ///-- 		void sourceCodeChangedSlot();  ///-- 		void indentSettingsChangedSlot();  ///-- 		void previewTurnedOnOff(bool turnOn); -///-- 		void exportToPDF(); -///-- 		void exportToHTML(); +		void exportToPDF(); +		void exportToHTML();  ///-- 		void languageChanged(int languageIndex);  ///-- 		void encodingChanged(TQAction *encodingAction);  ///-- 		void numberOfLinesChanged(); -///-- 		void updateRecentlyOpenedList(); -///-- 		void openFileFromRecentlyOpenedList(TQAction *recentlyOpenedAction); -///-- 		void clearRecentlyOpenedList(); -///-- 		void showAboutDialog(); +		void updateRecentlyOpenedList(); +		void openFileFromRecentlyOpenedList(int recentlyOpenedActionId); +		void clearRecentlyOpenedList(); +		void showAboutDialog();  ///-- 		void setStatusBarCursorPosInfo(int line, int column);  ///--  -///-- 	private: -///-- 		Ui::MainWindowUi *_mainWindowForm; -///--  +	private:  ///-- 		TQString loadFile(TQString filePath);  ///-- 		TQString openFileDialog(TQString dialogHeaderStr, TQString startPath, TQString fileMaskStr);  ///-- 		void     updateWindowTitle(); @@ -97,7 +95,7 @@ class MainWindow : public TQMainWindow  ///-- 		void     createEncodingMenu();  ///-- 		void     createHighlighterMenu();  ///-- 		bool     initApplicationLanguage(); -///-- 		void     initMainWindow(); +		void     initMainWindow();  ///-- 		void     initToolBar();  ///-- 		void     initTextEditor();  ///-- 		void     initSyntaxHighlighter(); @@ -118,6 +116,7 @@ class MainWindow : public TQMainWindow  ///-- 		AboutDialog             *_aboutDialog;  ///-- 		AboutDialogGraphicsView *_aboutDialogGraphicsView;  ///-- 		UiGuiSettingsDialog     *_settingsDialog; +		int _actionClearRecentlyOpenedListId;  ///-- 		int            _textEditLastScrollPos;  ///-- 		int            _currentIndenterID;  ///-- 		bool           _loadLastSourceCodeFileOnStartup; | 
