Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member
Dreamweaver makes it dirt simple to change the color of any text via CSS. You can choose from the basic palette of the color picker or extended system colors, or enter a color value directly, or my favorite, sample from any design element on your screen. So I have here open the index.htm file found in the Chapter 4 > 04_02 folder. A common application of color is bringing a design or comp to the Web accurately. Let's walk through an example with the tag found on this page in this area here.
So I'm going to put my cursor in the < em> tag and then create a new rule and let's limit it to just the tag and keep it stored in main.css. I'll click OK. So now I'm ready to enter in my color value, but I don't have it on the screen; I have it in a comp. So I'm going to switch over to my graphics program, Fireworks, where I have my comp design and if I go in and select some of this purple text here, down in the Property Inspector, I'll see that color up here, and if I expand the Color Picker, I can see the hex value, which I can then click into and copy, using a Command+C or Ctrl+C on the PC, of course.
I'll push Escape to get out of that, and now let's go back to Dreamweaver and I'm ready to enter in that value directly into the color field. So I'll do a Command+V to paste it in, press Tab and there's my same color. Click OK, and the color is immediately applied. Another approach is to use Dreamweaver's built-in color sampling ability to pull a color directly from your site. Let's use that technique to create the colors for the various link states. So I'm going to create a new rule and it is a Compound Rule, but it's for the a:link and a:visited states.
I'll click OK and I'm going to sample kind of the gold area that's found between Services and Portfolio right here. Now this is a gradation so we're not going to get something exactly right, but I want this type of feel for it. So I'll go ahead and open up the Color Picker and now that I have my eye dropper, I can go onto the page and just choose a color value. If I want to move around a little bit, I can see that there's a slight variation, but it's largely the same color. So I'll click on one of those and then click on OK.
Now for this, I'm going to drop out of Live View and go into Design view just because I like this kind of bright yellow that we see here. So I'm going to create the Hover Rule, also the active state, and this time, I'll move down and the color I'll sample right from there, and I can see it is actually a bright yellow. Now I could have chosen that right from the Color Picker, but sometimes you see something on your screen, and I'll just say, oh, that's exactly right, that's exactly what I want, and you can go and grab it. So I'll click OK.
Now let's say that the client comes back, and I'll go into Live View here, and scroll down to where the links are, so you can see them in action, and as I hover over them, I get that bright yellow appearance. Now let's say that the client comes back and says the yellow hover is too bright and they want something a little more subtle. You can use the system color tools to achieve that goal. I'm going to go and click on one of the links so that I can get the hover state showing up in my CSS STYLES panel, and then select that, and now I'll select the color swatch to bring up the Color Picker, and I'll open up the system Color Picker.
Now, of course, the system Color Picker is different for Macs than it is for PCs, but let me demonstrate one technique on the Mac, and then I'll describe it for you on the PC. So I'm going to go to the color sliders here and then from the dropdown list, choose HSB sliders and we'll set the Saturation about half way, around 50%, and I'll click OK and then Escape to drop that down. Now you can see what that did was it made it a little bit less and as I go over it, it's not quite as bright.
Now on Windows, the system Color Picker is calibrated with a hue saturation luminance scale, rather than the HSB scale, and to achieve the same effect, you would change the luminance value to 180. You can do this manually or by dragging this slider up towards the white about half way. Adding color to your text can help bring a page to life and coherence to a design. Dreamweaver's Color tools make it simple.
Get unlimited access to all courses for just $25/month.Become a member
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.
Your file was successfully uploaded.