Sophie

Sophie

distrib > Mageia > 7 > armv7hl > media > core-updates > by-pkgid > 1dd17e0d683ef79b4bb6872bbf359d7f > files > 6296

qt4-doc-4.8.7-26.2.mga7.noarch.rpm

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_US" lang="en_US">
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- qscriptenginedebugger.cpp -->
  <title>Qt 4.8: QScriptEngineDebugger Class Reference</title>
  <link rel="stylesheet" type="text/css" href="style/style.css" />
  <script src="scripts/jquery.js" type="text/javascript"></script>
  <script src="scripts/functions.js" type="text/javascript"></script>
  <link rel="stylesheet" type="text/css" href="style/superfish.css" />
  <link rel="stylesheet" type="text/css" href="style/narrow.css" />
  <!--[if IE]>
<meta name="MSSmartTagsPreventParsing" content="true">
<meta http-equiv="imagetoolbar" content="no">
<![endif]-->
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" href="style/style_ie6.css">
<![endif]-->
<!--[if IE 7]>
<link rel="stylesheet" type="text/css" href="style/style_ie7.css">
<![endif]-->
<!--[if IE 8]>
<link rel="stylesheet" type="text/css" href="style/style_ie8.css">
<![endif]-->

<script src="scripts/superfish.js" type="text/javascript"></script>
<script src="scripts/narrow.js" type="text/javascript"></script>

</head>
<body class="" onload="CheckEmptyAndLoadList();">
 <div class="header" id="qtdocheader">
    <div class="content"> 
    <div id="nav-logo">
      <a href="index.html">Home</a></div>
    <a href="index.html" class="qtref"><span>Qt Reference Documentation</span></a>
    <div id="narrowsearch"></div>
    <div id="nav-topright">
      <ul>
        <li class="nav-topright-home"><a href="http://qt.digia.com/">Qt HOME</a></li>
        <li class="nav-topright-dev"><a href="http://qt-project.org/">DEV</a></li>
        <li class="nav-topright-doc nav-topright-doc-active"><a href="http://qt-project.org/doc/">
          DOC</a></li>
        <li class="nav-topright-blog"><a href="http://blog.qt.digia.com/">BLOG</a></li>
      </ul>
    </div>
    <div id="shortCut">
      <ul>
        <li class="shortCut-topleft-inactive"><span><a href="index.html">Qt 4.8</a></span></li>
        <li class="shortCut-topleft-active"><a href="http://qt-project.org/doc/">ALL VERSIONS        </a></li>
      </ul>
     </div>
 <ul class="sf-menu" id="narrowmenu"> 
             <li><a href="#">API Lookup</a> 
                 <ul> 
                     <li><a href="classes.html">Class index</a></li> 
           <li><a href="functions.html">Function index</a></li> 
           <li><a href="modules.html">Modules</a></li> 
           <li><a href="namespaces.html">Namespaces</a></li> 
           <li><a href="qtglobal.html">Global Declarations</a></li> 
           <li><a href="qdeclarativeelements.html">QML elements</a></li> 
             </ul> 
             </li> 
             <li><a href="#">Qt Topics</a> 
                 <ul> 
                        <li><a href="qt-basic-concepts.html">Programming with Qt</a></li>  
                        <li><a href="qtquick.html">Device UIs &amp; Qt Quick</a></li>  
                        <li><a href="qt-gui-concepts.html">UI Design with Qt</a></li>  
                        <li><a href="supported-platforms.html">Supported Platforms</a></li>  
                        <li><a href="technology-apis.html">Qt and Key Technologies</a></li>  
                        <li><a href="best-practices.html">How-To's and Best Practices</a></li>  
              </ul> 
                 </li> 
                 <li><a href="#">Examples</a> 
                     <ul> 
                       <li><a href="all-examples.html">Examples</a></li> 
                       <li><a href="tutorials.html">Tutorials</a></li> 
                       <li><a href="demos.html">Demos</a></li> 
                       <li><a href="qdeclarativeexamples.html">QML Examples</a></li> 
                </ul> 
                     </li> 
                 </ul> 
    </div>
  </div>
  <div class="wrapper">
    <div class="hd">
      <span></span>
    </div>
    <div class="bd group">
      <div class="sidebar">
        <div class="searchlabel">
          Search index:</div>
        <div class="search" id="sidebarsearch">
          <form id="qtdocsearch" action="" onsubmit="return false;">
            <fieldset>
              <input type="text" name="searchstring" id="pageType" value="" />
 <div id="resultdialog"> 
 <a href="#" id="resultclose">Close</a> 
 <p id="resultlinks" class="all"><a href="#" id="showallresults">All</a> | <a href="#" id="showapiresults">API</a> | <a href="#" id="showarticleresults">Articles</a> | <a href="#" id="showexampleresults">Examples</a></p> 
 <p id="searchcount" class="all"><span id="resultcount"></span><span id="apicount"></span><span id="articlecount"></span><span id="examplecount"></span>&nbsp;results:</p> 
 <ul id="resultlist" class="all"> 
 </ul> 
 </div> 
            </fieldset>
          </form>
        </div>
        <div class="box first bottombar" id="lookup">
          <h2 title="API Lookup"><span></span>
            API Lookup</h2>
          <div  id="list001" class="list">
          <ul id="ul001" >
              <li class="defaultLink"><a href="classes.html">Class index</a></li>
              <li class="defaultLink"><a href="functions.html">Function index</a></li>
              <li class="defaultLink"><a href="modules.html">Modules</a></li>
              <li class="defaultLink"><a href="namespaces.html">Namespaces</a></li>
              <li class="defaultLink"><a href="qtglobal.html">Global Declarations</a></li>
              <li class="defaultLink"><a href="qdeclarativeelements.html">QML elements</a></li>
            </ul> 
          </div>
        </div>
        <div class="box bottombar" id="topics">
          <h2 title="Qt Topics"><span></span>
            Qt Topics</h2>
          <div id="list002" class="list">
            <ul id="ul002" >
               <li class="defaultLink"><a href="qt-basic-concepts.html">Programming with Qt</a></li> 
               <li class="defaultLink"><a href="qtquick.html">Device UIs &amp; Qt Quick</a></li> 
               <li class="defaultLink"><a href="qt-gui-concepts.html">UI Design with Qt</a></li> 
               <li class="defaultLink"><a href="supported-platforms.html">Supported Platforms</a></li>  
               <li class="defaultLink"><a href="technology-apis.html">Qt and Key Technologies</a></li> 
               <li class="defaultLink"><a href="best-practices.html">How-To's and Best Practices</a></li> 
            </ul>  
          </div>
        </div>
        <div class="box" id="examples">
          <h2 title="Examples"><span></span>
            Examples</h2>
          <div id="list003" class="list">
        <ul id="ul003">
              <li class="defaultLink"><a href="all-examples.html">Examples</a></li>
              <li class="defaultLink"><a href="tutorials.html">Tutorials</a></li>
              <li class="defaultLink"><a href="demos.html">Demos</a></li>
              <li class="defaultLink"><a href="qdeclarativeexamples.html">QML Examples</a></li>
            </ul> 
          </div>
        </div>
      </div>
      <div class="wrap">
        <div class="toolbar">
          <div class="breadcrumb toolblock">
            <ul>
              <li class="first"><a href="index.html">Home</a></li>
              <!--  Breadcrumbs go here -->
<li><a href="modules.html">Modules</a></li>
<li><a href="qtscripttools.html">QtScriptTools</a></li>
<li>QScriptEngineDebugger</li>
            </ul>
          </div>
          <div class="toolbuttons toolblock">
            <ul>
              <li id="smallA" class="t_button">A</li>
              <li id="medA" class="t_button active">A</li>
              <li id="bigA" class="t_button">A</li>
              <li id="print" class="t_button"><a href="javascript:this.print();">
                <span>Print</span></a></li>
            </ul>
        </div>
        </div>
        <div class="content mainContent">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<li class="level1"><a href="#public-types">Public Types</a></li>
<li class="level1"><a href="#public-functions">Public Functions</a></li>
<li class="level1"><a href="#signals">Signals</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
</ul>
</div>
<h1 class="title">QScriptEngineDebugger Class Reference</h1>
<!-- $$$QScriptEngineDebugger-brief -->
<p>The QScriptEngineDebugger class provides a <a href="qscriptengine.html">QScriptEngine</a> debugger. <a href="#details">More...</a></p>
<!-- @@@QScriptEngineDebugger -->
<pre class="cpp"> <span class="preprocessor">#include &lt;QScriptEngineDebugger&gt;</span></pre><p><b>Inherits: </b><a href="qobject.html">QObject</a>.</p>
<p>This class was introduced in Qt 4.5.</p>
<ul>
<li><a href="qscriptenginedebugger-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="public-types"></a>
<h2>Public Types</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#DebuggerAction-enum">DebuggerAction</a></b> { InterruptAction, ContinueAction, StepIntoAction, StepOverAction, ..., GoToLineAction }</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#DebuggerState-enum">DebuggerState</a></b> { RunningState, SuspendedState }</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#DebuggerWidget-enum">DebuggerWidget</a></b> { ConsoleWidget, StackWidget, ScriptsWidget, LocalsWidget, ..., ErrorLogWidget }</td></tr>
</table>
<a name="public-functions"></a>
<h2>Public Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#QScriptEngineDebugger">QScriptEngineDebugger</a></b> ( QObject * <i>parent</i> = 0 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#dtor.QScriptEngineDebugger">~QScriptEngineDebugger</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QAction * </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#action">action</a></b> ( DebuggerAction <i>action</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#attachTo">attachTo</a></b> ( QScriptEngine * <i>engine</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#autoShowStandardWindow">autoShowStandardWindow</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QMenu * </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#createStandardMenu">createStandardMenu</a></b> ( QWidget * <i>parent</i> = 0 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QToolBar * </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#createStandardToolBar">createStandardToolBar</a></b> ( QWidget * <i>parent</i> = 0 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#detach">detach</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#setAutoShowStandardWindow">setAutoShowStandardWindow</a></b> ( bool <i>autoShow</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QMainWindow * </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#standardWindow">standardWindow</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> DebuggerState </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#state">state</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWidget * </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#widget">widget</a></b> ( DebuggerWidget <i>widget</i> ) const</td></tr>
</table>
<ul>
<li class="fn">29 public functions inherited from <a href="qobject.html#public-functions">QObject</a></li>
</ul>
<a name="signals"></a>
<h2>Signals</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#evaluationResumed">evaluationResumed</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qscriptenginedebugger.html#evaluationSuspended">evaluationSuspended</a></b> ()</td></tr>
</table>
<ul>
<li class="fn">1 signal inherited from <a href="qobject.html#signals">QObject</a></li>
</ul>
<h3>Additional Inherited Members</h3>
<ul>
<li class="fn">1 property inherited from <a href="qobject.html#properties">QObject</a></li>
<li class="fn">1 public slot inherited from <a href="qobject.html#public-slots">QObject</a></li>
<li class="fn">7 static public members inherited from <a href="qobject.html#static-public-members">QObject</a></li>
<li class="fn">8 protected functions inherited from <a href="qobject.html#protected-functions">QObject</a></li>
</ul>
<a name="details"></a>
<!-- $$$QScriptEngineDebugger-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The QScriptEngineDebugger class provides a <a href="qscriptengine.html">QScriptEngine</a> debugger.</p>
<p>The QScriptEngineDebugger class provides a debugger that can be embedded into Qt applications that use Qt Script. The debugger enables the application user to inspect the state of the script environment and control script execution.</p>
<p>To attach the debugger to a script engine, call the <a href="qscriptenginedebugger.html#attachTo">attachTo</a>() function.</p>
<pre class="cpp">     <span class="type"><a href="qscriptengine.html">QScriptEngine</a></span> engine;
     <span class="type">QScriptEngineDebugger</span> debugger;
     debugger<span class="operator">.</span><a href="qscriptenginedebugger.html#attachTo">attachTo</a>(<span class="operator">&amp;</span>engine);</pre>
<p>Once the debugger has been attached to a script engine, you can proceed to evaluate scripts as usual, e.g&#x2e; by calling <a href="qscriptengine.html#evaluate">QScriptEngine::evaluate</a>(). The debugger will be triggered when an uncaught exception occurs, or when a <tt>debugger</tt> statement is encountered in a script. It is also possible to interrupt script evaluation at an arbitrary time by triggering the <a href="qscriptenginedebugger.html#DebuggerAction-enum">InterruptAction</a>. For instance, to start the debugger when script evaluation starts, you trigger the action before you begin to <a href="qscriptengine.html#evaluate">evaluate()</a> the script.</p>
<pre class="cpp">      debugger<span class="operator">-</span><span class="operator">&gt;</span>action(<span class="type">QScriptEngineDebugger</span><span class="operator">::</span>InterruptAction)<span class="operator">-</span><span class="operator">&gt;</span>trigger();
      engine<span class="operator">-</span><span class="operator">&gt;</span>evaluate(contents<span class="operator">,</span> fileName);</pre>
<p>By default, the <a href="qscriptenginedebugger.html#standardWindow">standard debugger window</a> is shown when evaluation is suspended. This can be changed by calling the <a href="qscriptenginedebugger.html#setAutoShowStandardWindow">setAutoShowStandardWindow</a>() function.</p>
<p>The debugger defines a set of <a href="qscriptenginedebugger.html#DebuggerAction-enum">actions</a> that are available, such as stopping execution or printing the contents of a variable. It also provides a set of widgets (components) that display the information available from the debugger and that trigger the actions on request. The actions available are identified by the <a href="qscriptenginedebugger.html#DebuggerAction-enum">DebuggerAction</a> enum, and the widgets are identified by the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">DebuggerWidget</a> enum.</p>
<p>Access to the individual debugger widgets is provided by the <a href="qscriptenginedebugger.html#widget">widget</a>() function. This makes it possible to arrange the widgets in a custom manner. Similarly, the <a href="qscriptenginedebugger.html#action">action</a>() function provides access to the various debugger actions.</p>
<p>The <a href="qscriptenginedebugger.html#createStandardToolBar">createStandardToolBar</a>() function creates a standard toolbar, and the <a href="qscriptenginedebugger.html#createStandardMenu">createStandardMenu</a>() function creates a standard menu; these functions can be useful if you are creating a custom debugger configuration.</p>
<p>The <a href="qscriptenginedebugger.html#evaluationSuspended">evaluationSuspended</a>() signal is emitted when the debugger has suspended script evaluation and entered interactive mode, i.e&#x2e;, the mode in which it accepts input from the user. The <a href="qscriptenginedebugger.html#evaluationResumed">evaluationResumed</a>() signal is emitted when script evaluation is resumed, i.e, when execution control is given back to the script engine. The <a href="qscriptenginedebugger.html#state">state</a>() function returns the debugger's current state.</p>
<p>When calling <a href="qscriptengine.html#evaluate">QScriptEngine::evaluate</a>() it is useful to pass a descriptive script name (file name) as second argument, as this is the name that will be displayed by the debugger in the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">ScriptsWidget</a>; if a name is not passed, the script will be labelled &quot;anonymous&quot;.</p>
<p>When evaluation is suspended, the debugger will also suspend the event loop of the script. In the following snippet, the call to <a href="qscriptengine.html#evaluate">QScriptEngine::evaluate</a>() causes the debugger to be triggered, and the function call does not return until the user has finished interacting with the debugger.</p>
<pre class="cpp">     engine<span class="operator">.</span>evaluate(<span class="string">&quot;debugger&quot;</span>);</pre>
<p>When the Qt Script debugger is running, the C++ application itself is not &quot;frozen&quot;. This means that it is possible that more scripts are evaluated, even though the debugger has suspended evaluation of the <b>current</b> script evaluation. For example, a C++ timer might trigger that causes a script function to be called, or the user might click on a button in the main application user interface whose clicked() signal is connected to a script function. This kind of nested evaluation is permitted. The debugger will enter interactive mode for the new script if an exception is thrown or a breakpoint is reached. Note that it will not stop when encountering <tt>debugger</tt> statements.</p>
<p>Nested evaluation requires some thought when deciding how the debugger is presented to the user; for example, whether a modal dialog is suitable, or whether some parts of the main application user interface should be disabled while the debugger is running.</p>
<p>Debugging inside of a <a href="qwidget.html#paintEvent">paintEvent</a>() is currently not supported. If you need to debug painting-related script code, that code should be evaluated outside of the C++ paintEvent(), e.g&#x2e; by rendering to an image, like the Context2D and Tetrix <a href="qtscript.html">QtScript</a> examples do. This will make the code safe for debugging.</p>
<p>The debugger adds some special properties to the script engine: <tt>__FILE__</tt> holds the name of the script in which the current evaluation occurs, and <tt>__LINE__</tt> holds the current line number. These are useful when doing print()-style debugging (the messages appear in the debugger's debug output widget).</p>
<p>The <a href="qtscriptdebugger-manual.html">Qt Script Debugger Manual</a> describes how to use the debugger. The <a href="script-context2d.html">Context2D example</a> shows how to integrate the debugger in applications.</p>
</div>
<p><b>See also </b><a href="qscriptengine.html">QScriptEngine</a> and <a href="script-context2d.html">Context2D Example</a>.</p>
<!-- @@@QScriptEngineDebugger -->
<div class="types">
<h2>Member Type Documentation</h2>
<!-- $$$DebuggerAction$$$InterruptAction$$$ContinueAction$$$StepIntoAction$$$StepOverAction$$$StepOutAction$$$RunToCursorAction$$$RunToNewScriptAction$$$ToggleBreakpointAction$$$ClearDebugOutputAction$$$ClearErrorLogAction$$$ClearConsoleAction$$$FindInScriptAction$$$FindNextInScriptAction$$$FindPreviousInScriptAction$$$GoToLineAction -->
<h3 class="fn"><a name="DebuggerAction-enum"></a>enum QScriptEngineDebugger::<span class="name">DebuggerAction</span></h3>
<p>This enum specifies the action that the <a href="qscriptenginedebugger.html#action">action</a>() function should retrieve. The actions retrieved can be connected to any slot and connected to any widget. Please see the <a href="qtscriptdebugger-manual.html">Qt Script Debugger Manual</a>'s <a href="qtscriptdebugger-manual.html#console-command-reference">Console Command Reference</a> for a detailed description of these actions.</p>
<table class="valuelist"><tr valign="top" class="odd"><th class="tblConst">Constant</th><th class="tblval">Value</th><th class="tbldscr">Description</th></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::InterruptAction</tt></td><td class="topAlign"><tt>0</tt></td><td class="topAlign">Suspends script execution as soon as the next script statement is reached.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::ContinueAction</tt></td><td class="topAlign"><tt>1</tt></td><td class="topAlign">Gives the execution control back to the script engine.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::StepIntoAction</tt></td><td class="topAlign"><tt>2</tt></td><td class="topAlign">Performs a step action.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::StepOverAction</tt></td><td class="topAlign"><tt>3</tt></td><td class="topAlign">Performs a next action.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::StepOutAction</tt></td><td class="topAlign"><tt>4</tt></td><td class="topAlign">Executes the script until the current function returns.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::RunToCursorAction</tt></td><td class="topAlign"><tt>5</tt></td><td class="topAlign">Continues execution to the selected line (which contains the cursor) in the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">CodeWidget</a>.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::RunToNewScriptAction</tt></td><td class="topAlign"><tt>6</tt></td><td class="topAlign">Returns control to the script engine until a new script is executed.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::ToggleBreakpointAction</tt></td><td class="topAlign"><tt>7</tt></td><td class="topAlign">Toggles a breakpoint at the selected line in the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">CodeWidget</a>.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::ClearDebugOutputAction</tt></td><td class="topAlign"><tt>8</tt></td><td class="topAlign">Clears the contents of the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">DebugOutputWidget</a>.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::ClearErrorLogAction</tt></td><td class="topAlign"><tt>9</tt></td><td class="topAlign">Clears the contents of the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">ErrorLogWidget</a>.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::ClearConsoleAction</tt></td><td class="topAlign"><tt>10</tt></td><td class="topAlign">Clears the contents of the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">ConsoleWidget</a>.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::FindInScriptAction</tt></td><td class="topAlign"><tt>11</tt></td><td class="topAlign">Displays the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">CodeFinderWidget</a>.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::FindNextInScriptAction</tt></td><td class="topAlign"><tt>12</tt></td><td class="topAlign">Finds next occurrence in the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">CodeWidget</a>.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::FindPreviousInScriptAction</tt></td><td class="topAlign"><tt>13</tt></td><td class="topAlign">Finds previous occurrence in the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">CodeWidget</a>.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::GoToLineAction</tt></td><td class="topAlign"><tt>14</tt></td><td class="topAlign">Shows the &quot;Go to Line&quot; dialog.</td></tr>
</table>
<!-- @@@DebuggerAction -->
<!-- $$$DebuggerState$$$RunningState$$$SuspendedState -->
<h3 class="fn"><a name="DebuggerState-enum"></a>enum QScriptEngineDebugger::<span class="name">DebuggerState</span></h3>
<p>This enum specifies the current state of the debugger.</p>
<table class="valuelist"><tr valign="top" class="odd"><th class="tblConst">Constant</th><th class="tblval">Value</th><th class="tbldscr">Description</th></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::RunningState</tt></td><td class="topAlign"><tt>0</tt></td><td class="topAlign">The debugger is running. (Script evaluation is allowed.)</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::SuspendedState</tt></td><td class="topAlign"><tt>1</tt></td><td class="topAlign">The debugger has suspended script evaluation.</td></tr>
</table>
<p>This enum was introduced or modified in Qt 4.6.</p>
<!-- @@@DebuggerState -->
<!-- $$$DebuggerWidget$$$ConsoleWidget$$$StackWidget$$$ScriptsWidget$$$LocalsWidget$$$CodeWidget$$$CodeFinderWidget$$$BreakpointsWidget$$$DebugOutputWidget$$$ErrorLogWidget -->
<h3 class="fn"><a name="DebuggerWidget-enum"></a>enum QScriptEngineDebugger::<span class="name">DebuggerWidget</span></h3>
<p>This enum decides the widget that the <a href="qscriptenginedebugger.html#widget">widget</a>() function should retrieve. We treat these widgets in more detail in the <a href="qtscriptdebugger-manual.html">Qt Script Debugger Manual</a>.</p>
<table class="valuelist"><tr valign="top" class="odd"><th class="tblConst">Constant</th><th class="tblval">Value</th><th class="tbldscr">Description</th></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::ConsoleWidget</tt></td><td class="topAlign"><tt>0</tt></td><td class="topAlign">Provides a command-line interface to the debugger.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::StackWidget</tt></td><td class="topAlign"><tt>1</tt></td><td class="topAlign">Shows a backtrace of the script's execution state.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::ScriptsWidget</tt></td><td class="topAlign"><tt>2</tt></td><td class="topAlign">Displays a list of currently loaded scripts.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::LocalsWidget</tt></td><td class="topAlign"><tt>3</tt></td><td class="topAlign">Shows the local variables of the current stack frame.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::CodeWidget</tt></td><td class="topAlign"><tt>4</tt></td><td class="topAlign">Displays the code of the current script.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::CodeFinderWidget</tt></td><td class="topAlign"><tt>5</tt></td><td class="topAlign">Provides a widget that can search for text in the script shown in the CodeWidget.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::BreakpointsWidget</tt></td><td class="topAlign"><tt>6</tt></td><td class="topAlign">Shows breakpoints that have been set.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::DebugOutputWidget</tt></td><td class="topAlign"><tt>7</tt></td><td class="topAlign">Contains output from the <tt>print()</tt> script function.</td></tr>
<tr><td class="topAlign"><tt>QScriptEngineDebugger::ErrorLogWidget</tt></td><td class="topAlign"><tt>8</tt></td><td class="topAlign">Shows error messages that have been generated.</td></tr>
</table>
<!-- @@@DebuggerWidget -->
</div>
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$QScriptEngineDebugger[overload1]$$$QScriptEngineDebuggerQObject* -->
<h3 class="fn"><a name="QScriptEngineDebugger"></a>QScriptEngineDebugger::<span class="name">QScriptEngineDebugger</span> ( <span class="type"><a href="qobject.html">QObject</a></span> * <i>parent</i> = 0 )</h3>
<p>Constructs a new <a href="qscriptenginedebugger.html">QScriptEngineDebugger</a> object with the given <i>parent</i>.</p>
<p>To attach a <a href="qscriptengine.html">QScriptEngine</a> to the debugger, use <a href="qscriptenginedebugger.html#attachTo">attachTo</a>() function.</p>
<!-- @@@QScriptEngineDebugger -->
<!-- $$$~QScriptEngineDebugger[overload1]$$$~QScriptEngineDebugger -->
<h3 class="fn"><a name="dtor.QScriptEngineDebugger"></a>QScriptEngineDebugger::<span class="name">~QScriptEngineDebugger</span> ()</h3>
<p>Destroys this <a href="qscriptenginedebugger.html">QScriptEngineDebugger</a>.</p>
<!-- @@@~QScriptEngineDebugger -->
<!-- $$$action[overload1]$$$actionDebuggerAction -->
<h3 class="fn"><a name="action"></a><span class="type"><a href="qaction.html">QAction</a></span> * QScriptEngineDebugger::<span class="name">action</span> ( <span class="type"><a href="qscriptenginedebugger.html#DebuggerAction-enum">DebuggerAction</a></span> <i>action</i> ) const</h3>
<p>Returns a pointer to the specified <i>action</i>. The actions available are given by the <a href="qscriptenginedebugger.html#DebuggerAction-enum">DebuggerAction</a> enum.</p>
<p>With this function, you can add the actions to your own widgets, toolbars, and menus. It is also convenient if you, for example, wish to spice things up with your own groovy icons. The code example below shows how to add actions to a <a href="qtoolbar.html">QToolBar</a>.</p>
<pre class="cpp">     <span class="type"><a href="qaction.html">QAction</a></span> <span class="operator">*</span>continueAction <span class="operator">=</span> debugger<span class="operator">-</span><span class="operator">&gt;</span>action(<span class="type"><a href="qscriptenginedebugger.html">QScriptEngineDebugger</a></span><span class="operator">::</span>ContinueAction);
     <span class="type"><a href="qaction.html">QAction</a></span> <span class="operator">*</span>stepOverAction <span class="operator">=</span> debugger<span class="operator">-</span><span class="operator">&gt;</span>action(<span class="type"><a href="qscriptenginedebugger.html">QScriptEngineDebugger</a></span><span class="operator">::</span>StepOverAction);
     <span class="type"><a href="qaction.html">QAction</a></span> <span class="operator">*</span>stepIntoAction <span class="operator">=</span> debugger<span class="operator">-</span><span class="operator">&gt;</span>action(<span class="type"><a href="qscriptenginedebugger.html">QScriptEngineDebugger</a></span><span class="operator">::</span>StepIntoAction);

     <span class="type"><a href="qtoolbar.html">QToolBar</a></span> <span class="operator">*</span>toolBar <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qtoolbar.html">QToolBar</a></span>;
     toolBar<span class="operator">-</span><span class="operator">&gt;</span>addAction(continueAction);</pre>
<p>Note that <a href="qscriptenginedebugger.html">QScriptEngineDebugger</a> has already added the actions to its <a href="qscriptenginedebugger.html#DebuggerWidget-enum">standard widgets</a> and <a href="qscriptenginedebugger.html#standardWindow">standard window</a>.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#widget">widget</a>(), <a href="qscriptenginedebugger.html#createStandardMenu">createStandardMenu</a>(), <a href="qscriptenginedebugger.html#createStandardToolBar">createStandardToolBar</a>(), and <a href="qscriptenginedebugger.html#standardWindow">standardWindow</a>().</p>
<!-- @@@action -->
<!-- $$$attachTo[overload1]$$$attachToQScriptEngine* -->
<h3 class="fn"><a name="attachTo"></a><span class="type">void</span> QScriptEngineDebugger::<span class="name">attachTo</span> ( <span class="type"><a href="qscriptengine.html">QScriptEngine</a></span> * <i>engine</i> )</h3>
<p>Attaches to the given <i>engine</i>.</p>
<p>The debugger will install a custom agent (using <a href="qscriptengine.html#setAgent">QScriptEngine::setAgent</a>()) to monitor the engine. While the debugger is attached, you should not change the agent; however, if you do have to perform additional monitoring, you must set a proxy agent that forwards all events to the debugger's agent.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#detach">detach</a>().</p>
<!-- @@@attachTo -->
<!-- $$$autoShowStandardWindow[overload1]$$$autoShowStandardWindow -->
<h3 class="fn"><a name="autoShowStandardWindow"></a><span class="type">bool</span> QScriptEngineDebugger::<span class="name">autoShowStandardWindow</span> () const</h3>
<p>Returns whether the standard debugger window is automatically shown when evaluation is suspended.</p>
<p>The default is true.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#setAutoShowStandardWindow">setAutoShowStandardWindow</a>().</p>
<!-- @@@autoShowStandardWindow -->
<!-- $$$createStandardMenu[overload1]$$$createStandardMenuQWidget* -->
<h3 class="fn"><a name="createStandardMenu"></a><span class="type"><a href="qmenu.html">QMenu</a></span> * QScriptEngineDebugger::<span class="name">createStandardMenu</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>parent</i> = 0 )</h3>
<p>Creates a standard debugger menu with the given <i>parent</i>. Returns the new menu object.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#createStandardToolBar">createStandardToolBar</a>().</p>
<!-- @@@createStandardMenu -->
<!-- $$$createStandardToolBar[overload1]$$$createStandardToolBarQWidget* -->
<h3 class="fn"><a name="createStandardToolBar"></a><span class="type"><a href="qtoolbar.html">QToolBar</a></span> * QScriptEngineDebugger::<span class="name">createStandardToolBar</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>parent</i> = 0 )</h3>
<p>Creates a standard debugger toolbar with the given <i>parent</i>. Returns the new toolbar object.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#createStandardMenu">createStandardMenu</a>().</p>
<!-- @@@createStandardToolBar -->
<!-- $$$detach[overload1]$$$detach -->
<h3 class="fn"><a name="detach"></a><span class="type">void</span> QScriptEngineDebugger::<span class="name">detach</span> ()</h3>
<p>Detaches from the current script engine, if any.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#attachTo">attachTo</a>().</p>
<!-- @@@detach -->
<!-- $$$evaluationResumed[overload1]$$$evaluationResumed -->
<h3 class="fn"><a name="evaluationResumed"></a><span class="type">void</span> QScriptEngineDebugger::<span class="name">evaluationResumed</span> ()<tt> [signal]</tt></h3>
<p>This signal is emitted when the debugger has resumed script evaluation (e.g&#x2e; the user gave the &quot;continue&quot; command).</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#evaluationSuspended">evaluationSuspended</a>().</p>
<!-- @@@evaluationResumed -->
<!-- $$$evaluationSuspended[overload1]$$$evaluationSuspended -->
<h3 class="fn"><a name="evaluationSuspended"></a><span class="type">void</span> QScriptEngineDebugger::<span class="name">evaluationSuspended</span> ()<tt> [signal]</tt></h3>
<p>This signal is emitted when the debugger has suspended script evaluation for whatever reason (e.g&#x2e; due to an uncaught script exception, or due to a breakpoint being triggered).</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#evaluationResumed">evaluationResumed</a>().</p>
<!-- @@@evaluationSuspended -->
<!-- $$$setAutoShowStandardWindow[overload1]$$$setAutoShowStandardWindowbool -->
<h3 class="fn"><a name="setAutoShowStandardWindow"></a><span class="type">void</span> QScriptEngineDebugger::<span class="name">setAutoShowStandardWindow</span> ( <span class="type">bool</span> <i>autoShow</i> )</h3>
<p>Sets whether the standard debugger window is automatically shown when evaluation is suspended. If <i>autoShow</i> is true, the window will be automatically shown, otherwise it will not.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#autoShowStandardWindow">autoShowStandardWindow</a>().</p>
<!-- @@@setAutoShowStandardWindow -->
<!-- $$$standardWindow[overload1]$$$standardWindow -->
<h3 class="fn"><a name="standardWindow"></a><span class="type"><a href="qmainwindow.html">QMainWindow</a></span> * QScriptEngineDebugger::<span class="name">standardWindow</span> () const</h3>
<p>Returns a main window with a standard configuration of the debugger's components.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#createStandardMenu">createStandardMenu</a>() and <a href="qscriptenginedebugger.html#createStandardToolBar">createStandardToolBar</a>().</p>
<!-- @@@standardWindow -->
<!-- $$$state[overload1]$$$state -->
<h3 class="fn"><a name="state"></a><span class="type"><a href="qscriptenginedebugger.html#DebuggerState-enum">DebuggerState</a></span> QScriptEngineDebugger::<span class="name">state</span> () const</h3>
<p>Returns the current state of the debugger.</p>
<p>This function was introduced in Qt 4.6.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#evaluationResumed">evaluationResumed</a>() and <a href="qscriptenginedebugger.html#evaluationSuspended">evaluationSuspended</a>().</p>
<!-- @@@state -->
<!-- $$$widget[overload1]$$$widgetDebuggerWidget -->
<h3 class="fn"><a name="widget"></a><span class="type"><a href="qwidget.html">QWidget</a></span> * QScriptEngineDebugger::<span class="name">widget</span> ( <span class="type"><a href="qscriptenginedebugger.html#DebuggerWidget-enum">DebuggerWidget</a></span> <i>widget</i> ) const</h3>
<p>Returns a pointer to the instance of the specified standard <i>widget</i>. The widgets available are defined by the <a href="qscriptenginedebugger.html#DebuggerWidget-enum">DebuggerWidget</a> enum.</p>
<p>A main window containing all widgets is returned by <a href="qscriptenginedebugger.html#standardWindow">standardWindow</a>(). If you do not want to use this window, you can fetch the individual widgets with this function. For instance, the code example below shows how to set up a layout containing a <a href="qscriptenginedebugger.html#DebuggerWidget-enum">code window</a> and a <a href="qscriptenginedebugger.html#DebuggerWidget-enum">stack widget</a>.</p>
<pre class="cpp">     <span class="type"><a href="qwidget.html">QWidget</a></span> <span class="operator">*</span>codeWindow <span class="operator">=</span> debugger<span class="operator">-</span><span class="operator">&gt;</span>widget(<span class="type"><a href="qscriptenginedebugger.html">QScriptEngineDebugger</a></span><span class="operator">::</span>CodeWidget);
     <span class="type"><a href="qwidget.html">QWidget</a></span> <span class="operator">*</span>stackWidget <span class="operator">=</span> debugger<span class="operator">-</span><span class="operator">&gt;</span>widget(<span class="type"><a href="qscriptenginedebugger.html">QScriptEngineDebugger</a></span><span class="operator">::</span>StackWidget);

     <span class="type"><a href="qlayout.html">QLayout</a></span> <span class="operator">*</span>layout <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qhboxlayout.html">QHBoxLayout</a></span>;
     layout<span class="operator">-</span><span class="operator">&gt;</span>addWidget(codeWindow);
     layout<span class="operator">-</span><span class="operator">&gt;</span>addWidget(stackWidget);</pre>
<p>Note that you need to set <a href="qscriptenginedebugger.html#setAutoShowStandardWindow">setAutoShowStandardWindow</a>() to false; if not, the standard window will be shown regardless.</p>
<p><b>See also </b><a href="qscriptenginedebugger.html#action">action</a>(), <a href="qscriptenginedebugger.html#standardWindow">standardWindow</a>(), and <a href="qscriptenginedebugger.html#setAutoShowStandardWindow">setAutoShowStandardWindow</a>().</p>
<!-- @@@widget -->
</div>
      </div>
    </div>
    </div> 
    <div class="ft">
      <span></span>
    </div>
  </div> 
  <div class="footer">
    <p>
      <acronym title="Copyright">&copy;</acronym> 2015 The Qt Company Ltd.
      Documentation contributions included herein are the copyrights of
      their respective owners.</p>
    <br />
    <p>
      The documentation provided herein is licensed under the terms of the
      <a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation
      License version 1.3</a> as published by the Free Software Foundation.</p>
    <p>
      Documentation sources may be obtained from <a href="http://www.qt-project.org">
      www.qt-project.org</a>.</p>
    <br />
    <p>
      Qt and respective logos are trademarks of The Qt Company Ltd 
      in Finland and/or other countries worldwide. All other trademarks are property
      of their respective owners. <a title="Privacy Policy"
      href="http://en.gitorious.org/privacy_policy/">Privacy Policy</a></p>
  </div>

  <script src="scripts/functions.js" type="text/javascript"></script>
</body>
</html>