I just ran into an issue (again actually) that I see, through searching, that a few other devs have also run into: Touch areas being too small for menu items, especially label items.
My temporary solution now was to modify CCMenu's itemForTouch: method to check items rect.size against a minimum size I defined in a macro. If the size is smaller, it's increased to the minimum (without doing anything to the actual item of course). Like this:
#define kMinimumWidth 44.0
#define kMinimumHeight 44.0
-(CCMenuItem *) itemForTouch: (UITouch *) touch
{
CGPoint touchLocation = [touch locationInView: [touch view]];
touchLocation = [[CCDirector sharedDirector] convertToGL: touchLocation];
CCMenuItem* item;
CCARRAY_FOREACH(children_, item){
// ignore invisible and disabled items: issue #779, #866
if ( [item visible] && [item isEnabled] ) {
CGPoint local = [item convertToNodeSpace:touchLocation];
CGRect r = [item rect];
r.origin = CGPointZero;
float newWidth = r.size.width, newHeight = r.size.height;
if (newWidth < kMinimumWidth) {
double factor = kMinimumWidth / newWidth;
newWidth = newWidth * factor;
}
if (newHeight < kMinimumHeight) {
double factor = kMinimumHeight / newHeight;
newHeight = newHeight * factor;
}
r.size = CGSizeMake(newWidth, newHeight);
if( CGRectContainsPoint( r, local ) )
return item;
}
}
return nil;
}
I set it to Apples recommended 44 points, but you could do anything else you deem appropriate of course.
Now, my suggestion for a change to Cocos2d is to add a new property to CCMenuItem, touchArea, that's a CGSize and literally the size you want the touchable area around the item to be. You could then set this for any item, be it that you're making a small text label that should be easily clickable but shouldn't take up too much visual space or an important button that can't be too large but should be easy to tap.
itemForTouch in CCMenu would then be modified to check if the item has this property set (it should have some default of course), and if it is, just use that instead of the rect.size.
This should be backward compatible (since all items would have a default touchArea of e.g. {0,0}) and wouldn't add a lot of overhead to the code. It would make it a lot easier to make small items easily touchable though, and be quite intuitive I think. Make an item, set it's image or label, then set the actual touchable area.
The only risk as I see it is that two items are placed too close together and intercept each others touch areas without intercepting each others visual rects. This could be accounted for by additional checks of course, but if you stick to the iPhone HIG, you shouldn't have items that close to each other anyway.