Viadeo Twitter Google Bookmarks ! Facebook Digg del.icio.us MySpace Yahoo MyWeb Blinklist Netvouz Reddit Simpy StumbleUpon Bookmarks Windows Live Favorites 
Logo Documentation Qt ·  Page d'accueil  ·  Toutes les classes  ·  Toutes les fonctions  ·  Vues d'ensemble  · 

InputMethods Class Reference
[QtInputMethodsModule]

The InputMethods class provides an implementation of Qt Extended server input method handling. More...

    #include <InputMethods>

Inherits QWidget.

Public Types

Public Functions

  • 206 public functions inherited from QWidget
  • 29 public functions inherited from QObject
  • 14 public functions inherited from QPaintDevice

Public Slots

  • 19 public slots inherited from QWidget
  • 1 public slot inherited from QObject

Signals

Additional Inherited Members

  • 57 properties inherited from QWidget
  • 1 property inherited from QObject
  • 1 public type inherited from QObject
  • 4 static public members inherited from QWidget
  • 4 static public members inherited from QObject
  • 38 protected functions inherited from QWidget
  • 7 protected functions inherited from QObject
  • 1 protected function inherited from QPaintDevice
  • 1 protected slot inherited from QWidget
  • 2 protected variables inherited from QObject
  • 1 protected type inherited from QPaintDevice

Detailed Description

The InputMethods class provides an implementation of Qt Extended server input method handling.

InputMethods is the core class for the Qt Extended servers input method handling. It is very closely related to the InputMethod service and InputMethodSelector classes.

InputMethods is primarily resposible for loading input method plugins and maintaining the hints set for different widgets. It also acts on the messages from the InputMethod service, either taking direct action or passing them on to the InputMethodSelector.

This class is part of the Qt Extended server and cannot be used by other Qt Extended applications.


Member Type Documentation

enum InputMethods::IMType

This enum describes which types of input an input method processes.

ConstantValueDescription
InputMethods::Any0The input method can process both mouse and keypad input
InputMethods::Mouse1The input method processes mouse or pointer input.
InputMethods::Keypad2The input method processes keypad input.

enum InputMethods::SystemMenuItemId

This enum defines values that input method menu items can return to activate system actions based for these menu items.

ConstantValueDescription
InputMethods::NextInputMethod-2This value results in the input method being changed to the next input method in alphabetic order.
InputMethods::ChangeInputMethod-3This value causes the input method selection menu to be shown, and to recieve keyboard focus, facilitating changing input methods with the keyboard.


Member Function Documentation

InputMethods::InputMethods ( QWidget * parent = 0, Qt::WFlags flags = 0, IMType t = Any )

Create a new InputMethods object with parent and flags that handles input according to t.

InputMethods::~InputMethods ()

Unloads all input methods.

void InputMethods::activateMenuItem ( int v )

Checks whether the activated menu item belonged to the server, and either responds or passes the information on to the current input method appropriately.

Server menu items typically have values less than 0, so v is generally passed to the current input method if it is greater than or equal to 0.

See also QtopiaInputMethod::menuActionActivated().

void InputMethods::changeInputMethod ()   [slot]

Activate the input method selector choice pop-up (a menu of available input methods), and give it keyboard focus.

QString InputMethods::currentShown () const   [slot]

Returns the name of the current input method, or an empty QString if there is no current input method.

See also QtopiaInputMethod::name().

void InputMethods::hideInputMethod ()   [slot]

Deactivates and hides the current input method.

void InputMethods::inputMethodHint ( int h, int wid, bool password = false )   [slot]

Sets the input hint for the current input method for widget wid. h is the hint for the input method, according to QtopiaApplication::InputMethodHint. The password flag sets password mode, indicating that input should be hidden after being entered, and defaults to false. This value is recorded for when this widget gains focus in the future, and if wid refers to the last active widget, the hint is forwarded to the current input method immediately.

void InputMethods::inputMethodHint ( const QString & h, int wid )   [slot]

This is an overloaded member function, provided for convenience.

Sets the input hint for widget wid, according to the hint h. This information is recorded for this widget should it gain focus, and if wid refers to the last active window, the hint is immediately forwarded to the current input method.

void InputMethods::inputMethodPasswordHint ( bool passwordFlag, int wid )   [slot]

Sets the password hint for wid to passwordFlag, provided an input hint has previously been set for that widget. If no hint has been set for that widget previously, this function does nothing.

See also inputMethodHint().

QRect InputMethods::inputRect () const

Returns the geometry of the current input methods input widget, or an empty QRect if there is no current input method, or no input widget for the current input method.

void InputMethods::inputToggled ( bool on )   [signal]

Connect to this signal to recieve notifications of changes in the state of input methods. on describes whether the input methods have just turned on (true), or off (false).

void InputMethods::loadInputMethods ()

Creates a QPluginManager for input methods to load input method plugins out of the plugins/inputmethods directory.

If InputMethods already has a QPluginManager, this function does nothing.

bool InputMethods::selectorShown () const

Returns true if the input method selector is visible, false otherwise. This indicates the visibility of the widget used to change input methods, not the drop-down menu itself. In Qtopia, this widget is only visible if at least 2 input methods have been loaded, and the widget with focus accepts text input.

See also InputMethodSelector::isVisible() and InputMethodSelector::count().

void InputMethods::setNextInputMethod ()   [slot]

Cycle to the next input method.

void InputMethods::setType ( IMType type )   [slot]

Set system-wide description for allowable inputmethods to the given type. Note: Triggers a reloading of all inputmethod plugins

void InputMethods::showInputMethod ( const QString & name )   [slot]

Selects the the input method named name, if it exists, and activates and shows it. If the named input method does not exist, this function activates the current input method.

void InputMethods::showInputMethod ()   [slot]

This is an overloaded member function, provided for convenience.

Shows and activates the current input method.

bool InputMethods::shown () const

Returns true if the current input method is active and visible, otherwise returns false.

void InputMethods::unloadInputMethods ()

Clears the current input method, and clears and destroys all previously loaded input methods. Called from InputMethods destructor.

void InputMethods::visibilityChanged ( bool visible )   [signal]

Connect to this signal to receive notification of changes in the visibility of input methods. This is synonymous with activation, input methods do not need to have an input widget to be visible in this sense. visible is true if the input method is becoming visible/activating, false if it becoming invisible/deactivating.

Publicité

Best Of

Actualités les plus lues

Semaine
Mois
Année
  1. « Quelque chose ne va vraiment pas avec les développeurs "modernes" », un développeur à "l'ancienne" critique la multiplication des bibliothèques 64
  2. Apercevoir la troisième dimension ou l'utilisation multithreadée d'OpenGL dans Qt, un article des Qt Quarterly traduit par Guillaume Belz 0
  3. Les développeurs ignorent-ils trop les failles découvertes dans leur code ? Prenez-vous en compte les remarques des autres ? 17
  4. BlackBerry 10 : premières images du prochain OS de RIM qui devrait intégrer des widgets et des tuiles inspirées de Windows Phone 0
  5. Quelles nouveautés de C++11 Visual C++ doit-il rapidement intégrer ? Donnez-nous votre avis 10
  6. Adieu qmake, bienvenue qbs : Qt Building Suite, un outil déclaratif et extensible pour la compilation de projets Qt 17
  7. La rubrique Qt a besoin de vous ! 1
Page suivante

Le blog Digia au hasard

Logo

Créer des applications avec un style Metro avec Qt, exemples en QML et C++, un article de Digia Qt traduit par Thibaut Cuvelier

Le blog Digia est l'endroit privilégié pour la communication sur l'édition commerciale de Qt, où des réponses publiques sont apportées aux questions les plus posées au support. Lire l'article.

Communauté

Ressources

Liens utiles

Contact

  • Vous souhaitez rejoindre la rédaction ou proposer un tutoriel, une traduction, une question... ? Postez dans le forum Contribuez ou contactez-nous par MP ou par email (voir en bas de page).

Qt dans le magazine

Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. Qt qtextended4.4
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD.
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP !
 
 
 
 
Partenaires

Hébergement Web