Skip to content

Conversation

GoodBoyDigital
Copy link
Member

…adding adjustments

  • Updated the updateTextBounds function to first calculate bounds using the full padded texture and then adjust for padding based on the text anchor.
  • Modified the test scene to position text correctly based on its width and height.
  • Updated visual snapshots for WebGL1, WebGL2, and WebGPU to reflect the changes in text rendering.
Description of change
  • Fixed up font padding issue . Anchor was tacking padding into account, silly me!
  • Updated test
Pre-Merge Checklist
  • Tests and/or benchmarks are included
  • Documentation is changed or added
  • Lint process passed (npm run lint)
  • Tests passed (npm run test)

…adding adjustments

- Updated the `updateTextBounds` function to first calculate bounds using the full padded texture and then adjust for padding based on the text anchor.
- Modified the test scene to position text correctly based on its width and height.
- Updated visual snapshots for WebGL1, WebGL2, and WebGPU to reflect the changes in text rendering.
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your PR title doesn't match the required format. The title should be in this format:

chore: update Text docs
fix: text not rendering
feat: add new feature to Text
breaking: remove Text#resolution 

Copy link

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

@bigtimebuddy bigtimebuddy changed the title refactor: enhance text bounds calculation to account for anchor and p… fix: enhance text bounds calculation to account for anchor and padding Jun 13, 2025
@Zyie Zyie added the ✅ Ready To Merge Helpful when issues are in the queue waiting to get merged. This means the PR is completed and has t label Jun 30, 2025
@Zyie Zyie added this pull request to the merge queue Jun 30, 2025
Merged via the queue into dev with commit e6b0825 Jun 30, 2025
5 of 6 checks passed
@Zyie Zyie deleted the fix/text-padding branch June 30, 2025 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✅ Ready To Merge Helpful when issues are in the queue waiting to get merged. This means the PR is completed and has t
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants