So you have created your own
Then you have to implement it yourself using the common handlers for mouse button down and up, and mouse move. There check the ALT key state with
and set class member variables accordingly to indicate that selection is active and where it starts:
- Button down: if ALT down save start position and set state to "selecting"
- Move: if state is "selecting" update screen to show the selection
- Button up: if state is "selecting" save end position and set state to "has selection"
- Copy: if state is "has selection" copy to clipboard
How to show the selection depends on your drawing routine. It usually requires getting the start and end character position from the mouse positions.