dts2hx icon indicating copy to clipboard operation
dts2hx copied to clipboard

Fontkit default

Open haxiomic opened this issue 4 years ago • 1 comments

Generates:

import fontkit.*;

@:jsRequire("fontkit") @valueModuleOnly extern class Fontkit {
	@:native("default")
	static final default_ : fontkit.Fontkit;
}

But .default does not resolve to the class, instead it should be

import fontkit.*;

@:jsRequire("fontkit") @valueModuleOnly extern class Fontkit {
	/**
		Opens a font file asynchronously, and calls the callback with a font object.
		For collection fonts (such as TrueType collection files),
		you can pass a postscriptName to get that font out of the collection instead of a collection object.
	**/
	static function open(filename:String, postscriptName:String, callback:(err:Null<js.lib.Error>, font:Font) -> Void):Void;
	/**
		Opens a font file synchronously, and returns a font object.
		For collection fonts (such as TrueType collection files),
		you can pass a postscriptName to get that font out of the collection instead of a collection object.
	**/
	static function openSync(filename:String, ?postscriptName:String):Font;
	/**
		Returns a font object for the given buffer.
		For collection fonts (such as TrueType collection files),
		you can pass a postscriptName to get that font out of the collection instead of a collection object.
	**/
	static function create(buffer:global.Buffer, ?postscriptName:String):Font;
}

haxiomic avatar Jan 19 '21 14:01 haxiomic

Same issue with lottie-web

haxiomic avatar Feb 02 '21 17:02 haxiomic