Abstract
A gradient creates a smooth transition between two or more colors, and is often used in graphic design to create an illusion of depth or a 3D effect. Until quite recently, the only cross-browser way to add a gradient to an element was to use a background image. With CSS3, you can generate a gradient simply by specifying its colors and shape. CSS supports both linear gradients—in which the colors fade smoothly from one to the next in a straight line—and radial gradients, which emerge from a single point with the colors spreading out in a circle or ellipse. You can also create gradients that repeat the same sequence of colors indefinitely.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Rights and permissions
Copyright information
© 2012 David Powers
About this chapter
Cite this chapter
Powers, D. (2012). Creating Gradients Without Images. In: Beginning CSS3. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4302-4474-5_19
Download citation
DOI: https://doi.org/10.1007/978-1-4302-4474-5_19
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4302-4473-8
Online ISBN: 978-1-4302-4474-5
eBook Packages: Professional and Applied ComputingProfessional and Applied Computing (R0)Apress Access Books