🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: JTable - row color

#11907
From: S�bastien GRENIER
Date: Fri, 12 Mar 1999 00:00
23 lines
1238 bytes
As mentionned in many other posts, you can use
your personnal CellRenderer for your JTable.

Default renderer is a JLabel with specific attributes,
depending on the column type (class).

You can subclass a JLabel and use it as CellRenderer,
changing the color of the renderer depending on the
row and column parameters in the call of
getCellRendererComponent(.....)

Dale Cooper a �crit dans le message <36E88D0E.6B1F93F5@cooper.cz>...
>Hallo there,
>
>I just want to know whether it is possible to set different colors for
>single row in JTable (jdbTable, DataGrid) - meaning different background
>and text color...
>I need to visually "split" the table horizontally.
>Did not find it anywhere....
>
>TIA,
>Dale
>
Technical Details
Message-ID: <7caofe$n8u15@forums.borland.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <36E88D0E.6B1F93F5@cooper.cz>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 111d45,f7cfc32da061f149
X-Google-Attributes: gid111d45,public
From: "S�bastien GRENIER" <sgrenier@NOSPAM.atos-group.com>
Subject: Re: JTable - row color
Date: 1999/03/12
Message-ID: <7caofe$n8u15@forums.borland.com>
X-Deja-AN: 454141446
References: <36E88D0E.6B1F93F5@cooper.cz>
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
Organization: Another Netscape Collabra Server User
Newsgroups: borland.public.jbuilder.java.swing