# HG changeset patch
# User Olaf Wintermann <olaf.wintermann@gmail.com>
# Date 1736805337 -3600
# Node ID 535089a269c80cffb0c1d49ff1491510417996d5
# Parent  5059f243577589f22e1504507d34bca93942375e
implement table columnsize (GTK4)

diff -r 5059f2435775 -r 535089a269c8 ui/gtk/list.c
--- a/ui/gtk/list.c	Mon Jan 13 22:50:38 2025 +0100
+++ b/ui/gtk/list.c	Mon Jan 13 22:55:37 2025 +0100
@@ -388,6 +388,13 @@
         GtkColumnViewColumn *column = gtk_column_view_column_new(model->titles[i], factory);
         gtk_column_view_column_set_resizable(column, true);
         gtk_column_view_append_column(GTK_COLUMN_VIEW(view), column);
+        
+        int size = model->columnsize[i];
+        if(size > 0) {
+            gtk_column_view_column_set_fixed_width(column, size);
+        } else if(size < 0) {
+            gtk_column_view_column_set_expand(column, TRUE);
+        }
     }
     
     // bind listview to list