Following this example, the compiler is complaining that setFontSize
is deprecated (I'm using Scala). How to set the font size?
val normalStyle = new JRDesignStyle
boldStyle.setFontName("DejaVu Sans")
boldStyle.setFontSize(12) // <--- this is deprecated
As you can see, this method replaced with new one: JRDesignStyle.setFontSize(Float).
In Java your code will be:
boldStyle.setFontSize(12.0f);