# Javascript: FormattingStyle.getFontSize Method

> Gets the font's size of the style.

- **Product:** DS Server
- **Section:** Reference
- **Kind:** Method
- **Introduced:** 28.0
- **Path:** DS Server > Reference > JavaScript API > Javascript: FormattingStyle.getFontSize Method
- **244 words**
- **Web URL:** https://docs.textcontrol.com/ds-server/reference/javascript/formattingstyle/getfontsize-method/
- **LLMs URL:** https://docs.textcontrol.com/ds-server/reference/javascript/formattingstyle/getfontsize-method/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/ds-server/reference/javascript/formattingstyle/getfontsize-method/llms-full.txt

---

### Description

Gets the font's size of the style.

### Syntax

```javascript
<void> FormattingStyle.getFontSize(<RequestNumberCallback> callback)
```

### Parameters

| Parameter | Description |
|---|---|
| callback | Receives the font's size of the style. |

### Examples

The following example demonstrates `FormattingStyle.getFontSize` in a practical document-editing workflow. It gets the font's size of the style.

```javascript
function inspectFontSize(formattingStyle) {
    formattingStyle.getFontSize(
        function(result) {
            console.log("get font size result:", result);
        }
    );
}
```

---

## Nearby

- **Previous:** [Javascript: FormattingStyle.getFontName Method](https://docs.textcontrol.com/ds-server/reference/javascript/formattingstyle/getfontname-method/llms-full.txt)
- **Next:** [Javascript: FormattingStyle.getForeColor Method](https://docs.textcontrol.com/ds-server/reference/javascript/formattingstyle/getforecolor-method/llms-full.txt)
