pub struct Interface { /* private fields */ }
Implementations
sourceimpl Interface
impl Interface
sourcepub fn current_scale(&self) -> f32
pub fn current_scale(&self) -> f32
The current scale without taking into account dpi based window scaling.
sourcepub fn current_effective_scale(&self) -> f32
pub fn current_effective_scale(&self) -> f32
The current scale taking into account dpi based window scaling.
sourcepub fn set_scale(&self, set_scale: f32)
pub fn set_scale(&self, set_scale: f32)
Set the current scale. Doesn’t account for dpi based window scaling.
sourcepub fn set_effective_scale(&self, set_scale: f32)
pub fn set_effective_scale(&self, set_scale: f32)
Set the current scale taking into account dpi based window scaling.
sourcepub fn current_msaa(&self) -> BstMSAALevel
pub fn current_msaa(&self) -> BstMSAALevel
Get the current MSAA level.
sourcepub fn set_msaa(&self, set_msaa: BstMSAALevel)
pub fn set_msaa(&self, set_msaa: BstMSAALevel)
Set the MSAA Level.
sourcepub fn increase_msaa(&self) -> BstMSAALevel
pub fn increase_msaa(&self) -> BstMSAALevel
Increase MSAA to the next step.
sourcepub fn decrease_msaa(&self) -> BstMSAALevel
pub fn decrease_msaa(&self) -> BstMSAALevel
Decrease MSAA to the next step.
pub fn get_bin_id_atop(&self, window: BstWindowID, x: f32, y: f32) -> Option<BinID>
pub fn get_bin_atop(&self, window: BstWindowID, x: f32, y: f32) -> Option<Arc<Bin>>
sourcepub fn get_bins_atop(&self, _window: BstWindowID, x: f32, y: f32) -> Vec<Arc<Bin>>
pub fn get_bins_atop(&self, _window: BstWindowID, x: f32, y: f32) -> Vec<Arc<Bin>>
Get the Bin
’s that are at the given mouse position accounting for current effective
scale. Returned Vec
is sorted where the top-most Bin
’s are first.
sourcepub fn get_bin_ids_atop(&self, window: BstWindowID, x: f32, y: f32) -> Vec<BinID>
pub fn get_bin_ids_atop(&self, window: BstWindowID, x: f32, y: f32) -> Vec<BinID>
Get the BinID
’s that are at the given mouse position accounting for current effective
scale. Returned Vec
is sorted where the top-most Bin
’s are first.
sourcepub fn bins(&self) -> Vec<Arc<Bin>>
pub fn bins(&self) -> Vec<Arc<Bin>>
Returns a list of all bins that have a strong reference. Note keeping this list will keep all bins returned alive and prevent them from being dropped. This list should be dropped asap to prevent issues with bins being dropped.
pub fn new_bins(&self, amt: usize) -> Vec<Arc<Bin>>
pub fn new_bin(&self) -> Arc<Bin>
pub fn get_bin(&self, id: BinID) -> Option<Arc<Bin>>
sourcepub fn mouse_inside(
&self,
_window: BstWindowID,
mouse_x: f32,
mouse_y: f32
) -> bool
pub fn mouse_inside(
&self,
_window: BstWindowID,
mouse_x: f32,
mouse_y: f32
) -> bool
Checks if the mouse position is on top of any Bin
’s in the interface.