Browse Source

KERNEL-1314 fine-itext支持JDK11

research/11.0
zhouping 5 years ago
parent
commit
b6b3653c12
  1. 2
      fine-itext-old/src/com/fr/third/com/lowagie/text/Row.java
  2. 6
      fine-itext-old/src/com/fr/third/com/lowagie/text/html/simpleparser/HTMLWorker.java
  3. 2
      fine-itext-old/src/com/fr/third/com/lowagie/text/rtf/table/RtfRow.java
  4. 8
      fine-itext-old/src/com/fr/third/com/lowagie/text/rtf/table/RtfTable.java
  5. 4
      fine-itext/src/com/fr/third/v2/lowagie/text/html/simpleparser/HTMLWorker.java

2
fine-itext-old/src/com/fr/third/com/lowagie/text/Row.java

@ -93,7 +93,7 @@ public class Row implements Element {
/** This is the array of Objects (<CODE>Cell</CODE> or <CODE>Table</CODE>). */ /** This is the array of Objects (<CODE>Cell</CODE> or <CODE>Table</CODE>). */
protected Object[] cells; protected Object[] cells;
/** carl:反正自己改代码,不管什么结构了*/ /** carl:反正自己改代码,不管什么结构了*/
protected int height = 0; protected int height = 0;
/** This is the vertical alignment. */ /** This is the vertical alignment. */

6
fine-itext-old/src/com/fr/third/com/lowagie/text/html/simpleparser/HTMLWorker.java

@ -72,14 +72,10 @@ import com.fr.third.com.lowagie.text.pdf.PdfPTable;
import com.fr.third.com.lowagie.text.pdf.draw.LineSeparator; import com.fr.third.com.lowagie.text.pdf.draw.LineSeparator;
import com.fr.third.com.lowagie.text.xml.simpleparser.SimpleXMLDocHandler; import com.fr.third.com.lowagie.text.xml.simpleparser.SimpleXMLDocHandler;
import com.fr.third.com.lowagie.text.xml.simpleparser.SimpleXMLParser; import com.fr.third.com.lowagie.text.xml.simpleparser.SimpleXMLParser;
import sun.misc.BASE64Decoder; import com.fr.third.sun.misc.BASE64Decoder;
import javax.imageio.ImageIO;
import java.awt.image.BufferedImage;
import java.io.ByteArrayInputStream;
import java.io.File; import java.io.File;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream;
import java.io.Reader; import java.io.Reader;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;

2
fine-itext-old/src/com/fr/third/com/lowagie/text/rtf/table/RtfRow.java

@ -232,7 +232,7 @@ public class RtfRow extends RtfElement {
this.cells = new ArrayList(); this.cells = new ArrayList();
this.width = this.document.getDocumentHeader().getPageSetting().getPageWidth() - this.document.getDocumentHeader().getPageSetting().getMarginLeft() - this.document.getDocumentHeader().getPageSetting().getMarginRight(); this.width = this.document.getDocumentHeader().getPageSetting().getPageWidth() - this.document.getDocumentHeader().getPageSetting().getMarginLeft() - this.document.getDocumentHeader().getPageSetting().getMarginRight();
this.width = (int) (this.width * this.parentTable.getTableWidthPercent() / 100); this.width = (int) (this.width * this.parentTable.getTableWidthPercent() / 100);
// carl: ´ŤľÝheight // carl: height
this.height = row.getHeight(); this.height = row.getHeight();
int cellRight = 0; int cellRight = 0;

8
fine-itext-old/src/com/fr/third/com/lowagie/text/rtf/table/RtfTable.java

@ -238,14 +238,14 @@ public class RtfTable extends RtfElement {
result.write(RtfFont.FONT_SIZE); result.write(RtfFont.FONT_SIZE);
result.write(intToByteArray(this.offset)); result.write(intToByteArray(this.offset));
} }
// carl:多出来的行,行高设为最小 1 // carl:多出来的行,行高设为最小 1
result.write(RtfParagraph.PLAIN); result.write(RtfParagraph.PLAIN);
// result.write("\\s".getBytes()); // result.write("\\s".getBytes());
// result.write(intToByteArray(0)); // result.write(intToByteArray(0));
result.write(RtfPhrase.LINE_SPACING); result.write(RtfPhrase.LINE_SPACING);
result.write(intToByteArray(0)); result.write(intToByteArray(0));
result.write(RtfParagraph.PLAIN); result.write(RtfParagraph.PLAIN);
// 这里是关键,把这破行设成1 // 这里是关键,把这破行设成1
result.write(RtfFont.FONT_SIZE); result.write(RtfFont.FONT_SIZE);
result.write(intToByteArray(2)); result.write(intToByteArray(2));
result.write(RtfParagraph.PARAGRAPH); result.write(RtfParagraph.PARAGRAPH);
@ -258,14 +258,14 @@ public class RtfTable extends RtfElement {
} }
result.write(RtfParagraph.PARAGRAPH_DEFAULTS); result.write(RtfParagraph.PARAGRAPH_DEFAULTS);
// carl:多出来的行,行高设为最小 1 // carl:多出来的行,行高设为最小 1
result.write(RtfParagraph.PLAIN); result.write(RtfParagraph.PLAIN);
// result.write("\\s".getBytes()); // result.write("\\s".getBytes());
// result.write(intToByteArray(0)); // result.write(intToByteArray(0));
result.write(RtfPhrase.LINE_SPACING); result.write(RtfPhrase.LINE_SPACING);
result.write(intToByteArray(0)); result.write(intToByteArray(0));
result.write(RtfParagraph.PLAIN); result.write(RtfParagraph.PLAIN);
// 这里是关键,把这破行设成1 // 这里是关键,把这破行设成1
result.write(RtfFont.FONT_SIZE); result.write(RtfFont.FONT_SIZE);
result.write(intToByteArray(2)); result.write(intToByteArray(2));
} }

4
fine-itext/src/com/fr/third/v2/lowagie/text/html/simpleparser/HTMLWorker.java

@ -58,8 +58,6 @@ import java.io.InputStream;
import java.io.Reader; import java.io.Reader;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.Stack; import java.util.Stack;
import java.util.StringTokenizer; import java.util.StringTokenizer;
@ -85,7 +83,7 @@ import com.fr.third.v2.lowagie.text.Paragraph;
import com.fr.third.v2.lowagie.text.Phrase; import com.fr.third.v2.lowagie.text.Phrase;
import com.fr.third.v2.lowagie.text.pdf.PdfPTable; import com.fr.third.v2.lowagie.text.pdf.PdfPTable;
import com.fr.third.v2.lowagie.text.xml.simpleparser.SimpleXMLParser; import com.fr.third.v2.lowagie.text.xml.simpleparser.SimpleXMLParser;
import sun.misc.BASE64Decoder; import com.fr.third.sun.misc.BASE64Decoder;
import javax.imageio.ImageIO; import javax.imageio.ImageIO;

Loading…
Cancel
Save