UI: SCADA symbol -> improve element text icon positioning.

This commit is contained in:
Igor Kulikov 2024-09-24 12:05:22 +03:00
parent 1c6e245d17
commit a2e3e8df7a

View File

@ -980,11 +980,14 @@ export class ScadaSymbolObject {
fontSetClasses.forEach(className => textElement.addClass(className));
textElement.font({size: `${size}px`});
textElement.attr({
'text-anchor': 'start',
'dominant-baseline': 'hanging',
style: `font-size: ${size}px`
});
textElement.fill(color);
const tspan = textElement.first();
tspan.attr({
'text-anchor': 'start',
'dominant-baseline': 'hanging'
});
return of(textElement);
}
}