mirror of
https://github.com/davatorium/rofi.git
synced 2025-04-07 17:33:14 -04:00
Add a y-offset.
This commit is contained in:
parent
1b9d4fb325
commit
82bdb5f348
4 changed files with 8 additions and 2 deletions
|
@ -67,5 +67,6 @@ Settings config = {
|
|||
.wmode = VERTICAL,
|
||||
// Padding of the window.
|
||||
.padding = 5,
|
||||
.show_title = 1
|
||||
.show_title = 1,
|
||||
.y_offset = 0
|
||||
};
|
||||
|
|
|
@ -101,8 +101,10 @@ typedef struct _Settings
|
|||
WindowLocation location;
|
||||
WindowMode wmode;
|
||||
unsigned int padding;
|
||||
int y_offset;
|
||||
|
||||
unsigned int show_title;
|
||||
|
||||
} Settings;
|
||||
|
||||
extern Settings config;
|
||||
|
|
|
@ -1227,6 +1227,8 @@ MenuReturn menu ( char **lines, char **input, char *prompt, Time *time, int *shi
|
|||
default:
|
||||
break;
|
||||
}
|
||||
// Apply offset.
|
||||
y+= config.y_offset;
|
||||
|
||||
|
||||
XMoveResizeWindow ( display, box, x, y, w, h );
|
||||
|
|
|
@ -63,7 +63,8 @@ XrmOption xrmOptions[] = {
|
|||
{ xrm_Number, "padding", { .num = &config.padding } },
|
||||
{ xrm_Number, "borderwidth", { .num = &config.menu_bw } },
|
||||
{ xrm_String, "terminal", { .str = &config.terminal_emulator } },
|
||||
{ xrm_Number, "location", { .num = &config.location} },
|
||||
{ xrm_Number, "location", { .num = &config.location } },
|
||||
{ xrm_Number, "yoffset", { .num = &config.y_offset } },
|
||||
};
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue