bug 58576: rename canComputeColumnWidht to canComputeColumnWidth

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1712219 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Javen O'Neal 2015-11-03 07:23:09 +00:00
parent 3b88a60498
commit 265d198612
4 changed files with 6 additions and 6 deletions

View File

@ -275,7 +275,7 @@ public class SheetUtil {
* @param font The Font that is used in the Cell
* @return true if computing the size for this Font will succeed, false otherwise
*/
public static boolean canComputeColumnWidht(Font font) {
public static boolean canComputeColumnWidth(Font font) {
// not sure what is the best value sample-here, only "1" did not work on some platforms...
AttributedString str = new AttributedString("1w");
copyAttributes(font, str, 0, "1w".length());

View File

@ -299,7 +299,7 @@ public final class TestXSSFFont extends BaseTestFont{
Workbook wb = new XSSFWorkbook();
// cannot check on result because on some machines we get back false here!
SheetUtil.canComputeColumnWidht(wb.getFontAt((short)0));
SheetUtil.canComputeColumnWidth(wb.getFontAt((short)0));
wb.close();
}
@ -310,6 +310,6 @@ public final class TestXSSFFont extends BaseTestFont{
font.setFontName("some non existing font name");
// Even with invalid fonts we still get back useful data most of the time...
SheetUtil.canComputeColumnWidht(font);
SheetUtil.canComputeColumnWidth(font);
}
}

View File

@ -381,7 +381,7 @@ public abstract class BaseTestBugzillaIssues {
// autoSize will fail if required fonts are not installed, skip this test then
Font font = wb.getFontAt(cell0.getCellStyle().getFontIndex());
Assume.assumeTrue("Cannot verify autoSizeColumn() because the necessary Fonts are not installed on this machine: " + font,
SheetUtil.canComputeColumnWidht(font));
SheetUtil.canComputeColumnWidth(font));
assertEquals("Expecting no indentation in this test",
0, cell0.getCellStyle().getIndention());
@ -399,7 +399,7 @@ public abstract class BaseTestBugzillaIssues {
double widthBeforeCol = SheetUtil.getColumnWidth(sheet, 0, false);
String info = widthManual + "/" + widthBeforeCell + "/" + widthBeforeCol + "/" +
SheetUtil.canComputeColumnWidht(font) + "/" + computeCellWidthFixed(font, "1") + "/" + computeCellWidthFixed(font, "w") + "/" +
SheetUtil.canComputeColumnWidth(font) + "/" + computeCellWidthFixed(font, "1") + "/" + computeCellWidthFixed(font, "w") + "/" +
computeCellWidthFixed(font, "1w") + "/" + computeCellWidthFixed(font, "0000") + "/" + computeCellWidthFixed(font, longValue);
assertTrue("Expected to have cell width > 0 when computing manually, but had " + info, widthManual > 0);
assertTrue("Expected to have cell width > 0 BEFORE auto-size, but had " + info, widthBeforeCell > 0);

View File

@ -72,7 +72,7 @@ public final class TestSheetUtil extends TestCase {
Workbook wb = new HSSFWorkbook();
// cannot check on result because on some machines we get back false here!
SheetUtil.canComputeColumnWidht(wb.getFontAt((short)0));
SheetUtil.canComputeColumnWidth(wb.getFontAt((short)0));
wb.close();
}