class_="taglist"

Provides an input box for multiple strings which are then parsed into tags. (Available as of version 15.04)

Syntax

<dynamic var="">
  <widget class_="taglist" 
  label_="[LABEL TEXT]"
  value_="@var" 
  inputheight_="[NUMBER]" 
  inputwidth_="[NUMBER]"
  complete_="0|1"
  maxcompletions_="[NUMBER]" 
  delimiters_="[TEXT]"/>
</dynamic>

Attributes

complete_
Specifies whether to use autocomplete.

When complete_="1", the widget offers an autocomplete menu for selecting list values. The user will not be able to enter any value that is not on the list.

When complete_="0", there is no autocomplete menu. This is the default value.

delimiters_
When text is pasted into the widget, the text is parsed into tags based on this attribute. You can include more than one delimiter character and the widget will parse in that order.

The default value is "\n\r ". This means that the taglist widget will first attempt to parse on a newline character (\n). If \n does not exist, the widget will then attempt to parse the text using the a carriage return character (\r). Lastly, the widget will parse the text on any whitespace character (newlines, tabs, spaces).

dropdownheight_
Accepts an integer value that specifies the maximum height of the drop-down menu.

If the number of items cannot fit in the specified height, a vertical scroll bar is added to the drop-down menu.

The default value is 200.

(Available as of version 15.26)

dropdownwidth_
Accepts an integer value that specifies the width of the drop-down menu.

If an item cannot fit in the specified width, the text will wrap over multiple lines.

If dropdownwidth_ is not specified, the drop-down menu is the same width as the input field (as specified by the inputwidth_ attribute).

(Available as of version 15.26)

filter_
filter_ is used in conjunction with serverfilter_="1" for server-side filtered completion.

When filter_="contains", the entered text in the widget must contain the same text before the backend can make completion suggestions. If the user enters ap, it will match both 'apple' and 'Cape Cod', because both contain ap.

When filter_="beginswith", the entered text in the widget must begin with the same text before the backend can make completion suggestions. If the user enters ap, it will match 'apple' but not 'Cape Cod'.

inputwidth_
The width of the input area of the taglist widget.
inputheight_
The height of the input area of the taglist widget. If there is not enough room to display the current tags, this area will scroll.
listvalue_
Accepts a dynamic variable that stores the selected items as a list-value. This attribute is interchangeable with value_. Either listvalue_ or value_ is required. The widget always outputs a list value.

(Available after version 15.28)

maxcompletions_
The maximum number of autocomplete options that can be used if complete_="1". The default value is 1000.
rowvalue_
Accepts a dynamic variable that packs all the values for a given row into a package using the column names as the package keys. If a user input value is not matched in the query, that row will be padded with appropriate null values in the table stored in rowvalue_, so that the number of rows in rowvalue_ always match the number of values in value_.

The variable specified to the rowvalue_ attribute must be declared in the opening <dynamic> tag as a package.

rowvalue_ is optional and is used in conjunction with complete_="1" or serverfilter_="1".

(Available as of version 15.27)

serverfilter_
Specifies whether to enable server-side filtered completion in the widget.

When serverfilter_="1", server-side filtered completion is enabled. When the user types at least one character, the widget retrieves completion suggestions, up to the limit specified in maxcompletions_. Unlike complete_="1", server filtering does not constrain input values to the set of completion options. Filtering is always case-insensitive.

Use serverfilter_ with filter_ to control the strategy for finding matches.

When serverfilter_="0", server-side filter completion is disabled. This is the default value.

(Available as of version 15.12)

value_
The dynamic variable name upon which the taglist widget will form a 2-way binding. While this widget can read data from a list value or a comma-separated list, it will always write a list value.

This attribute is interchangeable with listvalue_. Either listvalue_ (Available as of version 15.28) or value_ is required.

Example

The following example shows two taglist widgets. The first, freeform, allows the user to enter any text. The second, completion, is constrained by an autocomplete menu consisting of 2,000 possible values.

<dynamic x="input can,optionally be,a,csl,which is parsed,as a list" y="{lst()}">
  <layout arrange_="h">
    <layout>
      <widget class_="taglist" label_="freeform" 
           value_="@x" inputheight_="100" inputwidth_="150"/>
      <widget class_="value" value_="@x"/>
    </layout>
    <layout>
      <widget class_="taglist" label_="completion" 
           value_="@y" complete_="1" maxcompletions_="2000" delimiters_=",">
        <table depth="2000"/>
        <willbe name="x" value="i_"/>
      </widget>
      <widget class_="value" value_="@y"/>
    </layout>
   </layout>
</dynamic>