Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.gui > #4654

Re: Label clipping using Nimbus L&F

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!.POSTED!not-for-mail
From Tom <tom400f@gmail.com>
Newsgroups comp.lang.java.gui
Subject Re: Label clipping using Nimbus L&F
Date Sat, 20 Aug 2011 11:07:30 +0000 (UTC)
Organization Aioe.org NNTP Server
Lines 33
Message-ID <pan.2011.08.20.11.07.25@gmail.com> (permalink)
References <cfd76ad7-bcc7-44eb-b670-980c9cb2997e@m6g2000prh.googlegroups.com> <anut4751uuhdu5er8a3h5t12bmrju7idha@4ax.com>
NNTP-Posting-Host Vd3zjYYo2heJAT9ZVcrkiA.user.speranza.aioe.org
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding 8bit
X-Complaints-To abuse@aioe.org
User-Agent Pan/0.133 (House of Butterflies)
X-Notice Filtered by postfilter v. 0.8.2
Xref x330-a1.tempe.blueboxinc.net comp.lang.java.gui:4654

Show key headers only | View raw


On Fri, 19 Aug 2011 17:11:17 -0700, Roedy Green wrote:

> On Fri, 19 Aug 2011 13:30:14 -0700 (PDT), Fred
> <fred.l.kleinschmidt@boeing.com> wrote, quoted or indirectly quoted
> someone who said :
> 
>>When I use Nimbus Look-and-feel, often the text in a JLabel, JButton, or
>>JToggleButton will be partially clipped. This does not happen with Metal
>>or Motif.
>>Any suggestions how to solve this?
>  
>  
> 
> see http://mindprod.com/jgloss/jlabel.html
> 
> The trick is to use an empty border to put a little padding around the
> text that will suffice for all the different LAFs you use.
> 
> A related problem is that different type faces 10 point font vary
> considerably in size.  I work out adjustment factors for all possible
> fonts.

Well whatever works but if I'm on the right lines then the OP's problem
relates to an inadequate GUI layout that does not allow components to
assume their preferred size (even if they are subsequently not
supposed to be resizeable).

If changes in L&F (or even just default font sizes) mean that things
then get clipped probably their containers are preventing them from
being big enough.

Cue layout discussions, use of TableLayout etc
http://www.clearthought.info/sun/products/jfc/tsc/articles/tablelayout/index.html

Back to comp.lang.java.gui | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Label clipping using Nimbus L&F Fred <fred.l.kleinschmidt@boeing.com> - 2011-08-19 13:30 -0700
  Re: Label clipping using Nimbus L&F Tom <tom400f@gmail.com> - 2011-08-19 22:07 +0000
    Re: Label clipping using Nimbus L&F "John B. Matthews" <nospam@nospam.invalid> - 2011-08-20 03:58 -0400
  Re: Label clipping using Nimbus L&F Roedy Green <see_website@mindprod.com.invalid> - 2011-08-19 17:11 -0700
    Re: Label clipping using Nimbus L&F Tom <tom400f@gmail.com> - 2011-08-20 11:07 +0000
  Re: Label clipping using Nimbus L&F "John B. Matthews" <nospam@nospam.invalid> - 2011-08-20 03:54 -0400

csiph-web