Package org.eclipse.swt.custom

Examples of org.eclipse.swt.custom.CTabFolder


          lenguetasLData.heightHint = 249;
          lenguetas.setLayoutData(lenguetasLData);
          lenguetas.setLayout(lenguetasLayout);
          lenguetas.setEnabled(false);
          {
            cTabFolder1 = new CTabFolder(lenguetas, SWT.NONE);
            cTabFolder1.addSelectionListener(new SelectionListener(){

              public void widgetSelected(SelectionEvent arg0) {
                fillTable();
               
View Full Code Here


   * @param style para el composite
   * @return composite con el estado del robot
   */
  public Composite getStatusPannel(Composite parent, int style) throws ComponentGUIException
  {
    CTabFolder tabs;
    CTabItem sensors;
    CTabItem robot;
    Composite statusPannel = new Composite(parent,style);
    GridLayout robotStatusLayout = new GridLayout();
    statusPannel.setLayout(robotStatusLayout);

    try
    {

      tabs = new CTabFolder(statusPannel, SWT.FLAT | SWT.TOP | SWT.BORDER);
      {
        sensors = new CTabItem(tabs,SWT.NONE);
        sensors.setText("Sensores");
        sensors.setImage(SWTResourceManager.getImage("resources/icons/icon24x24/enable/System-ColorSync.png"));
        {
          sensorComposite = new Composite(tabs,SWT.NONE);
          GridData sensorCompositeLData = new GridData();
          sensorCompositeLData.horizontalAlignment = GridData.BEGINNING;
          sensorCompositeLData.verticalAlignment = GridData.BEGINNING;
          sensorCompositeLData.grabExcessHorizontalSpace = true;
          sensorCompositeLData.grabExcessVerticalSpace = false;
          GridLayout sensorCompositeLayout = new GridLayout();
          sensorCompositeLayout.numColumns = 2;
          sensorCompositeLayout.marginWidth = 0;
          sensorCompositeLayout.marginHeight = 0;
          sensorCompositeLayout.verticalSpacing = 1;
          sensorCompositeLayout.marginLeft = 3;
          sensorCompositeLayout.marginTop = 2;
          sensors.setControl(sensorComposite);
          sensorComposite.setLayout(sensorCompositeLayout);
          sensorComposite.setLayoutData(sensorCompositeLData);
          {
            for (int i=0; i<((Robot)component).getFeatures().length;i++)
            {
              Plugin plugin = ClassManager.getInstance().getPluginByName(((Robot)component).getFeatures()[i].getClass().getCanonicalName());

              if (plugin != null)
              {
                FeatureGUI featureGUI = (FeatureGUI)plugin.makeGUInstance(((Robot)component).getFeatures()[i]);
                featureStatus =  featureGUI.getStatusPannel( sensorComposite, sensorComposite.getStyle());
                 
                //Fuerzo layout
                GridData featureStatusLData = new GridData();
                featureStatusLData.horizontalAlignment = GridData.FILL;
                featureStatusLData.verticalAlignment = GridData.FILL;
                featureStatusLData.grabExcessHorizontalSpace = true;
                featureStatusLData.grabExcessVerticalSpace = true;
                featureStatus.setLayoutData(featureStatusLData);
              }
            }
          }       
          sensorComposite.layout(true);
        }
        neuralNet = new CTabItem(tabs,SWT.NONE);
        neuralNet.setText("Red Neuronal");
        neuralNet.setImage(SWTResourceManager.getImage("resources/icons/icon24x24/enable/neuron.png"));
        {
          Plugin neuralNetPlugin = ClassManager.getInstance().getPluginByName(((Robot)component).getNeuralNetwork().getClass().getCanonicalName());
          if (neuralNetPlugin != null)
          {
            NeuralNetworkGUI nnGUI = (NeuralNetworkGUI) neuralNetPlugin.makeGUInstance(((Robot)component).getNeuralNetwork());
            Composite neuralNetComposite = nnGUI.getStatusPannel(tabs,SWT.NONE);
            neuralNet.setControl(neuralNetComposite);
            GridData neuralNetCompositeLData = new GridData();
            neuralNetCompositeLData.horizontalAlignment = GridData.BEGINNING;
            neuralNetCompositeLData.verticalAlignment = GridData.BEGINNING;
            neuralNetCompositeLData.grabExcessHorizontalSpace = true;
            neuralNetCompositeLData.grabExcessVerticalSpace = false;
            GridLayout neuralNetCompositeLayout = new GridLayout();
            neuralNetComposite.setLayout(neuralNetCompositeLayout);
            neuralNetComposite.setLayoutData(neuralNetCompositeLData);
            neuralNetComposite.layout(true);
          }
         
        }
        commChannel = new CTabItem(tabs,SWT.NONE);
        commChannel.setText("Canal de Comunicaciones");
        commChannel.setImage(SWTResourceManager.getImage("resources/icons/icon24x24/enable/Connection.png"));
        {
          Plugin ccPlugin = ClassManager.getInstance().getPluginByName(((Robot)component).getCommChannel().getClass().getCanonicalName());
          if (ccPlugin != null)
          {
            CommunicationChannelGUI ccGUI = (CommunicationChannelGUI) ccPlugin.makeGUInstance(((Robot)component).getCommChannel());
            Composite ccComposite = ccGUI.getStatusPannel(tabs,SWT.NONE);
            commChannel.setControl(ccComposite);
            GridData ccCompositeLData = new GridData();
            ccCompositeLData.horizontalAlignment = GridData.BEGINNING;
            ccCompositeLData.verticalAlignment = GridData.BEGINNING;
            ccCompositeLData.grabExcessHorizontalSpace = true;
            ccCompositeLData.grabExcessVerticalSpace = false;
            GridLayout ccCompositeLayout = new GridLayout();
            ccComposite.setLayout(ccCompositeLayout);
            ccComposite.setLayoutData(ccCompositeLData);
            ccComposite.layout(true);
          }
        }
        {
          robot = new CTabItem(tabs, SWT.NONE);
          robot.setText("Robot");
          robot.setImage(SWTResourceManager.getImage("resources/icons/icon24x24/enable/AIBO210.png"));
          {
            Label roboText = new Label(tabs,SWT.NONE);
            roboText.setText"Robot Resuelve Laberintos v1.0\n" +
                      "Desarrollado por:\n" +
                      "Augusto Vega (ajvega@fi.uba.ar)\n" +
                      "Juan Caracoche (jmcaracoche@gmail.com)");
            robot.setControl(roboText);
          }
        }
      }
     
      tabs.layout(true);
      GridData cTabFolder1LData = new GridData();
      cTabFolder1LData.grabExcessHorizontalSpace = true;
      cTabFolder1LData.grabExcessVerticalSpace = true;
      cTabFolder1LData.horizontalAlignment = GridData.FILL;
      cTabFolder1LData.verticalAlignment = GridData.FILL;
      tabs.setLayoutData(cTabFolder1LData);
      tabs.setSelection(0);
     
    }
    catch (Exception e)
    {
      throw new ComponentGUIException( e.getMessage() );
View Full Code Here

    backComposite.setLayout(backCompositeLayout);
     
   
    try
    {
      configTabs = new CTabFolder(backComposite, SWT.NONE);
       
      {
        CTabItem cTabFeatures = new CTabItem(configTabs, SWT.NONE);
        cTabFeatures.setText("Features");
        cTabFeatures.setImage(SWTResourceManager.getImage("resources/icons/icon24x24/enable/System-ColorSync.png"));
        {
          featureTabs = new CTabFolder(configTabs,SWT.NONE);
          cTabFeatures.setControl(featureTabs);
         
          for (int i=0; i<((Robot)component).getFeatures().length; i++)
          {
            Plugin feature = null;
View Full Code Here

          label1LData.grabExcessHorizontalSpace = true;
          label1.setLayoutData(label1LData);
          label1.setText("label1")// TODO: "label1" ??????
        }
        {
          cTabFolder1 = new CTabFolder(back, SWT.NONE);
          {
            cTabItem1 = new CTabItem(cTabFolder1, SWT.NONE);
            cTabItem1.setText("Robots");
            {
              composite1 = new Composite(cTabFolder1, SWT.NONE);
              GridLayout composite1Layout = new GridLayout();
              composite1Layout.makeColumnsEqualWidth = true;
              composite1Layout.horizontalSpacing = 2;
              composite1Layout.marginHeight = 2;
              composite1Layout.marginWidth = 0;
              composite1Layout.verticalSpacing = 0;
              composite1Layout.marginLeft = 3;
              composite1Layout.marginRight = 3;
              composite1.setLayout(composite1Layout);
              cTabItem1.setControl(composite1);
              {
                barraRobots = new Composite(
                  composite1,
                  SWT.NONE);
                RowLayout barraRobotsLayout = new RowLayout(
                  org.eclipse.swt.SWT.HORIZONTAL);
                barraRobots.setLayout(barraRobotsLayout);
                GridData barraRobotsLData = new GridData();
                barraRobots.setLayoutData(barraRobotsLData);
                {
                  toolBarRobot = new ToolBar(
                    barraRobots,
                    SWT.FLAT);
                  RowData toolBarRobotLData = new RowData();
                  toolBarRobot
                    .setLayoutData(toolBarRobotLData);
                  {
                    toolItem1 = new ToolItem(
                      toolBarRobot,
                      SWT.NONE);
                    toolItem1.setToolTipText("Agregar");
                    toolItem1
                      .setImage(SWTResourceManager
                        .getImage("iconos/24x24/AIBO210-add.png"));
                  }
                  {
                    remRobot = new ToolItem(
                      toolBarRobot,
                      SWT.NONE);
                    remRobot
                      .setImage(SWTResourceManager
                        .getImage("iconos/24x24/AIBO210-rem.png"));
                  }
                  {
                    copyRobot = new ToolItem(
                      toolBarRobot,
                      SWT.NONE);
                    copyRobot
                      .setImage(SWTResourceManager
                        .getImage("iconos/24x24/AIBO210-copy.png"));
                  }
                  {
                    configRobot = new ToolItem(
                      toolBarRobot,
                      SWT.NONE);
                    configRobot
                      .setToolTipText("Propiedades");
                    configRobot
                      .setImage(SWTResourceManager
                        .getImage("iconos/24x24/Toolbar-_�Applications.png"));
                  }
                  {
                    calibrarRobot = new ToolItem(
                      toolBarRobot,
                      SWT.NONE);
                    calibrarRobot
                      .setImage(SWTResourceManager
                        .getImage("iconos/24x24/System-ColorSync.png"));
                  }
                }
              }
              {
                label2 = new Label(composite1, SWT.SEPARATOR
                  | SWT.HORIZONTAL);
                GridData label2LData = new GridData();
                label2LData.grabExcessHorizontalSpace = true;
                label2LData.horizontalAlignment = GridData.FILL;
                label2.setLayoutData(label2LData);
                label2.setText("label2")// TODO: "label2" ???
              }
              {
                GridData listadoLData = new GridData();
                listadoLData.grabExcessHorizontalSpace = true;
                listadoLData.horizontalAlignment = GridData.CENTER;
                listadoLData.heightHint = 89;
                listadoLData.widthHint = 592;
                listadoLData.verticalIndent = 3;
                listado = new Table(composite1, SWT.MULTI
                  | SWT.CHECK
                  | SWT.FULL_SELECTION);
                listado.setLayoutData(listadoLData);
                listado.setHeaderVisible(true);
                listado.setItemCount(5);
                listado.setLinesVisible(true);
                {
                  tableColumn4 = new TableColumn(
                    listado,
                    SWT.CENTER);
                  tableColumn4.setWidth(29);
                }
                {
                  tableColumn1 = new TableColumn(
                    listado,
                    SWT.NONE);
                  tableColumn1.setText("Nombre");
                  tableColumn1.setWidth(287);
                }
                {
                  tableColumn2 = new TableColumn(
                    listado,
                    SWT.CENTER);
                  tableColumn2.setText("Ruta del JAR");
                  tableColumn2.setWidth(206);
                }
                {
                  tableColumn3 = new TableColumn(
                    listado,
                    SWT.NONE);
                  tableColumn3.setText("Comentario");
                  tableColumn3.setWidth(72);
                }
              }
            }
          }
          {
            neuralNetworks = new CTabItem(cTabFolder1, SWT.NONE);
            neuralNetworks.setText("Redes Neuronales");
          }
          {
            features = new CTabItem(cTabFolder1, SWT.NONE);
            features.setText("Features");
            {
              cTabFolder2 = new CTabFolder(cTabFolder1, SWT.NONE);
              features.setControl(cTabFolder2);
              {
                cTabItem2 = new CTabItem(cTabFolder2, SWT.NONE);
                cTabItem2.setText("Sensores");
                {
View Full Code Here

   * @param flags
   */
  public PaneFolder(Composite parent, int flags) {
    // Initialize tab folder
    {
      tabFolder = new CTabFolder(parent, flags);

      tabFolder.setMRUVisible(((TabBehaviour)Tweaklets.get(TabBehaviour.KEY)).enableMRUTabVisibility());

      // Create a proxy control to measure the title area of the tab
      // folder
View Full Code Here

    /* (non-Javadoc)
     * @see org.eclipse.ui.IPresentationPreview#createControl(org.eclipse.swt.widgets.Composite, org.eclipse.ui.themes.ITheme)
     */
    public void createControl(Composite parent, ITheme currentTheme) {
        this.theme = currentTheme;
        folder = new CTabFolder(parent, SWT.BORDER);
        folder.setUnselectedCloseVisible(false);
        folder.setEnabled(false);
        folder.setMaximizeVisible(true);
        folder.setMinimizeVisible(true);

View Full Code Here

     * @param flags
     */
    public PaneFolder(Composite parent, int flags) {
        // Initialize tab folder
        {
            tabFolder = new CTabFolder(parent, flags);
           
      tabFolder.setMRUVisible(((TabBehaviour)Tweaklets.get(TabBehaviour.KEY)).enableMRUTabVisibility());

            // Create a proxy control to measure the title area of the tab folder
            titleAreaProxy = new Composite(tabFolder, SWT.NO_BACKGROUND);
View Full Code Here

    /**
     * {@inheritDoc}
     */
    public void createPartControl( Composite parent )
    {
        tabFolder = new CTabFolder( parent, SWT.BOTTOM );

        ocdTab = new CTabItem( tabFolder, SWT.NONE );
        ocdTab.setText( Messages.getString( "SchemaBrowser.ObjectClasses" ) ); //$NON-NLS-1$
        ocdTab.setImage( BrowserUIPlugin.getDefault().getImage( BrowserUIConstants.IMG_OCD ) );
        ocdPage = new ObjectClassDescriptionPage( this );
View Full Code Here

   * This is a callback that will allow us to create the viewer and initialize
   * it.
   */
  public void createPartControl(Composite parent) {
   
    final CTabFolder tabFolder = new CTabFolder(parent, SWT.BOTTOM);

    GridLayout layout = new GridLayout(2, false);
   
//////////////PE
   
    CTabItem tabPE = new CTabItem(tabFolder, SWT.NONE);
    tabPE.setText("Processing Elements");
   
    Composite panelPE = new Composite(tabFolder, SWT.NONE);

    panelPE.setLayout(layout);

    tabPE.setControl(panelPE);
       
    peView.createPartControlPE(panelPE);

//////////////ST
   
    CTabItem tabST = new CTabItem(tabFolder, SWT.NONE);
    tabST.setText("Structural Types");
       
    Composite panelST = new Composite(tabFolder, SWT.NONE);

    panelST.setLayout(layout);

    tabST.setControl(panelST);
       
    structView.createPartControlST(panelST);
   
//////////////DT
   
    CTabItem tabDT = new CTabItem(tabFolder, SWT.NONE);
    tabDT.setText("Domain Types");
       
    Composite panelDT = new Composite(tabFolder, SWT.NONE);

    panelDT.setLayout(layout);

    tabDT.setControl(panelDT);
       
    domainView.createPartControlDT(panelDT);
   
    getSite().setSelectionProvider(peView.getViewer());

    tabFolder.setSelection(0);   
   
//    getSite().setSelectionProvider(viewerDT);
    makeActions();
//    hookContextMenu();
//    hookDoubleClickAction();
View Full Code Here

        modulesInputGuiList = new ArrayList<ModuleGuiElement>();
        modulesOuputGuiList = new ArrayList<ModuleGuiElement>();

        // parent has FillLayout
        // create the tab folder
        final CTabFolder folder = new CTabFolder(parent, SWT.BOTTOM);
        folder.setUnselectedCloseVisible(false);
        folder.setLayout(new FillLayout());
        folder.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));

        // for every Tab object create a tab
        String layoutConstraint = "insets 20 20 20 20, fillx";

        makeInputTab(folder, layoutConstraint);
View Full Code Here

TOP

Related Classes of org.eclipse.swt.custom.CTabFolder

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.