Commit Graph

2820 Commits

Author SHA1 Message Date
Emil Ernerfeldt 38ab2d9ca7 Sort deny.toml 2023-11-23 15:45:48 +01:00
Emil Ernerfeldt dd794f253a Don't persist zoom_with_keyboard 2023-11-23 15:45:41 +01:00
Emil Ernerfeldt 185e18ad4f Improve some docs 2023-11-23 15:45:32 +01:00
Emil Ernerfeldt 6a8b51adb5 Improve demo backend panel 2023-11-23 15:45:19 +01:00
Emil Ernerfeldt 96bc34a66d Use workspace definitions of edition,license,rust-version,version 2023-11-23 15:45:11 +01:00
Emil Ernerfeldt b62676d21a Improve changelog generator: capitalize output 2023-11-23 15:42:10 +01:00
Emil Ernerfeldt 24913ceeba
Fix up some examples (#3614) 2023-11-23 12:58:44 +01:00
Emil Ernerfeldt a2b15b23ad
macOS `ViewportBuilder` tweaks (#3613) 2023-11-23 10:43:30 +01:00
Emil Ernerfeldt 85489dc1dd
Fix deadlock on `custom_window_frame` (#3612)
* Reverts commit e037489 (https://github.com/emilk/egui/pull/3601)
* Reopens https://github.com/emilk/egui/issues/3494

It caused a deadlock on Mac when running `custom_window_frame`
2023-11-23 09:22:10 +01:00
Andreas Reich f9f5db9885
PaintCallbackInfo::viewport_in_pixels now guarantees to stay in bounds (#3604)
* Fixes https://github.com/rerun-io/rerun/issues/4297
* tested against a very hasty and incomplete port of egui/trunk, found
[here](https://github.com/rerun-io/rerun/tree/andreas/experimental-egui-trunk)


In rare cases in can happen that the viewport returned by
`PaintCallbackInfo` is outside the bounds of the screen.
for at least [wgpu/webgpu in
particular](https://www.w3.org/TR/webgpu/#dom-gpurenderpassencoder-setviewport)
this is invalid usage, other backends might be affected as well.
Since this happened due to a float rounding error (in one repro case I
had I got (width==1126.5625) + (offset=715.4376) = 1842.0001 for a
resolution of 1842) I decided to do away with fractional values on the
viewport alltogether. They _technically_ make sense since a viewport is
only specifying the NDC to pixel coordinate conversion, but practically
this may lead to surprising sub-sampling issues.

---------

Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
2023-11-22 21:01:38 +01:00
Emil Ernerfeldt 6490dfafb6
Fix: fall back to default egui icon if non is set (#3610)
It broke in one of the recent multi-viewport prs
2023-11-22 20:54:16 +01:00
YgorSouza 4ece25bd05
Keep unsafe code forbidden when puffin is disabled (#3603)
This helps document what unsafe is being used for, and prevent other
uses from going unnoticed.
2023-11-22 20:37:46 +01:00
Emil Ernerfeldt 63e48dc855
Introduce global `zoom_factor` (#3608)
* Closes https://github.com/emilk/egui/issues/3602

You can now zoom any egui app by pressing Cmd+Plus, Cmd+Minus or Cmd+0,
just like in a browser. This will change the current `zoom_factor`
(default 1.0) which is persisted in the egui memory, and is the same for
all viewports.
You can turn off the keyboard shortcuts with `ctx.options_mut(|o|
o.zoom_with_keyboard = false);`

`zoom_factor` can also be explicitly read/written with
`ctx.zoom_factor()` and `ctx.set_zoom_factor()`.

This redefines `pixels_per_point` as `zoom_factor *
native_pixels_per_point`, where `native_pixels_per_point` is whatever is
the native scale factor for the monitor that the current viewport is in.

This adds some complexity to the interaction with winit, since we need
to know the current `zoom_factor` in a lot of places, because all egui
IO is done in ui points. I'm pretty sure this PR fixes a bunch of subtle
bugs though that used to be in this code.

`egui::gui_zoom::zoom_with_keyboard_shortcuts` is now gone, and is no
longer needed, as this is now the default behavior.

`Context::set_pixels_per_point` is still there, but it is recommended
you use `Context::set_zoom_factor` instead.
2023-11-22 20:34:51 +01:00
Emil Ernerfeldt ea53246c60
Refactor viewport ids in eframe (#3607)
Simplifies some things
2023-11-22 13:50:43 +01:00
Emil Ernerfeldt e037489ac2
eframe: update the maximized/minimized viewport state each frame (#3601)
* Closes https://github.com/emilk/egui/issues/3494

This makes sure it is always up-to-date.

Previously (years back) this caused a deadlock on Mac, but this seems to
have been fixed
2023-11-21 19:05:19 +01:00
Emil Ernerfeldt 1bbd5a9fc8
Update puffin to 0.18 (#3600)
THe profiling macros now contain unsafe code (but in a safe way), so
`#[foribd(unsafe)]` had to become `#[deny(unsafe)]`
2023-11-21 17:58:33 +01:00
Emil Ernerfeldt bfadb90d42
Update MSRV to Rust 1.72 (#3595)
Required to update to puffin 0.18
2023-11-21 17:26:35 +01:00
Emil Ernerfeldt 7abf8afd16
Change `Arc<glow::Context>` to `Rc<glow::Context>` (#3598)
This is required for Rust 1.72 (for unknown reasons; see
https://github.com/emilk/egui/pull/3595), but also for updating to glow
0.13, where the `glow::Context` is not longer `Sync+Send`
2023-11-21 17:13:46 +01:00
Emil Ernerfeldt e823491240
Update some crate dependencies (#3594)
Nothing major
2023-11-21 16:07:56 +01:00
Emil Ernerfeldt 8c68035b66 Add some explanations for the safari copy/cut fix 2023-11-21 14:58:19 +01:00
Ryan Hileman a6da34339a
Fix copy and cut on Safari (#3513)
* Closes <https://github.com/emilk/egui/issues/3480>

I've tested this on Safari and Chrome on macOS Sonoma 14.0.

Could be improved to only call `event.preventDefault()` if
`runner.logic()` actually performed a copy, but I don't see a way to get
that information out with the current API.
2023-11-21 14:54:31 +01:00
Zach Bateman 6adc4864cd
Fix TopBottomPanel doc comment to reference TopBottomPanel instead of SidePanel (#3590) 2023-11-21 14:47:18 +01:00
Antoine Beyeler 05a3c4c0f1
Plot auto-bounds API improvement (part 2/2): add API (#3586)
Part 2 of 2 of adding a better API for egui_plot's auto-bounds feature.

In this PR: add `auto_bounds()`/`set_auto_bounds()` APIs to PlotUI
2023-11-21 11:56:39 +01:00
YgorSouza 49eecc4287
Allow changing handle shape of a slider (#3429)
* Closes #1974

<!--
Please read the "Making a PR" section of
[`CONTRIBUTING.md`](https://github.com/emilk/egui/blob/master/CONTRIBUTING.md)
before opening a Pull Request!

* Keep your PR:s small and focused.
* If applicable, add a screenshot or gif.
* If it is a non-trivial addition, consider adding a demo for it to
`egui_demo_lib`, or a new example.
* Do NOT open PR:s from your `master` branch, as that makes it hard for
maintainers to add commits to your PR.
* Remember to run `cargo fmt` and `cargo cranky`.
* Open the PR as a draft until you have self-reviewed it and run
`./scripts/check.sh`.
* When you have addressed a PR comment, mark it as resolved.

Please be patient! I will review you PR, but my time is limited!
-->

---------

Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
2023-11-21 11:24:29 +01:00
Antoine Beyeler f20b7b43bf
Plot auto-bounds API improvement (part 1/2): clean-up (#3587)
Part 1 of 2 of adding a better API for egui_plot's auto-bounds feature.

In this PR:
- change the `Plot` builder struct field to `default_auto_bounds` (was
`auto_bounds`)
- change the `Plot` state field to `auto_bounds` (was `bounds_modified`)
- minor improvements to `Vec2b`
2023-11-21 11:22:19 +01:00
YgorSouza 78a93f81f0
Properly reverse bool animation if value changes before it's finished (#3577)
<!--
Please read the "Making a PR" section of
[`CONTRIBUTING.md`](https://github.com/emilk/egui/blob/master/CONTRIBUTING.md)
before opening a Pull Request!

* Keep your PR:s small and focused.
* If applicable, add a screenshot or gif.
* If it is a non-trivial addition, consider adding a demo for it to
`egui_demo_lib`, or a new example.
* Do NOT open PR:s from your `master` branch, as that makes it hard for
maintainers to add commits to your PR.
* Remember to run `cargo fmt` and `cargo cranky`.
* Open the PR as a draft until you have self-reviewed it and run
`./scripts/check.sh`.
* When you have addressed a PR comment, mark it as resolved.

Please be patient! I will review your PR, but my time is limited!
-->

Closes <https://github.com/emilk/egui/issues/3576>.
2023-11-21 10:39:43 +01:00
Emil Ernerfeldt 39271c3adf
CentralPanel: base id on the current viewport (#3593)
This means two `CentralPanel`s in different viewports get different ids,
avoiding id clashes
2023-11-20 21:54:32 +01:00
Emil Ernerfeldt 44ff29b012
Fix closing of viewports (#3591)
This ensures the closed viewport gets a close-event, and that it and the
parent viewport gets repainting, allowing the event to be registered.
2023-11-20 17:43:40 +01:00
Emil Ernerfeldt 7bfaf49636
Update to puffin 0.17 (#3581) 2023-11-19 21:28:42 +01:00
Emil Ernerfeldt 30ee478caf
Fix egui-wgpu performance regression (#3580)
Introduced in the recent multi-viewports work, we accidentally recreated
the wgpu surfaces every frame. This is now fixed.

I found this while improving the profiling of `eframe`
2023-11-19 21:14:13 +01:00
Emil Ernerfeldt 960b01b67a
Refactor: move code around in `eframe` (#3575)
`run.rs` was getting way too long and complex.
2023-11-19 12:12:43 +01:00
Emil Ernerfeldt a23b959fd4
eframe: Remove warm-starting (#3574)
This was an ill-supported feature with little benefit or use.
2023-11-19 11:21:38 +01:00
Emil Ernerfeldt 74862bd129 Rename `show_viewport` to `show_viewport_deferred`
Let's be explicit
2023-11-19 11:12:37 +01:00
Emil Ernerfeldt 39e60e367f
Use `egui::ViewportBuilder` in `eframe::NativeOptions` (#3572)
* Part of https://github.com/emilk/egui/issues/3556

This PR replaces a bunch of options in `eframe::NativeOptions` with
`egui::ViewportBuilder`. For instance:

``` diff
 let options = eframe::NativeOptions {
-    initial_window_size: Some(egui::vec2(320.0, 240.0)),
-    drag_and_drop_support: true,
+    viewport: egui::ViewportBuilder::default()
+        .with_inner_size([320.0, 240.0])
+        .with_drag_and_drop(true),
     centered: true,
     ..Default::default()
 };
```
2023-11-19 11:08:47 +01:00
lilly lizard 3a8ed37f49
Mention that the trace! macro was removed in the 0.23.0 changelog (#3567)
Was trying to figure out why `trace!` was removed in 0.23 and realized
it wasn't in the changelog. It was removed as part of
[#3391](https://github.com/emilk/egui/pull/3391)
2023-11-18 19:38:09 +01:00
Emil Ernerfeldt a0d092f38e Fix panic when resetting areas. Closes #3566 2023-11-18 19:37:55 +01:00
Emil Ernerfeldt 1571027556
Replace `eframe::Frame` commands and `WindowInfo` with egui (#3564)
* Part of https://github.com/emilk/egui/issues/3556

## In short
You now almost never need to use `eframe::Frame` - instead use
`ui.input(|i| i.viewport())` for information about the current viewport
(native window), and use `ctx.send_viewport_cmd` to modify it.

## In detail

This PR removes most commands from `eframe::Frame`, and replaces them
with `ViewportCommand`.
So `frame.close()` becomes
`ctx.send_viewport_cmd(ViewportCommand::Close)`, etc.

`frame.info().window_info` is now also gone, replaced with `ui.input(|i|
i.viewport())`.

`frame.info().native_pixels_per_point` is replaced with `ui.input(|i|
i.raw.native_pixels_per_point)`.

`RawInput` now contains one `ViewportInfo` for each viewport.

Screenshots are taken with
`ctx.send_viewport_cmd(ViewportCommand::Screenshots)` and are returned
in `egui::Event` which you can check with:

``` ust
ui.input(|i| {
    for event in &i.raw.events {
        if let egui::Event::Screenshot { viewport_id, image } = event {
            // handle it here
        }
    }
});
```

### Motivation
You no longer need to pass around the `&eframe::Frame` everywhere.
This also opens the door for other integrations to use the same API of
`ViewportCommand`s.
2023-11-18 19:27:53 +01:00
YgorSouza 3e37e9dfc7
Update hyperlink doc (#3561)
<!--
Please read the "Making a PR" section of
[`CONTRIBUTING.md`](https://github.com/emilk/egui/blob/master/CONTRIBUTING.md)
before opening a Pull Request!

* Keep your PR:s small and focused.
* If applicable, add a screenshot or gif.
* If it is a non-trivial addition, consider adding a demo for it to
`egui_demo_lib`, or a new example.
* Do NOT open PR:s from your `master` branch, as that makes it hard for
maintainers to add commits to your PR.
* Remember to run `cargo fmt` and `cargo cranky`.
* Open the PR as a draft until you have self-reviewed it and run
`./scripts/check.sh`.
* When you have addressed a PR comment, mark it as resolved.

Please be patient! I will review your PR, but my time is limited!
-->

Closes <https://github.com/emilk/egui/issues/3474>.
2023-11-18 17:13:03 +01:00
Emil Ernerfeldt beb4714e40 Update the web-demo CI action with the new folder name 2023-11-16 16:45:06 +01:00
Emil Ernerfeldt 94edb9d5e0 Rename `docs/` to `web_demo/` 2023-11-16 16:44:30 +01:00
Emil Ernerfeldt 8723c5a4d3 Try another gh-pages publish workflow 2023-11-16 16:32:19 +01:00
Emil Ernerfeldt 8a66040ad9
CI: Add workflow to publish web-demo to `gh-pages` branch on each PR (#3559)
The goal is to host the egui web-demo on its own `gh-pages` branch, and
have the CI build and publish a new demo on each merged CI.

Let's see if I can get this to work…
2023-11-16 16:23:31 +01:00
Emil Ernerfeldt f01b2b76c8
Fix clippy issues from 1.74 (#3558)
Nothing major
2023-11-16 15:50:44 +01:00
Emil Ernerfeldt a243180600
Add `#[inline]` to all builder-pattern functions (#3557)
Better performance and maybe code size
2023-11-16 13:50:05 +01:00
arduano 4886c8c8c0
Max window size & other size helpers (#3537)
Was a bit confused why the max_size API isn't exposed on `Window`, when
it's perfectly functional in `Resize`. Anyway here's the main thing that
it affects:

```rs
let screen = ctx.available_rect();
let size = screen.size();

egui::Window::new(self.name())
    .resizable(true)
    .resize(|resize| resize.max_size(size)) // Before
    .max_size(size)                         // After
    .show(ctx, |ui| todo!());
```

I also added some other relevant helpers for consistency.

This PR doesn't change any logic, only forwards along some helper
functions that are already public for consistency.
2023-11-16 11:59:08 +01:00
Konkitoman 83aa3109d3
Multiple viewports/windows (#3172)
* Closes #1044

---
(new PR description written by @emilk)

## Overview
This PR introduces the concept of `Viewports`, which on the native
eframe backend corresponds to native OS windows.

You can spawn a new viewport using `Context::show_viewport` and
`Cotext::show_viewport_immediate`.
These needs to be called every frame the viewport should be visible.

This is implemented by the native `eframe` backend, but not the web one.

## Viewport classes
The viewports form a tree of parent-child relationships.

There are different classes of viewports.

### Root vieport
The root viewport is the original viewport, and cannot be closed without
closing the application.

### Deferred viewports
These are created with `Context::show_viewport`.
Deferred viewports take a closure that is called by the integration at a
later time, perhaps multiple times.
Deferred viewports are repainted independenantly of the parent viewport.
This means communication with them need to done via channels, or
`Arc/Mutex`.

This is the most performant type of child viewport, though a bit more
cumbersome to work with compared to immediate viewports.

### Immediate viewports
These are created with `Context::show_viewport_immediate`.
Immediate viewports take a `FnOnce` closure, similar to other egui
functions, and is called immediately. This makes communication with them
much simpler than with deferred viewports, but this simplicity comes at
a cost: whenever tha parent viewports needs to be repainted, so will the
child viewport, and vice versa. This means that if you have `N`
viewports you are poentially doing `N` times as much CPU work. However,
if all your viewports are showing animations, and thus are repainting
constantly anyway, this doesn't matter.

In short: immediate viewports are simpler to use, but can waste a lot of
CPU time.

### Embedded viewports
These are not real, independenant viewports, but is a fallback mode for
when the integration does not support real viewports. In your callback
is called with `ViewportClass::Embedded` it means you need to create an
`egui::Window` to wrap your ui in, which will then be embedded in the
parent viewport, unable to escape it.


## Using the viewports
Only one viewport is active at any one time, identified wth
`Context::viewport_id`.
You can send commands to other viewports using
`Context::send_viewport_command_to`.

There is an example in
<https://github.com/emilk/egui/tree/master/examples/multiple_viewports/src/main.rs>.

## For integrations
There are several changes relevant to integrations.

* There is a [`crate::RawInput::viewport`] with information about the
current viewport.
* The repaint callback set by `Context::set_request_repaint_callback`
now points to which viewport should be repainted.
* `Context::run` now returns a list of viewports in `FullOutput` which
should result in their own independant windows
* There is a new `Context::set_immediate_viewport_renderer` for setting
up the immediate viewport integration
* If you support viewports, you need to call
`Context::set_embed_viewports(false)`, or all new viewports will be
embedded (the default behavior).


## Future work
* Make it easy to wrap child viewports in the same chrome as
`egui::Window`
* Automatically show embedded viewports using `egui::Window`
* Use the new `ViewportBuilder` in `eframe::NativeOptions`
* Automatically position new viewport windows (they currently cover each
other)
* Add a `Context` method for listing all existing viewports

Find more at https://github.com/emilk/egui/issues/3556




---

<details>
<summary>
Outdated PR description by @konkitoman
</summary>


## Inspiration
- Godot because the app always work desktop or single_window because of
embedding
- Dear ImGui viewport system

## What is a Viewport

A Viewport is a egui isolated component!
Can be used by the egui integration to create native windows!

When you create a Viewport is possible that the backend do not supports
that!
So you need to check if the Viewport was created or you are in the
normal egui context!
This is how you can do that:
```rust
if ctx.viewport_id() != ctx.parent_viewport_id() {
    // In here you add the code for the viewport context, like
    egui::CentralPanel::default().show(ctx, |ui|{
        ui.label("This is in a native window!");
    });
}else{
    // In here you add the code for when viewport cannot be created!
   // You cannot use CentralPanel in here because you will override the app CentralPanel
   egui::Window::new("Virtual Viewport").show(ctx, |ui|{
       ui.label("This is without a native window!\nThis is in a embedded viewport");
   });
}
```

This PR do not support for drag and drop between Viewports!

After this PR is accepted i will begin work to intregrate the Viewport
system in `egui::Window`!
The `egui::Window` i want to behave the same on desktop and web
The `egui::Window` will be like Godot Window

## Changes and new

These are only public structs and functions!

<details>
<summary>

## New
</summary>

- `egui::ViewportId`
- `egui::ViewportBuilder`
This is like winit WindowBuilder

- `egui::ViewportCommand`
With this you can set any winit property on a viewport, when is a native
window!

- `egui::Context::new`
- `egui::Context::create_viewport`
- `egui::Context::create_viewport_sync`
- `egui::Context::viewport_id`
- `egui::Context::parent_viewport_id`
- `egui::Context::viewport_id_pair`
- `egui::Context::set_render_sync_callback`
- `egui::Context::is_desktop`
- `egui::Context::force_embedding`
- `egui::Context::set_force_embedding`
- `egui::Context::viewport_command`
- `egui::Context::send_viewport_command_to`
- `egui::Context::input_for`
- `egui::Context::input_mut_for`
- `egui::Context::frame_nr_for`
- `egui::Context::request_repaint_for`
- `egui::Context::request_repaint_after_for`
- `egui::Context::requested_repaint_last_frame`
- `egui::Context::requested_repaint_last_frame_for`
- `egui::Context::requested_repaint`
- `egui::Context::requested_repaint_for`
- `egui::Context::inner_rect`
- `egui::Context::outer_rect`

- `egui::InputState::inner_rect`
- `egui::InputState::outer_rect`

- `egui::WindowEvent`

</details>

<details>
<summary>

## Changes
</summary>

- `egui::Context::run`
Now needs the viewport that we want to render!

- `egui::Context::begin_frame`
Now needs the viewport that we want to render!

- `egui::Context::tessellate`
Now needs the viewport that we want to render!

- `egui::FullOutput`
```diff
- repaint_after
+ viewports
+ viewport_commands
```

- `egui::RawInput`
```diff
+ inner_rect
+ outer_rect
```

- `egui::Event`
```diff
+ WindowEvent
```
</details>

### Async Viewport

Async means that is independent from other viewports!

Is created by `egui::Context::create_viewport`

To be used you will need to wrap your state in `Arc<RwLock<T>>`
Look at viewports example to understand how to use it!

### Sync Viewport

Sync means that is dependent on his parent!

Is created by `egui::Context::create_viewport_sync`

This will pause the parent then render itself the resumes his parent!

#### ⚠️ This currently will make the fps/2 for every sync
viewport

### Common

#### ⚠️ Attention

You will need to do this when you render your content
```rust
ctx.create_viewport(ViewportBuilder::new("Simple Viewport"), | ctx | {
    let content = |ui: &mut egui::Ui|{
        ui.label("Content");
    };

    // This will make the content a popup if cannot create a native window
    if ctx.viewport_id() != ctx.parent_viewport_id() {
        egui::CentralPanel::default().show(ctx, content);
    } else {
        egui::Area::new("Simple Viewport").show(ctx, |ui| {
            egui::Frame::popup(ui.style()).show(ui, content);
        });
    };
});
````

## What you need to know as egui user

### If you are using eframe

You don't need to change anything!

### If you have a manual implementation

Now `egui::run` or `egui::begin` and `egui::tessellate` will need the
current viewport id!
You cannot create a `ViewportId` only `ViewportId::MAIN`

If you make a single window app you will set the viewport id to be
`egui::ViewportId::MAIN` or see the `examples/pure_glow`
If you want to have multiples window support look at `crates/eframe`
glow or wgpu implementations!

## If you want to try this

- cargo run -p viewports

## This before was wanted to change

This will probably be in feature PR's

### egui::Window

To create a native window when embedded was set to false
You can try that in viewports example before:
[78a0ae8](78a0ae879e)

### egui popups, context_menu, tooltip

To be a native window

</details>

---------

Co-authored-by: Konkitoman <konkitoman@users.noreply.github.com>
Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
Co-authored-by: Pablo Sichert <mail@pablosichert.com>
2023-11-16 11:25:05 +01:00
LoganDark fb8fa67afd
egui: fix scroll not sticking when scrollbar is hidden (#3434)
Before:


https://github.com/emilk/egui/assets/4723091/4b42842c-4f34-45d1-9538-29cd0bfd614e


https://github.com/emilk/egui/assets/4723091/7544e300-5b9a-4b2b-aaa4-9acade69fa75

After:


https://github.com/emilk/egui/assets/4723091/d720286f-a166-4891-874a-350b15683587
2023-11-15 08:04:03 +01:00
Andreas Reich cd46691423
Updated to latest wgpu (0.18.0) (#3505)
Tested on M1 Mac:
* native
* webgl, firefox
* webgpu, chrome

all looking normal


Updated minor ahash version because 0.8.1 got yanked. Added some deny
exceptions for now - we'll have to update winit soon to resolve glow
related cargo deny errors (not a big issue though since we don't expect
wgpu and glow backends to be used at the same time)
2023-11-11 21:58:32 +01:00
Emil Ernerfeldt 6ba356d3d8
Replace `Id::null()` with `Id::NULL` (#3544)
Shorter and more idiomatic
2023-11-11 21:40:02 +01:00
Emil Ernerfeldt b27aa27e94
Add `emath::Vec2b`, replacing `egui_plot::AxisBools` (#3543)
Thanks to `impl From<bool> for Vec2b` one can now shorten some builder
calls, like:

Previous:
```rust
 egui::ScrollArea::vertical()
        .auto_shrink([false; 2])
```

New:
```rust
 egui::ScrollArea::vertical()
        .auto_shrink(false)
```
2023-11-11 21:31:36 +01:00