Exemplo n.º 1
0
 private void encodeNameAndConditionDefined(
     SheetGraphics graphics, VirtueFlawContent content, Bounds textBounds)
     throws DocumentException {
   Phrase phrase = new Phrase();
   phrase.add(new Chunk(content.getVirtueFlawName() + ": ", createNameFont(graphics)));
   phrase.add(new Chunk(content.getLimitBreakCondition(), createConditionFont(graphics)));
   graphics
       .createSimpleColumn(textBounds)
       .withLeading(REDUCED_LINE_HEIGHT)
       .andTextPart(phrase)
       .encode();
 }
Exemplo n.º 2
0
 private void encodeOnlyNameDefined(
     SheetGraphics graphics, Bounds bounds, VirtueFlawContent content, Bounds textBounds)
     throws DocumentException {
   Phrase phrase = new Phrase();
   phrase.add(new Chunk(content.getVirtueFlawName(), createNameFont(graphics)));
   float baseLine =
       graphics
           .createSimpleColumn(textBounds)
           .withLeading(REDUCED_LINE_HEIGHT)
           .andTextPart(phrase)
           .encode()
           .getYLine();
   encodeLines(graphics, bounds, REDUCED_LINE_HEIGHT, baseLine);
 }