Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!sdd.hp.com!hp-pcd!hpcvlx!paulm From: paulm@hpcvlx.cv.hp.com (Paul J. McClellan) Newsgroups: comp.windows.x.motif Subject: Re: mwmDecorations Message-ID: <110630024@hpcvlx.cv.hp.com> Date: 31 Oct 90 17:10:46 GMT References: <881@kivax.UUCP> Organization: Hewlett-Packard Co., Corvallis, OR, USA Lines: 75 The following client sets its mwm decorations to only include the resize handles and the title bar. The border is not included when resize handles are specified. The defines you need are listed in /usr/include/X11/MwmUtil.h . /************************************************************************ * File: decor.c * * Allow only the resize and title client decoration (border decoration * is not included when the resize handles are). ***********************************************************************/ #include #include #include #include #include #include /************************************************************************ * main ***********************************************************************/ main (argc, argv) int argc; char **argv; { XtAppContext context; Display *display; int ac; Arg al[2]; Widget app_shell, label; /* Initialize toolkit, create app context, and open display. */ XtToolkitInitialize (); context = XtCreateApplicationContext (); display = XtOpenDisplay (context, NULL, argv[0], "App-notes", NULL, 0, &argc, argv); if (!display) { XtWarning ("%s: can't open display, exiting...", argv[0]); exit (0); } /* * Create the ApplicationShell. * Set the XmNmwmDecorations resource. */ app_shell = XtAppCreateShell (argv[0], "App-notes", applicationShellWidgetClass, display, NULL, 0); ac = 0; XtSetArg (al[ac], XmNmwmDecorations, MWM_DECOR_RESIZEH|MWM_DECOR_TITLE); ac++; XtSetValues (app_shell, al, ac); /* * Create a Label widget for display purposes. */ label = XmCreateLabel (app_shell, "label", NULL, 0); XtManageChild (label); /* * Realize the widget hierarchy and enter the main loop. */ XtRealizeWidget (app_shell); XtAppMainLoop (context); }