Board.KolibriOS.org

Official KolibriOS board
It is currently Sun Sep 22, 2019 5:13 am

All times are UTC+03:00




Post new topic  Reply to topic  [ 81 posts ]  Go to page 1 2 3 4 5 6 Next
Author Message
 Post subject: TrueType
PostPosted: Tue Apr 10, 2012 12:56 pm 
Offline

Joined: Tue Apr 10, 2012 12:51 pm
Posts: 3
Hi, I'm not sure if this is the right sub-forum - and even though the forums have english describtions, all posts are in russian for no apparent reason?

Anyway, as KolibriOS is probably the most active menuet fork here's a link to a small truetype support file in C.
http://mollyrocket.com/forums/viewtopic.php?t=736

I know it's in C, but it's waaay smaller than freetype lib and also, much of the code is examples, all baked into one .h file. Maybe it can give inspiration to create native truetype support, or it could be compiled as-is for temparary support?

Regards,
Christoffer


Top
   
 Post subject: Re: truetype
PostPosted: Tue Apr 10, 2012 2:17 pm 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
Wow. I'm making my implementation of cool vector fonts, but it's cool too. I'll take a look.


Top
   
 Post subject: Re: truetype
PostPosted: Wed Apr 11, 2012 8:24 am 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
Pretty cool. I didn't figured out how to use it with unicode, though. If I find how to make it work with russian, I'll prepare demo.


Top
   
 Post subject: Re: truetype
PostPosted: Wed Apr 11, 2012 8:33 am 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
Upd: stupid Linux, stupid UTF-8! Everythin' works perfect. Packed Kolibri library should have size about 10 Kb. One nice TTF - about 70-80 Kb. The problem is EVERY program must have copy of TTF in memory. So, I need help with named memory regions for "system" true type font loaded after booting.


Top
   
 Post subject: Re: TrueType
PostPosted: Wed Apr 11, 2012 10:49 am 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
So, I managed to compile this library. It's public domain, so, it's just AWESOME. Works pretty fast.
There are two examples (both statically-linked now):
letter.kex draws letter "Я", you can scale it as you wish
string.kex draws "Hello world" string (or anything else you pass to it through command line).

String.kex doesn't support very long strings (you'll see something weird :D just as planned), as well as russian letters (because I must add my UTF16 converter to it and make few little fixes). Also, you can't scale label yet :D

UPD: St.kex is fixed string.kex, which support russian letters (I added dos2utf, which created for my own library).

I think, I can make COFF (standard Kolibri) library for handling TrueType (based on this library) in a few hours. Resulted binary should be about 10 Kb (I checked size already).

So, dear community, I need help with shared named memory, to store "system" TTF in it (it should save A LOT of RAM).


Attachments:
st.kex [32.28 KiB]
Downloaded 166 times
truetype.7z [133.1 KiB]
Downloaded 175 times
Top
   
 Post subject: Re: TrueType
PostPosted: Wed Apr 11, 2012 12:17 pm 
How about license for TTF fonts?
http://en.wikipedia.org/wiki/TrueType
We must carefully examine all the details before you adopt someone else's technology as one of the standards in the KolibriOS.


Top
   
 Post subject: Re: TrueType
PostPosted: Wed Apr 11, 2012 12:23 pm 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
This library doesn't use hinting. Moreover, patents are expired.


Top
   
 Post subject: Re: TrueType
PostPosted: Wed Apr 11, 2012 12:27 pm 
Patent for the TTF font file != Patent for the library.
Some fonts do not have a free license.


Top
   
 Post subject: Re: TrueType
PostPosted: Wed Apr 11, 2012 12:32 pm 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
Of course. But DejaVu is free font.


Top
   
 Post subject: Re: TrueType
PostPosted: Wed Apr 11, 2012 4:22 pm 
Offline
Mentor
User avatar

Joined: Tue Jan 15, 2008 11:27 am
Posts: 752
SoUrcerer Using sharing memory is very simple. You can see shell 0.5 sources. I added some functions to kolibri.c and they are used in module_program_console.c.


Top
   
 Post subject: Re: TrueType
PostPosted: Wed Apr 11, 2012 5:01 pm 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
Thank you :)


Top
   
 Post subject: Re: TrueType
PostPosted: Sun Apr 22, 2012 6:12 pm 
Offline

Joined: Tue Apr 10, 2012 12:51 pm
Posts: 3
Cool! I'm glad it was useful!

BTW, kolibri.c ? Have you changed over to parts of kolibri written in C? What else is new, there haven't been any official release since 2009 and it's very difficult to follow any progress on these forums when everything is in russian. :(

Regards,
Christoffer


Top
   
 Post subject: Re: TrueType
PostPosted: Sun Apr 22, 2012 7:25 pm 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
bubach wrote:
Cool! I'm glad it was useful!

BTW, kolibri.c ? Have you changed over to parts of kolibri written in C? What else is new, there haven't been any official release since 2009 and it's very difficult to follow any progress on these forums when everything is in russian. :(

Regards,
Christoffer


Didn't get it. Kolibri's kernel is still written in Fasm, and this library is just statically-linked to C-program. I'm trying to make DLL from this library, but it isn't easy. I think I can make my own library faster :(
You're right, there are no new official release, but we have autobuilds ( http://builds.kolibrios.org/ ), latest was built yesterday. I hope we'll have new web-site with software catalogue, list of compatible hardware and so on, but it isn't so easy - we haven't designers or they are very busy :(

upd.. Ah, kolibri.c. It's just wrapper for Kolibri system functions. Can be used with GCC, MSVC and TCC.


Top
   
 Post subject: Re: TrueType
PostPosted: Mon Apr 23, 2012 2:11 am 
Offline

Joined: Tue Apr 10, 2012 12:51 pm
Posts: 3
Ah ok. I understand. Ok, I didn't know there was any work done on font so i yhought you might be able to port it. :P

anyway thats nice to hear I hope you will try to include some english on the new webpage as well ;)


Top
   
 Post subject: Re: TrueType
PostPosted: Mon Apr 23, 2012 10:44 am 
Offline

Joined: Mon Sep 24, 2007 11:11 am
Posts: 2814
Do you know about http://kolibrios.org/en/ ? Or you talking about something else?


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 81 posts ]  Go to page 1 2 3 4 5 6 Next

All times are UTC+03:00


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited