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

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

?? table.java

?? 一個java操作pdf文件的開發包,很好用的.
?? JAVA
?? 第 1 頁 / 共 4 頁
字號:
/* * $Id: Table.java,v 1.94 2002/07/10 07:22:39 blowagie Exp $ * $Name:  $ * * Copyright 1999, 2000, 2001, 2002 by Bruno Lowagie. * * 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/ * * Some methods in this class were contributed by Geert Poels, Kris Jespers and * Steve Ogryzek. Check the CVS repository. */package com.lowagie.text;import java.awt.Color;import java.awt.Dimension;import java.awt.Point;import java.util.ArrayList;import java.util.Hashtable;import java.util.Iterator;import java.util.Properties;import java.util.StringTokenizer;import com.lowagie.text.markup.*;/** * A <CODE>Table</CODE> is a <CODE>Rectangle</CODE> that contains <CODE>Cell</CODE>s, * ordered in some kind of matrix. * <P> * Tables that span multiple pages are cut into different parts automatically. * If you want a table header to be repeated on every page, you may not forget to * mark the end of the header section by using the method <CODE>endHeaders()</CODE>. * <P> * The matrix of a table is not necessarily an m x n-matrix. It can contain holes * or cells that are bigger than the unit. Believe me or not, but it took some serious * thinking to make this as userfriendly as possible. I hope you wil find the result * quite simple (I love simple solutions, especially for complex problems). * I didn't want it to be something as complex as the Java <CODE>GridBagLayout</CODE>. * <P> * Example: * <BLOCKQUOTE><PRE> * // Remark: You MUST know the number of columns when constructing a Table. * //         The number of rows is not important. * <STRONG>Table table = new Table(3);</STRONG> * <STRONG>table.setBorderWidth(1);</STRONG> * <STRONG>table.setBorderColor(new Color(0, 0, 255));</STRONG> * <STRONG>table.setPadding(5);</STRONG> * <STRONG>table.setSpacing(5);</STRONG> * Cell cell = new Cell("header"); * cell.setHeader(true); * cell.setColspan(3); * <STRONG>table.addCell(cell);</STRONG> * <STRONG>table.endHeaders();</STRONG> * cell = new Cell("example cell with colspan 1 and rowspan 2"); * cell.setRowspan(2); * cell.setBorderColor(new Color(255, 0, 0)); * <STRONG>table.addCell(cell);</STRONG> * <STRONG>table.addCell("1.1");</STRONG> * <STRONG>table.addCell("2.1");</STRONG> * <STRONG>table.addCell("1.2");</STRONG> * <STRONG>table.addCell("2.2");</STRONG> * <STRONG>table.addCell("cell test1");</STRONG> * cell = new Cell("big cell"); * cell.setRowspan(2); * cell.setColspan(2); * <STRONG>table.addCell(cell);</STRONG> * <STRONG>table.addCell("cell test2");</STRONG> * </PRE></BLOCKQUOTE> * The result of this code is a table: *      <TABLE ALIGN="Center" BORDER="1" BORDERCOLOR="#0000ff" CELLPADDING="5" CELLSPACING="5"> *              <TR ALIGN="Left" VALIGN="Left"> *                      <TH ALIGN="Left" COLSPAN="3" VALIGN="Left"> *                              header *                      </TH> *              </TR> *              <TR ALIGN="Left" VALIGN="Left"> *                      <TD ALIGN="Left" BORDERCOLOR="#ff0000" ROWSPAN="2" VALIGN="Left"> *                              example cell with colspan 1 and rowspan 2 *                      </TD> *                      <TD ALIGN="Left" VALIGN="Left"> *                              1.1 *                      </TD> *                      <TD ALIGN="Left" VALIGN="Left"> *                              2.1 *                      </TD> *              </TR> *              <TR ALIGN="Left" VALIGN="Left"> *                      <TD ALIGN="Left" VALIGN="Left"> *                              1.2 *                      </TD> *                      <TD ALIGN="Left" VALIGN="Left"> *                              2.2 *                      </TD> *              </TR> *              <TR ALIGN="Left" VALIGN="Left"> *                      <TD ALIGN="Left" VALIGN="Left"> *                              cell test1 *                      </TD> *                      <TD ALIGN="Left" COLSPAN="2" ROWSPAN="2" VALIGN="Left"> *                              big cell *                      </TD> *              </TR> *              <TR ALIGN="Left" VALIGN="Left"> *                      <TD ALIGN="Left" VALIGN="Left"> *                              cell test2 *                      </TD> *              </TR> *      </TABLE> * * @see         Rectangle * @see         Element * @see         Row * @see         Cell */public class Table extends Rectangle implements Element, MarkupAttributes {    // membervariables    // these variables contain the data of the table/** This is the number of columns in the <CODE>Table</CODE>. */    private int columns;// this is the current Position in the table    private Point curPosition = new Point(0, 0);/** This is the list of <CODE>Row</CODE>s. */    private ArrayList rows = new ArrayList();    // these variables contain the layout of the table/** This Empty Cell contains the DEFAULT layout of each Cell added with the method addCell(String content). */    private Cell defaultLayout = new Cell(true);/** This is the number of the last row of the table headers. */    private int lastHeaderRow = -1;/** This is the horizontal alignment. */    private int alignment = Element.ALIGN_CENTER;/** This is cellpadding. */    private float cellpadding;/** This is cellspacing. */    private float cellspacing;/** This is the width of the table (in percent of the available space). */    private float widthPercentage = 80;    // member variable added by Evelyne De Cordier/** This is the width of the table (in pixels). */    private String absWidth = "";/** This is an array containing the widths (in percentages) of every column. */    private float[] widths;/** Boolean to track errors (some checks will be performed) */    boolean mDebug = false;/** Boolean to track if a table was inserted (to avoid unnecessary computations afterwards) */    boolean mTableInserted = false;/** * Boolean to automatically fill empty cells before a table is rendered *  (takes CPU so may be set to false in case of certainty) */    boolean mAutoFillEmptyCells = false;/** If true this table may not be split over two pages. */    boolean tableFitsPage = false;/** If true cells may not be split over two pages. */    boolean cellsFitPage = false;/** This is the offset of the table. */    float offset = Float.NaN;/** contains the attributes that are added to each odd (or even) row */    protected Hashtable alternatingRowAttributes = null;    // constructors/** * Constructs a <CODE>Table</CODE> with a certain number of columns. * * @param       columns         The number of columns in the table * @throws      BadElementException if the creator was called with less than 1 column */    public Table(int columns) throws BadElementException {        this(columns, 1);    }/** * Constructs a <CODE>Table</CODE> with a certain number of columns * and a certain number of <CODE>Row</CODE>s. * * @param       columns         The number of columns in the table * @param       rows            The number of rows * @throws      BadElementException if the creator was called with less than 1 column */    public Table(int columns, int rows) throws BadElementException {        // a Rectangle is create with BY DEFAULT a border with a width of 1        super(0, 0, 0, 0);        setBorder(BOX);        setBorderWidth(1);        defaultLayout.setBorder(BOX);        // a table should have at least 1 column        if (columns <= 0) {            throw new BadElementException("A table should have at least 1 column.");        }        this.columns = columns;        // a certain number of rows are created        for (int i = 0; i < rows; i++) {            this.rows.add(new Row(columns));        }        curPosition = new Point(0, 0);        // the DEFAULT widths are calculated        widths = new float[columns];        float width = 100f / columns;        for (int i = 0; i < columns; i++) {            widths[i] = width;        }    }/** * Returns a <CODE>Table</CODE> that has been constructed taking in account * the value of some <VAR>attributes</VAR>. * * @param    attributes        Some attributes */    public Table(Properties attributes) {        // a Rectangle is create with BY DEFAULT a border with a width of 1        super(0, 0, 0, 0);        setBorder(BOX);        setBorderWidth(1);        defaultLayout.setBorder(BOX);        String value = (String)attributes.remove(ElementTags.COLUMNS);        if (value == null) {            columns = 1;        }        else {            columns = Integer.parseInt(value);            if (columns <= 0) {                columns = 1;            }        }        rows.add(new Row(columns));        curPosition.setLocation(0, curPosition.y);        if ((value = (String)attributes.remove(ElementTags.LASTHEADERROW)) != null) {            setLastHeaderRow(Integer.parseInt(value));        }        if ((value = (String)attributes.remove(ElementTags.ALIGN)) != null) {            setAlignment(value);        }        if ((value = (String)attributes.remove(ElementTags.CELLSPACING)) != null) {            setSpacing(Float.valueOf(value + "f").floatValue());        }        if ((value = (String)attributes.remove(ElementTags.CELLPADDING)) != null) {            setPadding(Float.valueOf(value + "f").floatValue());        }        if ((value = (String)attributes.remove(ElementTags.OFFSET)) != null) {            setOffset(Float.valueOf(value + "f").floatValue());        }        if ((value = (String)attributes.remove(ElementTags.WIDTH)) != null) {            if (value.endsWith("%"))                setWidth(Float.valueOf(value.substring(0, value.length() - 1) + "f").floatValue());            else                setAbsWidth(value);        }        widths = new float[columns];        for (int i = 0; i < columns; i++) {            widths[i] = 0;        }        if ((value = (String)attributes.remove(ElementTags.WIDTHS)) != null) {            StringTokenizer widthTokens = new StringTokenizer(value, ";");            int i = 0;            while (widthTokens.hasMoreTokens()) {                value = (String) widthTokens.nextToken();                widths[i] = Float.valueOf(value + "f").floatValue();                i++;            }            columns = i;        }        if ((value = (String)attributes.remove(ElementTags.TABLEFITSPAGE)) != null) {            tableFitsPage = new Boolean(value).booleanValue();        }        if ((value = (String)attributes.remove(ElementTags.CELLSFITPAGE)) != null) {            cellsFitPage = new Boolean(value).booleanValue();        }        if ((value = (String)attributes.remove(ElementTags.BORDERWIDTH)) != null) {            setBorderWidth(Float.valueOf(value + "f").floatValue());        }        int border = 0;        if ((value = (String)attributes.remove(ElementTags.LEFT)) != null) {            if (new Boolean(value).booleanValue()) border |= Rectangle.LEFT;        }        if ((value = (String)attributes.remove(ElementTags.RIGHT)) != null) {            if (new Boolean(value).booleanValue()) border |= Rectangle.RIGHT;        }        if ((value = (String)attributes.remove(ElementTags.TOP)) != null) {            if (new Boolean(value).booleanValue()) border |= Rectangle.TOP;        }        if ((value = (String)attributes.remove(ElementTags.BOTTOM)) != null) {            if (new Boolean(value).booleanValue()) border |= Rectangle.BOTTOM;        }        setBorder(border);        String r = (String)attributes.remove(ElementTags.RED);        String g = (String)attributes.remove(ElementTags.GREEN);        String b = (String)attributes.remove(ElementTags.BLUE);        if (r != null || g != null || b != null) {            int red = 0;            int green = 0;            int blue = 0;            if (r != null) red = Integer.parseInt(r);            if (g != null) green = Integer.parseInt(g);            if (b != null) blue = Integer.parseInt(b);            setBorderColor(new Color(red, green, blue));        }        else if ((value = attributes.getProperty(ElementTags.BORDERCOLOR)) != null) {            setBorderColor(MarkupParser.decodeColor(value));        }        r = (String)attributes.remove(ElementTags.BGRED);        g = (String)attributes.remove(ElementTags.BGGREEN);        b = (String)attributes.remove(ElementTags.BGBLUE);        if (r != null || g != null || b != null) {            int red = 0;            int green = 0;            int blue = 0;            if (r != null) red = Integer.parseInt(r);            if (g != null) green = Integer.parseInt(g);            if (b != null) blue = Integer.parseInt(b);            setBackgroundColor(new Color(red, green, blue));        }        else if ((value = (String)attributes.remove(ElementTags.BACKGROUNDCOLOR)) != null) {            setBackgroundColor(MarkupParser.decodeColor(value));        }        if ((value = (String)attributes.remove(ElementTags.GRAYFILL)) != null) {            setGrayFill(Float.valueOf(value + "f").floatValue());        }        if (attributes.size() > 0) setMarkupAttributes(attributes);    }    // implementation of the Element-methods/** * Processes the element by adding it (or the different parts) to an * <CODE>ElementListener</CODE>. * * @param       listener        an <CODE>ElementListener</CODE> * @return <CODE>true</CODE> if the element was processed successfully */    public boolean process(ElementListener listener) {        try {            return listener.add(this);        }        catch(DocumentException de) {            return false;        }    }/** * Performs extra checks when executing table code (currently only when cells are added). */    public void setDebug(boolean aDebug) {        mDebug = aDebug;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩va亚洲va欧美va久久| 另类欧美日韩国产在线| 成人ar影院免费观看视频| 精品成人在线观看| 久久99精品久久久久| 精品国产乱码久久久久久图片| 久久精品72免费观看| 久久亚洲一区二区三区明星换脸 | 精品日韩一区二区三区| 久久国内精品视频| 欧美激情一区二区三区四区| av亚洲精华国产精华精华| 樱桃国产成人精品视频| 欧美日本在线观看| 精品在线免费视频| 成人免费一区二区三区视频| 欧美亚洲一区二区三区四区| 蜜桃精品在线观看| 国产精品青草久久| 欧美视频中文字幕| 国产激情精品久久久第一区二区 | 久久先锋影音av鲁色资源| 成人免费的视频| 五月天激情综合网| 国产欧美日韩卡一| 欧美日韩你懂的| 国产精品1024| 亚洲va欧美va天堂v国产综合| 日韩女优制服丝袜电影| kk眼镜猥琐国模调教系列一区二区 | 欧洲生活片亚洲生活在线观看| 天天操天天干天天综合网| 国产亚洲综合在线| 欧美中文字幕一区二区三区| 国产一区二区主播在线| 亚洲一区二三区| 国产蜜臀97一区二区三区 | 不卡一卡二卡三乱码免费网站| 亚洲最新视频在线播放| 久久这里只精品最新地址| 在线精品国精品国产尤物884a| 国产在线播放一区三区四| 亚洲一级二级三级| 国产精品美女一区二区三区| 日韩色在线观看| 91国模大尺度私拍在线视频| 国产精品中文字幕日韩精品 | 国产麻豆精品theporn| 午夜激情一区二区| 亚洲人快播电影网| 国产拍揄自揄精品视频麻豆| 日韩精品一区二区三区在线| 欧美日韩一级黄| 91社区在线播放| 粉嫩av一区二区三区粉嫩| 日韩高清中文字幕一区| 亚洲综合在线五月| 最新日韩在线视频| 亚洲国产成人私人影院tom| 欧美成人国产一区二区| 7777精品伊人久久久大香线蕉最新版| 91一区二区在线观看| 成人免费毛片a| 风间由美一区二区三区在线观看| 久久精品72免费观看| 久久精工是国产品牌吗| 麻豆高清免费国产一区| 男男视频亚洲欧美| 蜜臀av亚洲一区中文字幕| 性做久久久久久久免费看| 午夜久久久久久久久久一区二区| 亚洲综合一二三区| 一区二区三区四区精品在线视频| 亚洲欧美在线视频观看| 综合久久国产九一剧情麻豆| 国产精品美女久久久久久久| 中文字幕成人在线观看| 国产精品天干天干在观线| 国产视频在线观看一区二区三区| 国产日韩欧美激情| 国产精品久久毛片av大全日韩| 久久久久久久国产精品影院| 久久精品夜色噜噜亚洲aⅴ| 国产亚洲欧美在线| 国产精品久久久久影院亚瑟 | 国产精品初高中害羞小美女文| 中文字幕电影一区| 国产精品久久久久久久久果冻传媒| 国产欧美一区二区三区沐欲| 国产精品久久久久久久久动漫| 亚洲视频1区2区| 亚洲第一狼人社区| 麻豆精品久久久| 国产高清久久久久| 91麻豆免费看| 91精品一区二区三区久久久久久| 日韩一区二区免费高清| 久久久精品国产免大香伊| 国产精品国产三级国产专播品爱网| 国产精品乱人伦中文| 亚洲一区二区三区精品在线| 舔着乳尖日韩一区| 国产美女娇喘av呻吟久久| av中文一区二区三区| 欧美日韩精品一区二区三区蜜桃| 日韩一区二区三区免费观看| 国产欧美一区二区三区在线老狼| 亚洲人亚洲人成电影网站色| 手机精品视频在线观看| 国产精品伊人色| 欧美综合在线视频| 2020国产成人综合网| 一区二区三区日韩欧美| 美女脱光内衣内裤视频久久影院| 成人一区二区三区视频| 欧美日韩视频第一区| 国产亚洲欧美一区在线观看| 一区二区三区视频在线看| 精品午夜久久福利影院| 91丝袜美腿高跟国产极品老师 | 色婷婷狠狠综合| 日韩欧美国产一二三区| 综合久久综合久久| 开心九九激情九九欧美日韩精美视频电影| 国产成人免费在线观看不卡| 精品视频一区三区九区| 国产女主播在线一区二区| 丝袜美腿亚洲一区| 99免费精品在线观看| 日韩一二三区视频| 亚洲小少妇裸体bbw| 成人一区二区三区| xvideos.蜜桃一区二区| 五月天欧美精品| 在线亚洲+欧美+日本专区| 国产日韩高清在线| 久久av中文字幕片| 欧美日本一道本在线视频| 国产精品久久久久久久岛一牛影视 | 日韩精品一区在线观看| 一区二区三区精品在线| 成人亚洲精品久久久久软件| 欧美一区二区三区四区五区 | 91亚洲午夜精品久久久久久| 日韩欧美在线网站| 亚洲成人精品影院| 色婷婷精品大视频在线蜜桃视频| 欧美国产日本韩| 国产一区二区三区黄视频 | 久久综合资源网| 日韩国产欧美在线视频| 欧洲精品一区二区| 亚洲色图视频免费播放| 丁香六月综合激情| 久久久久久久综合狠狠综合| 久久精品二区亚洲w码| 欧美一区中文字幕| 日本不卡视频一二三区| 欧美日韩午夜在线| 亚洲国产欧美一区二区三区丁香婷| 成年人午夜久久久| 中文字幕在线不卡国产视频| 国产91在线看| 中文字幕不卡在线观看| 成人福利在线看| 国产精品美女久久久久aⅴ国产馆| 国产一区二区三区电影在线观看| 日韩一区二区三| 国产麻豆精品在线| 国产精品久久久一区麻豆最新章节| 春色校园综合激情亚洲| 亚洲欧洲美洲综合色网| 91香蕉国产在线观看软件| 1024亚洲合集| 色域天天综合网| 亚洲成人先锋电影| 欧美一区二区久久久| 精品一区二区日韩| 国产精品―色哟哟| 91行情网站电视在线观看高清版| 亚洲国产婷婷综合在线精品| 欧美猛男男办公室激情| 青青青爽久久午夜综合久久午夜| 日韩精品一区国产麻豆| 国产一区二区三区日韩| 国产精品福利av| 欧美视频一二三区| 麻豆精品国产91久久久久久| 国产日韩欧美一区二区三区综合| 91在线播放网址| 五月天一区二区| 久久综合九色综合久久久精品综合| 国产成人免费在线视频| 一区二区三区欧美| 欧美一区二区三区四区五区| 国产剧情一区在线| 亚洲一区二区在线播放相泽| 91精品婷婷国产综合久久性色| 激情文学综合丁香| 亚洲精品老司机|