• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • applications API Reference
  • KDE Home
  • Contact Us
 

Kate

  • sources
  • kde-4.12
  • applications
  • kate
  • part
  • script
katescriptconsole.h
Go to the documentation of this file.
1 /* This file is part of the KDE libraries
2  Copyright (C) 2010 Miquel Sabaté <mikisabate@gmail.com>
3 
4  This library is free software; you can redistribute it and/or
5  modify it under the terms of the GNU Library General Public
6  License as published by the Free Software Foundation; either
7  version 2 of the License, or (at your option) any later version.
8 
9  This library is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  Library General Public License for more details.
13 
14  You should have received a copy of the GNU Library General Public License
15  along with this library; see the file COPYING.LIB. If not, write to
16  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17  Boston, MA 02110-1301, USA.
18 */
19 
20 
21 #ifndef KATE_SCRIPT_CONSOLE_H
22 #define KATE_SCRIPT_CONSOLE_H
23 
24 
25 #include "kateviewhelpers.h"
26 
27 class QTextEdit;
28 class QPushButton;
29 class QLabel;
30 class QVBoxLayout;
31 class QHBoxLayout;
32 
33 
39 class KateScriptConsoleEngine
40 {
41  public:
43  KateScriptConsoleEngine(KateView * view);
44  virtual ~KateScriptConsoleEngine();
45 
51  const QString & execute(const QString & text);
52 
53  private:
55  QString m_utilsUrl;
56 
58  KateView * m_view;
59 
60  private:
68  const QString getFirstFunctionName(const QString & text, QString & msg);
69 };
70 
71 
72 class KateScriptConsole : public KateViewBarWidget
73 {
74  Q_OBJECT
75 
76  public:
77  KateScriptConsole(KateView * view, QWidget * parent = NULL);
78  virtual ~KateScriptConsole();
79 
80  protected:
81  // overridden
82  virtual void closed();
83 
84  private:
85  QVBoxLayout * layout;
86  QHBoxLayout * hLayout;
87  QTextEdit * m_edit;
88  QPushButton * m_execute;
89  QLabel * m_result;
90  KateView * m_view;
91  KateScriptConsoleEngine * m_engine;
92 
93  public slots:
94  void executePressed();
95 };
96 
97 
98 #endif /* KATE_SCRIPT_CONSOLE_H */
99 
100 
101 // kate: space-indent on; indent-width 2; replace-tabs on;
102 
KateScriptConsoleEngine
Manage JavaScript, allowing the user directly type commands as in KateCommnadLineBar environment...
Definition: katescriptconsole.h:39
KateScriptConsole::closed
virtual void closed()
Definition: katescriptconsole.cpp:132
QWidget
KateScriptConsoleEngine::KateScriptConsoleEngine
KateScriptConsoleEngine(KateView *view)
Constructor + Destructor.
Definition: katescriptconsole.cpp:40
QPushButton
QString
KateScriptConsoleEngine::execute
const QString & execute(const QString &text)
Execute a command or a set of functions.
Definition: katescriptconsole.cpp:51
kateviewhelpers.h
KateScriptConsole
Definition: katescriptconsole.h:72
KateViewBarWidget
Definition: kateviewhelpers.h:288
KateView
Definition: kateview.h:78
KateScriptConsole::~KateScriptConsole
virtual ~KateScriptConsole()
Definition: katescriptconsole.cpp:127
QLabel
KateScriptConsoleEngine::~KateScriptConsoleEngine
virtual ~KateScriptConsoleEngine()
Definition: katescriptconsole.cpp:46
KateScriptConsole::KateScriptConsole
KateScriptConsole(KateView *view, QWidget *parent=NULL)
Definition: katescriptconsole.cpp:103
KateScriptConsole::executePressed
void executePressed()
Definition: katescriptconsole.cpp:138
QTextEdit
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:31:52 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

Kate

Skip menu "Kate"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

applications API Reference

Skip menu "applications API Reference"
  •   kate
  •       kate
  •   KTextEditor
  •   Kate
  • Applications
  •   Libraries
  •     libkonq
  • Konsole

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal