#include <stdio.h>
#include <stdlib.h>
#include "label.h"
#include "container.h"
#include "../common/context.h"
#include "../common/object.h"
#include <ucx/mempool.h>
UIWIDGET ui_label(UiObject *obj,
char *label) {
UiContainer *ct = uic_get_current_container(obj);
XmString str = XmStringCreateLocalized(label);
int n =
0;
Arg args[
16];
XtSetArg(args[n], XmNlabelString, str);
n++;
Widget parent = ct->prepare(ct, args, &n,
FALSE);
Widget widget = XmCreateLabel(parent,
"label", args, n);
ct->add(ct, widget);
XtManageChild(widget);
return widget;
}
UIWIDGET ui_space(UiObject *obj) {
UiContainer *ct = uic_get_current_container(obj);
XmString str = XmStringCreateLocalized(
"");
int n =
0;
Arg args[
16];
XtSetArg(args[n], XmNlabelString, str);
n++;
Widget parent = ct->prepare(ct, args, &n,
TRUE);
Widget widget = XmCreateLabel(parent,
"space_label", args, n);
ct->add(ct, widget);
XtManageChild(widget);
return widget;
}