We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to ensure lane header text appears on a single line

Thread ID:





119338 Jun 8,2015 12:00 AM UTC Aug 25,2015 09:09 AM UTC ASP.NET Web Forms 3
Tags: Diagram
Jim Jacobs
Asked On June 8, 2015 12:00 AM UTC


See the attached screenshot for an example of my challenge.
Even though the lane height is more than adequate to allow the text to fit on a single line, the text wraps to a second line.

I would assume that the label within the lane header would grow in width as the lane is resized.
Is this not true?

How would you suggest that I accomplish what I am looking to do - get the text on a single line (with the ability for the text to wrap to a second line should the lane height necessitate it).

Thanks for any guidance.


Attachment: Syncfusion__Lane_Header_Label_Width__07Jun2015_cab52628.zip

Shyam G [Syncfusion]
Replied On June 8, 2015 11:35 AM UTC

Hi Jim

Thanks for using Syncfusion products.

Please note that the default value for the swimlane header width is 30, so that the header text is not wrapped properly. We suggest you to increase the width value for the swimlane header in order to achieve your requirement. Please refer the code snippet below.

Code snippet:

Lane swimLane = new Lane();

 swimLane.Name = "swimlane";

 swimLane.Header.Text = "";

 //set the width for the header
swimLane.Header.Width = 120;

Please let me know if any concerns.

Shyam G

Jim Jacobs
Replied On August 24, 2015 05:44 PM UTC

Hi Shyam,

This does not seem to work.
See the attached screenshot.
The vertical lane seems to be fine; just the horzontal.

Here's a snippet of code from my nodeCollectioChangeHandler:

... } else if (args.changeType == "insert" && args.element && args.element.isLane) {
                var lane = args.element;
                if (lane.orientation == "horizontal") {
                    lane.minHeight = 120;
                    lane.minWidth = 550;
                    lane.header.width = 110; // Ensure a wider label so it doesn't wrap (default = 30)
                    lane.header.height = 40;
                    lane.header.fontSize = 12;
                if (lane.orientation == "vertical") {
                    lane.minHeight = 550;
                    lane.minWidth = 250;
                    lane.header.width = 240; // Ensure a wider label so it doesn't wrap (default = 30)
                    lane.header.height = 40;
                    lane.header.fontSize = 12;
                diagram.updateNode(lane.name, {});
            } else if ...

If a interrogate the lane.header.width in the selectionChangeHandler (when I click on it) - it shows 60 ???

What am I doing wrong?



Attachment: Syncfusion__Lane_Header_Label_Width__24aug2015_1cbe228b.zip

Kameshwaran R [Syncfusion]
Replied On August 25, 2015 09:09 AM UTC

Hi Jim

Thanks for your update.

We have achieved your requirement in the sample and it is available in the below link for download.

Sample: sample

Please let us know if you need further assistance.


Kameshwaran R.


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon