Package org.eclipse.swt.widgets

Examples of org.eclipse.swt.widgets.Label.pack()


        layout.numColumns = 2;
        page.setLayout(layout);

        Label comboLabel = new Label(page, SWT.LEFT);
        comboLabel.setText("Layer:");
        comboLabel.pack();
       
        listenStrategy(true);
       
        comboViewer = new ComboViewer(page, SWT.READ_ONLY);
        comboViewer.setContentProvider(new ArrayContentProvider());
View Full Code Here


      for(int i = 0; i < icons.length; i++) {
        BNetIcon bni = icons[i];

        Label label = new Label(grpIcons, SWT.NULL);
        label.setImage(bni.getImage());
        label.pack();

        String text = "";
        if(bni.getProducts() != null)
          text += " " + HexDump.DWordToPretty(bni.getProducts()[0]);
        if(bni.getFlags() != 0)
View Full Code Here

        label = new Label(grpIcons, SWT.NULL);
        label.setBackground(background);
        label.setForeground(foreground);
        label.setText(Integer.toString(i) + text);
        label.pack();
      }
      grpIcons.pack();
    }

    s.pack();
View Full Code Here

        page.setLayout(layout);

        Label label = new Label(page, SWT.LEFT);
        //label.setLayoutData(new GridData(SWT.LEFT, SWT.TOP, false, false));
        label.setText("Bookmarks ");
        label.pack();
       
        IBookmarkService bookmarkService = BookmarksPlugin.getBookmarkService();
        listenService(true);
       
        comboViewer = new ComboViewer(page, SWT.READ_ONLY);
View Full Code Here

        //stuff to display a message
        String message = ocd.getDescription();
        if(message != null && !message.equals("")){
            Label msg = new Label(this.shell, SWT.WRAP);
            msg.setText(message);
            msg.pack(true);
            GridData labelData = new GridData();
            labelData.horizontalAlignment = GridData.CENTER;
            labelData.grabExcessHorizontalSpace = true;
            if (msg.getSize().x > TEXT_WRAP_LENGTH) {
              labelData.widthHint = TEXT_WRAP_LENGTH;
View Full Code Here

        // });
        // campaignSettingComboViewer.setInput(this);

        label = new Label(comp, SWT.SEPARATOR);
        label.setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false, 4, 1));
        label.pack();

        // // storage manager selection group
        // Group smGroup = new Group(comp, SWT.NONE);
        // smGroup.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 4, 1));
        // smGroup.setText(Messages.getString("campaign.manager.ui.dialog.campaign.builder.storage_manager.label"));
View Full Code Here

        });

        label = new Label(comp, SWT.SEPARATOR);
        label.setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false, 4, 1));
        label.pack();

        // if(storageManagerRegistry.getEntries().size() == 1) {
        // logger.debug("only one item in table; selecting it");
        //
        // ICampaignStorageManagerRegistryEntry entry = storageManagerRegistry.getEntries().get(0);
View Full Code Here

            // created PolicyOriginSelector and label (half the difference).
            // These two controls must be packed before they yield their
            // correct size. Note that laying them out doesn't work (in
            // fact there is no layout() for a Label widget).
            selector.pack();
            policyLabel.pack();
            grid.marginHeight = Math.abs(selector.getSize().y -
                                         policyLabel.getSize().y) / 2;
            labelComposite.setLayout(grid);
        }
View Full Code Here

                // created PolicyOriginSelector and label (half the difference).
                // These two controls must be packed before they yield their
                // correct size. Note that laying them out doesn't work (in
                // fact there is no layout() for a Label widget).
                selector.pack();
                policyLabel.pack();
                grid.marginHeight = Math.abs(selector.getSize().y -
                        policyLabel.getSize().y) / 2;
                labelComposite.setLayout(grid);
            }
View Full Code Here

        CoolItem coolItem = new CoolItem(coolBar, SWT.NONE);
        Label label = new Label(coolBar, SWT.NONE);

        label.setText(text);
        label.setToolTipText(toolTip);
        label.pack();

        Point size = label.getSize();
        size = label.computeSize(size.x, size.y);
        coolItem.setSize(size);
        coolItem.setMinimumSize(size);
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.