All notable changes to the egui
crate will be documented in this file.
NOTE: this is just the changelog for the core egui
crate. eframe
, ecolor
, epaint
, egui-winit
, egui_glow
and egui-wgpu
have their own changelogs!
This file is updated upon each release.
Changes since the last release can be found at https://github.com/emilk/egui/compare/latest...HEAD or by running the scripts/generate_changelog.py
script.
- Add
Image::uri()
#4720 by @rustbasic
- Better documentation for
Event::Zoom
#4778 by @emilk - Hide tooltips when scrolling #4784 by @emilk
- Smoother animations #4787 by @emilk
- Hide tooltip on click #4789 by @emilk
- Fix default height of top/bottom panels #4779 by @emilk
- Show the innermost debug rectangle when pressing all modifier keys #4782 by @emilk
- Fix occasional flickering of pointer-tooltips #4788 by @emilk
- Automatic sizing of menus/popups/tooltips with no jittering, using new sizing pass #4557, #4579 by @emilk
- Support interactive widgets in tooltips #4596 by @emilk
- Add a
ui.stack()
with info about all ancestorUi
s, with optional tags #4588 by @abey79, #4617 by @emilk - GIF support #4620 by @JustFrederik
- Blinking text cursor in
TextEdit
#4279 by @emilk
- Update MSRV to 1.76 (#4411)
- The
wrap/truncate
functions onLabel/Button/ComboBox
no longer take bools as arguments. Use.wrap_mode(…)
instead for more fine control (#4556) Style::wrap
has been deprecated in favor ofStyle::wrap_mode
(#4556)Ui::new
andui.child_ui
now takes a new parameter for theUiStack
(#4588)- The
extra_asserts
andextra_debug_asserts
feature flags have been removed (#4478) - Remove
Event::Scroll
and handle it in egui. UseEvent::MouseWheel
instead (#4524) Event::Zoom
is no longer emitted on ctrl+scroll. UseInputState::smooth_scroll_delta
instead (#4524)ui.set_enabled
andset_visbile
have been deprecated (#4614)DragValue::clamp_range
renamed torange
((#4728)
- Overload operators for
Rect + Margin
,Rect - Margin
etc #4277 by @emilk - Add
Window::order
#4301 by @alexparlett - Add a way to specify Undoer settings and construct Undoers more easily #4357 by @valadaptive
- Add xtask crate #4293 by @YgorSouza
- Add
ViewportCommand::RequestCut
,RequestCopy
andRequestPaste
to trigger clipboard actions #4035 by @bu5hm4nn - Added ability to define colors at UV coordinates along a path #4353 by @murl-digital
- Add a
Display
impl forVec2
,Pos2
, andRect
#4428 by @tgross35 - Easing functions #4630 by @emilk
- Add
Options::line_scroll_speed
andscroll_zoom_speed
#4532 by @emilk - Add
TextEdit::hint_text_font
#4517 by @zaaarf - Add
Options::reduce_texture_memory
to free up RAM #4431 by @varphone - Add support for text truncation to
egui::Style
#4556 by @abey79 - Add
Response::show_tooltip_ui
andshow_tooltip_text
#4580 by @emilk - Add
opacity
andmultiply_opacity
functions toUi
andPainter
#4586 by @emilk - Add
Key::Quote
#4683 by @mkeeter - Improve backtraces when hovering widgets with modifiers pressed #4696 by @emilk
- Add
PopupCloseBehavior
#4636 by @Umatriz - Add basic test for egui accesskit output #4716 by @Wcubed
- Add
clamp_to_range
option to DragValue, renameclamp_range
torange
(deprecating the former) #4728 by @Wumpf - Add
Style::number_formatter
as the default used byDragValue
#4740 by @emilk
- Improve the UI for changing the egui theme #4257 by @emilk
- Change the resize cursor when you reach the resize limit #4275 by @emilk
- Make
TextEdit
an atomic widget #4276 by @emilk - Rename
fn scroll2
tofn scroll
#4282 by @emilk - Change
Frame::multiply_with_opacity
to multiply in gamma space #4283 by @emilk - Use parent
Ui
s style for popups #4325 by @alexparlett - Take
rounding
into account when usingSlider::trailing_fill
#4308 by @rustbasic - Allow users to create viewports larger than monitor on Windows & macOS #4337 by @lopo12123
- Improve
ViewportBuilder::with_icon()
documentation #4408 by @roccoblues include_image!
now accepts expressions #4521 by @YgorSouza- Remove scroll latency for smooth trackpads #4526 by @emilk
- Smooth out zooming with discreet scroll wheel #4530 by @emilk
- Make
TextEdit::return_key
optional #4543 by @doonv - Better spacing and sizes for (menu) buttons #4558 by @emilk
ComboBox
: fix justified layout of popup if wider than parent button #4570 by @emilk- Make
Area
state public #4576 by @emilk - Don't persist
Area
size #4749 by @emilk - Round text galley sizes to nearest UI point size #4578 by @emilk
- Once you have waited for a tooltip to show, show the next one right away #4585 by @emilk
- Fade in windows, tooltips, popups, etc #4587 by @emilk
- Make
egu::menu
types public #4544 by @sor-ca - The default constrain rect for
Area/Window
is nowctx.screen_rect
#4590 by @emilk - Constrain
Area
s to screen by default #4591 by @emilk Grid
: set thesizing_pass
flag during the initial sizing pass #4612 by @emilk- Remove special case for 0 in DragValue default formatter #4639 by @YgorSouza
- Abort drags when pressing escape key #4678 by @emilk
- Allow setting a layer as a sublayer of another #4690 by @YgorSouza
- Close context menus with Escape #4711 by @emilk
- Cancel DragValue edit if Escape is pressed #4713 by @YgorSouza
- The default parser for
DragValue
andSlider
now ignores whitespace #4739 by @emilk - Disabled widgets are now also disabled in the accesskit output #4750 by @Wcubed
- Make it easier to grab the handle of a floating scroll bar #4754 by @emilk
- When debugging widget rects on hover, show width and height #4762 by @emilk
- Make sure all tooltips close if you open a menu in the same layer #4766 by @emilk
- Fix wrong replacement function in deprecation notice of
drag_released*
#4314 by @sornas - Consider layer transform when positioning text agent #4319 by @juancampa
- Fix incorrect line breaks #4377 by @juancampa
- Fix
hex_color!
macro by re-exportingcolor_hex
crate fromecolor
#4372 by @dataphract - Change
Ui::allocate_painter
to inherit properties fromUi
#4343 by @varphone - Fix
Panel
incorrect size #4351 by @zhatuokun - Improve IME support with new
Event::Ime
#4358 by @rustbasic - Disable interaction for
ScrollArea
andPlot
when UI is disabled #4457 by @varphone - Don't panic when replacement glyph is not found #4542 by @RyanBluth
- Fix
Ui::scroll_with_delta
only scrolling if theScrollArea
is focused #4303 by @lucasmerlin - Handle tooltips so large that they cover the widget #4623 by @emilk
- ScrollArea: Prevent drag interaction outside the area #4611 by @s-nie
- Fix buggy interaction with widgets outside of clip rect #4675 by @emilk
- Make sure contents of a panel don't overflow #4676 by @emilk
- Fix:
Response::hover_pos
returns incorrect positions with layer transforms #4679 by @Creative0708 - Fix: Menu popups and tooltips don't respect layer transforms #4708 by @Creative0708
- Bug fix: report latest area size in
Area::show
response #4710 by @emilk - Ensure
Window
scroll bars are at the window edges #4733 by @emilk - Prevent
TextEdit
widgets from sending fake primary clicks #4751 by @Aliremu - Fix text selection when there's multiple viewports #4760 by @emilk
- Use correct cursor icons when resizing panels too wide or narrow #4769 by @emilk
- Fix tooltips for non-interactive widgets #4291
- Fix problem clicking the edge of a
TextEdit
#4272 - Fix:
Response::clicked_elsewhere
takes clip rect into account #4274 - Fix incorrect
Response::interact_rect
forArea/Window
#4273
- Allow disabling animations on a
ScrollArea
#4309 (thanks @lucasmerlin!)
- Fix visual glitch on the right side of highly rounded rectangles #4244
- Prevent visual glitch when shadow blur width is very high #4245
- Fix
InputState::any_touches
and addInputState::has_touch_screen
#4247 - Fix
Context::repaint_causes
returning no causes #4248 - Fix touch-and-hold to open context menu #4249
- Hide shortcut text on zoom buttons if
zoom_with_keyboard
is false #4262
- Don't apply a clip rect to the contents of an
Area
orWindow
#4258
The hit test logic (what is the user clicking on?) has been completely rewritten, and should now be much more accurate and helpful.
The hit test and interaction logic is run at the start of the frame, using the widgets rects from the previous frame, but the latest mouse coordinates.
It enabled getting a Response
for a widget before creating it using Context::read_response
.
This will in the future unlock more powerful widget styling options.
The new hit test also allows clicking slightly outside a button and still hit it, improving the support for touch screens.
The menus have also been improved so that they both act and feel better, with no change in API. Included in this is much nicer looking shadows, supporting an offset.
Response::clicked*
andResponse::dragged*
may lock theContext
, so don't call it from aContext
-locking closure.Response::clicked_by
will no longer be true if clicked with keyboard. UseResponse::clicked
instead.Memory::focus
has been renamedMemory::focused
Area::new
now takes anId
by argument #4115- Change the definition of
clicked_by
#4192
- Add some distance between parent menu and submenu #4230
- Add
Area::sense
and improve hit-testing of buttons in menus #4234 - Improve logic for when submenus are kept open #4166
- Better align menus with the button that opened them #4233
- Hide hover UI when showing the context menu #4138 (thanks @abey79!)
- CSS-like
Shadow
with offset, spread, and blur #4232 - On touch screens, press-and-hold equals a secondary click #4195
- Add with_taskbar to viewport builder #3958 (thanks @AnotherNathan!)
- Add F21 to F35 key bindings #4004 (thanks @oscargus!)
- Add
Options::debug_paint_interactive_widgets
#4018 - Add
Ui::set_opacity
#3965 (thanks @YgorSouza!) - Add
Response::paint_debug_info()
to make it easy to visualize a widget's id and state #4056 (thanks @abey79!) - Add layer transforms, interaction in layer #3906 (thanks @Tweoss!)
- Add
ColorImage::from_gray_iter
#3536 (thanks @wangxiaochuTHU!) - Add API for raw mouse motion #4063 (thanks @GiantBlargg!)
- Add accessibility to
ProgressBar
andSpinner
#4139 (thanks @DataTriny!) - Add x11 window type settings to viewport builder #4175 (thanks @psethwick!)
- Add an API for customizing the return key in TextEdit #4085 (thanks @lemon-sh!)
- Convenience
const fn
forMargin
,Rounding
andShadow
#4080 (thanks @0Qwel!) - Serde feature: add serde derives to input related structs #4100 (thanks @gweisert!)
- Give each menu
Area
an id distinct from the id of what was clicked #4114 epaint
: AddedShape::{scale,translate}
wrappers #4090 (thanks @varphone!)- A
Window
can now be resizable in only one direction #4155 - Add
EllipseShape
#4122 (thanks @TheTacBanana!) - Adjustable Slider rail height #4092 (thanks @rustbasic!)
- Expose state override for
HeaderResponse
#4200 (thanks @Zeenobit!)
TextEdit
: Changemargin
property toegui::Margin
type #3993 (thanks @bu5hm4nn!)- New widget interaction logic #4026
ui.dnd_drop_zone()
now returnsInnerResponse
. #4079 (thanks @sowbug!)- Support interacting with the background of a
Ui
#4074 - Quickly animate scroll when calling
ui.scroll_to_cursor
etc #4119 - Don't clear modifier state on focus change #4157 (thanks @ming08108!)
- Prevent
egui::Window
from becoming larger than viewport #4199 (thanks @rustbasic!) - Don't show URLs when hovering hyperlinks #4218
- Fix incorrect handling of item spacing in
Window
title bar #3995 (thanks @varphone!) - Make
on_disabled_hover_ui
respecttooltip_delay
#4012 (thanks @YgorSouza!) - Fix
TextEdit
being too short whenever there is horizontal margin #4005 (thanks @gweisert!) - Fix
Response::interact
andUi:interact_with_hovered
#4013 - Fix:
Response.interact_pointer_pos
isSome
on click and drag released #4014 - Fix custom
Window
Frame
s #4009 (thanks @varphone!) - Fix: images with background color now respects rounding #4029 (thanks @vincent-sparks!)
- Fixed the incorrect display of the
Window
frame with a wide border or large rounding #4032 (thanks @varphone!) - TextEdit: fix crash when hitting SHIFT + TAB around non-ASCII text #3984 (thanks @rustbasic!)
- Fix two
ScrollArea
bugs: leaking scroll target and broken animation to target offset #4174 (thanks @abey79!) - Fix bug in
Context::parent_viewport_id
#4190 (thanks @rustbasic!) - Remove unnecessary allocation in
RepaintCause::new
#4146 (thanks @valsteen!)
- Fix
Window
title bar incorrect handling spacing #3995 (thanks @varphone!) - Make
on_disabled_hover_ui
respecttooltip_delay
#4012 (thanks @YgorSouza!) - Fix
TextEdit
being too short whenever there is horizontal margin #4005 (thanks @gweisert!) - Fix
Response::interact
andUi:interact_with_hovered
#4013 - Fix:
Response.interact_pointer_pos
isSome
on click and drag released #4014 - Fix custom
Window
Frame
s #4009 (thanks @varphone!)
- Always set
response.hovered
to false when dragging another widget #3860 InputState::scroll_delta
has been replaced byInputState::raw_scroll_delta
andInputState::smooth_scroll_delta
#3884- Improve
Response.dragged
,drag_started
andclicked
#3888
- Selectable text in Labels #3814 #3870
- Add some drag-and-drop-related APIs in
Response
andMemory
#3876 (thanks @abey79!) - Add drag-and-drop APIs with payloads storage #3887
ComboBox
: add builder method for height #3001 (thanks @hinto-janai!)- Add keys
?
,/
,|
#3820 - Add
Response::contains_pointer
#3859 - Add
Align2::anchor_size
#3863 - Add
Context::debug_text
#3864 - Allow read access to shapes added to painter this frame #3866 (thanks @brunizzl!)
- Register callbacks with
Context::on_begin_frame
andon_end_frame
#3886 - Improve
Frame
API to allow picking color until after adding content #3889 - Add opacity factor to
TextShape
#3916 (thanks @StratusFearMe21!) Context::repaint_causes
:file:line
of what caused a repaint #3949- Add
TextureOptions::wrap_mode
#3954 (thanks @CodedNil!) - Add
Spacing::menu_width
#3973
- Move text selection logic to own module #3843
- Smooth scrolling #3884
- Turn off text wrapping by default in combo-box popups #3912
Response.context_menu
now returns the response of the context menu, if open #3904 (thanks @AufarZakiev!)- Update to puffin 0.19 #3940
- Wait with showing tooltip until mouse has been still for 300ms #3977
- Fix: dragging to above/below a
TextEdit
orLabel
will select text to begin/end #3858 - Fix clickable widgets blocking scrolling on touch screens #3815 (thanks @lucasmerlin!)
- Fix
stable_dt
#3832 - Bug Fix :
Response::is_pointer_button_down_on
is now false the frame the button is released #3833 (thanks @rustbasic!) - Use runtime knowledge of OS for OS-specific text editing #3840
- Fix calling
request_repaint_after
every frame causing immediate repaint #3978
- Niche-optimize
Id
so thatOption<Id>
is the same size asId
#3932 - Parallel tessellation with opt-in
rayon
feature #3934
- Ignore extra SHIFT and ALT when matching modifiers #3769
- Replace
Key::PlusEquals
withKey::Plus
andKey::Equals
#3769 - Removed
WidgetTextGalley
,WidgetTextJob
,RichText::into_text_job
,WidgetText::into_text_job
#3727 - Rename
TextBuffer::replace
toreplace_with
#3751
- Replace a special
Color32::PLACEHOLDER
with widget fallback color #3727 - Add
Key
s forCut
Copy
Paste
[
]
,
\
:
.
;
+
=
#3725 #3373 #3649 #3769 (thanks @MarijnS95 and @mkrueger!) - Add
Key::from_name
,Key::ALL
#3649 - Add
Event::Key::physical_key
#3649 - Add indeterminate state to checkbox #3605 (thanks @YgorSouza!)
- Add
Color32::from_hex
andColor32::to_hex
#3570 #3777 (thanks @YgorSouza!) - Add
DragValue
s for RGB(A) in the color picker #2734 (thanks @IVAN-MK7!) - Add option to customize progress bar rounding #2881 (thanks @YgorSouza!)
- Add methods to load/store
TextEditState
undoer #3479 (thanks @LoganDark!) ScrollArea
: Add option to always scroll the only enabled direction #3710 (thanks @untbu!)
Grid
now followsstyle.visuals.striped
if not explicitly overwritten #3723 (thanks @Wcubed!)- Allow arrow keys to move away focus from a Slider #3641 (thanks @fornwall!)
- Keep submenus open until another one is hovered #3055 (thanks @DannyStoll1!)
- Highlight the header of the topmost
Window
, controlled byVisuals.window_highlight_topmost
#3515 (thanks @GuillaumeSchmid!)
- Derive
serde
Serialize
andDeserialize
forKeyboardShortcut
#3694 (thanks @zeozeozeo!) - Fix
Window
positioning bug when badpivot
is stored in app data #3721 (thanks @abey79!) - Impl
Clone
forFonts
#3737 - Add missing
ResizeDirection::East
#3749 (thanks @dbuch!) - Fix: don't open context menu on drag #3767
- Fix IME input of
CompositionEnd
without aCompositionStart
#3768 (thanks @FrankLeeC!) - Fix: allow using the full Private Use Area for custom fonts #3509 (thanks @varphone!)
- Fix: apply edited
DragValue
when it looses focus #3776 - Fix: Non-resizable
Area
s now ignore mouse input outside their bounds #3039 (thanks @fleabitdev!) - Highlight submenu buttons when hovered and open #3780
- Invalidate font atlas on any change to
pixels_per_point
, not matter how small #3698 (thanks @StarStarJ!) - Fix zoom-in shortcut (
Cmd +
) on non-English keyboards #3769
- Fix buggy text with multiple viewports on monitors with different scales #3666
You can now spawn multiple native windows on supported backends (e.g. eframe
), using the new viewport
API (#3172).
You can easily zoom any egui app using Cmd+Plus, Cmd+Minus or Cmd+0, just like in a browser (#3608).
Scrollbars are now hidden by default until you hover the ScrollArea
(#3539).
- Multiple viewports/windows #3172 (thanks @konkitoman!)
- Introduce global
zoom_factor
#3608 - Floating scroll bars #3539
- Add redo support to
Undoer
#3478 (thanks @LoganDark!) - Add
egui::Vec2b
#3543 - Add max
Window
size & other size helpers #3537 (thanks @arduano!) - Allow changing shape of slider handle #3429 (thanks @YgorSouza!)
RawInput::viewports
contains a list of all viewports. Access the current one withctx.input(|i| i.viewport())
- Fix upside down slider in the vertical orientation #3424 (thanks @YgorSouza!)
- Make slider step account for range start #3488 (thanks @YgorSouza!)
- Fix rounding of
ImageButton
#3531 (thanks @chriscate!) - Fix naming:
constraint_to
->constrain_to
#3438 (thanks @rinde!) - Fix Shift+Tab behavior when no widget is focused #3498 (thanks @DataTriny!)
- Fix scroll not sticking when scrollbar is hidden #3434 (thanks @LoganDark!)
- Add
#[inline]
to all builder-pattern functions #3557 - Properly reverse bool animation if value changes before it's finished #3577 (thanks @YgorSouza!)
egui::gui_zoom::zoom_with_keyboard_shortcuts
is gone, replaced withOptions::zoom_with_keyboard
, which istrue
by defaultSpacing::scroll_bar_X
has been moved toSpacing::scroll_bar.X
Context::set_pixels_per_point
now callsContext::set_zoom_level
, and it may make sense for you to call that directly instead- If you are using
eframe
, check out the breaking changes in theeframe
changelog
There are several changes relevant to integrations.
- Added
crate::RawInput::viewports
with information about all active viewports - The repaint callback set by
Context::set_request_repaint_callback
now points to which viewport should be repainted Context::run
now returns a list ofViewportOutput
inFullOutput
which should result in their own independent 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)
This release contains a simple and powerful image API:
// Load from web:
ui.image("https://www.example.com/some_image.png");
// Include image in the binary using `include_bytes`:
ui.image(egui::include_image!("../assets/ferris.svg"));
// With options:
ui.add(
egui::Image::new("file://path/to/image.jpg")
.max_width(200.0)
.rounding(10.0),
);
The API is based on a plugin-system, where you can tell egui
how to load the images, and from where.
egui_extras
comes with loaders for you, so all you need to do is add the following to your Cargo.toml
:
egui_extras = { version = "0.23", features = ["all_loaders"] }
image = { version = "0.24", features = ["jpeg", "png"] } # Add the types you want support for
And this to your code:
egui_extras::install_image_loaders(egui_ctx);
- A new image API #3297 #3315 #3328 #3338 #3342 #3343 #3402 (thanks @jprochazk!)
- Add option to truncate text at some width #3244
- Add control of line height and letter spacing #3302
- Support images with rounded corners #3257
- Change focused widget with arrow keys #3272 (thanks @TimonPost!)
- Add opt-in
puffin
feature to egui #3298 - Add debug-option to show a callstack to the widget under the mouse and removed the
trace!
macro as this is more useful #3391 - Add
Context::open_url
andContext::copy_text
#3380 - Add
Area::constrain_to
andWindow::constrain_to
#3396 - Add
Memory::area_rect
#3161 (thanks @tosti007!) - Add
Margin::expand_rect
andshrink_rect
#3214 - Provide
into_inner()
foregui::mutex::{Mutex, RwLock}
#3110 (thanks @KmolYuan!) - Support multi-threaded Wasm #3236
- Change touch force to be
Option<f32>
instead off32
#3240 (thanks @lucasmerlin!) - Add option to always open hyperlink in a new browser tab #3242 (thanks @FreddyFunk!)
- Add
Window::drag_to_scroll
#3118 (thanks @KYovchevski!) - Add
CollapsingState::remove
to clear stored state #3252 (thanks @dmackdev!) - Add tooltip_delay option #3245 (thanks @YgorSouza!)
- Added
Context::is_context_menu_open()
#3267 (thanks @dmlary!) - Add
mime
field toDroppedFile
#3273 (thanks @abey79!) - Allow setting the progress bar height #3183 (thanks @s-nie!)
- Add
scroll_area::State::velocity
#3300 (thanks @Barugon!) - Add
Visuals::interact_cursor
#3312 (thanks @zkldi!) - Add method to
RichText
making it easier to construct layout jobs #3319 (thanks @OmegaJak!) - Add
Context::style_mut
#3359 std::borrow::Cow<'_, str>
now implementsTextBuffer
#3164 (thanks @burtonageo!)
- Separate text cursor from selection visuals #3181 (thanks @lampsitter!)
DragValue
: update value on each key press by default #2880 (thanks @Barugon!)- Replace uses of
RangeInclusive<f32>
withemath::Rangef
#3221 - Implement
Send + Sync
forColorPickerFn
andUi
(#3148) #3233 (thanks @idanarye!) - Use the minus character instead of "dash" #3271
- Changing
menu_image_button
to useImageButton
builder #3288 (thanks @v-kat!) - Prune old egui memory data when reaching some limit #3299
- Fix TextEdit's character limit #3173 (thanks @Serverator!)
- Set the correct unicode character for "ctrl" shortcuts #3186 (thanks @abey79!)
- Fix crash in
DragValue
when only settingmin_decimals
#3231 - Fix clipping issued with
ScrollArea
#2860 (thanks @Barugon!) - Fix moving slider with arrow keys #3354
- Fix problems with tabs in text #3355
- Fix interaction with moved color-picker #3395
- Scroll bar visibility options #2729 (thanks @IVAN-MK7!)
- Add
Grid::with_row_color
#2519 (thanks @imgurbot12!) - Add raw mouse wheel event #2782 (thanks @YgorSouza!)
- Improved plot groups and bounds handling #2410 (thanks @s-nie!)
- Return plot transforms #2935
- Add
Pointer::is_decidedly_dragging
andcould_any_button_be_click
#2979 - Plot widget - allow disabling zoom and drag for x and y separately #2901 (thanks @OmegaJak!)
- Add character limit to
TextEdit
#2816 (thanks @wzid!) - Add
egui::Modifiers::contains
#2989 (thanks @Wumpf!)
- Improve vertical alignment of fonts #2724 (thanks @lictex!)
- Transpose the value/satuation panel of the color picker #2727 (thanks @IVAN-MK7!)
- Replace
ComboBox::show_index
String
withInto<TextWidget>
#2790 (thanks @tosti007!) - Replace
tracing
withlog
#2928 - Only show id clash warnings in debug builds by default #2930
⚠️ BREAKING:Plot::link_axis
andPlot::link_cursor
now take the name of the group #2410
- Clear all keys and modifies on focus change, fixing "stuck keys" #2933
- Fix deadlock when using
show_blocking_widget
#2753 (thanks @YgorSouza!) - Fix the OS check for windows #2832 (thanks @jleibs!)
- Fix scroll bars not appearing (#2826) #2827 (thanks @lunixbochs!)
- Fix UI
data()
read mutability #2742 (thanks @IS2511!) - Menu State rect now uses menu frame rect instead of contents rect #2886 (thanks @hats-np!)
- Hide
Response::triple_clicked
in docs #2867 (thanks @ccaven!) request_repaint_after
works even when called from background thread #2939- Show alt key on Mac as
"Option"
, not"Alt"
#2981 (thanks @Wumpf!) - Mention
store
inTextEditState
doc comment #2988 (thanks @fxdave!) - Fix typos #2866 (thanks @fezjo!)
- Fix resizable columns option in the table demo #2780 (thanks @Bobo1239!)
- Update serial window example #2756 (thanks @c-git!)
- Demo app: use
enum
instead of strings for demo-selector anchor #2781 (thanks @XyLyXyRR!) - Use
env_logger
in all examples #2934 - Rename
examples/user_attention/README.mg
toREADME.md
#2948 (thanks @MAlba124!) - egui_demo_app: add some native window info b5c24d6
⚠️ BREAKING:egui::Context
now use closures for locking (#2625):ctx.input().key_pressed(Key::A)
->ctx.input(|i| i.key_pressed(Key::A))
ui.memory().toggle_popup(popup_id)
->ui.memory_mut(|mem| mem.toggle_popup(popup_id))
- Add
Response::drag_started_by
andResponse::drag_released_by
for convenience, similar todragged
anddragged_by
(#2507). - Add
PointerState::*_pressed
to check if the given button was pressed in this frame (#2507). Event::Key
now has arepeat
field that is set totrue
if the event was the result of a key-repeat (#2435).- Add
Slider::drag_value_speed
, which lets you ask for finer precision when dragging the slider value rather than the actual slider. - Add
Memory::any_popup_open
, which returns true if any popup is currently open (#2464). - Add
Plot::clamp_grid
to only show grid where there is data (#2480). - Add
ScrollArea::drag_to_scroll
if you want to turn off that feature. - Add
Response::on_hover_and_drag_cursor
. - Add
Window::default_open
(#2539). - Add
ProgressBar::fill
if you want to set the fill color manually. (#2618). - Add
Button::rounding
to enable round buttons (#2616). - Add
WidgetVisuals::optional_bg_color
- set it toColor32::TRANSPARENT
to hide button backgrounds (#2621). - Add
Context::screen_rect
andContext::set_cursor_icon
(#2625). - You can turn off the vertical line left of indented regions with
Visuals::indent_has_left_vline
(#2636). - Add
Response.highlight
to highlight a widget (#2632). - Add
Separator::grow
andSeparator::shrink
(#2665). - Add
Slider::trailing_fill
for trailing color behind the circle like aProgressBar
(#2660).
- Improved plot grid appearance (#2412).
- Improved the algorithm for picking the number of decimals to show when hovering values in the
Plot
. - Default
ComboBox
is now controlled withSpacing::combo_width
(#2621). DragValue
andSlider
now use the proportional font (#2638).ScrollArea
is less aggressive about clipping its contents (#2665).- Updated to be compatible with a major breaking change in AccessKit that drastically reduces memory usage when accessibility is enabled (#2678).
- Improve
DragValue
behavior (#2649, #2650, #2688, #2638).
- Trigger
PointerEvent::Released
for drags (#2507). - Expose
TextEdit
's multiline flag to AccessKit (#2448). - Don't render
\r
(Carriage Return) (#2452). - The
button_padding
style option works closer as expected with image+text buttons now (#2510). - Menus are now moved to fit on the screen.
- Fix
Window::pivot
causing windows to move around (#2694).
InputState
: all press functions again include key repeats (like in egui 0.19) (#2429).- Improve the look of thin white lines (#2437).
- Fix key-repeats for
TextEdit
,Slider
s, etc (#2429).
- MSRV (Minimum Supported Rust Version) is now
1.65.0
(#2314). ⚠️ BREAKING: egui now expects integrations to do all color blending in gamma space (#2071).⚠️ BREAKING: if you have overlapping interactive widgets, only the top widget (last added) will be interactive (#2244).
- Added helper functions for animating panels that collapse/expand (#2190).
- Added
Context::os/Context::set_os
to query/set what operating system egui believes it is running on (#2202). - Added
Button::shortcut_text
for showing keyboard shortcuts in menu buttons (#2202). - Added
egui::KeyboardShortcut
for showing keyboard shortcuts in menu buttons (#2202). - Texture loading now takes a
TextureOptions
with minification and magnification filters (#2224). - Added
Key::Minus
andKey::Equals
(#2239). - Added
egui::gui_zoom
module with helpers for scaling the whole GUI of an app (#2239). - You can now put one interactive widget on top of another, and only one will get interaction at a time (#2244).
- Added
spacing.menu_margin
for customizing menu spacing (#2036) - Added possibility to enable text wrap for the selected text of
egui::ComboBox
(#2272) - Added
Area::constrain
andWindow::constrain
which constrains area to the screen bounds (#2270). - Added
Area::pivot
andWindow::pivot
which controls what part of the window to position (#2303). - Added support for thin space.
- Added optional integration with AccessKit for implementing platform accessibility APIs (#2294).
- Added
panel_fill
,window_fill
andwindow_stroke
toVisuals
for your theming pleasure (#2406). - Plots:
- Panels always have a separator line, but no stroke on other sides. Their spacing has also changed slightly (#2261).
- Tooltips are only shown when mouse pointer is still (#2263).
- Make it slightly easier to click buttons (#2304).
egui::color
has been renamedegui::ecolor
(#2399).
⚠️ BREAKING: Fix text being too small (#2069).- Improve mixed CJK/Latin line-breaking (#1986).
- Improved text rendering (#2071).
- Constrain menu popups to the screen (#2191).
- Less jitter when calling
Context::set_pixels_per_point
(#2239). - Fixed popups and color edit going outside the screen.
- Fixed keyboard support in
DragValue
(#2342). - If you nest
ScrollAreas
inside each other, the inner area will now move its scroll bar so it is always visible (#2371). - Ignore key-repeats for
input.key_pressed
(#2334, #2389). - Fixed issue with calling
set_pixels_per_point
each frame (#2352). - Fix bug in
ScrollArea::show_rows
(#2258). - Fix bug in
plot::Line::fill
(#2275). - Only emit
changed
events inradio_value
andselectable_value
if the value actually changed (#2343). - Fixed sizing bug in
Grid
(#2384). ComboBox::width
now correctly sets the outer width (#2406).
- Added
*_released
&*_clicked
methods forPointerState
(#1582). - Added
PointerButton::Extra1
andPointerButton::Extra2
(#1592). - Added
egui::hex_color!
to createColor32
's from hex strings under thecolor-hex
feature (#1596). - Optimized painting of filled circles (e.g. for scatter plots) by 10x or more (#1616).
- Added opt-in feature
deadlock_detection
to detect double-lock of mutexes on the same thread (#1619). - Added
InputState::stable_dt
: a more stable estimate for the delta-time in reactive mode (#1625). - You can now specify a texture filter for your textures (#1636).
- Added functions keys in
egui::Key
(#1665). - Added support for using
PaintCallback
shapes with the WGPU backend (#1684). - Added
Context::request_repaint_after
(#1694). ctrl-h
now acts like backspace inTextEdit
(#1812).- Added
custom_formatter
method forSlider
andDragValue
(#1851). - Added
RawInput::has_focus
which backends can set to indicate whether the UI as a whole has the keyboard focus (#1859). - Added
PointerState::button_double_clicked()
andPointerState::button_triple_clicked()
(#1906). - Added
custom_formatter
,binary
,octal
, andhexadecimal
toDragValue
andSlider
(#1953)
- MSRV (Minimum Supported Rust Version) is now
1.61.0
(#1846). PaintCallback
shapes now require the whole callback to be put in anArc<dyn Any>
with the value being a backend-specific callback type (#1684).- Replaced
needs_repaint
inFullOutput
withrepaint_after
. Used to force repaint after the set duration in reactive mode (#1694). Layout::left_to_right
andLayout::right_to_left
now takes the vertical align as an argument. Previous default wasAlign::Center
.- Improved ergonomics of adding plot items. All plot items that take a series of 2D coordinates can now be created directly from
Vec<[f64; 2]>
. TheValue
andValues
types were removed in favor ofPlotPoint
andPlotPoints
respectively (#1816). TextBuffer
no longer needs to implementAsRef<str>
(#1824).
- Fixed
Response::changed
forui.toggle_value
(#1573). - Fixed
ImageButton
's changing background padding on hover (#1595). - Fixed
Plot
auto-bounds bug (#1599). - Fixed dead-lock when alt-tabbing while also showing a tooltip (#1618).
- Fixed
ScrollArea
scrolling when editing an unrelatedTextEdit
(#1779). - Fixed
Slider
not always generating events on change (#1854). - Fixed jitter of anchored windows for the first frame (#1856).
- Fixed focus behavior when pressing Tab in a UI with no focused widget (#1861).
- Fixed automatic plot bounds (#1865).
- Change
Shape::Callback
from&dyn Any
to&mut dyn Any
to support more backends.
- Added
Shape::Callback
for backend-specific painting, with an example (#1351). - Added
Frame::canvas
(#1362). Context::request_repaint
will now wake up UI thread, if integrations has calledContext::set_request_repaint_callback
(#1366).- Added
Plot::allow_scroll
,Plot::allow_zoom
no longer affects scrolling (#1382). - Added
Ui::push_id
to resolve id clashes (#1374). - Added
ComboBox::icon
(#1405). - Added
Ui::scroll_with_delta
. - Added
Frame::outer_margin
. - Added
Painter::hline
andPainter::vline
. - Added
Link
andui.link
(#1506). - Added triple-click support; triple-clicking a TextEdit field will select the whole paragraph (#1512).
- Added
Plot::x_grid_spacer
andPlot::y_grid_spacer
for custom grid spacing (#1180). - Added
Ui::spinner()
shortcut method (#1494). - Added
CursorIcon
s for resizing columns, rows, and the eight cardinal directions. - Added
Ui::toggle_value
. - Added ability to add any widgets to the header of a collapsing region (#1538).
- MSRV (Minimum Supported Rust Version) is now
1.60.0
(#1467). ClippedMesh
has been replaced withClippedPrimitive
(#1351).- Renamed
Frame::margin
toFrame::inner_margin
. - Renamed
AlphaImage
toFontImage
to discourage any other use for it (#1412). - Warnings will be painted on screen when there is an
Id
clash forGrid
,Plot
orScrollArea
(#1452). Checkbox
andRadioButton
with an empty label (""
) will now take up much less space (#1456).- Replaced
Memory::top_most_layer
with more flexibleMemory::layer_ids
. - Renamed the feature
convert_bytemuck
tobytemuck
(#1467). - Renamed the feature
serialize
toserde
(#1467). - Renamed
Painter::sub_region
toPainter::with_clip_rect
.
- Fixed
ComboBox
es always being rendered left-aligned (#1304). - Fixed ui code that could lead to a deadlock (#1380).
- Text is darker and more readable in bright mode (#1412).
- Fixed a lot of broken/missing doclinks (#1419).
- Fixed
Ui::add_visible
sometimes leaving theUi
in a disabled state (#1436). - Added line breaking rules for Japanese text (#1498).
- Deprecated
CollapsingHeader::selectable
(#1538).
- Removed the
single_threaded/multi_threaded
flags - egui is now always thread-safe (#1390).
- 4JX
- a-liashenko
- ascclemens
- awaken1ng
- bigfarts
- bobyclaws
- Bromeon
- cloudhead
- collin-kemper
- cpterry
- dbuch
- DusterTheFirst
- Edgeworth
- elwerene
- follower
- Friz64
- Hunter522
- Jake-Shadle
- jean-airoldie
- JelNiSlaw
- juancampa
- LU15W1R7H
- mbillingr
- nicklasmoeller
- rukai
- tami5
- Titaniumtown
- trevyn
- waynr
- zam-5
- Much improved font selection (#1154):
- You can now select any font size and family using
RichText::size
amdRichText::family
and the newFontId
. - Easily change text styles with
Style::text_styles
. - Added
Ui::text_style_height
. - Added
TextStyle::resolve
. - Made the v-align and scale of user fonts tweakable (#1241).
- You can now select any font size and family using
- Plot:
- Added
Plot::x_axis_formatter
andPlot::y_axis_formatter
for custom axis labels (#1130). - Added
Plot::allow_boxed_zoom()
,Plot::boxed_zoom_pointer()
for boxed zooming on plots (#1188). - Added plot pointer coordinates with
Plot::coordinates_formatter
(#1235). - Added linked axis support for plots via
plot::LinkedAxisGroup
(#1184).
- Added
Context::load_texture
to convert an image into a texture which can be displayed using e.g.ui.image(texture, size)
(#1110).Ui::input_mut
to modify how subsequent widgets see theInputState
and a convenience methodInputState::consume_key
for shortcuts or hotkeys (#1212).- Added
Ui::add_visible
andUi::add_visible_ui
. - Added
CollapsingHeader::icon
to override the default open/close icon using a custom function. (1147). - Added
ui.data()
,ctx.data()
,ctx.options()
andctx.tessellation_options()
(#1175). - Added
Response::on_hover_text_at_pointer
as a convenience akin toResponse::on_hover_text
(1179). - Opt-in dependency on
tracing
crate for logging warnings (#1192). - Added
ui.weak(text)
. - Added
Slider::step_by
(1225). - Added
Context::move_to_top
andContext::top_most_layer
for managing the layer on the top (#1242). - Support a subset of macOS' emacs input field keybindings in
TextEdit
(#1243). - Added ability to scroll an UI into view without specifying an alignment (1247).
- Added
Ui::scroll_to_rect
(1252).
⚠️ Context::input
andUi::input
now locks a mutex. This can lead to a dead-lock is used in anif let
binding!if let Some(pos) = ui.input().pointer.latest_pos()
and similar must now be rewritten on two lines.- Search for this problem in your code using the regex
if let .*input
.
- Better contrast in the default light mode style (#1238).
- Renamed
CtxRef
toContext
(#1050). Context
can now be cloned and stored between frames (#1050).- Renamed
Ui::visible
toUi::is_visible
. - Split
Event::Text
intoEvent::Text
andEvent::Paste
(#1058). - Replaced
Style::body_text_style
with more genericStyle::text_styles
(#1154). TextStyle
is no longerCopy
(#1154).- Replaced
TextEdit::text_style
withTextEdit::font
(#1154). Plot::highlight
now takes abool
argument (#1159).ScrollArea::show
now returns aScrollAreaOutput
, so you might need to add.inner
after the call to it (#1166).- Replaced
corner_radius: f32
withrounding: Rounding
, allowing per-corner rounding settings (#1206). - Replaced Frame's
margin: Vec2
withmargin: Margin
, allowing for different margins on opposing sides (#1219). - Renamed
Plot::custom_label_func
toPlot::label_formatter
(#1235). Areas::layer_id_at
ignores non-interatable layers (i.e. Tooltips) (#1240).ScrollArea
s will not shrink below a certain minimum size, set bymin_scrolled_width/min_scrolled_height
(1255).- For integrations:
Output
has now been renamedPlatformOutput
andContext::run
now returns the newFullOutput
(#1292).FontImage
has been replaced byTexturesDelta
(found inFullOutput
), describing what textures were loaded and freed each frame (#1110).- The painter must support partial texture updates (#1149).
- Added
RawInput::max_texture_side
which should be filled in with e.g.GL_MAX_TEXTURE_SIZE
(#1154).
- Plot
Orientation
was not public, although fields using this type were (#1130). - Context menus now respects the theme (#1043).
- Calling
Context::set_pixels_per_point
before the first frame will now work. - Tooltips that don't fit the window don't flicker anymore (#1240).
- Scroll areas now follow text cursor (#1252).
- Slider: correctly respond with drag and focus events when interacting with the value directly (1270).
- 4JX
- 55nknown
- AlanRace
- a-liashenko
- awaken1ng
- BctfN0HUK7Yg
- Bromeon
- cat-state
- danielkeller
- dvec
- Friz64
- Gordon01
- HackerFoo
- juancampa
- justinj
- lampsitter
- LordMZTE
- manuel-i
- Mingun
- niklaskorz
- nongiach
- parasyte
- psiphi75
- s-nie
- t18b219k
- terhechte
- xudesheng
- yusdacra
- Added back
CtxRef::begin_frame,end_frame
as an alternative toCtxRef::run
.
- Added context menus: See
Ui::menu_button
andResponse::context_menu
(#543). - Most widgets containing text (
Label
,Button
etc) now supports rich text (#855). - Plots:
- You can now read and write the cursor of a
TextEdit
(#848). - When using a custom font you can now specify a font index (#873).
- Added vertical sliders with
Slider::new(…).vertical()
(#875). - Added
Button::image_and_text
(#832). - Added
CollapsingHeader::open
to control if it is open or collapsed (#1006). - Added
egui::widgets::color_picker::color_picker_color32
to show the color picker.
- MSRV (Minimum Supported Rust Version) is now
1.56.0
. ui.add(Button::new("…").text_color(…))
is nowui.button(RichText::new("…").color(…))
(same forLabel
)(#855).- Plots now provide a
show
method that has to be used to add items to and show the plot (#766). menu::menu(ui, ...)
is nowui.menu_button(...)
(#543)- Replaced
CtxRef::begin_frame
andend_frame
withCtxRef::run
(#872). - Replaced
scroll_delta
andzoom_delta
inRawInput
withEvent::Scroll
andEvent::Zoom
. - Unified the four
Memory
data buckets (data
,data_temp
,id_data
andid_data_temp
) into a singleMemory::data
, with a new interface (#836). - Replaced
Ui::__test
withegui::__run_test_ui
(#872).
- Fixed
ComboBox
and other popups getting clipped to parent window (#885). - The color picker is now better at keeping the same hue even when saturation goes to zero (#886).
- Removed
egui::math
(useegui::emath
instead). - Removed
egui::paint
(useegui::epaint
instead).
- 5225225: #849.
- aevyrie: #966.
- B-Reif: #875.
- Bromeon: #863, #918.
- d10sfan: #832.
- EmbersArc: #766, #892.
- Hperigo: #905.
- isegal: #934.
- mankinskin: #543.
- niladic: #499, #863.
- singalen: #973.
- sumibi-yakitori: #830, #870.
- t18b219k: #868, #888.
- Added horizontal scrolling support to
ScrollArea
andWindow
(opt-in). TextEdit::layouter
: Add custom text layout for e.g. syntax highlighting or WYSIWYG.Fonts::layout_job
: New text layout engine allowing mixing fonts, colors and styles, with underlining and strikethrough.- Added
ui.add_enabled(bool, widget)
to easily add a possibly disabled widget. - Added
ui.add_enabled_ui(bool, |ui| …)
to create a possibly disabled UI section. - Added feature
"serialize"
separately from"persistence"
. - Added
egui::widgets::global_dark_light_mode_buttons
to easily add buttons for switching the egui theme. TextEdit
can now be used to show text which can be selected and copied, but not edited.- Added
Memory::caches
for caching things from one frame to the next.
- Change the default monospace font to Hack.
- Label text will now be centered, right-aligned and/or justified based on the layout of the
Ui
it is in. Hyperlink
will now word-wrap just like aLabel
.- All
Ui
s must now have a finitemax_rect
.- Deprecated:
max_rect_finite
,available_size_before_wrap_finite
andavailable_rect_before_wrap_finite
.
- Deprecated:
Painter
/Fonts
: text layout now expect a color when creating aGalley
. You may override that color withPainter::galley_with_color
.- MSRV (Minimum Supported Rust Version) is now
1.54.0
. - By default,
DragValue
s no longer show a tooltip when hovered. Change withStyle::explanation_tooltips
. - Smaller and nicer color picker.
ScrollArea
will auto-shrink to content size unless told otherwise usingScrollArea::auto_shrink
.- By default,
Slider
'sclamp_to_range
is set to true. - Renamed
TextEdit::enabled
toTextEdit::interactive
. ui.label
(and friends) now takeimpl ToString
as argument instead ofimpl Into<Label>
.
- Fixed wrongly sized multiline
TextEdit
in justified layouts. - Fixed clip rectangle of windows that don't fit the central area.
- Show tooltips above widgets on touch screens.
- Fixed popups sometimes getting clipped by panels.
- Replace
Button::enabled
withui.add_enabled
.
- AlexApps99
- baysmith
- bpostlethwaite
- cwfitzgerald
- DrOptix
- JerzySpendel
- NiceneNerd
- parasyte
- spersson
- Stock84-dev
- sumibi-yakitori
- t18b219k
- TobTobXX
- zu1k
- Fixed window resize bug introduced in
0.14.1
.
- Added
Ui::horizontal_top
.
- Fixed
set_width/set_min_width/set_height/set_min_height/expand_to_include_x/expand_to_include_y
. - Make minimum grid column width propagate properly.
- Make sure
TextEdit
contents expand to fill width if applicable. ProgressBar
: add a minimum width and fix for having it in an infinite layout.- Fixed sometimes not being able to click inside a combo box or popup menu.
- Panels can now be added to any
Ui
. - Plot:
- Line styles.
- Added
show_background
andshow_axes
methods toPlot
.
- Progress bar.
Grid::num_columns
: allow the last column to take up the rest of the space of the parentUi
.- Added an API for dropping files into egui (see
RawInput
). CollapsingHeader
can now optionally be selectable.
- A single-line
TextEdit
will now clip text that doesn't fit in it, and scroll. - Return closure return value from
Area::show
,ComboBox::show_ui
,ComboBox::combo_box_with_label
,Window::show
,popup::*
,menu::menu
. - Only move/resize windows with primary mouse button.
- Tooltips are now moved to not cover the widget they are attached to.
- Fixed custom font definitions getting replaced when
pixels_per_point
is changed. - Fixed
lost_focus
forTextEdit
. - Clicking the edge of a menu button will now properly open the menu.
- Fixed hover detection close to an
Area
. - Fixed case where
Plot
'smin_auto_bounds
could be ignored after the first call toPlot::ui
. - Fixed slow startup when using large font files.
- Plot: you can now set the stroke of a
HLine/VLine
.
Plot::new
now takes anid_source: impl Hash
instead of aname: impl ToString
. Functionally it is the same.
- Plot:
- Panels:
- Added right and bottom panels (
SidePanel::right
andPanel::bottom
). - Panels can now be resized.
- Added an option to overwrite frame of a
Panel
.
- Added right and bottom panels (
- Improve accessibility / screen reader.
- Added
ScrollArea::show_rows
for efficient scrolling of huge UI:s. - Added
ScrollArea::enable_scrolling
to allow freezing scrolling when editing TextEdit widgets within it - Added
Ui::set_visible
as a way to hide widgets. - Added
Style::override_text_style
to easily change the text style of everything in aUi
(or globally). - You can now change
TextStyle
on checkboxes, radio buttons andSelectableLabel
. - Added support for cint under
cint
feature. - Added features
extra_asserts
andextra_debug_asserts
to enable additional checks. TextEdit
now supports edits on a generic buffer usingTextBuffer
.- Added
Context::set_debug_on_hover
andegui::trace!(ui)
- Minimum Rust version is now 1.51 (used to be 1.52)
- Tweaked the default visuals style.
- Plot: Renamed
Curve
toLine
. TopPanel::top
is nowTopBottomPanel::top
.SidePanel::left
no longet takes the default width by argument, but by a builder call.SidePanel::left
is resizable by default.
- Fixed uneven lettering on non-integral device scales ("extortion lettering").
- Fixed invisible scroll bar when native window is too narrow for egui.
- Added anchors to windows and areas so you can put a window in e.g. the top right corner.
- Make labels interactive with
Label::sense(Sense::click())
. - Added
Response::request_focus
andResponse::surrender_focus
. - Added
TextEdit::code_editor
(VERY basic). - Pan and zoom plots.
- Add plot legends.
- Users can now store custom state in
egui::Memory
. - Added
Response::on_disabled_hover_text
to show tooltip for disabled widgets. - Zoom input: ctrl-scroll and (on
eframe
web) trackpad-pinch gesture. - Support for raw multi touch events,
enabling zoom, rotate, and more. Works with
eframe
web on mobile devices, and should work withegui_glium
for certain touch devices/screens. - Added (optional) compatibility with mint.
- Make
Memory::has_focus
public (again). Plot
must now be given a name that is unique within its scope.- Tab only selects labels if the
screen_reader
option is turned on. - Renamed
ui.wrap
toui.scope
.
- Fixed defocus-bug on touch screens.
- Fixed bug with the layout of wide
DragValue
s.
- Moved experimental markup language to
egui_demo_lib
- You can now give focus to any clickable widget with tab/shift-tab.
- Use space or enter to click the selected widget.
- Use arrow keys to adjust sliders and
DragValue
s.
- egui will now output events when widgets gain keyboard focus.
- This can be hooked up to a screen reader to aid the visually impaired
- Added the option to restrict the dragging bounds of
Window
andArea
to a specified area usingdrag_bounds(rect)
. - Added support for small and raised text.
- Added
ui.set_row_height
. - Added
DebugOptions::show_widgets
to debug layouting by hovering widgets. - Added
ComboBox
to more easily customize combo boxes. - Added
Slider::new
andDragValue::new
to replace old type-specific constructors. - Added
TextEdit::password
to hide input characters.
ui.advance_cursor
is now calledui.add_space
.kb_focus
is now just calledfocus
.
- Fixed some bugs related to centered layouts.
- Fixed secondary-click to open a menu.
- Fix panic for zero-range sliders and zero-speed drag values.
- Fixed false id clash error for wrapping text.
- Fixed bug that would close a popup (e.g. the color picker) when clicking inside of it.
- Deprecated
combo_box_with_label
in favor of newComboBox
. - Deprecated type-specific constructors for
Slider
andDragValue
(Slider::f32
,DragValue::usize
etc).
- Added
egui::plot::Plot
to plot some 2D data. - Added
Ui::hyperlink_to(label, url)
. - Sliders can now have a value prefix and suffix (e.g. the suffix
"°"
works like a unit). Context::set_pixels_per_point
to control the scale of the UI.- Added
Response::changed()
to query if e.g. a slider was dragged, text was entered or a checkbox was clicked. - Added support for all integers in
DragValue
andSlider
(except 128-bit).
- Improve the positioning of tooltips.
- Only show tooltips if mouse is still.
Slider
will now show the value display by default, unless turned off with.show_value(false)
.- The
Slider
value is now aDragValue
which when dragged can pick values outside of the slider range (unlessclamp_to_range
is set).
- Added support for secondary and middle mouse buttons.
- Added
Label
methods for code, strong, strikethrough, underline and italics. - Added
ui.group(|ui| { … })
to visually group some widgets within a frame. - Added
Ui
helpers for doing manual layout (ui.put
,ui.allocate_ui_at_rect
and more). - Added
ui.set_enabled(false)
to disable all widgets in aUi
(grayed out and non-interactive). - Added
TextEdit::hint_text
for showing a weak hint text when empty. egui::popup::popup_below_widget
: show a popup area below another widget.- Added
Slider::clamp_to_range(bool)
: if set, clamp the incoming and outgoing values to the slider range. - Add:
ui.spacing()
,ui.spacing_mut()
,ui.visuals()
,ui.visuals_mut()
. - Add:
ctx.set_visuals()
. - You can now control text wrapping with
Style::wrap
. - Added
Grid::max_col_width
.
- Text will now wrap at newlines, spaces, dashes, punctuation or in the middle of a words if necessary, in that order of priority.
- Widgets will now always line break at
\n
characters. - Widgets will now more intelligently choose whether or not to wrap text.
mouse
has been renamedpointer
everywhere (to make it clear it includes touches too).- Most parts of
Response
are now methods, soif ui.button("…").clicked {
is nowif ui.button("…").clicked() {
. Response::active
is now gone. You can useresponse.dragged()
orresponse.clicked()
instead.- Backend: pointer (mouse/touch) position and buttons are now passed to egui in the event stream.
DragValue::range
is now calledclamp_range
and also clamps incoming values.- Renamed
Triangles
toMesh
. - The tessellator now wraps the clip rectangle and mesh in
struct ClippedMesh(Rect, Mesh)
. Mesh::split_to_u16
now returns a 16-bit indexedMesh16
.
- It is now possible to click widgets even when FPS is very low.
- Tessellator: handle sharp path corners better (switch to bevel instead of miter joints for > 90°).
- Added a simple grid layout (
Grid
). - Added
ui.allocate_at_least
andui.allocate_exact_size
. - Added function
InputState::key_down
. - Added
Window::current_pos
to position a window.
- New simpler and sleeker look!
- Renamed
PaintCmd
toShape
. - Replace tuple
(Rect, Shape)
with tuple-structClippedShape
. - Renamed feature
"serde"
to"persistence"
. - Break out the modules
math
andpaint
into separate cratesemath
andepaint
.
- Fixed a bug that would sometimes trigger a "Mismatching panels" panic in debug builds.
Image
andImageButton
will no longer stretch to fill a justified layout.
- Added
ui.scroll_to_cursor
andresponse.scroll_to_me
(#81 by lucaspoffo). - Added
window.id(…)
andarea.id(…)
for overriding the defaultId
.
- Renamed
Srgba
toColor32
. - All color constructors now starts with
from_
, e.g.Color32::from_rgb
. - Renamed
FontFamily::VariableWidth
toFontFamily::Proportional
. - Removed
pixels_per_point
fromFontDefinitions
.
RepaintSignal
now implementsSync
so it can be sent to a background thread.TextEdit
widgets are now slightly larger to accommodate their frames.
- Deprecated
color::srgba
.
- Turn off
Window
title bars withwindow.title_bar(false)
. ImageButton
-ui.add(ImageButton::new(…))
.ui.vertical_centered
andui.vertical_centered_justified
.ui.allocate_painter
helper.- Mouse-over explanation to duplicate ID warning.
- You can now easily constrain egui to a portion of the screen using
RawInput::screen_rect
. - You can now control the minimum and maixumum number of decimals to show in a
Slider
orDragValue
. - Added
egui::math::Rot2
: rotation helper. Response
now contains theId
of the widget it pertains to.ui.allocate_response
that allocates space and checks for interactions.- Added
response.interact(sense)
, e.g. to check for clicks on labels.
ui.allocate_space
now returns an(Id, Rect)
tuple.Arc<Context>
has been replaced withCtxRef
everywhere.- Slight tweak of the default
Style
and font sizes. SidePanel::left
andTopPanel::top
now takesimpl Hash
as first argument.- A
Window
may now cover an existingCentralPanel
. ui.image
now takesimpl Into<Vec2>
as asize
argument.- Made some more fields of
RawInput
optional. Slider
andDragValue
uses fewer decimals by default. See the full precision by hovering over the value.egui::App
: addedfn name(&self)
andfn clear_color(&self)
.- Combo boxes has scroll bars when needed.
- Expand
Window
+Resize
containers to be large enough for last frames content ui.columns
: Columns now defaults to justified top-to-down layouts.- Renamed
Sense::nothing()
toSense::hover()
. - Replaced
parking_lot
dependency withatomic_refcell
by default.
- The background for
CentralPanel
will now cover unused space too. ui.columns
: Improve allocated size estimation.
RawInput::screen_size
- useRawInput::screen_rect
instead.- left/centered/right column functions on
Ui
. ui.interact_hover
andui.hovered
.
- Emoji support: 1216 different emojis that work in any text.
- The Demo app comes with a Font Book to explore the available glyphs.
ui.horizontal_wrapped(|ui| …)
: Add widgets on a row but wrap atmax_size
.ui.horizontal_wrapped_for_text
: Likeui.horizontal_wrapped
, but with spacing made for embedding text.ui.horizontal_for_text
: Likeui.horizontal
, but with spacing made for embedding text.egui::Layout
now supports justified layouts where contents is also centered, right-aligned, etc.ui.allocate_ui(size, |ui| …)
: Easily create a child-Ui
of a given size.SelectableLabel
(ui.selectable_label
andui.selectable_value
): A text-button that can be selected.ui.small_button
: A smaller button that looks good embedded in text.ui.drag_angle_tau
: For those who want to specify angles as fractions of τ (a full turn).- Added
Resize::id_source
andScrollArea::id_source
to let the user avoid Id clashes.
- New default font: Ubuntu-Light.
- Make it simpler to override fonts in
FontDefinitions
. - Remove minimum button width.
- Refactor
egui::Layout
substantially, changing its interface. - Calling
on_hover_text
/on_hover_ui
multiple times will stack tooltips underneath the previous ones. - Text wrapping on labels, buttons, checkboxes and radio buttons is now based on the layout.
- Removed the
label!
macro.
TextEdit
improvements:- Much improved text editing, with better navigation and selection.
- Move focus between
TextEdit
widgets with tab and shift-tab. - Undo edtis in a
TextEdit
. - You can now check if a
TextEdit
lost keyboard focus withresponse.lost_focus
. - Added
ui.text_edit_singleline
andui.text_edit_multiline
.
- You can now debug why your
Ui
is unexpectedly wide withui.style_mut().debug.show_expand_width = true;
- Pressing enter in a single-line
TextEdit
will now surrender keyboard focus for it. - You must now be explicit when creating a
TextEdit
if you want it to be singeline or multiline. - Improved automatic
Id
generation, makingId
clashes less likely. - egui now requires modifier key state from the integration
- Added, renamed and removed some keys in the
Key
enum. - Fixed incorrect text wrapping width on radio buttons
- Fixed bug where a lost widget could still retain keyboard focus.
- Panels: you can now create panels using
SidePanel
,TopPanel
andCentralPanel
. - You can now override the default egui fonts.
- Added ability to override text color with
visuals.override_text_color
. - The demo now includes a simple drag-and-drop example.
- The demo app now has a slider to scale all of egui.
ui.horizontal(…)
etc returnsResponse
.- Refactored the interface for
egui::app::App
. - Windows are now constrained to the screen.
Context::begin_frame()
no longer returns aUi
. Instead put your widgets into aSidePanel
,TopPanel
,CentralPanel
,Window
orArea
.Context::end_frame()
now returns shapes that need to be converted to triangles withContext::tessellate()
.- Anti-aliasing is now off by default in debug builds.
- You can no longer throw windows.
- Fixed a bug where some regions would slowly grow for non-integral scales (
pixels_per_point
).
- Color picker
- Unicode characters in labels (limited by what the default font supports)
- Simple drop-down combo box menu
- Logarithmic sliders
- Optimization: coarse culling in the tessellator
- CHANGED: switch argument order of
ui.checkbox
andui.radio
This is when I started the CHANGELOG.md, after almost two years of development. Better late than never.
- Widgets: label, text button, hyperlink, checkbox, radio button, slider, draggable value, text editing
- Layouts: horizontal, vertical, columns
- Text input: very basic, multiline, copy/paste
- Windows: move, resize, name, minimize and close. Automatically sized and positioned.
- Regions: resizing, vertical scrolling, collapsing headers (sections)
- Rendering: Anti-aliased rendering of lines, circles, text and convex polygons.
- Tooltips on hover
- 2020-08-10: renamed the project to "egui"
- 2020-05-30: first release on crates.io (0.1.0)
- 2020-04-01: serious work starts (pandemic project)
- 2019-03-12: gave a talk about what would later become egui: https://www.youtube.com/watch?v=-pmwLHw5Gbs
- 2018-12-23: initial commit
- 2018-11-04: started tinkering on a train