1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/optparse.R
\name{IndentedHelpFormatter}
\alias{IndentedHelpFormatter}
\alias{TitledHelpFormatter}
\title{Builtin help text formatters}
\usage{
IndentedHelpFormatter(object)
TitledHelpFormatter(object)
}
\arguments{
\item{object}{An \code{\link[=OptionParser]{OptionParser()}} object.}
}
\value{
\code{NULL} invisibly. As a side effect prints out help text.
}
\description{
\code{IndentedHelpFormatter()} is the default help text formatter.
\code{TitledHelpFormatter()} is an alternative help text formatter.
}
\examples{
parser <- OptionParser(formatter = IndentedHelpFormatter)
parser <- add_option(parser, "--generator", help = "Generator option")
parser <- add_option(parser, "--count", help = "Count option")
print_help(parser)
parser <- OptionParser(formatter = TitledHelpFormatter)
parser <- add_option(parser, "--generator", help = "Generator option")
parser <- add_option(parser, "--count", help = "Count option")
print_help(parser)
}
|