Hello!
I have a label inside of a node. The label is shorter than a node. Still the label is wrapped inside of the node, though visually it should fit.
How to reduce the margins around label inside of the node, so it would not wrap.
Don't suggest to use Label.WrapText =false as this will stop from wrapping long labels too.
See the screenshot for details.
Also some code here:
Thank you
Tagir
var shape = new Syncfusion.Windows.Forms.Diagram.Rectangle(0, 0, _discoverySettings.TaskWidth, _discoverySettings.TaskHeight, MeasureUnits.Millimeter);
shape.FillStyle.Color = System.Drawing.Color.LightGreen;
Syncfusion.Windows.Forms.Diagram.Label lbl = new Syncfusion.Windows.Forms.Diagram.Label();
lbl.Text = name;
lbl.FontStyle.Size = _discoverySettings.TaskFontSize;
//lbl.WrapText = false;
shape.Labels.Add(lbl);
shape.PinPoint = new PointF(x, y);
DiagramPage.Model.AppendChild(shape);
Attachment:
node_label_margin_d2701949.zip