janet-lang / jaylib

Janet bindings to Raylib
MIT License
146 stars 37 forks source link

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

Closed sogaiu closed 6 months ago

sogaiu commented 10 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 10 months ago

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

sogaiu commented 10 months ago

Good point.