FoieGras- First look at how the text rendering

After about a months of time into the GSoC project, I was able to finish the first significant improvement in the project that happened from my side. For a long time I was wandering here and there testing one thing or the other to see what’s working best and finally got a breakthrough.

For now FoieGras (The code name of the editor we are developing) text engine is capable of these capabilities. It can render some given tags but only inline tags. It can hide and show tags, so if the user wants to see tags and work with them it’s possible. Also you can add more tags and configure the style tags, which are rendered using a configure file. I think it’ll be the main configuration file with regards to text rendering functions. After phenatic (http://phanatic.hu) releases the first UI part, we’ll be able to map the menu events to this text rendering functions and present the first release of FoieGras. 🙂

To tell you how the implementation of FoieGras is done: it’s done using python and PyGTK as the wrapper for GTK to do UI work. First I planned on implementing the text renderer using some thread system, giving a thread to take care of each tag. But soon I understood that it’s a waste of time and resources so thought of a better way. Now the text rendering is done through the XMLparser that comes with python, and so far it’s working nicely.

Also my mentor ( Dr. Don Scorgie – yeah, he is now a doctor 🙂 . Congrats Don ! ) is helping me with technical details and brilliant ideas. FoieGras now has a repository in GNOME svn and I’ve created a branch for tag rendering implementation and copied my works there, So you can check it. Another news is that I’m planning to goto GUADEC next 14th July and I hope it’ll be fun and be able to discuss more about FoieGras there with the team and also hack FoieGras there.

FoieGras-1

FoieGras-2

FoieGras-3

7 thoughts on “FoieGras- First look at how the text rendering

  1. Alex Jones says:

    Hey man.

    Try disabling hinting in your font settings. You’ll get much less sucky bold s’s!

  2. Looks nice, but it would be cool if you provided links to the fullsize image files.

  3. […] FoieGras- First look at how the text rendering After about a months of time into the GSoC project, I was able to finish the first significant improvement in the […] […]

  4. voyou says:

    That looks interesting; I’ve been playing around with something vaguely similar (a WYSIWYG-ish XML editor) myself. One minor point about the code: when you’re applying the tags to the buffer in xmlparser.py, you build the call to ‘insert_with_tags_by_name’ as a string, then exec it, which seems a little ugly. Couldn’t you use the asterisk operator, and do:

    self.buffer.insert_with_tags_by_name(self.iter3,data, *self.tag_stack)

  5. luckycala says:

    Alex, Sorry for that. Issue is fixed.

    Adam, here are the links.
    http://luckycala.wordpress.com/files/2007/07/screenshot.png
    http://luckycala.wordpress.com/files/2007/07/screenshot-1.png
    http://luckycala.wordpress.com/files/2007/07/screenshot-2.png

    voyou, Thanks a lot for reviewing the code. You are obviously correct and when I commit the works again I’ll surely edit this with some more errors in the code. Thanks again for the help.

  6. oh i can’t believe what i’m seeing with my eye. Andreina Cecilio.

Leave a Reply

Your email address will not be published. Required fields are marked *