HDTenEightyP/NetNews huggingface dataset:
From: dbrooks@osf.org
Newsgroups: comp.windows.x.motif
Subject: Re: XmTextSetString to NULL
Date: 23 Jul 92 21:01:08 GMT
Distribution: inet
Organization: The Internet

>I am having a trouble trying to set a XmTextField to a null
>string. It core dumps the program.
>
>Is
>pointer=NULL;
>XmTextSetString(text_widget, pointer)
>allowed ?

Actually, the answer is no.  First, you should be using XmTextFieldSetString,
and second the manpage/AES describes the 2nd parameter as "the character
pointer to the string value", and NULL isn't a pointer to anything.

Unfortunately, the widget code tries to be helpful to those who commit these
common errors.  But (you don't say what rev you are using) it's a known bug
that this doesn't work if the widget has a modifyVerifyCallback.  Fixed in
1.1.5 and, I'm pretty sure, 1.2.

David Brooks
Systems Engineering
Open Software Foundation
From: snail@lsl.co.uk
Newsgroups: comp.windows.x.motif
Subject: Re: XmStrings seem to cause memory leak.....
Date: 23 Jul 92 17:00:53 GMT
Organization: Laser-Scan Ltd., Cambridge

> ----------------
> malloc_verify: bad block size (1633841013) at 0x1e2584
> 

Hi, I don't know what your program does (looks like database access etc) but
the bug is probably in there. You're obviosuly on a Sun, since malloc_verify
is a sun enhancement to malloc. Bad blcok size means that something has 
trampled onto the beginning (most probably) of the malloc block you're trying
to use, and has knobled some of the (simple) checksums it uses. The problem
more than likely is nothing to do with the XmStrings. Note that X11R4 and early
Motif releases are worse than later ones.

If you really want to get to the bottom of your problem, get Purify from
Pure Software. It's amazingly good at this type of problem solving.

UK: info@pts.co.uk
US: info@pure.com

I don't know them, I just use the product. SPARCstations only tho (pity).
If they want to give me money...(they don't) fine! :-).
                                                              *      *
Stephen Kellett                                _______         \    /
Software Engineer                            --   ___ --        \  /  
Laser Scan Ltd                              (    _   __ )      ======
Science Park                               (    (  |   ) )    =      =
Milton Road                                (     (_)    ))   =  *  *  =
Cambridge CB4 4FS                           (           )  ==   .  .  =
England                                      --       --===      ..  =
snail@lsl.co.uk                              ==_______             ==
(+44) 223 420414 ex 275              ========                  ====   
                          ===========                      ====      [ ]BEER
                       ====================================          | |CIDER
-------------------------------------------------------------------------------
Newsgroups: comp.windows.x.motif
From: chris@ods.com (Chris Atkins)
Subject: Re: Wrapping a widget round a Window
Organization: Optical Data Systems, Inc.
X-Newsreader: Tin 1.1 PL4
Date: Fri, 24 Jul 1992 20:28:54 GMT

joel@argon.NoSubdomain.NoDomain (Joel Loo Peing Ling) writes:
: I am working on an application that requires multiple clients to draw in the
: same window. The problem is that MrmFetchWidget does not allow a X window ID
: to be passed as an argument and instead always creates a new window. How do
: I get around this?
: 
: I had tried setting the window slot of the core struct
: (ie. widget->core.window=myXwindowID), this only causes
: the drawing (output to the window) to appear correctly 
: but the widget does not get any event notification.
: 
: Any help will be very much appreciated.
: 
: -joel
Newsgroups: comp.windows.x.motif
From: nieh@surya.cadence.com (Ko-Haw Nieh)
Subject: how to associate a pixval to a XmPushButton ?
Reply-To: nieh@cadence.com (Ko-Haw Nieh)
Organization: Cadence Design Systems, San Jose CA.
Date: Wed, 8 Jul 1992 04:47:06 GMT


I would like to set the background color of a XmPushbutton widget to a 
particular pixel value. Therefore when I modified the colorMap
it will affect the background color of that XmPushbutton.

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.

My question is, how do I set the background of a XmPushbutton widget to
pixval=125. I don't care what is the color in pixval=125.

Thanks in advance,

--
Ko-Haw Nieh
Cadence Design System Inc.
2820 Orchard Parkway San Jose, CA. 95134
Tele: 408-944-6821  E-mail: nieh@cadence.com Fax: 408-943-1899



Newsgroups: comp.windows.x.motif
From: todds@code3 (Todd Stevenson)
Subject: Problems with Doug Young's tree widget
Organization: 3M Health Information Systems
Date: Mon, 27 Jul 1992 17:22:07 GMT

I have been trying to use the tree widget example from Doug Young's Book,
and I've found something that baffles me.  
When I reassign a child widget's super-node, the tree widget redisplays itself,
showing the new hierarchy of widgets, but the lines drawn to connect the
widgets are to the old positions of the widget.
When XtMoveWidget is called, the new coordinates are assigned to the
widget, but later, when the expose method is called, the child widgets have
their old coordinates.
Am I missing something in widget programming? or is there something that is
not complete in the tree widget? or is it just a bug?

Newsgroups: comp.windows.x.motif
From: m086414@pwa-b.uucp (Fred Comins)
Subject: Openwindows 3 with Motif and xdm
Organization: Pratt & Whitney Aircraft
Date: Fri, 31 Jul 1992 20:00:59 GMT

We are trying to run xdm within our Openwindows3/Motif
environment and not having lots of luck.  I am looking
for sample xdm-config files, scripts.   Do people
usually have Motif up first??

Our 2 main problems are:
 1 We have to build motif menus on the fly in order to have
   user options and a standard menu.  ie:
   /pw/prod/sun4/motif/bin/mwm -xrm "*configFile: $HOME/.current_motif_menu" &

 2 Many users have tablets instead of mouses so at normal login
   we prompt for pointer device and they pick mouse or tablet.
   then we might set
   setenv PTR_DEVICE /dev/tablet
   Then starting openwindows, the tablet is used.  I think this
   might be an undocumented openwindows feature.
   I don't know how to do this with xdm.

-- 
Fred S. Comins				 Pratt & Whitney Aircraft
Email: uunet!pwa-b!m086414   	         400 Main St. M/S 161-05
Sun Workstation Support                  East Hartford, CT 06108
From: rmauri@netcom.com (Richard Mauri)
Newsgroups: comp.windows.x.motif
Subject: Re: Help! Virtual mwm?
Date: 22 Jul 92 14:12:00 GMT
Organization: Netcom - Online Communication Services  (408 241-9760 guest)

In article <1992Jul21.030646.182721@cs.cmu.edu> houghton+@cs.cmu.edu (Ricky Houghton) writes:
>In article <LARRY.92Jul20122949@boris.webo.dg.com> larry@boris.webo.dg.com (Larry Rogers) writes:
>>
>>Here are the answers regarding the virtual window manager:
>>
>>1.  There is NOT one available free to anyone from anyone.
>>
>
>
>  Well, maybe not a virtual window manager, but there's something
>called vr by Richard Mauri that I got and compiled on several
>of our local machines.  Virtual rooms, vr allows upto 6 rooms.  
>It's rather nice and free.
>
>  I believe it was posted to export, but I'm not sure.  Richard's login
>is rmauri@netcom.com.
>
>  Ricky
>  houghton@cs.cmu.edu

Hello this is me (Rich Mauri). Yes vr is on export. version 1.1 allows
any number of rooms (not just six). I have been reluctant to participate
in the thread for the desperate hunt for a virtual mwm because I do not
consider it such. It does provide screen real-estate management that
effectively allows "virtual screens" but nothing like a viewport onto
a larger virtual screen. (This virtual screen stuff needs better definition
I agree). Anyway, try it, hack at it, send me your patches to 1.1 by Aug 15
and I may incorporate them into 1.2 which already allows you to migrate windows
between rooms and some minot bug fixes.

Rich
-- 
Richard Mauri               // Not ready to face the winter.
SW Eng / X hack             // Pray for wind.
Trimble Navigation Ltd.     // Pay the bills.
rmauri@netcom.com	    // Hope nothing breaks
From: drand@spinner.osf.org (Douglas Rand)
Subject: Re: Help with CascadeButton translations
Organization: Open Software Foundation
Date: 21 Jul 92 13:53:45

In article <1992Jul20.214746.7146@murdoch.acc.Virginia.EDU> rlb7h@rlbsun.ee.Virginia.EDU (Robert L. Blackburn) writes:

   ...

   The first case would be handier if there were already an appropriate action
   (<name1>), but I have not been able to determine what that action is.  (I have
   tried "Activate", "activate", "BtnUp", and a few others for <name1>.  In every
   case, I get a runtime message, e.g., 
	   "X Toolkit Warning: Actions not found: BtnUp"
   when the menu/button is constructed.  When <event> occurs, the menu goes away
   but my callbacks are not activated.)

I'm not answering via email.  This is all stuff that is of interest
to general Motif and X Intrinsics programming folks.

The event name is <BtnUp>,  the action is Activate.  The syntax is
"<BtnUp>: Activate()" which tells the translation manager to run 
the Activate action on the BtnUp event (any button up,  any modifiers).

The actions are documented per widget  (see XmCascadeButton, etc in 
the OSF/Motif Programmer's Reference).

Now Cascade has no Activate() action,  it's parent Label has no 
Activate() action and Primitive has no Activate() action.  Therefore
you get the warning.

As a last thing.  I strongly recommend that you reconsider what 
you're doing.  As someone with some familiarity with the menu code,
I can tell you that you're going to regret this.  Really regret it.



--
Douglas S. Rand <drand@osf.org>		OSF/Motif Dev.
Snail:         11 Cambridge Center,  Cambridge,  MA  02142
Disclaimer:    I don't know if OSF agrees with me... let's vote on it.
Amateur Radio: KC1KJ
Newsgroups: comp.windows.x.motif
From: sandys@ruby.aruba.UUCP (Sandy Schindler)
Subject: Re: placing a dialog exactly where I want it
Date: Fri, 24 Jul 1992 12:35:30 GMT
Organization: Project Zed

The way I got this to work was to do an XtTranslateCoordinates and *then* set
the XmNx and XmNy coordinates (since this is a shell, its coords are not
interpreted relative to its parent widget, but relative to the root window of
the display).

To prevent motif from overriding my specified coordinates, I also set the 
XmNdefaultPosition to False for the dialog.

-- 
Sandy Schindler                      |Internet Style: aruba!sandys@uu2.psi.com
Systems Programming/UI, Project Zed  |UUCP : ...!uunet!uu2.psi.com!aruba!sandys
Newsgroups: comp.windows.x.motif
From: sandys@ruby.aruba.UUCP (Sandy Schindler)
Subject: Re: placing a dialog exactly where I want it
Date: Tue, 21 Jul 1992 16:41:46 GMT
Organization: Project Zed
Keywords: dialog coordinates

The resource I needed to set is XmNdefaultPosition, False.  Everything else
was ready to go.

Thanks go to the FAQ, which set this resource in the Heller example.  Also, 
thanks to nazgul@alfalfa.com (Kee Hinckley) for a code sample.

-- 
Sandy Schindler                      |Internet Style: aruba!sandys@uu2.psi.com
Systems Programming/UI, Project Zed  |UUCP : ...!uunet!uu2.psi.com!aruba!sandys
From: kulla@casee.enet.dec.com (Marc Kulla)
Newsgroups: comp.windows.x.motif
Subject: XmOptionMenu items
Keywords: XmOptionMenu
Date: 23 Jul 92 14:25:20 GMT
Reply-To: kulla@casee.enet.dec.com (Marc Kulla)
Organization: Digital Equipment Corporation

Does anyone know how to insert a new item into an XmOptionMenu in a 
particular location (namely 1st)?  I can add new items by creating more
pushbuttons with the subMenuId as the parent.  That works fine.  The item
appears at the end of the list!  Now I need to insert an item at the top of the 
list and I have no idea how to do it.  Any suggestions?

Thanks.

Marc
----------------------------------------------------------
Marc Kulla               e-mail: kulla@casee.enet.dec.com
Pande SA
Sophia Antipolis  France
----------------------------------------------------------
Newsgroups: comp.windows.x.motif
From: sscott@rtsg.mot.com (Steven R Scott)
Subject: X11R5 server on HP 425T under HP/UX 8.0?
Organization: Motorola Inc., Cellular Infrastructure Group
Date: Thu, 23 Jul 1992 22:01:35 GMT



I have gotten the MIT X11R5 sources and have built them.

Unfortunately, my hw/sw (HP/UX 8.0 running on a 425T) is not supported
as a R5 server.  Therefore, I need to know:

Has (is) anybody working on making the required changes to that the
425T under 8.0 can be supported as an R5 server?

Does anybody know when HP might have R5 support built in?

Thanks for your help.

P.S.  Please respond via email to sscott@mot.com.  I will summarize and
post if I get enough responses


Newsgroups: comp.windows.x.motif,comp.windows.x
From: ericr@ssd.intel.com (Eric Richards)
Subject: Re: Using xwd to dump menus
Organization: Supercomputer Systems Divison, Intel Corp.
Distribution: usa
Date: Thu, 30 Jul 1992 00:32:36 GMT

What I do to snap menus is the following:


sleep 5;xsnap -r "400x400+0+0"

Then select the menu and wait a few seconds.  When you're
done with the menu, xsnap should pop up a window containing
a snap of the region starting at 0,0 being 400x400 wide.
Now, if this doesn't contain the correct region, modify the
geometry string after the -r.  Once it contains the menu,
do the following:

xsnap

Now you can select from the menu snap.  This way, you can
select just exactly what you want.  So, the first snap,
with region, is a shotgun approach to get everything.  The
second snap is surgery to get the menu.

xsnap should be on export if you don't already have it.
Very nice program.


ejr
From: d8guspe@dtek.chalmers.se (Peter Gustavsson)
Newsgroups: comp.windows.x.motif
Subject: drawingarea shrinks in scrolled window
Date: 24 Jul 92 15:31:43 GMT
Organization: Chalmers University of Technology


I have a problem with a scrolled window. In my scrolled window I
have put a drawing area as a child, and in this drawing area I have
put a pixmap, using XmNbackgroundPixmap.

Now, if I don't place any pushbuttons in my drawingarea, everything is OK.
But if do, the drawingarea shrinks so that most of the pixmap vanishes. 
The problem is that I want to be able to see all of the drawingarea, not just
the part where the pushbuttons are placed.

I better clarify:

If I place a pushbutton in the left corner, like this, everything
is fine, the drawing area doesn't shrink.

 ------------------------------------------------
 |						|
 |						|
 |						|
 |						|
 |						|
 |						|
 |						|
 |				            PB  |
 ------------------------------------------------


But if I place a pushbutton like this, the drawing area shrinks to the size
of the ****'s.

 ------------------------------------------------
 |			  *			|
 |			  *			|
 |			  *			|
 |			PB*			|
 |*************************			|
 |						|
 |						|
 |				                |
 ------------------------------------------------

I have tried to set the resource XmNworkwindow using :

XtVaSetValues(scrolledwindow, XmNworkWindow, drawingarea);

I have set the size of the drawingarea (XmNwidth, XmNheight).

WHY DOES THIS HAPPEN, AND HOW DO I PREVENT IT ???



Thanks in advance

-----------------------------------------------------------------
Peter Gustavsson
email: d8guspe@dtek.chalmers.se

Chalmers University of Technology, Gothenburg, Sweden
-----------------------------------------------------------------
Newsgroups: comp.windows.x.motif
From: vincent@cadillac.cray.com (Vincent LE BARAZER)
Subject: PopDown with XmNactivateCallback
Originator: vincent@cadillac
Organization: Cray Research, Inc.
Date: 28 Jul 92 10:41:15 CDT



 I don't understand why clicking in a PushButton Widget contained in a
Dialog Shell always pops it down, without calling XtPopDown, or XtUnmanageChild.

 Here is the structure of my Widget tree :

	dshell = XtVaCreatePopupShell (NULL,xmDialogShellWidgetClass, ...)

	form = XtCreateWidget(NULL,xmFormWidgetClass, ...)

	pushB = XmCreatePushButtonGadget( form, ...)
	XtAddCallback(pushB,XmNactivateCallback, mycb,0);
	XtManageChild(pushB);

	XtManageChild(form);

	XtPopup(dshell,XtGrabNone);

 And when clicking on pushB, mycb is called ... and dshell is poped down 
automatically. 

 How can I avoid dshell to be poped down ???

 Many thanks in advance,

 Vincent Le Barazer
 Cray Research France
 Email : vincent@cray.com
From: sennett@sol.UUCP (Michael Sennett)
Newsgroups: comp.windows.x.motif
Subject: Focus problems running Motif app under OpenWindows
Keywords: focus, Motif, olwm, click-to-type
Date: 27 Jul 92 18:23:00 GMT
Organization: Vista Technologies, Inc. Schaumburg, IL 60173 USA

One of our Motif applications needs to run under OpenWindows. For the most
part, it seems to work, but it has a problems when click-to-type is being
used.  The symptons of the problem are that sometimes when a modal question 
dialog is popped up, the focus can't be shifted to the dialog box. 
In fact the focus cannot be shifted at all, so the user is stuck.
(Although I have been able to pop the dialog box down using F1 (but I'm not
sure what F1 is under OpenWindows)).  A similar problem occurs when our app
starts up an editor.  The focus can't be shifted from our window to the new
window or any other window.

In my .Xdefaults, I have set `FocusLenience' and `*Input' to true.
The problem occurs more frequently in click-to-type mode, although one
person claims to have seen it in follow-mouse mode.

Any help on this question, or general advice on running Motif programs
under OpenWindows would be appreciated.

Thanks,

Mike Sennett
Vista Technologies, Inc.
sennett@vistatech.com
Newsgroups: comp.windows.x.motif
From: rpeck@pure.com (Ray Peck)
Subject: Re: What is "Purify" ? (Ostriches)
Organization: Pure Software, Los Altos, CA
Date: Tue, 28 Jul 1992 22:47:04 GMT

In article <4600@balrog.ctron.com> Larry Smith writes:
>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.
>-------------------------------------------------------------

I'd like to pursue this, since we have not had a report of missing
memory leaks in six months.

Purify will not report on memory chunks which are in use at program
exit, because these chunks are not leaks.

Malloc-debug packages will tell you about *all* the things you've
malloc'ed but not freed.  But they won't distinguish between things
that you have in use (have references to) and those you've lost
reference to like Purify will.

char *sym_table;

main()
{
  sym_table = malloc(10000);
}

will be reported by a malloc-debug package even though you (correctly)
retain a reference to the chunk at exit().  You have to look at all
the malloc-debug output, and figure out (manually) which chunks should
and which should not have been freed (i.e., which are leaks, and which
are permanently allocated memory).

By default, Purify tells you only about those malloc chunks to which
you have no references, so you don't have to sort out which ones are
permanently allocated memory.

It does this by using a conservative garbage-detection algorithm (mark
and sweep) similar to garbage collectors used in lisp, Smalltalk, et.
al.  This robust technology has been around since the first lisp
interpreter in the 50s.



If you want Purify to tell you about all "outstanding mallocs" in the
way that malloc_debug packages do, you can use the purify_allallocated()
routine (instead of purify_newleaks() or purify_allleaks()).



-- 
Ray Peck						rpeck@pure.com
Pure Software						415-903-5100
2111 Grant Road
Los Altos, CA, 94024
From: ilise@ssvax.gte.com (Ilise Landesberg)
Newsgroups: comp.windows.x.motif
Subject: Key Translations - (Email wrong in prev post)
Date: 30 Jul 92 18:37:02 GMT
Organization: GTE/SCSD


   SORRY FOR THE RE-POST - THERE WAS A PROBLEM WITH THE Email ADRESS
   IN THE FIRST POST.

How can I make a return key act like a tab key?  I would like the return
and tab key to be interchangeable as far as the user is concerned.

After being unable to change this for my whole application or
toplevel window I started changing it widget by widget.

I was able to do this for text widgets by using the translations
resource.

         ie:  In .Xdefaults file

              *text_widget.translations: #override \
                          <Key>Return : process-tab()

But I was unable to do this for toggle widgets. The toggle widget does
not recognize the action process-tab.  I have been unsuccessful in
figuring out what action it uses when I press tab.

Thanks,
Ilise
From: nazgul@alfalfa.com (Kee Hinckley)
Newsgroups: comp.windows.x.motif
Subject: Re: Xmlist code for you to compile and run.
Date: 21 Jul 92 19:42:31 GMT
Distribution: inet
Organization: The Internet

> The problem is that when I select any item in the list, it highlights this
> item while mouse and button are pressed on it and then when you let go
> it goes through the callback routine, uses the Replace routine and then
> commences to highlight all items in the new list which match the one 
> that was selected.  Thus any item you pick that matches items in the list
I fixed this in my version of Motif - only to be told by OSF that it wasn't
bug.  The logic in list assumes that any item with the same name is the
"same" item.  You'll have to try and work around it.

> I have come up with a temporary fix to this behaviour to put in the List.c
There's a one line change I think that makes it work, but it's a feature,
so...

nazgul@alfalfa.com
617/646-7703 voice/fax

If Unix is the answer, then we've clearly forgotten the question.
From: mike@inform.co.nz (Mike Williams)
Newsgroups: comp.windows.x.motif
Subject: Motif button-boxes
Date: 30 Jul 92 22:59:40 GMT
Distribution: comp
Organization: InForm Group, Wellington, New Zealand.


  Has anyone found a better way to handle button-boxes than the XmForm or
  XmRowColumn widgets.  I like the way the XmSelectionBox widget handles
  it's button layout (especially with resizing), but can't work out how to
  duplicate this behaviour for a custom dialog-box.

  Please email if you have any suggestions.  Thanks.

    ------------------------------------------------------------------
        Mike Williams, InForm Group Ltd., Wellington, New Zealand.
   Email: mike@inform.co.nz   Phone: 64 4 472 0996   Fax: 64 4 473 2407