tablecolumn

Multiple Components in one column of JavaFX TableView

天大地大妈咪最大 提交于 2019-11-29 11:31:30
I am working with JavaFx 2.2. I am having a problem that I am not able to place different components in a TableView Column. For example I have two columns 1) Answer 2) AnswerType If AnswerType contains “Multiple Choice” then the corresponding cell in Answer Column should display a ComboBox else it should display a TextField. I have a code example below but its displaying either ComboBox or TextField but not both in different cells of same column. import javafx.application.Application; import javafx.beans.property.SimpleStringProperty; import javafx.collections.FXCollections; import javafx

p:column rendered attribute does not seem to work with p:dataTable var

孤人 提交于 2019-11-29 07:48:49
I have written a code like: <p:column headerText="Edit" width="40" rendered="#{(leaveDetails.strLeaveStatus == 'Canceled') or (leaveDetails.strLeaveStatus == 'Availed')}"> <p:commandLink actionListener="#{userLeaveBean.editAppliedLeave}" title="Edit" disabled="true" process="@this" update="leaveDataTable" immediate="false"> <h:graphicImage url="resources/images/edit.JPG"/> <f:attribute name="userId" value="#{employee.name}"/> <f:attribute name="editFirstHalf" value="#{leaveDetails.strStartTiming}"/> <f:attribute name="editSecondHalf" value="#{leaveDetails.strEndTiming}"/> <f:attribute name=

cannot convert from String to ObservableValue<String>

泄露秘密 提交于 2019-11-29 07:04:48
I'm making a program to manage and show data about airports, their flights and so on. The fact is that I have a tableView (in javafx) with several tableColumns, and I want to show some information (destiny, origin, company, etc) on each column so I typed this: @FXML private TableColumn<Flight, String> destinoCol; @FXML private TableColumn<Flight, String> numCol; @FXML private MenuButton aeropuerto; @FXML private MenuButton tipo; @FXML private Button filtrar; @FXML private TableColumn<Flight, LocalTime> horaCol; @FXML private Button este; @FXML private DatePicker fecha; @FXML private

Controls (Combo, Radio, Text) in column header SWT

安稳与你 提交于 2019-11-28 10:34:59
问题 I've been searching everywhere, but I can't find a solution, nor an answer. Can custom controls/widgets be placed in a column header of a table in SWT? I can put those controls in the first row, but that is not the solution, because of the scrolling. The reason for the need is because I'm importing a CSV file, but sometimes the columns in it aren't in the same order as before, so I want to give the user an option to set which column is for what (Radio Buttons or Combo). Thank you. 回答1: No,

JTable horizontal scrollbar based on width of one column

帅比萌擦擦* 提交于 2019-11-28 08:59:58
问题 I am running into a problem that has been discussed on here before: getting a JScrollPane containing a JTable to display the horizontal scrollbar as I desire. HERE is a post I tried following, but for some reason it does not seem to work with my situation (I think it is because I've set one of my columns to have a fixed width. Here is a SSCCE: import javax.swing.JFrame; import javax.swing.JScrollPane; import javax.swing.JTable; import javax.swing.table.DefaultTableModel; @SuppressWarnings(

Multiple Components in one column of JavaFX TableView

北城以北 提交于 2019-11-28 04:49:01
问题 I am working with JavaFx 2.2. I am having a problem that I am not able to place different components in a TableView Column. For example I have two columns 1) Answer 2) AnswerType If AnswerType contains “Multiple Choice” then the corresponding cell in Answer Column should display a ComboBox else it should display a TextField. I have a code example below but its displaying either ComboBox or TextField but not both in different cells of same column. import javafx.application.Application; import

How do I autosize the column in SlickGrid?

谁说我不能喝 提交于 2019-11-28 04:39:25
I want slickgrid to autosize the columns based on the widest content or header text - whichever is wider. In simpler terms, I want it to simulate the default behavior of regular HTML tables when it comes to column sizing. How can I do it in slickgrid? When constructing your options, you can use forceFitColumns: true var options = { enableCellNavigation: true, forceFitColumns: true }; This will make the columns fill the entire width of your grid div. The OP is looking for columns to grow to match their content. grid.autosizeColumns() grows the cells to fit the parent container, which is not the

p:column rendered attribute does not seem to work with p:dataTable var

℡╲_俬逩灬. 提交于 2019-11-28 01:21:00
问题 I have written a code like: <p:column headerText="Edit" width="40" rendered="#{(leaveDetails.strLeaveStatus == 'Canceled') or (leaveDetails.strLeaveStatus == 'Availed')}"> <p:commandLink actionListener="#{userLeaveBean.editAppliedLeave}" title="Edit" disabled="true" process="@this" update="leaveDataTable" immediate="false"> <h:graphicImage url="resources/images/edit.JPG"/> <f:attribute name="userId" value="#{employee.name}"/> <f:attribute name="editFirstHalf" value="#{leaveDetails

cannot convert from String to ObservableValue<String>

这一生的挚爱 提交于 2019-11-28 00:36:46
问题 I'm making a program to manage and show data about airports, their flights and so on. The fact is that I have a tableView (in javafx) with several tableColumns, and I want to show some information (destiny, origin, company, etc) on each column so I typed this: @FXML private TableColumn<Flight, String> destinoCol; @FXML private TableColumn<Flight, String> numCol; @FXML private MenuButton aeropuerto; @FXML private MenuButton tipo; @FXML private Button filtrar; @FXML private TableColumn<Flight,

Slickgrid, column with a drop down select list?

*爱你&永不变心* 提交于 2019-11-27 19:44:29
Hi I was wondering if anyone knows if it's possible to define a column in slickgrid as being a drop down select list. If not does anyone with some experience with slickgrid know how I should go about adding this option? Thanks I assume you mean a custom cell editor. Here's a sample select-based boolean cell editor from slick.editors.js. You could easily modify it to work with an arbitrary set of possible values. function YesNoSelectCellEditor($container, columnDef, value, dataContext) { var $select; var defaultValue = value; var scope = this; this.init = function() { $select = $("<SELECT