Eneboo - Documentación para desarrolladores
Tipos públicos | Métodos públicos | Métodos públicos estáticos
Referencia de la Clase QFocusEvent

The QFocusEvent class contains event parameters for widget focus events. Más...

#include <qevent.h>

Diagrama de herencias de QFocusEvent
QEvent QEvent Qt Qt Qt Qt

Lista de todos los miembros.

Tipos públicos

enum  Reason {
  Mouse, Tab, Backtab, ActiveWindow,
  Popup, Shortcut, Other, Mouse,
  Tab, Backtab, ActiveWindow, Popup,
  Shortcut, Other
}
enum  Reason {
  Mouse, Tab, Backtab, ActiveWindow,
  Popup, Shortcut, Other, Mouse,
  Tab, Backtab, ActiveWindow, Popup,
  Shortcut, Other
}

Métodos públicos

 QFocusEvent (Type type)
bool gotFocus () const
bool lostFocus () const
 QFocusEvent (Type type)
bool gotFocus () const
bool lostFocus () const

Métodos públicos estáticos

static Reason reason ()
static void setReason (Reason reason)
static void resetReason ()
static Reason reason ()
static void setReason (Reason reason)
static void resetReason ()

Descripción detallada

The QFocusEvent class contains event parameters for widget focus events.

Focus events are sent to widgets when the keyboard input focus changes. Focus events occur due to mouse actions, keypresses (e.g. Tab or Backtab), the window system, popup menus, keyboard shortcuts or other application specific reasons. The reason for a particular focus event is returned by reason() in the appropriate event handler.

The event handlers QWidget::focusInEvent() and QWidget::focusOutEvent() receive focus events.

Use setReason() to set the reason for all focus events, and resetReason() to set the reason for all focus events to the reason in force before the last setReason() call.

Ver también:
QWidget::setFocus(), QWidget::setFocusPolicy()

Documentación de las enumeraciones miembro de la clase

This enum specifies why the focus changed.

Mouse because of a mouse action. Tab because of a Tab press. Backtab because of a Backtab press (possibly including Shift/Control, e.g. Shift+Tab). ActiveWindow because the window system made this window (in)active. Popup because the application opened/closed a popup that grabbed/released focus. Shortcut because of a keyboard shortcut. Other any other reason, usually application-specific.

See the keyboard focus overview for more about focus.

Valores de enumeraciones:
Mouse 
Tab 
Backtab 
ActiveWindow 
Popup 
Shortcut 
Other 
Mouse 
Tab 
Backtab 
ActiveWindow 
Popup 
Shortcut 
Other 
Valores de enumeraciones:
Mouse 
Tab 
Backtab 
ActiveWindow 
Popup 
Shortcut 
Other 
Mouse 
Tab 
Backtab 
ActiveWindow 
Popup 
Shortcut 
Other 

Documentación del constructor y destructor

QFocusEvent::QFocusEvent ( Type  type) [inline]

Constructs a focus event object.

The type parameter must be either QEvent::FocusIn or QEvent::FocusOut.

QFocusEvent::QFocusEvent ( Type  type) [inline]

Documentación de las funciones miembro

bool QFocusEvent::gotFocus ( ) const [inline]

Returns TRUE if the widget received the text input focus; otherwise returns FALSE.

bool QFocusEvent::gotFocus ( ) const [inline]
bool QFocusEvent::lostFocus ( ) const [inline]

Returns TRUE if the widget lost the text input focus; otherwise returns FALSE.

bool QFocusEvent::lostFocus ( ) const [inline]
static Reason QFocusEvent::reason ( ) [static]
QFocusEvent::Reason QFocusEvent::reason ( ) [static]

Returns the reason for this focus event.

Ver también:
setReason()
void QFocusEvent::resetReason ( ) [static]

Resets the reason for all future focus events to the value before the last setReason() call.

Ver también:
reason(), setReason()
static void QFocusEvent::resetReason ( ) [static]
void QFocusEvent::setReason ( Reason  reason) [static]

Sets the reason for all future focus events to reason.

Ver también:
reason(), resetReason()
static void QFocusEvent::setReason ( Reason  reason) [static]

La documentación para esta clase fue generada a partir de los siguientes ficheros:
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'