Skip to content

Implement Bright Foreground Colors. #12

Description

@Parakleta

The _COLOR_BRIGHT flag should be separated into _COLOR_FGBRIGHT and _COLOR_BGBRIGHT to allow accessing the upper 8 colors in ANSI mode. Particularly this allows access to bright and bold colors.

The output coding currently as:

result += colorstring[(29 + (_value & _COLOR_FG))];
would then be changed to:

    result += colorstring[((_value & _COLOR_FGBRIGHT ? 89 : 29) + (_value & _COLOR_FG))];

Currently it's possible to trick the existing code into giving bright and bold colors by requesting inverse bright bold <background> on <foreground> but this is really quite ugly.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions