Fix: on Windows 8.1, ESC[7m (REVERSE) does not work. #51
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Sorry, I mistaked on #50 . On Windows 8.1, the flag COMMON_LVB_REVERSE_VIDEO is ignored by OS's default terminal.
Please look at the rectangled area. You will find
ESC[7m
does not work on Windows 8.1.The current code on Windows 8.1 (This case has the problem that
ESC[7m
does not work.)Same test on Windows 10, (This case has no problems.)
So, I made the patch again which reverts the change for
ESC[7m
andESC[27m
.But, it does not solute all problems. Please see these two images.
ESC[27m
loses the compatiblity with Windows10's native ANSI-Escape sequence.Patch applied code on Windows8.1
Patch applied code on Windows10.
ESC[27m
loses the compatibility with Windows10's native sequence.The idea exists to make the boolean-variable indicating
ESC[7m
is used or not, but I am afraid that it causes unexpected bugs.I have added the undesired behavior to your code, so I have the duty to make the patch to revert it even if it may be rejected. I will respect your judgement whether the patch is merged or rejected.