Package org.jfree.report.structure

Examples of org.jfree.report.structure.Section


    else
    {
      variablesSectionStyle.setStyleName(TextRawReportTarget.VARIABLES_HIDDEN_STYLE_WITHOUT_KEEPWNEXT);
    }

    final Section paragraphProps = new Section();
    paragraphProps.setNamespace(OfficeNamespaces.STYLE_NS);
    paragraphProps.setType("paragraph-properties");
    paragraphProps.setAttribute(OfficeNamespaces.FO_NS, "background-color", "transparent");
    paragraphProps.setAttribute(OfficeNamespaces.FO_NS, "text-align", "start");
    paragraphProps.setAttribute(OfficeNamespaces.FO_NS, "keep-with-next", "always");
    paragraphProps.setAttribute(OfficeNamespaces.FO_NS, "keep-together", "always");
    paragraphProps.setAttribute(OfficeNamespaces.STYLE_NS, "vertical-align", "top");
    variablesSectionStyle.addNode(paragraphProps);

    final Section textProps = new Section();
    textProps.setNamespace(OfficeNamespaces.STYLE_NS);
    textProps.setType("text-properties");
    textProps.setAttribute(OfficeNamespaces.FO_NS, "font-variant", "normal");
    textProps.setAttribute(OfficeNamespaces.FO_NS, "text-transform", "none");
    textProps.setAttribute(OfficeNamespaces.FO_NS, "color", "#ffffff");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-outline", "false");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-blinking", "false");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-line-through-style", "none");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-line-through-mode", "continuous");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-position", "0% 100%");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "font-name", "Tahoma");
    textProps.setAttribute(OfficeNamespaces.FO_NS, "font-size", "1pt");
    textProps.setAttribute(OfficeNamespaces.FO_NS, "letter-spacing", "normal");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "letter-kerning", "false");
    textProps.setAttribute(OfficeNamespaces.FO_NS, "font-style", "normal");
    textProps.setAttribute(OfficeNamespaces.FO_NS, "text-shadow", "none");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-underline-style", "none");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-underline-mode", "continuous");
    textProps.setAttribute(OfficeNamespaces.FO_NS, "font-weight", "normal");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-rotation-angle", "0");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-emphasize", "none");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-combine", "none");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-combine-start-char", "");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-combine-end-char", "");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-blinking", "false");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-scale", "100%");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "font-relief", "none");
    textProps.setAttribute(OfficeNamespaces.STYLE_NS, "text-display", "none");
    variablesSectionStyle.addNode(textProps);
    return variablesSectionStyle;
  }
View Full Code Here


          // Lets set the 'keep-together' flag..

          Element paragraphProps = style.getParagraphProperties();
          if (paragraphProps == null)
          {
            paragraphProps = new Section();
            paragraphProps.setNamespace(OfficeNamespaces.STYLE_NS);
            paragraphProps.setType("paragraph-properties");
            style.addNode(paragraphProps);
          }
          paragraphProps.setAttribute(OfficeNamespaces.FO_NS, "keep-together", "always");
          final int keepTogetherState = getCurrentContext().getKeepTogether();
          // We prevent pagebreaks within the two adjacent rows (this one and the next one) if
          // either a group-wide keep-together is defined or if we haven't reached the end of the
          // current section yet.
          if (keepTogetherState == PageContext.KEEP_TOGETHER_GROUP || expectedTableRowCount > 0)
          {
            paragraphProps.setAttribute(OfficeNamespaces.FO_NS, "keep-with-next", "always");
          }

          attrs.setAttribute(OfficeNamespaces.TEXT_NS, "style-name", style.getStyleName());
        }
      }
    }
    else
    {
      if (ReportTargetUtil.isElementOfType(OfficeNamespaces.TABLE_NS, "table-cell", attrs))
      {
        cellEmpty = false;
        if (firstCellSeen == false && sectionKeepTogether)
        {
          final String styleName = (String) attrs.getAttribute(OfficeNamespaces.TABLE_NS, "style-name");
          final OfficeStyle style = deriveStyle("table-cell", styleName);
          // Lets set the 'keep-together' flag..

          Element paragraphProps = style.getParagraphProperties();
          if (paragraphProps == null)
          {
            paragraphProps = new Section();
            paragraphProps.setNamespace(OfficeNamespaces.STYLE_NS);
            paragraphProps.setType("paragraph-properties");
            style.addNode(paragraphProps);
          }
          paragraphProps.setAttribute(OfficeNamespaces.FO_NS, "keep-together", "always");
View Full Code Here

  private Section tableRow;

  public TableRowReadHandler()
  {
    tableCells = new ArrayList();
    tableRow = new Section();
  }
View Full Code Here

    private TableReadHandler sectionTableReadHandler;
    private final Section section;

    public RootTableReadHandler()
    {
        section = new Section();
    }
View Full Code Here

        if (reportHeader != null)
        {
            rootSection.setReportHeader(reportHeader.getElement());
        }

        final Section preBody = createSection("report-pre-body", preBodyHandlers);
        if (preBody != null)
        {
            rootSection.setPreBodySection(preBody);
        }

        final Section groupBody = new Section();
        groupBody.setNamespace(JFreeReportInfo.REPORT_NAMESPACE);
        groupBody.setType("report-body");
        rootSection.setBodySection(groupBody);

        // XOR: Either the detail or the group section can be set ..
        if (groups != null)
        {
            groupBody.addNode(groups.getElement());
        }
        else if (detail != null)
        {
            groupBody.addNode(detail.getElement());
        }

        final Section postBody = createSection("report-post-body", postBodyHandlers);
        if (postBody != null)
        {
            rootSection.setPostBodySection(postBody);
        }
View Full Code Here

    private final Section createSection(final String name, final List handler)
    {
        if (!handler.isEmpty())
        {
            final Section section = new Section();
            section.setNamespace(JFreeReportInfo.REPORT_NAMESPACE);
            section.setType(name);

            for (int i = 0; i < handler.size(); i++)
            {
                final ElementReadHandler erh = (ElementReadHandler) handler.get(i);
                section.addNode(erh.getElement());
            }
            return section;
        }
        return null;
    }
View Full Code Here

    protected AttributeMap computeAttributes(final FlowController fc, final Element element, final ReportTarget target)
            throws DataSourceException
    {
        final AttributeMap attributeMap = new AttributeMap( super.computeAttributes(fc, element, target) );
        final Section s = (Section) element;
        int rowCount = 0;
        final Node[] nodeArray = s.getNodeArray();
        for (int i = 0; i < nodeArray.length; i++)
        {
            final Node node = nodeArray[i];
            if (node instanceof Element)
            {
View Full Code Here

    private final Section tableColumns;

    public TableColumnsReadHandler()
    {
        columns = new ArrayList();
        tableColumns = new Section();
    }
View Full Code Here

{

    private final Section tableColumn;
    public TableColumnReadHandler()
    {
        tableColumn = new Section();
    }
View Full Code Here

    private final Section tableRows;

    public TableRowsReadHandler()
    {
        rows = new ArrayList();
        tableRows = new Section();
    }
View Full Code Here

TOP

Related Classes of org.jfree.report.structure.Section

Copyright © 2018 www.massapicom. 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.