4.2.1 Selectors

Each observer (Section 4.2.2) and event handler (Section 4.2.3) needs to define a selector. A selector matches a set of graphical elements in the visualization (e.g. images or shapes). A selector follows the syntax provided by jQuery.1 For instance, to match the graphical element with the ID “elem1” (each element should have a unique ID in the visualization) the user can define the selector “#elem1”. The prefix “#” is used for matching a graphical element by its ID in jQuery.

Footnotes

  1. Fore more information about jQuery and selectors we refer the reader to the jQuery API documentation: http://api.jquery.com/category/selectors/.