Package org.jfree.layouting.renderer.border

Examples of org.jfree.layouting.renderer.border.RenderLength.resolve()


      {
        node.setMaximumBoxWidth(contentSize.getWidth());
      }
      else
      {
        node.setMaximumBoxWidth(requestedWidth.resolve(contentSize.getWidth()));
      }

      node.setMinimumChunkWidth(0);
      // replaced content cannot have any childs anymore, so it is safe to
      // set this flag to an unconditional true.
View Full Code Here


      {
        node.setMaximumBoxWidth(contentSize.getWidth());
      }
      else
      {
        node.setMaximumBoxWidth(requestedWidth.resolve(contentSize.getWidth()));
      }

      node.setMinimumChunkWidth(0);
      // replaced content cannot have any childs anymore, so it is safe to
      // set this flag to an unconditional true.
View Full Code Here

      {
        // A percentage is now relative to the intrinsinc size.
        // And yes, I'm aware that this is not what the standard says ..
        final RenderLength blockContextWidth =
            node.getComputedLayoutProperties().getBlockContextWidth();
        height = node.getRequestedHeight().resolve(blockContextWidth.resolve(0));
      }
    }
    else
    {
      // width is not auto.
View Full Code Here

        if (contentSize.getWidth() > 0)
        {
          final RenderLength blockContextWidth =
              node.getComputedLayoutProperties().getBlockContextWidth();
          final long computedWidth =
              node.getRequestedWidth().resolve(blockContextWidth.resolve(0));
          // Requested height must be computed to preserve the aspect ratio.
          height = computedWidth * contentSize.getHeight()/contentSize.getWidth();
        }
        else
        {
View Full Code Here

      else
      {
        // height is something fixed ..
        final RenderLength blockContextWidth =
            node.getComputedLayoutProperties().getBlockContextWidth();
        height = node.getRequestedHeight().resolve(blockContextWidth.resolve(0));
      }
    }
  }

  public long getBaselineDistance(final int baseline)
View Full Code Here

    }

    final RenderLength baselineShiftResolved = node.getBaselineShiftResolved();
    if (baselineShiftResolved != null)
    {
      return baselineShiftResolved.resolve(lineHeight);
    }

    return 0;
  }
View Full Code Here

    final RenderLength alLength = node.getAlignmentAdjustResolved();
    if (alLength != null)
    {
      /// this is not fully true. The line height depends on the context ..
      return alLength.resolve(lineHeight);
    }

    return context.getBaselineDistance(defaultBaseLine);
  }
View Full Code Here

    // Check the height. Set the height.
    final ComputedLayoutProperties clp = box.getComputedLayoutProperties();
    final RenderLength computedWidth = clp.getComputedWidth();
    final RenderLength preferredHeight = box.getBoxDefinition().getPreferredHeight();
    final long computedHeight =
        preferredHeight.resolve(computedWidth.resolve(0));

    final ComputedLayoutProperties blp = box.getComputedLayoutProperties();
    final long insetBottom = blp.getBorderBottom() + blp.getPaddingBottom();

    final RenderNode lastChildNode = box.getLastChild();
View Full Code Here

    final long contentAreaY1 = inlineRenderBox.getY() + insetTop;
    final RenderLength lineHeight = inlineRenderBox.getLineHeight();
    final ComputedLayoutProperties clp = inlineRenderBox.getComputedLayoutProperties();
    final RenderLength bcw = clp.getBlockContextWidth();
    processor.align (boxAlignContext, contentAreaY1,
        lineHeight.resolve(bcw.resolve(0)));
  }

  protected void finishOtherBox(final RenderBox box)
  {
    if (breakState != null)
View Full Code Here

        box.setContentAreaX2(x + leftPadding + box.getMinimumChunkWidth());
      }
    }
    else
    {
      final long contentWidth = computedWidth.resolve(0);
      box.setContentAreaX2(x + leftPadding + contentWidth);
    }
  }

  private long computeX(final RenderNode node)
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.