Titlebar and Statusbar height

From awesome

Jump to: navigation, search

Minimum requirements

  • Awesome version 3.
  • Your favorite text editor (like VIM).
  • A few minutes.


Titlebar

You need patched version of awful library. It placed at /usr/share/awesome/lib/awful.lua

Edit function titlebar.add(c, args) and add "if args.height then targs.height = args.height end" like below:

    -- Built args
    local targs = {}
    -- height attribute support
    if args.height then targs.height = args.height end
    if args.fg then targs.fg = args.fg end
    if args.bg then targs.bg = args.bg end
    local tb = capi.titlebar(targs)

Now we should edit rc.lua file.

Edit function hook_manage(c) like below:

    if use_titlebar then
        -- Add a titlebar
        awful.titlebar.add(c, { modkey = modkey, height = "14" })
    end


Statusbar

Like a Titlebar we should edit rc.lua file again. Look in file line

mystatusbar[s] = statusbar({ position = "top", name = "mystatusbar" .. s,

and change it to

mystatusbar[s] = statusbar({ position = "top", name = "mystatusbar" .. s, height = "16",


Now we ready to reload config. Press Meta4+Ctrl+r and enjoy ;)


* Awesome version 3.4.1

Only need to edit rc.lua file.

    -- Create the wibox
    mywibox[s] = awful.wibox({ position = "top", height = "18", screen = s })
Personal tools