Compare commits

..

1 Commits

Author SHA1 Message Date
Ujjwal Verma
ac0381bf16 Fixes #1 2017-09-03 03:21:21 +05:30
2 changed files with 3 additions and 17 deletions

View File

@ -20,12 +20,11 @@ make clean
### Usage
```
Usage: xwinwrap [-g {w}x{h}+{x}+{y}] [-ni] [-argb] [-fdt] [-fs] [-s] [-st] [-sp] [-a] [-d] [-b] [-nf] [-o OPACITY] [-sh SHAPE] [-ov]-- COMMAND ARG1...
Usage: xwinwrap [-g {w}x{h}+{x}+{y}] [-ni] [-argb] [-fs] [-s] [-st] [-sp] [-a] [-b] [-nf] [-o OPACITY] [-sh SHAPE] [-ov]-- COMMAND ARG1...
Options:
-g - Specify Geometry (w=width, h=height, x=x-coord, y=y-coord. ex: -g 640x480+100+100)
-ni - Ignore Input
-argb - RGB
-fdt - force WID window a desktop type window
-fs - Full Screen
-un - Undecorated
-s - Sticky
@ -37,7 +36,6 @@ Options:
-o - Opacity value between 0 to 1 (ex: -o 0.20)
-sh - Shape of window (choose between rectangle, circle or triangle. Default is rectangle)
-ov - Set override_redirect flag (For seamless desktop background integration in non-fullscreenmode)
-d - Daemonize
-debug - Enable debug messages
```
Example

View File

@ -133,13 +133,12 @@ static void sigHandler (int sig)
static void usage (void)
{
fprintf(stderr, "%s \n", NAME);
fprintf (stderr, "\nUsage: %s [-g {w}x{h}+{x}+{y}] [-ni] [-argb] [-fdt] [-fs] [-s] [-st] [-sp] [-a] [-d] "
fprintf (stderr, "\nUsage: %s [-g {w}x{h}+{x}+{y}] [-ni] [-argb] [-fs] [-s] [-st] [-sp] [-a] "
"[-b] [-nf] [-o OPACITY] [-sh SHAPE] [-ov]-- COMMAND ARG1...\n", NAME);
fprintf (stderr, "Options:\n \
-g - Specify Geometry (w=width, h=height, x=x-coord, y=y-coord. ex: -g 640x480+100+100)\n \
-ni - Ignore Input\n \
-argb - RGB\n \
-fdt - force WID window a desktop type window\n \
-fs - Full Screen\n \
-un - Undecorated\n \
-s - Sticky\n \
@ -151,7 +150,6 @@ static void usage (void)
-o - Opacity value between 0 to 1 (ex: -o 0.20)\n \
-sh - Shape of window (choose between rectangle, circle or triangle. Default is rectangle)\n \
-ov - Set override_redirect flag (For seamless desktop background integration in non-fullscreenmode)\n \
-d - Daemonize\n \
-debug - Enable debug messages\n");
}
@ -276,7 +274,6 @@ int main(int argc, char **argv)
bool have_argb_visual = false;
bool noInput = false;
bool argb = false;
bool set_desktop_type = false;
bool fullscreen = false;
bool noFocus = false;
bool override = false;
@ -311,10 +308,6 @@ int main(int argc, char **argv)
{
argb = true;
}
else if (strcmp (argv[i], "-fdt") == 0)
{
set_desktop_type = true;
}
else if (strcmp (argv[i], "-fs") == 0)
{
fullscreen = 1;
@ -532,12 +525,7 @@ int main(int argc, char **argv)
xa = ATOM(_NET_WM_WINDOW_TYPE);
Atom prop;
if (set_desktop_type)
{
prop = ATOM(_NET_WM_WINDOW_TYPE_DESKTOP);
} else {
prop = ATOM(_NET_WM_WINDOW_TYPE_NORMAL);
}
prop = ATOM(_NET_WM_WINDOW_TYPE_NORMAL);
XChangeProperty(display, window.window, xa, XA_ATOM, 32,
PropModeReplace, (unsigned char *) &prop, 1);