Profile Picture

simple rotate of a boundlabel does not work

Posted By Hans Henrik Friis Pedersen... 5 Years Ago
Author
Message
Hans Henrik Friis Pedersen...
Question Posted 5 Years Ago
View Quick Profile
Forum Newbie

Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)

Group: Forum Members
Last Active: 4 Years Ago
Posts: 28, Visits: 136
Hi,I would like to make a simple rotation of a boundslabel but it does not work - any ideas what I'm doing wrong??
I have tried to use .Rotat and a orientation but noting works??



NShape shape = new NRectangleShape(10, 10, 20, 20);
shape.Style.FillStyle = new NColorFillStyle(Color.FromArgb(50, 0xcc, 0, 0));

shape.Labels.RemoveAllChildren();

NBoundsLabel boundsLabel = new NBoundsLabel("Label 1, Wrapped", shape.UniqueId, new Nevron.Diagram.NMargins(0, 0, 0, 50));
shape.Labels.AddChild(boundsLabel);
shape.Labels.DefaultLabelUniqueId = boundsLabel.UniqueId;

           
NTextStyle TextStyle2 = new NTextStyle(new NFontStyle("Verdana", 2.0f, FontStyle.Regular), Color.Red);
TextStyle2.StringFormatStyle = new NStringFormatStyle(StringFormatType.GenericTypographic, HorzAlign.Center, VertAlign.Bottom);
TextStyle2.Orientation = 90.0f;
NStyle.SetTextStyle(boundsLabel, TextStyle2);
nDrawingDocument1.ActiveLayer.AddChild(shape);
boundsLabel.Shape.Rotate(CoordinateSystem.Parent, 90f, shape.Location );
NStyle.SetTextStyle(boundsLabel, TextStyle2);








Similar Topics


Reading This Topic