Analysis
Overview
The frame could be filled with GRADIENT of two colors. The gradient could be two types - linear and radial. Those are two different opption of frame filling - LINEAR GRADIENT and RADIAL GRADIENT.
Task requirements
- If the RADIAL GRADIENT filling is chosen, frame should be filled with radial gradient of the two filling colors.
- If the LINEAR GRADIENT filling is chosen, frame should be filled with radial gradient of the two filling colors.
- Every time the user chooses different first or second filling color from the hud the filling changes.
- The default colors for GRADIENT are white and black.
Task result
The result of this task is source code.
Implementation idea
Add a second color to the shape scene elements. When creating the scene shape element compute its filling type and colors from the model. Use the java.awt.Graphics2D methods to setPaint and fill the scene element according to its type and color.
Related
FRAME_APPEARANCE_HALO_AND_HUD_R0
FRAME_FILLING_SOLID_R0
FRAME_FILLING_PATTERN_R0
FRAME_FILLING_IMAGE_R0
How to demo
- Demonstrate changing the colors of the frames gradient filling.
- Demonstrate changing the type of the frames gradient filling – linear to/from radial.
Design
Implementation
(Implementation results should be described and linked here (from the wiki or the repository))
Testing
Comments
(Write comments for this or later revisions here.)