| |||
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] |
The "square" client property is different than the square style that buttons become when they are shrunk too small. If you reduce the button's vertical height by enough, it will turn from a rounded style to the square style, with no space for the focus ring. Currently, if you setOpaque(true) on the JTextField, it will also remove the space allocated for the focus ring. You may want to try using one of the other buttons styles that are more lightweight than a standard push button, and won't need to physically abut the textfield, like "roundRect". Another option may be a "small" style "textured" button. All of these issues pretty clearly cry out for a "JComponent.includeFocusRing" style client property to dictate if the focus ring should be clipped or not (since you may have already have setFocusable(false), and the padding is not needed). But this is only one possible solution. Generally speaking, pushing controls up against each other doesn't work very well in Aqua. The Aqua Human Interface Guidelines expound at much length how large regions of whitespace are more useful to the user to visually group controls, and you might be trying to composite two controls together to form a whole different kind of control (I'm assuming this probably some kind of path or class picker?). If we know a little more about what these controls are doing, we might be able to offer a more creative solution for you in Aqua, that will still degrade nicely to "just a button" in other Look and Feels. Please file a bug report with a test case that brings up the layout you are looking for using, say Metal or the Aqua from Tiger, and what the overall component group is trying to accomplish. Thanks, Mike Swingler Java Frameworks Engineer Apple Inc. On Nov 21, 2007, at 6:11 AM, Ken Orr wrote:
|
_______________________________________________ Do not post admin requests to the list. They will be ignored. Java-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/java-dev/email@hidden This email sent to email@hidden
| References: | |
| >Re: Toolbar button offset (From: Ken Orr <email@hidden>) |
| Home | Archives | FAQ | Terms/Conditions | Contact | RSS | Lists | About |
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE
Contact Apple | Terms of Use | Privacy Policy
Copyright © 2007 Apple Inc. All rights reserved.