From d1525d92b138f73d4d7a2f4baae1ced14c07af00 Mon Sep 17 00:00:00 2001 From: George Waters Date: Mon, 4 May 2026 18:24:24 -0400 Subject: [PATCH] Add show line endings button to Settings UI (#55707) This is following up from #39609 to add the line endings button setting into settings ui. Release Notes: - Added the line endings button setting to settings ui. --- crates/settings_ui/src/page_data.rs | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/crates/settings_ui/src/page_data.rs b/crates/settings_ui/src/page_data.rs index 112aa5f571..a43c566d1a 100644 --- a/crates/settings_ui/src/page_data.rs +++ b/crates/settings_ui/src/page_data.rs @@ -3487,7 +3487,7 @@ fn search_and_files_page() -> SettingsPage { } fn window_and_layout_page() -> SettingsPage { - fn status_bar_section() -> [SettingsPageItem; 10] { + fn status_bar_section() -> [SettingsPageItem; 11] { [ SettingsPageItem::SectionHeader("Status Bar"), SettingsPageItem::SettingItem(SettingItem { @@ -3574,6 +3574,28 @@ fn window_and_layout_page() -> SettingsPage { metadata: None, files: USER, }), + SettingsPageItem::SettingItem(SettingItem { + title: "Line Endings Button", + description: "Show the active line endings button in the status bar.", + field: Box::new(SettingField { + json_path: Some("status_bar.line_endings_button"), + pick: |settings_content| { + settings_content + .status_bar + .as_ref()? + .line_endings_button + .as_ref() + }, + write: |settings_content, value, _| { + settings_content + .status_bar + .get_or_insert_default() + .line_endings_button = value; + }, + }), + metadata: None, + files: USER, + }), SettingsPageItem::SettingItem(SettingItem { title: "Terminal Button", description: "Show the terminal button in the status bar.",