1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-19 12:28:22 +01:00
Files
wmaker/WINGs/Tests/testmywidget.c
dan a20aebdef2 - Made all changes for moving WINGs headers in the WINGs subdirectory.
- Updated get-{wings|wutil}-flags accordingly
2001-01-18 19:21:56 +00:00

51 lines
799 B
C

#include <WINGs/WINGs.h>
#include "mywidget.h"
void
wAbort()
{
exit(1);
}
int main(int argc, char **argv)
{
Display *dpy = XOpenDisplay("");
WMScreen *scr;
WMWindow *win;
MyWidget *thing;
WMInitializeApplication("Test", &argc, argv);
if (!dpy) {
wfatal("could not open display");
exit(1);
}
scr = WMCreateSimpleApplicationScreen(dpy);
/* init our widget */
InitMyWidget(scr);
win = WMCreateWindow(scr, "test");
WMResizeWidget(win, 150, 50);
thing = CreateMyWidget(win);
SetMyWidgetText(thing, "The Test");
WMResizeWidget(thing, 100, 20);
WMMoveWidget(thing, 10, 10);
WMRealizeWidget(win);
WMMapSubwidgets(win);
WMMapWidget(win);
WMScreenMainLoop(scr);
return 0;
}