janet-lang / jaylib

Janet bindings to Raylib
MIT License
137 stars 36 forks source link

Address #56: two-argument load-font-ex #57

Closed sogaiu closed 4 months ago

sogaiu commented 7 months ago

This PR is an attempt to address #56.

The approach taken is for load-font-ex to also handle being called with 2 arguments (in addition to its existing ability to handle 3 arguments).

If called with 2 arguments, the 3rd and 4th arguments to LoadFontEx are set to NULL and 0 respectively.


I've made a demo in a fork.

If interested in trying, instructions are here and the demo code file is here.

jangler commented 7 months ago

text_cfuns should also be updated to document the new signature; otherwise this won't be discoverable.

sogaiu commented 7 months ago

Good point.