if (attribute.equals("0")) {
return ProcessOutputTypes.STDOUT;
}
+ boolean inverse = false;
TextAttributes attrs = new TextAttributes();
final String[] strings = attribute.split(";");
for (String string : strings) {
else if (value == 4) {
attrs.setEffectType(EffectType.LINE_UNDERSCORE);
}
+ else if (value == 7) {
+ inverse = true;
+ }
else if (value == 22) {
attrs.setFontType(Font.PLAIN);
}
}
attrs.setEffectColor(foregroundColor);
}
+ if (inverse) {
+ Color foregroundColor = attrs.getForegroundColor();
+ if (foregroundColor == null) {
+ foregroundColor = getDefaultForegroundColor();
+ }
+ Color backgroundColor = attrs.getBackgroundColor();
+ if (backgroundColor == null) {
+ backgroundColor = getDefaultBackgroundColor();
+ }
+ attrs.setForegroundColor(backgroundColor);
+ attrs.setEffectColor(backgroundColor);
+ attrs.setBackgroundColor(foregroundColor);
+ }
Key newKey = new Key(completeAttribute);
ConsoleViewContentType contentType = new ConsoleViewContentType(completeAttribute, attrs);
ConsoleViewContentType.registerNewConsoleViewType(newKey, contentType);