HDTenEightyP/NetNews huggingface dataset:
From: feats@feats.cc.vt.edu feats@vtvm1.cc.vt.edu
Newsgroups: comp.windows.x
Subject: Learning X-windows
Date: 30 Dec 92 12:52:02 GMT
Distribution: usa
Organization: Virginia Tech, Blacksburg, VA

I have a RS/6000 POWERstation 220 running AIX 3.2.  I am interested             
in learning about AIXwindows and how to write a 'C' application that            
uses the X-windows environment.  As of right now I don't have access            
to any of the IBM manuals that cover this topic in depth.  I do feel            
that the IBM manuals are not the best ones to learn from but they do            
make good references.                                                           
                                                                                
Can anyone suggest any good books on X-windows programming in 'C'?              
I don't know if just any X-windows programming book will do or if I             
need one that specifically covers AIXwindows!                                   
                                                                                
I would also be interested in some small programming samples of                 
X-windows applications.  Are there any FTP sites that would have                
any coding samples or would any of you have any samples you would               
like to share.  I am talking small and simple examples because I                
know very little about 'C' and almost nothing about X-windows!                  
                                                                                
Thanks in advance!                                                              
                                                                                
                                                                                
Stephen L. Greenfield                     Bitnet:   FEATS@VTVM1                 
Virginia Polytechnic Institute   ,/\      Internet: feats@feats.cc.vt.edu       
Blacksburg, Virginia           ,/   `\/`'\                                      
                           ,/\/          /                                      
                         ,/             <_          ._.                         
                        /                 `\       / /                          
             ,/\_     _/'                   `-`-\  |/                           
          ,/'    `_'_'  *  Blacksburg          \_> '                            
       ,/'                                    \__>_/\                           
      +----------------------------------------------+                          
Newsgroups: comp.windows.x
From: john@pluto.Jpl.Nasa.Gov (John R Veregge)
Subject: Xt and CPU usage
Reply-To: john@pluto.Jpl.Nasa.Gov
Organization: Jet Propulsion Laboratory, Pasadena CA
Date: Tue, 29 Dec 1992 04:41:04 GMT

We have developed several large Motif applications that are complete CPU
hogs and I don't know why.

Each application has 300 to 500 XtCreateWidget() and 8 XtAppCreateShell()
calls. These calls are all made before XtAppMainLoop() is called. Widgets
are not destroyed until the application exits.

Each application is driven by both the GUI and serialized data using
XtInputCallbackProc's.

We run 2 to 4 application on a workstation.

2 applications will put CPU usage of a Sparc 2 at 97%, even when
completely idle with no serialized data input and no X events (GUI input).

Can anyone tell me (1) Why? and (2) How can I fix (optimize) this?
______________________________

John R Veregge
Jet Propulsion Laboratory
Calif Institute of Technology
john@pluto.triton.jpl.nasa.gov
Newsgroups: comp.windows.x
From: leisner@wrc.xerox.com ( Marty Leisner)
Subject: playing with window managers
Reply-To: leisner@eso.mc.xerox.com
Organization: Xerox
X-Newsreader: TIN [version 1.1 PL8]
Date: Mon, 28 Dec 1992 02:59:16 GMT


I normally exec a window manager at the end of my .xinitrc...

But how do I easily select different window managers to try out 
(I'm talking about twm, vtwm, tvtwm, and ctwm?)

Another apporach is to have a xterm window and the end of the .xinitrc, and
exiting this window will kill X -- but this I find kludgy..

Should I just kill the X server on my server and everything will die?



--
marty
leisner.henr801c@xerox.com  leisner@eso.mc.xerox.com
Member of the League for Programming Freedom
Newsgroups: comp.windows.x
From: ori@marvin.technion.ac.il (Ori Degani)
Subject: Re: tvtwm - cannot link
Organization: Heart of Gold Institute
Date: Thu, 31 Dec 1992 01:50:20 GMT

Luca Priorelli (luca@dedalo.unipg.it) wrote:
: I am trying to compile tvtwm on a SPARCstation with Solaris 1.0.1.
: I am using the X files in the openwin distribution (should be X 11.4).

: The compilation is done right but when I link I get the following undefined
: symbols:
: _pow
: _floor
: _get_wmShellWidgetClass
: _get_applicationSHellWidgetClass
: __XtInherit
: _XtToolkitInitialize

: The libraries specified in the Imakefile are:
: 	-lXmu -lXext -lX11

: to these I have added:
: 	-lXt

: It seems I still have to add something. Any hints?

1) the order matters in the libs:  Xt must precede X11
2) seems like you need -lm (math)
: Thamk you.

: Luca Priorelli

--
   |  ----      Ori Degani
   |  |___      ori@eddie.technion.ac.il   (Ship Computer on the HOG)
   |  |         ori@marvin.technion.ac.il  (Who else) 
   |  ----      s2973229@techst02.technion.ac.il (Ech..)   
Newsgroups: comp.windows.x
From: koverber@cs.ulowell.edu (Kurt Overberg)
Subject: What is Xremote?
Originator: koverber@bigmax.ulowell.edu
Organization: University of Massachusetts at Lowell Computer Science
Date: Wed, 30 Dec 1992 15:26:47 GMT



I saw someone post something about a program called 
Xremote?  It sounds interesting, what is it?  Could it
be a way to dial into my machine at work and set my 
display to my 486 at home?!  Wow! That would be 
great!  Thanks...  :)



				peace out.

				    kurt

-- 
Kurt Overberg            | I honestly doubt you care about my opinions ;^)      
U of Mass, Lowell        | "Poke a double-decker on a Llama taboot,       
koverber@cs.ulowell.edu  |  Llama taboot, taboot!"      -Phish
Newsgroups: comp.windows.x,comp.windows.x.motif
From: daver@cbnewsj.cb.att.com (dave.robertson)
Subject: Help Request for mwm send.msg
Organization: AT&T
Date: Tue, 22 Dec 1992 13:41:47 GMT
Followup-To: comp.windows.x
Keywords: Motif, mwm, send.msg, XChangeProperty, Atom


I tried posting this last week, but received no response or suggestions
from the motif newsgroup, and so I am re-posting and also cross-posting
to comp.windows.x .........

I am having problems trying to use the send_msg function in mwm.
I need to add an application specific capability to each window
manager menu, and I believe that this can be achieved in this manner.

Firstly in my mwm configuration file I define the menu as follows : 

Menu DefaultWindowMenu MwmWindowMenu
{
    MyFunc              f.send_msg 123
    Restore             f.normalize
    Minimize            f.minimize
    Maximize            f.maximize
    Lower               f.lower
    no-label            f.separator
    Close               f.kill
}

where MyFunc is my application specific capability.
On startup, I do the following:

Atom	wm_motif_messages;

wm_motif_messages = XInternAtom(dpy, "_MOTIF_WM_MESSAGES", FALSE);

Then, when windows are created:

static	int	helpmsg = 123;

XChangeProperty(dpy, win, wm_motif_messages, XA_INTEGER, 32,
                PropModeReplace, (unsigned char *) &helpmsg, 1);

I then check for the appropriate ClientMessage event while the application
is running.

My problem is that MyFunc is always dimmed. What am I doing wrong?
I suspect that my XChangeProperty() call may be at fault and I have
tried a few variations on the above. If I run xprop on one of my windows
then it appears that the message number 123 has been correctly registered
with the _MOTIF_WM_MESSAGES property.

One further point, I am not using the Motif toolkit but instead a 
proprietary Xlib based class library. The principles ought to be the
same though.

If anyone has done this before and has code segments that they don't
mind sharing, or any suggestions, I'd really appreciate it.

Dave Robertson
Consultant				att!mtnms!dar
AT&T Paradyne
Middletown, NJ				(908) 957 3925

// "All I want for Christmas is for my send.msg to work!"
From: mouse@thunder.mcrcim.mcgill.edu (der Mouse)
Newsgroups: comp.windows.x
Subject: Re: X protocol
Date: 23 Dec 92 16:40:12 GMT
Organization: McGill Research Centre for Intelligent Machines

> Distribution: comp

Please don't misuse newsgroup hierarchy names as distributions.

In article <LAH.92Dec22111915@genesis.unh.edu>, lah@unh.edu (Lance A. Hartford) writes:

> I am looking into writing a protocol decoder for the X protocol.  I
> don't know much about X and I have no idea where to look for
> information like this. Where should I look for protocol
> specifications?

mit/doc/Protocol on the R5 tape.  Of course, it's also available by
anonymous ftp from the R5untarred area on export.

					der Mouse

			    mouse@larry.mcrcim.mcgill.edu
From: tchal@tmchome.UUCP (Thomas M. Chalfant)
Newsgroups: comp.windows.x
Subject: Problems Compiling X11R4
Date: Thu, 31 Dec 92 23:12:11 EST
Distribution: world
Organization: My house

To all:

I posted a message the other day about having problems compiling X11R4 MIT
distribution.  I am still having problems and have not had any responses to
my message.  I realize this is the holiday season and not everyone is
reading messages, but can someone read back to my message and give me a hand?

Another interesting tidbit to add to the situation:  The man pages for the
ld linker say that directories listed with the -L option are searched before
the standard locations.  This does not seem to be the case, because running
ldd on some executables shows the standard location libraries listed and not
the ones from the newly compiled distribution.  Is this the case, or is this
a LD_LIBRARY_PATH kind of thing?  Will someone clear this up for me as well?

Thanks,
Tom
Newsgroups: comp.windows.x.intrinsics
From: ed.duomo@lambada.oit.unc.edu
Subject: X-fiendly sleep?
Organization: Massachvsetts Institvte of Technology
Date: Sun, 27 Dec 1992 05:53:53 GMT

I'm wondering if there exists any such thing as an X-friendly sleep,
i.e. sleep that would not grab the server. If I simply put sleep(2) in
a callback, events cannot be handled by the intrinsics during that
sleep, and if the window is exposed, it would not be updated until the
program return from the sleep function call.

What I want is a funtion that when called from a certain location of
the program with an argument of say 2 seconds, does not return from
that location until 2 seconds have passed, but in contrast to
sleep(2), those two seconds should not be spent idle, but in
XtAppMainLoop so that events could be properly handled during that
time. 

Any idea if something like this is available. If not, could it be
implemented by timeouts? How?

Thanks.

E.D.

Newsgroups: comp.windows.x.intrinsics
From: john@pluto.Jpl.Nasa.Gov (John R Veregge)
Subject: Xt and CPU usage
Reply-To: john@pluto.Jpl.Nasa.Gov
Organization: Jet Propulsion Laboratory, Pasadena CA
Date: Tue, 29 Dec 1992 04:49:57 GMT

We have developed several large Motif applications that are complete CPU
hogs and I don't know why.

Each application has 300 to 500 XtCreateWidget() and 8 XtAppCreateShell()
calls. These calls are all made before XtAppMainLoop() is called. Widgets
are not destroyed until the application exits.

Each application is driven by both the GUI and serialized data using
XtInputCallbackProc's.

We run 2 to 4 application on a workstation.

2 applications will put CPU usage of a Sparc 2 at 97%, even when
completely idle with no serialized data input and no X events (GUI input),
using X11R4, on Sun Sparc 2's with 32+ megs of memory and 20+ megs of swap.

Can anyone tell me (1) Why? and (2) How can I fix (optimize) this?
______________________________

John R Veregge
Jet Propulsion Laboratory
Calif Institute of Technology
john@pluto.triton.jpl.nasa.gov
Newsgroups: comp.windows.x.intrinsics
From: qualtrak@netcom.com (Qual Trak)
Subject: Re: Xt and CPU usage
Organization: QualTrak Corporation
Date: Wed, 30 Dec 1992 05:19:35 GMT

In article <1992Dec29.044957.19576@llyene.jpl.nasa.gov> john@pluto.Jpl.Nasa.Gov writes:
>We have developed several large Motif applications that are complete CPU
>hogs and I don't know why.
>
>Each application has 300 to 500 XtCreateWidget() and 8 XtAppCreateShell()
>calls. These calls are all made before XtAppMainLoop() is called. Widgets
>are not destroyed until the application exits.
>
>Each application is driven by both the GUI and serialized data using
>XtInputCallbackProc's.
>
>We run 2 to 4 application on a workstation.
>
>2 applications will put CPU usage of a Sparc 2 at 97%, even when
>completely idle with no serialized data input and no X events (GUI input),
>using X11R4, on Sun Sparc 2's with 32+ megs of memory and 20+ megs of swap.
>
>Can anyone tell me (1) Why? and (2) How can I fix (optimize) this?
>______________________________
>
>John R Veregge
>Jet Propulsion Laboratory
>Calif Institute of Technology
>john@pluto.triton.jpl.nasa.gov

I seem to remember having a program returning zero length reads on a
file associated with a tty when I had added a reader proc with the
XtAppAddInput () function.  The result was that the reader proc was
being called each time through the XtAppMainLoop ().  Something like
this could be chewing up your CPU.
-----                                                              -----
John Birchfield - QualTrak Corp (408) 730-2674 Home (408) 736-3852
jb@QualTrak.COM
-----                                                              -----
Newsgroups: comp.windows.x.intrinsics
From: witr@rwwa.COM (Robert Withrow)
Subject: Re: Wanted: table widget
Keywords: table widget for athena
Reply-To: witr@rwwa.com
Organization: R.W. Withrow Associates
Distribution: usa
Date: Tue, 22 Dec 1992 16:18:21 GMT

In article <1992Dec21.141258.1305@Informatik.TU-Muenchen.DE>, schreibs@Informatik.TU-Muenchen.DE (Siegfried Schreiber) writes:
| I' am looking forward for a flexible composite Athena 
| compatible widget, which allows to arrange other
| widgets in a table

Use the Table widget in WCL.  Get WCL from an archive near you, or 
see archie.

-- 
 Robert Withrow, Tel: +1 617 598 4480, Fax: +1 617 598 4430, Net: witr@rwwa.COM
 R.W. Withrow Associates, 21 Railroad Ave, Swampscott MA 01907-1821 USA
Newsgroups: comp.windows.x.intrinsics
From: wyser@ubilab.ubs.ch (Wyser Martin GLA1-WTY)
Subject: Re: Wanted: table widget
Organization: UBS Informatics Laboratory
X-Newsreader: TIN [version 1.1 PL6]
Date: Tue, 22 Dec 1992 15:52:10 GMT

You should look at the Widget Creation Library (WCL), available at your
favorite ftp-source. Supplied with it is a table widget in Motif, Athena
and OpenLook versions. It is a basically a constraint widget, and causes
less layouting pain than eg. the Motif form widget.
WCL interprets the resource database to build widget trees. It was
contributed by Martin Brunecky and David E. Smyth. The Table widget was
originally contributed by David Harrison.

bye
Martin Wyser, wyser@ubilab.ubs.ch
Newsgroups: comp.windows.x.intrinsics
From: converse@expo.lcs.mit.edu (Donna Converse)
Subject: Re: core dump with Form widget
Keywords: Form widget, XtDestroyWidget
Organization: X Consortium, MIT Laboratory for Computer Science
Date: Wed, 30 Dec 1992 22:07:10 GMT


> Our system is: SunOS 4.1.1, X11R4 on sun4c
> 
> We have got a menu with callbacks poping up Popup-Shells. These Shells contain
> a Form-widget, which in turn contains some labels, buttons, a scrollbar and a 
> list widget. 
> After leaving the popup, we use XtDestroyWidget on the popup-shell widget. 
> Next time a menu item is selected, all widgets (including the popup shell) 
> are created once again.
> So far, so good ! It works well for the first time, perhaps for the second, too
> but then we receive a "Segmentation fault (core dumped)" or a Bus error.


Fixed in R5.

------- Forwarded Message

Date: 12 Apr 91 13:13:34 GMT
From: rod@scooter.rosemount.com (Rodney Drenth)
Organization: Rosemount Industrial
Subject: Error: XmuCvtStringToWidget
To: xpert@expo.lcs.mit.edu

An error exists in the way the String to Widget Conversion routine is
registered with the resource converter in the Athena Form WIdget.
The resource converter should not cache conversions, but does. Under
certain circumstances it will cause sporatic bus errors and segmentation
faults. 

The problem affects the fromVert and fromHoriz resources in the Athena
Form widget.  If these are specified in a resource file (not in a program)
and if the form widget and its children can be destroyed and re-created, it is
possible for the widget ID of the form widget to stay the same but the
Widget ID's of the children to be different.  When this occurs, and
because the Name To Widget conversion is cached, the resource conversion
returns incorrect values, which cause segmentation faults and core dumps.

The problem can be corrected by either not specifying the fromHoriz and
fromVert resources in resource files, or by making a copy of the 
XmuCvtStringToWidget function, modifying it so that it is a new type
resource converter, and changing the ClassInitialize function in the
Athena Form Widget to install your revised StringToWidget function with
XtCacheNone specified.

Rodney Drenth

------- End of Forwarded Message


Donna Converse
MIT X Consortium
Xref: sparky comp.windows.x.intrinsics:686 comp.windows.x.motif:8191
From: lusardi@sybil.cs.Buffalo.EDU (Christopher Lusardi)
Newsgroups: comp.windows.x.intrinsics,comp.windows.x.motif
Subject: Creating an Image and Saving It to a File?
Date: 23 Dec 92 12:12:28 GMT
Organization: State University of New York at Buffalo/Comp Sci
Originator: lusardi@sybil.cs.Buffalo.EDU

I want to learn X! I want to use it to create a simple image with circles, 
rectangles et cetera and save the image to a file in my directory. (I also 
want to do some image processing with it.) How can I get X to create and 
save images to a file?

The answer could be any of:

	(1)X programs that create and save simple images to files.

	(2)I have the book: The X Window System Programming & Applications with
	   Xt by John Young, and John Pew. 

	   Are there any good image processing books that explain to me how 
 	   to do this with X?

	(3)I have all the application programs in (2) on-line. Are there any
	   good ftp sites with simple imaging programs like this?

						Thanks,
-- 
Christopher M. Lusardi     University At Buffalo  lusardi@sybil.cs.buffalo.edu
From: qizeng@acsu.buffalo.edu (Qi Y. Zeng)
Newsgroups: comp.windows.x.intrinsics
Subject: where to look for Xw
Date: 30 Dec 92 16:53:06 GMT
Organization: UB

Dear Netters:
    From Douglass Young's book we know that we can ftp

        Xw.patch.works.tar.Z

from export.lcs.mit.edu.

    However I tried and could not find it there.

    If any person knows where can I find those wedgets used in

young's book, could you tell me? Thank you!! 
Newsgroups: comp.windows.x.intrinsics
From: gregc@eagle.fsl.noaa.gov (Greg Compestine)
Subject: Re: Xt and CPU usage
Organization: Forecast Systems Lab, NOAA - Boulder CO, USA
Date: Tue, 29 Dec 1992 23:07:37 GMT

john@pluto.Jpl.Nasa.Gov (John R Veregge) writes:

>We have developed several large Motif applications that are complete CPU
>hogs and I don't know why.

>Each application has 300 to 500 XtCreateWidget() and 8 XtAppCreateShell()
>calls. These calls are all made before XtAppMainLoop() is called. Widgets
>are not destroyed until the application exits.

>Each application is driven by both the GUI and serialized data using
>XtInputCallbackProc's.

>We run 2 to 4 application on a workstation.

>2 applications will put CPU usage of a Sparc 2 at 97%, even when
>completely idle with no serialized data input and no X events (GUI input),
>using X11R4, on Sun Sparc 2's with 32+ megs of memory and 20+ megs of swap.

>Can anyone tell me (1) Why? and (2) How can I fix (optimize) this?

    Since the performance on a Sparc 2 is "reasonable", you could greatly
reduce the startup cost and runtime size of your app by only creating widgets 
and shells when needed.  Unfortunately, this may mean a substantial rewrite of 
your application.

   As for your CPU being so busy, I have not a clue.  First, are you
sure your app is in XtAppMainLoop when usage is so high?  How are you
measuring usage?  If you are running "ps", it may take some time (several
minutes) before the usage numbers stabilize.  Running a perfmeter may
give you a little better feedback.

Greg
From: taylor@foraker.NoSubdomain.NoDomain (Eric Taylor)
Newsgroups: comp.windows.x.intrinsics
Subject: Re: How to change a window title dynamically ?
Keywords: title, motif
Date: 23 Dec 92 03:10:07 GMT
Distribution: comp

In article <FAJNER.92Dec14132821@ramses.frlv.bull.fr>, fajner@frlv.bull.fr (Alain.Fajner) writes:
|> 
|> I'm using OSF/Motif and I have a problem...
|> 
|> I am looking for the way to change the title of a Shell Widget once it has
|> been managed. This doesn't work at all :
|> 
|> 	XtSetArg(args[0], XmNtitle, xs);
|> 	XtSetValues(ShellWin, args, 1);
|> 

Are you REALLY working with the shell widget or its child?
XmCreateBulletinBoardDialog or whatever does not return the
shell, but its child.  If you are calling XtManageChild
on ShellWin then this is the case.
Newsgroups: comp.windows.x.intrinsics
From: adelt@imada.ou.dk (Adel Shavandi)
Subject: Can't run XView applications without out of xxgdb ?!
Keywords: Only xxgdb can run my XView applications ?!
Organization: Dept. of Math. & Computer Science, Odense University, Denmark
Date: Sun, 3 Jan 1993 14:09:01 GMT



I am a linux user with XFree86 version 1.1 and XView version 3.0L2. I have 
written a very simple XView application which runs with no problems under
SUN-OS4 with XView3.0 and now I would like to port it to linux.  
 
After having done all work required for compiling and linking a Xview 
application, when I tried to start it from my xterm window, the program 
did nothing! Then I tried to run it from xxgdb version 4.6 and the program 
runs without no problems, but after the following message appears in the
window of xxgdb: 
 
        [ioctl TIOCSPGRP failed in terminal-inferior: Not a typewriter] 
 
What is this message supposed to mean, and how can I correct this problem? 
I guess this is why I can't run my application without xxgdb. Is it true? 
 
 
I will really appraciate any kind of hints/help. 
 
 
 
 
                        Thanks in advance and 
                                happy new year, 
 
                                        Ade'l
From: taylor@tivoli.com (Eric Taylor)
Newsgroups: comp.windows.x.intrinsics
Subject: XmForm problems
Date: 23 Dec 92 03:13:46 GMT

Has anyone had any problems with attaching both
edges of a child in a form?

I looked at the code in XmForm and in CalcEdgeValues
CalcEdgeValue( on the left edge) depends on the
"value" of the righ edge before it has been calculated.

Does this sound familiar to anyone?

On the Sun this seemd to work fine, but bombed on the HP
we think because the memory was not "zeroed" out.
Newsgroups: comp.windows.x.intrinsics