RPTools/maptool

[Refactoring]: Campaign Properties - Reworking Token Properties Edit Table

bubblobill opened this issue · 11 comments

[Refactoring]: Campaign Properties - Reworking Token Properties Edit Table

@cwisniew Re: Token Properties edit table. I cannot for the life of me work out how to expose the table cell renderer for cells in the table header in order to setToolTipText(). Any suggestions?

@cwisniew Re: Token Properties edit table. I cannot for the life of me work out how to expose the table cell renderer for cells in the table header in order to setToolTipText(). Any suggestions?

JTable tooltips are not as straightforward as other controls, but before I answer your question, can we change the names of the columns to make more sense? or put an explanatory bit of text above the table instead? Tooltips have problems, one of those being users don't expect them as much, so never check to see if they are there. If you can't think of a better way then we can discuss how to do the tooltips

I'll add a panel with help/clarification text. There should be enough room. If it looks pretty enough we will go with that.

image
Added descriptive text above.
Shuffled the stat-sheet combo boxes up a row.
Good enough?

@cwisniew I have;

  • moved all the properties buttons into one group at the top,
  • added some styling,
  • shuffled the column order,and
  • set columns to user resizable.

I have a problem though. TextFieldEditorButtonTableCellEditor "panel" does not scale to fit. Obvioiusly needs something set to take up available width. Is there an "autofit" parameter I can set on it and the text field to fill out the space?
image

Lots of ways to order these fields, but I think they should be ordered mirroring the description boxes at the top.

And since Display Name and Short Name are stat sheet items, they should probably be in the "Stat Sheet" description box. Then you can remove the "Used in Stat Sheet and Character Sheet" text. Short Name could probably be indented under Display Name in the description box with a note that it supersedes the Display Name.

All the text boxes should be either left justified or centered. Mixing and matching tends to look odd.

And, cosmetically, I've always preferred a more subtle alternating background colors for rows over the "lined chart" look. Not sure if that's more challenging with theme differences.

I haven't tested the column shading in other themes yet. It's entirely possible it will fail.
I haven't been able to work out which bits of theme are determining colours, or indeed how to get colours from the theme in order to manually override the defaults. At present it is drawing the difference by setting a transparent black background in the cellRenderer. Something I expect will not fly well in dark themes.
I may have to explore and fiddle theme implementation before I can get a useful theme responsive styling. If JavaFX is involved in the form I might be able to CSS my way out of it.

I find it off that the check boxes are left most, this doesn't seem to line up with what the brain expects after decades of spreadsheets and tables in text books. The name of the property should be leftmost as everything relates to that. Also it shouldn't be centered.

I will look at what's up with the width on the button text field tomorrow.

Oh also since none of the other tables have alternating rows colors it would be odd to do it in this one

You don't get alternating colours for columns and rows. I've never seen it done well. Columns get shaded to help separate and group associated bits. Rows get horizontal lines. Adding vertical lines makes it look naff so I'm not going to do that.
Currently trying to get the column width settings to behave. The auto fit seems to think everything should be the same size, and size-to-fit does the same.
I got the heading row to wrap text but now it won't vertically align.
My aesthetic is killing me.