Skip to contents

A list of choices. See option_list().

Super classes

Widget -> ListBase -> OptionList

Active bindings

value

Value of the highlighted choice (NULL if none).

choices

The choice values.

Methods

Inherited methods


OptionList$new()

Create an option list. See option_list().

Usage

OptionList$new(
  choices,
  id = NULL,
  classes = NULL,
  style = NULL,
  disabled = FALSE
)

Arguments

choices

Choices.

id, classes, style, disabled

See Widget.


OptionList$set_choices()

Replace the choices.

Usage

OptionList$set_choices(choices)

Arguments

choices

Character vector (named: names are shown).


OptionList$item_count()

Number of choices.

Usage

OptionList$item_count()


OptionList$item_text()

Label of choice i.

Usage

OptionList$item_text(i)

Arguments

i

Index.


OptionList$on_highlight()

Sends "option_list.highlighted".

Usage

OptionList$on_highlight(i)

Arguments

i

Index.


OptionList$on_activate()

Sends "option_list.selected".

Usage

OptionList$on_activate(i)

Arguments

i

Index.


OptionList$clone()

The objects of this class are cloneable with this method.

Usage

OptionList$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.