feat: There is no way the,
This commit is contained in:
@@ -49,15 +49,15 @@ public class WaterMarkUtil {
|
|||||||
// set Transparency
|
// set Transparency
|
||||||
PdfGState gs = new PdfGState();
|
PdfGState gs = new PdfGState();
|
||||||
// 设置透明度为0.2
|
// 设置透明度为0.2
|
||||||
gs.setFillOpacity(0.4f);
|
gs.setFillOpacity(0.3f);
|
||||||
under.setGState(gs);
|
under.setGState(gs);
|
||||||
under.restoreState();
|
under.restoreState();
|
||||||
under.beginText();
|
under.beginText();
|
||||||
under.setFontAndSize(base, 56);
|
under.setFontAndSize(base, 50);
|
||||||
under.setTextMatrix(30, 30);
|
under.setTextMatrix(30, 30);
|
||||||
under.setColorFill(BaseColor.LIGHT_GRAY);
|
under.setColorFill(BaseColor.LIGHT_GRAY);
|
||||||
for (int y = 0; y < 10; y++) {
|
for (int y = 0; y < 5; y++) {
|
||||||
for (int x = 0; x < 8; x++) {
|
for (int x = 0; x < 10; x++) {
|
||||||
// 水印文字成45度角倾斜
|
// 水印文字成45度角倾斜
|
||||||
under.showTextAligned(Element.ALIGN_LEFT
|
under.showTextAligned(Element.ALIGN_LEFT
|
||||||
, waterMarkName, 100 + 300 * x, 300 * y, 40);
|
, waterMarkName, 100 + 300 * x, 300 * y, 40);
|
||||||
|
|||||||
Reference in New Issue
Block a user