Hey all,

Mostly for fun, here's a simple replacement for xprop. It's 64 LOC,
compared to xprop's god-knows-how-many. It needs to be linked with
Xlib. Something like:
$ cc -o sprop sprop.c -lX11

It doesn't have the same arguments as xprop, but it can replace xprop
in surf's config.h like so:

12,13c12
< "prop=\"`xprop -id $1 $0 | cut -d '\"' -f 2 | dmenu`\" &&" \
< "xprop -id $1 -f $0 8s -set $0 \"$prop\"", \
---
> "prop=\"`sprop $1 $0 | dmenu`\" && sprop $1 $0 \"$prop\"", \

(If you pull dmenu tip you can also use flags like "-e $1 -l 1", which
is awesome.)

There is no real point besides "less is more".

Happy Easter!

cls

Attachment: sprop.c
Description: Binary data

Reply via email to