trm wname - wmutils - X windows manipulation utilities
 (HTM) git clone git://z3bra.org/wmutils
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit 1be37b684a7d4e5fc3cc755330b311e2634a8ef4
 (DIR) parent 4acb2c2c6466433eeec51f4bdd762f6fe799e0bc
 (HTM) Author: dcat <dcat@iotek.org>
       Date:   Thu, 25 Jun 2015 19:16:49 +0200
       
       rm wname
       
       Diffstat:
         M Makefile                            |       1 -
         M man/Makefile                        |       1 -
         D man/wname.1                         |      18 ------------------
         D wname.c                             |      65 -------------------------------
       
       4 files changed, 0 insertions(+), 85 deletions(-)
       ---
 (DIR) diff --git a/Makefile b/Makefile
       t@@ -14,7 +14,6 @@ SRC =           \
                wrs.c   \
                chwb.c  \
                ignw.c  \
       -        wname.c \
                wmp.c
        
        OBJ = $(SRC:.c=.o)
 (DIR) diff --git a/man/Makefile b/man/Makefile
       t@@ -13,7 +13,6 @@ MAN =           \
                wrs.1   \
                chwb.1  \
                ignw.1  \
       -        wname.1 \
                wmp.1   \
                wmutils.1
        
 (DIR) diff --git a/man/wname.1 b/man/wname.1
       t@@ -1,18 +0,0 @@
       -.Dd December 13, 2014
       -.Dt WNAME 1
       -.Os wmutils
       -.Sh NAME
       -.Nm wname
       -.Nd print window name
       -.Sh SYNOPSIS
       -.Nm wname
       -.Ar wid Op ...
       -.Sh DESCRIPTION
       -.Nm
       -prints the name of the window IDs given as arguments,
       -one name per line.
       -.Sh ENVIRONMENT
       -.Nm
       -acts on the X display specified by the
       -.Ev DISPLAY
       -variable.
 (DIR) diff --git a/wname.c b/wname.c
       t@@ -1,65 +0,0 @@
       -/* See LICENSE file for copyright and license details. */
       -
       -#include <stdio.h>
       -#include <stdlib.h>
       -#include <xcb/xcb.h>
       -#include <err.h>
       -
       -#include "util.h"
       -
       -static xcb_connection_t *conn;
       -
       -static void usage(char *);
       -static int get_title(xcb_window_t);
       -
       -static void
       -usage(char *name)
       -{
       -        fprintf(stderr, "usage: %s <wid>\n", name);
       -        exit(1);
       -}
       -
       -static int
       -get_title(xcb_window_t win)
       -{
       -        int len = 0;
       -        xcb_get_property_cookie_t cookie;
       -        xcb_get_property_reply_t *r;
       -
       -        cookie = xcb_get_property(conn, 0, win,
       -                        XCB_ATOM_WM_NAME, XCB_ATOM_STRING, 0L, 32L);
       -        r = xcb_get_property_reply(conn, cookie, NULL);
       -
       -        if (r) {
       -                len = xcb_get_property_value_length(r);
       -                if (!len)
       -                        return 1;
       -
       -                printf("%.*s\n", len, (char *) xcb_get_property_value(r));
       -
       -                free(r);
       -                return 0;
       -        }
       -
       -        warnx("could not get window title");
       -        free(r);
       -        return 1;
       -}
       -
       -int
       -main(int argc, char **argv)
       -{
       -        int i, r = 0;
       -
       -        if (argc < 2)
       -                usage(argv[0]);
       -
       -        init_xcb(&conn);
       -
       -        for (i=1; i < argc; i++)
       -                r += get_title(strtoul(argv[i], NULL, 16));
       -
       -        kill_xcb(&conn);
       -
       -        return r;
       -}