Padding property of the select tag is incorrect in WebView. left and right���property is ignored. test code: import javafx.application.Application; import javafx.scene.Scene; import javafx.scene.layout.StackPane; import javafx.scene.web.WebView; import javafx.stage.Stage; public class SelectTagPaddingTest extends Application{ @Override public void start(Stage stage) throws Exception { StackPane pane = new StackPane(); WebView browser = new WebView(); browser.getEngine().loadContent( "<html><body>" + "<select style='padding:1em 1em 1em 1em'><option>AAAAAAAAAA<option>BBBBBBBBBBB<option>CCCCCCCCCCC</select><br>" + "<select style='padding:1em 0em 0em 0em'><option>AAAAAAAAAA<option>BBBBBBBBBBB<option>CCCCCCCCCCC</select><br>" + "<select style='padding:0em 1em 0em 0em'><option>AAAAAAAAAA<option>BBBBBBBBBBB<option>CCCCCCCCCCC</select><br>" + "<select style='padding:0em 0em 1em 0em'><option>AAAAAAAAAA<option>BBBBBBBBBBB<option>CCCCCCCCCCC</select><br>" + "<select style='padding:0em 0em 0em 1em'><option>AAAAAAAAAA<option>BBBBBBBBBBB<option>CCCCCCCCCCC</select><br>" + "</body></html>"); pane.getChildren().add(browser); Scene scene = new Scene(pane); stage.setScene(scene); stage.show(); } public static void main(String[] args){ Application.setUserAgentStylesheet(Application.STYLESHEET_MODENA); launch(args); } }
|