Skip to content
You are viewing documentation for v2.0.0. Switch to latest (main).

ftxui::Mouse ​

cpp
#include <ftxui/component/mouse.hpp>

A mouse event. It contains the coordinate of the mouse, the button pressed and the modifier (shift, ctrl, meta).

Examples: component/print_key_press

Summary ​

SymbolDescription
Button
Motion
button
motion
shift
meta
control
x
y

Public Types ​

Button ​

cpp
enum Button { Left, Middle, Right, None, WheelUp, WheelDown };

Examples: component/button, component/composition, component/gallery, component/modal_dialog, component/nested_screen, component/renderer, component/with_restored_io

Motion ​

cpp
enum Motion { Released, Pressed };

Public Attributes ​

button ​

cpp
Button button;

Examples: component/print_key_press

motion ​

cpp
Motion motion;

Examples: component/print_key_press

shift ​

cpp
bool shift;

Examples: component/print_key_press

meta ​

cpp
bool meta;

Examples: component/print_key_press

control ​

cpp
bool control;

Examples: component/print_key_press

x ​

cpp
int x;

Examples: component/print_key_press

y ​

cpp
int y;

Examples: component/print_key_press