Convert unicode text to a font

???????? ?????
User avatar
Rksk
Major
Major
Posts: 730
Joined: Thu Jan 07, 2010 4:19 pm
Location: Rathnapura, Sri Lanka

Convert unicode text to a font

Post by Rksk » Wed Apr 07, 2010 10:41 pm

can i convert unicode text to a font?
i want to convert unicode meanings given by www.maduraonline.com to Madura font.
User avatar
Neo
Site Admin
Site Admin
Posts: 2642
Joined: Wed Jul 15, 2009 2:07 am
Location: Colombo

Re: Convert unicode text to a font

Post by Neo » Thu Apr 08, 2010 1:32 am

Do you refer "UNICODE text" to a set of images of letter?
If that is the case, you need to use a font drawing software like Fontographer to import all the images and construct a new UNICODE font.
User avatar
Rksk
Major
Major
Posts: 730
Joined: Thu Jan 07, 2010 4:19 pm
Location: Rathnapura, Sri Lanka

Re: Convert unicode text to a font

Post by Rksk » Thu Apr 08, 2010 8:33 am

No no,

i meant that,

there is a text written in unicode. i want to convert it to another font (non unicode)
User avatar
Neo
Site Admin
Site Admin
Posts: 2642
Joined: Wed Jul 15, 2009 2:07 am
Location: Colombo

Re: Convert unicode text to a font

Post by Neo » Thu Apr 08, 2010 9:20 am

In that case, it is lot more easier. You only need a font drawing software like Fontographer to open the UNICODE font and then copy the letters you need across to the new font.

If you are unable to copy fonts across font files, you might need to copy the glyphs you need from source font to set of images. Unicode Image Maker seems a free one that does the thing.

If you are going to use the second method, Refer the following video.
[media]http://www.youtube.com/watch?v=IhcNsY71Vc4[/media]

I found another beautiful free font drawing program called Font Struct. I'm not sure you can import fonts from other fonts with this. But you may give it a try.
User avatar
Rksk
Major
Major
Posts: 730
Joined: Thu Jan 07, 2010 4:19 pm
Location: Rathnapura, Sri Lanka

Re: Convert unicode text to a font

Post by Rksk » Thu Apr 08, 2010 10:25 am

Still you haven't understood my question.

i don't want to create a font.

i want to convert a text wich typed with unicode to a text wich can view with a ttf font like Araliya.ttf.
User avatar
Rksk
Major
Major
Posts: 730
Joined: Thu Jan 07, 2010 4:19 pm
Location: Rathnapura, Sri Lanka

Re: Convert unicode text to a font

Post by Rksk » Thu Apr 08, 2010 11:08 am

Pls tell me a way to get a ascill map fro a unicode!
User avatar
Neo
Site Admin
Site Admin
Posts: 2642
Joined: Wed Jul 15, 2009 2:07 am
Location: Colombo

Re: Convert unicode text to a font

Post by Neo » Thu Apr 08, 2010 12:25 pm

I feel you are a bit confused with fonts. I clarified about UNICODE and ASCII few days ago, so I suggest you to read the post. https://robot.lk/viewtopic.php?f=91&t=1613

Okay, lets break up your question in to two parts. Source and the Destination.
  1. So first thing first. Clarify the source
    i want to convert a text wich typed with unicode
    1. You have a whole image of fonts <- If that is the case, you can't refer this as UNICODE
    2. You have a UNICODE TTF font and you used to type some text somewhere like in MS Word
  2. Next, clarify the destination
    to a text wich can view with a ttf font like Araliya.ttf
    TTF is a file format and It can carry either UNICODE or ASCII.
    So if you want to view your font as a TTF (regardless of whether it is UNICODE or ASCII) you need to write it in TTF format.
    To write anything you have to TTF format you need a Fontographer like software.
In whatever case, your question lacks information. You need to be more descriptive.
Also, avoid putting external links as much as possible. Understand the fact that we do jobs here as the top priority while we try to help you and we don't have much time to spend on trying imagine your question if you do not clarify it within the post. So don't be shy, be more descriptive next time ;)
User avatar
Rksk
Major
Major
Posts: 730
Joined: Thu Jan 07, 2010 4:19 pm
Location: Rathnapura, Sri Lanka

Re: Convert unicode text to a font

Post by Rksk » Thu Apr 08, 2010 3:17 pm

Ok, i will describe 'What i want to do?'.

I'm developing a online English-Sinhala mobile dictionary in J2ME. :D
I have created a pngFont and it can view sinhala text typed in Madhura font. :roll:

I have made Excel/Access database for my dictionary. :arrow:
but uploading it to server as a MySql BD and developing PHP scripts for searching, is much hard. :cry:

Therefore I think using www.maduraonline.com as my data base is very easy. ;)
with a external PHP script I will can get results for my purpose.
But that site gives Sinhala meanings in Unicode font. :cry:

Please tell me, Howto use these "Meanings" given in unicode with my J2ME app? :arrow:
I have 02 ways. pls help me to do any of these!!!!!!!!!!! :idea:

1. a PHP script will can convert Unicode to Madura font
2. Also in the J2ME app it will can understand unicode and view them
User avatar
Neo
Site Admin
Site Admin
Posts: 2642
Joined: Wed Jul 15, 2009 2:07 am
Location: Colombo

Re: Convert unicode text to a font

Post by Neo » Sat Apr 10, 2010 3:34 am

1. a PHP script will can convert Unicode to Madura font
I would suggest to name it as "convert UNICODE characters to Madura Font". Otherwise I'm getting misguided by Unicode fonts.

I had a look at your thought on using madura.
I have added a short article on Understanding Sinhala/Tamil UNICODE.

So what you have to do is, scrap the contents from the web page. php commands that are used for this, is covered in article: How to scrap links on a web page using PHP.
2. Also in the J2ME app it will can understand unicode and view them
Now, the codes you get is as FF FE C3 0D B8 0D B1 0D BD 0D BA 0D CF 0D.
You need a mapping table, to map those characters to your glyphs (font pictures).
For example:
0DC3 -> 1st glyph of your PNG image
0DB8 -> 2nd glyph of your PNG iamge
0DB1 -> 3rd glyph of your PNG image
.........
.........
.........

I'm sure you are now somewhere with it.

After you build you application, you might have to get permission form MaduraOnline.com. In addition to that, you might add ROBOT.LK name somewhere if these articles had helped you :D
User avatar
Rksk
Major
Major
Posts: 730
Joined: Thu Jan 07, 2010 4:19 pm
Location: Rathnapura, Sri Lanka

Re: Convert unicode text to a font

Post by Rksk » Sat Apr 10, 2010 11:55 pm

I think, creating a new FONTimage for unicode charactors is easy.

but there is a problem with ASCILL and CHAR functions with Unicode charactors. is there any way to get ASCILL of a unicode charactor in PHP or JAVA?
Post Reply

Return to “???????? ?????”