Page 1 of 1

I want to apply different fonts to celestia

Posted: 27.09.2019, 13:26
by fly_space
Hello,
I want to apply some fonts to celestia.
I searched many topics about txf fonts, but there are no useful information.

It seems to there are some tools (ttf2txf? txfutil?) to extract txf fonts from .ttf fonts.
but I couldn't found anything.

How can I do this hard things?
please help.

Posted: 27.09.2019, 14:06
by onetwothree
Unless somebody saved that ttf2txf utility you have two possibilities: either reimplement it from stratch or wait for 1.7 version with ttf support.

Posted: 27.09.2019, 16:05
by fly_space
either reimplement it from stratch or wait for 1.7 version with ttf support.

stratch? what is that?

and, will 1.7 supports ttf? good :)

Thanks.

Posted: 27.09.2019, 18:12
by onetwothree
I meant `from scratch`.

Yes, I have unfinished branch with ttf support. Now it works with LTR languages, so support for RTL still have to be added, and I have no idea how implement properly korean script, is it allowed to use it as LTR script (upd: if my firefox renders it correctly, then it's LTR)?

Posted: 28.09.2019, 05:01
by Janus
Or you can go back in time to retrieve it.

Secret sauce

I haven't looked at the contents yet, but I am sure it can be compiled quite easily.


Janus.

I want to apply different fonts to celestia

Posted: 29.09.2019, 07:34
by fly_space
Did you mean LTR is Left To Right(english, french...etc) and RTL is Right To Left(arabic)?
if right, Korean is LTR language.

and I have no idea how implement properly korean script

what is exact meaning of 'implement'? Do you need help about translate, or making .cel and .celx scripts?
I want to help you about making korean scripting, or printing korean in Celestia
(actually, I found a problem with Korean characters not displaying correctly. some characters print like '?'
so first step to solve this problem is changing font.)

글자_자음만.png
글자_자음만.png (3.48 KiB) Viewed 9490 times


I haven't looked at the contents yet, but I am sure it can be compiled quite easily

I will compile it and do some test.


Huge Thanks :)

P.S : How do I insert nickname in quote?

Posted: 29.09.2019, 20:55
by onetwothree
fly_space wrote:Did you mean LTR is Left To Right(english, french...etc) and RTL is Right To Left(arabic)?
if right, Korean is LTR language.

Yep, I meant exactly this.

fly_space wrote:what is exact meaning of 'implement'?

I was talking about writing code that renders korean text correctly. Actually I had an impression that in korean script you have words composed out of syllables written horizontally but letters in a syllable are vertical (one above another). But your image shows that
characters (being either letters or syllables) are written as in european languages, so no additional code for korean script is required.

fly_space wrote:P.S : How do I insert nickname in quote?

[ quote = "fly_space" ] <--- without spaces. Or just use a quote button above the message you are replying to, first select a text you want to quote and it will appear.

Posted: 01.10.2019, 16:23
by fly_space
onetwothree wrote:I was talking about writing code that renders korean text correctly. Actually I had an impression that in korean script you have words composed out of syllables written horizontally but letters in a syllable are vertical (one above another). But your image shows that
characters (being either letters or syllables) are written as in european languages, so no additional code for korean script is required.

Characters in my image file are all korean consonant. but some of them don't appear completely.

242FFF4D533B71E513EE46.gif
242FFF4D533B71E513EE46.gif (10.32 KiB) Viewed 9436 times


some complete words, such as '엌' don't appear, too. I hope your computer prints character in quote.

I don't know why this problem happening.
(problem with encoding? or other things? hmm... give me some clue...)

onetwothree wrote: [ quote = "fly_space" ] <--- without spaces. Or just use a quote button above the message you are replying to, first select a text you want to quote and it will appear.

Thanks!! :)

Posted: 03.10.2019, 07:34
by onetwothree
I suppose they are just not included in bitmap fonts shipped with Celestia. So your idea to create a new font sounds reasonable.

Posted: 11.10.2019, 13:23
by fly_space
[quote=onetwothree] I suppose they are just not included in bitmap fonts shipped with Celestia. So your idea to create a new font sounds reasonable.[/quote]

I tried many times to build ttf2txf, but I failed. (I think that some files not exist)
actually, there are no problems to print Korean characters used to make sentences Korean people readable.
but I want to add some technique which is more fun to Celestia users, like show steps to completing characters
(In English's view, I want to show writing 'celestia' with 'c' -> 'ce' > 'cel' > .... > 'celestia'
in Korean, '한' : 'ㅎ' > '하' > '한'. but In Celestia , it will be '?' > '하' > '한')

I will wait to Celestia 1.7.0 released.
I appreciate all of yours trying to develop Celestia.
Until that day, I will organize grammar of cel script in Korean.
See you soon :D

Posted: 09.07.2020, 10:09
by gironde
ttf2txf-win32-binaries.7z is downloadable here :

http://chateau-logic.com/content/ttf-txf-font-conversion

:hi:

Added after 2 hours 45 minutes:
option command line for ttf2txf.exe

options :
- w <width> (default 256)
- h <heigt> (default 256)
- f < filename > (file containing character codes to convert)
- c <string> (characters to convert)
- g <gap> (space between glyphs, default 1
- s <size> (font point size default 20)
- o <filename> (output file txf)
- q quiet, no output

< TrueType font>

example
ttf2txf -o DejaVuSans18.txf -s 18 -w 214 -h 214 DejaVuSans.ttf

to test...