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


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

Re: JTable CellRendererPane placement

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!eternal-september.org!feeder.eternal-september.org!mx05.eternal-september.org!.POSTED!not-for-mail
From Daniele Futtorovic <da.futt.news@laposte-dot-net.invalid>
Newsgroups comp.lang.java.gui
Subject Re: JTable CellRendererPane placement
Date Thu, 09 May 2013 00:59:19 +0200
Organization A noiseless patient Spider
Lines 23
Message-ID <kmel58$8tq$1@dont-email.me> (permalink)
References <4feceb84-2eac-4dae-97ae-c2a1decbddae@googlegroups.com>
Mime-Version 1.0
Content-Type text/plain; charset=ISO-8859-1
Content-Transfer-Encoding 7bit
Injection-Date Wed, 8 May 2013 22:55:37 +0000 (UTC)
Injection-Info mx05.eternal-september.org; posting-host="8e103db3a4f21801713a9e44848762c0"; logging-data="9146"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/e6lKN52GoOjQBmgG4FgUY"
User-Agent Mozilla/5.0 (Windows NT 5.1; rv:17.0) Gecko/20130328 Thunderbird/17.0.5
In-Reply-To <4feceb84-2eac-4dae-97ae-c2a1decbddae@googlegroups.com>
Cancel-Lock sha1:vX9XgUoYAS/hp2yc+tbl5LyQJuU=
Xref csiph.com comp.lang.java.gui:5338

Show key headers only | View raw


On 08/05/2013 22:34, FredK allegedly wrote:
> I have a JTable with two columns and a JTableHeader.
> The left column contains strings, and the right column contains JTextFields.
> Clicking on a header sorts the rows.
> 
> If I click in one of the text fields to begin editing it ( say, for
> instance, in row 7), and then click in the header to sort the table, 
> the CellRendererPane (and the CellEditor) remain over the original position
> (row 7), even though that field is now in row 2. When I click in the editor
> it *LOOKS* like I am editing what is now in line 7, but in fact I am still
> editing what is now in row 2. 
> 
> If I click over any other row, or resize the table, everything gets 
> updated and the editor moves to the proper position.
> 
> After sorting, how can I ensure that the editor moves be over the
> new position?
> 

Unless someone else has an answer ready for you, could you post an SSCCE?

-- 
DF.

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


Thread

JTable CellRendererPane placement FredK <fred.l.kleinschmidt@gmail.com> - 2013-05-08 13:34 -0700
  Re: JTable CellRendererPane placement Daniele Futtorovic <da.futt.news@laposte-dot-net.invalid> - 2013-05-09 00:59 +0200
    Re: JTable CellRendererPane placement "John B. Matthews" <nospam@nospam.invalid> - 2013-05-08 20:15 -0400

csiph-web