widget_scroll
The rows a scroll, list, tree or table reads: its bars, where it is scrolled to and what scrolls it.
На этой странице
ui · 11 properties · UI
The rows a scroll, list, tree or table reads: its bars, where it is scrolled to and what scrolls it.
In a scene, widget_scroll is the node key that applies it. A script reaches each property below as a field on node.widget_scroll: reading one asks the running component, and assigning one leaves the rest alone. The whole table is node.widget_scroll.get() and node.widget_scroll.set(table).
Properties
| property | type | default | description |
|---|---|---|---|
animated |
bool | true |
Ease a scroll, list, tree or table to where it is sent, such as a row scrolled into view, rather than jump |
drag_cursor |
enum | arrow |
The pointer's shape while a drag scrolls a scroll, list, tree or table's content; arrow leaves it as it is One of arrow, none, hand, text, vertical_text, cross, cell, wait, progress, help, context_menu, move, grab, grabbing, alias, copy, no_drop, forbidden, all_scroll, resize_x, resize_y, resize_n, resize_e, resize_s, resize_w, resize_ne, resize_nw, resize_se, resize_sw, resize_nesw, resize_nwse, resize_col, resize_row, zoom_in, zoom_out. |
drag_scroll |
enum | touch |
When dragging a scroll, list, tree or table's content scrolls it: on a touch screen, always, or never; a scroll_deadzone takes the drag over itself One of touch, always, never. |
min_scrolled_height |
float | 0 |
The shortest a scroll, list, tree or table draws while its content runs past it downwards, in design pixels; 0 takes egui's At least 0. |
min_scrolled_width |
float | 0 |
The narrowest a scroll, list, tree or table draws while its content runs past it sideways, in design pixels; 0 takes egui's At least 0. |
scroll_deadzone |
float | 0 |
How far a finger drags a scroll before it scrolls, in design pixels, so a tap on a child still lands; 0 scrolls at once At least 0. |
scroll_offset |
vec2 | [-1,-1] |
Where a scroll, list, tree or table is scrolled to, across and down, in design pixels: written as the reader scrolls, and a new one written by the scene or a script scrolls it there. Below zero on an axis leaves that axis where it is; ui.scroll takes it too |
scrollbar |
enum | auto |
When a scroll, list, tree or table has its bars: while its content runs past it, always, or never. The bars float, so one shows once the pointer is over the box One of auto, always, never. |
stick_to_end |
bool | false |
Keep a scroll, list, tree or table at its end as content arrives, until the reader scrolls away from it; ui.scroll takes it too |
wheel_scroll |
bool | true |
Let the mouse wheel scroll a scroll, list, tree or table |
wheel_speed |
vec2 | [1,1] |
How far a mouse wheel scrolls a scroll, list, tree or table, across and down, as a multiple of egui's own |