163 |
/** |
/** |
164 |
* Number of spaces between accelerator and menu item's label. |
* Number of spaces between accelerator and menu item's label. |
165 |
*/ |
*/ |
166 |
private int defaultAcceleratorLabelGap = 4; |
private int defaultAcceleratorLabelGap = 10; |
167 |
|
|
168 |
/** |
/** |
169 |
* Creates a new BasicMenuItemUI object. |
* Creates a new BasicMenuItemUI object. |
325 |
m.getToolkit().getFontMetrics(acceleratorFont)); |
m.getToolkit().getFontMetrics(acceleratorFont)); |
326 |
|
|
327 |
// add width of accelerator's text |
// add width of accelerator's text |
328 |
d.width = d.width + rect.width + defaultAcceleratorLabelGap; |
d.width += rect.width + defaultAcceleratorLabelGap; |
329 |
|
|
330 |
// adjust the heigth of the preferred size if necessary |
// adjust the heigth of the preferred size if necessary |
331 |
if (d.height < rect.height) |
if (d.height < rect.height) |