diff --git a/src/buffer/out/TextAttribute.cpp b/src/buffer/out/TextAttribute.cpp index ad7ee0546e7..06c94184432 100644 --- a/src/buffer/out/TextAttribute.cpp +++ b/src/buffer/out/TextAttribute.cpp @@ -249,6 +249,11 @@ bool TextAttribute::IsUnderlined() const noexcept return WI_IsFlagSet(_extendedAttrs, ExtendedAttributes::Underlined); } +bool TextAttribute::IsDoublyUnderlined() const noexcept +{ + return WI_IsFlagSet(_extendedAttrs, ExtendedAttributes::DoublyUnderlined); +} + bool TextAttribute::IsOverlined() const noexcept { return WI_IsFlagSet(_wAttrLegacy, COMMON_LVB_GRID_HORIZONTAL); @@ -294,6 +299,11 @@ void TextAttribute::SetUnderlined(bool isUnderlined) noexcept WI_UpdateFlag(_extendedAttrs, ExtendedAttributes::Underlined, isUnderlined); } +void TextAttribute::SetDoublyUnderlined(bool isDoublyUnderlined) noexcept +{ + WI_UpdateFlag(_extendedAttrs, ExtendedAttributes::DoublyUnderlined, isDoublyUnderlined); +} + void TextAttribute::SetOverlined(bool isOverlined) noexcept { WI_UpdateFlag(_wAttrLegacy, COMMON_LVB_GRID_HORIZONTAL, isOverlined); diff --git a/src/buffer/out/TextAttribute.hpp b/src/buffer/out/TextAttribute.hpp index 7cec03f75e6..22c61a6aa91 100644 --- a/src/buffer/out/TextAttribute.hpp +++ b/src/buffer/out/TextAttribute.hpp @@ -95,6 +95,7 @@ class TextAttribute final bool IsInvisible() const noexcept; bool IsCrossedOut() const noexcept; bool IsUnderlined() const noexcept; + bool IsDoublyUnderlined() const noexcept; bool IsOverlined() const noexcept; bool IsReverseVideo() const noexcept; @@ -105,6 +106,7 @@ class TextAttribute final void SetInvisible(bool isInvisible) noexcept; void SetCrossedOut(bool isCrossedOut) noexcept; void SetUnderlined(bool isUnderlined) noexcept; + void SetDoublyUnderlined(bool isDoublyUnderlined) noexcept; void SetOverlined(bool isOverlined) noexcept; void SetReverseVideo(bool isReversed) noexcept; diff --git a/src/cascadia/TerminalCore/TerminalDispatchGraphics.cpp b/src/cascadia/TerminalCore/TerminalDispatchGraphics.cpp index f8ff0d129da..635d9bded26 100644 --- a/src/cascadia/TerminalCore/TerminalDispatchGraphics.cpp +++ b/src/cascadia/TerminalCore/TerminalDispatchGraphics.cpp @@ -158,8 +158,12 @@ bool TerminalDispatch::SetGraphicsRendition(const gsl::span_expectedAttribute = TextAttribute{ 0 }; _testGetSet->_expectedAttribute.SetUnderlined(true); break; + case DispatchTypes::GraphicsOptions::DoublyUnderlined: + Log::Comment(L"Testing graphics 'Doubly Underlined'"); + _testGetSet->_attribute = TextAttribute{ 0 }; + _testGetSet->_expectedAttribute = TextAttribute{ 0 }; + _testGetSet->_expectedAttribute.SetDoublyUnderlined(true); + break; case DispatchTypes::GraphicsOptions::Overline: Log::Comment(L"Testing graphics 'Overline'"); _testGetSet->_attribute = TextAttribute{ 0 }; @@ -1334,6 +1340,7 @@ class AdapterTest Log::Comment(L"Testing graphics 'No Underline'"); _testGetSet->_attribute = TextAttribute{ 0 }; _testGetSet->_attribute.SetUnderlined(true); + _testGetSet->_attribute.SetDoublyUnderlined(true); _testGetSet->_expectedAttribute = TextAttribute{ 0 }; break; case DispatchTypes::GraphicsOptions::NoOverline: