I have a right click menu here and as you can see it shows up nicely:
When I try to add a right click menu to another table, it shows up like this:
Can I re-align the graphic or can I force the MenuItems to be the right size?
Here is the code (I add it to both tables the same way):
ContextMenu contextMenu = new ContextMenu(TableCommons.getAttendanceMenuItem(30),
TableCommons.getAttendanceMenuItem(10),
TableCommons.getAttendanceMenuItem(5));
this.table.setContextMenu(contextMenu);
import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIcon;
import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIconView;
static MenuItem getAttendanceMenuItem(int number)
{
MenuItem attendanceMenuItem = new MenuItem(number + " day Attendance");
MaterialDesignIconView materialDesignIconView = new MaterialDesignIconView(MaterialDesignIcon.FILE_WORD_BOX);
materialDesignIconView.setSize("1em");
materialDesignIconView.setFill(Main.OFFICE_WORD_BLUE_COLOUR);
attendanceMenuItem.setGraphic(materialDesignIconView);
return attendanceMenuItem;
}

