Hi.
I have a feature request:
Support ANSI escape sequences in Viewer. At least the color codes would be nice to have.
Why:
I use the file viewer to view linux logs. Sometimes, logs are just terminal ouput redirected to a file and many programs, especially gcc & clang, use color codes in output. This makes the file difficult to read with a simple text viewer. Selecting and copying text from the file to paste in a web page (bug report) is also difficult.
Thank you.
[feature request] ANSI escape sequences in Viewer
Moderators: Hacker, petermad, Stefan2, white
[feature request] ANSI escape sequences in Viewer
Last edited by M95D on 2025-03-06, 16:33 UTC, edited 1 time in total.
Re: [feature request] ANSI escape sequences in Viewer
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Re: [feature request] ANSI escape sequences in Viewer
No. That plugin generates an image from text. It does have colors, etc., but the width is fixed at 80 characters and longer lines are truncated. Also, being just an image, text can't be selected for copy/paste. And it only works if the extension is ".ans". I see no way to "call" the plugin while viewing an ordinary text file (.txt or .log).
Re: [feature request] ANSI escape sequences in Viewer
2M95D
Not what you asked, but are you aware that recent Windows 10 versions and later have native support for ANSI/VT100 escape sequences directly in the Windows Console Host (conhost.exe), which powers cmd.exe? So perhaps a button like this is useful to you:
Be aware of history buffer though (nowadays defaults to 9001 lines and has a max value of 32767).
(I used parameter /k so you can also drag a file onto the button)
Not what you asked, but are you aware that recent Windows 10 versions and later have native support for ANSI/VT100 escape sequences directly in the Windows Console Host (conhost.exe), which powers cmd.exe? So perhaps a button like this is useful to you:
Code: Select all
TOTALCMD#BAR#DATA
wt.exe --title "Show File" -p "Command Prompt" "%comspec%" /k type
%P%N & echo. & pause & exit
%comspec%
Show File in Command Prompt | |(use Ctrl+Shift+F to find, Ctrl+Shift+Home/End/PgUp/PgDn/Up/Down to navigate)
-1
(I used parameter /k so you can also drag a file onto the button)
Re: [feature request] ANSI escape sequences in Viewer
No, I'm not aware. I don't use Win10 for anything other than gaming and even that is very rare.