its seems that i made a mistake and replied ton don only.
Hi
in borders.c, function BorderWinpartCalc says :
----------------------
if (topleft == -1) /* topleft is the value next to TOPLEFT_ORIGIN */
{
x = ((ewin->border->part[i].geom.topleft.x.percent * ww) >> 10) +
ewin->border->part[i].geom.topleft.x.absolute;
y = ((ewin->border->part[i].geom.topleft.y.percent * hh) >> 10) +
ewin->border->part[i].geom.topleft.y.absolute;
}
else if (topleft >= 0) /* if TOPLEFT_ORIGIN is a positive value */
{
x = ((ewin->border->part[i].geom.topleft.x.percent *
ewin->bits[topleft].w) >> 10) +
ewin->border->part[i].geom.topleft.x.absolute +
ewin->bits[topleft].x; /* here is the difference */
y = ((ewin->border->part[i].geom.topleft.y.percent *
ewin->bits[topleft].h) >> 10) +
ewin->border->part[i].geom.topleft.y.absolute +
ewin->bits[topleft].y; /* and here too */
}
-----------------------
Ok, after a litlle more reading, it seems that the -> bits part is an
array of _ewinbits struct. This array describes the borders belonging
to the container window. It looks like it's ordered in the config file
order.
As Don said, it mostly seems to be a way to avoid placement
calculation at theme creation time and to say that your "close" button
starts 2 pixels from the right of the iconify one instead of calculating
distance from the border of the iconify one + size of the iconify
broder +2.
But it seems to also be usefull when you want to place stuffs at a
given distance from each other but you don't know the size they will
have at runtime. I think this can occur if one defines an imageclass
made of pictures of variable size, i.e. to provide zoom effect on
highlight.
An other possibility seems to be that a border can be placed at the
center of another one.
I'll have to try it out. :)
------------------------------------------------------------------------------
This SF.net email is sponsored by
Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev
_______________________________________________
enlightenment-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-users