ICEfaces
  1. ICEfaces
  2. ICE-1925

ice:outputChart disable legend

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.6
    • Fix Version/s: 1.6.1
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      Gentoo Linux, Sun-JDK 1.5.0_11, JBoss 4.0.5 GA, MyEclipse 5.5

      Description

      Hi,
      it would be nice, if ice:outputChart can create a chart without legend for example to implement a scrolling chart with ice:panelGroup.
      I've done it simple on the 1.6.0 source:
      In the JSP:
      <ice:outputChart legendPlacement="none" .../>

      In AbstractChart.java:

      public LegendProperties getLegendProperties() {
           LegendProperties legendProperties = new LegendProperties();
           if ("none".equals(outputChart.getLegendPlacement())) {
           return null;
           }
          legendProperties.setPlacement(legendPlacementMap.getLegendPlacement(
      String.valueOf(outputChart.getLegendPlacement())));
          Object legendColumns = outputChart.getLegendColumns();
          if (legendColumns instanceof Integer) {
          legendProperties.setNumColumns(((Integer)outputChart.getLegendColumns()).intValue());
          }else if (legendColumns instanceof String) {
          legendProperties.setNumColumns(Integer.parseInt(outputChart.getLegendColumns().toString()));
          }
          return legendProperties;
          }

      The result is a nice chart without legend.

        Activity

        Hide
        yip.ng added a comment -

        Made changes based on the user's recommendation, after checking to make sure that there would be no adverse side effects.

        Updated the tag library documentation.

        Show
        yip.ng added a comment - Made changes based on the user's recommendation, after checking to make sure that there would be no adverse side effects. Updated the tag library documentation.

          People

          • Assignee:
            Unassigned
            Reporter:
            Janos Schwellach
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: