I would like to use this module with accentuated letters. With lower case letters it works fine, but with the same letters in uppercase (ÉÁŰŐÚÖÜÓÍ) it doesn't. Is there a solution to this problem? I didn't find help so far...
I would like to use this module with accentuated letters. With lower case letters it works fine, but with the same letters in uppercase (ÉÁŰŐÚÖÜÓÍ) it doesn't. Is there a solution to this problem? I didn't find help so far...
Comments
Comment #1
sgabe commentedI found the exact problem: The $bheight variable and the $y variable in the imagettftext() function need to be bigger with 5 pixel... Otherwise the accent is cut off from the image.
Comment #2
decipheredHi sgabe,
Increasing by 5 pixels may fix this case, but if you rotated the image or changed the font face or size it would not longer be the correct fix. I will have a play with this issue shortly and see that I can come up with a better fix for you.
Cheers,
Deciphered.
Comment #3
sgabe commentedHi Deciphered,
You are absolutely right, I think this may be a solution only for this one exact case. Anyway I just wanted to help with some hint, so you guys know where to look.
Cheers,
sgabe
Comment #4
decipheredHi sgabe,
It only occurred to me this morning to check what version you where using, which I see is 2.1. Try downloading the latest development build, there's changes to prevent character cutoff that should fix this exact problem.
Give it a shot and let me know how it goes.
Cheers,
Deciphered.
Comment #5
sgabe commentedHi Deciphered,
I upgraded to the latest dev version and it's better but not perfect, 70 percent of the accent is still out of sight.
Cheers,
sgabe
Comment #6
decipheredHi sgabe,
I'm still looking into solutions for this issue (that I am happy with). I haven't had a lot of time to dedicate to Textimage of late, but rest assured I will not forget this issue and fully intend to have it fixed for the release of 2.2.
Cheers,
Deciphered.
Comment #7
sgabe commentedThanks a lot for all your efforts to fix this issue!
Comment #8
forngren commentedMake sure that you use an truetype font (.ttf) instead of an opent ype font (.otf), as PHP/GD only has limited support for open type fonts. That did the trick for me atleast.
Comment #9
sgabe commentedSorry, I didn't mention it but the problem occurs with TrueType font of course. I'm still increasing the dimensions by 5 pixel, that solves the problem until a real solution.
Comment #10
mondrake