亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? pdfprow.java

?? 源碼包含生成 PDF 和 HTML 的類庫
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
/* * $Id: PdfPRow.java 3560 2008-07-14 10:31:32Z blowagie $ * * Copyright 2001, 2002 Paulo Soares * * The contents of this file are subject to the Mozilla Public License Version 1.1 * (the "License"); you may not use this file except in compliance with the License. * You may obtain a copy of the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the License. * * The Original Code is 'iText, a free JAVA-PDF library'. * * The Initial Developer of the Original Code is Bruno Lowagie. Portions created by * the Initial Developer are Copyright (C) 1999, 2000, 2001, 2002 by Bruno Lowagie. * All Rights Reserved. * Co-Developer of the code is Paulo Soares. Portions created by the Co-Developer * are Copyright (C) 2000, 2001, 2002 by Paulo Soares. All Rights Reserved. * * Contributor(s): all the names of the contributors are added in the source code * where applicable. * * Alternatively, the contents of this file may be used under the terms of the * LGPL license (the "GNU LIBRARY GENERAL PUBLIC LICENSE"), in which case the * provisions of LGPL are applicable instead of those above.  If you wish to * allow use of your version of this file only under the terms of the LGPL * License and not to allow others to use your version of this file under * the MPL, indicate your decision by deleting the provisions above and * replace them with the notice and other provisions required by the LGPL. * If you do not delete the provisions above, a recipient may use your version * of this file under either the MPL or the GNU LIBRARY GENERAL PUBLIC LICENSE. * * This library is free software; you can redistribute it and/or modify it * under the terms of the MPL as stated above or under the terms of the GNU * Library General Public License as published by the Free Software Foundation; * either version 2 of the License, or any later version. * * This library is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS * FOR A PARTICULAR PURPOSE. See the GNU Library general Public License for more * details. * * If you didn't download this code from the following link, you should check if * you aren't using an obsolete version: * http://www.lowagie.com/iText/ */package com.lowagie.text.pdf;import java.awt.Color;import com.lowagie.text.DocumentException;import com.lowagie.text.Element;import com.lowagie.text.ExceptionConverter;import com.lowagie.text.Image;import com.lowagie.text.Rectangle;/** * A row in a PdfPTable. *  * @author Paulo Soares (psoares@consiste.pt) */public class PdfPRow {	/** the bottom limit (bottom right y) */	public static final float BOTTOM_LIMIT = -(1 << 30);	protected PdfPCell cells[];	protected float widths[];	protected float maxHeight = 0;	protected boolean calculated = false;        private int[] canvasesPos;	/**	 * Constructs a new PdfPRow with the cells in the array that was passed as a parameter.	 * @param cells	 */	public PdfPRow(PdfPCell cells[]) {		this.cells = cells;		widths = new float[cells.length];	}	/**	 * Makes a copy of an existing row.	 * @param row	 */	public PdfPRow(PdfPRow row) {		maxHeight = row.maxHeight;		calculated = row.calculated;		cells = new PdfPCell[row.cells.length];		for (int k = 0; k < cells.length; ++k) {			if (row.cells[k] != null)				cells[k] = new PdfPCell(row.cells[k]);		}		widths = new float[cells.length];		System.arraycopy(row.widths, 0, widths, 0, cells.length);	}	/**	 * Sets the widths of the columns in the row.	 * @param widths	 * @return true if everything went right	 */	public boolean setWidths(float widths[]) {		if (widths.length != cells.length)			return false;		System.arraycopy(widths, 0, this.widths, 0, cells.length);		float total = 0;		calculated = false;		for (int k = 0; k < widths.length; ++k) {			PdfPCell cell = cells[k];			cell.setLeft(total);			int last = k + cell.getColspan();			for (; k < last; ++k)				total += widths[k];			--k;			cell.setRight(total);			cell.setTop(0);		}		return true;	}	/**	 * Calculates the heights of each cell in the row.	 * @return the maximum height of the row.	 */	public float calculateHeights() {		maxHeight = 0;		for (int k = 0; k < cells.length; ++k) {			PdfPCell cell = cells[k];			if (cell == null)				continue;			Image img = cell.getImage();			if (img != null) {				img.scalePercent(100);                float refWidth = img.getScaledWidth();                if (cell.getRotation() == 90 || cell.getRotation() == 270) {                    refWidth = img.getScaledHeight();                }                float scale = (cell.getRight() - cell.getEffectivePaddingRight()                    - cell.getEffectivePaddingLeft() - cell.getLeft())                    / refWidth;                img.scalePercent(scale * 100);                float refHeight = img.getScaledHeight();                if (cell.getRotation() == 90 || cell.getRotation() == 270) {                    refHeight = img.getScaledWidth();                }                cell.setBottom(cell.getTop() - cell.getEffectivePaddingTop()                    - cell.getEffectivePaddingBottom()                    - refHeight);			} else {                if (cell.getRotation() == 0 || cell.getRotation() == 180) {                    float rightLimit = cell.isNoWrap() ? 20000 : cell.getRight()                            - cell.getEffectivePaddingRight();                    float bry = (cell.getFixedHeight() > 0) ? cell.getTop()                            - cell.getEffectivePaddingTop()                            + cell.getEffectivePaddingBottom()                            - cell.getFixedHeight() : BOTTOM_LIMIT;                    ColumnText ct = ColumnText.duplicate(cell.getColumn());                    setColumn(ct,                            cell.getLeft() + cell.getEffectivePaddingLeft(), bry,                            rightLimit, cell.getTop() - cell.getEffectivePaddingTop());                    try {                        ct.go(true);                    } catch (DocumentException e) {                        throw new ExceptionConverter(e);                    }                    float yLine = ct.getYLine();                    if (cell.isUseDescender())                        yLine += ct.getDescender();                    cell.setBottom(yLine - cell.getEffectivePaddingBottom());                }                else {                    if (cell.getFixedHeight() > 0) {                        cell.setBottom(cell.getTop() - cell.getFixedHeight());                    }                    else {                        ColumnText ct = ColumnText.duplicate(cell.getColumn());                        setColumn(ct, 0, cell.getLeft() + cell.getEffectivePaddingLeft(),                                20000, cell.getRight() - cell.getEffectivePaddingRight());                        try {                            ct.go(true);                        } catch (DocumentException e) {                            throw new ExceptionConverter(e);                        }                        cell.setBottom(cell.getTop() - cell.getEffectivePaddingTop()                             - cell.getEffectivePaddingBottom() - ct.getFilledWidth());                    }                }			}			float height = cell.getFixedHeight();			if (height <= 0)				height = cell.getHeight();			if (height < cell.getFixedHeight())				height = cell.getFixedHeight();			else if (height < cell.getMinimumHeight())				height = cell.getMinimumHeight();			if (height > maxHeight)				maxHeight = height;		}		calculated = true;		return maxHeight;	}	/**	 * Writes the border and background of one cell in the row.	 * @param xPos	 * @param yPos	 * @param cell	 * @param canvases	 */	public void writeBorderAndBackground(float xPos, float yPos, PdfPCell cell,			PdfContentByte[] canvases) {		PdfContentByte lines = canvases[PdfPTable.LINECANVAS];		PdfContentByte backgr = canvases[PdfPTable.BACKGROUNDCANVAS];		// the coordinates of the border are retrieved		float x1 = cell.getLeft() + xPos;		float y2 = cell.getTop() + yPos;		float x2 = cell.getRight() + xPos;		float y1 = y2 - maxHeight;		// the backgroundcolor is set		Color background = cell.getBackgroundColor();		if (background != null) {			backgr.setColorFill(background);			backgr.rectangle(x1, y1, x2 - x1, y2 - y1);			backgr.fill();        }		// if the element hasn't got any borders, nothing is added		if (cell.hasBorders()) {			if (cell.isUseVariableBorders()) {				Rectangle borderRect = new Rectangle(cell.getLeft() + xPos, cell						.getTop()						- maxHeight + yPos, cell.getRight() + xPos, cell.getTop()						+ yPos);				borderRect.cloneNonPositionParameters(cell);                borderRect.setBackgroundColor(null);				lines.rectangle(borderRect);			} else {				// the width is set to the width of the element				if (cell.getBorderWidth() != Rectangle.UNDEFINED) {					lines.setLineWidth(cell.getBorderWidth());				}				// the color is set to the color of the element				Color color = cell.getBorderColor();				if (color != null) {					lines.setColorStroke(color);				}				// if the box is a rectangle, it is added as a rectangle				if (cell.hasBorder(Rectangle.BOX)) {					lines.rectangle(x1, y1, x2 - x1, y2 - y1);				}				// if the border isn't a rectangle, the different sides are				// added apart				else {					if (cell.hasBorder(Rectangle.RIGHT)) {						lines.moveTo(x2, y1);						lines.lineTo(x2, y2);					}					if (cell.hasBorder(Rectangle.LEFT)) {						lines.moveTo(x1, y1);						lines.lineTo(x1, y2);					}					if (cell.hasBorder(Rectangle.BOTTOM)) {						lines.moveTo(x1, y1);						lines.lineTo(x2, y1);					}					if (cell.hasBorder(Rectangle.TOP)) {						lines.moveTo(x1, y2);						lines.lineTo(x2, y2);					}				}				lines.stroke();				if (color != null) {					lines.resetRGBColorStroke();				}			}		}	}    private void saveAndRotateCanvases(PdfContentByte[] canvases, float a, float b, float c, float d, float e, float f) {        int last = PdfPTable.TEXTCANVAS + 1;        if (canvasesPos == null) {            canvasesPos = new int[last * 2];        }        for (int k = 0; k < last; ++k) {            ByteBuffer bb = canvases[k].getInternalBuffer();            canvasesPos[k * 2] = bb.size();            canvases[k].saveState();            canvases[k].concatCTM(a, b, c, d, e, f);            canvasesPos[k * 2 + 1] = bb.size();        }    }        private void restoreCanvases(PdfContentByte[] canvases) {        int last = PdfPTable.TEXTCANVAS + 1;        for (int k = 0; k < last; ++k) {            ByteBuffer bb = canvases[k].getInternalBuffer();            int p1 = bb.size();            canvases[k].restoreState();            if (p1 == canvasesPos[k * 2 + 1])                bb.setSize(canvasesPos[k * 2]);        }    }        private float setColumn(ColumnText ct, float llx, float lly, float urx, float ury) {        if (llx > urx)            urx = llx;        if (lly > ury)            ury = lly;        ct.setSimpleColumn(llx, lly, urx, ury);        return ury;    }    	/**	 * Writes a number of cells (not necessarily all cells).	 * @param colStart	 * @param colEnd	 * @param xPos	 * @param yPos	 * @param canvases	 */	public void writeCells(int colStart, int colEnd, float xPos, float yPos,			PdfContentByte[] canvases) {		if (!calculated)			calculateHeights();		if (colEnd < 0)			colEnd = cells.length;		colEnd = Math.min(colEnd, cells.length);		if (colStart < 0)			colStart = 0;		if (colStart >= colEnd)			return;		int newStart;		for (newStart = colStart; newStart >= 0; --newStart) {			if (cells[newStart] != null)				break;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
成人黄色小视频在线观看| 婷婷国产在线综合| 成人av网址在线观看| 欧美激情一区二区三区不卡| 国产成人亚洲综合色影视| 国产亚洲精品资源在线26u| 成人精品在线视频观看| 亚洲人成网站影音先锋播放| 欧洲精品在线观看| 日本欧美一区二区三区乱码| 精品精品欲导航| 国产精品99久久久久久久女警| 国产精品久久久久永久免费观看| 97se亚洲国产综合自在线观| 亚洲成人高清在线| 久久蜜臀精品av| 不卡一卡二卡三乱码免费网站| 一区二区三区精品在线| 日韩一区二区不卡| 成人免费视频一区二区| 亚洲制服丝袜av| 精品日韩欧美在线| 99久久久久久| 蜜臀va亚洲va欧美va天堂| www国产成人免费观看视频 深夜成人网 | 中文字幕一区日韩精品欧美| 欧美日韩激情一区二区| 国内精品免费**视频| 国产精品无遮挡| 在线观看一区二区精品视频| 美日韩黄色大片| 国产欧美日韩亚州综合| 欧美精品自拍偷拍| 成人精品在线视频观看| 青青青伊人色综合久久| 亚洲欧洲精品天堂一级| 欧美一区二区福利在线| av福利精品导航| 美女www一区二区| 亚洲制服丝袜av| 国产无一区二区| 91麻豆精品91久久久久久清纯| 国产91高潮流白浆在线麻豆| 日韩高清一级片| 亚洲视频资源在线| 国产午夜精品在线观看| 欧美一区二区在线播放| 在线看不卡av| 99精品视频在线观看免费| 久草在线在线精品观看| 五月婷婷欧美视频| 亚洲日本va在线观看| 国产午夜亚洲精品羞羞网站| 日韩欧美精品三级| 91精品国产色综合久久不卡电影| 色哦色哦哦色天天综合| 成人免费视频caoporn| 久久成人麻豆午夜电影| 午夜欧美大尺度福利影院在线看| 最好看的中文字幕久久| 国产调教视频一区| 久久无码av三级| 欧美变态tickle挠乳网站| 91福利小视频| 91欧美激情一区二区三区成人| 国产乱码精品一区二区三区五月婷 | 日韩高清一区在线| 亚洲va韩国va欧美va| 亚洲一区二区综合| 亚洲精品乱码久久久久久日本蜜臀| 欧美激情综合在线| 国产精品视频一二三区| 国产精品视频一二三| 国产精品久久久久影视| 国产精品免费人成网站| 国产拍欧美日韩视频二区| 久久精品在线观看| 国产日韩欧美精品综合| 中文无字幕一区二区三区| 中文字幕免费不卡| 中文字幕在线观看不卡| 国产精品久久久久婷婷| 亚洲特黄一级片| 亚洲午夜在线视频| 视频一区二区中文字幕| 久久成人18免费观看| 欧美一区永久视频免费观看| 亚洲影视在线播放| 综合久久给合久久狠狠狠97色| 欧美极品xxx| 亚洲特级片在线| 一区二区三区加勒比av| 亚洲成人av福利| 久久99精品国产.久久久久| 国内外精品视频| www.亚洲国产| 欧美又粗又大又爽| 欧美电影影音先锋| 精品少妇一区二区三区在线播放| 国产三级一区二区三区| 亚洲黄色小说网站| 日韩电影免费在线| 国产麻豆9l精品三级站| av不卡一区二区三区| 欧美视频在线一区二区三区| 欧美大胆人体bbbb| 国产精品国产自产拍在线| 亚洲最大成人网4388xx| 日本欧美一区二区| 国产成人夜色高潮福利影视| 91成人在线免费观看| 国产精品久久久久久久久免费樱桃| 亚洲精品乱码久久久久| 国产精品国产三级国产| 亚洲高清视频中文字幕| 国产一区二区三区精品视频| av爱爱亚洲一区| 日韩久久久久久| 中文字幕日本不卡| 日本aⅴ亚洲精品中文乱码| 国产一区二区按摩在线观看| 色老汉av一区二区三区| 精品美女一区二区| 亚洲最快最全在线视频| 国产成人精品一区二区三区四区| 欧美日韩午夜在线视频| 国产亚洲精品中文字幕| 日本不卡的三区四区五区| 99在线精品一区二区三区| 欧美一区二区观看视频| 一区二区三区四区国产精品| 国产一区二区中文字幕| 欧美日韩午夜精品| 中文字幕一区二区三区蜜月| 美女爽到高潮91| 欧美日韩在线一区二区| 国产精品久久国产精麻豆99网站| 麻豆成人久久精品二区三区红 | 国产精品久久久久毛片软件| 免费久久精品视频| 欧洲精品中文字幕| 中文字幕亚洲电影| 国产精品资源网| 日韩一级片在线观看| 亚洲va在线va天堂| 色香蕉久久蜜桃| 国产精品传媒视频| 国产精品18久久久久久久网站| 日韩一级黄色片| 视频一区二区三区在线| 欧美丝袜丝交足nylons图片| 日韩美女视频一区| 99re这里只有精品6| 国产欧美日韩综合精品一区二区| 另类人妖一区二区av| 91精品国产色综合久久不卡电影 | 日韩电影免费在线看| 欧美色电影在线| 亚洲欧洲中文日韩久久av乱码| 国产suv精品一区二区883| 久久精品这里都是精品| 国产精品系列在线观看| 国产日韩欧美a| 国产精品综合av一区二区国产馆| 久久久亚洲精品石原莉奈| 日韩电影一区二区三区| 日韩一卡二卡三卡| 久久激情综合网| 26uuu国产一区二区三区| 久久国产夜色精品鲁鲁99| 91精品国产手机| 蓝色福利精品导航| 欧美v国产在线一区二区三区| 免费在线欧美视频| 日韩三区在线观看| 国产在线播放一区三区四| www国产精品av| 成人黄色电影在线| 一区视频在线播放| 在线观看视频一区| 亚洲高清免费视频| 日韩欧美一区二区视频| 黄色资源网久久资源365| 国产日韩精品久久久| 成人av资源站| 亚洲一区二区欧美| 欧美一区二区视频在线观看2022 | 国产制服丝袜一区| 国产日本欧洲亚洲| 色诱视频网站一区| 视频在线观看国产精品| 日韩精品在线网站| www.爱久久.com| 亚洲mv大片欧洲mv大片精品| 日韩一区二区三区免费看| 成人免费毛片app| 婷婷亚洲久悠悠色悠在线播放 | 91在线视频免费91| 五月天欧美精品| 国产喷白浆一区二区三区|