0

im trying to setup DWM, im able to successfully patch few patches, but there a couple things im not able figure out

  1. im using this on a laptop so i want to bind my volume, brightness, play pause keys which are on the functions keys to be able to control the same. there is Fn button on the keyboard which if pressed with the combination of function keys register as normal function keys and if Fn key is not pressed then function keys act as brightness volume and all.

  2. i have everything mostly set up, but there is no status bar in my build, i want to use dwmblocks. but there 3 different patches on suckless.org website and it conflicts with my already patched build for eg there is a line in dwm.c file

else if (ev->x > selmon->ww - TEXTW(stext) - getsystraywidth())

and the patch wants me to remove this line -

else if (ev->x > selmon->ww - TEXTW(stext))

which i dont have same in my config as im using the systray patch, and wants me to replace with -

else if (ev->x > (x = selmon->ww - TEXTW(stext) + lrpad)) {

i dont know if im using the right patch, i want some help with installing the dwmblocks, as i dont want to install someone else's fork i want to configure my own.

0

I understand you don't want to use a fork but I strongly suggest bakkeby's dwm-flexipatch. Patching things on top of each other can quickly cause problems unless you know all the patches and its code. The linked repo modularises things as best as possible and I think this is the cleanest way to build the config. You can add in your own customization too.

| improve this answer | |
  • interesting, so this is basically a interactive installation script for DWM, and i can select which patches i want to include during installation? – apoorv569 Jun 2 at 9:12
  • that's right. And because of the way they structured it, future problems are also likely as long as you patch following the existing approach. – Littleone Jun 2 at 20:05
  • nice, thanks. about the other issue i have regarding binding volume and brightness and all those keys, do you know anything that can help me? – apoorv569 Jun 2 at 20:54
  • i was able to successfully patch the required patch for dwmblocks, its working now. it basically wanted me to do this - pastebin.com/ZXmxnfAc, but i did this - pastebin.com/UrSieMyu, as i wanted to use the sytemtray patch too. i dont know if this is the right way to do it. but its working now. – apoorv569 Jun 3 at 1:18
  • For those additional keys, you need to include X11/XF86keysym.h and then go wiki.linuxquestions.org/wiki/XF86_keyboard_symbols and find out the key you want to use. Then bind it for example: { 0, XF86XK_MonBrightnessUp, spawn, {.v = "xbacklight -inc 10" } }, Note the first 0 – Littleone Jun 4 at 17:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.