Open LuisMayo opened 2 years ago
Same as some Turkish letters e.g. Ğ/ğ
Where is font asset, used for render text, is actually hosted?
Is it pixelmap font asset or is it generated in some way directly from code during render?
UPD: Just found font assets used to render text:
class AnimText:
font_array = [
# AA-Like > Pixel > Generic
# AA-like, Latin, hiragana, katakana, (part of) cyrillic
{'path': './assets/igiari/Igiari.ttf'},
# Pixel, Kanji, Hiragana, Katakana
{'path':'./assets/igiari/jackeyfont.ttf'},
# Arabic
{'path':'./assets/igiari/arabic-1.ttf', 'size': 12},
# Pixel-font, Hebrew
{'path':'./assets/igiari/STANRG__.ttf'},
# Generic
{'path':'./assets/igiari/NotoSans-Regular.ttf'},
# Pixel font, Arabic
{'path':'./assets/igiari/bitsy-font-with-arabic.ttf', 'size': 10},
]
BUT, How to edit those font TTF-files? Are them on GitHub?
UPD2: @LuisMayo, as I see Igiari.ttf
is freeware for non-commercial, but proprietary font:
What about to replace this font with similar, but open-source alternative font instead? (I could help to find such alternative)
Hi
As you have already discovered, the font used is in the assets folder. About changing the font, it wouldn't do harm to change it. As long as the new font supports the same number of languages/glyphs the old one did.
The thing is, it's not really that important. This project is not and it's not willing to be commercial. And about licensing, this project is already in a weird place for the copyright law. Take into consideration that Phoenix & Co. are protected until copyright, which cannot be used even in free projects. So I doubt a font for non-comercial usages (which again, this project doesn't have) is the biggest of our problems.
An improvement is an improvement though, so I may accept another font with a better license.
BTW I have to change Igiari, some user sent me via Telegram a modified Igiari.ttf with better support from turkish that I haven't added yet.
An improvement is an improvement though, so I may accept another font with a better license.
BTW I have to change Igiari, some user sent me via Telegram a modified Igiari.ttf with better support from turkish that I haven't added yet.
What about to replace "Igiari" with "Galmuri" font? It has almost all needed characters:
Galmuri 11
(preview): https://quiple.github.io/galmuri/galmuri11Galmuri 11 Bold
(preview): https://quiple.github.io/galmuri/galmuri11-bold
Galmuri 9
(preview): https://quiple.github.io/galmuri/galmuri9Any missed character/glyph would be easily added to "Galmuri", as it is open-source font ;)
Additionally, for pixel emoji fonts are few fonts too:
N.B. I would search a little bit and will add few more links especially for pixel emoji fonts
@LuisMayo, how to create pull with font replacement changes?
Just drop the zip here, fonts are outside Git control. Unless you're adding new fonts, in that case you should make changes in text.py so drop the zip file in the Pull Request that has the text.py change
Just drop the zip here, fonts are outside Git control.
OK, Here is Galmuri 11
font (see: https://github.com/LuisMayo/objection_engine/issues/53#issuecomment-1013235784) TTF-file:
May you try it?
I've now tried it. The problem is it's not exactly the Ace Attorney font, which I enjoy more.
However it's a really good pixel font, with more charsets support than Igiari, so it's now the second font in the priority check (fonts get checked one by one until one perfect font has been found, Galmuri is the second to be texted, after Igiari). Thanks for the font.
And talking about the issue at hand Ukranian should be a bit better now
And talking about the issue at hand Ukranian should be a bit better now
Great news! Thanks.
JFTR, Does @aceCourtBot
does not work at this time/today again?
Because I just tried and there are no render yet:
UPD: Got it in 15 minutes
You're just in queue, I'm doing some experiments with the queue so it may be longer than expected!
I tried the new Noto Emoji and it kinda works, except it overflows from the line:
Edit: The AnimText
class should also be tweaked to allow using emoji font with others.
Yes, you're right, that way we can set an specific size for the emoji font so it doesn't overflow while the rest of the text is in another font
So I found two issues for emojis so far.
[:frame]
does not work for emojis as an emoji includes several unicode characters. Some library like https://pypi.org/project/grapheme/ should be used to properly render an emoji without breaking it down, but even that library does not support the latest emojis as it's not being maintained well.AnimText
objects Yah, I'm afraid about the non fallback from pillow. That's thy I had to create the "compute best font" by myself.
Maybe a PR to the Pillow is warranted
Reported by an user Original report
Added report for Chinese
Same with Emoji