namespace Spectre.Console.Cli.Help; /// /// Styles for the HelpProvider to use when rendering help text. /// public sealed class HelpProviderStyle { /// /// Gets or sets the style for describing the purpose or details of a command. /// public DescriptionStyle? Description { get; set; } /// /// Gets or sets the style for specifying the usage format of a command. /// public UsageStyle? Usage { get; set; } /// /// Gets or sets the style for providing examples of command usage. /// public ExampleStyle? Examples { get; set; } /// /// Gets or sets the style for specifying arguments in a command. /// public ArgumentStyle? Arguments { get; set; } /// /// Gets or sets the style for specifying options or flags in a command. /// public OptionStyle? Options { get; set; } /// /// Gets or sets the style for specifying subcommands or nested commands. /// public CommandStyle? Commands { get; set; } /// /// Gets the default HelpProvider styles. /// public static HelpProviderStyle Default { get; } = new HelpProviderStyle() { Description = new DescriptionStyle() { Header = "yellow", }, Usage = new UsageStyle() { Header = "yellow", CurrentCommand = "underline", Command = "aqua", Options = "grey", RequiredArgument = "aqua", OptionalArgument = "silver", }, Examples = new ExampleStyle() { Header = "yellow", Arguments = "grey", }, Arguments = new ArgumentStyle() { Header = "yellow", RequiredArgument = "silver", OptionalArgument = "silver", }, Commands = new CommandStyle() { Header = "yellow", ChildCommand = "silver", RequiredArgument = "silver", }, Options = new OptionStyle() { Header = "yellow", DefaultValueHeader = "lime", DefaultValue = "bold", RequiredOption = "silver", OptionalOption = "grey", }, }; } /// /// Defines styles for describing the purpose or details of a command. /// public sealed class DescriptionStyle { /// /// Gets or sets the style for the header in the description. /// public Style? Header { get; set; } } /// /// Defines styles for specifying the usage format of a command. /// public sealed class UsageStyle { /// /// Gets or sets the style for the header in the usage. /// public Style? Header { get; set; } /// /// Gets or sets the style for the current command in the usage. /// public Style? CurrentCommand { get; set; } /// /// Gets or sets the style for general commands in the usage. /// public Style? Command { get; set; } /// /// Gets or sets the style for options in the usage. /// public Style? Options { get; set; } /// /// Gets or sets the style for required arguments in the usage. /// public Style? RequiredArgument { get; set; } /// /// Gets or sets the style for optional arguments in the usage. /// public Style? OptionalArgument { get; set; } } /// /// Defines styles for providing examples of command usage. /// public sealed class ExampleStyle { /// /// Gets or sets the style for the header in the examples. /// public Style? Header { get; set; } /// /// Gets or sets the style for arguments in the examples. /// public Style? Arguments { get; set; } } /// /// Defines styles for specifying arguments in a command. /// public sealed class ArgumentStyle { /// /// Gets or sets the style for the header in the arguments. /// public Style? Header { get; set; } /// /// Gets or sets the style for required arguments. /// public Style? RequiredArgument { get; set; } /// /// Gets or sets the style for optional arguments. /// public Style? OptionalArgument { get; set; } } /// /// Defines styles for specifying subcommands or nested commands. /// public sealed class CommandStyle { /// /// Gets or sets the style for the header in the command section. /// public Style? Header { get; set; } /// /// Gets or sets the style for child commands in the command section. /// public Style? ChildCommand { get; set; } /// /// Gets or sets the style for required arguments in the command section. /// public Style? RequiredArgument { get; set; } } /// /// Defines styles for specifying options or flags in a command. /// public sealed class OptionStyle { /// /// Gets or sets the style for the header in the options. /// public Style? Header { get; set; } /// /// Gets or sets the style for the header of default values in the options. /// public Style? DefaultValueHeader { get; set; } /// /// Gets or sets the style for default values in the options. /// public Style? DefaultValue { get; set; } /// /// Gets or sets the style for required options. /// public Style? RequiredOption { get; set; } /// /// Gets or sets the style for optional options. /// public Style? OptionalOption { get; set; } }