1
1
mirror of https://github.com/wez/wezterm.git synced 2024-11-23 23:21:08 +03:00

Uncomment title font

This commit is contained in:
David Rios 2022-03-25 22:28:43 +01:00 committed by Wez Furlong
parent c55d44aa72
commit eaaf98ad2f
2 changed files with 10 additions and 15 deletions

View File

@ -1,5 +1,3 @@
use winapi::um::winuser::WM_USER;
pub const TMT_CAPTIONFONT: i32 = 801;
pub const HP_HEADERITEM: i32 = 1;
pub const HIS_NORMAL: i32 = 1;

View File

@ -753,19 +753,16 @@ impl WindowOps for Window {
let has_focus = unsafe { GetFocus() } == hwnd;
let is_full_screen = window_state.contains(WindowState::FULL_SCREEN);
// let title_font = unsafe {
// let hdc = GetDC(hwnd);
// if hdc.is_null() {
// return Err(anyhow::anyhow!("Could not get device context"));
// }
// let result = match get_title_log_font(hwnd, hdc) {
// Some(lf) => Some(wezterm_font::locator::gdi::parse_log_font(&lf, hdc)?),
// None => None,
// };
// ReleaseDC(hwnd, hdc);
// result
// };
let title_font = None;
let title_font = unsafe {
let hdc = GetDC(hwnd);
anyhow::ensure!(!hdc.is_null(), "Could not get device context");
let result = match get_title_log_font(hwnd, hdc) {
Some(lf) => wezterm_font::locator::gdi::parse_log_font(&lf, hdc).ok(),
None => None,
};
ReleaseDC(hwnd, hdc);
result
};
let hkcu = RegKey::predef(HKEY_CURRENT_USER);
let use_accent = hkcu