title: How do I automatically select text in a Backgrid cell when it receives focus?
body: <p>I have an app that is using <a href="http://backgridjs.com" rel="nofollow">BackgridJS</a> for a spreadsheet-like editor interface. As the user tabs across a row, each cell (Backgrid.StringCell) becomes editable automatically. However, the cursor is placed at the end of the cell contents requiring the user to backspace their way to the beginning of the string before entering new data into the cell.</p>
  
  <p>I would like cell content to automatically be highlighted when a cell receives focus so that the user can immediately begin entering new data into that cell, or tab to the next cell to leave that data in place.</p>
  
  <p>I have a feeling I should be listening to the enterEditMode event of the StringCell, but I can't figure out where to go from there. I currently have:</p>
  
  <pre><code>var stringCell = Backgrid.StringCell.extend({
      enterEditMode: function() {
          // highlight cell contents here
      }
  });
  </code></pre>