summaryrefslogtreecommitdiff
path: root/pdf-over-gui/src
diff options
context:
space:
mode:
authorJakob Heher <jakob.heher@iaik.tugraz.at>2022-08-08 14:52:00 +0200
committerJakob Heher <jakob.heher@iaik.tugraz.at>2022-08-08 14:52:00 +0200
commit6c13dd46eabee023b9b852fa9e7897658017e4b8 (patch)
treec1d8202aa46e28d5db257b444ba9bacf050427fa /pdf-over-gui/src
parent87d9ea517e2b879da2d271c3d01f5811e49383be (diff)
downloadpdf-over-6c13dd46eabee023b9b852fa9e7897658017e4b8.tar.gz
pdf-over-6c13dd46eabee023b9b852fa9e7897658017e4b8.tar.bz2
pdf-over-6c13dd46eabee023b9b852fa9e7897658017e4b8.zip
remove "signature" overlay text from position screen
Diffstat (limited to 'pdf-over-gui/src')
-rw-r--r--pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java15
1 files changed, 1 insertions, 14 deletions
diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java
index 02b1e21e..5cc1b749 100644
--- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java
+++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SignaturePanel.java
@@ -383,21 +383,8 @@ public class SignaturePanel extends JPanel {
this.sigPlaceholderScaled = new BufferedImage(this.sigScreenWidth, this.sigScreenHeight, BufferedImage.TYPE_INT_ARGB);
Graphics g_phs = this.sigPlaceholderScaled.getGraphics();
g_phs.drawImage(placeholder, 0, 0, null);
-
- // Draw grey "Signature" overlay
- String overlay = Messages.getString("positioning.signature");
- // Voodoo to get overlay font scale
- float scale = (((float) this.sigScreenWidth) / this.sigPlaceholder.getWidth(null)) * 150;
- g_phs.setFont(getFont().deriveFont(scale));
- g_phs.setColor(this.sigPlaceholderBorderColor);
- Rectangle2D overlay_size = g_phs.getFontMetrics().getStringBounds(overlay, g_phs);
- int width = (int) overlay_size.getWidth();
- int height = (int) overlay_size.getHeight();
- int x = this.sigScreenWidth / 2 - width / 2;
- int y = this.sigScreenHeight / 2 - height / 2 + g_phs.getFontMetrics().getAscent();
- g_phs.drawString(overlay, x, y);
-
g_phs.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) {