Package com.google.gwt.safehtml.shared

Examples of com.google.gwt.safehtml.shared.SafeHtmlBuilder.appendEscaped()


        layout.add(tools.asWidget());

        SafeHtmlBuilder helpText = new SafeHtmlBuilder();
        helpText.appendHtmlConstant("<ul>");
        helpText.appendHtmlConstant("<li>");
        helpText.appendEscaped("This is a raw dump of the current configuration values on this node. It only resolves values on the current level, hence some attributes (or children) may show up as UNDEFINED.");
        helpText.appendHtmlConstant("</ul>");
        StaticHelpPanel help = new StaticHelpPanel(helpText.toSafeHtml());
        layout.add(help.asWidget());

        layout.add(dump);
View Full Code Here


        String[] lines = s.split("\n");
        for(String line : lines)
        {
            html.appendHtmlConstant("<span class='browser-dump-line'>");
            html.appendEscaped(line).appendHtmlConstant("<br/>");
            html.appendHtmlConstant("</span>");
        }

        html.appendHtmlConstant("</pre>");
        return html;
View Full Code Here

                    SafeHtmlBuilder html = new SafeHtmlBuilder();
                    int i=0;
                    for(String detail : validation.getMessages())
                    {
                        if(i==0) html.appendHtmlConstant("<b>");
                        html.appendEscaped(detail).appendHtmlConstant("<br/>");
                        if(i==0) html.appendHtmlConstant("</b>");

                        i++;
                    }
View Full Code Here

        if(record.getRuntimeName().length()>27)
            title = record.getName().substring(0,26)+"...";
        else
            title = record.getName();
        //html.appendHtmlConstant("<a href='javascript:void(0)' style='outline:none'>");
        html.appendEscaped(title);
        //html.appendHtmlConstant("</a>");

        if(record.getPath()!=null)
            html.appendHtmlConstant("&nbsp;<span class='footnote'><sup>[1]</sup></span>");
View Full Code Here

      StyleHelper.addStyle(decoratedWidget, ControlGroupType.ERROR);
      SafeHtmlBuilder sb = new SafeHtmlBuilder();
      for (EditorError error : errors) {
        if(error.getEditor() == this) {
          error.setConsumed(true);
          sb.appendEscaped(error.getMessage());
          sb.appendHtmlConstant("<br />");
        }
      }
      setErrorLabelText(sb.toSafeHtml().asString());
    } else {
View Full Code Here

        Set<String> roles = bootstrap.getRoles();
        SafeHtmlBuilder sb = new SafeHtmlBuilder();
        sb.appendHtmlConstant("<div class='roles-menu'>");
        for(String role : roles)
        {
            sb.appendEscaped(role).appendHtmlConstant("<br/>");
        }
        sb.appendHtmlConstant("<div>");

        // current user
        String userHtml = "<i style='color:#cecece' class='icon-user'></i>&nbsp;"+bootstrap.getPrincipal();
View Full Code Here

            SafeHtmlBuilder runAsRole = new SafeHtmlBuilder();
            runAsRole.appendHtmlConstant("<i class='icon-flag'></i>&nbsp;").appendEscaped("Run as");
            if (bootstrap.getRunAs()!=null) {
                runAsRole.appendHtmlConstant("&nbsp;").appendEscaped(bootstrap.getRunAs());
            } else {
                runAsRole.appendEscaped("...");
            }

            runAsBtn.setHTML(runAsRole.toSafeHtml());
            runAsBtn.addClickHandler(new ClickHandler() {
                @Override
View Full Code Here

        SafeHtmlBuilder html = new SafeHtmlBuilder();
        html.appendHtmlConstant("<ul>");
        html.appendHtmlConstant("<li>").appendEscaped("Locale: The user interface language.");
        if (productConfig.getProfile() == COMMUNITY) {
            html.appendHtmlConstant("<li>").appendEscaped("Analytics: We track browser and operating system information in order to improve the user interface. ");
            html.appendEscaped("You can disable the analytics feature at anytime.");
        }
        html.appendHtmlConstant("</ul>");
        StaticHelpPanel help = new StaticHelpPanel(html.toSafeHtml());
        layout.add(help.asWidget());
        layout.add(form.asWidget());
View Full Code Here

  @ShowcaseSource
  private void addItem(TreeItem root, ImageResource image, String label) {
    SafeHtmlBuilder sb = new SafeHtmlBuilder();
    sb.append(SafeHtmlUtils.fromTrustedString(AbstractImagePrototype.create(
        image).getHTML()));
    sb.appendEscaped(" ").appendEscaped(label);
    root.addItem(sb.toSafeHtml());
  }

  /**
   * Create the list of Contacts.
View Full Code Here

      // Open the contact info popup when the user clicks a contact
      contactLink.addClickHandler(new ClickHandler() {
        public void onClick(ClickEvent event) {
          // Set the info about the contact
          SafeHtmlBuilder sb = new SafeHtmlBuilder();
          sb.appendEscaped(contactName);
          sb.appendHtmlConstant("<br><i>");
          sb.appendEscaped(contactEmail);
          sb.appendHtmlConstant("</i>");
          contactInfo.setHTML(sb.toSafeHtml());
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.