From ed0fadcd82cbc666809c0e9a69348c32ac421993 Mon Sep 17 00:00:00 2001 From: ShlomoCode <78599753+ShlomoCode@users.noreply.github.com> Date: Mon, 1 Jul 2024 18:35:04 +0300 Subject: [PATCH] Feat: Hide the window title in the preview window if it's the same as the app name --- DockDoor/Views/HoverWindow.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DockDoor/Views/HoverWindow.swift b/DockDoor/Views/HoverWindow.swift index 134dd78f..7eaed13a 100644 --- a/DockDoor/Views/HoverWindow.swift +++ b/DockDoor/Views/HoverWindow.swift @@ -543,7 +543,7 @@ struct WindowPreview: View { Spacer() - if let windowTitle = windowInfo.window?.title, !windowTitle.isEmpty { + if let windowTitle = windowInfo.window?.title, !windowTitle.isEmpty, windowTitle != windowInfo.appName { let maxLabelWidth = calculatedSize.width - 150 let stringMeasurementWidth = measureString(windowTitle, fontSize: 12).width + 5 let width = maxLabelWidth > stringMeasurementWidth ? stringMeasurementWidth : maxLabelWidth