Implement inject-code to functions using QChar in QFontMetrics and
QFontMetricsF
Reviewer: Luciano Wolf <luciano.wolf@openbossa.org>
Marcelo Lira <marcelo.lira@openbossa.org>
This commit is contained in:
parent
ef7eb0fca4
commit
4cca85f525
2 changed files with 58 additions and 0 deletions
|
|
@ -185,5 +185,15 @@ class FSizeTest(QFontMetricsFTest):
|
|||
'PySide by INdT', 20, ['aaaa', 'ase'])
|
||||
|
||||
|
||||
class QCharTest(QFontMetricsFTest):
|
||||
|
||||
def testBoundingRect(self):
|
||||
retCh = self.metrics.boundingRectChar('a')
|
||||
self.assertEqual(type(retCh), QRectF)
|
||||
|
||||
def testWith(self):
|
||||
retCh = self.metrics.widthChar('a')
|
||||
self.assert_(retCh > 0)
|
||||
|
||||
if __name__ == '__main__':
|
||||
unittest.main()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue