w:i (Italic)
Applies italic formatting to the text of the run.
Parent elements
Description
w:i applies italic formatting to all text in the run. It is an on/off toggle property defined in ECMA-376 Part 1 §17.3.2.16.
When present without a w:val attribute, or with w:val="true", the run is italicised. Setting w:val="false" cancels italic, overriding any italic inherited from a parent style. The complex-script equivalent is w:iCs.
Attributes
| Attribute | Type | Possible Values | Description |
|---|---|---|---|
w:val |
ST_OnOff |
true, 1, on (italic on) / false, 0, off (italic off). Omitting the attribute is equivalent to true. |
Toggles italic on or off. |
Examples
<!-- Italic text -->
<w:r>
<w:rPr>
<w:i/>
</w:rPr>
<w:t>Italic text</w:t>
</w:r>
new Run(
new RunProperties(new Italic()),
new Text("Italic text"));
<!-- Cancel inherited italic from parent style -->
<w:rPr>
<w:i w:val="false"/>
</w:rPr>
new RunProperties(
new Italic { Val = false }); // w:val="false" cancels italic
<!-- Italic with complex script italic matched -->
<w:rPr>
<w:i/>
<w:iCs/> <!-- Complex script (Arabic/Hebrew) also italic -->
</w:rPr>
new RunProperties(
new Italic(),
new ItalicComplexScript()); // Ensure RTL text is italic too
Emphasis & Semantic Use Cases
When to Use Italic
Semantic & Typographic Uses:
- Foreign Words: “café”, “née”, “et cetera”
- Book/Publication Titles: “The Great Gatsby”, “Nature magazine”
- Variable Names: x, y, mathematical symbols
- Emphasis: Important concepts (use sparingly)
- Thought/Speech: “What time is it?” she wondered
- Scientific Names: Homo sapiens, biological taxonomy
- Placeholders: Enter your name here
- Slight Emphasis: Softer than bold
Italic Style Behavior
<!-- Apply italic -->
<w:rPr>
<w:i/> <!-- Uses font's italic variant -->
<w:i w:val="true"/> <!-- Explicit on -->
</w:rPr>
new RunProperties(
new Italic()); // w:i applies italic formatting
<!-- Cancel inherited italic -->
<w:rPr>
<w:i w:val="false"/> <!-- Override parent style -->
</w:rPr>
new RunProperties(
new Italic { Val = false }); // Override parent style
Slant Angle: Italic typically slants ~12 degrees depending on font design.
Complex Script Italic
Always pair italic with complex-script equivalent:
<!-- Latin + RTL consistent styling -->
<w:rPr>
<w:i/> <!-- Latin italic (slanted) -->
<w:iCs/> <!-- Complex script italic (Arabic/Hebrew) -->
</w:rPr>
new RunProperties(
new Italic(), // Latin italic
new ItalicComplexScript()); // Complex script italic
Note: Some complex scripts don’t have true italic variants; fallback may be oblique or synthetic.
Emphasis Combinations
Effective Layering:
- Italic only:
<w:i/>(moderate emphasis) - Italic + Bold:
<w:b/><w:i/>(strong emphasis, use rarely) - Italic + Color:
<w:i/><w:color w:val="0000FF"/>(blue italic for links, comments) - Italic + Underline:
<w:i/><w:u w:val="single"/>(emphasis + focus, use carefully)
Best Practices:
- Limit italic to <3% of body text
- Prefer semantic markup (style-based) over inline italic
- Never italicize entire paragraphs
- Use color instead of italic when possible for better accessibility
Citation/Attribution Example
<!-- Italic text reference -->
<w:r><w:rPr><w:i/></w:rPr><w:t>Pride and Prejudice</w:t></w:r>
<w:r><w:t> by </w:t></w:r>
<w:r><w:rPr><w:i/></w:rPr><w:t>Jane Austen</w:t></w:r>
// "Pride and Prejudice" by "Jane Austen" with titles italicized
new Paragraph(
new Run(new RunProperties(new Italic()), new Text("Pride and Prejudice")),
new Run(new Text(" by ")),
new Run(new RunProperties(new Italic()), new Text("Jane Austen")));
Notes
- Toggle Pattern:
w:iis an on/off toggle; presence (orw:val="true") enables italic,w:val="false"disables. - Inheritance Cancellation: Use
<w:i w:val="false"/>to cancel italic inherited from parent style. - Boolean Values: Omit
w:valor usetrue/1/onto enable; usefalse/0/offto disable. - Complex Script: Always include
w:iCsfor runs with Arabic, Hebrew, or complex scripts. - Visual Style: Italic slants text at ~12 degrees depending on font.
- Semantic Use: Indicates emphasis, titles, foreign words, variable names.
- Accessibility: Screen readers may announce italic text; use sparingly; color is often more accessible than style changes.
- Print Rendering: Italic renders consistently across all printer types.
- Font Support: All common fonts have italic variant; fallback to oblique if true italic unavailable.
- Compatibility: Italic formatting is supported in all Office versions.
- Readability: Excessive italic reduces readability; use only for semantic purposes.
- Web Safety: Italic renders reliably online; safe for web-destined documents.