code: private static TableColumnModelListener createTableColumnModelListener(final JTable table) {
          return new TableColumnModelListener() {
              public void columnAdded(TableColumnModelEvent e) {
                  if (table.getParent() instanceof JViewport && table.getParent().getParent() instanceof JScrollPane) {
                      table.getParent().repaint();
                  }
              }
  
              public void columnMarginChanged(ChangeEvent e) {
                  if (table.getParent() instanceof JViewport && table.getParent().getParent() instanceof JScrollPane) {
                      table.getParent().repaint();
                  }
              }
  
              public void columnMoved(TableColumnModelEvent e) {
                  if (table.getParent() instanceof JViewport && table.getParent().getParent() instanceof JScrollPane) {
                      table.getParent().repaint();
                  }
              }
  
              public void columnRemoved(TableColumnModelEvent e) {
                  if (table.getParent() instanceof JViewport && table.getParent().getParent() instanceof JScrollPane) {
                      table.getParent().repaint();
                  }
              }
  
              public void columnSelectionChanged(ListSelectionEvent e) {
                  if (table.getParent() instanceof JViewport && table.getParent().getParent() instanceof JScrollPane) {
                      table.getParent().repaint();
                  }
              }
          };
      }
docs: DOCUMENT ME!
  
  @param  table DOCUMENT ME!
  
  @return DOCUMENT ME!