dennismagno / metroframework-modern-ui

My humble attempt to bring the new Modern UI alias Metro UI of Windows 8 to .NET Windows Forms applications.
http://dennismagno.github.io/metroframework-modern-ui
Other
861 stars 1.08k forks source link

Controls don't use custom colors, or styles #89

Open Jiraiyah opened 5 years ago

Jiraiyah commented 5 years ago

This is the designer, not only button but also notice the top section with labels http://prntscr.com/lu8pmr and this is run time : http://prntscr.com/lu8pz5 nothing is working !, every now and then i see red on button but when i move the mouse on the section, it's lost. After some try i found this : http://prntscr.com/lu8tlo the button is sitting inside a panel, when the whole window loses focus, it's using my colors giving back focus to the window, or any panel gets focused, the button loses style. I think every control has this Issue.

On a side note, WHY using a xml solution for styling? you can simply develop a type class with all the color properties. for each control or frame, add an instance of this type or let the user instantiate a global styling and assign it to everything manually when he is adding stuff. alternatively, you can use the concept of manager but, this way, we can easily instantiate a copy of the type class, tweak it to out hear desire, and assign it to the manager or directly to the controls if we want to. Also, if the user assigned his copy to a control, the manager should NOT override it! This way, we can easily see stuff happening in the editor, tweak the colors inside the property window and so on and so forth. your style and them properties, will now behave more like a switch case that would internally switch the Type Class's PARAMETERS when they are changed ! I know it means one type instance PER control and frame, but IMO it's a much more desirable and manageable approach. After all, we are building winform app here, what's the difference of having 1-5 extra mega bytes because of those instanced colors?

Jiraiyah commented 5 years ago

If you are insisting on using xml (THAT i didn't find any on the repo to play with the colors), you should add a stand alone executable program that will let us choose colors, and hit a button and get a generated xml file, with enough documentation on where to put this xml, and how to handle it.

BUT, all of this is irrelevant to the issue i opened this ticket for.

Jiraiyah commented 5 years ago

Farther testing this, looks like problem happens when controls are sitting inside metro panel and not metro window itself and only for button so far (I didn't flag the labels to use custom color)!

Jiraiyah commented 5 years ago

Another issue, we don't have control on the hovered states of button. http://prntscr.com/lu90ov This one is sitting out side of panel and word nicely BUT image