enum Cairo::SvgUnit

Overview

SvgUnit used to describe the units valid for coordinates and lengths in the SVG specification.

###See also

Defined in:

cairo/svg_unit.cr

Enum Members

User = 0

User unit, a value in the current coordinate system. If used in the root element for the initial coordinate systems it corresponds to pixels.

Em = 1

The size of the element's font.

Ex = 2

The x-height of the element’s font.

Px = 3

Pixels (1px = 1/96th of 1in).

In = 4

Inches (1in = 2.54cm = 96px).

Cm = 5

Centimeters (1cm = 96px/2.54).

Mm = 6

Millimeters (1mm = 1/10th of 1cm).

Pt = 7

Points (1pt = 1/72th of 1in).

Pc = 8

Picas (1pc = 1/6th of 1in).

Percent = 9

Percent, a value that is some fraction of another reference value.

Instance Method Summary

Instance Method Detail

def cm? #

[View source]
def em? #

[View source]
def ex? #

[View source]
def in? #

[View source]
def mm? #

[View source]
def pc? #

[View source]
def percent? #

[View source]
def pt? #

[View source]
def px? #

[View source]
def user? #

[View source]