Skip to content

Commit 3fcbe51

Browse files
author
ntwigg
committed
Recreate the issue.
1 parent f162788 commit 3fcbe51

File tree

4 files changed

+99
-0
lines changed

4 files changed

+99
-0
lines changed
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
package com.diffplug.common.swt
2+
3+
import com.diffplug.common.swt.jface.ImageDescriptors
4+
import org.eclipse.jface.resource.ImageDescriptor
5+
import org.eclipse.swt.SWT
6+
import org.eclipse.swt.widgets.Label
7+
import org.junit.Test
8+
import org.junit.experimental.categories.Category
9+
10+
@Category(InteractiveTest::class)
11+
class Issue_2228 {
12+
@Test
13+
fun recreate() {
14+
InteractiveTest.testCoat("Show the difference between `.svg` and `@x2.png` rendering") {
15+
Layouts.setGrid(it).numColumns(2)
16+
Label(it, SWT.NONE).apply {
17+
text = ".svg"
18+
}
19+
Label(it, SWT.NONE).apply {
20+
val imgDesc = ImageDescriptor.createFromFile(Issue_2228::class.java, "/issue_2228/strikethrough.svg");
21+
image = imgDesc.createImage()
22+
}
23+
Label(it, SWT.NONE).apply {
24+
text = ".png"
25+
}
26+
Label(it, SWT.NONE).apply {
27+
val imgDesc = ImageDescriptor.createFromFile(Issue_2228::class.java, "/issue_2228/strikethrough.png");
28+
image = imgDesc.createImage()
29+
}
30+
}
31+
}
32+
}
433 Bytes
Loading
Lines changed: 67 additions & 0 deletions
Loading
725 Bytes
Loading

0 commit comments

Comments
 (0)