Show current filename on title bar
Moderators: white, Hacker, petermad, Stefan2
Show current filename on title bar
Hi, i'm using an autohotkey script to show current filename on title bar using
PostMessage 1075, 2017, , , ahk_class TTOTAL_CMD = cm_CopyNamesToClip
this works perfectly when no files are selected, but when multiple files are
selected fails. Is it possibe to show current filename without path on title bar
when multiple files are selected ? Thanks
Edited
Last edited by Galizza on 2022-05-14, 10:45 UTC, edited 5 times in total.
Re: Show current filename on title bar
- "current filename on title bar"
- copy to clipboard only current filename without path
different things?
See text file "TOTALCMD.inc":
cm_CopyNamesToClip=2017;Copy one or many filenames to clipboard
cm_CopyFullNamesToClip=2018;Copy one or many filenames to clipboard with full path
- copy to clipboard only current filename without path
different things?
See text file "TOTALCMD.inc":
cm_CopyNamesToClip=2017;Copy one or many filenames to clipboard
cm_CopyFullNamesToClip=2018;Copy one or many filenames to clipboard with full path
Re: Show current filename on title bar
I prefer to only show the current folder in the Title bar.
I makes no sense to update the title for every change of the cursor in the file list.
I makes no sense to update the title for every change of the cursor in the file list.
Code: Select all
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
#Persistent
SetTimer timerRoutine, 250
Return
#IfWinActive ; turns off ifWinActive
timerRoutine:
if WinActive( "ahk_class TTOTAL_CMD" )
{
SendMessage, 1074, 17
WinGetText, PathInTC, ahk_id %ErrorLevel%
StringTrimRight, PathInTC, PathInTC, 3
pathToDisplay = %PathInTC%
WinGetTitle currentTitle
if ( currentTitle != pathToDisplay )
WinSetTitle %pathToDisplay%
}
Return
Windows 11 Home x64 Version 23H2 (OS Build 22631.3527)
TC 11.03 x64 / x86
Everything 1.5.0.1373a (x64), Everything Toolbar 1.3.3, Listary Pro 6.3.0.77
QAP 11.6.3.3 x64
TC 11.03 x64 / x86
Everything 1.5.0.1373a (x64), Everything Toolbar 1.3.3, Listary Pro 6.3.0.77
QAP 11.6.3.3 x64
Re: Show current filename on title bar
2Horst.Epp & Stefan2 thanks
I was able to solve it using %N & Autohotkey
I was able to solve it using %N & Autohotkey