summaryrefslogtreecommitdiff
path: root/config/config.go
blob: 71c377cdf041a4903f6e5f8e05024544c0c83b72 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
package config // import "hhvn.uk/hbspbar/config"

import "image/color"

// Bar height
var H         uint    = 17

const (
	// Bar colours
	xBg       = 0xff050a10
	xUnselMon = 0xff0c1726
	xStatus   = 0xff0a2126
	xFg       = 0xffeeeeee
	xFgDark   = 0xff444444
	xSel      = 0xff1b364b
	xUrg      = 0xff90222b

	// Status colours
	xRed      = 0xffaa2222
	xOrange   = 0xffaa7700
	xGreen    = 0xff00aa00
	xBlack    = 0xff000000
	xGrey     = 0xff888888
	xYellow   = 0xffaaaa00
	xWhite    = 0xffcccccc
)

func int2rgb(argb uint32) (color.Color) {
	return color.RGBA{
		B: uint8( argb & 0x000000ff),
		G: uint8((argb & 0x0000ff00) >> 8),
		R: uint8((argb & 0x00ff0000) >> 16),
		A: uint8((argb & 0xff000000) >> 24) }
}

var (
	Bg       = int2rgb(xBg)
	UnselMon = int2rgb(xUnselMon)
	Status   = int2rgb(xStatus)
	Fg       = int2rgb(xFg)
	FgDark   = int2rgb(xFgDark)
	Sel      = int2rgb(xSel)
	Urg      = int2rgb(xUrg)

	Red      = int2rgb(xRed)
	Orange   = int2rgb(xOrange)
	Green    = int2rgb(xGreen)
	Black    = int2rgb(xBlack)
	Grey     = int2rgb(xGrey)
	Yellow   = int2rgb(xYellow)
	White    = int2rgb(xWhite)
)

var Font      string  = "/usr/share/fonts/TTF/DejaVuSansMono.ttf"
var FontSize  float64 = 11.0
var FontYPad  int     = 1

// Space between status elements
var StatusPad int     = 15