'The row consists of attributes sorted by name; class is at the
beginning, if present, so it\'s on the x-axis and not lost somewhere.'

def row_for_state(self, score, state):

    class_var = self.master.color_data.domain.class_var
    attrs = tuple(sorted((self.attr_ordering[x] for x in state), key=(lambda attr: ((1 - (attr is class_var)), attr.name))))
    item = QStandardItem(',    '.join((a.name for a in attrs)))
    item.setData(attrs, self._AttrRole)
    return [item]
