Closed shshalom closed 8 years ago
Which APIs are you trying to access? You should only use the APIs from the auto-generated class.
This one in particular: Iconic.registerFont("FontAwesome", map: FontAwesomeIconMap)
But in general I've notice that I can't even extend using extension because the entire class is set as internal by default.
Isn't this related to https://github.com/dzenbot/Iconic/issues/33?
No, that's an unrelated to #33. The ReadMe file shows this:
You can also register the font with its family name and unicode mapping:
Iconic.registerFont("FontAwesome", map: FontAwesomeIconMap)
But registerFont method is not exposed as public.
Totally forgot to update the docs. Sorry about that!
In theory, you should not need to call Iconic.registerFont("FontAwesome", map: FontAwesomeIconMap)
anymore since registerIconFont()
does it for you internally.
Got it. while we're at it, if I provide a font that is a custom font which was built over another FontAwesome file, with different name and different icons... the generated class creates this:
Iconic.registerFont("FontAwesome", map: MyFontIconMap)
Notice that it sets the "FontAwesome" instead of "MyFont".
That's another reason for asking to expose registerFont as public.
That is because it grabs the font's postscript name to create the class and specially, to register to the font manager.
I figure that much, I guess I could edit the file and change the postscript name to solve this.
I generally use Glyph
app for editing font files.
It seems you've forgot to set access control in Iconic class.