Rockbox

This is the bug/patch tracker for Rockbox. Click here for more information.

Quick links: Bugs · Patches · Rockbox frontpage

Tasklist

FS#9595 - Correct thai font display

Attached to Project: Rockbox
Opened by Phinitnun Chanasabaeng (crackerizer) - Monday, 01 December 2008, 16:47 GMT+2
Task Type Patches
Category User Interface
Status Unconfirmed
Assigned To No-one
Player Type All players
Severity Low
Priority Normal
Reported Version Daily build (which?)
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Private No

Details

This patch will correct how thai vowels and tonal makers display.
   patch (4.5 KiB)
This task depends upon

Comment by Rafaël Carré (funman) - Tuesday, 02 December 2008, 17:33 GMT+2
you should use only 1 > and 1 < comparison for the thai vowels when they are next to each other:

+ if(*ucs == 0xe47 || *ucs == 0xe48 || *ucs == 0xe49 || *ucs == 0xe4a ||
+ *ucs == 0xe4b || *ucs == 0xe4c || *ucs == 0xe4d || *ucs == 0xe4e)

should become

if(*ucs >= 0xe47 && *ucs <= 0xe4e)
Comment by Phinitnun Chanasabaeng (crackerizer) - Tuesday, 02 December 2008, 17:51 GMT+2
Thank you for your comment. Here is the updated patch.
   patch (3.9 KiB)
Comment by freeMAN (freeMANsiam) - Monday, 29 December 2008, 22:21 GMT+2 Comment by Jonas Häggqvist (rasher) - Tuesday, 30 December 2008, 03:49 GMT+2
A few things:
a) Rockbox is C89 - no mixing code with variable declarations.
b) This patch seems prone to bitrot, since you have the same code in 3 places. Would it be possible to centralise it?
Comment by Phinitnun Chanasabaeng (crackerizer) - Tuesday, 30 December 2008, 04:26 GMT+2
Jonas, thank you for your comment. This is a very dirty patch. I think adding somethings beyond this would be a new feature rather than a patch. I have been thinking about adding the complex text layout support to rockbox but my time doesn't allow me to :).

About the C89, as I'm not a programmer by nature, I don't know much about it. But I would look at it to standardize myself.

Thank you for your suggestion. :)

Loading...