Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support customizable Ansi color scheme #80

Closed
remkop opened this issue Apr 3, 2017 · 2 comments
Closed

Support customizable Ansi color scheme #80

remkop opened this issue Apr 3, 2017 · 2 comments

Comments

@remkop
Copy link
Owner

remkop commented Apr 3, 2017

Something like Help.setStyle(String, EnumSet<Ansi.Style>).

TBD add method on CommandLine?

Where keys are:

  • heading
  • command
  • options
  • option-parameters
  • positional-parameters
@remkop remkop added this to the 0.4.0 user manual milestone Apr 3, 2017
@remkop remkop changed the title Support custom Ansi color scheme Support customizable Ansi color scheme Apr 3, 2017
@remkop
Copy link
Owner Author

remkop commented Apr 3, 2017

Note that this will not work for custom synopsis. This is static text in the annotation attribute, so it cannot call the Help.Ansi methods. To support colors in the custom synopsis we need to do something like the "render" method that Jansi offers: "@|red Hello|@ @|green World|@") .

@remkop
Copy link
Owner Author

remkop commented Apr 4, 2017

CommandLine.usage(Object, PrintStream, Help.StyleScheme);

class StyleScheme {
  EnumSet<Help.Ansi.Style> command;
  ...
}

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

No branches or pull requests

1 participant