#[repr(C)]pub struct SDL_TextEditingEvent {
pub type: SDL_EventType,
pub reserved: Uint32,
pub timestamp: Uint64,
pub windowID: SDL_WindowID,
pub text: *const c_char,
pub start: Sint32,
pub length: Sint32,
}Expand description
Keyboard text editing event structure (event.edit.*)
The start cursor is the position, in UTF-8 characters, where new typing will be inserted into the editing text. The length is the number of UTF-8 characters that will be replaced by new typing.
§Availability
This struct is available since SDL 3.2.0.
Fields§
§type: SDL_EventType§reserved: Uint32§timestamp: Uint64In nanoseconds, populated using SDL_GetTicksNS()
windowID: SDL_WindowIDThe window with keyboard focus, if any
text: *const c_charThe editing text
start: Sint32The start cursor of selected editing text, or -1 if not set
length: Sint32The length of selected editing text, or -1 if not set
Trait Implementations§
Source§impl Clone for SDL_TextEditingEvent
impl Clone for SDL_TextEditingEvent
Source§fn clone(&self) -> SDL_TextEditingEvent
fn clone(&self) -> SDL_TextEditingEvent
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SDL_TextEditingEvent
impl Debug for SDL_TextEditingEvent
Source§impl Default for SDL_TextEditingEvent
impl Default for SDL_TextEditingEvent
impl Copy for SDL_TextEditingEvent
Auto Trait Implementations§
impl Freeze for SDL_TextEditingEvent
impl RefUnwindSafe for SDL_TextEditingEvent
impl !Send for SDL_TextEditingEvent
impl !Sync for SDL_TextEditingEvent
impl Unpin for SDL_TextEditingEvent
impl UnwindSafe for SDL_TextEditingEvent
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more