So, while still figuring out JavaFX, I managed to turn off text input in the text box, but I'm not sure how to prevent the context menu from appearing when I right-click. Does anyone know how to prevent the default context menu from appearing when right-clicking? `
//CombatFeedback is scrollable textbox to update user on what happening. TextArea CombatFeedback= new TextArea("Text."); CombatFeedback.setPrefColumnCount(20); CombatFeedback.setPrefRowCount(5); CombatFeedback.setWrapText(true); CombatFeedback.setStyle("-fx-font: 20 arial"); CombatFeedback.setEditable(false); ScrollPane scrollerCombat = new ScrollPane(CombatFeedback);`
java user-interface javafx
Strom
source share