Repository navigation
Deprecate unused Style::compact_menu_style - #8909
Draft
IG-ABHINAV wants to merge 2 commits into
Draft
IG-ABHINAV wants to merge 2 commits into
IG-ABHINAV wants to merge 2 commits into
Conversation
The field has had no effect since the old menu module was removed in emilk#8105. Mark it deprecated, like `Visuals::clip_rect_margin`, and drop its checkbox from the style settings UI. Fixes emilk#8896
|
Preview is being built... Preview will be available at https://egui-pr-preview.github.io/pr/8909-deprecate-compact-menu-style View snapshot changes at kitdiff |
emilk
approved these changes
Nov 23, 2026
emilk
reviewed
Nov 23, 2026
Comment on lines
346
to
352
|
|
||
| /// Use a more compact style for menus. | ||
| /// Unused. Kept only for backwards compatibility. | ||
| /// | ||
| /// Used to select a more compact style for menus. | ||
| /// Setting it now has no effect. | ||
| #[deprecated(note = "This is now unused and has no effect")] | ||
| pub compact_menu_style: bool, |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Style::compact_menu_styleis unused #8896What & why
The flag stopped having an effect when #8105 removed the old menu module (its
set_menu_stylewas the only reader).How
Style::compact_menu_style#[deprecated(note = "This is now unused and has no effect")], the same wayVisuals::clip_rect_marginis handled.Style::ui, since toggling it did nothing.Verification
cargo fmt --all -- --check✅cargo clippy -p egui --all-features --all-targets -- -D warnings✅cargo test -p egui --lib: 99 passed ✅cargo check -p egui_demo_lib✅Judgment calls
I deprecated the field rather than removing it or wiring it to
menu::menu_style. That keeps existing code and serialized styles compiling and loading. Happy to switch to either alternative if you'd prefer.