HDTenEightyP/NetNews huggingface dataset:
From: adolce@bbn.com (Anne Dolce)
Newsgroups: comp.windows.x.motif
Subject: Menu Item Alignment
Date: 23 Jul 92 14:35:39 GMT
Organization: Bolt, Beranek & Newman, Inc.
NNTP-Posting-Host: spcsun24.bbn.com

Hi,
   I'm having problems getting menu item names to align
   properly.  If I have an XmPulldownMenu with different
   types of buttons, the text labels do not line up.

   For example,

                 +------------------+
                 |     Button 1     |   Push button
                 |     Button 2  -> |   Cascade button
                 | [] Button 3      |   Toggle button
                 +------------------+

    
   The text label for the toggle button doesn't line up 
   with the other push button and cascade button labels. 
   It's always to the left just a bit.  

   I've tried twiddling every Motif resource having to do 
   with XmNspacing (for the toggle button), XmNmarginLeft, 
   etc., etc. but with no success.  

   I've seen other applications get this to work.  Anyone
   know what resource I have to set to fix this problem?

Thanks, Anne
------------
*        *                   *********************************
*        *                   *  Anne Dolce (adolce@bbn.com)  *
*        *                   *  BBN Software Products        *
******   ******   ******     *  150 Cambridge Park Dr 20/9C  *
*    *   *    *   *    *     *  Cambridge, MA  02140  USA    *
*    *   *    *   *    *     *  Phone:  617-873-2122         *
******   ******   *    *     *********************************
Newsgroups: comp.windows.x.motif
From: wolfgg@urmel.vta.mw.tu-muenchen.de (Wolfgang Goettert)
Subject: Modal dialog questions
Reply-To: wolfgg@urmel.vta.mw.tu-muenchen.de
Organization: Lehrstuhl A fuer Verfahrenstechnik, TU Muenchen, 8000 Muenchen 2, Germany
Date: Wed, 29 Jul 1992 09:27:31 GMT

Hi, 
I have a few questions concerning modal dialogs. I did not found the
answers in the FAQ. 
1.) My application has one Toplevel Shell, a mainwindow as child of 
this shell and a menubar as child of mainwindow. If I popup a dialog, 
which is PRIMARY_APPLICATION_MODAL and a child of the Toplevel Shell, 
my understanding of the documentation is that I should still be able 
to click in the menu, but it does not work. Can anyone give me a hint,
please?
2.) If I have a dialog which is MODAL of any kind and the user takes
an action in the dialog, which pops up a second dialog, this one
should be modal, too. In that case the first dialog is unmanaged. It
seems as if only one modal dialog is allowed at one time. My solution
is to unmanage the first dialog, set it to modeless, manage it again
and manage the second one. Is there a better way?
Any answers and suggestions welcome. 

Thanks
-- 
Wolfgang Goettert  Inst. Chem. Engng., TU Muenchen
                   8000 Munich 2, Germany
wolfgg@urmel.vta.mw.tu-muenchen.de Tel.: +49 89 2105 2840
Newsgroups: comp.windows.x.motif
From: matt@fics.uucp (Shithead II)
Subject: poping XtMainWindow
Organization: Kvam data as
Date: Tue, 21 Jul 1992 09:34:26 GMT


  I have an AppShell (from XtAppCreatShell()) and then a dialog box 
  (a XmCreateDialogShell() in with Style=PRIMARY_APPLICATION_MODAL
  so the MainWindow in the AppShell is off limits...)

  when the dialog box is done and removed (via XtUnmanageChild() and then
  XtDestroyWidget()) how can I force my AppShell to be place on *top*
  of all of the other windows in my display?

  I know the answer is (well, should be) easy, but...

  oh, I'm in Motif 1.1


Matthew Kerr
Kvam data as
Nikkelveien 14, N-4300 Sandnes, Norway
Tel: + 47 4 62 37 66
Fax: + 47 4 62 39 85
Newsgroups: comp.windows.x.motif
From: klee@wsl.dec.com (Ken Lee)
Subject: Re: how to associate a pixval to a XmPushButton ?
Reply-To: klee@wsl.dec.com
Organization: DEC Western Software Laboratory
Date: Tue, 21 Jul 92 20:55:22 GMT

|> According to my understanding, one can only use the symbolic color name or
|> RGB values to set background resource. There is no way to use pixel value.

How are you setting this value?  If you use XtSetValues (which you
probably should if you're dealing with pixel values), then you must use
the pixel value, not the color name string.

-- 
Ken Lee
DEC Western Software Laboratory, Palo Alto, Calif.
Internet: klee@wsl.dec.com
uucp: uunet!decwrl!klee
Xref: sparky comp.windows.x.motif:5214 comp.windows.x:14365
From: munoz@bcstec.ca.boeing.com (David Munoz)
Newsgroups: comp.windows.x.motif,comp.windows.x
Subject: How do you make a whole composite motif window appear "grey" or "Insensitive"?
Keywords: X11R5, Motif 1.1.2, Transparent Window, See Through
Date: 22 Jul 92 18:29:35 GMT
Followup-To: poster
Organization: Boeing Computer Services, Seattle

Hellow fellow net talkers,

How do you make a whole window appear insensitive? by
"whole window" I mean a container widget that has
a bunch of motif components in it, like scrollbars,
pushbuttons, text widgets etc.  The effect I want
is for the display to appear to have a transparent
veil pulled over it, as if you were able to mask
a diagonal hatch pattern, or other pattern on to
the display and still see what's underneith.

Any help would be greatly appreciated.  Please
e-mail if possible.

Thanks,

David Munoz
dgm1626@boeing
From: nhj@cs.bham.ac.uk (Nick Jurascheck)
Newsgroups: comp.windows.x.motif
Subject: Bug in XmScale ??
Summary: Help requested regarding possible bug in XmScale widget.
Keywords: XmScale, help
Date: 24 Jul 92 17:01:43 GMT
Followup-To: nhj@cs.bham.ac.uk
Organization: School of Computer Science, Univ of Birmingham, UK

Hi !

My Motif application exhibits some very strange behaviour when the
user clicks on a slider, to in/de-crement its value by
XmNscaleMultiple. Under certain program conditions, this causes a
message dialog to pop up, in which case the value-changed callback
gets repeatedly called, as if in an infinite loop, instead of just
getting called once.  If the callback does not cause the dialog box to
pop up there is no problem. When the same callback is triggered by
dragging the slider bar, this problem does not occur at all.

Could this be a bug in Motif ? BTW I am using v1.0 on a DECstation
running Ultrix 4.2.

Any suggestions would be welcomed; if necessary I could post some
code, but it's on another machine, and in any case the code that
causes this problem is very standard stuff. All that is required to
cause this effect is to add an XmNvalueChanged callback to an XmScale
widget, and then popup a MessageDialog from inside the callback.

If this is a bug, is there a way I can work around it, perhaps even by
disabling the 'click on slider' facility? (I can't see how to do
this...)

-- 
JANET: N.H.Jurascheck@cs.bham.ac.uk | UUCP: ...!mcvax!bhamcs!JurascheckNH
BITNET: JurascheckNH%cs.bham.ac.uk@ukacrl.bitnet
INTERNET: JurascheckNH%cs.bham.ac.uk@cunyvm.cuny.edu
From: olsenc@milton.u.washington.edu (Clint Olsen)
Newsgroups: comp.windows.x.motif
Subject: Building motif 1.1.4 w/X11R5 on SunOS 4.1.2
Date: 29 Jul 92 09:12:32 GMT
Organization: University of Washington, Seattle


Hello:

After reading the README doc w/motif 1.1.4, I got the impression
that it would NOT work with X11R5.  Apparently it said that it
expects to see X11R4 Xlibs and other X11R4 stuff.  If this is true,
will motif 1.2 be compatible with X11R5?  I am aware that there
is a backward compatibility switch for X.

Has anyone out there done anything remotely similar to this on a
Sun Sparc 2 running SunOS 4.1.2?  Advice would be appreciated.

Clint Olsen
olsenc@maxwell.ee.washington.edu
Newsgroups: comp.windows.x.motif
From: schnepp@nodecg.ncc.telecomwa.oz.au (Tom Schnepple)
Subject: Validating Text Widgets
Organization: Network Computer Centre
Date: Thu, 23 Jul 1992 12:13:15 GMT


Problem: Validating Text Widgets 

Sorry if you've received this more than once, my posting does not seem to work  properly....
My application uses the MOTIF library and run under X. It has several text
entry forms, and each text field needs to be validated and acted upon.
What I want to do is to implement a text entry validation routine for
these text widgets.

The only appropriate callback resource for text widgets in my application
is XmNlosingFocusCallback, so I have attached a callback to each of my text
widgets as follow:

XtAddCallback(text_widget, XmNlosingFocusCallback,
		text_callback, callback_data);

In the callback routine (text_callback), I would check to see if the 
entered text is valid, if not, I would output an error message. 
After outputing the error message, I also want to put the focus back on 
the text widget that has called the callback routine so that the user 
can re-enter the text:

	void   text_callback
	(
		Widget	    	widget,
		caddr_t		client_data,
		caddr_t     	call_data
	)
	{
	      char	      ascii_text[10];

		/* get the text entered in the text widget and
		** initialise the text in the ascii_text array
		*/
		  strcpy(ascii_text, XmTextGetString(widget));

		/* validate the entered text
		** validate text are either "YES" or "NO"
		*/
		  if ((strcmp(ascii_text, "YES") != 0) or
			(strcmp(ascii_text, "NO")  != 0))
			{
			    /* outputing error messages
			    */
				  /* ...., code too complicated to add here */

				/* setting the focus at the widget so that
				** the user can re-enter the text
				*/
				  XmProcessTraversal(widget, 
							XmTRAVERSE_CURRENT);
			}
	}

PROBLEM: I can't seem to be able to place the focus back to the text widget 
	which is being validated. Since to be able to invoke the callback 
	the user has to hit a Tab key to move to the next field 
	(ie: callback is called when the text field has lost its focus). 
	Thus, after the user has finished entering the text and hit the Tab 
	key to move to the next field, the callback function was called and 
	the focus was set back to the text field, but after the callback 
	has finished, the Tab key action is processed and the focus is set 
	to the next field.
			
HELP	Does anyone know how I can set the focus back the the text widget 
	that is being validated?? Any help would be much appreciated!!

Thanks in advance!!
 

     _--_|\    Tom Schnepple  (schnepp@telecomwa.oz.au) 
    /      \   Perth, Western Australia
--> *_.--._/ 
          v 
Newsgroups: comp.windows.x.motif
From: gopal@iastate.edu (Suresh Gopalratnam)
Subject: In case you happen to teach X-window,motif course(s)!
Organization: Iowa State University, Ames IA
Date: Thu, 23 Jul 1992 18:39:46 GMT

 I am a newcomer. I am just flaggerbasted by the number of books
on windows. I need help from you guys. Can you tell me how I should
start off? like what books to read? General course outline. Any material
you might have prepared for such classes etc.,.

  Hoping for a reply soon. Thanks in advance. If anybody else is
interested I will post what I receive.

Newsgroups: comp.windows.x.motif
From: dbrooks@osf.org (David Brooks)
Subject: Re: Is widget C the decendant of widget A?
Followup-To: comp.windows.x.motif
Reply-To: dbrooks@osf.org (David Brooks)
Organization: Open Software Foundation
Date: Wed, 22 Jul 1992 14:03:34 GMT

In article <1992Jul21.170650.1@ssrl01.slac.stanford.edu> tcox@ssrl01.slac.stanford.edu (Tony Cox) writes:
>In article <1992Jul21.202155.23809@uhura.neoucom.edu>, fmc@uhura.neoucom.edu (Fu-Min Chen) writes:
>#  If widget C is the child of widget B and widget B is the child of widget A,
>#  What can I do to determine is widget C the descendant of widget A?
>
>	if (A == XtParent( XtParent( XtParent( D)))
>		etc.
>
>{but I cant help thinking that perhaps the question you need to ask is
> different still... ;-)

Try this question: How can I tell if widget B is *a* descendant of widget A?

	for (C = B; C; C = XtParent(C))
	  if (C == B) return true;
	return false;

You may want to insert a test into the loop to break out if XtIsShell(C) is
true, if you don't want look beyond the shell your widget is in.
-- 
David Brooks					dbrooks@osf.org
Open Software Foundation			uunet!osf.org!dbrooks
Six more months!  Six more months!
Newsgroups: comp.windows.x.motif
From: kahil@gamekeeper.bellcore.com (Richard K. Branton)
Subject: Custom Resources
Organization: Bellcore, Livingston, NJ
Date: Tue, 21 Jul 92 20:12:39 GMT

I am interested in creating my own custom resources which
could be attached to a widget in sort of the way wcl does
"theWidget.wcClassName: ...".

Does anybody know how to attach your own resources to motif
widgets?  Better yet, does anybody have any code which
demonstrates this technique?

Thanks.

----------------------------->
kahil@gamekeeper.bellcore.com
----------------------------->
From: liw@rockyj.rockefeller.edu (Wentian Li)
Newsgroups: comp.windows.x.motif
Subject: Re: using gif files in motif
Date: 30 Jul 92 16:07:18 GMT
Organization: Rockefeller University


I'm posting this for someone else who doesn't
have access to READNEWS...  
 
--------------------------------------------------- 
Does anyone know how to add "record" and "playback"
features in motif window programming? (i.e., record
the keystrokes and mouse motions for the purpose of
later playback). 
---------------------------------------------------
 
Please send a message to wli@physics-sun.rockefeller.edu
Thanks!
From: d8ahlcr@dtek.chalmers.se (Christopher Ahlberg)
Newsgroups: comp.windows.x.motif
Subject: two buttons on the same XmScale, this time not empty!
Date: 21 Jul 92 15:54:50 GMT
Organization: Chalmers University of Technology


	/Christopher

--
Christopher Ahlberg		       Chalmers University of Technology
email: d8ahlcr@dtek.chalmers.se	       School of Computer Science & Engineering
				       G|teborg, Sweden

Newsgroups: comp.windows.x.motif
From: scott@asd.com (Scott Barman)
Subject: Quickie separator widget question
Organization: American Software Development Corp., W. Babylon, NY
Date: Wed, 29 Jul 1992 21:37:11 GMT

How can I change the thickness of an XmSeparator widget XmNseparatorType
is set to XmSINGLE_LINE and XmNorientation is XmVERTICAL?

THANKS!
-- 
scott barman			| <This space intentionally left blank>
scott@asd.com			|
 (I can barely speak for myself, you expect me to speak for my employer??)
From: jxt@stc06.ctd.ornl.gov (TOLLIVER J S)
Newsgroups: comp.windows.x.motif
Subject: Problems positioning option menus
Date: 27 Jul 92 16:28:14 GMT
Reply-To: jxt@stc06.ctd.ornl.gov (TOLLIVER J S)
Organization: Oak Ridge National Laboratory

Hi. I've got a small aesthetic problem positioning option menus in a Motif
1.1 application. Consider the desired look (greatly simplified for brevity):

 -------------------------------------------------------------
 |  Label1  Text1                              Label2 Text2  |
 |                                                           |
 |  option_menu_label1 menu1       option_menu_label2 menu2  |
 |                                                           |
 -------------------------------------------------------------
    ^                                                     ^
    |                                                     |
    \--------I want these positions to line up------------/

All of this is in a Form with the Label and Text widgets positioned with
XmPOSITION values. That is, Label1 begins at XmNleftPosition = 2 and
Text2 ends at XmNrightPosition = 98 (using default fractionBase of 100).

The option menus and labels are made with XmCreateOptionMenu. Lets call
the RowColumns returned option_menu1 and option_menu2 and try to position
them as shown above.

Alas, specifying leftPosition of 2 for option_menu_1 and rightPosition
of 98 for option_menu2 produces this:

 -------------------------------------------------------------
 |  Label1  Text1                              Label2 Text2  |
 |                                                           |
 |   option_menu_label1 menu1   option_menu_label2 menu2     |
 |                                                           |
 -------------------------------------------------------------
    ^                                                   ^
    |                                                   |
    \--------GAK!---------------------------------------/

Note option_menu_label1 is not where I want it. Neither is menu2.
Turning on a borderWidth of 1 indicates that the border is left-aligned
where I want it, but there seems to be small amount of space built in
between the border and label on the left. I've tried ALIGNMENT_BEGINNING.
I've tried setting the position resources on XmOptionLabelGadget(). No
luck! (Setting the left position at 1 instead of 2 moves it too far left.)

Similarly, the border indicates that option_menu2 is indeed positioned
where I want it but there is a (larger) amount of space between the menu and
the right edge of the border. This amount of space is adjustable somewhat by
varying the amount of text in option_menu_label2.

How can I position these option menus where I really want them? Thanks
for any advice you can offer.

Johnny Tolliver
Oak Ridge National Laboratory
jxt@ornl.gov
Newsgroups: comp.windows.x.motif
From: rvloon@cv.ruu.nl (Ronald van Loon)
Subject: Re: Is widget B the child of widget A?
Originator: rvloon@triton.cv.ruu.nl
Date: Tue, 21 Jul 1992 14:23:40 GMT
Organization: University of Utrecht, 3D Computer Vision Research Group

In <1992Jul21.122535.19734@uhura.neoucom.edu> fmc@uhura.neoucom.edu (Fu-Min Chen) writes:

| "Can someone tell me what is the easy way to find out if widget B is the child
| "of widget A?
| "
| "Thank You!
| "
| "Fu-Min Chen
| "fmc@uhura.neoucom.edu

Widget A,B;

if (XtParent(B) == A)
  { 
   /* B is a child of A */
  }
else
  { 
    /* B is not a child of A */
  }
-- 
Ronald van Loon (rvloon@cv.ruu.nl) 3DCV Group, Utrecht, The Netherlands.

Insanity is not bad in itself as long as there is a system to it. (H.Liberg)
Healthy absurdism once in a while has never hurt anybody (me)
From: smith@ctron.com (Larry Smith)
Newsgroups: comp.windows.x.motif
Subject: Re: What is "Purify" ? (Ostriches)
Date: 28 Jul 92 12:38:58 GMT
Reply-To: smith@ctron.com
Organization: Cabletron Systems, Inc.

In article <BruxKB.1Ms@solbourne.com> misek@solbourne.com (Steve Misek) writes:

>If you release software that you have not run through purify, you're just
>begging for trouble.

Purify, as I've mentioned before, is not a substitute for malloc/free analysis.
I've run Purify on a large program here at Cabletron and had it tell me just
687 bytes were unaccounted for - when our debug malloc told me in no uncertain
terms that I had over a megabyte gone with the wind.  Purify is very good at
certain things, but if you assume it can tell you everything, then if you
release software tested with it you're just, to steal a phrase, begging for
trouble.

Larry Smith (smith@ctron.com) No, I don't speak for Cabletron.
-------------------------------------------------------------
Daily I'd go over to Congress - that grand old benevolent national asylum - and
report on the inmates there.  Never seen a body of men with tongues more handy,
or information more uncertain.  If one of those men had been present when the
Deity was on the point of saying "Let there be light" we never would've had it.
From: drp40@cd.amdahl.com (Douglas R Puchalski)
Newsgroups: comp.windows.x.motif
Subject: Virtual desktop in MWM
Date: 25 Jul 92 21:29:40 GMT
Reply-To: drp40@cd.amdahl.com
Organization: Amdahl Corporation, Sunnyvale, CA

I wrote a while back and someone told me the name of
a program that would give me a virtual desktop in MWM.
Actually it was supposed to work with any window mgr.

Well, I wasn't able to get it to compile, and blew it
off.  I'd like to give it another try, and I forgot
the name of the program.  Can someone remind me?

Thanks.

-- 
Doug Puchalski						drp40@cd.amdahl.com
Newsgroups: comp.windows.x.motif,biz.sco.opendesktop
From: vijay@iitb.ernet.in (Vijay J. Talati)
Subject: Overriding the Return key in text widget
Organization: Indian Institute of Technology, Bombay
Date: Wed, 22 Jul 1992 07:04:24 IST

Hi,

I have a text widget in which i want to take some particular action
when return key is pressed. I am doing the following, but it does not work.

-----------
/* Declarations for translations */
char	newTrans[] = "<Key>Return : my_action()" ;

XtTranslations 	transTable ;


/* The actual code which translates( after creating 
			the multiline textwidget)*/

transTable = XtParseTranslationTable(newTrans) ;
XtOverrideTranslations(textWidget, transTrable); 

XtManageChild(textWidget) ;



------------


But doing this does not help.. my_action is not called .Pressing Return
gives only the newline() action.

So whats wrong ???

The textwidget is child of a Bulletin Board widget .

I am using Motif 1.0, ODT 1.0 under SCO-UNIX 5.3.2.

Thanks.

Vijay.
(vijay@gateway.iitb.ernet.in) 

P.S. : This is not the FAQ30.
From: reha@cunixf.cc.columbia.edu (Reha Elci)
Newsgroups: comp.windows.x.motif
Subject: Re: Serious Expose Event Problem!
Date: 24 Jul 92 20:26:31 GMT
Reply-To: reha@cunixf.cc.columbia.edu (Reha Elci)
Organization: Columbia University

In article <1992Jul24.180513.945@PA.dec.com> klee@wsl.dec.com writes:
>
>An expose event means that more area is visible (and thus has to be painted
>by the client).  If you're interested in configuration changes, then use
>ConfigureNotify events.
>

Not true. I am converting from DEC Dwt to DEC Motif 1.1.3 and 
under Dwt when a DwtWindow is attached in a DwtAttachedDialogBox
Expose events are generated on both shrinks and grows. Dwt is doing
things correctly, Xm's behavior is questionable and inconsistent.

Furthermore, I also added <ConfigureNotify> to actions as well
and that did not solve the problem either.

Anyhow, thanks to Dan Smith (thanks *very* much Dan!); I've 
identified and corrected the problem which seems to be
related to the Gravity of the XmDrawingArea. Why motif's
choices are different than Dwt's is still a mystery.

Reha Elci
Email: elci@bugs.gs.com
From: osbornk@prism.CS.ORST.EDU (Kasey S. Osborn)
Newsgroups: comp.windows.x.motif
Subject: Help with handling a resized MLE text widget.
Date: 28 Jul 92 19:45:13 GMT
Organization: Oregon State University, Computer Science Dept.

My application contains a scrolled window containing a multi-
line text window with application defined scrolling policy.
That is, I've taken control of the scrollbars because the work
window would be huge.  Everything works except when the
scrolled window is resized.  The scrollbars resize correctly,
but I need to be notified so that I may adjust the contents of
the MLE text widget.  There are no resize callbacks in Motif
(1.1) except in the drawing area widget!

Heller's book (p. 237) says to do this:

  XtActionsRec rec;
  rec.string = "resize"; rec.proc = resize;
  XtAddActions (& rec, 1);
     XtOverrideTranslations (mleTextWidgetWithinScroll,
       XtParseTranslationTable ("<Configure>: resize ()"));

'resize' is never called and I get a warning at app. startup:
  Warning: Actions not found: resize

So, how can I find out when a text widget is resized?  Do I even
have a clue?  Thanks for any help.
--
Kasey S. Osborn
osbornk@cs.orst.edu
"There's a lot to be said for brevity."
From: neve@nlm.nih.gov (Leif Neve)
Newsgroups: comp.windows.x.motif
Subject: Shareable libXm on Sun: Worthwhile?
Keywords: shareable, libXm
Date: 21 Jul 92 13:55:10 GMT
Reply-To: neve@nlm.nih.gov
Organization: National Library of Medicine

I've read the Motif FAQ which tells you *how* to build libXm shareable
on a Sun platform. What I want to know is:

     Have the modules in libXm been written in such a way that it is
    *worthwhile* building it shareable? 

I'm talking here about all the things it tells you to do in the Sun manual when
it comes to building shareable libs. For example, should there technically be
a .sa file?

I'd love to hear from the OSF folks on this. But also, if folks are doing
the shareable thing on Suns with libXm and have seen the expected performance
gains, I'd love to hear about that also.

Leif Neve
NLM