MindFusion.Charting for JavaScript Programmer's Guide
Graphics.measureString Method
See Also
Collapse All Expand All Language Filter: All Language Filter: Multiple Language Filter: None Language Filter: C# Language Filter: Visual Basic Language Filter: Java Language Filter: JavaScript Language Filter: C++ Language Filter: XAML

C#
Visual Basic
Java
JavaScript
C++
XAML

Gets the size of the specified string.

Namespace: MindFusion.Drawing
File: Graphics.js

## Syntax

JavaScript Copy Code
function measureString (text, font, [width])

### Parameters

text

  Type: String
  The string to measure.

font

  Type: Font
  The font to use.

width
  Optional.

  Type: Number
  The maximum width.

### Return Value

Type: Size
The size of the given string when drawn with the given font.

## See Also

Graphics Members
Graphics Class
MindFusion.Drawing Namespace