Package | com.yworks.graph.model |
Interface | public interface ILabelModelParameterFinder |
Implementors | CompositeLabelModel, DefaultLabelModelParameterFinder, DescriptorWrapperLabelModel, FreeEdgeLabelModel, FreeNodeLabelModel, RotatedSideSliderEdgeLabelModel, RotatedSliderEdgeLabelModel, SliderEdgeLabelModel |
ILabelModel
implementations to
find the best ILabelModelParameter
to approximate a given layout.
Implementations of this class may be retrieved from ILabelModel
implementations using their lookup
method.
Note that implementations are not required to return an instance if queried
for this interface.
See also
Method | Defined By | ||
---|---|---|---|
findBestParameter(label:ILabel, model:ILabelModel, labelLayout:IOrientedRectangle):ILabelModelParameter
Tries to find a parameter that best matches the given layout for the
provided label instance. | ILabelModelParameterFinder |
findBestParameter | () | method |
public function findBestParameter(label:ILabel, model:ILabelModel, labelLayout:IOrientedRectangle):ILabelModelParameter
Tries to find a parameter that best matches the given layout for the provided label instance.
This method may not necessarily find a parameter that matches the provided
layout exactly. Implementations may choose to simply return the model's
default parameter
but may never return null
.
Parameters
label:ILabel — The label to find a parameter for.
| |
model:ILabelModel — The model instance to use. This should be the instance
this instance has been obtained from.
| |
labelLayout:IOrientedRectangle — The anticipated layout for the label.
|
ILabelModelParameter — A non-null parameter that can be used for the label to approximate the provided layout.
|
See also