Add live config reload for font size

This commit is contained in:
wayne 2019-10-02 13:49:19 -05:00 committed by Christian Duerr
parent 3e82aa2830
commit f6f444bc2d
2 changed files with 6 additions and 0 deletions

View File

@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Terminal escape bindings with combined modifiers
- Bindings for ScrollToTop and ScrollToBottom actions
- `ReceiveChar` key binding action to insert the key's text character
- Live reload font size from config
### Changed

View File

@ -938,6 +938,11 @@ impl Term {
self.dynamic_title = config.dynamic_title();
self.auto_scroll = config.scrolling.auto_scroll;
self.grid.update_history(config.scrolling.history() as usize, &self.cursor.template);
if self.original_font_size == self.font_size {
self.font_size = config.font.size;
}
self.original_font_size = config.font.size;
}
#[inline]