I've been trying to figure out how to adjust the coordinates of a MenuButton's Context Menu using CSS, but I haven't had any luck so far. I attempted to use the "top" property in CSS, but it didn't work. I also tried using padding, but that didn't work either.
CSS
.menu-button {
-fx-background-color: #8400d4;
}
.root {
-fx-background-color: #ba5555;
-fx-padding: 10;
}
.context-menu {
-fx-background-color: #006699;
-fx-text-fill: white;
-fx-padding: 5em 0 0 0 ;
top: 5em;
}
.menu-item .label {
-fx-text-fill: #11534b;
}
.menu-item:focused .label {
-fx-text-fill: white;
}
Example Picture :
https://i.sstatic.net/5FlB0.jpg
https://i.sstatic.net/GmdtT.jpg
Any ideas on how I could achieve this? Thanks in advance.