Selection

org.appliedtopology.tda4j.plot.Selection
See theSelection companion object
final case class Selection(name: String, labels: Vector[String] = ..., hover: Boolean = ..., click: Boolean = ..., listed: Boolean = ..., title: String = ...)

A set of things the viewer picks by pointing at them: the classes of a barcode, the points of a cloud. Items of a Panel name a key (a whole number, the index of the thing they stand for) and choose it with Behavior.Selects; other items appear while a key is chosen with Behavior.Selected, so that pointing at a bar of the barcode lights up its point in the diagram and its cycle on the input. A selection is to the viewer's pointer what a Control is to a slider: a named input that behaviors listen to.

Pointing at an item chooses its key for as long as the pointer stays (hover); a click pins it until it is clicked again (a shift-click adds to the pinned keys, a click on the background of a panel lets them all go); a Panel.Flat.brushable panel chooses by dragging a rectangle.

Value parameters

click

whether clicking an item pins it

hover

whether pointing at an item chooses it

labels

what to write for each key, labels(key), in the list under the panels and in the heading of a still picture

listed

whether the page lists the labels of the chosen keys under the panels

name

what behaviors call it (a letter, then letters, digits, _ or -)

title

what the page writes beside that list, and in the heading of a still picture; the name when empty

Attributes

Companion
object
Experimental
true
Source
Selection.scala
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

This selection chosen only by clicking: pointing at an item does nothing.

This selection chosen only by clicking: pointing at an item does nothing.

Attributes

Source
Selection.scala

This selection chosen only by pointing at an item: clicking does nothing.

This selection chosen only by pointing at an item: clicking does nothing.

Attributes

Source
Selection.scala
def labelOf(key: Int): String

What to write for key: its label, or the number when there is none.

What to write for key: its label, or the number when there is none.

Attributes

Source
Selection.scala
def shownName: String

What the page writes beside the list of the chosen keys.

What the page writes beside the list of the chosen keys.

Attributes

Source
Selection.scala
def withLabels(texts: Seq[String]): Selection

This selection with texts as the labels of keys 0, 1, 2, ...

This selection with texts as the labels of keys 0, 1, 2, ...

Attributes

Source
Selection.scala

This selection listed under the panels.

This selection listed under the panels.

Attributes

Source
Selection.scala
def withTitle(text: String): Selection

This selection written text beside its list.

This selection written text beside its list.

Attributes

Source
Selection.scala

Inherited methods

def productElementNames: Iterator[String]

An iterator over the names of all the elements of this product.

An iterator over the names of all the elements of this product.

Attributes

Inherited from:
Product
Source
Product.scala
def productIterator: Iterator[Any]

An iterator over all the elements of this product.

An iterator over all the elements of this product.

Attributes

Returns

in the default implementation, an Iterator[Any]

Inherited from:
Product
Source
Product.scala