Enum DispatchType
pub enum DispatchType<'a> {
Show 60 variants
Custom(&'a str, &'a str),
SetCursor(&'a str, u16),
Exec(&'a str),
Pass(WindowIdentifier<'a>),
Global(&'a str),
KillActiveWindow,
CloseWindow(WindowIdentifier<'a>),
Workspace(WorkspaceIdentifierWithSpecial<'a>),
MoveToWorkspace(WorkspaceIdentifierWithSpecial<'a>, Option<WindowIdentifier<'a>>),
MoveToWorkspaceSilent(WorkspaceIdentifierWithSpecial<'a>, Option<WindowIdentifier<'a>>),
ToggleFloating(Option<WindowIdentifier<'a>>),
ToggleFullscreen(FullscreenType),
ToggleFakeFullscreen,
ToggleDPMS(bool, Option<&'a str>),
TogglePseudo,
TogglePin,
MoveFocus(Direction),
MoveWindow(WindowMove<'a>),
CenterWindow,
ResizeActive(Position),
MoveActive(Position),
ResizeWindowPixel(Position, WindowIdentifier<'a>),
MoveWindowPixel(Position, WindowIdentifier<'a>),
CycleWindow(CycleDirection),
SwapNext(CycleDirection),
SwapWindow(Direction),
FocusWindow(WindowIdentifier<'a>),
FocusMonitor(MonitorIdentifier<'a>),
ChangeSplitRatio(f32),
ToggleOpaque,
MoveCursorToCorner(Corner),
MoveCursor(i64, i64),
WorkspaceOption(WorkspaceOptions),
RenameWorkspace(i32, Option<&'a str>),
Exit,
ForceRendererReload,
MoveCurrentWorkspaceToMonitor(MonitorIdentifier<'a>),
MoveWorkspaceToMonitor(WorkspaceIdentifier<'a>, MonitorIdentifier<'a>),
SwapActiveWorkspaces(MonitorIdentifier<'a>, MonitorIdentifier<'a>),
BringActiveToTop,
ToggleSpecialWorkspace(Option<String>),
FocusUrgentOrLast,
FocusCurrentOrLast,
ToggleSplit,
SwapWithMaster(SwapWithMasterParam),
FocusMaster(FocusMasterParam),
AddMaster,
RemoveMaster,
OrientationLeft,
OrientationRight,
OrientationTop,
OrientationBottom,
OrientationCenter,
OrientationNext,
OrientationPrev,
ToggleGroup,
ChangeGroupActive(WindowSwitchDirection),
LockGroups(LockType),
MoveIntoGroup(Direction),
MoveOutOfGroup,
}
Expand description
This enum holds every dispatcher
Variants§
Custom(&'a str, &'a str)
This lets you use dispatchers not supported by hyprland-rs yet, please make issues before using
SetCursor(&'a str, u16)
This dispatcher changes the current cursor
Exec(&'a str)
This dispatcher executes a program
Pass(WindowIdentifier<'a>)
This dispatcher passes a keybind to a window when called in a keybind, its used for global keybinds. And should ONLY be used with keybinds
Global(&'a str)
Executes a Global Shortcut using the GlobalShortcuts portal.
KillActiveWindow
This dispatcher kills the active window/client
CloseWindow(WindowIdentifier<'a>)
This dispatcher closes the specified window
Workspace(WorkspaceIdentifierWithSpecial<'a>)
This dispatcher changes the current workspace
MoveToWorkspace(WorkspaceIdentifierWithSpecial<'a>, Option<WindowIdentifier<'a>>)
This dispatcher moves a window (focused if not specified) to a workspace
MoveToWorkspaceSilent(WorkspaceIdentifierWithSpecial<'a>, Option<WindowIdentifier<'a>>)
This dispatcher moves a window (focused if not specified) to a workspace, without switching to that workspace
ToggleFloating(Option<WindowIdentifier<'a>>)
This dispatcher floats a window (current if not specified)
ToggleFullscreen(FullscreenType)
This dispatcher toggles the current window fullscreen state
ToggleFakeFullscreen
This dispatcher toggles the focused window’s internal fullscreen state without altering the geometry
ToggleDPMS(bool, Option<&'a str>)
This dispatcher sets the DPMS status for all monitors
TogglePseudo
This dispatcher toggles pseudo tiling for the current window
TogglePin
This dispatcher pins the active window to all workspaces
MoveFocus(Direction)
This dispatcher moves the window focus in a specified direction
MoveWindow(WindowMove<'a>)
This dispatcher moves the current window to a monitor or in a specified direction
CenterWindow
This dispatcher centers the active window
ResizeActive(Position)
This dispatcher resizes the active window using a Position enum
MoveActive(Position)
This dispatcher moves the active window using a Position enum
ResizeWindowPixel(Position, WindowIdentifier<'a>)
This dispatcher resizes the specified window using a Position enum
MoveWindowPixel(Position, WindowIdentifier<'a>)
This dispatcher moves the specified window using a Position enum
CycleWindow(CycleDirection)
This dispatcher cycles windows using a specified direction
SwapNext(CycleDirection)
This dispatcher swaps the focused window with the window on a workspace using a specified direction
SwapWindow(Direction)
This dispatcher swaps windows using a specified direction
FocusWindow(WindowIdentifier<'a>)
This dispatcher focuses a specified window
FocusMonitor(MonitorIdentifier<'a>)
This dispatcher focuses a specified monitor
ChangeSplitRatio(f32)
This dispatcher changed the split ratio
ToggleOpaque
This dispatcher toggle opacity for the current window/client
MoveCursorToCorner(Corner)
This dispatcher moves the cursor to a specified corner of a window
MoveCursor(i64, i64)
This dispatcher moves the cursor to a specified position (x, y) where x starts from left to right, and y starts from top to bottom
WorkspaceOption(WorkspaceOptions)
This dispatcher applied a option to all windows in a workspace
RenameWorkspace(i32, Option<&'a str>)
This dispatcher renames a workspace
Exit
This exits Hyprland (DANGEROUS)
ForceRendererReload
This dispatcher forces the renderer to reload
MoveCurrentWorkspaceToMonitor(MonitorIdentifier<'a>)
This dispatcher moves the current workspace to a specified monitor
MoveWorkspaceToMonitor(WorkspaceIdentifier<'a>, MonitorIdentifier<'a>)
This dispatcher moves a specified workspace to a specified monitor
SwapActiveWorkspaces(MonitorIdentifier<'a>, MonitorIdentifier<'a>)
This dispatcher swaps the active workspaces of two monitors
BringActiveToTop
This dispatcher brings the active window to the top of the stack
ToggleSpecialWorkspace(Option<String>)
This toggles the special workspace (AKA scratchpad)
FocusUrgentOrLast
This dispatcher jump to urgent or the last window
FocusCurrentOrLast
Switch focus from current to previously focused window
ToggleSplit
Toggles the split (top/side) of the current window. preserve_split
must be enabled for toggling to work.
SwapWithMaster(SwapWithMasterParam)
Swaps the current window with master. If the current window is the master, swaps it with the first child.
FocusMaster(FocusMasterParam)
Focuses the master window.
AddMaster
Adds a master to the master side. That will be the active window, if it’s not a master, or the first non-master window.
RemoveMaster
Removes a master from the master side. That will be the active window, if it’s a master, or the last master window.
OrientationLeft
Sets the orientation for the current workspace to left (master area left, slave windows to the right, vertically stacked)
OrientationRight
Sets the orientation for the current workspace to right (master area right, slave windows to the left, vertically stacked)
OrientationTop
Sets the orientation for the current workspace to top (master area top, slave windows to the bottom, horizontally stacked)
OrientationBottom
Sets the orientation for the current workspace to bottom (master area bottom, slave windows to the top, horizontally stacked)
OrientationCenter
Sets the orientation for the current workspace to center (master area center, slave windows alternate to the left and right, vertically stacked)
OrientationNext
Cycle to the next orientation for the current workspace (clockwise)
OrientationPrev
Cycle to the previous orientation for the current workspace (counter-clockwise)
ToggleGroup
Toggles the current active window into a group
ChangeGroupActive(WindowSwitchDirection)
Switches to the next window in a group.
LockGroups(LockType)
Locks the groups
MoveIntoGroup(Direction)
Moves the active window into a group in a specified direction
MoveOutOfGroup
Moves the active window out of a group.
Trait Implementations§
§impl<'a> Clone for DispatchType<'a>
impl<'a> Clone for DispatchType<'a>
§fn clone(&self) -> DispatchType<'a>
fn clone(&self) -> DispatchType<'a>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl<'a> Freeze for DispatchType<'a>
impl<'a> RefUnwindSafe for DispatchType<'a>
impl<'a> Send for DispatchType<'a>
impl<'a> Sync for DispatchType<'a>
impl<'a> Unpin for DispatchType<'a>
impl<'a> UnwindSafe for DispatchType<'a>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more