private int adjustColumn(int row,int col){
  if (col < 0) {
    return 0;
  }
  if (row == getRowCount() - 1) {
    int lastRowCount=model.getByteCount() % 16;
    if (lastRowCount == 0) {
      lastRowCount=16;
    }
    if (lastRowCount < 16) {
      return Math.min(col,(model.getByteCount() % 16) - 1);
    }
  }
  return Math.min(col,getColumnCount() - 1 - 1);
}

private int adjustColumn ( int row , int col ) { if ( col < 0 ) { return 0 ; } if ( row == getRowCount ( ) - 1 ) { int lastRowCount = model . getByteCount ( ) % 16 ; if ( lastRowCount == 0 ) { lastRowCount = 16 ; } if ( lastRowCount < 16 ) { return Math . min ( col , ( model . getByteCount ( ) % 16 ) - 1 ) ; } } return Math . min ( col , getColumnCount ( ) - 1 - 1 ) ; }
returns the column for the cell containing data that is the closest to the specified cell . this is used when , for example , the user clicks on an " empty " cell in the last row of the table .
