{ 0, 0, 0, NULL, (void*)&SizeKludge, "", NULL, BarEnd, "" },
{ 0, LR|T2T|BORDER|SAME_ROW, 0, NULL, NULL, "", NULL, Label, "1" }, // optional title in window
{ 50, LL|TT, 100, NULL, (void*) &LogoW, NULL, NULL, -1, "LogoW" }, // white logo
-{ 0, L2L|T2T, 200, NULL, (void*) &CCB, NULL, NULL, Label, "White" }, // white clock
-{ 0, R2R|T2T|SAME_ROW, 200, NULL, (void*) &CCB, NULL, NULL, Label, "Black" }, // black clock
+{ 12, L2L|T2T, 200, NULL, (void*) &CCB, NULL, NULL, Label, "White" }, // white clock
+{ 13, R2R|T2T|SAME_ROW, 200, NULL, (void*) &CCB, NULL, NULL, Label, "Black" }, // black clock
{ 50, RR|TT|SAME_ROW, 100, NULL, (void*) &LogoB, NULL, NULL, -1, "LogoB" }, // black logo
{ 0, LR|T2T|BORDER, 401, NULL, NULL, "", NULL, -1, "2" }, // backup for title in window (if no room for other)
{ 0, LR|T2T|BORDER, 270, NULL, NULL, "", NULL, Label, "message" }, // message field
gboolean res;
gint index, x, y;
+ if(memo->type == Label) { ((ButtonCallback*) memo->target)(memo->value); return TRUE; } // only clock widgets use this
+
switch(event->type) { // figure out what's up
case GDK_MOTION_NOTIFY:
f = 0;
gtk_container_add(GTK_CONTAINER(frame), label);
label = frame;
}
- Pack(hbox, table, label, left, left+3, top);
+ Pack(hbox, table, label, left, left+3, top);
+ if(option[i].target) { // allow user to specify event handler for button presses
+ gtk_widget_add_events(GTK_WIDGET(label), GDK_BUTTON_PRESS_MASK);
+ g_signal_connect(label, "button-press-event", G_CALLBACK(MemoEvent), (gpointer) &option[i]);
+ }
break;
case SaveButton:
case Button: