Skip to content

Commit

Permalink
Merge pull request Alexays#446 from bschacht/fix-typo-persistant
Browse files Browse the repository at this point in the history
Fix typo: persistant -> persistent
  • Loading branch information
Alexays committed Aug 31, 2019
2 parents f2f1c4f + 2646390 commit 36fc836
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions man/waybar-sway-workspaces.5.scd
Original file line number Diff line number Diff line change
Expand Up @@ -76,15 +76,15 @@ Additional to workspace name matching, the following *format-icons* can be set.
- *urgent*: Will be shown, when workspace is flagged as urgent
- *focused*: Will be shown, when workspace is focused

# PERSISTANT WORKSPACES
# PERSISTENT WORKSPACES

Each entry of *persistant_workspace* names a workspace that should always be shown.
Each entry of *persistent_workspace* names a workspace that should always be shown.
Associated with that value is a list of outputs indicating *where* the workspace should be shown,
an empty list denoting all outputs.

```
"sway/workspaces": {
"persistant_workspaces": {
"persistent_workspaces": {
"3": [], // Always show a workspace with name '3', on all outputs if it does not exists
"4": ["eDP-1"], // Always show a workspace with name '4', on output 'eDP-1' if it does not exists
"5": ["eDP-1", "DP-2"] // Always show a workspace with name '5', on outputs 'eDP-1' and 'DP-2' if it does not exists
Expand Down Expand Up @@ -120,4 +120,4 @@ n.b.: the list of outputs can be obtained from command line using *swaymsg -t ge
- *#workspaces button.visible*
- *#workspaces button.focused*
- *#workspaces button.urgent*
- *#workspaces button.persistant*
- *#workspaces button.persistent*
10 changes: 5 additions & 5 deletions src/modules/sway/workspaces.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ void Workspaces::onCmd(const struct Ipc::ipc_response &res) {
: true;
});

// adding persistant workspaces (as per the config file)
if (config_["persistant_workspaces"].isObject()) {
const Json::Value & p_workspaces = config_["persistant_workspaces"];
// adding persistent workspaces (as per the config file)
if (config_["persistent_workspaces"].isObject()) {
const Json::Value & p_workspaces = config_["persistent_workspaces"];
const std::vector<std::string> p_workspaces_names = p_workspaces.getMemberNames();

for (const std::string &p_w_name : p_workspaces_names) {
Expand Down Expand Up @@ -151,9 +151,9 @@ auto Workspaces::update() -> void {
button.get_style_context()->remove_class("urgent");
}
if ((*it)["target_output"].isString()) {
button.get_style_context()->add_class("persistant");
button.get_style_context()->add_class("persistent");
} else {
button.get_style_context()->remove_class("persistant");
button.get_style_context()->remove_class("persistent");
}
if (needReorder) {
box_.reorder_child(button, it - workspaces_.begin());
Expand Down

0 comments on commit 36fc836

Please sign in to comment.