| 12 | If you have `FontTests` from #126 you could add the following code (which could be substantially signified - I'm using the test framework where I discovered the error) : |
| 13 | |
| 14 | {{{ |
| 15 | |
| 16 | "{ Encoding: utf8 }" ! |
| 17 | !FontTests methodsFor:'tests'! |
| 18 | |
| 19 | test_issue_208_XftFontDescription_does_not_understand_xftDrawDestroy |
| 20 | " Testing long strings display. |
| 21 | The test takes shown textView and tries to find out non-white pixels. |
| 22 | |
| 23 | For more visit: https://swing.fit.cvut.cz/projects/stx-jv/ticket/126" |
| 24 | |
| 25 | self skipIf: (DeviceWorkstation current isX11Platform not) description: 'Not a X11 Platform.'. |
| 26 | |
| 27 | fontList do:[:font | |
| 28 | testFontSize do:[:preselectedFontSize | | setFontSize fontAtSize | |
| 29 | [ (font size = 0.0) ifTrue:[setFontSize := preselectedFontSize] "/TrueType font |
| 30 | ifFalse:[setFontSize := font size]. "/Raster font |
| 31 | fontAtSize := (font copy asSize:setFontSize) onDevice:textView device. |
| 32 | textView font:fontAtSize. |
| 33 | textView contents: testString. |
| 34 | |
| 35 | self assert:(font shouldImplement: 'xftDrawDestroy'). |
| 36 | |
| 37 | ] ensure:[textView contents:nil]. |
| 38 | ]. |
| 39 | ] |
| 40 | |
| 41 | "Created: / 25-04-2018 / 16:29:11 / smalltalk" |
| 42 | ! ! |