Add ability to hide status bar (#38974)
This pull request adds the ability to configure the setting to hide or show the status bar, as described in discussion: https://github.com/zed-industries/zed/discussions/38591 --------- Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This commit is contained in:
co-authored by
Conrad Irwin
parent
6f4381b39d
commit
126ed6fbdd
@@ -58,6 +58,7 @@ pub struct SettingsContent {
|
||||
|
||||
pub tabs: Option<ItemSettingsContent>,
|
||||
pub tab_bar: Option<TabBarSettingsContent>,
|
||||
pub status_bar: Option<StatusBarSettingsContent>,
|
||||
|
||||
pub preview_tabs: Option<PreviewTabsSettingsContent>,
|
||||
|
||||
|
||||
@@ -54,8 +54,6 @@ pub struct EditorSettingsContent {
|
||||
///
|
||||
/// Default: 300
|
||||
pub hover_popover_delay: Option<u64>,
|
||||
/// Status bar related settings
|
||||
pub status_bar: Option<StatusBarContent>,
|
||||
/// Toolbar related settings
|
||||
pub toolbar: Option<ToolbarContent>,
|
||||
/// Scrollbar related settings
|
||||
@@ -193,20 +191,6 @@ pub struct EditorSettingsContent {
|
||||
pub lsp_document_colors: Option<DocumentColorsRenderMode>,
|
||||
}
|
||||
|
||||
// Status bar related settings
|
||||
#[skip_serializing_none]
|
||||
#[derive(Debug, Clone, Default, Serialize, Deserialize, JsonSchema, MergeFrom, PartialEq, Eq)]
|
||||
pub struct StatusBarContent {
|
||||
/// Whether to display the active language button in the status bar.
|
||||
///
|
||||
/// Default: true
|
||||
pub active_language_button: Option<bool>,
|
||||
/// Whether to show the cursor position button in the status bar.
|
||||
///
|
||||
/// Default: true
|
||||
pub cursor_position_button: Option<bool>,
|
||||
}
|
||||
|
||||
// Toolbar related settings
|
||||
#[skip_serializing_none]
|
||||
#[derive(Debug, Clone, Default, Serialize, Deserialize, JsonSchema, MergeFrom, PartialEq, Eq)]
|
||||
|
||||
@@ -361,6 +361,24 @@ pub struct TabBarSettingsContent {
|
||||
pub show_tab_bar_buttons: Option<bool>,
|
||||
}
|
||||
|
||||
#[skip_serializing_none]
|
||||
#[derive(Clone, Default, Serialize, Deserialize, JsonSchema, MergeFrom, Debug, PartialEq, Eq)]
|
||||
pub struct StatusBarSettingsContent {
|
||||
/// Whether to show the status bar.
|
||||
///
|
||||
/// Default: true
|
||||
#[serde(rename = "experimental.show", default)]
|
||||
pub show: Option<bool>,
|
||||
/// Whether to display the active language button in the status bar.
|
||||
///
|
||||
/// Default: true
|
||||
pub active_language_button: Option<bool>,
|
||||
/// Whether to show the cursor position button in the status bar.
|
||||
///
|
||||
/// Default: true
|
||||
pub cursor_position_button: Option<bool>,
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug, Serialize, Deserialize, PartialEq, Eq, JsonSchema, MergeFrom)]
|
||||
#[serde(rename_all = "snake_case")]
|
||||
pub enum AutosaveSetting {
|
||||
|
||||
Reference in New Issue
Block a user