MVC Grid stop text from wrapping

2 posts, 0 answers
  1. Patrick
    Patrick avatar
    11 posts
    Member since:
    Dec 2014

    Posted 21 Nov Link to this post

    How to force the grid item into a single line stop text from wrapping ?

    + ---------------------------------------------------------+
    |  column 1 | column 2 |  column 3
    + ---------------------------------------------------------+

    |  data 1     | data 2 .... |  data 3
    + ---------------------------------------------------------+

    instead of:

    + -------------------------------------------+
    | column 1 |column n | column 3
    + -------------------------------------------+

    |  data 1     | data 2  t|  data 3

    |                 | testing  | 
    + ---------------------------------------------------------+

    Please see the screenshot
  2. Stefan
    Admin
    Stefan avatar
    1394 posts

    Posted 23 Nov Link to this post

    Hello, Patrick,

    This could be achieved with the following CSS:

    .k-grid tbody tr{
        height: 50px;// need only if the row height was to be fixed
    }
      
    .k-grid td{
        white-space: nowrap;
    }

    https://dojo.telerik.com/ejaHO

    I hope this is helpful.

    Regards,
    Stefan
    Progress Telerik
    Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top