3199 static int text_width = 12;
3208 GtkWidget *frame_pg, *table_pg;
3211 GtkWidget *button_okay;
3214 window_conn = gtk_window_new(GTK_WINDOW_TOPLEVEL);
3215 gtk_container_set_border_width(GTK_CONTAINER(
window_conn), 10);
3216 gtk_window_set_title(GTK_WINDOW(
window_conn),
_(
"PostGIS connection"));
3217 gtk_window_set_position(GTK_WINDOW(
window_conn), GTK_WIN_POS_CENTER);
3221 vbox = gtk_vbox_new(
FALSE, 15);
3226 frame_pg = gtk_frame_new(
_(
"PostGIS Connection"));
3227 table_pg = gtk_table_new(5, 3,
TRUE);
3228 gtk_container_set_border_width (GTK_CONTAINER (table_pg), 8);
3229 gtk_table_set_col_spacings(GTK_TABLE(table_pg), 7);
3230 gtk_table_set_row_spacings(GTK_TABLE(table_pg), 3);
3233 label = gtk_label_new(
_(
"Username:"));
3235 gtk_table_attach_defaults(GTK_TABLE(table_pg), label, 0, 1, 0, 1 );
3236 gtk_table_attach_defaults(GTK_TABLE(table_pg),
entry_pg_user, 1, 3, 0, 1 );
3239 label = gtk_label_new(
_(
"Password:"));
3242 gtk_table_attach_defaults(GTK_TABLE(table_pg), label, 0, 1, 1, 2 );
3243 gtk_table_attach_defaults(GTK_TABLE(table_pg),
entry_pg_pass, 1, 3, 1, 2 );
3246 label = gtk_label_new(
_(
"Server Host:"));
3248 gtk_entry_set_width_chars(GTK_ENTRY(
entry_pg_host), text_width);
3249 gtk_table_attach_defaults(GTK_TABLE(table_pg), label, 0, 1, 2, 3 );
3250 gtk_table_attach_defaults(GTK_TABLE(table_pg),
entry_pg_host, 1, 2, 2, 3 );
3254 gtk_table_attach_defaults(GTK_TABLE(table_pg),
entry_pg_port, 2, 3, 2, 3 );
3257 label = gtk_label_new(
_(
"Database:"));
3259 gtk_table_attach_defaults(GTK_TABLE(table_pg), label, 0, 1, 3, 4 );
3260 gtk_table_attach_defaults(GTK_TABLE(table_pg),
entry_pg_db, 1, 3, 3, 4 );
3263 gtk_container_add(GTK_CONTAINER(frame_pg), table_pg);
3266 gtk_container_add(GTK_CONTAINER(
window_conn), vbox);
3269 gtk_container_add(GTK_CONTAINER(vbox), frame_pg);
3272 button_okay = gtk_button_new_with_label(
_(
"OK"));
3273 gtk_container_add(GTK_CONTAINER(vbox), button_okay);
static GtkWidget * entry_pg_port
static gint pgui_event_popup_delete(GtkWidget *widget, GdkEvent *event, gpointer data)
static GtkWidget * entry_pg_host
static GtkWidget * entry_pg_user
static GtkWidget * entry_pg_db
static GtkWidget * entry_pg_pass
static GtkWidget * window_conn
static void pgui_action_connection_okay(GtkWidget *widget, gpointer data)