> For AI agents: the complete documentation index is available at /next/llms.txt, the full documentation bundle is available at /next/llms-full.txt.

# font-style

APISummary
## Introduction

Set the font style.

## Examples

**This is an example below: css-api**

**Entry:** `src/font-style`
**Bundle:** `dist/font-style.lynx.bundle`

```tsx
import { root } from "@lynx-js/react";
import "./index.scss";

const FontStyle = () => {
  return (
    <scroll-view className="root" scroll-orientation="vertical">
      <view className="fixed_area">
        <text>
          font-style: 无
        </text>

        <text style={{ fontStyle: "normal" }}>
          font-style: normal 普通
        </text>

        <text style={{ fontStyle: "italic" }}>
          font-style: italic 斜体
        </text>

        <text style={{ fontStyle: "oblique" }}>
          font-style: oblique 倾斜
        </text>
      </view>
    </scroll-view>
  );
};

root.render(<FontStyle />);

```

v0.11.0



## Syntax

```css
font-style: italic;
font-style: oblique;
font-style: normal;
```

### Values

- **`normal`**
  Selects a font that is classified as normal within a font-family.

- `italic`
  Selects a font that is classified as `italic`.

- `oblique`
  Selects a font that is classified as `oblique`.

## Formal definition

| Initial value | normal |
| Applies to | text |
| Inherited | yes |
| Animatable | no |


## Formal syntax

```
font-style = normal | italic | oblique
```

## Differences from the Web

- Only support `normal`, `oblique` and `italic`

- [mdn:font-style](https://developer.mozilla.org/en-US/docs/Web/CSS/font-style)

## Compatibility

**Compatibility Table**

**Query:** `css.properties.font-style`

[Source](https://github.com/lynx-family/lynx/blob/develop/tools/css_generator/css_defines/62-font-style.json) · [MDN](https://developer.mozilla.org/en-US/docs/Web/CSS/font-style)

| Feature | Android | HarmonyOS | iOS | macOS | Windows | Web |
| --- | --- | --- | --- | --- | --- | --- |
| font-style | Yes (1.0) | Yes (3.4) | Yes (1.0) | Yes (1.0) | Yes (1.0) | Yes |

**`font-style`**

**Specifications:**

