Add limit to minimum window size (#13126)
Release Notes: - Add a limit to the minimum window size on macOS. Here's the minimum window before change: <img width="121" alt="image" src="https://github.com/zed-industries/zed/assets/38318044/9e907194-42e5-457e-91ea-96613426b479"> After change: <img width="410" alt="image" src="https://github.com/zed-industries/zed/assets/38318044/6e9c3057-9860-4f4b-9a73-c158ebac5ba9">
This commit is contained in:
parent
328d98dddc
commit
93a5d0ca29
7 changed files with 30 additions and 0 deletions
|
@ -567,6 +567,9 @@ pub struct WindowOptions {
|
|||
|
||||
/// Application identifier of the window. Can by used by desktop environments to group applications together.
|
||||
pub app_id: Option<String>,
|
||||
|
||||
/// Window minimum size
|
||||
pub window_min_size: Size<Pixels>,
|
||||
}
|
||||
|
||||
/// The variables that can be configured when creating a new window
|
||||
|
@ -594,6 +597,9 @@ pub(crate) struct WindowParams {
|
|||
pub display_id: Option<DisplayId>,
|
||||
|
||||
pub window_background: WindowBackgroundAppearance,
|
||||
|
||||
#[cfg_attr(target_os = "linux", allow(dead_code))]
|
||||
pub window_min_size: Size<Pixels>,
|
||||
}
|
||||
|
||||
/// Represents the status of how a window should be opened.
|
||||
|
@ -642,6 +648,7 @@ impl Default for WindowOptions {
|
|||
display_id: None,
|
||||
window_background: WindowBackgroundAppearance::default(),
|
||||
app_id: None,
|
||||
window_min_size: Size::default(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue