Display

I don't know if this is the correct place to put this but it seems the most correct that I can find. If it is not I would be happy to go where it needs to go if I just knew where.

I am a designer/developer and have run into this problem many times in the display attribute. Specifically speaking of C# and VS but also in general with validation.

 It seems the convention to show / hide a validation tag is to change the inline style from display:none; to display:inline; This seems accurate enough because most validation is inline, but occasionally I have needed to add a display: block; to the element. When I need to do that the inline display overrides my block display. Putting a !important in the stylesheet will override the display:none;

I mention this because it seems that it would be an appropriate value for the display attribute. Would there be a display: default; ? The functionality would be to have an element revert back to the default display, for example. If I have a <p> the default would be block. There is a little more to the functionality which might make default not an appropriate keyword. So maybe this could be two values. Default and 'defined' (this can be changed of course) The second would take the last defined value, for instance if I had a <span> the default being inline, I could define a display block in the stylesheet, then in the inline style I would be able to say display: defined; and it would render the way the stylesheet defined the element to display, if there is no display definition the element would use the default display.

I hope that makes sense.

Thanks,

Colt Pini

Received on Tuesday, 27 April 2010 08:30:08 UTC