/** * A class for handing paddings, borders, margins, etc. * * @typedef {import("../../spec/view.js").Paddings} Paddings * @typedef {import("../../spec/view.js").PaddingConfig} PaddingConfig */ export default class Padding { /** * * @param {PaddingConfig} config */ static createFromConfig(config: PaddingConfig): Padding; /** * @param {Paddings} paddings */ static createFromRecord(paddings: Paddings): Padding; /** * Returns a zeroed padding. */ static zero(): Padding; /** * * @param {number} value */ static createUniformPadding(value: number): Padding; /** * @param {number} top * @param {number} right * @param {number} bottom * @param {number} left */ constructor(top: number, right: number, bottom: number, left: number); /** @readonly */ readonly top: number; /** @readonly */ readonly right: number; /** @readonly */ readonly bottom: number; /** @readonly */ readonly left: number; /** * Returns the sum of left and right */ get width(): number; /** * Returns the sum of top and bottom */ get height(): number; /** * @param {number} amount In pixels */ expand(amount: number): Padding; /** * * @param {Padding} padding padding to add */ add(padding: Padding): Padding; /** * * @param {Padding} padding padding to subtract */ subtract(padding: Padding): Padding; /** * * @param {Padding} padding padding to union */ union(padding: Padding): Padding; /** * Returns a new padding with the left and right, but with the top and bottom set to 0. */ getHorizontal(): Padding; /** * Returns a new padding with the same top and bottom, but with the left and right set to 0. */ getVertical(): Padding; get horizontalTotal(): number; get verticalTotal(): number; } /** * A class for handing paddings, borders, margins, etc. */ export type Paddings = import("../../spec/view.js").Paddings; /** * A class for handing paddings, borders, margins, etc. */ export type PaddingConfig = import("../../spec/view.js").PaddingConfig; //# sourceMappingURL=padding.d.ts.map