Enum swayr::cmds::SwayrCommand
source · pub enum SwayrCommand {
Show 42 variants
Nop,
SwitchToUrgentOrLRUWindow {
skip_flags: SkipFlags,
},
SwitchToAppOrUrgentOrLRUWindow {
name: String,
skip_flags: SkipFlags,
},
SwitchToMarkOrUrgentOrLRUWindow {
con_mark: String,
skip_flags: SkipFlags,
},
SwitchToMatchingOrUrgentOrLRUWindow {
criteria: String,
skip_flags: SkipFlags,
},
SwitchWindow,
StealWindow,
StealWindowOrContainer,
SwitchWorkspace,
SwitchOutput,
SwitchWorkspaceOrWindow,
SwitchWorkspaceContainerOrWindow,
SwitchTo,
QuitWindow {
kill: bool,
},
QuitWorkspaceOrWindow,
QuitWorkspaceContainerOrWindow,
NextWindow {
windows: ConsiderWindows,
},
PrevWindow {
windows: ConsiderWindows,
},
NextTiledWindow {
windows: ConsiderWindows,
},
PrevTiledWindow {
windows: ConsiderWindows,
},
NextTabbedOrStackedWindow {
windows: ConsiderWindows,
},
PrevTabbedOrStackedWindow {
windows: ConsiderWindows,
},
NextFloatingWindow {
windows: ConsiderWindows,
},
PrevFloatingWindow {
windows: ConsiderWindows,
},
NextWindowOfSameLayout {
windows: ConsiderWindows,
},
PrevWindowOfSameLayout {
windows: ConsiderWindows,
},
NextMatchingWindow {
criteria: String,
},
PrevMatchingWindow {
criteria: String,
},
MoveFocusedToWorkspace,
MoveFocusedTo,
SwapFocusedWith,
ToggleTabShuffleTileWorkspace {
floating: ConsiderFloating,
},
TileWorkspace {
floating: ConsiderFloating,
},
TabWorkspace {
floating: ConsiderFloating,
},
ShuffleTileWorkspace {
floating: ConsiderFloating,
},
ExecuteSwaymsgCommand,
ExecuteSwayrCommand,
ConfigureOutputs,
GetWindowsAsJson {
include_scratchpad: bool,
criteria: Option<String>,
error_if_no_match: bool,
},
ForEachWindow {
include_scratchpad: bool,
error_if_no_match: bool,
criteria: String,
shell_command: Vec<String>,
},
PrintConfig,
PrintDefaultConfig,
}
Variants§
Nop
No-operation. Interrupts any in-progress prev/next sequence but has no other effect
SwitchToUrgentOrLRUWindow
Switch to next urgent window (if any) or to last recently used window.
SwitchToAppOrUrgentOrLRUWindow
Fields
Switch to the given app (given by app_id or window class) if that’s not focused already. If it is, switch to the next urgent window (if any) or to last recently used window.
For example, you can provide “firefox” as argument to this command to have a convenient firefox <-> last-recently-used window toggle.
SwitchToMarkOrUrgentOrLRUWindow
Switch to the window with the given mark if that’s not focused already. If it is, switch to the next urgent window (if any) or to last recently used window.
For example, you can assign a “browser” mark to your browser window
(using a standard sway for_window
rule). Then you can provide
“browser” as argument to this command to have a convenient browser <->
last-recently-used window toggle.
SwitchToMatchingOrUrgentOrLRUWindow
Fields
Switch to the (first) window matching the given criteria (see section
CRITERIA
in sway(5)
) if it exists and is not already focused.
Otherwise, switch to the next urgent window (if any) or to the last
recently used window.
SwitchWindow
Focus the selected window.
StealWindow
Steal the selected window from another workspace into the current workspace.
StealWindowOrContainer
Steal the selected window or container from another workspace into the current workspace.
SwitchWorkspace
Switch to the selected workspace.
SwitchOutput
Switch to the selected output.
SwitchWorkspaceOrWindow
Switch to the selected workspace or focus the selected window.
SwitchWorkspaceContainerOrWindow
Switch to the selected workspace or focus the selected container, or window.
SwitchTo
Switch to the selected output or workspace or focus the selected container, or window.
QuitWindow
Quit the selected window.
QuitWorkspaceOrWindow
Quit all windows of selected workspace or the selected window.
QuitWorkspaceContainerOrWindow
Quit all windows of selected workspace, or container or the selected window.
NextWindow
Fields
windows: ConsiderWindows
Focus the next window in LRU order.
PrevWindow
Fields
windows: ConsiderWindows
Focus the previous window in LRU order.
NextTiledWindow
Fields
windows: ConsiderWindows
Focus the next window of a tiled container.
PrevTiledWindow
Fields
windows: ConsiderWindows
Focus the previous window of a tiled container.
NextTabbedOrStackedWindow
Fields
windows: ConsiderWindows
Focus the next window of a tabbed or stacked container.
PrevTabbedOrStackedWindow
Fields
windows: ConsiderWindows
Focus the previous window of a tabbed or stacked container.
NextFloatingWindow
Fields
windows: ConsiderWindows
Focus the next floating window.
PrevFloatingWindow
Fields
windows: ConsiderWindows
Focus the previous floating window.
NextWindowOfSameLayout
Fields
windows: ConsiderWindows
Focus the next window having the same layout as the current one.
PrevWindowOfSameLayout
Fields
windows: ConsiderWindows
Focus the previous window having the same layout as the current one.
NextMatchingWindow
Focus the next window matching the given criteria query.
PrevMatchingWindow
Focus the previous window matching the given criteria query.
MoveFocusedToWorkspace
Move the currently focused window or container to the selected workspace.
MoveFocusedTo
Move the currently focused window or container to the selected output, workspace, container or window.
SwapFocusedWith
Swap the currently focused window or container with the selected container or window.
ToggleTabShuffleTileWorkspace
Fields
floating: ConsiderFloating
Tab or shuffle-and-tile the windows on the current workspace, including or excluding floating windows.
TileWorkspace
Fields
floating: ConsiderFloating
Tiles the windows on the current workspace, including or excluding floating windows.
TabWorkspace
Fields
floating: ConsiderFloating
Tabs the windows on the current workspace, including or excluding floating windows.
ShuffleTileWorkspace
Fields
floating: ConsiderFloating
Shuffles and tiles the windows on the current workspace, including or excluding floating windows.
ExecuteSwaymsgCommand
Select and execute a swaymsg command.
ExecuteSwayrCommand
Select and execute a swayr command.
ConfigureOutputs
Configure outputs.
GetWindowsAsJson
Returns a JSON array of all sway nodes being actual application windows
with some extra properties not present in sway IPC (swayr_icon
,
swayr_type
).
ForEachWindow
Executes a shell command for each matching window.
PrintConfig
Print the current effective swayr configuration (without default values).
PrintDefaultConfig
Prints the default swayr configuration.
Trait Implementations§
source§impl Clone for SwayrCommand
impl Clone for SwayrCommand
source§fn clone(&self) -> SwayrCommand
fn clone(&self) -> SwayrCommand
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl CommandFactory for SwayrCommand
impl CommandFactory for SwayrCommand
source§impl Debug for SwayrCommand
impl Debug for SwayrCommand
source§impl<'de> Deserialize<'de> for SwayrCommand
impl<'de> Deserialize<'de> for SwayrCommand
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
source§impl DisplayFormat for SwayrCommand
impl DisplayFormat for SwayrCommand
fn format_for_display(&self) -> String
fn get_indent_level(&self) -> usize
source§impl FromArgMatches for SwayrCommand
impl FromArgMatches for SwayrCommand
source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches ) -> Result<Self, Error>
source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches ) -> Result<(), Error>
ArgMatches
to self
.source§fn update_from_arg_matches_mut<'b>(
&mut self,
__clap_arg_matches: &mut ArgMatches
) -> Result<(), Error>
fn update_from_arg_matches_mut<'b>( &mut self, __clap_arg_matches: &mut ArgMatches ) -> Result<(), Error>
ArgMatches
to self
.source§impl Parser for SwayrCommand
impl Parser for SwayrCommand
§fn parse_from<I, T>(itr: I) -> Self
fn parse_from<I, T>(itr: I) -> Self
§fn try_parse_from<I, T>(itr: I) -> Result<Self, Error>
fn try_parse_from<I, T>(itr: I) -> Result<Self, Error>
§fn update_from<I, T>(&mut self, itr: I)
fn update_from<I, T>(&mut self, itr: I)
§fn try_update_from<I, T>(&mut self, itr: I) -> Result<(), Error>
fn try_update_from<I, T>(&mut self, itr: I) -> Result<(), Error>
source§impl PartialEq for SwayrCommand
impl PartialEq for SwayrCommand
source§fn eq(&self, other: &SwayrCommand) -> bool
fn eq(&self, other: &SwayrCommand) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for SwayrCommand
impl Serialize for SwayrCommand
source§impl Subcommand for SwayrCommand
impl Subcommand for SwayrCommand
source§fn augment_subcommands<'b>(__clap_app: Command) -> Command
fn augment_subcommands<'b>(__clap_app: Command) -> Command
source§fn augment_subcommands_for_update<'b>(__clap_app: Command) -> Command
fn augment_subcommands_for_update<'b>(__clap_app: Command) -> Command
source§fn has_subcommand(__clap_name: &str) -> bool
fn has_subcommand(__clap_name: &str) -> bool
Self
can parse a specific subcommandimpl Eq for SwayrCommand
impl StructuralEq for SwayrCommand
impl StructuralPartialEq for SwayrCommand
Auto Trait Implementations§
impl RefUnwindSafe for SwayrCommand
impl Send for SwayrCommand
impl Sync for SwayrCommand
impl Unpin for SwayrCommand
impl UnwindSafe for SwayrCommand
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
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.