1 // Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 // File : SalomePyQt.sip
23 // Author : Vadim SANDLER, Open CASCADE S.A.S. (vadim.sandler@opencascade.com)
28 %Import QtCore/QtCoremod.sip
29 %Import QtGui/QtGuimod.sip
31 %Import QtWidgets/QtWidgetsmod.sip
34 class PyEditor_Settings
37 #include <PyEditor_Settings.h>
43 void setHighlightCurrentLine( bool );
44 bool highlightCurrentLine() const;
46 void setTextWrapping( bool );
47 bool textWrapping() const;
49 void setCenterCursorOnScroll( bool );
50 bool centerCursorOnScroll() const;
52 void setLineNumberArea( bool );
53 bool lineNumberArea() const;
55 void setVerticalEdge( bool );
56 bool verticalEdge() const;
58 void setNumberColumns( int );
59 int numberColumns() const;
61 void setTabSpaceVisible( bool );
62 bool tabSpaceVisible() const;
64 void setTabSize( int );
67 void setFont( const QFont& );
70 void setCompletionPolicy( int );
71 int completionPolicy() const;
74 class PyEditor_Editor : QPlainTextEdit
77 #include <PyEditor_Editor.h>
81 explicit PyEditor_Editor( QWidget* /TransferThis/ = 0 );
82 virtual ~PyEditor_Editor();
84 void setSettings( const PyEditor_Settings& );
85 const PyEditor_Settings& settings() const;
88 QStringList keywords() const;
89 void appendKeywords( const QStringList&, int, const QColor& = QColor() );
90 void removeKeywords( const QStringList& );
93 void deleteSelected();
94 void append( const QString& );
95 void setText( const QString& text );
98 virtual void keyPressEvent( QKeyEvent* );
99 virtual void resizeEvent( QResizeEvent* );
100 virtual void paintEvent( QPaintEvent* );
103 PyEditor_Editor( const PyEditor_Editor& );
104 PyEditor_Editor& operator=( const PyEditor_Editor& );