Examples of StyledLabel


Examples of com.jidesoft.swing.StyledLabel

    JPanel titlePanel = new JPanel();
    titlePanel.setBorder(BorderFactory.createCompoundBorder(
        BorderFactory.createEmptyBorder( 10, 10, 0, 10),
        new PartialEtchedBorder(EtchedBorder.LOWERED, PartialEtchedBorder.SOUTH)));
    titlePanel.setLayout(new BorderLayout());
    StyledLabel label = new StyledLabel(getTitle());
    label.setStyleRanges(new StyleRange[]{new StyleRange(Font.BOLD, Color.BLACK)});
    titlePanel.add(label, BorderLayout.WEST);
    return titlePanel;
  }
View Full Code Here

Examples of com.jidesoft.swing.StyledLabel

    formPanel.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10));
    formPanel.setLayout(new BorderLayout());
    JPanel title = new JPanel();
    title.setBorder(BorderFactory.createEmptyBorder(10, 0, 10, 0));
    title.setLayout(new BorderLayout());
    StyledLabel titleLabel = new StyledLabel(getFormComponentLabel());
    titleLabel.setStyleRanges(new StyleRange[]{new StyleRange(Font.PLAIN, Color.BLACK)});
    title.add(titleLabel, BorderLayout.WEST);
    formPanel.add(title, BorderLayout.NORTH);
      formPanel.add(getFormComponentControl(), BorderLayout.CENTER);
      return formPanel;
  }
View Full Code Here

Examples of com.jidesoft.swing.StyledLabel

     * @param labelProvider  the label provider
     * @param selectionModel the selection model
     */
    public SelectionBasedComponentProvider( @NotNull final Class<S> selectionType, @NotNull LabelProvider labelProvider, @NotNull SelectionModel selectionModel ) {
      this.labelProvider = labelProvider;
      label = new StyledLabel();

      //update the selection
      this.selectionModel = selectionModel;
      selectionModel.addSelectionChangeListener( new SelectionChangeListener() {
        @Override
View Full Code Here

Examples of com.jidesoft.swing.StyledLabel

    JTextArea textArea = getComponentFactory().createTextArea();
    textArea.setText( out.toString() );

    panel.add( getComponentFactory().createScrollPane( textArea ), BorderLayout.CENTER );

    StyledLabel label = new StyledLabel( cause.getMessage() );
    label.addStyleRange( new StyleRange( Font.BOLD ) );
    panel.add( new JLabel( cause.getMessage() ), BorderLayout.NORTH );

    return panel;
  }
View Full Code Here

Examples of org.onesocialweb.gwt.client.ui.widget.StyledLabel

    StyledFlowPanel sectionSimple = new StyledFlowPanel("section");

    Button buttonAdvanced = new Button("Advanced");
    buttonAdvanced.addStyleName("sectionedit");

    StyledLabel titleUN = new StyledLabel("grouplabel", "Privacy settings");
    StyledLabel instructionUN = new StyledLabel("instruction",
        "Choose the defaults for who can see and do what.");
    sectionSimple.add(buttonAdvanced);
    sectionSimple.add(titleUN);
    sectionSimple.add(instructionUN);
    DisclosurePanel disclosureStatus = new DisclosurePanel(
View Full Code Here

Examples of org.onesocialweb.gwt.client.ui.widget.StyledLabel

    sectionGeneral = new StyledFlowPanel("section");
    buttonEditG = new TooltipPushButton(new Image(OswClient.getInstance()
        .getPreference("theme_folder")
        + "assets/i-edit.png"), uiText.EditProfile());
    buttonEditG.addStyleName("sectionedit");
    StyledLabel titleG = new StyledLabel("grouplabel", uiText.General());
    sectionGeneral.add(buttonEditG);
    sectionGeneral.add(titleG);
    this.profile.add(sectionGeneral);

    // Editor version of general information
View Full Code Here

Examples of org.onesocialweb.gwt.client.ui.widget.StyledLabel

  private void loadAccount() {

    // username
    StyledFlowPanel sectionUsername = new StyledFlowPanel("section");
    FlexTable username = new FlexTable();
    StyledLabel titleUN = new StyledLabel("grouplabel", uiText.YourIdentity());
    StyledLabel instructionUN = new StyledLabel("instruction",
        uiText.IdentityFixed());
    sectionUsername.add(titleUN);
    sectionUsername.add(instructionUN);
    sectionUsername.add(username);
    account.add(sectionUsername);

    addHTMLLabelRow(username, uiText.UserName(), OswServiceFactory.getService()
        .getUserBareJID());

    // change language
    StyledFlowPanel sectionChangeLocale = new StyledFlowPanel("section");
    FlexTable changeLocale = new FlexTable();
    StyledLabel titleCL = new StyledLabel("grouplabel", uiText.ChangeLocale());
    StyledLabel instructionCL = new StyledLabel("instruction", uiText.SetLanguage());
   
    final ListBox languageSelector = new ListBox();
   
    // add the values to the list
    HashMap<String, String> OSWLocales = OswClient.getInstance().getOSWLocales();
View Full Code Here

Examples of org.onesocialweb.gwt.client.ui.widget.StyledLabel

                        isComment=true;
        }


        if ((!isComment) && (activity.hasRecipients())) {
      authorWrapper.add(new StyledLabel("separator", " " + uiText.To() + " "));
      Iterator<AtomReplyTo> recipients = activity.getRecipients()
          .iterator();
      while (recipients.hasNext()) {
        final AtomReplyTo recipient = recipients.next();
        final String recipientJID = recipient.getHref();
        final StyledLabel label = new StyledLabel("link", recipientJID);
        label.setTitle(uiText.ViewProfileOf() + recipientJID);

        service.getProfile(recipientJID,
            new RequestCallback<Profile>() {

              @Override
              public void onFailure() {
                // do nothing
              }

              @Override
              public void onSuccess(Profile result) {
                // show display name
                final String fullName = result.getFullName();
                if (fullName != null && fullName.length() > 0) {
                  label.setText(fullName);
                }

              }

            });

        label.addClickHandler(new ClickHandler() {
          public void onClick(ClickEvent event) {
            // get the app instance from the session manager
            AbstractApplication app = OswClient.getInstance()
                .getCurrentApplication();
            ProfileWindow profileWindow = (ProfileWindow) app
                .addWindow(ProfileWindow.class.toString(), 1);
            profileWindow.setJID(recipientJID);
            profileWindow.show();
          }
        });
        authorWrapper.add(label);

        if (recipients.hasNext()) {
          authorWrapper.add(new StyledLabel("separator", ", "));
        }
      }
    }

    statuswrapper.add(statusIcon);
View Full Code Here

Examples of org.onesocialweb.gwt.client.ui.widget.StyledLabel

    StyledTooltipImage attachmentIcon = new StyledTooltipImage(OswClient
        .getInstance().getPreference("theme_folder")
        + "assets/i-attachment.png", "icon", "");
    StyledFlowPanel attachmentFlow = new StyledFlowPanel("image");
    StyledFlowPanel wrapper = new StyledFlowPanel("metadata");
    StyledLabel title = new StyledLabel("title", "");
    StyledLabel description = new StyledLabel("description", "");
    attachment.add(attachmentIcon);
    attachment.add(attachmentFlow);
    attachment.add(wrapper);
    wrapper.add(title);
    attachmentswrapper.add(attachment);

    // show the link elements
    for (int i = 0; i < object.getLinks().size(); i++) {
      // get the url to the picture
      if (object.hasLinks() && object.getLinks().get(0).hasRel()
          && object.getLinks().get(i).getRel().equals("alternate")) {

        // get the link to the image
        final StyledTooltipImage image = new StyledTooltipImage(object
            .getLinks().get(i).getHref(), "attachment",
            uiText.ShowPreview());

        image.addStyleName("link");

        // if the activity has a title
        if (activity.hasTitle() && activity.getTitle().length() > 0) {

          // and the link has a title as well
          if (object.getLinks().get(i).hasTitle()
              && object.getLinks().get(i).getTitle().length() > 0) {

            // check if they are the same and skip it on the link if
            // so
            // TODO this needs to be refactored to the
            // object.getTitle()
            if (!activity.getTitle().trim().equals(
                object.getLinks().get(i).getTitle().trim())) {
              title.setText(object.getLinks().get(i).getTitle());
            }

          }

          // otherwise we can show it
          // TODO this needs to be refactored to the object.getTitle()
        } else {
          title.setText(object.getLinks().get(i).getTitle());
        }

        attachmentFlow.add(image);

        image.addClickHandler(new ClickHandler() {
          public void onClick(ClickEvent event) {
            PicturePreviewDialog.getInstance().showDialog(
                image.getUrl(), uiText.ImagePreview());
          }
        });
      }
    }

    // show description
    if (object.hasContents()
        && object.getContents().get(0).getValue() != null
        && object.getContents().get(0).getValue().length() > 0) {
      description.setText(object.getContents().get(0).getValue());
      wrapper.add(description);
    }

  }
View Full Code Here

Examples of org.onesocialweb.gwt.client.ui.widget.StyledLabel

        + "assets/i-private-r.png");
    setCloseTooltip(uiText.BackToDefault());

    // construct
    visibility = new ListBox();
    StyledLabel show = new StyledLabel("label", uiText.With());
    final Roster roster = OswServiceFactory.getService().getRoster();
    roster.registerEventHandler(new Observer<RosterEvent>() {

      @Override
      public void handleEvent(RosterEvent event) {
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.