Jason Tackaberry wrote:
> On Tue, 2005-12-27 at 21:06 +0100, Dirk Meyer wrote:
>> Maybe put svg support to kaa.imlib2? Yes, I know it has nothing to do
>> with imlib2, but kaa.imlib2 is our image lib and kaa.thumb is based on
>> that. So if you add svg support to kaa.imlib2, we can also generate
>> thumbnails for svg files.
>
> Maybe.  I can move the extension to kaa.imlib2 and just have kaa.canvas
> use that directly, but it will still require extra code to get
> kaa.imlib2 to read SVG files.  I'll think about that.

That would be nice.

>> engine on top of mevas (e.g. adding animations). But I don't see a
>> reason why we need something high-level on top of kaa.canvas. So I
>> would like to request some features to kaa.canvas Freevo needs right
>> now:
>
> Well, some things will still be layered on top of kaa.canvas. I don't
> see the canvas turning into a widget set. :)

True, we still need progressbar, button, window, etc in Freevo. 

>> o Text fading out. IIRC this is already done using imlib2
>
> Right.  It's a terrible kludge, and it doesn't work for TextBlock
> objects, but it does work.

Same with Freevo. For text blocks I have some special handling in
Freevo. You define width and height and Freevo does the line
breaking. If the text is too long, Freevo adds '...'. We only fade for
texts in one line (e.g. menu items with too much text)

>> o Round rectangles. It looks nice to have round corders for
>>   rectangles. I guess evas can't do it since not even imlib2 can. But
>>   imlib2 supports rectangles and circles so based on imlib2 you can
>>   add round rectangles support to kaa.canvas. Just use an imlib2 image
>>   with round corders are requested.
>
> Would it work to just use an image as a template (a white rectangle with
> rounded corners) and scale that to the desired size?  

I like to have the same x and y radius. If you scale the rectangle, it
would look different. But that's a small price, I could live with that
solution. 

>> o Shadows and borders. It is nice to have a shadow or a border around
>>   texts and rectangles. Freevo does this by drawing on object more
>>   than once in different colors. It would be nice if kaa.canvas could
>>   do this, too.
>
> Evas has a bunch of text effects, including shadow and outline, but
> because we're using Imlib2 to render the text (to get the fade-on-clip
> effect), we can't make use of them.

Too bad. BTW, you only need to use imlib2 when you need the fade out
effect. But maybe there is a better way to add the fade out effect
than using imlib2.

>> complicated, adding animation support would kill it. So maybe we need
>> to go back to make a skin file part xml and part python to have the
>> full power of animation. And special classes for drawing menus and the
>> other things to support animation where needed. And how should such an
>> xml file look like?
>
> I keep seeing something like inline Javascript, only python.  Consider
> this fictional, high level example:
>
> <theme name="foo">
>    <screen class="main">
>       <menu name="mainmenu" width="40%" height="70%" hcenter="50%"
>             vcenter="50%" onselect="mainmenu_select" />
>
>       <image right="90%" width="30%" top="10%" alpha="180" 
>              name="watermark" />
>    </screen>
>    <script>
>    <!--
>       def mainmenu_select(screen, item_name, item_label):
>          image = screen.find_object("watermark")
>          image.set_image("watermark-%s.png" % item_name)
>    -->
>    </script>
>     <script src="someotherscript.py" />
> </theme>
>
> Obviously something like the above is going to be really, really hard to
> get right.  Or even good.  But that's the kind of thing I had in mind.

Maybe it would be possible to define tags? Like Freevo registers
<listing> to kaa.canvas and the xml parser will call the Freevo code
when it gets to <listing>?


Dischi

-- 
Veni, Vidi, VISA:
        I came, I saw, I did a little shopping.

Attachment: pgp3Ac6vzxcez.pgp
Description: PGP signature

Reply via email to