pub struct MonitorId { /* private fields */ }
Expand description
Identifier for a monitor.
Implementations§
source§impl MonitorId
impl MonitorId
sourcepub fn get_name(&self) -> Option<String>
pub fn get_name(&self) -> Option<String>
Returns a human-readable name of the monitor.
Returns None
if the monitor doesn’t exist anymore.
sourcepub fn get_dimensions(&self) -> (u32, u32)
pub fn get_dimensions(&self) -> (u32, u32)
Returns the number of pixels currently displayed on the monitor.
sourcepub fn get_position(&self) -> (i32, i32)
pub fn get_position(&self) -> (i32, i32)
Returns the top-left corner position of the monitor relative to the larger full screen area.
sourcepub fn get_hidpi_factor(&self) -> f32
pub fn get_hidpi_factor(&self) -> f32
Returns the ratio between the monitor’s physical pixels and logical pixels.
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for MonitorId
impl Send for MonitorId
impl Sync for MonitorId
impl Unpin for MonitorId
impl UnwindSafe for MonitorId
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more