mirror of
https://github.com/wez/wezterm.git
synced 2024-09-21 03:39:16 +03:00
Use dpi from configuration while resizing
This commit is contained in:
parent
15cd1afbdc
commit
962c10330f
@ -1,6 +1,6 @@
|
||||
use crate::utilsprites::RenderMetrics;
|
||||
use ::window::{Dimensions, Window, WindowOps, WindowState};
|
||||
use config::{ConfigHandle, DimensionContext};
|
||||
use config::{configuration, ConfigHandle, DimensionContext};
|
||||
use mux::Mux;
|
||||
use std::rc::Rc;
|
||||
use wezterm_font::FontConfiguration;
|
||||
@ -15,11 +15,15 @@ pub struct RowsAndCols {
|
||||
impl super::TermWindow {
|
||||
pub fn resize(
|
||||
&mut self,
|
||||
dimensions: Dimensions,
|
||||
mut dimensions: Dimensions,
|
||||
window_state: WindowState,
|
||||
window: &Window,
|
||||
live_resizing: bool,
|
||||
) {
|
||||
// ignore dpi changes if there is a fixed dpi set in configuration
|
||||
if let Some(dpi) = configuration().dpi {
|
||||
dimensions.dpi = dpi as usize;
|
||||
}
|
||||
log::trace!(
|
||||
"resize event, live={} current cells: {:?}, current dims: {:?}, new dims: {:?} window_state:{:?}",
|
||||
live_resizing,
|
||||
|
Loading…
Reference in New Issue
Block a user