Group: Forum Members
Last Active: Last Week
Posts: 3,054,
Visits: 4,009
|
Hi, You can use XML formatted texts. Take a look at XML Formatted Texts documentation topic for more information.
Best Regards, Nevron Support Team
|
Group: Forum Members
Last Active: 10 Years Ago
Posts: 1,
Visits: 8
|
Hi, Here's my doubt: How can i split text in nevron shape and assign different fontstyles for different lines of text. For examples: lets us consider below two lines as my shape.Text: USA Land Of Opportunities
I want to make USA as bolded in shape text and rest of the text as normal. Please find below code i am using for customizing text format in nevron shape:Font ftName = new Font("Arial", 10, FontStyle.Bold); Font ftInputs = new Font("Arial", 10); shape.Style.FillStyle = new NSizeF(width, (height/2)); shape.CollapsedSize = new NColorFillStyle(backgroundColor);shape.Name = name; shape.Text = shapeText; shape.Tag = tag; NTextStyle textStyle = new NTextStyle(ftInputs, IOsColor); //Create a NTextStyle object textStyle.StringFormatStyle.HorzAlign = Nevron.HorzAlign.Left; //Horizontal alignment textStyle.StringFormatStyle.VertAlign = Nevron.VertAlign.Top; //Vertical alignment textStyle.Offset =new NPointL(2, 2); //The offset within the object NStyle.SetTextStyle(shape, textStyle); //Set the objects text style
In the above code, textStyle is customizing entire text to font: arial , 10.
I want shape name to be bolded. my text contains shape name and additional text. how to make shape name bolded.
Regards, Suren
|