Interface JRTextElement

    • Field Detail

      • PROPERTY_TRUNCATE_AT_CHAR

        static final String PROPERTY_TRUNCATE_AT_CHAR
        Boolean property that determines whether text elements are to be truncated at the last character that fits.

        By default, when the entire text of a text element does not fit the element's area, the text is truncated at the last word that fits the area. This property can instruct the engine to truncate the text at the last character that fits.

        The property can be set at the same levels as PROPERTY_PRINT_KEEP_FULL_TEXT.

        See Also:
        Constant Field Values
      • PROPERTY_TRUNCATE_SUFFIX

        static final String PROPERTY_TRUNCATE_SUFFIX
        Property whose value is used as a suffix for the truncated text.

        The suffix is appended to the text when truncation occurs. If the property is not defined or empty (which is the case by default), no suffix will be used when the text is truncated.

        The property can be set at the same levels as PROPERTY_PRINT_KEEP_FULL_TEXT.

        See Also:
        Constant Field Values
      • PROPERTY_SAVE_LINE_BREAKS

        static final String PROPERTY_SAVE_LINE_BREAKS
        Boolean property that determines whether the positions where text line break occurs are to be saved during report fill in oder to be used at export time.

        At report fill time, each text element is measured in order to determine how long it needs to stretch or where it needs to be truncated. During this measurement, the text wraps at certain positions in order to fit the text element defined width.

        Setting this property to true instructs the engine to save the positions at which line breaks occur in the generated print element. The positions can be used by report exporters that want to enforce line breaks to occur at exactly the same position as they did during text measurement at fill time.

        Currently, the HTML exporter will make use of the saved line break positions by introducing explicit line breaks.

        The property can be set globally, at report level or at text element level.

        See Also:
        JRPrintText.getLineBreakOffsets(), Constant Field Values