Skip to content

[p5.js 2.0 Bug Report]: width/height/options overloads inconsistent/incorrect for typography methods #7820

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
1 of 17 tasks
davepagurek opened this issue May 15, 2025 · 0 comments

Comments

@davepagurek
Copy link
Contributor

davepagurek commented May 15, 2025

Most appropriate sub-area of p5.js?

  • Accessibility
  • Color
  • Core/Environment/Rendering
  • Data
  • DOM
  • Events
  • Image
  • IO
  • Math
  • Typography
  • Utilities
  • WebGL
  • Build process
  • Unit testing
  • Internationalization
  • Friendly errors
  • Other (specify if possible)

p5.js version

2.0.2

Web browser and version

N/A

Operating system

N/A

Steps to reproduce this

textToModel has these overloads:

textToModel(str, x, y, width, height, [options], [options.extrude], [options.sampleFactor])

textToContours has these overloads:

textToContours(str, x, y, [options])

textToPoints has these:

textToPoints(str, x, y, [options])

A few issues to fix:

  • All of these optionally support width and height. The overloads should maybe be:

    something(str, x, y, [options])
    something(str, x, y, width, height, [options])
    
  • All should have the same base options. These include sampleFactor and simplifyThreshold (see the 1.x docs for descriptions of these.) textToModel additionally has extrude.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Open for Discussion
Development

No branches or pull requests

1 participant