@Override
    public Component prepareRenderer(TableCellRenderer renderer,
            int rowIndex, int vColIndex) {
        Component c = super.prepareRenderer(renderer, rowIndex, vColIndex);
        if(global.markChanges){
            if(rowIndex>=ch.length) restate();
            if(ch[rowIndex]>0 && vColIndex==1){
                switch(ch[rowIndex]){
                    case 1: c.setBackground(Color.PINK); break;
                    case 2: c.setBackground(Color.ORANGE); break;
                    case 3: c.setBackground(Color.RED); break;
                }
            }
            else{
                if(this.isCellSelected(rowIndex, vColIndex))
                    c.setBackground(this.getSelectionBackground());
                else
                    c.setBackground(getBackground());
            }
        }
        else{
            if(this.isCellSelected(rowIndex, vColIndex))
                c.setBackground(this.getSelectionBackground());
            else
                c.setBackground(getBackground());
        }
        return c;

    }