Struct ActiveWindowName

Source
pub struct ActiveWindowName { /* private fields */ }
Expand description

A text widget that is set via updating the root window name a la dwm

Implementations§

Source§

impl ActiveWindowName

Source

pub fn new( style: &TextStyle, max_chars: usize, is_greedy: bool, right_justified: bool, ) -> Self

Create a new ActiveWindowName widget

Trait Implementations§

Source§

impl Clone for ActiveWindowName

Source§

fn clone(&self) -> ActiveWindowName

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ActiveWindowName

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<X> Hook<X> for ActiveWindowName
where X: XConn,

Source§

fn remove_client(&mut self, wm: &mut WindowManager<X>, _: Xid) -> Result<()>

Trigger Point Read more
Source§

fn focus_change(&mut self, wm: &mut WindowManager<X>, id: Xid) -> Result<()>

Trigger Point Read more
Source§

fn client_name_updated( &mut self, wm: &mut WindowManager<X>, id: Xid, name: &str, root: bool, ) -> Result<()>

Trigger Point Read more
Source§

fn screen_change(&mut self, _: &mut WindowManager<X>, _: usize) -> Result<()>

Trigger Point Read more
Source§

fn startup(&mut self, wm: &mut WindowManager<X>) -> Result<()>

Trigger Point Read more
Source§

fn new_client(&mut self, wm: &mut WindowManager<X>, id: Xid) -> Result<()>

Trigger Point Read more
Source§

fn client_added_to_workspace( &mut self, wm: &mut WindowManager<X>, id: Xid, wix: usize, ) -> Result<()>

Trigger Point Read more
Source§

fn layout_applied( &mut self, wm: &mut WindowManager<X>, workspace_index: usize, screen_index: usize, ) -> Result<()>

Trigger Point Read more
Source§

fn layout_change( &mut self, wm: &mut WindowManager<X>, workspace_index: usize, screen_index: usize, ) -> Result<()>

Trigger Point Read more
Source§

fn workspace_change( &mut self, wm: &mut WindowManager<X>, previous_workspace: usize, new_workspace: usize, ) -> Result<()>

Trigger Point Read more
Source§

fn workspaces_updated( &mut self, wm: &mut WindowManager<X>, names: &[&str], active: usize, ) -> Result<()>

Trigger Point Read more
Source§

fn screens_updated( &mut self, wm: &mut WindowManager<X>, dimensions: &[Region], ) -> Result<()>

Trigger Point Read more
Source§

fn randr_notify(&mut self, wm: &mut WindowManager<X>) -> Result<()>

Trigger Point Read more
Source§

fn event_handled(&mut self, wm: &mut WindowManager<X>) -> Result<()>

Trigger Point Read more
Source§

impl PartialEq for ActiveWindowName

Source§

fn eq(&self, other: &ActiveWindowName) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Widget for ActiveWindowName

Source§

fn draw( &mut self, ctx: &mut dyn DrawContext, screen: usize, screen_has_focus: bool, w: f64, h: f64, ) -> Result<()>

Render the current state of the widget to the status bar window.
Source§

fn current_extent( &mut self, ctx: &mut dyn DrawContext, h: f64, ) -> Result<(f64, f64)>

Current required width and height for this widget due to its content
Source§

fn require_draw(&self) -> bool

Does this widget currently require re-rendering? (should be updated when ‘draw’ is called)
Source§

fn is_greedy(&self) -> bool

If true, this widget will expand to fill remaining available space after layout has been computed. If multiple greedy widgets are present in a given StatusBar then the available space will be split evenly between all widgets.
Source§

impl StructuralPartialEq for ActiveWindowName

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit #126799)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<X, T> HookableWidget<X> for T
where X: XConn, T: Hook<X> + Widget,