Visually improve the list of strings

Julien LepillerSat Jun 23 12:23:44+0200 2018

75c3815

Visually improve the list of strings

offlate/window.py

5757
                cont = True
5858
            if not cont:
5959
                continue
60-
            item = QTreeWidgetItem([entry.msgids[0], entry.msgstrs[0]])
60+
            item = QTreeWidgetItem([entry.msgids[0].replace('\n', ' '),
61+
                                    entry.msgstrs[0].replace('\n', ' ')])
62+
            if entry.isFuzzy():
63+
                item.setForeground(1, QBrush(QColor(255, 127, 80)))
64+
            item.setFont(0, QFont("sans-serif", 10))
65+
            item.setFont(1, QFont("sans-serif", 10))
66+
            item.setSizeHint(0, QSize(-1, 22))
6167
            item.setData(0, Qt.UserRole, entry)
6268
            items.append(item)
6369
        self.treeWidget.insertTopLevelItems(0, items)

155161
                data.update(i, self.msgstr.widget(i).toPlainText())
156162
                i=i+1
157163
            item.setText(1, data.get(0))
164+
        item.setForeground(1, QBrush())
158165
159166
    def save(self):
160167
        self.project.save()