Examples of SashForm


Examples of org.eclipse.swt.custom.SashForm

    /* take 80% of the application window or 800x500 if that's bigger */
    Point size = getParentShell().getSize();
    gridData.widthHint = Math.max(Double.valueOf(size.x * 0.8).intValue(), 800);
    gridData.heightHint = Math.max(Double.valueOf(size.y * 0.8).intValue(), 500);

      sashForm = new SashForm(composite, SWT.HORIZONTAL);
      sashForm.setLayout(createGridLayout());
      sashForm.setLayoutData(gridData);
      sashForm.setSashWidth(10);

      Composite left = new Composite(sashForm, SWT.NONE);
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

  protected Control createDialogArea(Composite parent) {
    Composite composite = (Composite) super.createDialogArea(parent);

    GridData gridData = createFillGridData();

      sashForm = new SashForm(composite, SWT.HORIZONTAL);
      sashForm.setLayout(createGridLayout());
      sashForm.setLayoutData(gridData);

      Composite left = new Composite(sashForm, SWT.NONE);
      left.setLayout(createGridLayout());
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

  public void createControl() {

      setLayout(createGridLayout());
      setLayoutData(createFillGridData());

    sashForm = new SashForm(this, SWT.VERTICAL);
    sashForm.setLayout(createGridLayout());
        sashForm.setLayoutData(createFillGridData());

    createInfoViewer(sashForm);
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

        form.setImage(titleImg);

        // CREATE CONTROLS
        Composite body = form.getBody();

        SashForm sashForm = new SashForm(body, SWT.HORIZONTAL);

        Composite treePanel = toolkit.createComposite(sashForm);
        contentTreePart = new JARContentTreePart(treePanel, managedForm);
        managedForm.addPart(contentTreePart);

        Composite detailsPanel = toolkit.createComposite(sashForm);
        entryPart = new JAREntryPart(getEditor(), detailsPanel, toolkit);
        managedForm.addPart(entryPart);

        if (selectedPath != null)
            contentTreePart.setSelectedPath(selectedPath);

        // LAYOUT
        GridLayout layout;
        layout = new GridLayout();
        layout.marginHeight = 0;
        layout.marginWidth = 0;
        body.setLayout(layout);

        sashForm.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
        // treeSection.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
        // detailsPanel.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
    }
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

    /**
     * Creates the details tab.
     */
    private void createDetailsTab()
    {
        SashForm detailsForm = new SashForm( tabFolder, SWT.VERTICAL );
        detailsForm.setLayout( new FillLayout() );

        Composite hierarchyContainer = new Composite( detailsForm, SWT.NONE );
        GridLayout hierarchyLayout = new GridLayout( 1, false );
        hierarchyLayout.marginTop = 10;
        hierarchyLayout.marginWidth = 10;
        hierarchyContainer.setLayout( hierarchyLayout );
        BaseWidgetUtils.createLabel( hierarchyContainer, Messages
            .getString( "CertificateInfoComposite.CertificateHierarchyLabel" ), 1 ); //$NON-NLS-1$
        hierarchyTreeViewer = new TreeViewer( hierarchyContainer );
        hierarchyTreeViewer.getTree().setLayoutData( new GridData( GridData.FILL, GridData.FILL, true, true ) );
        hierarchyTreeViewer.setContentProvider( new HierarchyContentProvider() );
        hierarchyTreeViewer.setLabelProvider( new HierarchyLabelProvider() );
        hierarchyTreeViewer.addSelectionChangedListener( new ISelectionChangedListener()
        {
            public void selectionChanged( SelectionChangedEvent event )
            {
                populateCertificateTree();
            }
        } );

        Composite certificateContainer = new Composite( detailsForm, SWT.NONE );
        GridLayout certificateLayout = new GridLayout( 1, false );
        certificateLayout.marginWidth = 10;
        certificateContainer.setLayout( certificateLayout );
        BaseWidgetUtils.createLabel( certificateContainer, Messages
            .getString( "CertificateInfoComposite.CertificateFieldsLabel" ), 1 ); //$NON-NLS-1$
        certificateTree = new Tree( certificateContainer, SWT.BORDER );
        certificateTree.setLayoutData( new GridData( GridData.FILL, GridData.FILL, true, true ) );
        certificateTree.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( final SelectionEvent e )
            {
                TreeItem item = ( TreeItem ) e.item;
                if ( ( item != null ) && ( item.getData() != null ) )
                {
                    valueText.setText( item.getData().toString() );
                }
                else
                {
                    valueText.setText( StringUtils.EMPTY );
                }
            }
        } );

        Composite valueContainer = new Composite( detailsForm, SWT.NONE );
        GridLayout valueLayout = new GridLayout( 1, false );
        valueLayout.marginWidth = 10;
        valueLayout.marginBottom = 10;
        valueContainer.setLayout( valueLayout );
        BaseWidgetUtils.createLabel( valueContainer,
            Messages.getString( "CertificateInfoComposite.FieldValuesLabel" ), 1 ); //$NON-NLS-1$
        valueText = new Text( valueContainer, SWT.MULTI | SWT.BORDER | SWT.H_SCROLL | SWT.V_SCROLL | SWT.READ_ONLY );
        valueText.setLayoutData( new GridData( GridData.FILL, GridData.FILL, true, true ) );
        valueText.setFont( JFaceResources.getFont( JFaceResources.TEXT_FONT ) );
        valueText.setBackground( detailsForm.getBackground() );

        // create tab
        detailsForm.setWeights( new int[]
            { 1, 2, 1 } );
        detailsTab = new TabItem( tabFolder, SWT.NONE, DETAILS_TAB_INDEX );
        detailsTab.setText( Messages.getString( "CertificateInfoComposite.Details" ) ); //$NON-NLS-1$
        detailsTab.setControl( detailsForm );
    }
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

    gridData2.horizontalAlignment = GridData.FILL;
    gridData2.grabExcessHorizontalSpace = true;
    gridData2.grabExcessVerticalSpace = false;
    gridData2.verticalAlignment = GridData.FILL;

    sashForm = new SashForm(parent, SWT.V_SCROLL);
    sashForm.setOrientation(SWT.HORIZONTAL);
    sashForm.setLayout(new GridLayout());
    sashForm.setLayoutData(gridData);

    createImageComposite(sashForm);
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

        topLayout.marginWidth = 0;
        composite.setLayout(topLayout);
       
        // Create the SashForm that contains the selection area on the left,
        // and the edit area on the right
        SashForm sashForm = new SashForm(composite, SWT.FILL);
        sashForm.setOrientation(SWT.HORIZONTAL);
        gd = new GridData(SWT.FILL, SWT.FILL, true, true);
        sashForm.setLayoutData(gd);
        sashForm.setFont(parent.getFont());
       
        // Build the validation selection area and put it into the composite.
        Composite validationSelectionArea;
        try {
            validationSelectionArea = createValidationSelectionArea(sashForm);
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

    public void createPartControl( Composite aParent ) {
        parent= aParent;
        addResizeListener(parent);
       
        // split
        splitter = new SashForm( parent, SWT.HORIZONTAL);
        // TODO: key listener
       
        viewer = createViewer( splitter );
        viewer.setContentProvider( createContentProvider() );
        viewer.setLabelProvider( createLabelProvider() );       
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

        Composite comp = new Composite(parent, SWT.NONE);
        GridData gd = new GridData(SWT.FILL, SWT.FILL, true, true);
        comp.setLayoutData(gd);
        comp.setLayout(new GridLayout(3, false));

        sash = new SashForm(comp, SWT.VERTICAL);
        gd = new GridData(SWT.FILL, SWT.FILL, true, true);
        gd.widthHint = parent.getBounds().x;
        gd.heightHint = parent.getBounds().y;
        gd.horizontalSpan = 3;
        sash.setLayoutData(gd);
View Full Code Here

Examples of org.eclipse.swt.custom.SashForm

        setTitle(Messages.ConnectionFailurePage_displayedTitle);
        setMessage(Messages.ConnectionFailurePage_message);
    }

    public void createControl( Composite parent ) {
        SashForm form=new SashForm(parent, SWT.VERTICAL);
        Tree tree=new Tree(form, SWT.V_SCROLL|SWT.SINGLE);
        TableLayout layout=new TableLayout();
        layout.addColumnData(new ColumnWeightData(100,false));
        tree.setLayout(layout);
        tree.setLinesVisible(true);
        viewer=new TreeViewer(tree);
       
        viewer.setContentProvider(this);
        viewer.setLabelProvider(this);
       
        viewer.addPostSelectionChangedListener(new ISelectionChangedListener(){

            public void selectionChanged( SelectionChangedEvent event ) {
                setDetails();
            }
        });
       
        viewer.setSorter(new ViewerSorter(){
             @Override
            public void sort( Viewer viewer, Object[] elements ) {
                Arrays.sort(elements, new Comparator<Object>(){

                    public int compare( Object o1, Object o2 ) {
                        return 0;
                    }
                   
                });
            }
            
        });
       
        Composite composite = new Composite(form, SWT.BORDER);
        composite.setLayout(new FillLayout());
        details=new Text(composite, SWT.BORDER|SWT.WRAP|SWT.READ_ONLY|SWT.V_SCROLL);
       
        form.setWeights(new int[]{75,25});
       
        setControl(form);
    }
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.