paragui-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[paragui-users] Layout and custom widgets.


From: Guillaume Schmid
Subject: [paragui-users] Layout and custom widgets.
Date: 14 Jun 2002 14:27:40 +0200

Hello,
I am thinking about programming a simple framework for the user
interface of my application. I would like to customize a few widget (by
inheritance, of course) and I would like to use the layout loader.

I did not see if there is a possibility to create some inherited widgets
from the layout loader. I might have missed something, but by looking at
the sources, I think that there might be a solution to my problem
involving some modification of the loader.

I am in no way a XML expert (in fact this is the first time I look into
an xml library so I may have not understood everything and missed some
important points), but I think that this loader would benefit from being
separated into 2 parts.
The first one would be the XML parsing stage, and the second one would
be a factory class.

The factory class would have some methods to create a new widget and to
set the right parameters. And the xml stage would only parse and call
the appropriate methods.

An advantage of this is that it could be possible to inherit from the
factory and extend it to create new widgets defined into the
application.

A second adventage is that it would be possible to use the factory
without the xml layer.

In fact, I was thinking about this because I was told that the use of
xml is rather slow and I am used to parse my data file with some simple
custom grammar written with lex and yacc (and usually, it is fast). So
naturally, I thought that it might be interesting to have a very simple
and efficient layout loader written in a few lines of yacc. And that
would remove some complexity of the layout loader due to parsing context
checking.

So, after all this blablabla, here is my question: Have I missed
something ? Is there a way to create custom widget and about my
suggestions ?

Thank you for your attention.

a++
Guillaume









reply via email to

[Prev in Thread] Current Thread [Next in Thread]