I'm working with EtoileUI, and I'm trying to setup a ETLayoutItemGroup so that 
it displays its sub-items with a minimum width. No matter what I try, I can't 
seem to stop it from displaying at the minimum 50x50 layout. It would ideally 
resize the layout items so that they have a width equal to the width of the 
layout item group, and then just size the height proportionately. I've tried 
setting the minimum icon size and the "iconSizeForScaleFactorUnit", and even 
the size of the template item I'm creating, but I can't seem to get it to work.

Here is the code that I'm trying to use:

    ETLayoutItemGroup *viewSwitcher = [[ETLayoutItemFactory factory] 
layoutItemGroup];

...

    [viewSwitcher setSize: NSMakeSize(200, 400)];

    ETIconLayout *layout = [ETIconLayout layout];
    ETLayoutItem *templateItem = [[ETLayoutItemFactory factory] item];
    [templateItem setStyle: [[[ETIconAndLabelStyle alloc] init] autorelease]];
    [templateItem setSize: NSMakeSize(128, 128)];
    [layout setTemplateItem: templateItem];
    [layout setPositionalLayout: [ETColumnLayout layout]];
    [layout setItemSizeConstraintStyle: ETSizeConstraintStyleNone];
    [layout setTemplateKeys: A(kETStyleProperty, kETFrameProperty)];
    [layout setIconSizeForScaleFactorUnit: NSMakeSize(256, 256)];
    [layout setMinIconSize: NSMakeSize(256, 256)];

    //[[layout positionalLayout] setItemMargin: 20];
    [viewSwitcher setLayout: layout];
    [[[ETLayoutItemFactory factory] windowGroup]
        addItem: viewSwitcher];
    [viewSwitcher reloadAndUpdateLayout];
}

Would anyone have any ideas?

Thanks

Christopher Armstrong
[email protected]






_______________________________________________
Etoile-discuss mailing list
[email protected]
https://mail.gna.org/listinfo/etoile-discuss

Répondre à