1 19 20 package jxl.write.biff; 21 22 import jxl.write.WriteException; 23 import jxl.biff.FontRecord; 24 import jxl.format.Font; 25 26 30 public class WritableFontRecord extends FontRecord 31 { 32 43 protected WritableFontRecord(String fn, int ps, int bold, boolean it, 44 int us, int ci, int ss) 45 { 46 super(fn, ps, bold, it, us, ci, ss); 47 } 48 49 54 protected WritableFontRecord(Font f) 55 { 56 super(f); 57 } 58 59 60 66 protected void setPointSize(int pointSize) throws WriteException 67 { 68 if (isInitialized()) 69 { 70 throw new JxlWriteException(JxlWriteException.formatInitialized); 71 } 72 73 super.setFontPointSize(pointSize); 74 } 75 76 82 protected void setBoldStyle(int boldStyle) throws WriteException 83 { 84 if (isInitialized()) 85 { 86 throw new JxlWriteException(JxlWriteException.formatInitialized); 87 } 88 89 super.setFontBoldStyle(boldStyle); 90 } 91 92 99 protected void setItalic(boolean italic) throws WriteException 100 { 101 if (isInitialized()) 102 { 103 throw new JxlWriteException(JxlWriteException.formatInitialized); 104 } 105 106 super.setFontItalic(italic); 107 } 108 109 116 protected void setUnderlineStyle(int us) throws WriteException 117 { 118 if (isInitialized()) 119 { 120 throw new JxlWriteException(JxlWriteException.formatInitialized); 121 } 122 123 super.setFontUnderlineStyle(us); 124 } 125 126 133 protected void setColour(int colour) throws WriteException 134 { 135 if (isInitialized()) 136 { 137 throw new JxlWriteException(JxlWriteException.formatInitialized); 138 } 139 140 super.setFontColour(colour); 141 } 142 143 150 protected void setScriptStyle(int scriptStyle) throws WriteException 151 { 152 if (isInitialized()) 153 { 154 throw new JxlWriteException(JxlWriteException.formatInitialized); 155 } 156 157 super.setFontScriptStyle(scriptStyle); 158 } 159 160 166 protected void setStruckout(boolean os) throws WriteException 167 { 168 if (isInitialized()) 169 { 170 throw new JxlWriteException(JxlWriteException.formatInitialized); 171 } 172 super.setFontStruckout(os); 173 } 174 } 175 | Popular Tags |