CKEDITOR.plugins.lineutils.locator
A utility that analyses relations found by CKEDITOR.plugins.lineutils.finder and locates them in the viewport as horizontal lines of specific coordinates.
Filtering
Properties
Methods
-
Creates a Locator class instance.
Parameters
editor : editorEditor instance that Locator belongs to.
Returns
locator
locate( relations ) → ObjectCKEDITOR.plugins.lineutils.locator#locateLocates the Y coordinate for all types of every single relation and stores them in an object.
Parameters
relations : Object
Returns
Object
sort( y, [ howMany ] ) → ArrayCKEDITOR.plugins.lineutils.locator#sortCalculates distances from every location to given vertical coordinate and sorts locations according to that distance.
Parameters
y : NumberThe vertical coordinate used for sorting, used as a reference.
[ howMany ] : NumberDetermines the number of "closest locations" to be returned.
Returns
ArraySorted, array representation of locations.
store( uid, type, y )CKEDITOR.plugins.lineutils.locator#storeStores the location in a collection.
Parameters
uid : NumberUnique identifier of the relation.
type : NumberOne of
CKEDITOR.LINEUTILS_BEFORE,CKEDITOR.LINEUTILS_AFTERandCKEDITOR.LINEUTILS_INSIDE.y : NumberVertical position of the relation.