Data and collections
Native Qt
Table View
Table View is a native Zui component in the data and collections catalog, with 44 component-specific properties.
Usage
Ruby example
Paste this complete Builder example inside the app surface from the Quickstart. Replace illustrative asset paths with files from your project.
rows = [
{ name: "Ada", role: "Engineer", status: "Online" },
{ name: "Grace", role: "Scientist", status: "Away" }
]
columns = [
{ key: :name, label: "Name", width: 180 },
{ key: :role, label: "Role", width: 220 },
{ key: :status, label: "Status", width: 120 }
]
table = table_view rows, columns: columns,
selection_behavior: :rows,
alternating_rows: true
on table, :cell_click do |cell|
puts "Selected row: #{cell.fetch("row")}"
end
API
Component properties
44 component-specific values, plus shared item and layout properties.
rowsRows configuration for Table View.propertycolumnsColumns configuration for Table View.propertyselected_rowSelected row configuration for Table View.propertyselected_columnSelected column configuration for Table View.propertyshow_headerShow header configuration for Table View.propertyheader_heightHeader height configuration for Table View.propertyrow_heightRow height configuration for Table View.propertycolumn_widthColumn width configuration for Table View.propertyrow_spacingRow spacing configuration for Table View.propertycolumn_spacingColumn spacing configuration for Table View.propertyselection_behaviorSelection behavior configuration for Table View.propertyselection_modeSelection mode configuration for Table View.propertyeditableEditable configuration for Table View.propertyedit_triggersEdit triggers configuration for Table View.propertyalternating_rowsAlternating rows configuration for Table View.propertyanimateAnimate configuration for Table View.propertyreuse_itemsReuse items configuration for Table View.propertykey_navigation_enabledKey navigation enabled configuration for Table View.propertypointer_navigation_enabledPointer navigation enabled configuration for Table View.propertyinteractiveInteractive configuration for Table View.propertyclipClip configuration for Table View.propertypaddingPadding configuration for Table View.propertywidthWidth configuration for Table View.propertyheightHeight configuration for Table View.propertyempty_textEmpty text configuration for Table View.propertyenabledEnabled configuration for Table View.propertybackgroundBackground configuration for Table View.propertyheader_backgroundHeader background configuration for Table View.propertycell_backgroundCell background configuration for Table View.propertyalternate_backgroundAlternate background configuration for Table View.propertyselected_backgroundSelected background configuration for Table View.propertyforegroundForeground configuration for Table View.propertyheader_foregroundHeader foreground configuration for Table View.propertyselected_foregroundSelected foreground configuration for Table View.propertymutedMuted configuration for Table View.propertyaccentAccent configuration for Table View.propertygrid_colorGrid color configuration for Table View.propertyborder_colorBorder color configuration for Table View.propertyradiusRadius configuration for Table View.propertyfont_familyFont family configuration for Table View.propertyfont_sizeFont size configuration for Table View.propertyheader_sizeHeader size configuration for Table View.propertyaccessible_nameAccessible name configuration for Table View.propertyvisibleVisible configuration for Table View.propertyShow 13 shared item properties
opacityscalerotationzfill_widthfill_heightpreferred_widthpreferred_heightminimum_widthminimum_heightmaximum_widthmaximum_heightlayout_alignment
Interaction
Events
Subscribe with on widget, :event and keep behavior in Ruby.
↗
cell_clickNative event payload↗
cell_double_clickNative event payload↗
activateNative event payload↗
selection_changeNative event payload↗
current_changeNative event payload↗
editNative event payload↗
row_count_changeNative event payload↗
column_count_changeNative event payload↗
scrollNative event payload↗
movement_startNative event payload↗
movement_endNative event payload↗
showNative event payload↗
hideNative event payload↗
focusNative event payload↗
blurNative event payload