red-agate-barcode
Version:
red-agate barcode tag library.
32 lines (31 loc) • 1.28 kB
TypeScript
import { SvgCanvas } from 'red-agate-svg-canvas/modules/drawing/canvas/SvgCanvas';
import { BarcodeBaseProps, BarcodeBasePropsNoUndefined, BarcodeBase } from './BarcodeBase';
export interface JapanPostalProps extends BarcodeBaseProps {
elementWidth?: number;
}
export interface JapanPostalPropsNoUndefined extends BarcodeBasePropsNoUndefined {
elementWidth: number;
}
export declare const japanPostalPropsDefault: JapanPostalPropsNoUndefined;
export declare class JapanPostal extends BarcodeBase<JapanPostalProps> {
constructor(props: JapanPostalProps);
protected calcSymbolSize(data: string, startChar: string, stopChar: string, cdChar: string): {
tw: number;
th: number;
};
protected calcCheckDigit(data: string): string;
protected encodeData(data: string): {
data: string;
heightData?: string;
labelText?: string;
startChar: string;
stopChar: string;
};
protected getBarSpaceWidth(): number[];
protected getBarSpaceHeight(): Array<Array<{
offset: number;
height: number;
}>>;
protected get isHeightModulated(): boolean;
protected renderText(canvas: SvgCanvas, tw: number, th: number, data: string, text: string): void;
}