I would like to make a dynamic change font property based on variable condition.
I have already searched on the stackoverflow's questions but I didn't find anything for this detail.
Below my snippet code:
<textField>
<reportElement style="DetailsPrice" x="370" y="5" width="56" height="15" uuid="2f0dc291-6a8b-48d3-b7d1-fe931b88e859">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.x" value="mm"/>
<property name="com.jaspersoft.studio.unit.height" value="mm"/>
<printWhenExpression>
<![CDATA[$F{product_unformatted_discount_amount} != null && $F{product_unformatted_discount_amount} != 0]]>
</printWhenExpression>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Middle">
<font isBold="true" isStrikeThrough="true"/>
</textElement>
<textFieldExpression><![CDATA["+" + $F{product_price_formatted_amount}]]></textFieldExpression>
</textField>
How can I change isStrikeThrough property value depending on $F{product_unformatted_discount_amount} value ? In a nutshell I would like to apply condition in line in the font tag.
Thanks