diff options
author | Thomas Adam <thomas@xteddy.org> | 2019-11-28 12:18:41 +0000 |
---|---|---|
committer | Thomas Adam <thomas@xteddy.org> | 2019-11-28 12:18:41 +0000 |
commit | 5f5f029e3b3a782dc616778739b2801b00b17c0e (patch) | |
tree | fad35dccc37c54e45d0ecc497d3b915dd7b835aa /spawn.c | |
parent | c13838436e6883d191374f1628e675bfbb8c8aeb (diff) | |
parent | fa409194d3dfe0095bf6572a253772f2825f5dec (diff) | |
download | rtmux-5f5f029e3b3a782dc616778739b2801b00b17c0e.tar.gz rtmux-5f5f029e3b3a782dc616778739b2801b00b17c0e.tar.bz2 rtmux-5f5f029e3b3a782dc616778739b2801b00b17c0e.zip |
Merge branch 'obsd-master'
Diffstat (limited to 'spawn.c')
-rw-r--r-- | spawn.c | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -83,7 +83,7 @@ spawn_window(struct spawn_context *sc, char **cause) struct window_pane *wp; struct winlink *wl; int idx = sc->idx; - u_int sx, sy; + u_int sx, sy, xpixel, ypixel; spawn_log(__func__, sc); @@ -153,8 +153,9 @@ spawn_window(struct spawn_context *sc, char **cause) xasprintf(cause, "couldn't add window %d", idx); return (NULL); } - default_window_size(sc->c, s, NULL, &sx, &sy, -1); - if ((w = window_create(sx, sy)) == NULL) { + default_window_size(sc->c, s, NULL, &sx, &sy, &xpixel, &ypixel, + -1); + if ((w = window_create(sx, sy, xpixel, ypixel)) == NULL) { winlink_remove(&s->windows, sc->wl); xasprintf(cause, "couldn't create window %d", idx); return (NULL); @@ -336,6 +337,8 @@ spawn_pane(struct spawn_context *sc, char **cause) memset(&ws, 0, sizeof ws); ws.ws_col = screen_size_x(&new_wp->base); ws.ws_row = screen_size_y(&new_wp->base); + ws.ws_xpixel = w->xpixel * ws.ws_col; + ws.ws_ypixel = w->ypixel * ws.ws_row; /* Block signals until fork has completed. */ sigfillset(&set); |