diff options
author | tkellner <tkellner@3a0b52a2-8410-0410-bc02-ff6273a87459> | 2012-10-31 16:36:41 +0000 |
---|---|---|
committer | tkellner <tkellner@3a0b52a2-8410-0410-bc02-ff6273a87459> | 2012-10-31 16:36:41 +0000 |
commit | 84787c7868dcd55883e066c2046144833524a00d (patch) | |
tree | 98ba05de805ada7e14c490030c868ed0e7be0b52 /trunk/pdf-over-gui | |
parent | b0b3d5e20859073097d95cefa92da52f7e620d8d (diff) | |
download | pdf-over-84787c7868dcd55883e066c2046144833524a00d.tar.gz pdf-over-84787c7868dcd55883e066c2046144833524a00d.tar.bz2 pdf-over-84787c7868dcd55883e066c2046144833524a00d.zip |
Use specified font, scale emblem in placeholder
git-svn-id: https://svn.iaik.tugraz.at/svn/egiz/prj/current/12PDF-OVER-4.0@12709 3a0b52a2-8410-0410-bc02-ff6273a87459
Diffstat (limited to 'trunk/pdf-over-gui')
-rw-r--r-- | trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java index 7fee3021..cb23d055 100644 --- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java +++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java @@ -255,6 +255,7 @@ public class SignaturePanel extends JPanel { if ((this.sigScreenWidth != this.prevSigScreenWidth) || (this.sigScreenHeight != this.prevSigScreenHeight)) { + // redraw scaled transparent placeholder this.prevSigScreenWidth = this.sigScreenWidth; this.prevSigScreenHeight = this.sigScreenHeight; Image placeholder = this.sigPlaceholder.getScaledInstance( @@ -262,6 +263,7 @@ public class SignaturePanel extends JPanel { this.sigPlaceholderScaled = new BufferedImage(this.sigScreenWidth, this.sigScreenHeight, BufferedImage.TYPE_INT_ARGB); Graphics g2 = this.sigPlaceholderScaled.getGraphics(); g2.drawImage(placeholder, 0, 0, null); + g2.dispose(); int[] phpixels = new int[this.sigScreenWidth * this.sigScreenHeight]; phpixels = this.sigPlaceholderScaled.getRGB(0, 0, this.sigScreenWidth, this.sigScreenHeight, phpixels, 0, this.sigScreenWidth); for (int i = 0; i < phpixels.length; ++i) { |