Package ModalGUI

Examples of ModalGUI.GUIPanelTabbed


    float posY = 10;
    float posX = 10;
    float panelHeight = 120;

    GUIPanelTabbed tabbedPanel = new GUIPanelTabbed(0f, height
        - panelHeight, (int) width, (int) panelHeight, gui);
    gui.add(tabbedPanel);

    //tools
    GUIPanel toolPanel = new GUIPanel(0f, height - panelHeight,
        (int) width, (int) panelHeight, gui);
    tabbedPanel.addTabbedPanel(toolPanel, "tools", gui);

    GUIComponentSet toggleSet = new GUIComponentSet();

    GUIToggle toggle = new GUIToggle(posX, posY, button_width,
        button_height, "gui/draw.png", gui);
View Full Code Here


   
   

    setupGUITabsAll(applet,gui);

    GUIPanelTabbed tabbedPanel = new GUIPanelTabbed(0f, GLOBAL.windowHeight
        - panelHeight, (int) GLOBAL.windowWidth, (int) panelHeight, gui);
    gui.add(tabbedPanel);
    GLOBAL.designToolbarBasic = tabbedPanel;

    //tools
    GUIPanel toolPanel = new GUIPanel(0f,
        GLOBAL.windowHeight - panelHeight, (int) GLOBAL.windowWidth,
        (int) panelHeight, gui);
    tabbedPanel.addTabbedPanel(toolPanel, "tools", gui);


    GUIToggle toggle = new GUIToggle(posX, posY, button_width,
        button_height, "gui/draw.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
View Full Code Here

    sliderToggle.isDown = true;
    sliderToggle.addActionListener(GLOBAL.uiTools, "render3dPreview", null);
    gui.add(sliderToggle);
     */

    GUIPanelTabbed tabbedPanel = new GUIPanelTabbed((GLOBAL.windowWidth-panelWidth)/2.0f, GLOBAL.windowHeight
        - panelHeight, (int) panelWidth, (int) panelHeight, gui);
    gui.add(tabbedPanel);
    GLOBAL.designToolbarAdvanced = tabbedPanel;

    /*
          ______
    _________/tools/____________________________________________________________________________
   
    Tools tab hold tools for manipulating design
    */

    GUIPanel toolPanel = new GUIPanel(0f,0f, (int) tabbedPanel.getWidth(),
        (int) panelHeight, gui);
    tabbedPanel.addTabbedPanel(toolPanel, "tools","gui/GUI_TAB_EDIT_UP.png","gui/GUI_TAB_EDIT_DOWN.png", gui);


    GUIToggle toggle = new GUIToggle(posX, posY, button_width,
        button_height, "gui/draw.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
    toggle.addActionListener(GLOBAL.uiTools.SketchTools, "selectTool",
        SketchTools.DRAW_TOOL);
    toggle.setLabel("brush");
    toggle.label.align = GUILabel.CENTRE;
    toggle.label.layout = GUILabel.UNDER_COMPONENT;
   
    if (GLOBAL.uiTools.SketchTools.getCurrentTool() == SketchTools.DRAW_TOOL)
      toggle.toggleDown();
   
    toolPanel.placeComponent(toggle);

    toggle = new GUIToggle(posX, posY, button_width, button_height,
        "gui/add_leg.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
    toggle.addActionListener(GLOBAL.uiTools.SketchTools, "selectTool",
        SketchTools.LEG_TOOL);
    toggle.setLabel("leg");
    toggle.label.align = GUILabel.CENTRE;
    toggle.label.layout = GUILabel.UNDER_COMPONENT;

    if (GLOBAL.uiTools.SketchTools.getCurrentTool() == SketchTools.LEG_TOOL)
      toggle.toggleDown();
   
    toolPanel.placeComponent(toggle);

    toggle = new GUIToggle(posX, posY, button_width, button_height,
        "gui/select.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
    toggle.addActionListener(GLOBAL.uiTools.SketchTools, "selectTool",
        SketchTools.SELECT_TOOL);
    toggle.setLabel("select");
    toggle.label.align = GUILabel.CENTRE;
    toggle.label.layout = GUILabel.UNDER_COMPONENT;


    if (GLOBAL.uiTools.SketchTools.getCurrentTool() == SketchTools.SELECT_TOOL)
      toggle.toggleDown();
   
    toolPanel.placeComponent(toggle);

    toggle = new GUIToggle(posX, posY, button_width, button_height,
        "gui/draw_path.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
    toggle.addActionListener(GLOBAL.uiTools.SketchTools, "selectTool",
        SketchTools.DRAW_PATH_TOOL);
    toggle.setLabel("path");
    toggle.label.align = GUILabel.CENTRE;
    toggle.label.layout = GUILabel.UNDER_COMPONENT;
    if (GLOBAL.uiTools.SketchTools.getCurrentTool() == SketchTools.DRAW_PATH_TOOL)
      toggle.toggleDown();
   
    toolPanel.placeComponent(toggle);

    toggle = new GUIToggle(posX, posY, button_width, button_height,
        "gui/GUI_OFFSET_PATH_ICON.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
    toggle.addActionListener(GLOBAL.uiTools.SketchTools, "selectTool",
        SketchTools.DRAW_OFFSETPATH_TOOL);
    toggle.setLabel("offset path");
    toggle.label.align = GUILabel.CENTRE;
    toggle.label.layout = GUILabel.UNDER_COMPONENT;
    if (GLOBAL.uiTools.SketchTools.getCurrentTool() == SketchTools.DRAW_OFFSETPATH_TOOL)
      toggle.toggleDown();
    toolPanel.placeComponent(toggle);

    toggle = new GUIToggle(posX, posY, button_width, button_height,
        "gui/bezier.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
    toggle.addActionListener(GLOBAL.uiTools.SketchTools, "selectTool",
        SketchTools.SELECT_BEZIER_TOOL);
    toggle.setLabel("bezier");
    toggle.label.align = GUILabel.CENTRE;
    toggle.label.layout = GUILabel.UNDER_COMPONENT;
    if (GLOBAL.uiTools.SketchTools.getCurrentTool() == SketchTools.SELECT_BEZIER_TOOL)
      toggle.toggleDown();
    toolPanel.placeComponent(toggle);

    toggle = new GUIToggle(posX, posY, button_width, button_height,
        "gui/measure.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
    toggle.addActionListener(GLOBAL.uiTools, "selectTool",
        UITools.MEASURE_TOOL);
    toggle.setLabel("measure");
    toggle.label.align = GUILabel.CENTRE;
    toggle.label.layout = GUILabel.UNDER_COMPONENT;
    if (GLOBAL.uiTools.getCurrentTool() == UITools.MEASURE_TOOL)
      toggle.toggleDown();
    toolPanel.placeComponent(toggle);

    toggle = new GUIToggle(posX, posY, button_width, button_height,
        "gui/scale.png", gui);
    toggle.setComponentSet(GLOBAL.uiTools.toggleSet);
    toggle.addActionListener(GLOBAL.uiTools, "selectTool",
        UITools.SCALE_TOOL);
    toggle.setLabel("scale");
    toggle.label.align = GUILabel.CENTRE;
    toggle.label.layout = GUILabel.UNDER_COMPONENT;

    toolPanel.placeComponent(toggle);

    GUIButton button = new GUIButton(posX, posY, button_width,
        button_height, "gui/undo.png", null, gui);
    button.addActionListener(GLOBAL.uiTools, "undo", UITools.SCALE_TOOL);
    button.setLabel("undo");
    button.label.align = GUILabel.CENTRE;
    button.label.layout = GUILabel.UNDER_COMPONENT;

    toolPanel.placeComponent(button);

    GLOBAL.widgetToolSettings = new WidgetToolSettings(600, 0, 250,
        toolPanel.getHeight(), gui);
    toolPanel.add(GLOBAL.widgetToolSettings);

    /*
     *
     *
     *
     *
        ______
    _______/layers/____________________________________________________________________________

    Selecting and editing layers
    
     */

    GUIPanel LayerPanel = new GUIPanel(0f, 0f, (int) tabbedPanel.getWidth(), (int) panelHeight, gui);
    tabbedPanel.addTabbedPanel(LayerPanel, "layers","gui/GUI_TAB_LAYERS_UP.png","gui/GUI_TAB_LAYERS_DOWN.png", gui);

    GLOBAL.planesWidget = new WidgetPlanes(0, 0, 900, 100, gui);
    //GLOBAL.planesWidget.setup();

    LayerPanel.add(GLOBAL.planesWidget);

    /*
     *
     *
     *
     *
        ______
    _______/slices/____________________________________________________________________________

    Selecting and editing slices
    
     */
    GUIPanel slicesPanel = new GUIPanel(0f, 0f, tabbedPanel.getWidth(), (int) panelHeight, gui);
    tabbedPanel.addTabbedPanel(slicesPanel, "slices","gui/GUI_TAB_SLICES_UP.png","gui/GUI_TAB_SLICES_DOWN.png", gui);

    GLOBAL.toggleSetSlices = new GUIComponentSet();

    toggle = new GUIToggle(posX, posY, button_width, button_height,
        "gui/GUI_SLICE_SLICE_BUTTON.png", gui);
View Full Code Here

    sliderToggle.isDown = true;
    sliderToggle.addActionListener(GLOBAL.uiTools, "render3dPreview", null);
    gui.add(sliderToggle);
     */

    GUIPanelTabbed tabbedPanel = new GUIPanelTabbed((GLOBAL.windowWidth-panelWidth)/2, GLOBAL.windowHeight
        - panelHeight, (int) panelWidth, (int) panelHeight, gui);
    gui.add(tabbedPanel);
    GLOBAL.designToolbarPattern = tabbedPanel;

    //tools
    GUIPanel toolPanel = new GUIPanel((GLOBAL.windowWidth-panelWidth)/2,
        GLOBAL.windowHeight - panelHeight, panelWidth,
        (int) panelHeight, gui);
    tabbedPanel.addTabbedPanel(toolPanel, "tools", gui);

   
    //save

    GUIButton button = new GUIButton(0, 0, button_width, button_height,
        "gui/save_pdf.png", null, gui);
    button.addActionListener(GLOBAL.uiTools, "savePDF",
        UITools.VIEW_SHAPE_PACK);
    button.setLabel("save pdf");
    button.label.align = GUILabel.CENTRE;
    button.label.layout = GUILabel.UNDER_COMPONENT;
    toolPanel.placeComponent(button);

    button = new GUIButton(0, 0, button_width, button_height,
        "gui/print.png", null, gui);
    button.addActionListener(GLOBAL.uiTools, "print",
        UITools.VIEW_SHAPE_PACK);
    button.setLabel("print");
    button.label.align = GUILabel.CENTRE;
    button.label.layout = GUILabel.UNDER_COMPONENT;
    toolPanel.placeComponent(button);

    button = new GUIButton(0, 0, button_width, button_height,
        "gui/plot.png", null, gui);
    button.addActionListener(GLOBAL.uiTools, "saveCraftRobo",
        UITools.VIEW_SHAPE_PACK);
    button.setLabel("plot");
    button.label.align = GUILabel.CENTRE;
    button.label.layout = GUILabel.UNDER_COMPONENT;
    toolPanel.placeComponent(button);
   
    // materials
    GLOBAL.widgetMaterials =  new WidgetMaterials(0f, GLOBAL.windowHeight
        - panelHeight, (int) panelWidth, (int) panelHeight, gui);
   
    tabbedPanel.addTabbedPanel(GLOBAL.widgetMaterials, "materials", gui);
   

  }
View Full Code Here

TOP

Related Classes of ModalGUI.GUIPanelTabbed

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.