title: How to fix sync issue between column-header-width and column-body-width without the use of deprecated jqGrid updateColumns method?
body: <p>Currently I am working on restoring saved grid preferences/configuration.  This is more or less working beautifully, until we get to the last last step of performing that performs a column remap, $grid.jqGrid("remapColumns", perm, true, true); and what happens is that the reordered column-header-widths are out of sync with thier corresponding column-body-widths.</p>
  
  <p>This remap does correctly display of both the column-header names and column-body data in the new order and based on user preferences.  </p>
  
  <p>However, what is wonky is the following.  There are three columns: (1) Name (width: 200), (2) Id (width: 70), and (3) Alert (width: 60)</p>
  
  <p>As stated the actual reorder of column headers and correspeond column body data is fine.  </p>
  
  <p>So that the original order:</p>
  
  <pre><code>                          Name       |  Id   | Alert
                            x          |  1    | a,c,d
                            y          |  2    | 
                            z          |  3    | c
  </code></pre>
  
  <p>Correctly remaps to new order, but (for purpose of visual example) as shown below the column-header-widths are out of sync with the the column-body-widths</p>
  
  <pre><code>                          Id         |  Name  | Alert
                            1  | x              | a,c,d
                            2  | y              | 
                            3  | z              | c
  </code></pre>
  
  <p>Each column contains the correct data, but now the following is happening with regard to the column widths.</p>
  
  <p>Id column-header now has a column-header-width = 200 (incorrect width), and the 
  Id column-body-width = 70 (correct width) </p>
  
  <p>Name column-header now has a column-header-width = 70 (incorrect width) and the 
  Name column-body-width = 200 (correct width).  </p>
  
  <p>Alert column is unaffected and is correctly sized width for both column-header (width = 60) and column-body (width = 60).</p>
  
  <p>In working to resolve this issue, I believed that the updateColumns method was a good bet for syncing column-header-widths that were out of sync with corresponding column-body-widths. As stated here in the documentation, (<a href="http://www.trirand.com/jqgridwiki/doku.php?id=wiki%3amethods" rel="nofollow">http://www.trirand.com/jqgridwiki/doku.php?id=wiki%3amethods</a>)</p>
  
  <p><strong>updateColumns</strong> - this synchronizes the width of the headers with the data. Useful when used with table drag and drop. This method should be used this way – Example: 
  var mygrid=jQuery("#grid_id")[0];
  mygrid.updateColumns();</p>
  
  <p>However, after unsuccessful attempts to use updateColumns() and then some further digging, it turns out that this method is deprecated/removed from code as of jqGrid 3.8.  We are currently using jqGrid version 4.4/4.5.  </p>
  
  <p>(preferred) How in the world can I fix this issue using the current version of the software both with regard to syncing the column-header-widths and column-body widths?</p>
  
  <p>And/or where can I find jqGrid source code 3.7 so I can take a look at this method and possibly use it? While I have found previous versions of jqGrid, I just haven't been able to find versions &lt;= 3.7.</p>
  
  <p>At this point, there really is a huge need on my end for an efficient solution and clear guidance to nip this in the bud.  Please let me know if any further clarifications or code are necessary.</p>