libgnt/libgnt

Remove C99-obsoleted constructs

19 months ago, Elliott Sales de Andrade
f5126e6837e3
Remove C99-obsoleted constructs

See [this development thread for a future Fedora change](https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/thread/CJXKTLXJUPZ4F2C2VQOTNMEA5JAUPMBD/) or [the proposed change page](https://fedoraproject.org/wiki/Changes/PortingToModernC). These may be made stronger errors in GCC 14.

Testing Done:
Configured with `-Dc_args='-Werror=implicit-int -Werror=implicit-function-declaration -Werror=int-conversion -Werror=strict-prototypes -Werror=old-style-definition'` and compiled.

Reviewed at https://reviews.imfreedom.org/r/1973/
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <gnt.h>
int
main(void)
{
GntWidget *vbox, *tree;
GntTreeRow *row;
#ifdef STANDALONE
freopen(".error", "w", stderr);
gnt_init();
#endif
vbox = gnt_box_new(FALSE, TRUE);
gnt_widget_set_name(vbox, "vbox");
gnt_box_set_toplevel(GNT_BOX(vbox), TRUE);
gnt_box_set_fill(GNT_BOX(vbox), FALSE);
gnt_box_set_title(GNT_BOX(vbox), "Tree test");
gnt_box_set_alignment(GNT_BOX(vbox), GNT_ALIGN_MID);
tree = gnt_tree_new();
gnt_widget_set_has_border(tree, FALSE);
gnt_box_add_widget(GNT_BOX(vbox), tree);
row = gnt_tree_create_row(GNT_TREE(tree), "foo");
gnt_tree_add_row_last(GNT_TREE(tree), GINT_TO_POINTER(1), row, NULL);
row = gnt_tree_create_row(GNT_TREE(tree), "bar");
gnt_tree_add_row_last(GNT_TREE(tree), GINT_TO_POINTER(2), row, NULL);
row = gnt_tree_create_row(GNT_TREE(tree), "baz");
gnt_tree_add_row_last(GNT_TREE(tree), GINT_TO_POINTER(3), row, NULL);
gnt_widget_show(vbox);
#ifdef STANDALONE
gnt_main();
gnt_quit();
#endif
return 0;
}