Custom Styling for Global Features
Background Color of Scalar Pages
CSS accepts a number of color values: hexadecimal colors (e.g. #F1F1F1), RGB colors (e.g. 255,255,255) and predefined color names (e.g. red). To change the page background color for a Scalar project one needs to begin by declaring the selector for the html element that defines the body of a document (body), the property they wish to modify (background-color) and then decide how they want to define the color of their choice. To change the page background color for a Scalar project to red using a predefined color name (see a list of cross-browser redefined color names here) one would insert:
body {background-color:red;}
To change the page background color for a Scalar project to black using hexadecimal colors, one would insert:body {background-color:#000000;}
And to change the page background color for a Scalar project to bright blue using RGB colors, one would insert:
body {background-color:rgb(0,0,255);}
Learn more about CSS background colors here.
Styling Links on Scalar Pages
All linked text can be stylized with any CSS property: font color, font size etc... What's more, every link has four separate "states" which can be individually stylized. These four states are as follows:
- a:link - a normal link that has not yet been visited
- a:visited - a link which the user has already visited
- a:hover - a link when the user moves the mouse cursor over it
- a:active - a link at the moment it is clicked
a:link {font-size:20px;}
And to change the color of text for a link already visited by the user to red using a predefined color name, one would start by declaring the selector a:visited, the property they wish to modify (color) and then declare the value red:
a:visited {color:red;}
Previous page on path | Custom Styling, page 9 of 10 | Next page on path |
Discussion of "Custom Styling for Global Features"
Add your voice to this discussion.
Checking your signed in status ...