I think itโs safer to always apply color along with the background image.
The browser cannot support the png format, or the image request may fail (for any reason).
Color on the other hand will always apply. See this as a kind of backup plan :-)
Edit:
In fact, you do not need the image file to just create a color translucent overlay. Just background-color
and opacity
enough.
I think the exact reason is that jquery ui allows you to apply textures (you can select them or turn them off in ThemeBuilder on the jquery ui website. That's why the image is used even if the texture is not selected. The texture is not really " flat "texture. In fact, you can see it in the image file name:
ui-bg_flat_75_aaaaaa_40x100.png
- flat = no texture, flat color
- 75 = texture opacity (using png alpha channel)
- aaaaaa = texture color
- 40x100 = template size
If you apply the โwhite linesโ texture to the overlay in ThemeBuilder, it will generate image files with this name:
u-bg_ <strong> white-lines _75_aaaaaa_40x100
The first part of the answer is still valid, but this is the main reason in the case of jquery ui.
Didier ghys
source share