We have to use "4" ...since the  "siMenuItemSection" constant started to
error out on us.

  oItem = oMenu.AddItem( "F  I  L  E", 4 )
  oItem.SetBackgroundColor(128,192,255)

On Thu, Sep 27, 2012 at 4:37 PM, Miquel Campos <[email protected]>wrote:

> Thanks Vladimir!  and thanks Alan to ask my question ;)!
>
> Finally I found that ".AddCommandItem" and ".AddItem" is the same Class
> but only AddItem  can add colors. I  was trying to color the command menu
> but he just didnt work. but not errors.
>
> After found that, I tried without list unpack and it is working.
>
>
> Anyway,  the option to color menus will be great to have it in the future.
> Like Apple folders.
>
>
> Miq
>
> ----------------------------------------------------
> ----------------------------------------------------
> Miquel Campos
> *Character TD & ICE TD
> *www.akaosaru.com
> ----------------------------------------------------
> ----------------------------------------------------
>
>
>
> 2012/9/27 Alan Fregtman <[email protected]>
>
>> Cool! Thanks. :)
>>
>>
>> On Thu, Sep 27, 2012 at 5:04 PM, Vladimir Jankijevic <
>> [email protected]> wrote:
>>
>>> use it this way:
>>>
>>>     MENUCOLOR = [134,179,212]
>>>     menu = in_ctxt.Source
>>>     oItem = menu.AddItem( "XXXXXX", c.siMenuItemSection )
>>>     oItem.SetBackgroundColor( *MENUCOLOR)
>>>     oItem = menu.AddItem( "YYYYY", c.siMenuItemSection )
>>>     oItem.SetBackgroundColor(*MENUCOLOR)
>>>     zMenu = menu.AddSubMenu( "ZZZZZZ" )
>>>     aMenu = zMenu.AddSubMenu( "AAAAAAA" )
>>>     oItem = aMenu.AddItem( " AAAAAAA ", c.siMenuItemSection )
>>>     oItem.SetBackgroundColor(*MENUCOLOR)
>>>
>>> On Thu, Sep 27, 2012 at 4:56 PM, Alan Fregtman 
>>> <[email protected]>wrote:
>>>
>>>> Hey guys,
>>>>
>>>> We're trying to set some background colors for (custom) menu items over
>>>> here, and it's not working. The menuitem gets declared fine and no errors
>>>> appear, but the color won't change.
>>>>
>>>> Is it broken or is there a trick to it I'm not seeing? Just curious.
>>>> Cheers,
>>>>
>>>>    -- Alan
>>>>
>>>>
>>>
>>>
>>> --
>>> ---------------------------------------
>>> Vladimir Jankijevic
>>> Technical Direction
>>>
>>> Elefant Studios AG
>>> Lessingstrasse 15
>>> CH-8002 Zürich
>>>
>>> +41 44 500 48 20
>>>
>>> www.elefantstudios.ch
>>> ---------------------------------------
>>>
>>
>>
>


-- 




-=T=-

Reply via email to