use of de.cau.cs.kieler.klighd.kgraph.KLabel in project lingua-franca by lf-lang.
the class LinguaFrancaStyleExtensions method applyOnEdgeStyle.
public void applyOnEdgeStyle(KLabel label) {
if (_onEdgeLabelConfigurator == null) {
LabelDecorationConfigurator configurator = LabelDecorationConfigurator.create().withInlineLabels(true);
_onEdgeLabelConfigurator = configurator.withLabelTextRenderingProvider((KContainerRendering container, KLabel klabel) -> {
KText kText = _kRenderingFactory.createKText();
_kRenderingExtensions.setFontSize(kText, 9);
container.getChildren().add(kText);
return kText;
});
}
_onEdgeLabelConfigurator.applyTo(label);
}
Aggregations