issue with setting anchors of menu items

I have been trying to create a vertically aligned menu that is left-aligned and includes sub items that are themselves horizontally aligned menus.

You can see an example of this working perfectly for centre aligned menus at http://imgur.com/3PPfO

However, I’ve tried setting the anchors of all of the menu items (and the sub-menu) and the result is this: http://imgur.com/z695Y
All the items are now correctly justified, except for the row that is made up of a set of horizontally aligned controls. No matter what I try, I can’t get it to align properly. Any ideas?

The code that’s used to set it up is:

`quickPlayButton=standardButtonWithTitle(“Quick Play”);
customGameButton=standardButtonWithTitle(“Custom Game”);
optionsButton=standardButtonWithTitle(“Options”);

CCMenuPassive* tempMenu=CCMenuPassive::menuWithItems( standardButtonWithTitle(“1”), standardButtonWithTitle(“2”), standardButtonWithTitle(“3”), standardButtonWithTitle(“4”), NULL);

tempMenu->alignItemsHorizontallyWithPadding(0);

quickPlayButton->setAnchorPoint(ccp(0.0f, 0.5f));
customGameButton->setAnchorPoint(ccp(0.0f, 0.5f));
optionsButton->setAnchorPoint(ccp(0.0f, 0.5f));
tempMenu->setAnchorPoint(ccp(0.0f, 0.5f));
tempMenu->setIsRelativeAnchorPoint(true);

mainMenu = CCMenuPassive::menuWithItems(quickPlayButton, customGameButton, optionsButton, temp, NULL);
mainMenu->setPosition(currentMenuPosition);
mainMenu->alignItemsVerticallyWithPadding(20.0f);

`

CCMenuPassive is almost identical to CCMenu, but it’s necessary to set the content size of the menu itself to the correct size (instead of defaulting to the screen size, as is done in CCMenu). I have checked the anchors and content sizes of the menus and they are all being set correctly, but for some reason, when it comes to the actual rendering, the anchor point doesn’t seem to make a difference. It’s almost as if the tempMenu object is being rendered as if it had zero content size.