added feature: Associating names with views, which are shown in the status bar.
This commit is contained in:
parent
404c91f6ba
commit
0f6215b162
4 changed files with 24 additions and 13 deletions
|
@ -49,7 +49,7 @@ Bar_init(m) {
|
||||||
; tags
|
; tags
|
||||||
Loop, % Config_viewCount {
|
Loop, % Config_viewCount {
|
||||||
i := A_Index
|
i := A_Index
|
||||||
text := " " i " "
|
text := " " Config_viewNames_#%i% " "
|
||||||
w := Bar_getTextWidth(text)
|
w := Bar_getTextWidth(text)
|
||||||
Gui, Add, Text, x%x1% y%y1% w%w% h%h1% BackgroundTrans vBar_#%m%_#%i%_view gBar_GuiClick,
|
Gui, Add, Text, x%x1% y%y1% w%w% h%h1% BackgroundTrans vBar_#%m%_#%i%_view gBar_GuiClick,
|
||||||
If (w <= h1)
|
If (w <= h1)
|
||||||
|
@ -80,8 +80,8 @@ Bar_init(m) {
|
||||||
w := Bar_getTextWidth(" ?? ")
|
w := Bar_getTextWidth(" ?? ")
|
||||||
x2 -= w
|
x2 -= w
|
||||||
titleWidth -= w
|
titleWidth -= w
|
||||||
Gui, Add, Text, x%x2% y%y1% w%w% h%h1% BackgroundTrans vBar_#%m%_#%i% gBar_toggleCommandGui,
|
Gui, Add, Text, x%x2% y%y1% w%w% h%h1% BackgroundTrans vBar_#%m%_#%i% gBar_toggleCommandGui,
|
||||||
Gui, Add, Progress, x%x2% y%y1% w%w% h%h1% Background%Config_normBgColor2%
|
Gui, Add, Progress, x%x2% y%y1% w%w% h%h1% Background%Config_normBgColor2%
|
||||||
Gui, Add, Text, x%x2% y%y2% w%w% h%h2% Center BackgroundTrans, #!
|
Gui, Add, Text, x%x2% y%y2% w%w% h%h2% Center BackgroundTrans, #!
|
||||||
} Else If (i = Config_viewCount + 5) And Config_readinTime { ; time
|
} Else If (i = Config_viewCount + 5) And Config_readinTime { ; time
|
||||||
w := Bar_getTextWidth(" ??:?? ")
|
w := Bar_getTextWidth(" ??:?? ")
|
||||||
|
@ -752,6 +752,6 @@ Bar_updateView(m, v) {
|
||||||
; Update the percentage fill for the view.
|
; Update the percentage fill for the view.
|
||||||
GuiControl, , Bar_#%m%_#%A_Index%_tagged, % ViewIdsLen / IdsLen * 100
|
GuiControl, , Bar_#%m%_#%A_Index%_tagged, % ViewIdsLen / IdsLen * 100
|
||||||
; Refresh the number on the bar.
|
; Refresh the number on the bar.
|
||||||
GuiControl, , Bar_#%m%_#%A_Index%, %A_Index%
|
GuiControl, , Bar_#%m%_#%A_Index%, % Config_viewNames_#%A_Index%
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
Config_init() {
|
Config_init() {
|
||||||
Local i, key, layout0, layout1, layout2
|
Local i, key, layout0, layout1, layout2, vNames0, vNames1, vNames2, vNames3, vNames4, vNames5, vNames6, vNames7, vNames8, vNames9
|
||||||
|
|
||||||
; status bar
|
; status bar
|
||||||
Config_showBar := True ; If false, the bar is hidden. It can be made visible or hidden by hotkey (see below).
|
Config_showBar := True ; If false, the bar is hidden. It can be made visible or hidden by hotkey (see below).
|
||||||
|
@ -52,7 +52,7 @@ Config_init() {
|
||||||
Config_selBorderColor := "" ; Border colour of the active window; format: 0x00BBGGRR (e. g. "0x006A240A", if = "", the system's window border colour is not changed).
|
Config_selBorderColor := "" ; Border colour of the active window; format: 0x00BBGGRR (e. g. "0x006A240A", if = "", the system's window border colour is not changed).
|
||||||
; Config_borderWidth, Config_borderPadding and Config_selBorderColor are especially usefull, if you are not allowed to set the design in the system settings.
|
; Config_borderWidth, Config_borderPadding and Config_selBorderColor are especially usefull, if you are not allowed to set the design in the system settings.
|
||||||
; window arrangement
|
; window arrangement
|
||||||
Config_viewCount := 9 ; The total number of views. This has effects on the displayed groups in the bar, and should not be exceeded in the hotkeys below.
|
Config_viewNames := "1;2;3;4;5;6;7;8;9" ; The names of the views separated by a semicolon. This variable sets the names of the views shown in the status bar and determines the nummber of views (Config_viewCount); the total number of names given, i. e. views, should not be exceeded in the hotkeys section below.
|
||||||
Config_layout_#1 := "[]=;tile" ; The layout symbol and arrange function (the first entry is set as the default layout, no layout function means floating behavior)
|
Config_layout_#1 := "[]=;tile" ; The layout symbol and arrange function (the first entry is set as the default layout, no layout function means floating behavior)
|
||||||
Config_layout_#2 := "[M];monocle"
|
Config_layout_#2 := "[M];monocle"
|
||||||
Config_layout_#3 := "><>;"
|
Config_layout_#3 := "><>;"
|
||||||
|
@ -104,9 +104,14 @@ Config_init() {
|
||||||
StringSplit, layout, Config_layout_#%A_Index%, `;
|
StringSplit, layout, Config_layout_#%A_Index%, `;
|
||||||
Config_layoutFunction_#%A_Index% := layout2
|
Config_layoutFunction_#%A_Index% := layout2
|
||||||
Config_layoutSymbol_#%A_Index% := layout1
|
Config_layoutSymbol_#%A_Index% := layout1
|
||||||
}
|
}
|
||||||
If (Config_viewCount > 9)
|
StringSplit, vNames, Config_viewNames, `;
|
||||||
Config_viewCount := 9
|
If vNames0 > 9
|
||||||
|
Config_viewCount := 9
|
||||||
|
Else
|
||||||
|
Config_viewCount := vNames0
|
||||||
|
Loop, % Config_viewCount
|
||||||
|
Config_viewNames_#%A_Index% := vNames%A_Index%
|
||||||
}
|
}
|
||||||
|
|
||||||
Config_initColors() {
|
Config_initColors() {
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
(~) changed
|
(~) changed
|
||||||
(+) added
|
(+) added
|
||||||
|
|
||||||
=8.2.2(?)=
|
=8.3.0=
|
||||||
|
|
||||||
(+) Multi-dimensional tiling of the master area. The user may now specify
|
(+) Multi-dimensional tiling of the master area. The user may now specify
|
||||||
X and Y dimensions independently up to 9 x 9.
|
X and Y dimensions independently up to 9 x 9.
|
||||||
|
@ -26,6 +26,10 @@
|
||||||
a non-active monitor could cause both monitors to change views.
|
a non-active monitor could cause both monitors to change views.
|
||||||
(~) Gap widths are now treated identically on both "tile" and "monocle"
|
(~) Gap widths are now treated identically on both "tile" and "monocle"
|
||||||
layouts.
|
layouts.
|
||||||
|
(+) Added the configuration variable "Config_viewNames", with which views
|
||||||
|
can be named and the number of views can be set. The configuration
|
||||||
|
variable "Config_viewCount" therewith becomes obsolete.
|
||||||
|
(-) Removed the configuration variable "Config_viewCount".
|
||||||
|
|
||||||
|
|
||||||
=8.2.1=
|
=8.2.1=
|
||||||
|
|
|
@ -156,9 +156,11 @@ settings.
|
||||||
|
|
||||||
=== View / Layout ===
|
=== View / Layout ===
|
||||||
|
|
||||||
: **Config_viewCount**=9
|
: **Config_viewNames**=1;2;3;4;5;6;7;8;9
|
||||||
The total number of views. This has effects on the displayed groups in
|
The names of the views in use separated by a semicolon. With the number
|
||||||
the bar, and should not be exceeded in the hotkeys below.
|
of fields in this list the total number of views is given. This has
|
||||||
|
effects on the displayed groups in the bar, and should not be exceeded in
|
||||||
|
the hotkeys section of the configuration.
|
||||||
|
|
||||||
: **Config_layout_#1**=[]=;tile
|
: **Config_layout_#1**=[]=;tile
|
||||||
The layout symbol and arrange function (the first entry is set as the
|
The layout symbol and arrange function (the first entry is set as the
|
||||||
|
|
Loading…
Reference in a new issue