Release Notes > JTGO 4.0 Release Notes > Compatibility Issues > Patterns |
Patterns |
PREVIOUS NEXT |
Starting from JTGO 4.0, the interface IlPattern
is deprecated together with its two methods fillRect
and fillPolygon
. The way patterns are handled within JTGO has changed also and is now based on the Paint
interface and handled directly by the Java Graphics2D
class.
The abstract class IltPattern
defines a new abstract method, getPaint
, that should be implemented to create a new user-defined pattern in JTGO.
Users who directly implemented IlPattern
or extended IltPattern
are affected by this change. The recommended migration procedure is to use one of the predefined patterns (all patterns defined in IlvPattern
are now supported), or to implement the method IltPattern.getPaint
.
You only need to perform a small modification to your implementations of IlPattern
to comply with the changes. To do so, follow these steps:
IlPattern
implementation extends IltPattern
.
IltPattern.getPaint
method as follows:
This code is provided as a contribution and may be optimized according to the user's needs.
Copyright © Rogue Wave Software, Inc. 1997, 2015. All rights reserved. Legal terms. | PREVIOUS NEXT |