🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #10779

jtree problem

#10779
From: Vincent Nuijten
Date: Tue, 10 Aug 1999 00:00
20 lines
1277 bytes
hi

i am using a JTree. for it i have implemented my own TreeCellRenderer which
extends the JPanel class.
This size of the cells depends on the visual size of the tree, i want to
avoid horizontal scrolling.
the problem is that whenever the size of the tree changes the cells are not
rendered again.
once they are collapsed they are rendered. their paint methods is called on
resizing but the method
getPreferredSize is never called.

does anyone know how to make cells in jtrees dynamic of size. i think the
tree must be drwan from scratch again
or a call to the cell's getPreferredSize must be forced.
can anyone please help me out?

tia
greetings
casper
Technical Details
Message-ID: <7opd6m$a8b$1@zonnetje.nl.uu.net>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,2351744ee7c9d6f7,start
X-Google-Attributes: gid111d45,public
From: "Vincent Nuijten" <info@c-content.nl>
Subject: jtree problem
Date: 1999/08/10
Message-ID: <7opd6m$a8b$1@zonnetje.nl.uu.net>
X-Deja-AN: 511060345
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.2106.4
X-Complaints-To: abuse@nl.uu.net
X-Trace: zonnetje.nl.uu.net 934295574 10507 212.136.248.72 (10 Aug 1999 14:32:54 GMT)
Organization: UUNET-NL (http://www.nl.uu.net)
NNTP-Posting-Date: 10 Aug 1999 14:32:54 GMT
Newsgroups: borland.public.jbuilder.java.swing