Allow styling the cursor in MouseEventHandler
Co-Authored-By: Max Brunsfeld <max@zed.dev> Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
co-authored by
Max Brunsfeld
Nathan Sobo
parent
53dc08dfc5
commit
5e6e0c68cd
@@ -47,6 +47,8 @@ pub trait Platform: Send + Sync {
|
||||
|
||||
fn write_credentials(&self, url: &str, username: &str, password: &[u8]);
|
||||
fn read_credentials(&self, url: &str) -> Option<(String, Vec<u8>)>;
|
||||
|
||||
fn set_cursor_style(&self, style: CursorStyle);
|
||||
}
|
||||
|
||||
pub(crate) trait ForegroundPlatform {
|
||||
@@ -114,6 +116,13 @@ pub enum PromptLevel {
|
||||
Critical,
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
pub enum CursorStyle {
|
||||
Arrow,
|
||||
ResizeLeftRight,
|
||||
PointingHand,
|
||||
}
|
||||
|
||||
pub trait FontSystem: Send + Sync {
|
||||
fn load_family(&self, name: &str) -> anyhow::Result<Vec<FontId>>;
|
||||
fn select_font(
|
||||
|
||||
Reference in New Issue
Block a user