Set maximum number of visible items in popup menus.