mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-04 04:06:06 -05:00
client: add "--window-size-pixels" and "--window-size-chars" options
This commit is contained in:
parent
10eda1faa5
commit
748f98e0c0
3 changed files with 56 additions and 13 deletions
16
server.c
16
server.c
|
|
@ -263,6 +263,22 @@ fdm_client(struct fdm *fdm, int fd, int events, void *data)
|
|||
else if (cdata.fullscreen)
|
||||
client->conf.startup_mode = STARTUP_FULLSCREEN;
|
||||
|
||||
if (cdata.width > 0 && cdata.height > 0) {
|
||||
client->conf.size.type = cdata.size_type;
|
||||
|
||||
switch (cdata.size_type) {
|
||||
case CONF_SIZE_PX:
|
||||
client->conf.size.px.width = cdata.width;
|
||||
client->conf.size.px.height = cdata.height;
|
||||
break;
|
||||
|
||||
case CONF_SIZE_CELLS:
|
||||
client->conf.size.cells.width = cdata.width;
|
||||
client->conf.size.cells.height = cdata.height;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
client->term = term_init(
|
||||
&client->conf, server->fdm, server->reaper, server->wayl,
|
||||
"footclient", cwd, cdata.argc, argv, &term_shutdown_handler, client);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue