Results 1 to 3 of 3
- 06-22-2010, 07:56 PM #1
Member
- Join Date
- Sep 2009
- Posts
- 6
- Rep Power
- 0
Custom component and paint outside of bounds
Hey
I have created a custom component which can be scaled and rotated, and that is working.
But my problem is that the rotated bounds might be different from the component.
Example, I have rotated the component so the rotated bounds is -10 in X and -3 in Y and is +23 in width and +4 in height. If I then move the component so the original Y is below the visible field of the parent, the component is not displayed. I have tried to make a custom repaintmanager, but it did not work.
Does anyone know which class I must extend to allow my component to still be visible if the transformed bounds is still visible?
- 06-30-2010, 05:07 PM #2
Member
- Join Date
- Sep 2009
- Posts
- 6
- Rep Power
- 0
It looked like it was in the paintchildren method and I could not get it working, so I decided to use afffinetransform instead, as I use it for rotating the component and it worked.
Case closed
-
Thank you for posting a follow-up on this.
Similar Threads
-
array going out of bounds?
By jabo in forum New To JavaReplies: 9Last Post: 04-02-2010, 10:08 AM -
Array Index out of bounds
By leapinlizard in forum New To JavaReplies: 5Last Post: 04-29-2009, 05:11 AM -
Custom painter for standard component
By spike in forum AWT / SwingReplies: 1Last Post: 10-04-2008, 05:06 PM -
why is my array out of bounds?
By Phobos0001 in forum New To JavaReplies: 3Last Post: 03-24-2008, 01:20 AM -
Help with custom component
By Falcon1 in forum AWT / SwingReplies: 8Last Post: 07-21-2007, 12:39 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks