23#ifndef SCRIPTDOCKWIDGET_H
24#define SCRIPTDOCKWIDGET_H
26#include "abstractDockWidget.h"
27#include "itomQWidgets.h"
28#include "outlineSelectorWidget.h"
29#include "scriptEditorWidget.h"
30#include "tabSwitcherWidget.h"
35#include <qsharedpointer.h>
39#include "../models/bookmarkModel.h"
40#include "../models/outlineItem.h"
44#include "../ui/widgetFindWord.h"
53 QAction* actNavigationForward;
54 QAction* actNavigationBackward;
64 const QString& objName,
70 Qt::WindowFlags flags = Qt::WindowFlags());
75 void getAllCanonicalFilenamesWithModificationState(QStringList &filenames, QList<bool> &modified)
const;
81 bool askFirst =
true,
bool ignoreNewScripts =
false,
int excludeIndex = -1);
83 bool saveFirst =
true,
85 bool ignoreNewScripts =
false,
86 int excludeIndex = -1,
87 bool closeScriptWidgetIfLastTabClosed =
true);
91 return (tabIndex >= 0 && tabIndex < m_tab->count());
95 return m_tab->count();
97 inline int getCurrentIndex()
const
99 return m_tab->currentIndex();
101 void setCurrentIndex(
int index);
113 bool activeTabEnsureLineVisible(
114 const int lineNr,
bool errorMessageClick =
false,
bool showSelectedCallstackLine =
false);
115 void activeTabShowLineAndHighlightWord(
117 const QString& highlightedText,
118 Qt::CaseSensitivity caseSensitivity = Qt::CaseInsensitive);
119 const QTabWidget* tabWidget()
const
124 QList<ito::ScriptEditorStorage> saveScriptState()
const;
128 QList<OutlineSelectorWidget::EditorOutline> getAllOutlines(
int& activeIndex)
const;
130 ScriptEditorWidget* getEditorByCanonicalFilepath(
const QString &filepath)
const;
136 void tabFilenameOrModificationChanged(
int index);
144 virtual void windowStateChanged(
bool windowNotToolbox);
146 RetVal
closeTab(
int index,
bool saveFirst =
true,
bool closeScriptWidgetIfLastTabClosed =
true);
147 RetVal
saveTab(
int index,
bool forceSaveAs =
false,
bool askFirst =
true);
150 QWidget* m_pCenterWidget;
151 QVBoxLayout* m_pVBox;
159 static const char* statusBarStatePropertyName;
167 QList<int> m_stackHistory;
169 QSharedPointer<TabSwitcherWidget> m_tabSwitcherWidget;
170 QSharedPointer<OutlineSelectorWidget> m_outlineSelectorWidget;
221 QMenu* m_tabContextMenu;
223 QMenu* m_lastFilesMenu;
229 QToolBar* m_fileToolBar;
230 QToolBar* m_editToolBar;
231 QToolBar* m_scriptToolBar;
232 QToolBar* m_bookmarkToolBar;
234 QString m_autoCodeFormatCmd;
237 QWidget* m_classMenuBar;
238 QComboBox* m_classBox;
239 QComboBox* m_methodBox;
240 bool m_outlineShowNavigation;
241 void fillNavigationClassComboBox(
242 const QSharedPointer<OutlineItem>& parent,
const QString& prefix);
243 void fillNavigationMethodComboBox(
244 const QSharedPointer<OutlineItem>& parent,
const QString& prefix);
247 static QPointer<ScriptEditorWidget>
248 currentSelectedCallstackLineEditor;
259 const QString& filename,
266 bool closeDockIfEmpty =
272 bool undockToNewScriptWindow =
false,
273 bool closeDockIfEmpty =
284 QString selectionText);
288 void statusBarInformationChanged(
289 const QPointer<ScriptDockWidget> sourceDockWidget,
290 const QString& encoding,
305 void replaceTextExpr(QString expr, QString replace);
313 void insertIconBrowserText(QString iconLink);
351 void mnuScriptRunSelection();
358 void mnuFindTextExpr();
359 void mnuReplaceTextExpr();
361 void mnuToggleBookmark();
362 void mnuInsertCodec();
364 void mnuPyCodeFormatting();
365 void mnuPyReferenceRenaming();
366 void mnuPyDocstringGenerator();
369 void menuLastFilesAboutToShow();
370 void lastFileOpen(
const QString& path);
373 void navigatorClassSelected(
int row);
374 void navigatorMethodSelected(
int row);
377 void findWordWidgetFinished();
379 void currentScriptCursorPositionChanged();
382 void editorMarginChanged();
383 void updateCodeNavigation(
ScriptEditorWidget* editor, QSharedPointer<OutlineItem> rootItem);
384 void tabChangedRequest();
385 void mnuFindSymbolsShow();
model for management of all bookmarks. This model will be displayed by a viewer-widget in the main wi...
Definition bookmarkModel.h:65
Definition dialogReplace.h:38
Class for managing status values (like errors or warning)
Definition retVal.h:54
Definition shortcutAction.h:41
Definition apiFunctionsGraph.cpp:40
Definition scriptEditorWidget.h:78
this struct can hold common actions for all script editor and script dock widgets
Definition scriptDockWidget.h:52