15#include <QtCore/qstring.h> 
   16#include <QtCore/qstringlist.h> 
   17#include <QtCore/qregularexpression.h> 
   24    class SyntaxHighlighter;
 
   25    class TextEditorSearchPopup;
 
   32        QSize sizeHint() 
const override;
 
   35        void paintEvent(QPaintEvent * _event) 
override;
 
 
   51        TextEditor(QWidget* _parent = (QWidget*)
nullptr);
 
   57        virtual void setupFromConfig(
const TextEditorCfg& _config, 
bool _isUpdate);
 
   59        int lineNumberAreaWidth(
void) 
const;
 
   60        void lineNumberAreaPaintEvent(QPaintEvent * _event);
 
   62        void setContentChanged(
void);
 
   63        void setContentSaved(
void);
 
   64        bool getContentChanged(
void) 
const;
 
   66        void setCode(
const QString& _text);
 
   67        void setCode(
const QStringList& _lines);
 
   69        QStringList code(
void) 
const;
 
   97        void saveRequested(
void);
 
  102        virtual void keyPressEvent(QKeyEvent* _event) 
override;
 
  103        virtual void resizeEvent(QResizeEvent * _event) 
override;
 
  104        virtual void wheelEvent(QWheelEvent* _event) 
override;
 
  107        void slotUpdateLineNumberAreaWidth(
int _newBlockCount);
 
  108        void slotHighlightCurrentLine();
 
  109        void slotUpdateLineNumberArea(
const QRect & _rect, 
int _dy);
 
  110        void slotSaveRequested(
void);
 
  111        void slotFindRequested(
void);
 
  112        void slotFindClosing(
void);
 
  113        void slotDuplicateLine(
void);
 
  115        void slotSelectionChanged(
void);
 
  116        void slotContentChange(
bool _changed); 
 
  121        void getCurrentLineSelection(QList<QTextEdit::ExtraSelection>& _selections);
 
  122        void addAdditionalSelections(QList<QTextEdit::ExtraSelection>& _selections);
 
  127        bool m_newLineSamePrefix;
 
  128        bool m_enableDuplicateLineShortcut;
 
  129        bool m_enableSameTextHighlighting;
 
  130        int m_sameTextHighlightingMinimum;
 
 
#define OT_DECL_NOCOPY(___class)
Removes the default copy constructor and assignment operator.
Definition OTClassHelper.h:14
Definition ColorStyle.h:24
Definition PlainTextEdit.h:17
Definition SyntaxHighlighter.h:21
Definition TextEditorCfg.h:19
Definition TextEditor.h:47
bool isSameTextHighlightingEnabled(void) const
Definition TextEditor.h:94
bool newLineWithSamePrefix(void) const
Definition TextEditor.h:88
void setEnableSameTextHighlighting(bool _enabled)
Definition TextEditor.h:93
void setDuplicateLineShortcutEnabled(bool _enabled)
Definition TextEditor.h:90
virtual void contentSaved(void)
Definition TextEditor.h:100
int tabSpaces(void) const
Definition TextEditor.h:85
virtual void contentChanged(void)
Definition TextEditor.h:101
void setNewLineWithSamePrefix(bool _enabled)
Definition TextEditor.h:87
void setTabSpaces(int _spaces)
Definition TextEditor.h:84
bool isDuplicateLineShortcutEnabled(void) const
Definition TextEditor.h:91
SyntaxHighlighter * getSyntaxHighlighter(void)
Returns the current syntax highlighter. The TextEditor keeps ownership of the highlighter.
Definition TextEditor.h:78
Definition TextEditor.h:27