Added accepted_ans arg to improve answer handling

This commit is contained in:
Waldir Leoncio 2020-05-20 11:34:26 +02:00
parent 3f8121f5a6
commit ce7fdeb003
2 changed files with 19 additions and 4 deletions

View file

@ -4,7 +4,13 @@
\alias{questdlg}
\title{Prompt for multiple-choice}
\usage{
questdlg(quest, dlgtitle, btn = c("y", "n"), defbtn = "n")
questdlg(
quest,
dlgtitle,
btn = c("y", "n"),
defbtn = "n",
accepted_ans = c("y", "yes", "n", "no")
)
}
\arguments{
\item{quest}{Question}
@ -14,6 +20,8 @@ questdlg(quest, dlgtitle, btn = c("y", "n"), defbtn = "n")
\item{btn}{Vector of alternatives}
\item{defbtn}{Scalar with the name of the default option}
\item{accepted_ans}{Vector containing accepted answers}
}
\description{
This function aims to loosely mimic the behavior of the