From 0c26660f27b3f99f2540e55d0b3c42e7d744d011 Mon Sep 17 00:00:00 2001 From: JeremyStarTM Date: Thu, 5 Dec 2024 15:27:23 +0100 Subject: [PATCH] Fix AnsiShortcodeParser parsing --- .../de/staropensource/engine/ansi/AnsiShortcodeParser.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ansi/src/main/java/de/staropensource/engine/ansi/AnsiShortcodeParser.java b/ansi/src/main/java/de/staropensource/engine/ansi/AnsiShortcodeParser.java index bd993e6..233cf25 100644 --- a/ansi/src/main/java/de/staropensource/engine/ansi/AnsiShortcodeParser.java +++ b/ansi/src/main/java/de/staropensource/engine/ansi/AnsiShortcodeParser.java @@ -63,12 +63,12 @@ public final class AnsiShortcodeParser extends ShortcodeParser { status.clear(); } else if (component.startsWith("TEXT:")) ansi.a(component.substring(5)); - else if (component.startsWith("COLOR:")) + else if (component.startsWith("COLOR:")) { if (component.startsWith("COLOR:FOREGROUND:")) ansi.fg(Ansi.Color.valueOf(component.substring(17))); else if (component.startsWith("COLOR:BACKGROUND:")) ansi.bg(Ansi.Color.valueOf(component.substring(17))); - else if (component.startsWith("ATTRIBUTE:")) + } else if (component.startsWith("ATTRIBUTE:")) if (component.startsWith("ATTRIBUTE:BLINK")) { if (status.contains("ATTRIBUTE:BLINK")) continue;