Skip to content

Add editor font size settings#911

Draft
CopeFiend wants to merge 20 commits intoFyroxEngine:masterfrom
CopeFiend:editor_font_size_settings
Draft

Add editor font size settings#911
CopeFiend wants to merge 20 commits intoFyroxEngine:masterfrom
CopeFiend:editor_font_size_settings

Conversation

@CopeFiend
Copy link
Copy Markdown
Contributor

@CopeFiend CopeFiend commented Apr 12, 2026

Closes #910

Description

Add options for configuring font size in Editor UI.

Progress

  • Add font_size option to Settings Window -> General
  • Modify Editor font size through font_size option
  • Store modified value in settings.ron
  • Clamp value in Settings Window (8.0px - 48.0px)
  • Handle text widgets with previously hard-coded values (World Viewer, Tilemap Property, etc.)
  • Handle layout scaling with large fonts

Review Guidance

  • Most Builders now have the following fields and methods:
pub font: Option<FontResource>, // Default: None
pub font_size: Option<StyledProperty<f32>>, // Default: None

pub fn with_font(mut self, font: FontResource) -> Self {
   self.font = Some(font);
   self
}

pub fn with_font_size(mut self, font_size: StyledProperty<f32>) -> Self {
   self.font_size = Some(font_size);
   self
}
  • Every instance of Builder now explicitly calls the with_font() and with_font_size() methods
  • Would like to whether putting everything in Settings::general is a wise decision.

Screenshots/GIFs

WIP

Checklist

  • My code follows the project's code style guidelines
  • I have commented my code, particularly in hard-to-understand areas
  • I have updated the documentation accordingly
  • My changes don't generate new warnings or errors
  • No unsafe code introduced (or if introduced, thoroughly justified and documented)

@CopeFiend CopeFiend force-pushed the editor_font_size_settings branch 5 times, most recently from 2bf7e3c to caa8397 Compare April 20, 2026 14:06
@CopeFiend CopeFiend force-pushed the editor_font_size_settings branch from be386ca to d8778d3 Compare April 25, 2026 07:16
CopeFiend added 2 commits April 26, 2026 03:28
- `InspectorContext` and other "context" structs now carry explicit font/font_size values
- Method calls now have to explicitly set font/font_size data
- Changed helper functions to also take font/font_size
- Builders now have font/font_size fields
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add UI font size configuration in Editor Settings Window

1 participant