1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
|
package pages.historique.excel;
import jxl.format.Alignment;
import jxl.write.WritableCellFormat;
import jxl.write.WritableFont;
public class GlobalExcel
{
private static final WritableFont.FontName STANDARD_FONT_NAME = WritableFont.ARIAL;
private static final Integer STANDARD_FONT_SIZE = 12;
public static final WritableCellFormat FORMAT_TH = getFORMAT_TH();
private static WritableCellFormat getFORMAT_TH()
{
try
{
if (FORMAT_TH == null)
{
WritableCellFormat format = new WritableCellFormat(
new WritableFont(STANDARD_FONT_NAME,
STANDARD_FONT_SIZE, WritableFont.BOLD, false));
format.setAlignment(Alignment.CENTRE);
return format;
}
}
catch (Exception e)
{
e.printStackTrace();
}
return FORMAT_TH;
}
} |