Skip to content

Improve Arabic XLSX text rendering and font compatibility - #260

Closed
ttrudging wants to merge 1 commit into
storytold:mainfrom
ttrudging:arabic-support
Closed

ttrudging wants to merge 1 commit into
storytold:mainfrom
ttrudging:arabic-support

Conversation

@ttrudging

Copy link
Copy Markdown

Title: Improve Arabic XLSX rendering and font compatibility

Summary

This contribution improves Arabic-language spreadsheet rendering in GridCraft, particularly when opening XLSX files exported from Odoo.

Issues addressed

  • Arabic characters displaying as missing glyphs or square boxes.
  • Arabic text clipping vertically inside spreadsheet cells.
  • Incorrect positioning of Arabic text in wrapped cells.
  • Font compatibility issues with imported XLSX documents.

Changes

  • Added Arabic font fallback support.
  • Introduced a dedicated Arabic font family for spreadsheet cells.
  • Added automatic Arabic Unicode detection.
  • Selected Noto Naskh Arabic to improve text rendering within Excel-style cell dimensions.
  • Adjusted wrapped-text positioning and clipping.

Testing

Built and tested locally on Debian 13 KDE using real-world Arabic and mixed Arabic/English XLSX exports.

The previously affected spreadsheets now display Arabic text correctly.

Request

Would you consider reviewing these changes for inclusion in the official GridCraft repository?

The improvements are currently published in a separate fork for evaluation and further testing.

Full RTL worksheet behavior has not yet been comprehensively tested.

@ttrudging ttrudging changed the title Improve Arabic XLSX text rendering and font compatibility Improve Arabic XLSX text rendering and font compatibility "tested on Debian" Oct 11, 2026
@ttrudging ttrudging changed the title Improve Arabic XLSX text rendering and font compatibility "tested on Debian" Improve Arabic XLSX text rendering and font compatibility "tested on Debian only" Oct 11, 2026
@ttrudging ttrudging changed the title Improve Arabic XLSX text rendering and font compatibility "tested on Debian only" Improve Arabic XLSX text rendering and font compatibility Oct 11, 2026
@ttrudging

Copy link
Copy Markdown
Author

Additional platform comparison:

I tested Arabic XLSX rendering on Windows using the official GridCraft installer and could not reproduce the Arabic rendering problem observed on Debian 13 KDE.

The Arabic rendering fix has been tested successfully on Debian only.

This suggests the original issue may be related to Linux font availability or fallback behavior, rather than a universal Arabic rendering problem.

@echelon

echelon commented Oct 11, 2026

Copy link
Copy Markdown
Member

Thank you for working on Arabic text — it's an important gap. Unfortunately this approach can't fix it: egui doesn't do Arabic shaping or right-to-left layout, so loading an Arabic font doesn't produce correctly joined text. The PR also hard-codes Linux font paths, loads Noto Naskh Arabic twice and bypasses the existing font fallback chain, and the grid.rs clip change is a no-op. We're closing this one; proper shaping needs a text-shaping layer (a bigger design discussion — we'd love your input on Discord).

If you haven't already, come join us on the ArtCraft Discord: https://discord.gg/artcraft

@echelon echelon closed this Oct 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants