【问题标题】:How to add custom text next to the title of the window's preview tab? — Windows 10如何在窗口的预览选项卡标题旁边添加自定义文本? — 视窗 10
【发布时间】:2017-12-02 19:53:25
【问题描述】:

我正在寻找在此处添加自定义文本:



这可能有助于我在每个窗口上添加快速简短描述。我也在寻找添加颜色标签,但是,现在具体来说,我怎么能在这里添加文本?

什么 API 或命令允许我在窗口预览标签的标题旁边添加自定义文本 - Windows 10

我将使用AutoHotkey 编写主脚本来实现这一点。

【问题讨论】:

  • 使用 Windows API,您可以调用 FindWindow("TaskListOverlayWnd",NULL) 来获取缩略图窗口的句柄。您可以在其上放置一个分层窗口以显示您的自定义文本。窗口或 WinEvent 挂钩可用于跟踪缩略图窗口可见性的变化。虽然不知道如何使用 AutoHotkey 来做到这一点。

标签: windows tabs autohotkey taskbar


【解决方案1】:

试试这个简单的解决方案:

#Persistent

title1 = Sf
title2 = QkRfit

title1a = Sf || my description for Sf
title2a = QkRfit || my description for QkRfit

SetTimer ChangeTitle, 50
return

ChangeTitle:
SetTitleMatchMode, 3
If (WinExist("ahk_class TaskListThumbnailWnd") || MouseIsOver("ahk_class TaskListThumbnailWnd"))
{
    WinSetTitle, %title1% ahk_class CabinetWClass,, %title1a%
    WinSetTitle, %title2% ahk_class CabinetWClass,, %title2a%
}
else
{
    WinSetTitle, %title1a% ahk_class CabinetWClass,, %title1%
    WinSetTitle, %title2a% ahk_class CabinetWClass,, %title2%
}
return

MouseIsOver(WinTitle) {
 MouseGetPos,,, Window
 return WinExist(WinTitle . " ahk_id " . Window)
}

【讨论】:

    猜你喜欢
    • 2013-01-19
    • 2020-06-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多