pub struct SCWindow(/* private fields */);Expand description
Wrapper around SCWindow from ScreenCaptureKit
Represents a window that can be captured.
§Examples
use screencapturekit::shareable_content::SCShareableContent;
let content = SCShareableContent::get()?;
for window in content.windows() {
if let Some(title) = window.title() {
println!("Window: {} (ID: {})", title, window.window_id());
}
}Implementations§
Source§impl SCWindow
impl SCWindow
Sourcepub fn owning_application(&self) -> Option<SCRunningApplication>
pub fn owning_application(&self) -> Option<SCRunningApplication>
Get the owning application
Sourcepub fn window_layer(&self) -> i32
pub fn window_layer(&self) -> i32
Get window layer
Sourcepub fn is_on_screen(&self) -> bool
pub fn is_on_screen(&self) -> bool
Check if window is on screen
Trait Implementations§
impl Eq for SCWindow
impl Send for SCWindow
impl Sync for SCWindow
Auto Trait Implementations§
impl Freeze for SCWindow
impl RefUnwindSafe for SCWindow
impl Unpin for SCWindow
impl UnwindSafe for SCWindow
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