Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

adding log as a scrolling JList within aJDialog

RichFNov 26 2010 — edited Dec 3 2010
I am designing the final item for the Help menu of the [url http://r0k.us/graphics/SIHwheel.html]Interactive Color Wheel. It will be a log of user actions, to replace and extend the System.out.println() info currently going to the Java Console.

Preliminary Design
1) implemented as a single-instance JDialog containing a scrolling JList
2) typically 2 rows per entry. background color for both rows equal to selected color
3) potential 3rd row if color name mismatch (a limitation of quantized color space)
4) potential 4th row when user has Quantization Error toggled on
5) created invisibly. records events whether visible or not

The 4 rows would look something like:
@Frangipani -- #ffd9b3, luma = 217, complement = #b3d9ff
   r,g,b = 255, 217, 179  --  h,s,b =  30°, 29.8%, 255
   Frangipani (FFDEB3) != NTC's Light Apricot (#FDD5B1), false
   hqe(#FDD5B1) = (2r, 4g, 2b) = 3%
Normally, only the first two lines would exist. The third and/or fourth lines are conditional.

Concerns
1) Is there a practical or actual limit to how many items in JList?
2) Whether or not limit, would it be beneficial to discard earliest rows when beyond some pre-determined limit?
3) Is there an easy way to enable copying JList rows (or dragged text) to clipboard?
.... If not, I'll add button to enable copying selected row(s) to clipboard.
4) Is a scrolling JList actually the best way to handle all this?

The clipboard stuff is based on user feedback. Some folks are looking for specific color(s), and they would like an easy way to capture that info.

Any feedback about my concerns, or even the general design, would be appreciated. Thank you.

-- Rich

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Dec 31 2010
Added on Nov 26 2010
22 comments
250 views