Skip to content

Mismatching cases (Pretext vs. CSS) #89

@Hasan0540

Description

@Hasan0540

Assuming the implementation of the diff tool in https://pretext-diff.replit.app/ is correct (https://replit.com/@bmwhsnrr/Pretext-Diff), I'm reporting the following cases with mismatches between Pretext and CSS:

  • Browser: Google Chrome, 146.0.7680.164 / Linux
  • Font: 16px Inter, system-ui, sans-serif
  • Line height: 24

  • Width: 600
  • Functions: prepareWithSegments() + layoutNextLine().
  • Text: We must also consider edge-case strings. Consider a long, continuous tracking URL like https://www.super-long-domain-name.com/api/v1/tracking/xyz12345987654321.
  • Image
  • There are two issues here: Pretext placed "tracking" on the next line, and didn't break the long link until it's on a separate line.


  • Width: 600
  • Functions: prepareWithSegments() + layoutNextLine().
  • Text: breaking before the full stop. Similarly, the Chinese localization, 我们正在测试文本换行和分段功能,看看浏览器如何处理它。, worked lawlessly even inside tightly constrained flexbox containers.
  • Image
  • This may be related to Feature request: support word-break: keep-all for CJK text #74, but I think it should be by default for CJK to match CSS?
  • Same for Thai text (width 350): Thai text, which requires dictionary-based line breaking, was also verified: นี่คือข้อความภาษาไทยสำหรับการทดสอบการตัดคำ.
  • Image

  • Width: 610
  • Functions: prepareWithSegments() + layoutNextLine(), but layoutWithLines() and walkLineRanges() are also broken.
  • Text: They remain hyper-focused on delivering a best-in-class experience (even when dealing with nested [bracketed {and heavily punctuated}] data!). Whether the user is typing in English, sending a 👩‍🚀 emoji, formatting currency like £3,450.75, or reading Thai (ทดสอบ), the layout engine must hold strong.
  • Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions