Package ket.display.box

Examples of ket.display.box.BoxGap


  public Box toBox(Argument argument, Vector<Box> boxArgs, long settings, ColourScheme colourScheme) {
    if (boxArgs.size()>2) {
      return super.toBox(argument, boxArgs, settings, colourScheme);
    }
    BoxGraphic bar = new BoxGraphic(argument, 0L, BoxGraphic.HORIZONTAL_LINE);
    Box above = new BoxGap(argument, 0L, bar, 0.0, 1.0, 0.0, 0.0);
    Box below = new BoxGap(argument, 0L, bar, 0.0, 1.0, 0.0, 0.0);
    boxArgs.add(1, above);
    boxArgs.add(2, bar);
    boxArgs.add(3, below);
    Box box = BoxTools.centredVerticalBoxList(argument, settings, boxArgs);
    bar.setProperty(Box.HORIZONTAL_STRETCH);
View Full Code Here


  }

  @Override
  public Box toBox(Argument argument, Vector<Box> boxArgs, long settings, ColourScheme colourScheme) {
    BoxGraphic left1 = new BoxGraphic(argument, 0L, BoxGraphic.VERTICAL_LINE);
    Box left2 = new BoxGap(argument, 0L, left1, 1.0, 1.0, 0.0, 0.0);
    BoxGraphic left3 = new BoxGraphic(argument, 0L, BoxGraphic.VERTICAL_LINE);
    BoxGraphic right1 = new BoxGraphic(argument, 0L, BoxGraphic.VERTICAL_LINE);
    Box right2 = new BoxGap(argument, 0L, left1, 1.0, 1.0, 0.0, 0.0);
    BoxGraphic right3 = new BoxGraphic(argument, 0L, BoxGraphic.VERTICAL_LINE);
    Vector<Box> list = new Vector<Box>();
    list.add(left1);
    list.add(left2);
    list.add(left3);
    list.add(boxArgs.firstElement());
    list.add(right1);
    list.add(right2);
    list.add(right3);
    Box box = BoxTools.centredHorizontalBoxList(argument, settings, list);
    left1.setProperty(Box.VERTICAL_STRETCH);
    left2.setProperty(Box.VERTICAL_STRETCH);
    left3.setProperty(Box.VERTICAL_STRETCH);
    right1.setProperty(Box.VERTICAL_STRETCH);
    right2.setProperty(Box.VERTICAL_STRETCH);
    right3.setProperty(Box.VERTICAL_STRETCH);
    box.setProperty(settings);
    return box;
  }
View Full Code Here

TOP

Related Classes of ket.display.box.BoxGap

Copyright © 2018 www.massapicom. 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.