"SelectColor" (Question Interface Type)
"SelectColor" (Question Interface Type)
"SelectColor"
provides a color picker for one value to be selected.
Properties
- In QuestionInterface["SelectColor",props], props is an Association that supports the following keys:
-
"Prompt" None text asking the user a question
Corresponding AssessmentFunction
- "SelectColor" is the automatically assigned interface type for an AssessmentFunction of the form AssessmentFunction[{RGBColor1 ,…}].
- The values in the assessment function can be True and False or numeric values, in which case positive values are interpreted as correct.
Examples
open all close allBasic Examples (2)
Scope (1)
Create a randomly generated color question:
With[{p = RandomEntity["Pokemon"]}, QuestionObject[QuestionInterface["SelectColor", <|"Prompt" -> Column[{"What color is this pokemon? ", ColorConvert[p["Image"], "Grayscale"]}]|>], AssessmentFunction[DominantColors[p["Image"]], Tolerance -> 0.3]]]See Also
QuestionInterface QuestionObject
Question Interface Types: NumericRange ClickLocations
Comparison Methods: Color