Skip to content
This repository was archived by the owner on Jul 6, 2025. It is now read-only.

Conversation

@chausner
Copy link

@chausner chausner commented Sep 30, 2023

This improves the compatibility of the LoggingFlag::ColoredTerminalOutput setting on Windows.

Windows 10 and later introduced virtual terminal support in conhost and Windows Terminal, see also https://learn.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences. This adds logic to easylogging++ to detect when virtual terminal processing is enabled, to allow colored output if LoggingFlag::ColoredTerminalOutput is set.

Before, easylogging++ would not attempt to output VT colored text even if the user enabled LoggingFlag::ColoredTerminalOutput and the terminal supports it.

With this change, running the all-logs sample in Windows Terminal:

image

This is a

  • Breaking change
  • New feature
  • Bugfix

I have

@robloh
Copy link

robloh commented Feb 27, 2024

Thanks for this patch! Can confirm it works on Windows 10 with VS2019.

@chausner
Copy link
Author

chausner commented Mar 1, 2024

@abumq Any chance of getting this merged? :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants