Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.9, 1.9.1, and 1.9.2

changeset: use a separate QLabel for the changeset info header

TODO: the horizontal splitter should preferrably only hide the
change message text

Changeset 36da6057988a

Parent 2edc8d913c3f

by Adrian Buehlmann

Changes to one file · Browse files at 36da6057988a Showing diff from parent 2edc8d913c3f Diff from another changeset...

 
33
34
35
36
37
38
39
 
 
 
 
 
 
40
41
42
43
44
45
 
 
46
47
48
49
50
51
52
 
53
54
55
 
182
183
184
 
 
185
186
187
188
 
 
 
33
34
35
 
36
37
 
38
39
40
41
42
43
44
45
46
47
 
 
48
49
50
51
52
53
54
55
 
56
57
58
59
 
186
187
188
189
190
191
192
 
 
193
194
@@ -33,23 +33,27 @@
  def __init__(self, parent=None):   QtGui.QWidget.__init__(self, parent)   - self._details = QtGui.QTextBrowser()   vb = QtGui.QVBoxLayout()   vb.setMargin(0) - vb.addWidget(self._details) + + self._header = w = QtGui.QLabel() + vb.addWidget(w) + self._message = w = QtGui.QTextBrowser() + vb.addWidget(w) +   self.setLayout(vb)     self.descwidth = 60 # number of chars displayed for parent/child descriptions   - connect(self._details, - SIGNAL('anchorClicked(const QUrl &)'), + connect(self._header, + SIGNAL('linkActivated(const QString&)'),   self.anchorClicked)     def anchorClicked(self, qurl):   """   Callback called when a link is clicked in the text browser   """ - rev = str(qurl.toString()) + rev = str(qurl)   if rev.startswith('diff_'):   self.diffrev = int(rev[5:])   self.refreshDisplay() @@ -182,7 +186,9 @@
  '\n' % (p.rev(), p.rev(), short, desc)     buf += "</table>\n" + self._header.setText(buf) +   desc = xml_escape(unicode(ctx.description(), 'utf-8', 'replace'))   desc = desc.replace('\n', '<br/>\n') - buf += '<div class="diff_desc"><p>%s</p></div>\n' % desc - self._details.setHtml(buf) + buf = '<div class="diff_desc"><p>%s</p></div>' % desc + self._message.setHtml(buf)