sudara / melatonin_inspector

A JUCE module that gives you the ability to inspect and visually edit (non-destructively) components in your UI.
MIT License
156 stars 18 forks source link

Refx/property improvements #46

Closed FigBug closed 1 year ago

FigBug commented 1 year ago

Made more properties settable Added named properties to the list Added colour picker for juce colours

FigBug commented 1 year ago

I copy / pasted this colour picker from gin, could probably be restyled to look like yours

Regarding layout, shouldn't the tree be on the left, and then the properties being displayed on the right? Feels backwards right now.

sudara commented 1 year ago

Thanks, I'll take a look!

Feels backwards right now.

Fair enough, it's an artifact of how it was first built (everything in one col). I was going to start off by putting the right column into its own wrapper component (see: the unused tree_component) but got distracted... maybe @dikadk remembers if there was another reason for this layout, I could be forgetting.

sudara commented 1 year ago

Two questions for you:

dikadk commented 1 year ago

Thanks, I'll take a look!

Feels backwards right now.

Fair enough, it's an artifact of how it was first built (everything in one col). I was going to start off by putting the right column into its own wrapper component (see: the unused tree_component) but got distracted... maybe @dikadk remembers if there was another reason for this layout, I could be forgetting.

I think reason for tree being on the right is to prevent "jumpy" behavior for UI in full vs collapsed mode. Something like that.

FigBug commented 1 year ago

Also, I'm missing seeing wantsKeyboardFocus in the hierarchy, so I guess I'd put in an less bright icon for that and move the icons to the end of the label unless you object.

Originally I had the icon at the end, I thought it looked funny. But it doesn't really matter to me.

FigBug commented 1 year ago

Do you have colors throughout the component hierarchy or do they all tend to be at the top level?

throughout

Are you using the functionality you added where you can pass in a PropertiesFile* to melatonin::inspector's constructor or was it just to offer the option? If you aren't using, I might simplify (need to pass the settings to components or use a SharedResourcePointer)

I'm passing nullptr, don't use the juce propertiesfile in my app

sudara commented 1 year ago

Closing, as these commits are included in #48