From 73e08154a4ed143fca23bbd4321dea62eba72f90 Mon Sep 17 00:00:00 2001 From: mwcp5 <90090630+mwcp5@users.noreply.github.com> Date: Sun, 5 Jun 2022 16:24:13 +0000 Subject: [PATCH 1/2] Change last workspace to "+" instead of number Changes last workspace to "+" instead of number if there are no windows open. Looks cool with dynamic workspaces! Got the idea from: https://github.com/christopher-l/space-bar --- extension.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/extension.js b/extension.js index 5e096c5..592cb1c 100644 --- a/extension.js +++ b/extension.js @@ -109,7 +109,11 @@ class WorkspacesBar extends PanelMenu.Button { if (this.workspaces_names[ws_index]) { this.ws_box.label.set_text(" " + this.workspaces_names[ws_index] + " "); } else { - this.ws_box.label.set_text(" " + (ws_index + 1) + " "); + if (this.ws_count == ws_index + 1 && this.active_ws_index != ws_index && global.workspace_manager.get_workspace_by_index(ws_index).n_windows == 0) { + this.ws_box.label.set_text(" + "); + } else { + this.ws_box.label.set_text(" " + (ws_index + 1) + " "); + } } this.ws_box.set_child(this.ws_box.label); this.ws_box.connect('button-release-event', () => this._toggle_ws(ws_index) ); From 1890e836e19095af2a59c64a7c6a043901872f87 Mon Sep 17 00:00:00 2001 From: mwcp5 <90090630+mwcp5@users.noreply.github.com> Date: Sun, 5 Jun 2022 16:32:22 +0000 Subject: [PATCH 2/2] Make backgrounds more transparent and sleek Also makes padding a bit diffrent --- stylesheet.css | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/stylesheet.css b/stylesheet.css index 1e0a55a..39e274d 100644 --- a/stylesheet.css +++ b/stylesheet.css @@ -39,27 +39,31 @@ /* non-framed version */ .desktop-label-nonempty-active { + padding: 3px 0; margin-left: 0px; margin-right: 8px; - background-color: rgba(154, 154, 154, 0.7); + background-color: rgba(255, 255, 255, 0.3); border-radius: 4px; } .desktop-label-nonempty-inactive { + padding: 3px 0; margin-left: 0px; margin-right: 8px; - background-color: rgba(96, 96, 96, 0.7); + background-color: rgba(0, 0, 0, 0.0); border-radius: 4px; } .desktop-label-empty-active { + padding: 3px 0; margin-left: 0px; margin-right: 8px; - background-color: rgba(154, 154, 154, 0.7); + background-color: rgba(255, 255, 255, 0.3); border-radius: 4px; } .desktop-label-empty-inactive { + padding: 3px 0; margin-left: 0px; margin-right: 8px; background-color: rgba(0, 0, 0, 0.0);