mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-04 04:06:06 -05:00
term: start slave before loading fonts and starting rendering threads
This allows the client to load in parallel with our font loading, which should improve startup time.
This commit is contained in:
parent
242bcb9550
commit
ae5af7bb06
1 changed files with 9 additions and 8 deletions
17
terminal.c
17
terminal.c
|
|
@ -850,6 +850,14 @@ term_init(const struct config *conf, struct fdm *fdm, struct wayland *wayl,
|
|||
.cwd = strdup(cwd),
|
||||
};
|
||||
|
||||
/* Start the slave/client */
|
||||
if ((term->slave = slave_spawn(
|
||||
term->ptmx, argc, term->cwd, argv,
|
||||
conf->term, conf->shell, conf->login_shell)) == -1)
|
||||
{
|
||||
goto err;
|
||||
}
|
||||
|
||||
/* Guess scale; we're not mapped yet, so we don't know on which
|
||||
* output we'll be. Pick highest scale we find for now */
|
||||
tll_foreach(term->wl->monitors, it) {
|
||||
|
|
@ -858,6 +866,7 @@ term_init(const struct config *conf, struct fdm *fdm, struct wayland *wayl,
|
|||
}
|
||||
|
||||
initialize_color_cube(term);
|
||||
|
||||
/* Initialize the Wayland window backend */
|
||||
if ((term->window = wayl_win_init(term)) == NULL)
|
||||
goto err;
|
||||
|
|
@ -886,14 +895,6 @@ term_init(const struct config *conf, struct fdm *fdm, struct wayland *wayl,
|
|||
break;
|
||||
}
|
||||
|
||||
/* Start the slave/client */
|
||||
if ((term->slave = slave_spawn(
|
||||
term->ptmx, argc, term->cwd, argv,
|
||||
conf->term, conf->shell, conf->login_shell)) == -1)
|
||||
{
|
||||
goto err;
|
||||
}
|
||||
|
||||
if (!initialize_render_workers(term))
|
||||
goto err;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue