Path: csiph.com!eternal-september.org!feeder.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: Daniele Futtorovic Newsgroups: comp.lang.java.programmer Subject: Re: Displaying a ragged array Date: Wed, 19 Sep 2018 18:12:20 +0200 Organization: A noiseless patient Spider Lines: 30 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Injection-Date: Wed, 19 Sep 2018 16:12:55 -0000 (UTC) Injection-Info: reader02.eternal-september.org; posting-host="0c724807a73e5e2491905503275baeb2"; logging-data="29875"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/o1GPDU87UYuNI6aca8LtU" User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 Cancel-Lock: sha1:A7ABVGFm6xCxr4EmPRyFxXismKE= In-Reply-To: X-Antivirus-Status: Clean Content-Language: en-GB X-Antivirus: AVG (VPS 180919-2, 09/19/2018), Outbound message Xref: csiph.com comp.lang.java.programmer:38601 On 2018-09-18 01:43, Martin Gregorie wrote: > On Mon, 17 Sep 2018 23:29:39 +0200, Daniele Futtorovic wrote: >> I can see two options. >> One would be to display comments separately, in a dedicated UI >> component, when a specific data row is selected. This assumes that >> comment lines "belong" to a specific data row. >> > I'm still thinking about that. You're right that they belong in a > specific row, so should be displayed at the correct position(s) in the > row list. I was thinking of a separate component, say a TextArea in some corner, for the comment, which would get shown when the row it belongs to is selected. It depends on whether you need to see comments all the time, or if it's fine just having it when the row is selected. >> The other would be to use a JTreeTable. I'd love to get you a link for >> that, but that Oracle's Java site is so goddamn fucking useless I >> haven't been able to find the relevant article. I think it was somewhere >> in the Swing tutorials. >> > Is that like a JTree, but with the content of branches displayed > horizontally rather than hanging down as in a JTree? It doesn't appear to > be part of the Java 8 standard class library. I might be misremembering it. Doc says it's a JTable "using a JTree as a renderer (and editor) for the cells in a particular column in the JTable". -- DF.