diff options
author | QC <qball@gmpclient.org> | 2014-05-15 21:55:23 +0200 |
---|---|---|
committer | QC <qball@gmpclient.org> | 2014-05-15 21:55:23 +0200 |
commit | 3ebd0d9001ecab3bc4264a6447fd045bcf338eff (patch) | |
tree | 4b9899fdb40c4b61a2fb4f6940444f840771a8e1 /source | |
parent | 82bdb5f348688c7427a77fcfaed91881b2e2d84a (diff) |
Allow xoffset, fix bottom/right edge.
Diffstat (limited to 'source')
-rw-r--r-- | source/rofi.c | 9 | ||||
-rw-r--r-- | source/xrmoptions.c | 1 |
2 files changed, 6 insertions, 4 deletions
diff --git a/source/rofi.c b/source/rofi.c index ca9f3105..43e9ecab 100644 --- a/source/rofi.c +++ b/source/rofi.c @@ -1206,18 +1206,18 @@ MenuReturn menu ( char **lines, char **input, char *prompt, Time *time, int *shi y = mon.y; case WL_EAST: - x = mon.x + mon.w - w; + x = mon.x + mon.w - w-config.menu_bw*2; break; case WL_EAST_SOUTH: - x = mon.x + mon.w - w; + x = mon.x + mon.w - w-config.menu_bw*2; case WL_SOUTH: - y = mon.y + mon.h - h; + y = mon.y + mon.h - h-config.menu_bw*2; break; case WL_SOUTH_WEST: - y = mon.y + mon.h - h; + y = mon.y + mon.h - h-config.menu_bw*2; case WL_WEST: x = mon.x; @@ -1229,6 +1229,7 @@ MenuReturn menu ( char **lines, char **input, char *prompt, Time *time, int *shi } // Apply offset. y+= config.y_offset; + x+= config.x_offset; XMoveResizeWindow ( display, box, x, y, w, h ); diff --git a/source/xrmoptions.c b/source/xrmoptions.c index f6f3d50f..771feb01 100644 --- a/source/xrmoptions.c +++ b/source/xrmoptions.c @@ -65,6 +65,7 @@ XrmOption xrmOptions[] = { { xrm_String, "terminal", { .str = &config.terminal_emulator } }, { xrm_Number, "location", { .num = &config.location } }, { xrm_Number, "yoffset", { .num = &config.y_offset } }, + { xrm_Number, "xoffset", { .num = &config.x_offset } }, }; |