]> git.madduck.net Git - etc/awesome.git/blob - borderbox.md

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

Updated Home (markdown)
[etc/awesome.git] / borderbox.md
1 [<- widgets](https://github.com/copycat-killer/lain/wiki/Widgets)
2
3 Creates a thin wibox at a position relative to another wibox.
4
5 This allows to create "borders" for your wiboxes.
6
7         lain.widget.borderbox(relbox, s, args)
8
9 `relbox` and `s` (an integer being screen number) are required arguments, `args` is an optional table
10 which can contain:
11
12 Variable | Meaning | Type | Default
13 --- | --- | --- | ---
14 `position` | Position of the additional box | string | "above"
15 `color` | Color of the additional box | string | `#FFFFFF`
16 `size` | Size in pixels of the additional box | int | 1
17
18 Possible values for `.position`: `top`, `bottom`, `left` and `right`.
19
20 ### Example usage
21
22 Think of this as a wibox:
23
24         [======================]
25
26 If `args.position = "above"`, then you'll get an additional wibox below
27 the existing one:
28
29         ________________________
30         [======================]
31
32 It'll match position and size of the existing wibox.
33
34 If your main wiboxes are stored in a table called `mywibox` (one wibox
35 for each screen) and are located at the bottom of your screen, then this
36 adds a borderbox on top of them:
37
38     -- Layout section
39         for s = 1, screen.count() do
40         ...
41
42             -- Most likely, you'll want to do this as well:
43             awful.screen.padding(screen[s], "bottom")
44
45             -- Create the box and place it above the existing box.
46             lain.widgets.borderbox(mywibox[s], s )
47
48         ...
49         end