How do you change the text color in an outline?

  1. Select the text you want to change.

    To change all of the text in a text box or table cell, select the text box or table cell.

  2. In the Format

    How do you change the text color in an outline?
     sidebar, click the Text tab, then click the Style button near the top of the sidebar.

  3. Click the pop-up menu below the Font section and choose Image fill, or choose Advanced Image Fill if you want to add a tint to the image.

  4. Click Choose, navigate to your photos, then double-click an image with a .jpg, .png, or .gif filename extension.

  5. If you chose Advanced Image Fill, click the color well (to the right of the Choose button) and select a tint color.

    To make the tint more or less transparent, click the color wheel, then drag the Opacity slider.

  6. If the image doesn’t look the way you expected or you want to change how the image fills the text, click the pop-up menu above the Choose button, then choose an option:

    • Original Size: Places the image inside the text without altering its original dimensions. To resize the image, drag the Scale slider.

    • Stretch: Resizes the image to fit the text’s dimensions, which might change the image’s proportions.

    • Tile: Repeats the image inside the text. To resize the image, drag the Scale slider.

    • Scale to Fill: Makes the image larger or smaller to leave no space in the text.

    • Scale to Fit: Resizes the image to fit the text’s dimensions, but maintains the image’s proportions.

The outline-color CSS property sets the color of an element's outline.

Try it

Syntax

/*  values */
outline-color: #f92525;
outline-color: rgb(30, 222, 121);
outline-color: blue;

/* Keyword value */
outline-color: invert;

/* Global values */
outline-color: inherit;
outline-color: initial;
outline-color: revert;
outline-color: revert-layer;
outline-color: unset;

The outline-color property is specified as any one of the values listed below.

Values

The color of the outline, specified as a .

invert

To ensure the outline is visible, performs a color inversion of the background. Note that browsers are not required to support this value; if they don't, this keyword is considered invalid.

Description

An outline is a line that is drawn around an element, outside the border. Unlike the element's border, the outline is drawn outside the element's frame, and may overlap other content. The border, on the other hand, will actually alter the page's layout to ensure that it fits without overlapping anything else (unless you explicitly set it to overlap).

It is often more convenient to use the shorthand property outline when defining the appearance of an outline.

Accessibility concerns

Custom focus styles commonly involve making adjustments to the outline property. If the color of the outline is adjusted, it is important to ensure that the contrast ratio between it and the background the outline is placed over is high enough that people experiencing low vision conditions will be able to perceive it.

Color contrast ratio is determined by comparing the luminosity of the text and background color values. In order to meet current Web Content Accessibility Guidelines (WCAG), a ratio of 4.5:1 is required for text content and 3:1 for larger text such as headings. Large text is defined as 18.66px and bold or larger, or 24px or larger.

  • WebAIM: Color Contrast Checker
  • MDN Understanding WCAG, Guideline 1.4 explanations
  • Understanding Success Criterion 1.4.3 | W3C Understanding WCAG 2.0

Formal definition

Formal syntax

outline-color = 
|
invert

Examples

Setting a solid blue outline

HTML

<p>My outline is blue, as you can see.p>

CSS

p {
  outline: 2px solid; /* Set the outline width and style */
  outline-color: #0000ff; /* Make the outline blue */
  margin: 5px;
}

Result

Specifications

Specification
CSS Basic User Interface Module Level 4
# outline-color

Browser compatibility

BCD tables only load in the browser

See also

How do you change a text box outline?

Select the text box or shape. If you want to change multiple text boxes or shapes, click the first text box or shape, and then press and hold Ctrl while you click the other text boxes or shapes. Click the Format tab, click Shape Outline, point to Dashes, and then click the style you want.

How do you outline text in Word?

Add an outline, shadow, reflection, or glow text effect.
Select your text or WordArt..
Click Home > Text Effects..
Click the effect you want. For more choices, point to Outline, Shadow, Reflection, or Glow, and then click the effect you want..

How do I change the color of text in Word?

You can change the color of text in your Word document. Select the text that you want to change. On the Home tab, in the Font group, choose the arrow next to Font Color, and then select a color. You can also use the formatting options on the Mini toolbar to quickly format text.

How do I change text color in Corel Draw?

In the text color area, click the Fill settings button , and modify the settings in the dialog box. In the text background color area, choose a fill type from the Background fill type list box, open the Fill picker, and then click a color or a fill.