I don't know if the approach I used would work in your case, as what you're
after is a lot more flexible than what I built. To simplify what it actually
is, mine is simply laying out components either 1 or 2 in a row depending on
the components size (and container size) and it re-arranges the order
they're shown to minimize wasted space (using brute force, so it increases
in time with factorial), and then expands them slightly in some cases so
they line up nicely. But because my component has distinct rows and yours
doesn't, my approach won't work for you.

Mine is like this:

+-------+---+
|       |   |
+---+---+---+
|   |       |
+-----------+
|           |
+------+----+
|      |
+------+

Whereas yours is a grid in which there are 2 dimensions where things won't
line up like so:

+---+-------+
|   |       |
+---+       |
|   |       |
|   +---+---+
|   |   |   |
|   |   +---+
|   |   |
+-------+

-

sorry for the ascii art :)

-Josh

On Thu, Sep 4, 2008 at 4:17 PM, anuj sharma <[EMAIL PROTECTED]> wrote:

>  Hi Josh
> If you don't mind can you please help me out with the code for this thing.
> You mentioned you had made something like this (snapin).
> Can you please show me which way i have to start and which component i need
> to extend. If its okay with you can i take guidance form your code and try
> to achieve what i am looking for.
> Your help will be appreciated
> Thanks
> Anuj
>
>
> On Wed, Sep 3, 2008 at 7:37 PM, Josh McDonald <[EMAIL PROTECTED]> wrote:
>
>>   Basically it's a *really* hard thing to do, in part due to its nature,
>> in part due to the way Flex does some things. I built something similar, but
>> more specialised (lays out "snapin" components), finds the best order to use
>> the space most efficiently, and increases the size on them so they line up
>> horizontally. It's difficult and it took about a week. I'd say the solution
>> is to relax some of the requirements :)
>>
>> -Josh
>>
>> On Thu, Sep 4, 2008 at 12:26 PM, Amy <[EMAIL PROTECTED]>wrote:
>>
>>> --- In flexcoders@yahoogroups.com, "Doug McCune" <[EMAIL PROTECTED]> wrote:
>>> >
>>> > His layout is really difficult. Basically he wants images to be smart
>>> enough
>>> > to size any which way to fit around each other. If you take a look at
>>> the
>>> > word doc he attached the second mockup shows the problem. Basically he
>>> > doesn't want to restrict to rows or columns, and wants items to be
>>> able to
>>> > span both, which is hard to do.
>>> >
>>> > I honestly don't have an answer for how to do that layout. If you can
>>> change
>>> > the requirement to let you use either columns or rows then you're
>>> fine.
>>>
>>> Isn't that waht Grid does?
>>>
>>>
>>> ------------------------------------
>>>
>>> --
>>> Flexcoders Mailing List
>>> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
>>> Search Archives:
>>> http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
>>> Links
>>>
>>>
>>>
>>>
>>
>>
>> --
>> "Therefore, send not to know For whom the bell tolls. It tolls for thee."
>>
>> http://flex.joshmcdonald.info/
>>
>> :: Josh 'G-Funk' McDonald
>> :: 0437 221 380 :: [EMAIL PROTECTED]
>>
>
> 
>



-- 
"Therefore, send not to know For whom the bell tolls. It tolls for thee."

http://flex.joshmcdonald.info/

:: Josh 'G-Funk' McDonald
:: 0437 221 380 :: [EMAIL PROTECTED]

Reply via email to