This commit is contained in:
@@ -925,7 +925,14 @@ public class TerminalPanel extends JPanel {
|
||||
int cs = (ea.cs != 0) ? (ea.cs & 0xFF) : (currentFieldEa != null ? (currentFieldEa.cs & 0xFF) : 0);
|
||||
boolean drawnAsPs = false;
|
||||
if (cs >= 0x40 && client.getProgramSymbolManager() != null) {
|
||||
drawnAsPs = client.getProgramSymbolManager().drawSymbol(g2, cs, ea.ec & 0xFF, x, y, cellWidth, cellHeight, fgColor, bgColor);
|
||||
org.lib3270j.graphics.ProgramSymbolSet.SymbolSlot slot = client.getProgramSymbolManager().getSymbol(cs, ea.ec & 0xFF);
|
||||
if (slot != null) {
|
||||
int[] rgb = slot.getRgbPixels(fgColor.getRGB(), bgColor.getRGB());
|
||||
java.awt.image.BufferedImage img = new java.awt.image.BufferedImage(slot.getWidth(), slot.getHeight(), java.awt.image.BufferedImage.TYPE_INT_ARGB);
|
||||
img.setRGB(0, 0, slot.getWidth(), slot.getHeight(), rgb, 0, slot.getWidth());
|
||||
g2.drawImage(img, x, y, cellWidth, cellHeight, null);
|
||||
drawnAsPs = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (!drawnAsPs) {
|
||||
@@ -958,7 +965,12 @@ public class TerminalPanel extends JPanel {
|
||||
int gridW = cols * cellWidth;
|
||||
int gridH = rows * cellHeight;
|
||||
client.getGraphicsPlane().resize(gridW, gridH);
|
||||
g2.drawImage(client.getGraphicsPlane().getImage(), ox, oy, gridW, gridH, null);
|
||||
int[] rgb = client.getGraphicsPlane().getRgbBuffer();
|
||||
if (rgb != null) {
|
||||
java.awt.image.BufferedImage img = new java.awt.image.BufferedImage(gridW, gridH, java.awt.image.BufferedImage.TYPE_INT_ARGB);
|
||||
img.setRGB(0, 0, gridW, gridH, rgb, 0, gridW);
|
||||
g2.drawImage(img, ox, oy, gridW, gridH, null);
|
||||
}
|
||||
}
|
||||
|
||||
// Draw cursor
|
||||
|
||||
Reference in New Issue
Block a user