feat: format-icon for persistent workspaces

pull/651/head
Alex 2020-04-04 21:13:25 +02:00
parent ec451b5908
commit bb2c16386b
2 changed files with 3 additions and 0 deletions

View File

@ -75,6 +75,7 @@ Additional to workspace name matching, the following *format-icons* can be set.
- *default*: Will be shown, when no string matches is found.
- *urgent*: Will be shown, when workspace is flagged as urgent
- *focused*: Will be shown, when workspace is focused
- *persistent*: Will be shown, when workspace is persistent one.
# PERSISTENT WORKSPACES

View File

@ -205,6 +205,8 @@ std::string Workspaces::getIcon(const std::string &name, const Json::Value &node
if (config_["format-icons"][key].isString() && node[key].asBool()) {
return config_["format-icons"][key].asString();
}
} else if (config_["format_icons"]["persistent"].isString() && node["target_output"].isString()) {
return config_["format-icons"]["persistent"].asString();
} else if (config_["format-icons"][key].isString()) {
return config_["format-icons"][key].asString();
}