-
Notifications
You must be signed in to change notification settings - Fork 57
Appy rtl #41
base: main
Are you sure you want to change the base?
Appy rtl #41
Conversation
hmmftg
commented
May 27, 2023
- Replace manual RTL with automatic rtl detection
- Handle arabic presentation form with goarabic library
- fix character width calculation problem for special characters with variable lengths in different presentation forms
- Write unit tests and add sample arabic fonts
Codecov ReportPatch coverage:
❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more. Additional details and impacted files@@ Coverage Diff @@
## main #41 +/- ##
==========================================
+ Coverage 79.40% 79.81% +0.41%
==========================================
Files 32 33 +1
Lines 7547 7527 -20
==========================================
+ Hits 5993 6008 +15
+ Misses 1228 1200 -28
+ Partials 326 319 -7
☔ View full report in Codecov by Sentry. |
sbinet
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for the PR (and apologies for the belated answer).
I have a couple of comments, see below, but also one here:
instead of adding the fonts that exercize RTL text in this repository, could we instead add them in a dedicated repository ?
see, e.g., what I did for other fonts:
(and, what are the LICENSE requirements of that new font ?)
finally: your PR makes Fpdf automatically detect whether a piece of text is RTL (or LTR).
this introduces inconsistency with the RTL and LTR public methods of Fpdf.
how would you think we should resolve this ?
thanks again.
|
Hi, thanks for your attention |
|
I am definitely not against having something automatic. also, you hard-code a given reverse-strings function (or, rather, you replaced one hard-coded one with another one). shouldn't we instead provide a way for users to provide their own "reverse-strings" function ? |
|
I haven't forgotten about this. |
|
ping ? unless I am mistaken, I don't think my comment in #41 (comment) has been addressed. |