Repository: alacritty/alacritty
File: alacritty/src/window_context.rs (Rust)

Code before:
            self.display.pending_update.set_cursor_dirty();
        }

        if old_config.font != config.font {
            // Do not update font size if it has been changed at runtime.
            if self.font_size == old_config.font.size() {
                self.font_size = config.font.size();
            }

            let font = config.font.clone().with_size(self.font_size);
            self.display.pending_update.set_font(font);
        }

        // Update display if padding options were changed.
        let window_config = &old_config.window;
        if window_config.padding(1.) != config.window.padding(1.)
            || window_config.dynamic_padding != config.window.dynamic_padding
        {
            self.display.pending_update.dirty = true;
        }

        // Live title reload only when title wasn't provided on command line.
        //
        // We know that the title was provided on the command line when dynamic_title is disaabled
        // and old_config title isn't equal to the current one.
        if !config.window.dynamic_title && self.identity.title != old_config.window.identity.title {
            self.display.window.set_title(&config.window.identity.title);
        }

        // Set subpixel anti-aliasing.
        #[cfg(target_os = "macos")]
        crossfont::set_font_smoothing(config.font.use_thin_strokes);

        // Disable shadows for transparent windows on macOS.
        #[cfg(target_os = "macos")]
        self.display.window.set_has_shadow(config.window_opacity() >= 1.0);

        // Update hint keys.
        self.display.hint_state.update_alphabet(config.hints.alphabet());

        // Update cursor blinking.
        let event = Event::new(TerminalEvent::CursorBlinkingChange.into(), None);
        self.event_queue.push(event.into());

        self.dirty = true;
    }

    /// Process events for this terminal window.
    pub fn handle_event(
        &mut self,
        event_loop: &EventLoopWindowTarget<Event>,

Review comment (suggestion):
The `||` was in originally to allow changing the title when it was still the same as the original window title. Is this not something we want? I feel like it makes sense but ultimately I don't really care.

Code after:
        if (old_config.terminal_config.cursor.thickness()
            - config.terminal_config.cursor.thickness())
        .abs()
            > f32::EPSILON
        {
            self.display.pending_update.set_cursor_dirty();
        }

        if old_config.font != config.font {
            // Do not update font size if it has been changed at runtime.
            if self.font_size == old_config.font.size() {
                self.font_size = config.font.size();
            }

            let font = config.font.clone().with_size(self.font_size);
            self.display.pending_update.set_font(font);
        }

        // Update display if padding options were changed.
        let window_config = &old_config.window;
        if window_config.padding(1.) != config.window.padding(1.)
            || window_config.dynamic_padding != config.window.dynamic_padding
        {
            self.display.pending_update.dirty = true;
        }

        // Update title on config reload according to the following table.
        //
        // │cli │ dynamic_title │ current_title == old_config ││ set_title │
        // │ Y  │       _       │              _              ││     N     │
        // │ N  │       Y       │              Y              ││     Y     │
        // │ N  │       Y       │              N              ││     N     │
        // │ N  │       N       │              _              ││     Y     │
        if !self.preserve_title
            && (!config.window.dynamic_title
                || self.display.window.title() == old_config.window.identity.title)
        {
            self.display.window.set_title(config.window.identity.title.clone());
        }

        // Set subpixel anti-aliasing.
        #[cfg(target_os = "macos")]
        crossfont::set_font_smoothing(config.font.use_thin_strokes);

        // Disable shadows for transparent windows on macOS.
        #[cfg(target_os = "macos")]
        self.display.window.set_has_shadow(config.window_opacity() >= 1.0);

        // Update hint keys.
        self.display.hint_state.update_alphabet(config.hints.alphabet());