Package java.text

Examples of java.text.NumberFormat.format()


            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue((long) (contentHeight * scaleFactor)),
                safariLengthFix)), PT_UNIT);
      }
      else
      {
        styleBuilder.append(WIDTH_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(nodeWidth), safariLengthFix)), PT_UNIT);
        styleBuilder.append(HEIGHT_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(nodeHeight), safariLengthFix)), PT_UNIT);
      }
    }
View Full Code Here


      }
      else
      {
        styleBuilder.append(WIDTH_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(nodeWidth), safariLengthFix)), PT_UNIT);
        styleBuilder.append(HEIGHT_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(nodeHeight), safariLengthFix)), PT_UNIT);
      }
    }
    else
    {
View Full Code Here

      }

      if (contentWidth == 0 && contentHeight == 0)
      {
        // Drawable content has no intrinsic height or width, therefore we must not use the content size at all.
        styleBuilder.append(WIDTH_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(nodeWidth), safariLengthFix)), PT_UNIT);
        styleBuilder.append(HEIGHT_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(nodeHeight), safariLengthFix)), PT_UNIT);
      }
      else
View Full Code Here

      if (contentWidth == 0 && contentHeight == 0)
      {
        // Drawable content has no intrinsic height or width, therefore we must not use the content size at all.
        styleBuilder.append(WIDTH_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(nodeWidth), safariLengthFix)), PT_UNIT);
        styleBuilder.append(HEIGHT_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(nodeHeight), safariLengthFix)), PT_UNIT);
      }
      else
      {
        final long width = Math.min(nodeWidth, contentWidth);
View Full Code Here

      }
      else
      {
        final long width = Math.min(nodeWidth, contentWidth);
        final long height = Math.min(nodeHeight, contentHeight);
        styleBuilder.append(WIDTH_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(width), safariLengthFix)), PT_UNIT);
        styleBuilder.append(HEIGHT_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(height), safariLengthFix)), PT_UNIT);
      }
    }
View Full Code Here

      {
        final long width = Math.min(nodeWidth, contentWidth);
        final long height = Math.min(nodeHeight, contentHeight);
        styleBuilder.append(WIDTH_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(width), safariLengthFix)), PT_UNIT);
        styleBuilder.append(HEIGHT_STYLE, pointConverter.format
            (HtmlPrinter.fixLengthForSafari(StrictGeomUtility.toExternalValue(height), safariLengthFix)), PT_UNIT);
      }
    }
    return styleBuilder;
  }
View Full Code Here

          colWidths[col] = pointConverter.format(100 - totalWidth);
        }
        else
        {
          totalWidth += colWidth;
          colWidths[col] = pointConverter.format(colWidth);
        }
      }
    }
    else
    {
View Full Code Here

      {
        final int width = (int) StrictGeomUtility.toExternalValue(sheetLayout.getCellWidth(col, col + 1));
        final double colWidth = fixLengthForSafari(Math.max(1, width));
        if (col == colCount - 1)
        {
          colWidths[col] = pointConverter.format(fullWidth - totalWidth);
        }
        else
        {
          totalWidth += colWidth;
          colWidths[col] = pointConverter.format(colWidth);
View Full Code Here

          colWidths[col] = pointConverter.format(fullWidth - totalWidth);
        }
        else
        {
          totalWidth += colWidth;
          colWidths[col] = pointConverter.format(colWidth);
        }
      }
    }

    for (int col = 0; col < colCount; col++)
View Full Code Here

      {
        final int width = (int) StrictGeomUtility.toExternalValue(sheetLayout.getCellWidth(col, col + 1));
        final double colWidth = fixLengthForSafari(Math.max(1, width * 100.0d / fullWidth));
        if (col == colCount - 1)
        {
          colWidths[col] = pointConverter.format(100 - totalWidth);
        }
        else
        {
          totalWidth += colWidth;
          colWidths[col] = pointConverter.format(colWidth);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.