egui/scripts
Emil Ernerfeldt 5d2e192927
Selectable text in Labels (#3814)
* Closes https://github.com/emilk/egui/issues/3804

Add ability to select the text in labels with mouse-drag, double-click,
and keyboard (once clicked).
Hit Cmd+C to copy the text. If everything of a label with elided text is
selected, the copy command will copy the full non-elided text. IME and
accesskit _should_ work, but is untested.

You can control wether or not text in labels is selected globally in
`style.interaction.selectable_labels` or on a per-label basis in
`Label::selectable`. The default is ON.

This also cleans up the `TextEdit` code somewhat, fixing a couple
smaller bugs along the way.

This does _not_ implement selecting text across multiple widgets. Text
selection is only supported within a single `Label`, `TextEdit`, `Link`
or `Hyperlink`.


![label-text-selection](https://github.com/emilk/egui/assets/1148717/c161e819-50da-4b97-9686-042e6abf3564)


## TODO
* [x] Test
2024-01-14 15:17:55 +01:00
..
clippy_wasm Update MSRV to Rust 1.72 (#3595) 2023-11-21 17:26:35 +01:00
build_demo_web.sh Add -g option to build_demo_web.sh 2023-12-28 10:36:07 +01:00
cargo_deny.sh Make sure `check.sh` installs all tools it uses 2023-11-30 17:45:15 +01:00
check.sh Selectable text in Labels (#3814) 2024-01-14 15:17:55 +01:00
clippy_wasm.sh Introduce global `zoom_factor` (#3608) 2023-11-22 20:34:51 +01:00
docs.sh Rename `sh/` folder to `scripts/` 2023-04-18 17:10:52 +02:00
find_bloat.sh Rename `sh/` folder to `scripts/` 2023-04-18 17:10:52 +02:00
generate_changelog.py Strip trailing periods from changelog entries 2024-01-08 12:19:23 +01:00
generate_example_screenshots.sh Add screenshot to custom_plot_manipulation example 2024-01-08 11:16:44 +01:00
lint.py Use `Self` everywhere (#3787) 2024-01-08 17:41:21 +01:00
setup_web.sh Highlight submenu buttons when hovered and open (#3780) 2024-01-07 22:08:32 +01:00
start_server.sh Rename `docs/` to `web_demo/` 2023-11-16 16:44:30 +01:00
wasm_bindgen_check.sh Remove dependency on `tts` (#3651) 2023-11-28 10:46:18 +01:00
wasm_size.sh Rename `docs/` to `web_demo/` 2023-11-16 16:44:30 +01:00