Type Definition xcb::xproto::ButtonPressEvent [−][src]
type ButtonPressEvent = Event<xcb_button_press_event_t>;
a mouse button was pressed/released
Implementations
impl ButtonPressEvent
[src]
pub fn detail(&self) -> Button
[src]
The keycode (a number representing a physical key on the keyboard) of the key which was pressed.
pub fn time(&self) -> Timestamp
[src]
Time when the event was generated (in milliseconds).
pub fn root(&self) -> Window
[src]
The root window of child
.
pub fn event(&self) -> Window
[src]
pub fn child(&self) -> Window
[src]
pub fn root_x(&self) -> i16
[src]
The X coordinate of the pointer relative to the root
window at the time of
the event.
pub fn root_y(&self) -> i16
[src]
The Y coordinate of the pointer relative to the root
window at the time of
the event.
pub fn event_x(&self) -> i16
[src]
If same_screen
is true, this is the X coordinate relative to the event
window’s origin. Otherwise, event_x
will be set to zero.
pub fn event_y(&self) -> i16
[src]
If same_screen
is true, this is the Y coordinate relative to the event
window’s origin. Otherwise, event_y
will be set to zero.
pub fn state(&self) -> u16
[src]
The logical state of the pointer buttons and modifier keys just prior to the event.
pub fn same_screen(&self) -> bool
[src]
Whether the event
window is on the same screen as the root
window.
pub fn new(
response_type: u8,
detail: Button,
time: Timestamp,
root: Window,
event: Window,
child: Window,
root_x: i16,
root_y: i16,
event_x: i16,
event_y: i16,
state: u16,
same_screen: bool
) -> ButtonPressEvent
[src]
response_type: u8,
detail: Button,
time: Timestamp,
root: Window,
event: Window,
child: Window,
root_x: i16,
root_y: i16,
event_x: i16,
event_y: i16,
state: u16,
same_screen: bool
) -> ButtonPressEvent
Constructs a new ButtonPressEvent
response_type
must be set to one of:
- BUTTON_PRESS
- BUTTON_RELEASE