How can show foreign fonts in Gideros?
I came across these discussion.
http://www.giderosmobile.com/forum/discussion/2132/what039s-the-best-way-to-show-any-unicode-character--I could not use this,It does not support Arabic(since it goes from right to left,it looks fragmented ) and Cantonese fonts(shows squares)
http://appcodingeasy.com/Gideros-Mobile/Localization-in-Gideros --Keep in mind
Examples:
--goes from right to left
تنظیمات جستجو · تاریخچه ی شبکه. فار
-- or cantonese
广州话 or 廣州話
-------------------------------------------
So correct me if I am wrong ,
1.So as long as I copy and paste all the
required alphabet(Cantonese,arabic,german,..)
into the Gideros Font Creator and export it ,then I should be fine.
2.Then I can create a
--Arabic.lua class
Arabic = {}
Arabic.line 1 = "تنظیمات جستجو · تاریخچه ی شبکه. فار"
return Arabic
------------------------------------------
Then later can I print this out?in my main.lua
local Arabic = require("Arabic")
--do the text api function to show Arabic.line 1
Am I doing the right thing here?
Also any chance any of you know a good source to find different type of alphabets(different languages) for copying and pasting?so far all I can find is images.
Thanks again in advance,off the topic I have been really amazed by Gideros speed.
That what makes it so attractive for me.Very very smooth.
And it is far more amazing knowing it is done only by one person.
And for me you will see me around a lot asking lots of question,since I am new to this framework.
Thanks again
Comments
http://www.nightspade.com
https://github.com/gideros/gideros
https://www.youtube.com/c/JohnBlackburn1975
http://www.wildboar.net/multilingual/asian/chinese/language/fonts/unicode/non-microsoft/non-microsoft.html
Not sure of copyright status. The fact that TTF is there for immediate download seems to indicate it is copyright free.
https://github.com/gideros/gideros
https://www.youtube.com/c/JohnBlackburn1975
That is exactly what I were looking for.
The files seems very small which is good.29 kb for example.
I did not mean just copy and paste it any where,what I meant to paste the alphabets into restore default in Gideros text editor .
And there is a step after that,that I will look into.
I have seen @atilim did it somewhere and it worked.
Thanks
If you have a TTF font you need to do this:
https://github.com/gideros/gideros
https://www.youtube.com/c/JohnBlackburn1975
This include any language,Arabic, Chinese , any thing.
1.Find a ttf file of that language.(that is the hardest part for me,
if you have any better resource let me know.)
2.In this case right click on ttf and install it(in windows).
3.open Microsoft Words(Well I hope you have this software).
Find the font in the font type drop down at the top.
select the font and write something.
4. Use Gideros Font Creator,use the TTF create text and png from it.
5. Now you have to write first in the Microsoft word,
and when it is ready ,just copy and paste it into your lua file.
(it will shows up as random English fonts when you paste it)
6.But when in Gideros player it show up correctly,even Arabic words.
so that is the best solution I came up with:)
I have attached an example.
Cheers
Likes: Nascode, hosamred
It's a shame the text shows as garbage in Gideros Studio. Perhaps if you tried TTF fonts instead this would work better. I think you will need TTF fonts for Chinese as there are simply too many characters to make a PNG.
Would any devs like to comment?
https://github.com/gideros/gideros
https://www.youtube.com/c/JohnBlackburn1975
http://www.nightspade.com
But then the difference is in you as developer. TTF support allows you to use all those created fonts that already exist and BitmapFonts would allow you more easily create your own font (either from scratch or by modifying existing font)
Basically you have to get your translator to use the same TTF in microsoft words.
Then copy and paste it ,from microsoft words into the gideros,
It all shows up as numbers,but when you display it ,it will show up correctly.
https://github.com/gideros/gideros
https://www.youtube.com/c/JohnBlackburn1975
Although we don't support for right to left languages, we support for Chinese, Japanese,
Cyrillic, Hebrew, etc. You just need to find the correct font.
They are free and included in Linux distribution and their size are not too much.
I define two functions getString(key) to recover translation from key in the current language of the device and getTTFont(font, size, size2) where font is common font for English, Spanish, German, French, Italian, Portuguese...