wezterm/wezterm · error
to resolve pane selection font
Error message
to resolve pane selection font
What it means
PaneSelect::compute resolves the overlay font via fonts.pane_select_font() (Entity::PaneSelect, same font machinery as the command palette) and .expect("to resolve pane selection font")s the anyhow::Result. Any failure in font selection/loading therefore becomes a panic exactly when the Pane Select overlay is computed, rather than a reportable error, even though compute() returns anyhow::Result and could propagate it.
Source
Thrown at wezterm-gui/src/termwindow/paneselect.rs:61
element: RefCell::new(None),
labels: RefCell::new(vec![]),
selection: RefCell::new(String::new()),
alphabet,
mode: args.mode,
was_zoomed,
show_pane_ids: args.show_pane_ids,
}
}
fn compute(
term_window: &mut TermWindow,
alphabet: &str,
show_pane_ids: bool,
) -> anyhow::Result<(Vec<ComputedElement>, Vec<String>)> {
let font = term_window
.fonts
.pane_select_font()
.expect("to resolve pane selection font");
let metrics = RenderMetrics::with_font_metrics(&font.metrics());
let top_bar_height = if term_window.show_tab_bar && !term_window.config.tab_bar_at_bottom {
term_window.tab_bar_pixel_height().unwrap()
} else {
0.
};
let (padding_left, padding_top) = term_window.padding_left_top();
let border = term_window.get_os_border();
let top_pixel_y = top_bar_height + padding_top + border.top.get() as f32;
let panes = term_window.get_panes_to_render();
let labels =
crate::overlay::quickselect::compute_labels_for_alphabet(alphabet, panes.len());
let mut elements = vec![];
for pos in panes {
let caption = if show_pane_ids {View on GitHub (pinned to 3ff7522b96)
Solutions
- Verify the configured font families exist on the system (fc-list :family / Font Book / Windows font settings)
- Remove or simplify custom font_rules and window_frame font overrides and retest the overlay
- Clear wezterm's font cache and restart to re-enumerate installed fonts
- Reinstall or repair the target font, then reopen pane select
Example fix
// before
let font = term_window.fonts.pane_select_font().expect("to resolve pane selection font");
// after
let font = term_window.fonts.pane_select_font().context("pane select font")?; Defensive patterns
Strategy: try-catch
Validate before calling
// Fail loudly at startup, not when the user opens pane select
fn overlay_fonts_ok(fonts: &wezterm_font::Fonts) -> bool {
fonts.pane_select_font().is_ok()
} Try / catch
match term_window.fonts.pane_select_font() {
Ok(font) => RenderMetrics::with_font_metrics(&font.metrics()),
Err(err) => {
log::error!("pane select font unresolved: {err:#}");
anyhow::bail!("cannot compute pane selector without a font")
}
} Prevention
- Pre-warm entity fonts during startup so failures surface in logs immediately
- Keep font_rules satisfiable: test with a minimal config after edits
- Install fonts system-wide when configs are shared across users
- Watch wezterm logs for font-resolution warnings before they become overlay panics
When it happens
Trigger: Entering pane-select mode on a setup where the overlay font cannot be resolved: missing font family, unsatisfiable font_rules, stale font cache entries pointing at deleted files, or a font that fails to parse under FreeType/CoreText/DirectWrite.
Common situations: Custom fonts uninstalled after the config was written; per-user font installs not visible to the session; heavily customized window_frame/fonts blocks; systems where the font enumeration backend errors out.
Related errors
- to resolve char selection font
- thread terminated without providing a result
- expected to have extents for non-svg image data
- metrics_for_idx: there is no font with idx={font_idx}!?
- RateLimiter capacity to be non-zero
AI-assisted analysis of wezterm/wezterm@3ff7522b96 (2026-08-20).
Data as JSON: /api/errors/6c84a903e8042c63.
Report an issue: GitHub.