javafx.scene.control.ListView.getStyleClass()方法的使用及代码示例

x33g5p2x  于2022-01-24 转载在 其他  
字(3.3k)|赞(0)|评价(0)|浏览(198)

本文整理了Java中javafx.scene.control.ListView.getStyleClass()方法的一些代码示例,展示了ListView.getStyleClass()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ListView.getStyleClass()方法的具体详情如下:
包路径:javafx.scene.control.ListView
类名称:ListView
方法名:getStyleClass

ListView.getStyleClass介绍

暂无

代码示例

代码示例来源:origin: jfoenixadmin/JFoenix

updateListHeight();
});
suggestionList.getStyleClass().add("autocomplete-list");
control.suggestionsCellFactoryProperty().addListener((o, oldVal, newVal) -> {
  if (newVal != null) {

代码示例来源:origin: stackoverflow.com

TableView table = new TableView(items);
table.getStyleClass().addAll("visible-lg", "visible-md");

ListView list = new ListView(items);
list.getStyleClass().addAll("visible-xs", "visible-sm");

pane.getChildren().addAll(table, list);

代码示例来源:origin: at.bestsolution.efxclipse.rt/org.eclipse.fx.ui.workbench.fx

public void init(BorderPane parent) {
  this.listView = new ListView<>();
  this.listView.getStyleClass().add("efx-perspective-list"); //$NON-NLS-1$
  this.listView.setCellFactory(PerspectiveCell::new);
  List<MPerspective> list = this.modelService.findElements(this.window, null, MPerspective.class, null);

代码示例来源:origin: org.controlsfx/controlsfx

public AutoCompletePopupSkin(AutoCompletePopup<T> control){
  this.control = control;
  suggestionList = new ListView<>(control.getSuggestions());
  suggestionList.getStyleClass().add(AutoCompletePopup.DEFAULT_STYLE_CLASS);
  suggestionList.getStylesheets().add(AutoCompletionBinding.class
      .getResource("autocompletion.css").toExternalForm()); //$NON-NLS-1$
  /**
   * Here we bind the prefHeightProperty to the minimum height between the
   * max visible rows and the current items list. We also add an arbitrary
   * 5 number because when we have only one item we have the vertical
   * scrollBar showing for no reason.
   */
  suggestionList.prefHeightProperty().bind(
      Bindings.min(control.visibleRowCountProperty(), Bindings.size(suggestionList.getItems()))
      .multiply(LIST_CELL_HEIGHT).add(18));
  suggestionList.setCellFactory(TextFieldListCell.forListView(control.getConverter()));
  
  //Allowing the user to control ListView width.
  suggestionList.prefWidthProperty().bind(control.prefWidthProperty());
  suggestionList.maxWidthProperty().bind(control.maxWidthProperty());
  suggestionList.minWidthProperty().bind(control.minWidthProperty());
  registerEventListener();
}

代码示例来源:origin: com.jfoenix/jfoenix

updateListHeight();
});
suggestionList.getStyleClass().add("autocomplete-list");
control.suggestionsCellFactoryProperty().addListener((o, oldVal, newVal) -> {
  if (newVal != null) {

代码示例来源:origin: at.bestsolution.eclipse/org.eclipse.fx.text.ui

this.stage.getScene().getStylesheets().addAll(this.viewer.getTextWidget().getScene().getStylesheets());
this.proposalList = new ListView<>();
this.proposalList.getStyleClass().add("content-proposal-list"); //$NON-NLS-1$
this.proposalList.setOnMouseClicked((e) -> {
  if(e.getClickCount() == 1) {

代码示例来源:origin: PhoenicisOrg/phoenicis

public void initialise() {
  final ListView<CompactListElement<E>> container = new ListView<>();
  container.getStyleClass().addAll("listWidget", "compactListWidget");

代码示例来源:origin: PhoenicisOrg/phoenicis

public void initialise() {
  final ListView<DetailsListElement<E>> container = new ListView<>();
  container.getStyleClass().addAll("listWidget", "detailsListWidget");

相关文章