One Logo Pool Ball
Charts · IOS API REFERENCE

MarkDimension

struct · iOS 16.0+ · SDK 27.1

@frozen struct MarkDimension

An individual dimension representing a mark's width or height.

Members (7)

get · iOS 16.0+

description

TypeScript
get description(): string
Swift declaration
var description: String { get }

A textual representation of this instance. Calling this property directly is discouraged. Instead, convert an instance of any type to a string by using the `String(describing:)` initializer. This initializer works with any type, and uses the custom `description` property for types that conform to `CustomStringConvertible`: struct Point: CustomStringConvertible { let x: Int, y: Int var description: String { return "(\(x), \(y))" } } let p = Point(x: 21, y: 30) let s = String(describing: p) print(s) // Prints "(21, 30)" The conversion of `p` to a string in the assignment to `s` uses the `Point` type's `description` property.

init · iOS 16.0+

init

TypeScript
static initFloatLiteral(value: number): MarkDimension
Swift declaration
nonisolated init(floatLiteral value: Double)

Creates a constant width or height from a floating point value. - Parameter value: The width or height.

init · iOS 16.0+

init

TypeScript
static initIntegerLiteral(value: number): MarkDimension
Swift declaration
nonisolated init(integerLiteral value: Int)

Creates a constant width or height from an integer. - Parameter value: The width or height.

static · iOS 16.0+

fixed

TypeScript
static fixed(value: number): MarkDimension
Swift declaration
static func fixed(_ value: CGFloat) -> MarkDimension

A constant dimension. - Parameter value: The fixed width or height.

static · iOS 16.0+

inset

TypeScript
static inset(value: number): MarkDimension
Swift declaration
static func inset(_ value: CGFloat) -> MarkDimension

A dimension that's the step size minus the specified inset value on each side. - Parameter value: The given inset value in screen coordinates.

static · iOS 16.0+

ratio

TypeScript
static ratio(value: number): MarkDimension
Swift declaration
static func ratio(_ value: CGFloat) -> MarkDimension

A dimension that's proportional to the scale step size, using the specified ratio. - Parameter value: The given ratio, from 0 to 1.

get · iOS 16.0+

automatic

TypeScript
static get automatic(): MarkDimension
Swift declaration
static var automatic: MarkDimension { get }

A dimension that determines its value automatically.

Skipped declarations

No declarations were skipped in this snapshot.

All Charts types →