I'd like to set JMenuItem's height to specified size (width should be auto set to see full text). Method setMinimumSize(X, Y) is ignored (anyone know why?). Method setPreferredSize(X, Y) sets size exactly to X, Y even if it cuts the text of JMenuItem. I've been also tring to work out something with menu.getPopupMenu() and it's layout but without results.. What I'd like to get, is JMenuItem with height of Y and width set to largest JMenu's item (to see whole text; check image at bottom of this post).
I believe this is very easy to do.. but have no ideas how.. I appreciate any suggestions.
Sample code to see the problem:
this is what I've got (text is cut):
this is what I'd like to get (created with graphic editor!):