Search in sources :

Example 16 with WritableFont

use of jxl.write.WritableFont in project cubrid-manager by CUBRID.

the class ExportTableDefinitionLayoutType method getNormalLeftAlignCellStyle.

/**
	 * GetNormalLeftAlignCellStyle
	 *
	 * @return WritableCellFormat
	 */
public static WritableCellFormat getNormalLeftAlignCellStyle() {
    WritableFont font = new WritableFont(WritableFont.ARIAL, 10);
    WritableCellFormat format = new WritableCellFormat(font);
    try {
        format.setAlignment(jxl.format.Alignment.LEFT);
        format.setVerticalAlignment(jxl.format.VerticalAlignment.TOP);
        format.setBorder(Border.ALL, BorderLineStyle.THIN, Colour.BLACK);
        format.setWrap(true);
    } catch (WriteException e) {
        LOGGER.error("", e);
    }
    return format;
}
Also used : WriteException(jxl.write.WriteException) WritableFont(jxl.write.WritableFont) WritableCellFormat(jxl.write.WritableCellFormat)

Example 17 with WritableFont

use of jxl.write.WritableFont in project cubrid-manager by CUBRID.

the class ExportTableDefinitionLayoutType method getBoldCenterAlignCellStyle.

/**
	 * GetNormalCell
	 *
	 * @return WritableCellFormat
	 */
public static WritableCellFormat getBoldCenterAlignCellStyle() {
    WritableFont font = new WritableFont(WritableFont.ARIAL, 10);
    WritableCellFormat format = new WritableCellFormat(font);
    try {
        font.setBoldStyle(WritableFont.BOLD);
        format.setAlignment(jxl.format.Alignment.CENTRE);
        format.setVerticalAlignment(jxl.format.VerticalAlignment.CENTRE);
        format.setBorder(Border.ALL, BorderLineStyle.THIN, Colour.BLACK);
        format.setBackground(jxl.format.Colour.GREY_25_PERCENT);
        format.setWrap(true);
    } catch (WriteException e) {
        LOGGER.error("", e);
    }
    return format;
}
Also used : WriteException(jxl.write.WriteException) WritableFont(jxl.write.WritableFont) WritableCellFormat(jxl.write.WritableCellFormat)

Example 18 with WritableFont

use of jxl.write.WritableFont in project cubrid-manager by CUBRID.

the class RunSQLEventHandler method getNormalCell.

/**
	 * Return the normal cell format.
	 *
	 * @return WritableCellFormat
	 */
public static WritableCellFormat getNormalCell() {
    // FIXME logic code move to core module
    WritableFont font = new WritableFont(WritableFont.TIMES, 12);
    WritableCellFormat format = new WritableCellFormat(font);
    try {
        format.setAlignment(jxl.format.Alignment.LEFT);
        format.setVerticalAlignment(jxl.format.VerticalAlignment.CENTRE);
        format.setBorder(Border.ALL, BorderLineStyle.THIN, Colour.BLACK);
        format.setWrap(true);
    } catch (WriteException e) {
        LOGGER.error(e.getMessage(), e);
    }
    return format;
}
Also used : WriteException(jxl.write.WriteException) WritableFont(jxl.write.WritableFont) WritableCellFormat(jxl.write.WritableCellFormat)

Aggregations

WritableCellFormat (jxl.write.WritableCellFormat)18 WritableFont (jxl.write.WritableFont)18 WriteException (jxl.write.WriteException)13 Label (jxl.write.Label)4 WorkbookSettings (jxl.WorkbookSettings)3 WritableSheet (jxl.write.WritableSheet)3 WritableWorkbook (jxl.write.WritableWorkbook)3 CubridDatabase (com.cubrid.common.ui.spi.model.CubridDatabase)1 DatabaseEditorConfig (com.cubrid.common.ui.spi.model.DatabaseEditorConfig)1 DatabaseInfo (com.cubrid.cubridmanager.core.cubrid.database.model.DatabaseInfo)1 CUBRIDResultSetMetaDataProxy (com.cubrid.jdbc.proxy.driver.CUBRIDResultSetMetaDataProxy)1 FileNotFoundException (java.io.FileNotFoundException)1 IOException (java.io.IOException)1 UnsupportedEncodingException (java.io.UnsupportedEncodingException)1 SQLException (java.sql.SQLException)1 Timestamp (java.sql.Timestamp)1 ParseException (java.text.ParseException)1 ArrayList (java.util.ArrayList)1 Collection (java.util.Collection)1 Date (java.util.Date)1