setSelectedDOMRange(_:affinity:)
Selects a range of nodes.
Declaration
func setSelectedDOMRange(_ range: DOMRange!, affinity selectionAffinity: NSSelectionAffinity)Parameters
- range:
The range of nodes to select. If
rangeisnil, the current selection is cleared. This method raises aDOMRangeExceptonif the range has been detached or refers to nodes not displayed by the receiver. - selectionAffinity:
See the Selectionaffinity property for information on selection affinity.