Reimplemented from QtCore.QAbstractItemModel

        The value gets validated and is red if validation fails
        and green if it passes.

def data(self, index, role = QtCore.Qt.DisplayRole):
        """Reimplemented from QtCore.QAbstractItemModel

        The value gets validated and is red if validation fails
        and green if it passes.
        """
        if not index.isValid():
            return None
        if role == QtCore.Qt.DisplayRole or role == QtCore.Qt.EditRole:
            if index.column() == 0:
                p = index.internalPointer()
                k = self.get_key(p, index.row())
                return k
            if index.column() == 1:
                v = self.get_value(index)
                if not isinstance(v, Section):
                    return self._val_to_str(v)
            if index.column() == 2:
                return self.get_configspec_str(index)
        if role == QtCore.Qt.ForegroundRole:
            if index.column() == 1:
                v = self.get_value(index)
                if not isinstance(v, Section):
                    spec = self.get_configspec_str(index)
                    if spec is None or isinstance(spec, Section):
                        return
                    try:
                        self._vld.check(spec, v)
                    except ValidateError:
                        return QtGui.QBrush(self._invalid_col)
                    else:
                        return QtGui.QBrush(self._valid_col)