我有一个tableview,我在场景构建器中做过。当我在预览中选择显示时,窗口选项看起来很好。当我点击标题列时,箭头指示顺序(但如果我最大化窗口,我点击标题)没有任何反应。该表未被选中,表格静止不动,就像mouseTransparent一样。
这是我的FXML中表格的一部分:
<AnchorPane id="AnchorPane" fx:id="container" disable="false" focusTraversable="true" mouseTransparent="false" opacity="1.0" pickOnBounds="false" prefHeight="699.0" prefWidth="1203.0" styleClass="tab-header-background, tab-pane" xmlns:fx="http://javafx.com/fxml/1" xmlns="http://javafx.com/javafx/2.2" fx:controller="co.com.xdevelop.interfaz.FXMLDocumentController">
<children>
<TabPane blendMode="SRC_OVER" disable="false" focusTraversable="true" mouseTransparent="false" opacity="1.0" pickOnBounds="false" prefHeight="699.0" prefWidth="1203.0" rotate="0.0" rotateGraphic="false" side="BOTTOM" tabClosingPolicy="UNAVAILABLE" tabMaxHeight="1.7976931348623157E308" visible="true" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<tabs>
<Tab closable="false" disable="false" text="Consult">
<content>
<AnchorPane id="Content" focusTraversable="true" minHeight="0.0" minWidth="0.0" pickOnBounds="false" prefHeight="668.0" prefWidth="1199.0" snapToPixel="true">
<children>
<TableView fx:id="generalTable" prefHeight="352.0" prefWidth="1120.0" AnchorPane.bottomAnchor="236.0" AnchorPane.leftAnchor="41.0" AnchorPane.rightAnchor="42.0" AnchorPane.topAnchor="80.0">
<columns>
<TableColumn maxWidth="5000.0" minWidth="10.0" prefWidth="36.0" text="#" fx:id="rowNumber" />
<TableColumn maxWidth="5000.0" minWidth="10.0" prefWidth="173.0" text="Names" fx:id="names" />
<TableColumn maxWidth="5000.0" minWidth="10.0" prefWidth="160.0" text="Last name" fx:id="lastNames" />
<TableColumn maxWidth="5000.0" minWidth="10.0" prefWidth="49.0" text="Document Type" fx:id="typeDocument" />
<TableColumn maxWidth="5000.0" minWidth="10.0" prefWidth="126.0" text="Identification Number" fx:id="identificationNumber" />
<TableColumn maxWidth="5000.0" minWidth="10.0" prefWidth="251.0" text="found" fx:id="pensionFund" />
<TableColumn maxWidth="5000.0" minWidth="10.0" prefWidth="275.0" text="Time" fx:id="affiliationDates" />
<TableColumn maxWidth="5000.0" minWidth="10.0" prefWidth="48.0" text="Changes" fx:id="numberChanges" />
</columns>
</TableView>
提前致谢