You are not logged in.

#1 2010-04-02 22:47:31

schen
Member
Registered: 2009-06-06
Posts: 468

Dwm patches [Solved]

Hello, I've started to use DWM and have gotten it to look exactly the way I want, except for one thing. Is there anyway to make all windows outside of the focus transparent?

Last edited by schen (2010-04-04 23:16:26)

Offline

#2 2010-04-02 23:13:14

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Offline

#3 2010-04-03 00:03:32

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

Thanks, but do you know how to apply the patch?

Offline

#4 2010-04-03 00:12:56

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: Dwm patches [Solved]

You could use the diff on the dwm wiki: http://dwm.suckless.org/patches/transparency

Or use one of Simon's patches as karol linked to. If so, for the c file, you just need to add it to your config.h (as per Simon's example:
http://github.com/simongmzlj/dwm/blob/master/config.h )

or for the diff:

patch -p1 < opacity.diff

Last edited by jasonwryan (2010-04-03 00:13:18)


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#5 2010-04-03 00:49:59

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

Thanks for all of your quick replies. I'll try it right now.

Unfortunately, I seem to have run into problems. Apparently, makepkg doesn't recognize opacity.c even though it is in the build directory.

==> Making package: dwm 5.7.2-2 x86_64 (Fri Apr  2 20:10:29 CDT 2010)
==> Checking Runtime Dependencies...
==> Checking Buildtime Dependencies...
==> WARNING: Skipping source retrieval        -- using existing src/ tree
==> WARNING: Skipping source integrity checks -- using existing src/ tree
==> WARNING: Skipping source extraction       -- using existing src/ tree
==> Removing existing pkg/ directory...
==> Entering fakeroot environment...
==> Starting build()...
dwm build options:
CFLAGS   = -std=c99 -pedantic -Wall -Os -I. -I/usr/include -I/usr/include/X11 -DVERSION="5.7.2" -DXINERAMA
LDFLAGS  = -s -L/usr/lib -lc -L/usr/lib/X11 -lX11 -L/usr/lib/X11 -lXinerama
CC       = cc
CC dwm.c
In file included from dwm.c:274:
config.h:53:21: error: opacity.c: No such file or directory
make: *** [dwm.o] Error 1
==> ERROR: Build Failed.
    Aborting...

Last edited by schen (2010-04-03 01:14:52)

Offline

#6 2010-04-03 16:25:58

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

I've also tried both diffs with the same error of not knowing which file to patch.

Offline

#7 2010-04-03 19:20:31

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: Dwm patches [Solved]

You are attempting to patch dwm.c, aren't you?


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#8 2010-04-04 00:40:45

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

Where is dwm.c? Yes, I am trying to patch that.

Offline

#9 2010-04-04 00:43:23

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: Dwm patches [Solved]

In the source directory...

 cd {your build directory}/dwm/src/dwm-5.7.2/

Last edited by jasonwryan (2010-04-04 00:43:52)


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#10 2010-04-04 15:12:57

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

I don't have a source directory, because I installed dwm from ABS.

Last edited by schen (2010-04-04 19:21:05)

Offline

#11 2010-04-04 15:33:25

bharani
Member
From: Karaikudi, India
Registered: 2009-07-12
Posts: 202

Re: Dwm patches [Solved]

You can download the dwm source ,patch and install it yourselt It is not much complicated and very fast.And you can have a very customized dwm that suits  you.


Tamil is my mother tongue.

Offline

#12 2010-04-04 15:34:50

sam87
Member
From: down the rabbit hole
Registered: 2009-09-26
Posts: 141

Re: Dwm patches [Solved]

well then why not create one?get it from the abs directory, /var/abs/community/dwm i think, and then build dwm using makepkg and do your thing.You must have opacity.c in the dwm.c source directory as jason said, or you will get errors.


what i cannot build, i do not understand

Offline

#13 2010-04-04 20:59:20

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: Dwm patches [Solved]

schen wrote:

I don't have a source directory, because I installed dwm from ABS.

If you installed from ABS, you must have a source directory: you had to unpack the tarball somewhere...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#14 2010-04-04 21:15:56

skottish
Forum Fellow
From: Here
Registered: 2006-06-16
Posts: 7,942

Re: Dwm patches [Solved]

jasonwryan wrote:
schen wrote:

I don't have a source directory, because I installed dwm from ABS.

If you installed from ABS, you must have a source directory: you had to unpack the tarball somewhere...

schen probably used some sort of build tool like yaourt and accepted the defaults.

Offline

#15 2010-04-04 21:22:58

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: Dwm patches [Solved]

skottish wrote:
jasonwryan wrote:
schen wrote:

I don't have a source directory, because I installed dwm from ABS.

If you installed from ABS, you must have a source directory: you had to unpack the tarball somewhere...

schen probably used some sort of build tool like yaourt and accepted the defaults.

In which case this thread is rather pointless...

Archwiki entry on dwm wrote:

Note that by omitting compiling dwm from source a great deal of customizability is lost, since dwm's entire configuration is performed by editing its source code.


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#16 2010-04-04 22:11:09

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

I meant to say ABS, not AUR.

EDIT: Nevermind.

I followed the instructions in the ArchWiki article, which said to copy the ABS files from /var.

Last edited by schen (2010-04-04 22:14:09)

Offline

#17 2010-04-04 22:13:26

skottish
Forum Fellow
From: Here
Registered: 2006-06-16
Posts: 7,942

Re: Dwm patches [Solved]

schen wrote:

I meant to say ABS, not AUR.

Please explain the steps that you took to build DWM so that we can help you.

Offline

#18 2010-04-04 22:15:47

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

[wiki]http://wiki.archlinux.org/index.php/Dwm#Installing[/wiki]

Here are the instructions I took!

Last edited by schen (2010-04-04 22:17:35)

Offline

#19 2010-04-04 22:44:57

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: Dwm patches [Solved]

OK, so if you followed this to the letter, you should have a directory called ~/dwm

$ cp -r /var/abs/community/dwm ~/dwm

So, your source directory is ~/dwm/src/dwm-5.7.2/ - and therein you will find dwm.c. To patch this file, copy the .diff to the same directory and issue the patch command:

patch -p1 < yourdiff.diff

And away you go...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#20 2010-04-04 22:54:27

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

Oh!!!

Thank you very much! I didn't see the src directory in my dwm directory!

Offline

#21 2010-04-04 23:10:04

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

I ran into another problem...

When I patched dwm.c with the transparency patch from suckless.org, everything went well. However, when trying to recompile, this error came up.

==> Making package: dwm 5.7.2-2 x86_64 (Sun Apr  4 18:07:28 CDT 2010)
==> Checking Runtime Dependencies...
==> Checking Buildtime Dependencies...
==> WARNING: Skipping source retrieval        -- using existing src/ tree
==> WARNING: Skipping source integrity checks -- using existing src/ tree
==> WARNING: Skipping source extraction       -- using existing src/ tree
==> Removing existing pkg/ directory...
==> Entering fakeroot environment...
==> Starting build()...
dwm build options:
CFLAGS   = -std=c99 -pedantic -Wall -Os -I. -I/usr/include -I/usr/include/X11 -DVERSION="5.7.2" -DXINERAMA
LDFLAGS  = -s -L/usr/lib -lc -L/usr/lib/X11 -lX11 -L/usr/lib/X11 -lXinerama
CC       = cc
CC dwm.c
dwm.c: In function 'focus':
dwm.c:835: error: 'shade' undeclared (first use in this function)
dwm.c:835: error: (Each undeclared identifier is reported only once
dwm.c:835: error: for each function it appears in.)
make: *** [dwm.o] Error 1
==> ERROR: Build Failed.
    Aborting...

Last edited by schen (2010-04-04 23:10:46)

Offline

#22 2010-04-04 23:12:56

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: Dwm patches [Solved]

Have you added the function to your config.h?

static const double shade     = 0.6;      /* opacity of unfocussed clients */

Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#23 2010-04-04 23:15:54

schen
Member
Registered: 2009-06-06
Posts: 468

Re: Dwm patches [Solved]

Wow, you guys are helpful! You guys are the best! I guess that's why I chose Arch Linux: for the helpful community.;)

Last edited by schen (2010-04-04 23:16:13)

Offline

Board footer

Powered by FluxBB