copy
This could use textLayout.copy(), but that doesn't work if we have a masked password field (textLayout only sees the password char).
Parameters
- self:*TextEntryWidget
- *TextEntryWidget
Source
Implementation
pub fn copy(self: *TextEntryWidget) void {
var sel = self.textLayout.selectionGet(self.len);
if (!sel.empty()) {
// copy selection to clipboard
dvui.clipboardTextSet(self.text[sel.start..sel.end]);
}
}