Sophie

Sophie

distrib > Mageia > 7 > x86_64 > by-pkgid > 1dd17e0d683ef79b4bb6872bbf359d7f > files > 7140

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" />
<!-- qwindowsystem_qws.cpp -->
  <title>Qt 4.8: QWSServer 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="qtgui.html">QtGui</a></li>
<li>QWSServer</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="#static-public-members">Static Public Members</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
<li class="level2"><a href="#client-administration">Client Administration</a></li>
<li class="level2"><a href="#mouse-handling">Mouse Handling</a></li>
<li class="level2"><a href="#keyboard-handling">Keyboard Handling</a></li>
<li class="level2"><a href="#display-handling">Display Handling</a></li>
<li class="level2"><a href="#input-method-handling">Input Method Handling</a></li>
</ul>
</div>
<h1 class="title">QWSServer Class Reference</h1>
<!-- $$$QWSServer-brief -->
<p>The QWSServer class encapsulates a server process in Qt for Embedded Linux. <a href="#details">More...</a></p>
<!-- @@@QWSServer -->
<pre class="cpp"> <span class="preprocessor">#include &lt;QWSServer&gt;</span></pre><p><b>Inherits: </b><a href="qobject.html">QObject</a>.</p>
<ul>
<li><a href="qwsserver-members.html">List of all members, including inherited members</a></li>
<li><a href="qwsserver-obsolete.html">Obsolete members</a></li>
<li><a href="qwsserver-qt3.html">Qt 3 support members</a></li>
</ul>
<a name="public-types"></a>
<h2>Public Types</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> class </td><td class="memItemRight bottomAlign"><b><a href="qwsserver-keyboardfilter.html">KeyboardFilter</a></b></td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#IMMouse-enum">IMMouse</a></b> { MousePress, MouseRelease, MouseMove, MouseOutside }</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#WindowEvent-enum">WindowEvent</a></b> { Create, Destroy, Hide, Show, ..., Name }</td></tr>
</table>
<a name="public-functions"></a>
<h2>Public Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> const QBrush &amp; </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#backgroundBrush">backgroundBrush</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> const QList&lt;QWSWindow *&gt; &amp; </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#clientWindows">clientWindows</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#closeKeyboard">closeKeyboard</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#closeMouse">closeMouse</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#enablePainting">enablePainting</a></b> ( bool <i>enable</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#openKeyboard">openKeyboard</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#openMouse">openMouse</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#refresh">refresh</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#refresh-2">refresh</a></b> ( QRegion &amp; <i>region</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#resumeMouse">resumeMouse</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#sendIMEvent">sendIMEvent</a></b> ( const QInputMethodEvent * <i>event</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#sendIMQuery">sendIMQuery</a></b> ( int <i>property</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#suspendMouse">suspendMouse</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWSWindow * </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#windowAt">windowAt</a></b> ( const QPoint &amp; <i>position</i> )</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="qwsserver.html#markedText">markedText</a></b> ( const QString &amp; <i>selection</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#newChannel">newChannel</a></b> ( const QString &amp; <i>channel</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#removedChannel">removedChannel</a></b> ( const QString &amp; <i>channel</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#windowEvent">windowEvent</a></b> ( QWSWindow * <i>window</i>, QWSServer::WindowEvent <i>eventType</i> )</td></tr>
</table>
<ul>
<li class="fn">1 signal inherited from <a href="qobject.html#signals">QObject</a></li>
</ul>
<a name="static-public-members"></a>
<h2>Static Public Members</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#addKeyboardFilter">addKeyboardFilter</a></b> ( KeyboardFilter * <i>filter</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWSServer * </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#instance">instance</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#isCursorVisible">isCursorVisible</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWSKeyboardHandler * </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#keyboardHandler">keyboardHandler</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWSMouseHandler * </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#mouseHandler">mouseHandler</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> const QList&lt;QWSMouseHandler *&gt; &amp; </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#mouseHandlers">mouseHandlers</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#processKeyEvent">processKeyEvent</a></b> ( int <i>unicode</i>, int <i>keycode</i>, Qt::KeyboardModifiers <i>modifiers</i>, bool <i>isPress</i>, bool <i>autoRepeat</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#removeKeyboardFilter">removeKeyboardFilter</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#screenSaverActivate">screenSaverActivate</a></b> ( bool <i>activate</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#screenSaverActive">screenSaverActive</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#sendKeyEvent">sendKeyEvent</a></b> ( int <i>unicode</i>, int <i>keycode</i>, Qt::KeyboardModifiers <i>modifiers</i>, bool <i>isPress</i>, bool <i>autoRepeat</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setBackground">setBackground</a></b> ( const QBrush &amp; <i>brush</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setCurrentInputMethod">setCurrentInputMethod</a></b> ( QWSInputMethod * <i>method</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setCursorVisible">setCursorVisible</a></b> ( bool <i>visible</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setDefaultKeyboard">setDefaultKeyboard</a></b> ( const char * <i>keyboardDriver</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setDefaultMouse">setDefaultMouse</a></b> ( const char * <i>mouseDriver</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setKeyboardHandler">setKeyboardHandler</a></b> ( QWSKeyboardHandler * <i>driver</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setMaxWindowRect">setMaxWindowRect</a></b> ( const QRect &amp; <i>rectangle</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setMouseHandler">setMouseHandler</a></b> ( QWSMouseHandler * <i>driver</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setScreenSaver">setScreenSaver</a></b> ( QWSScreenSaver * <i>screenSaver</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setScreenSaverBlockLevel">setScreenSaverBlockLevel</a></b> ( int <i>eventBlockLevel</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setScreenSaverInterval">setScreenSaverInterval</a></b> ( int <i>milliseconds</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwsserver.html#setScreenSaverIntervals">setScreenSaverIntervals</a></b> ( int * <i>intervals</i> )</td></tr>
</table>
<ul>
<li class="fn">7 static public members inherited from <a href="qobject.html#static-public-members">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">8 protected functions inherited from <a href="qobject.html#protected-functions">QObject</a></li>
</ul>
<a name="details"></a>
<!-- $$$QWSServer-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The QWSServer class encapsulates a server process in Qt for Embedded Linux.</p>
<p>When you run a <a href="qt-embedded-linux.html">Qt for Embedded Linux</a> application, it either runs as a server or connects to an existing server. The server and client processes have different responsibilities: The client process performs all application specific operations. The server process is responsible for managing the clients as well as taking care of the pointer handling, character input, and screen output. In addition, the server provides functionality to handle input methods.</p>
<p>In <a href="qt-embedded-linux.html">Qt for Embedded Linux</a>, all system generated events are passed to the server application which then propagates the event to the appropriate client. See the <a href="qt-embedded-architecture.html">Qt for Embedded Linux Architecture</a> documentation for details.</p>
<p>Note that this class is instantiated by <a href="qapplication.html">QApplication</a> for <a href="qt-embedded-linux.html">Qt for Embedded Linux</a> server processes; you should never construct this class yourself. Use the <a href="qwsserver.html#instance">instance</a>() function to retrieve a pointer to the server object.</p>
<p>Note that the static functions of the QWSServer class can only be used in the server process.</p>
<a name="client-administration"></a>
<h3>Client Administration</h3>
<p>As applications add and remove windows, the server process maintains information about each window. In <a href="qt-embedded-linux.html">Qt for Embedded Linux</a>, top-level windows are encapsulated as <a href="qwswindow.html">QWSWindow</a> objects. Each window can tell which client that owns it through its <a href="qwswindow.html#client">QWSWindow::client</a>() function. Use the <a href="qwsserver.html#clientWindows">clientWindows</a>() function to retrieve a list of the current top-level windows. Given a particular position on the display, the window containing it can be retrieved using the <a href="qwsserver.html#windowAt">windowAt</a>() function.</p>
<p>QWSServer also provides the <a href="qwsserver.html#windowEvent">windowEvent</a>() signal which is emitted whenever something happens to a top level window; the <a href="qwsserver.html#WindowEvent-enum">WindowEvent</a> enum describes the various types of events that the signal recognizes. In addition, the server class provides the <a href="qwsserver.html#markedText">markedText</a>() signal which is emitted whenever some text has been selected in any of the windows, passing the selection as parameter.</p>
<p>The <a href="qcopchannel.html">QCopChannel</a> class and the QCOP communication protocol enable transfer of messages between clients. QWSServer provides the <a href="qwsserver.html#newChannel">newChannel</a>() and <a href="qwsserver.html#removedChannel">removedChannel</a>() signals that is emitted whenever a new <a href="qcopchannel.html">QCopChannel</a> object is created or destroyed, respectively.</p>
<p>See also: <a href="qwswindow.html">QWSWindow</a>, <a href="qwsclient.html">QWSClient</a> and <a href="qcopchannel.html">QCopChannel</a>.</p>
<a name="mouse-handling"></a>
<h3>Mouse Handling</h3>
<p>The mouse driver (represented by an instance of the <a href="qwsmousehandler.html">QWSMouseHandler</a> class) is loaded by the server application when it starts running, using Qt's <a href="plugins-howto.html">plugin system</a>. A mouse driver receives mouse events from the device and encapsulates each event with an instance of the <a href="qwsevent.html">QWSEvent</a> class which it then passes to the server.</p>
<p>The <a href="qwsserver.html#openMouse">openMouse</a>() function opens the mouse devices specified by the <a href="qt-embedded-envvars.html#qws-mouse-proto">QWS_MOUSE_PROTO</a> environment variable, and the <a href="qwsserver.html#setMouseHandler">setMouseHandler</a>() functions sets the primary mouse driver. Alternatively, the static <a href="qwsserver.html#setDefaultMouse">setDefaultMouse</a>() function provides means of specifying the mouse driver to use if the <a href="qt-embedded-envvars.html#qws-mouse-proto">QWS_MOUSE_PROTO</a> variable is not defined (note that the default is otherwise platform dependent). The primary mouse driver can be retrieved using the static <a href="qwsserver.html#mouseHandler">mouseHandler</a>() function. Use the <a href="qwsserver.html#closeMouse">closeMouse</a>() function to delete the mouse drivers.</p>
<p>In addition, the QWSServer class can control the flow of mouse input using the <a href="qwsserver.html#suspendMouse">suspendMouse</a>() and <a href="qwsserver.html#resumeMouse">resumeMouse</a>() functions.</p>
<p>See also: <a href="qwsmousehandler.html">QWSMouseHandler</a> and <a href="qt-embedded-pointer.html">Qt for Embedded Linux Pointer Handling</a>.</p>
<a name="keyboard-handling"></a>
<h3>Keyboard Handling</h3>
<p>The keyboard driver (represented by an instance of the <a href="qwskeyboardhandler.html">QWSKeyboardHandler</a> class) is loaded by the server application when it starts running, using Qt's <a href="plugins-howto.html">plugin system</a>. A keyboard driver receives keyboard events from the device and encapsulates each event with an instance of the <a href="qwsevent.html">QWSEvent</a> class which it then passes to the server.</p>
<p>The <a href="qwsserver.html#openKeyboard">openKeyboard</a>() function opens the keyboard devices specified by the <a href="qt-embedded-envvars.html#qws-keyboard">QWS_KEYBOARD</a> environment variable, and the <a href="qwsserver.html#setKeyboardHandler">setKeyboardHandler</a>() functions sets the primary keyboard driver. Alternatively, the static <a href="qwsserver.html#setDefaultKeyboard">setDefaultKeyboard</a>() function provides means of specifying the keyboard driver to use if the <a href="qt-embedded-envvars.html#qws-keyboard">QWS_KEYBOARD</a> variable is not defined (note again that the default is otherwise platform dependent). The primary keyboard driver can be retrieved using the static <a href="qwsserver.html#keyboardHandler">keyboardHandler</a>() function. Use the <a href="qwsserver.html#closeKeyboard">closeKeyboard</a>() function to delete the keyboard drivers.</p>
<p>In addition, the QWSServer class can handle key events from both physical and virtual keyboards using the <a href="qwsserver.html#processKeyEvent">processKeyEvent</a>() and <a href="qwsserver.html#sendKeyEvent">sendKeyEvent</a>() functions, respectively. Use the <a href="qwsserver.html#addKeyboardFilter">addKeyboardFilter</a>() function to filter the key events from physical keyboard drivers, the most recently added filter can be removed and deleted using the <a href="qwsserver.html#removeKeyboardFilter">removeKeyboardFilter</a>() function.</p>
<p>See also: <a href="qwskeyboardhandler.html">QWSKeyboardHandler</a> and <a href="qt-embedded-charinput.html">Qt for Embedded Linux Character Input</a>.</p>
<a name="display-handling"></a>
<h3>Display Handling</h3>
<p>When a screen update is required, the server runs through all the top-level windows that intersect with the region that is about to be updated, and ensures that the associated clients have updated their memory buffer. Then the server uses the screen driver (represented by an instance of the <a href="qscreen.html">QScreen</a> class) to copy the content of the memory to the screen.</p>
<p>In addition, the QWSServer class provides some means of managing the screen output: Use the <a href="qwsserver.html#refresh">refresh</a>() function to refresh the entire display, or alternatively a specified region of it. The <a href="qwsserver.html#enablePainting">enablePainting</a>() function can be used to disable (and enable) painting onto the screen. QWSServer also provide the <a href="qwsserver.html#setMaxWindowRect">setMaxWindowRect</a>() function restricting the area of the screen which <a href="qt-embedded-linux.html">Qt for Embedded Linux</a> applications will consider to be the maximum area to use for windows. To set the brush used as the background in the absence of obscuring windows, QWSServer provides the static <a href="qwsserver.html#setBackground">setBackground</a>() function. The corresponding <a href="qwsserver.html#backgroundBrush">backgroundBrush</a>() function returns the currently set brush.</p>
<p>QWSServer also controls the screen saver: Use the <a href="qwsserver.html#setScreenSaver">setScreenSaver</a>() to install a custom screen saver derived from the <a href="qwsscreensaver.html">QWSScreenSaver</a> class. Once installed, the screensaver can be activated using the <a href="qwsserver.html#screenSaverActivate">screenSaverActivate</a>() function, and the <a href="qwsserver.html#screenSaverActive">screenSaverActive</a>() function returns its current status. Use the <a href="qwsserver.html#setScreenSaverInterval">setScreenSaverInterval</a>() function to specify the timeout interval. <a href="qt-embedded-linux.html">Qt for Embedded Linux</a> also supports multilevel screen saving, use the <a href="qwsserver.html#setScreenSaverIntervals">setScreenSaverIntervals</a>() function to specify the various levels and their timeout intervals.</p>
<p>Finally, the QWSServer class controls the cursor's appearance, i.e&#x2e;, use the <a href="qwsserver.html#setCursorVisible">setCursorVisible</a>() function to hide or show the cursor, and the <a href="qwsserver.html#isCursorVisible">isCursorVisible</a>() function to determine whether the cursor is visible on the display or not.</p>
<p>See also: <a href="qscreen.html">QScreen</a> and <a href="qt-embedded-displaymanagement.html">Qt for Embedded Linux Display Management</a>.</p>
<a name="input-method-handling"></a>
<h3>Input Method Handling</h3>
<p>Whenever the server receives an event, it queries its stack of top-level windows to find the window containing the event's position (each window can identify the client application that created it). Then the server forwards the event to the appropriate client. If an input method is installed, it is used as a filter between the server and the client application.</p>
<p>Derive from the <a href="qwsinputmethod.html">QWSInputMethod</a> class to create custom input methods, and use the server's <a href="qwsserver.html#setCurrentInputMethod">setCurrentInputMethod</a>() function to install it. Use the <a href="qwsserver.html#sendIMEvent">sendIMEvent</a>() and <a href="qwsserver.html#sendIMQuery">sendIMQuery</a>() functions to send input method events and queries.</p>
<p>QWSServer provides the <a href="qwsserver.html#IMMouse-enum">IMMouse</a> enum describing the various mouse events recognized by the <a href="qwsinputmethod.html#mouseHandler">QWSInputMethod::mouseHandler</a>() function. The latter function allows subclasses of <a href="qwsinputmethod.html">QWSInputMethod</a> to handle mouse events within the preedit text.</p>
</div>
<p><b>See also </b><a href="qwsinputmethod.html">QWSInputMethod</a>.</p>
<!-- @@@QWSServer -->
<div class="types">
<h2>Member Type Documentation</h2>
<!-- $$$IMMouse$$$MousePress$$$MouseRelease$$$MouseMove$$$MouseOutside -->
<h3 class="fn"><a name="IMMouse-enum"></a>enum QWSServer::<span class="name">IMMouse</span></h3>
<p>This enum describes the various types of mouse events recognized by the <a href="qwsinputmethod.html#mouseHandler">QWSInputMethod::mouseHandler</a>() function.</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>QWSServer::MousePress</tt></td><td class="topAlign"><tt>0</tt></td><td class="topAlign">An event generated by pressing a mouse button.</td></tr>
<tr><td class="topAlign"><tt>QWSServer::MouseRelease</tt></td><td class="topAlign"><tt>1</tt></td><td class="topAlign">An event generated by relasing a mouse button.</td></tr>
<tr><td class="topAlign"><tt>QWSServer::MouseMove</tt></td><td class="topAlign"><tt>2</tt></td><td class="topAlign">An event generated by moving the mouse cursor.</td></tr>
<tr><td class="topAlign"><tt>QWSServer::MouseOutside</tt></td><td class="topAlign"><tt>3</tt></td><td class="topAlign">This value is only reserved, i.e&#x2e;, it is not used in current implementations.</td></tr>
</table>
<p><b>See also </b><a href="qwsinputmethod.html">QWSInputMethod</a> and <a href="qwsserver.html#setCurrentInputMethod">setCurrentInputMethod</a>().</p>
<!-- @@@IMMouse -->
<!-- $$$WindowEvent$$$Create$$$Destroy$$$Hide$$$Show$$$Raise$$$Lower$$$Geometry$$$Active$$$Name -->
<h3 class="fn"><a name="WindowEvent-enum"></a>enum QWSServer::<span class="name">WindowEvent</span></h3>
<p>This enum specifies the various events that can occur in a top-level window.</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>QWSServer::Create</tt></td><td class="topAlign"><tt>0x0001</tt></td><td class="topAlign">A new window has been created (by the <a href="qwidget.html">QWidget</a> constructor).</td></tr>
<tr><td class="topAlign"><tt>QWSServer::Destroy</tt></td><td class="topAlign"><tt>0x0002</tt></td><td class="topAlign">The window has been closed and deleted (by the <a href="qwidget.html">QWidget</a> destructor).</td></tr>
<tr><td class="topAlign"><tt>QWSServer::Hide</tt></td><td class="topAlign"><tt>0x0004</tt></td><td class="topAlign">The window has been hidden using the <a href="qwidget.html#hide">QWidget::hide</a>() function.</td></tr>
<tr><td class="topAlign"><tt>QWSServer::Show</tt></td><td class="topAlign"><tt>0x0008</tt></td><td class="topAlign">The window has been shown using the <a href="qwidget.html#show">QWidget::show</a>() function or similar.</td></tr>
<tr><td class="topAlign"><tt>QWSServer::Raise</tt></td><td class="topAlign"><tt>0x0010</tt></td><td class="topAlign">The window has been raised to the top of the desktop.</td></tr>
<tr><td class="topAlign"><tt>QWSServer::Lower</tt></td><td class="topAlign"><tt>0x0020</tt></td><td class="topAlign">The window has been lowered.</td></tr>
<tr><td class="topAlign"><tt>QWSServer::Geometry</tt></td><td class="topAlign"><tt>0x0040</tt></td><td class="topAlign">The window has changed size or position.</td></tr>
<tr><td class="topAlign"><tt>QWSServer::Active</tt></td><td class="topAlign"><tt>0x0080</tt></td><td class="topAlign">The window has become the active window (i.e&#x2e;, it has keyboard focus).</td></tr>
<tr><td class="topAlign"><tt>QWSServer::Name</tt></td><td class="topAlign"><tt>0x0100</tt></td><td class="topAlign">The window has been named.</td></tr>
</table>
<p><b>See also </b><a href="qwsserver.html#windowEvent">windowEvent</a>().</p>
<!-- @@@WindowEvent -->
</div>
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$addKeyboardFilter[overload1]$$$addKeyboardFilterKeyboardFilter* -->
<h3 class="fn"><a name="addKeyboardFilter"></a><span class="type">void</span> QWSServer::<span class="name">addKeyboardFilter</span> ( <span class="type"><a href="qwsserver-keyboardfilter.html">KeyboardFilter</a></span> * <i>filter</i> )<tt> [static]</tt></h3>
<p>Activates the given keyboard <i>filter</i> all key events generated by physical keyboard drivers (i.e&#x2e;, events sent using the <a href="qwsserver.html#processKeyEvent">processKeyEvent</a>() function).</p>
<p>Note that the filter is not invoked for keys generated by <i>virtual</i> keyboard drivers (i.e&#x2e;, events sent using the <a href="qwsserver.html#sendKeyEvent">sendKeyEvent</a>() function).</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#removeKeyboardFilter">removeKeyboardFilter</a>().</p>
<!-- @@@addKeyboardFilter -->
<!-- $$$backgroundBrush[overload1]$$$backgroundBrush -->
<h3 class="fn"><a name="backgroundBrush"></a>const <span class="type"><a href="qbrush.html">QBrush</a></span> &amp; QWSServer::<span class="name">backgroundBrush</span> () const</h3>
<p>Returns the brush used as background in the absence of obscuring windows.</p>
<p><b>See also </b><a href="qwsserver.html#setBackground">setBackground</a>().</p>
<!-- @@@backgroundBrush -->
<!-- $$$clientWindows[overload1]$$$clientWindows -->
<h3 class="fn"><a name="clientWindows"></a>const <span class="type"><a href="qlist.html">QList</a></span>&lt;<span class="type"><a href="qwswindow.html">QWSWindow</a></span> *&gt; &amp; QWSServer::<span class="name">clientWindows</span> ()</h3>
<p>Returns the list of current top-level windows.</p>
<p>Note that the collection of top-level windows changes as applications add and remove widgets so it should not be stored for future use. The windows are sorted in stacking order from top-most to bottom-most.</p>
<p>Use the <a href="qwswindow.html#client">QWSWindow::client</a>() function to retrieve the client application that owns a given window.</p>
<p><b>See also </b><a href="qwsserver.html#windowAt">windowAt</a>() and <a href="qwsserver.html#instance">instance</a>().</p>
<!-- @@@clientWindows -->
<!-- $$$closeKeyboard[overload1]$$$closeKeyboard -->
<h3 class="fn"><a name="closeKeyboard"></a><span class="type">void</span> QWSServer::<span class="name">closeKeyboard</span> ()</h3>
<p>Closes all the keyboard devices (specified by the <a href="qt-embedded-envvars.html#qws-keyboard">QWS_KEYBOARD</a> environment variable) by deleting the associated keyboard drivers.</p>
<p><b>See also </b><a href="qwsserver.html#openKeyboard">openKeyboard</a>() and <a href="qwsserver.html#keyboardHandler">keyboardHandler</a>().</p>
<!-- @@@closeKeyboard -->
<!-- $$$closeMouse[overload1]$$$closeMouse -->
<h3 class="fn"><a name="closeMouse"></a><span class="type">void</span> QWSServer::<span class="name">closeMouse</span> ()</h3>
<p>Closes all pointer devices (specified by the <a href="qt-embedded-envvars.html#qws-mouse-proto">QWS_MOUSE_PROTO</a> environment variable) by deleting the associated mouse drivers.</p>
<p><b>See also </b><a href="qwsserver.html#openMouse">openMouse</a>() and <a href="qwsserver.html#mouseHandler">mouseHandler</a>().</p>
<!-- @@@closeMouse -->
<!-- $$$enablePainting[overload1]$$$enablePaintingbool -->
<h3 class="fn"><a name="enablePainting"></a><span class="type">void</span> QWSServer::<span class="name">enablePainting</span> ( <span class="type">bool</span> <i>enable</i> )</h3>
<p>Enables painting onto the screen if <i>enable</i> is true; otherwise painting is disabled.</p>
<p><b>See also </b><a href="qt-embedded-architecture.html#drawing-on-screen">Qt for Embedded Linux Architecture</a>.</p>
<!-- @@@enablePainting -->
<!-- $$$instance[overload1]$$$instance -->
<h3 class="fn"><a name="instance"></a><span class="type">QWSServer</span> * QWSServer::<span class="name">instance</span> ()<tt> [static]</tt></h3>
<p>Returns a pointer to the server instance.</p>
<p>Note that the pointer will be 0 if the application is not the server, i.e&#x2e;, if the <a href="qapplication.html#type">QApplication::type</a>() function doesn't return <a href="qapplication.html#Type-enum">QApplication::GuiServer</a>.</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qwsserver.html#clientWindows">clientWindows</a>() and <a href="qwsserver.html#windowAt">windowAt</a>().</p>
<!-- @@@instance -->
<!-- $$$isCursorVisible[overload1]$$$isCursorVisible -->
<h3 class="fn"><a name="isCursorVisible"></a><span class="type">bool</span> QWSServer::<span class="name">isCursorVisible</span> ()<tt> [static]</tt></h3>
<p>Returns true if the cursor is visible; otherwise returns false.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#setCursorVisible">setCursorVisible</a>().</p>
<!-- @@@isCursorVisible -->
<!-- $$$keyboardHandler[overload1]$$$keyboardHandler -->
<h3 class="fn"><a name="keyboardHandler"></a><span class="type"><a href="qwskeyboardhandler.html">QWSKeyboardHandler</a></span> * QWSServer::<span class="name">keyboardHandler</span> ()<tt> [static]</tt></h3>
<p>Returns the primary keyboard driver.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#setKeyboardHandler">setKeyboardHandler</a>(), <a href="qwsserver.html#openKeyboard">openKeyboard</a>(), and <a href="qwsserver.html#closeKeyboard">closeKeyboard</a>().</p>
<!-- @@@keyboardHandler -->
<!-- $$$markedText[overload1]$$$markedTextconstQString& -->
<h3 class="fn"><a name="markedText"></a><span class="type">void</span> QWSServer::<span class="name">markedText</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>selection</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted whenever some text is selected in any of the running applications, passing the selected text in the <i>selection</i> parameter.</p>
<p><b>See also </b><a href="qwsserver.html#windowEvent">windowEvent</a>().</p>
<!-- @@@markedText -->
<!-- $$$mouseHandler[overload1]$$$mouseHandler -->
<h3 class="fn"><a name="mouseHandler"></a><span class="type"><a href="qwsmousehandler.html">QWSMouseHandler</a></span> * QWSServer::<span class="name">mouseHandler</span> ()<tt> [static]</tt></h3>
<p>Returns the primary mouse driver.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#setMouseHandler">setMouseHandler</a>(), <a href="qwsserver.html#openMouse">openMouse</a>(), and <a href="qwsserver.html#closeMouse">closeMouse</a>().</p>
<!-- @@@mouseHandler -->
<!-- $$$mouseHandlers[overload1]$$$mouseHandlers -->
<h3 class="fn"><a name="mouseHandlers"></a>const <span class="type"><a href="qlist.html">QList</a></span>&lt;<span class="type"><a href="qwsmousehandler.html">QWSMouseHandler</a></span> *&gt; &amp; QWSServer::<span class="name">mouseHandlers</span> ()<tt> [static]</tt></h3>
<p>Returns list of all mouse handlers</p>
<p>Note that this function can only be used in the server process.</p>
<p>This function was introduced in Qt 4.5.</p>
<p><b>See also </b><a href="qwsserver.html#mouseHandler">mouseHandler</a>(), <a href="qwsserver.html#setMouseHandler">setMouseHandler</a>(), <a href="qwsserver.html#openMouse">openMouse</a>(), and <a href="qwsserver.html#closeMouse">closeMouse</a>().</p>
<!-- @@@mouseHandlers -->
<!-- $$$newChannel[overload1]$$$newChannelconstQString& -->
<h3 class="fn"><a name="newChannel"></a><span class="type">void</span> QWSServer::<span class="name">newChannel</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>channel</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted whenever a new <a href="qcopchannel.html">QCopChannel</a> object is created, passing the channel's name in the <i>channel</i> parameter.</p>
<p><b>See also </b><a href="qwsserver.html#removedChannel">removedChannel</a>().</p>
<!-- @@@newChannel -->
<!-- $$$openKeyboard[overload1]$$$openKeyboard -->
<h3 class="fn"><a name="openKeyboard"></a><span class="type">void</span> QWSServer::<span class="name">openKeyboard</span> ()</h3>
<p>Opens the keyboard devices specified by the <a href="qt-embedded-envvars.html#qws-keyboard">QWS_KEYBOARD</a> environment variable.</p>
<p><b>See also </b><a href="qwsserver.html#closeKeyboard">closeKeyboard</a>() and <a href="qwsserver.html#keyboardHandler">keyboardHandler</a>().</p>
<!-- @@@openKeyboard -->
<!-- $$$openMouse[overload1]$$$openMouse -->
<h3 class="fn"><a name="openMouse"></a><span class="type">void</span> QWSServer::<span class="name">openMouse</span> ()</h3>
<p>Opens the mouse devices specified by the <a href="qt-embedded-envvars.html#qws-mouse-proto">QWS_MOUSE_PROTO</a> environment variable. Be advised that <a href="qwsserver.html#closeMouse">closeMouse</a>() is called first to delete all the existing mouse handlers. This behaviour could be the cause of problems if you were not expecting it.</p>
<p><b>See also </b><a href="qwsserver.html#closeMouse">closeMouse</a>() and <a href="qwsserver.html#mouseHandler">mouseHandler</a>().</p>
<!-- @@@openMouse -->
<!-- $$$processKeyEvent[overload1]$$$processKeyEventintintQt::KeyboardModifiersboolbool -->
<h3 class="fn"><a name="processKeyEvent"></a><span class="type">void</span> QWSServer::<span class="name">processKeyEvent</span> ( <span class="type">int</span> <i>unicode</i>, <span class="type">int</span> <i>keycode</i>, <span class="type"><a href="qt.html#KeyboardModifier-enum">Qt::KeyboardModifiers</a></span> <i>modifiers</i>, <span class="type">bool</span> <i>isPress</i>, <span class="type">bool</span> <i>autoRepeat</i> )<tt> [static]</tt></h3>
<p>Processes the given key event. The key is identified by its <i>unicode</i> value and the given <i>keycode</i>, <i>modifiers</i>, <i>isPress</i> and <i>autoRepeat</i> parameters.</p>
<p>The <i>keycode</i> parameter is the Qt keycode value as defined by the <a href="qt.html#Key-enum">Qt::Key</a> enum. The <i>modifiers</i> is an OR combination of <a href="qt.html#KeyboardModifier-enum">Qt::KeyboardModifier</a> values, indicating whether <b>Shift/Alt/Ctrl</b> keys are pressed. The <i>isPress</i> parameter is true if the event is a key press event and <i>autoRepeat</i> is true if the event is caused by an auto-repeat mechanism and not an actual key press.</p>
<p>This function is typically called internally by keyboard drivers. Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#sendKeyEvent">sendKeyEvent</a>() and <a href="qt-embedded-charinput.html">Qt for Embedded Linux Character Input</a>.</p>
<!-- @@@processKeyEvent -->
<!-- $$$refresh[overload1]$$$refresh -->
<h3 class="fn"><a name="refresh"></a><span class="type">void</span> QWSServer::<span class="name">refresh</span> ()</h3>
<p>Refreshes the display by making the screen driver update the entire display.</p>
<p><b>See also </b><a href="qscreen.html#exposeRegion">QScreen::exposeRegion</a>().</p>
<!-- @@@refresh -->
<!-- $$$refresh$$$refreshQRegion& -->
<h3 class="fn"><a name="refresh-2"></a><span class="type">void</span> QWSServer::<span class="name">refresh</span> ( <span class="type"><a href="qregion.html">QRegion</a></span> &amp; <i>region</i> )</h3>
<p>This is an overloaded function.</p>
<p>Refreshes the given <i>region</i> of the display.</p>
<!-- @@@refresh -->
<!-- $$$removeKeyboardFilter[overload1]$$$removeKeyboardFilter -->
<h3 class="fn"><a name="removeKeyboardFilter"></a><span class="type">void</span> QWSServer::<span class="name">removeKeyboardFilter</span> ()<tt> [static]</tt></h3>
<p>Removes and deletes the most recently added filter.</p>
<p>Note that the programmer is responsible for removing each added keyboard filter.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#addKeyboardFilter">addKeyboardFilter</a>().</p>
<!-- @@@removeKeyboardFilter -->
<!-- $$$removedChannel[overload1]$$$removedChannelconstQString& -->
<h3 class="fn"><a name="removedChannel"></a><span class="type">void</span> QWSServer::<span class="name">removedChannel</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>channel</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted immediately after the given the <a href="qcopchannel.html">QCopChannel</a> object specified by <i>channel</i>, is destroyed.</p>
<p>Note that a channel is not destroyed until all its listeners have been unregistered.</p>
<p><b>See also </b><a href="qwsserver.html#newChannel">newChannel</a>().</p>
<!-- @@@removedChannel -->
<!-- $$$resumeMouse[overload1]$$$resumeMouse -->
<h3 class="fn"><a name="resumeMouse"></a><span class="type">void</span> QWSServer::<span class="name">resumeMouse</span> ()</h3>
<p>Resumes pointer handling by reactivating all the mouse drivers registered by the <a href="qt-embedded-envvars.html#qws-mouse-proto">QWS_MOUSE_PROTO</a> environment variable.</p>
<p><b>See also </b><a href="qwsserver.html#suspendMouse">suspendMouse</a>() and <a href="qwsmousehandler.html#resume">QWSMouseHandler::resume</a>().</p>
<!-- @@@resumeMouse -->
<!-- $$$screenSaverActivate[overload1]$$$screenSaverActivatebool -->
<h3 class="fn"><a name="screenSaverActivate"></a><span class="type">void</span> QWSServer::<span class="name">screenSaverActivate</span> ( <span class="type">bool</span> <i>activate</i> )<tt> [static]</tt></h3>
<p>Activates the screen saver if <i>activate</i> is true; otherwise it is deactivated.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#screenSaverActive">screenSaverActive</a>() and <a href="qwsserver.html#setScreenSaver">setScreenSaver</a>().</p>
<!-- @@@screenSaverActivate -->
<!-- $$$screenSaverActive[overload1]$$$screenSaverActive -->
<h3 class="fn"><a name="screenSaverActive"></a><span class="type">bool</span> QWSServer::<span class="name">screenSaverActive</span> ()<tt> [static]</tt></h3>
<p>Returns true if the screen saver is active; otherwise returns false.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#screenSaverActivate">screenSaverActivate</a>().</p>
<!-- @@@screenSaverActive -->
<!-- $$$sendIMEvent[overload1]$$$sendIMEventconstQInputMethodEvent* -->
<h3 class="fn"><a name="sendIMEvent"></a><span class="type">void</span> QWSServer::<span class="name">sendIMEvent</span> ( const <span class="type"><a href="qinputmethodevent.html">QInputMethodEvent</a></span> * <i>event</i> )</h3>
<p>Sends the given input method <i>event</i>.</p>
<p>The <tt>QInputMethodEvent</tt> class is derived from <a href="qwsevent.html">QWSEvent</a>, i.e&#x2e;, it is a <a href="qwsevent.html">QWSEvent</a> object of the <a href="qwsevent.html#Type-enum">QWSEvent::IMEvent</a> type.</p>
<p>If there is a window actively composing the preedit string, the event is sent to that window. Otherwise, the event is sent to the window currently in focus.</p>
<p><b>See also </b><a href="qwsserver.html#sendIMQuery">sendIMQuery</a>() and <a href="qwsinputmethod.html#sendEvent">QWSInputMethod::sendEvent</a>().</p>
<!-- @@@sendIMEvent -->
<!-- $$$sendIMQuery[overload1]$$$sendIMQueryint -->
<h3 class="fn"><a name="sendIMQuery"></a><span class="type">void</span> QWSServer::<span class="name">sendIMQuery</span> ( <span class="type">int</span> <i>property</i> )</h3>
<p>Sends an input method query for the given <i>property</i>.</p>
<p>To receive responses to input method queries, the virtual <a href="qwsinputmethod.html#queryResponse">QWSInputMethod::queryResponse</a>() function must be reimplemented in a <a href="qwsinputmethod.html">QWSInputMethod</a> subclass that is activated using the <a href="qwsserver.html#setCurrentInputMethod">setCurrentInputMethod</a>() function.</p>
<p><b>See also </b><a href="qwsserver.html#sendIMEvent">sendIMEvent</a>() and <a href="qwsserver.html#setCurrentInputMethod">setCurrentInputMethod</a>().</p>
<!-- @@@sendIMQuery -->
<!-- $$$sendKeyEvent[overload1]$$$sendKeyEventintintQt::KeyboardModifiersboolbool -->
<h3 class="fn"><a name="sendKeyEvent"></a><span class="type">void</span> QWSServer::<span class="name">sendKeyEvent</span> ( <span class="type">int</span> <i>unicode</i>, <span class="type">int</span> <i>keycode</i>, <span class="type"><a href="qt.html#KeyboardModifier-enum">Qt::KeyboardModifiers</a></span> <i>modifiers</i>, <span class="type">bool</span> <i>isPress</i>, <span class="type">bool</span> <i>autoRepeat</i> )<tt> [static]</tt></h3>
<p>Sends the given key event. The key is identified by its <i>unicode</i> value and the given <i>keycode</i>, <i>modifiers</i>, <i>isPress</i> and <i>autoRepeat</i> parameters.</p>
<p>Use this function to send key events generated by &quot;virtual keyboards&quot; (note that the <a href="qwsserver.html#processKeyEvent">processKeyEvent</a>() function is impelemented using this function).</p>
<p>The <i>keycode</i> parameter is the Qt keycode value as defined by the <a href="qt.html#Key-enum">Qt::Key</a> enum. The <i>modifiers</i> is an OR combination of <a href="qt.html#KeyboardModifier-enum">Qt::KeyboardModifier</a> values, indicating whether <b>Shift/Alt/Ctrl</b> keys are pressed. The <i>isPress</i> parameter is true if the event is a key press event and <i>autoRepeat</i> is true if the event is caused by an auto-repeat mechanism and not an actual key press.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#processKeyEvent">processKeyEvent</a>() and <a href="qt-embedded-charinput.html">Qt for Embedded Linux Character Input</a>.</p>
<!-- @@@sendKeyEvent -->
<!-- $$$setBackground[overload1]$$$setBackgroundconstQBrush& -->
<h3 class="fn"><a name="setBackground"></a><span class="type">void</span> QWSServer::<span class="name">setBackground</span> ( const <span class="type"><a href="qbrush.html">QBrush</a></span> &amp; <i>brush</i> )<tt> [static]</tt></h3>
<p>Sets the brush used as background in the absence of obscuring windows, to be the given <i>brush</i>.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#backgroundBrush">backgroundBrush</a>().</p>
<!-- @@@setBackground -->
<!-- $$$setCurrentInputMethod[overload1]$$$setCurrentInputMethodQWSInputMethod* -->
<h3 class="fn"><a name="setCurrentInputMethod"></a><span class="type">void</span> QWSServer::<span class="name">setCurrentInputMethod</span> ( <span class="type"><a href="qwsinputmethod.html">QWSInputMethod</a></span> * <i>method</i> )<tt> [static]</tt></h3>
<p>Sets the current input method to be the given <i>method</i>.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#sendIMQuery">sendIMQuery</a>() and <a href="qwsserver.html#sendIMEvent">sendIMEvent</a>().</p>
<!-- @@@setCurrentInputMethod -->
<!-- $$$setCursorVisible[overload1]$$$setCursorVisiblebool -->
<h3 class="fn"><a name="setCursorVisible"></a><span class="type">void</span> QWSServer::<span class="name">setCursorVisible</span> ( <span class="type">bool</span> <i>visible</i> )<tt> [static]</tt></h3>
<p>Shows the cursor if <i>visible</i> is true: otherwise the cursor is hidden.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#isCursorVisible">isCursorVisible</a>().</p>
<!-- @@@setCursorVisible -->
<!-- $$$setDefaultKeyboard[overload1]$$$setDefaultKeyboardconstchar* -->
<h3 class="fn"><a name="setDefaultKeyboard"></a><span class="type">void</span> QWSServer::<span class="name">setDefaultKeyboard</span> ( const <span class="type">char</span> * <i>keyboardDriver</i> )<tt> [static]</tt></h3>
<p>Sets the keyboard driver that will be used if the <a href="qt-embedded-envvars.html#qws-keyboard">QWS_KEYBOARD</a> environment variable is not defined, to be the given <i>keyboardDriver</i>.</p>
<p>Note that the default is platform-dependent. This function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#setKeyboardHandler">setKeyboardHandler</a>() and <a href="qt-embedded-charinput.html">Qt for Embedded Linux Character Input</a>.</p>
<!-- @@@setDefaultKeyboard -->
<!-- $$$setDefaultMouse[overload1]$$$setDefaultMouseconstchar* -->
<h3 class="fn"><a name="setDefaultMouse"></a><span class="type">void</span> QWSServer::<span class="name">setDefaultMouse</span> ( const <span class="type">char</span> * <i>mouseDriver</i> )<tt> [static]</tt></h3>
<p>Sets the mouse driver that will be used if the <a href="qt-embedded-envvars.html#qws-mouse-proto">QWS_MOUSE_PROTO</a> environment variable is not defined, to be the given <i>mouseDriver</i>.</p>
<p>Note that the default is platform-dependent. This function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#setMouseHandler">setMouseHandler</a>() and <a href="qt-embedded-pointer.html">Qt for Embedded Linux Pointer Handling</a>.</p>
<!-- @@@setDefaultMouse -->
<!-- $$$setKeyboardHandler[overload1]$$$setKeyboardHandlerQWSKeyboardHandler* -->
<h3 class="fn"><a name="setKeyboardHandler"></a><span class="type">void</span> QWSServer::<span class="name">setKeyboardHandler</span> ( <span class="type"><a href="qwskeyboardhandler.html">QWSKeyboardHandler</a></span> * <i>driver</i> )<tt> [static]</tt></h3>
<p>Sets the primary keyboard driver to be the given <i>driver</i>.</p>
<p><a href="qt-embedded-linux.html">Qt for Embedded Linux</a> provides several ready-made keyboard drivers, and custom drivers are typically added using Qt's plugin mechanism. See the <a href="qt-embedded-charinput.html">Qt for Embedded Linux Character Input</a> documentation for details.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#keyboardHandler">keyboardHandler</a>() and <a href="qwsserver.html#setDefaultKeyboard">setDefaultKeyboard</a>().</p>
<!-- @@@setKeyboardHandler -->
<!-- $$$setMaxWindowRect[overload1]$$$setMaxWindowRectconstQRect& -->
<h3 class="fn"><a name="setMaxWindowRect"></a><span class="type">void</span> QWSServer::<span class="name">setMaxWindowRect</span> ( const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>rectangle</i> )<tt> [static]</tt></h3>
<p>Sets the maximum area of the screen that <a href="qt-embedded-linux.html">Qt for Embedded Linux</a> applications can use, to be the given <i>rectangle</i>.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwidget.html#showMaximized">QWidget::showMaximized</a>().</p>
<!-- @@@setMaxWindowRect -->
<!-- $$$setMouseHandler[overload1]$$$setMouseHandlerQWSMouseHandler* -->
<h3 class="fn"><a name="setMouseHandler"></a><span class="type">void</span> QWSServer::<span class="name">setMouseHandler</span> ( <span class="type"><a href="qwsmousehandler.html">QWSMouseHandler</a></span> * <i>driver</i> )<tt> [static]</tt></h3>
<p>Sets the primary mouse driver to be the given <i>driver</i>.</p>
<p><a href="qt-embedded-linux.html">Qt for Embedded Linux</a> provides several ready-made mouse drivers, and custom drivers are typically added using Qt's plugin mechanism. See the <a href="qt-embedded-pointer.html">Qt for Embedded Linux Pointer Handling</a> documentation for details.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#mouseHandler">mouseHandler</a>() and <a href="qwsserver.html#setDefaultMouse">setDefaultMouse</a>().</p>
<!-- @@@setMouseHandler -->
<!-- $$$setScreenSaver[overload1]$$$setScreenSaverQWSScreenSaver* -->
<h3 class="fn"><a name="setScreenSaver"></a><span class="type">void</span> QWSServer::<span class="name">setScreenSaver</span> ( <span class="type"><a href="qwsscreensaver.html">QWSScreenSaver</a></span> * <i>screenSaver</i> )<tt> [static]</tt></h3>
<p>Installs the given <i>screenSaver</i>, deleting the current screen saver.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#screenSaverActivate">screenSaverActivate</a>(), <a href="qwsserver.html#setScreenSaverInterval">setScreenSaverInterval</a>(), <a href="qwsserver.html#setScreenSaverIntervals">setScreenSaverIntervals</a>(), and <a href="qwsserver.html#setScreenSaverBlockLevel">setScreenSaverBlockLevel</a>().</p>
<!-- @@@setScreenSaver -->
<!-- $$$setScreenSaverBlockLevel[overload1]$$$setScreenSaverBlockLevelint -->
<h3 class="fn"><a name="setScreenSaverBlockLevel"></a><span class="type">void</span> QWSServer::<span class="name">setScreenSaverBlockLevel</span> ( <span class="type">int</span> <i>eventBlockLevel</i> )<tt> [static]</tt></h3>
<p>Block the key or mouse event that wakes the system from level <i>eventBlockLevel</i> or higher. To completely disable event blocking (the default behavior), set <i>eventBlockLevel</i> to -1.</p>
<p>The algorithm blocks the &quot;down&quot;, &quot;up&quot; as well as any &quot;repeat&quot; events for the same key but will not block other key events after the initial &quot;down&quot; event. For mouse events, the algorithm blocks all mouse events until an event with no buttons pressed is received.</p>
<p>There are 2 keys that are never blocked, <a href="qt.html#Key-enum">Qt::Key_F34</a> (POWER) and <a href="qt.html#Key-enum">Qt::Key_F35</a> (LIGHT).</p>
<p>Example usage:</p>
<pre class="cpp"> <span class="type">bool</span> MyScreenSaver<span class="operator">::</span>save( <span class="type">int</span> level )
 {
     <span class="keyword">switch</span> ( level ) {
         <span class="keyword">case</span> <span class="number">0</span>:
             <span class="keyword">if</span> ( dim_enabled ) {
                 <span class="comment">// dim the screen</span>
             }
             <span class="keyword">return</span> <span class="keyword">true</span>;
         <span class="keyword">case</span> <span class="number">1</span>:
             <span class="keyword">if</span> ( screenoff_enabled ) {
                 <span class="comment">// turn off the screen</span>
             }
             <span class="keyword">return</span> <span class="keyword">true</span>;
         <span class="keyword">case</span> <span class="number">2</span>:
             <span class="keyword">if</span> ( suspend_enabled ) {
                 <span class="comment">// suspend</span>
             }
             <span class="keyword">return</span> <span class="keyword">true</span>;
         <span class="keyword">default</span>:
             <span class="keyword">return</span> <span class="keyword">false</span>;
     }
 }

 <span class="operator">.</span><span class="operator">.</span><span class="operator">.</span>

 <span class="type">int</span> timings<span class="operator">[</span><span class="number">4</span><span class="operator">]</span>;
 timings<span class="operator">[</span><span class="number">0</span><span class="operator">]</span> <span class="operator">=</span> <span class="number">5000</span>;  <span class="comment">// dim after 5 seconds</span>
 timings<span class="operator">[</span><span class="number">1</span><span class="operator">]</span> <span class="operator">=</span> <span class="number">10000</span>; <span class="comment">// light off after 15 seconds</span>
 timings<span class="operator">[</span><span class="number">2</span><span class="operator">]</span> <span class="operator">=</span> <span class="number">45000</span>; <span class="comment">// suspend after 60 seconds</span>
 timings<span class="operator">[</span><span class="number">3</span><span class="operator">]</span> <span class="operator">=</span> <span class="number">0</span>;
 <span class="type"><a href="qwsserver.html">QWSServer</a></span><span class="operator">::</span><a href="qwsserver.html#setScreenSaverIntervals">setScreenSaverIntervals</a>( timings );

 <span class="comment">// ignore the key/mouse event that turns on the screen</span>
 <span class="type">int</span> blocklevel <span class="operator">=</span> <span class="number">1</span>;
 <span class="keyword">if</span> ( <span class="operator">!</span>screenoff_enabled ) {
     <span class="comment">// screenoff is disabled, ignore the key/mouse event that wakes from suspend</span>
     blocklevel <span class="operator">=</span> <span class="number">2</span>;
     <span class="keyword">if</span> ( <span class="operator">!</span>suspend_enabled ) {
         <span class="comment">// suspend is disabled, never ignore events</span>
         blocklevel <span class="operator">=</span> <span class="operator">-</span><span class="number">1</span>;
     }
 }
 <span class="type"><a href="qwsserver.html">QWSServer</a></span><span class="operator">::</span>setScreenSaverBlockLevel( blocklevel );</pre>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#setScreenSaverIntervals">setScreenSaverIntervals</a>() and <a href="qwsserver.html#setScreenSaverInterval">setScreenSaverInterval</a>().</p>
<!-- @@@setScreenSaverBlockLevel -->
<!-- $$$setScreenSaverInterval[overload1]$$$setScreenSaverIntervalint -->
<h3 class="fn"><a name="setScreenSaverInterval"></a><span class="type">void</span> QWSServer::<span class="name">setScreenSaverInterval</span> ( <span class="type">int</span> <i>milliseconds</i> )<tt> [static]</tt></h3>
<p>Sets the timeout interval for the screensaver to the specified <i>milliseconds</i>. To turn off the screensaver, set the timout interval to 0.</p>
<p>Note that this function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#setScreenSaverIntervals">setScreenSaverIntervals</a>() and <a href="qwsserver.html#setScreenSaverBlockLevel">setScreenSaverBlockLevel</a>().</p>
<!-- @@@setScreenSaverInterval -->
<!-- $$$setScreenSaverIntervals[overload1]$$$setScreenSaverIntervalsint* -->
<h3 class="fn"><a name="setScreenSaverIntervals"></a><span class="type">void</span> QWSServer::<span class="name">setScreenSaverIntervals</span> ( <span class="type">int</span> * <i>intervals</i> )<tt> [static]</tt></h3>
<p>Specifies the time <i>intervals</i> (in milliseconds) between the different levels of screen responsiveness.</p>
<p><a href="qt-embedded-linux.html">Qt for Embedded Linux</a> supports multilevel screen saving, i.e&#x2e;, it is possible to specify several different levels of screen responsiveness by implementing the <a href="qwsscreensaver.html#save">QWSScreenSaver::save</a>() function. For example, you can choose to first turn off the light before you fully activate the screensaver. See the <a href="qwsscreensaver.html">QWSScreenSaver</a> documentation for details.</p>
<p>Note that an interval of 0 milliseconds will turn off the screensaver, and that the <i>intervals</i> array must be 0-terminated. This function can only be used in the server process.</p>
<p><b>See also </b><a href="qwsserver.html#setScreenSaverInterval">setScreenSaverInterval</a>() and <a href="qwsserver.html#setScreenSaverBlockLevel">setScreenSaverBlockLevel</a>().</p>
<!-- @@@setScreenSaverIntervals -->
<!-- $$$suspendMouse[overload1]$$$suspendMouse -->
<h3 class="fn"><a name="suspendMouse"></a><span class="type">void</span> QWSServer::<span class="name">suspendMouse</span> ()</h3>
<p>Suspends pointer handling by deactivating all the mouse drivers registered by the <a href="qt-embedded-envvars.html#qws-mouse-proto">QWS_MOUSE_PROTO</a> environment variable.</p>
<p><b>See also </b><a href="qwsserver.html#resumeMouse">resumeMouse</a>() and <a href="qwsmousehandler.html#suspend">QWSMouseHandler::suspend</a>().</p>
<!-- @@@suspendMouse -->
<!-- $$$windowAt[overload1]$$$windowAtconstQPoint& -->
<h3 class="fn"><a name="windowAt"></a><span class="type"><a href="qwswindow.html">QWSWindow</a></span> * QWSServer::<span class="name">windowAt</span> ( const <span class="type"><a href="qpoint.html">QPoint</a></span> &amp; <i>position</i> )</h3>
<p>Returns the window containing the given <i>position</i>.</p>
<p>Note that if there is no window under the specified point this function returns 0.</p>
<p><b>See also </b><a href="qwsserver.html#clientWindows">clientWindows</a>() and <a href="qwsserver.html#instance">instance</a>().</p>
<!-- @@@windowAt -->
<!-- $$$windowEvent[overload1]$$$windowEventQWSWindow*QWSServer::WindowEvent -->
<h3 class="fn"><a name="windowEvent"></a><span class="type">void</span> QWSServer::<span class="name">windowEvent</span> ( <span class="type"><a href="qwswindow.html">QWSWindow</a></span> * <i>window</i>, <span class="type"><a href="qwsserver.html#WindowEvent-enum">QWSServer::WindowEvent</a></span> <i>eventType</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted whenever something happens to a top-level window (e.g&#x2e;, it's created or destroyed), passing a pointer to the window and the event's type in the <i>window</i> and <i>eventType</i> parameters, respectively.</p>
<p><b>See also </b><a href="qwsserver.html#markedText">markedText</a>().</p>
<!-- @@@windowEvent -->
</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>