Esempio n. 1
0
 /**
  * Resets all member variables within this object recursively
  *
  * <p>Note: Manually written
  */
 public final void initialize() {
   // setBackground( ColorDefinitionImpl.WHITE( ) );
   final LineAttributes lia =
       LineAttributesImpl.create(ColorDefinitionImpl.BLACK(), LineStyle.SOLID_LITERAL, 0);
   lia.setVisible(false);
   setOutline(lia);
   setInsets(InsetsImpl.create(0, 0, 0, 0));
 }
Esempio n. 2
0
  protected final void initialize() {
    // Outline
    LineAttributes lia =
        LineAttributesImpl.create(ColorDefinitionImpl.BLACK(), LineStyle.SOLID_LITERAL, 1);
    setLineAttributes(lia);

    // Label
    Label lb = LabelImpl.create();
    setLabel(lb);

    // MAJOR GRID
    Grid gr = ComponentFactory.eINSTANCE.createGrid();
    lia =
        LineAttributesImpl.create(
            ColorDefinitionImpl.create(196, 196, 196), LineStyle.SOLID_LITERAL, 1);
    lia.setVisible(true);
    gr.setLineAttributes(lia);
    lia =
        LineAttributesImpl.create(
            ColorDefinitionImpl.create(196, 196, 196), LineStyle.SOLID_LITERAL, 1);
    gr.setTickAttributes(lia);
    gr.setTickStyle(TickStyle.BELOW_LITERAL);
    setMajorGrid(gr);

    // MINOR GRID
    gr = ComponentFactory.eINSTANCE.createGrid();
    lia =
        LineAttributesImpl.create(
            ColorDefinitionImpl.create(225, 225, 225), LineStyle.SOLID_LITERAL, 1);
    lia.setVisible(false);
    gr.setLineAttributes(lia);
    lia =
        LineAttributesImpl.create(
            ColorDefinitionImpl.create(225, 225, 225), LineStyle.SOLID_LITERAL, 1);
    lia.setVisible(false);
    gr.setTickAttributes(lia);
    gr.setTickStyle(TickStyle.BELOW_LITERAL);
    setMinorGrid(gr);

    // SCALE
    Scale sc = ComponentFactory.eINSTANCE.createScale();
    sc.setMinorGridsPerUnit(5);
    setScale(sc);
  }