m2tklib example
here are some elements (widgets) arranged within the gridlist container (c2 = two columns)
M2_LABEL(el_label1, NULL, "red");
M2_RADIO(el_radio1, "v0", &select_color);
M2_LABEL(el_label2, NULL, "green");
M2_RADIO(el_radio2, "v1", &select_color);
M2_LABEL(el_label3, NULL, "blue");
M2_RADIO(el_radio3, "v2", &select_color);
M2_BUTTON(el_cancel, NULL, "cancel", fn_cancel);
M2_BUTTON(el_ok, NULL, " ok ", fn_ok);
M2_LIST(list) = { &el_label1, &el_radio1,
&el_label2, &el_radio2,
&el_label3, &el_radio3,
&el_cancel, &el_ok };
M2_GRIDLIST(list_element, "c2",list);
results are portable accross different output devices:
dogs102 (dogm128 lib):
16x4 LCD (LiquidCrystal Lib):
Oliver