Opened 11 years ago

Closed 11 years ago

#8713 closed defect (invalid)

dojox.grid.DataGrid cannot resize columns when using width="auto"

Reported by: Josh Trutwin Owned by: Bryan Forbes
Priority: high Milestone: tbd
Component: DojoX Grid Version: 1.3.0b1
Keywords: grid resize width="auto" Cc:
Blocked By: Blocking:

Description

I was playing around with DataGrid? (1.3beta1) and noticed that you cannot resize the columns of a data grid if you use width="auto" on all your fields.

Here's the grid I tried:

<table dojoType="dojox.grid.DataGrid?"

class="grid" store="jsonStore" autoHeight="10" query="{ id: '*' }" rowsPerPage="20">

<thead>

<tr>

<th field="id" width="auto">Id</th> <th field="name" width="auto">Event Name</th> <th field="name" width="auto">Start Date</th> <th field="name" width="auto">Start Time</th> <th field="name" width="auto">Event Type</th>

</tr>

</thead>

</table>

If I change the first field to width="50px" then I can resize only that column.

I think this is related to another old grid bug related to percentage widths not allowing you to change the column size.

Josh

Change History (1)

comment:1 Changed 11 years ago by Bryan Forbes

Resolution: invalid
Status: newclosed

This is correct. If a column is set to "auto", that means it takes up all the remaining space so it should not be resizeable.

Note: See TracTickets for help on using tickets.