This is a migrated thread and some comments may be shown as answers.

Ellipsis when string too long

3 Answers 609 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jay
Top achievements
Rank 1
Jay asked on 15 May 2012, 07:01 PM
For strings which are too long for a column, an ellipsis is appearing at the end of the string. When I hover over that text, shouldn't I get some "bubble help" or something which shows the entire string?

3 Answers, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 16 May 2012, 01:07 PM
Hi Jay,

The appearance of ellipsis is a matter of a couple of CSS styles:

.k-grid td
{
    overflow: hidden;
    text-overflow: ellipsis;
}

However, there is no ready-to-use or automatic browser mechanism to display tooltips for content that is clipped with ellipsis. What you can do is:

1. Use a column template that will include a title HTML attribute, for example:

columns: [
    {
      field: "fieldName",
      title: "column title",
      template: "<div title='#= fieldName #'>#= fieldName # </div>"
    }
]

2. Use some custom Javascript-based technique that may or may not also require a column template.

Greetings,
Dimo
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Felickz
Top achievements
Rank 2
answered on 13 Jan 2014, 03:46 PM
Grid integration with the tooltip would be a great addition to the Kendo library!

0
Per
Top achievements
Rank 1
answered on 10 Jun 2015, 12:08 PM

Is does not work unless you also set white-space: nowrap; in the CSS.

 

 

Tags
Grid
Asked by
Jay
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Felickz
Top achievements
Rank 2
Per
Top achievements
Rank 1
Share this question
or