HDTenEightyP/NetNews huggingface dataset:
From: ware@oboe.cis.ohio-state.edu (Peter Ware)
Subject: Re: using float data types via resources?
Originator: ware@oboe.cis.ohio-state.edu
Organization: Ohio State Computer Science
	<1992Nov9.174547.17618@constellation.ecn.uoknor.edu>
Date: Tue, 10 Nov 1992 14:37:52 GMT

In article <1992Nov9.174547.17618@constellation.ecn.uoknor.edu>
dwight@geohub.gcn.uoknor.edu (Dwight D. Moore) writes:

   What about passing a pointer to a float? That seems simple enough.
   I use this technique when passing a structure of data to a widget.

The intrinsics are clever and when they see that the size of the data
type is > sizeof(XtArgVal) they assume the data is passed by reference
(ie. the address); othewise the intrinsics assume it is the actual
value and copy it directly into the resource.  Typically, most
structures are larger then an XtArgVal and so passing in an address is
correct.

The problem with floats, as the FAQ mentions, is they are not larger
then an XtArgVal and so must be passed by value.  Unfortunately, C's
type conversion rules kick in when you assign to the arg.value field
and your floating point data is converterd to an integral value.

--pete
--
Pete Ware / Ohio State University /		228 Bolz Hall  (614) 292-7318
           ware@cis.ohio-state.edu		2036 Neil Ave.
           (h) (614) 538-0965			Columbus, OH 43210
Welcome William Patrick Ware to the world!  Born 10/21/92, 8lbs 6.2oz (3.83kg)
From: cs_nlg@lub001.lamar.edu
Newsgroups: comp.windows.x.intrinsics
Subject: XtMain or XtAppMain..Help!!
Date: 7 Nov 92 18:38:57 +1700
Organization: Lamar University - Beaumont

Hello!
	This may be a beginner's Question, still I could not find
the answer in the material I have.... Hence to the peers....
	What is the difference between XtMainLoop and XtAppMainLoop ?
Can I interchange.... What is the idea behind this App ?

	Thanks.

Raj.
From: brianw@ark.Eng.Sun.COM (Brian Warkentine)
Newsgroups: comp.windows.x.intrinsics
Subject: Re: >X calls in multi-threaded programs
Date: 9 Nov 1992 19:37:03 GMT
Organization: Sun Microsystems, Mt. View, Ca.
NNTP-Posting-Host: ark

In article <sturm.720698676@bloch> sturm@bloch.informatik.uni-kl.de (Peter Sturm) writes:
>At least Xlib is already prepared to be used in a multi-threaded
>environment. We've done that for our multi-threaded C++ runtime
>system.
>
>
>In Xlibos.h (contained in the Xlib sources), there are macros
 ...
>In the normal version of Xlib these macros evaluate to empty strings.
>But if you change these macros to calls to a semaphore or any other
>mechanism which gives you mutual exclusion, you'll gain a reentrant
>Xlib after compilation.
>
>That's all. After compilation everything works fine. 


	Are you sure?   There are some major portions of Xlib that are
	not "protected" by these macros.  What have you done to fix the
	context manager, the resource db, and error handling?  If
	you're using an R5 based Xlib, do you know of the problems in
	the I18N and Xcms code?

-brian
brian.warkentine@eng.sun.com

Newsgroups: comp.windows.x.intrinsics
From: afqwemi@cid.aes.doe.CA (Roger Bouffard)
Subject: Re: Double click in XmDrawingArea
Organization: Environment Canada (CID), Dorval, QC
Date: Mon, 9 Nov 92 15:17:22 GMT

In article <BxAu9F.LCB@ecmwf.co.uk> syj@ecmwf.co.uk (Jean-Philippe Martin-Flatin) writes:
(...stuff deledted...)
>Could you please elaborate on that "strange behaviour" ? I seem to have
>a similar problem: double-clicking on an icon, I would expect just the
>application to pop up. The application does pop up, but it also receives
>the last ButtonRelease event. And when my pointer happens to be above
>a gadget in a DrawingArea, this one gets activated (translations similar
>to above), and a callback gets called, etc...
(...more stuff deledted...)
>
>
>Any idea ? Can it be something wrong in the application itself ?
>
>Thanks in advance

 There is a ressource in mwm called passSelectButton 

 (the followoing is an excerpt from the man page)

passSelectButton (class PassSelectButton)
	This resource indicates whether or not to pass the select
	button press events to clients after they are used to do a
	window manager function in the client context.  If the
	resource value is False, then the button press will not be
	passed to the client.  If the value is True, the button press
	is passed to the client window.  The window manager function
	is done in either case.  The default value for this resource
	is True.

 Maybe that could be what is wrong.
From: paulw@praxis.co.uk (Paul Wand)
Newsgroups: comp.windows.x
Subject: OS2 PM to X port
Summary: Need advice on practicality of above.
Keywords: X, OS2, PM
Date: 11 Nov 92 15:52:29 GMT
Organization: Praxis, Bath, U.K.

I'm looking into the possibility of porting an OS2 Presentation
Manager application to run under X. The PM application is 
a fairly standard (but large) windows program; windows, 
pull-down menus, dialogue boxes and such like.
Do any of you X gurus out there also know enough 
about PM to answer questions like:

1. How similar are function calls in the two packages? Can they
   be mapped easily or would a large application require 
   major rewriting?

2. What would be the best X package to code the port under?
   My feeling is that since the application is a fairly 
   straightforward one, high level toolkits e.g. OSF MOTIF
   would be best. 

Please email advice/comments/rebuttals.

Thanks

Paul W.


-----------------------------------------------------------------------
Paul Wand               Praxis Systems plc, 20 Manvers St, Bath BA1 1PX
paulw@praxis.co.uk      Tel: +44 (0)225 444700
-- 

-----------------------------------------------------------------------
Paul Wand               Praxis Systems plc, 20 Manvers St, Bath BA1 1PX
paulw@praxis.co.uk      Tel: +44 (0)225 444700
Newsgroups: comp.windows.x
From: singg@alf.uib.no (Kurt George Gjerde)
Subject: Saving pixmap
Organization: University of Bergen, Norway
Date: Sat, 7 Nov 92 14:23:12 GMT

I use the following code to save a pixmap to file:


             if (!XWriteBitmapFile(dpy,name,pixmap,width,
                                  height,-1,-1) != BitmapSuccess)
                reportError(drawing_a,"Error saving drawing to '%s'.",tok[1],
                            NULL,NULL,NULL);


Are there any faster ways of doing this??

Kurt.
From: ROSSJI@js-jtf.af.MIL ("Jim Ross")
Newsgroups: comp.windows.x
Subject: RE: xsetroot for VMS/DecWindows
Date: 6 Nov 92 03:10:00 GMT
Organization: The Internet

#
#I look for program equivalent to xsetroot on X/Unix machine but for VMS runnin g 
#DecWindows. this program must be able to load standard bitmap files .
...
#Does anybody know where I could transfer such program from?
#
>Get XV from Public.TGV.COM under [.mahan].  It will allow you to set the
>root background using any image format (xbm, gif, jpeg, tiff, pbm, etc).
True, but if all you want is xsetroot it's available in the xutilities
directory on DecwMotif V1.1, as are many "standard" clients.

Jim Ross
Newsgroups: comp.windows.x
From: dan@moon.imp.ch (Daniel Mueller)
Subject: RGB->HSV/HSV->RGB conversion
Organization: ImproWare AG
Date: Wed, 4 Nov 1992 14:40:36 GMT



Hi there,


I want to write a conversion from rgb to hsv and hsv to rgb. Does anyone
know a book for background information or better a public domain source 
code from where i can get ne necessary informations?


Please answer me by e-mail, if possible: dan@imp.ch


				many thanks in advance

		

Newsgroups: comp.windows.x
From: cqyang@ponder.csci.unt.edu (Cui-Qing Yang)
Subject: Re: HELP: DECwindow font format
Organization: University of North Texas, Denton
Date: Fri, 6 Nov 1992 15:43:27 GMT

In article <1992Nov5.204651.7926@nntpd2.cxo.dec.com> jimw@empros.enet.dec.com writes:
>
>In article <1992Nov5.174341.12163@mercury.unt.edu>, cqyang@ponder.csci.unt.edu (Cui-Qing Yang) writes:
>
>|>I need to convert some of font files from the standard X format (.bdf or .snf)
>|>into DECwindow font format (.dwf). Does anyone know if there's such a program
>|>(running under Ultrix)? If so, where can I get it? Thanks in advance for any
>|>help.
>|>
>
>  We provide /usr/bin/X11/bdftopcf already.  We use .pcf format on ULTRIX.
>
>  Not sure about .snf font files though.
>
>-/ Jim /-

Thanks for the follow-up (Sorry, I couldn't reach Jim via direct e-mail (:-).
Unfortunately, my Ultrix system still runs the DEC server, which requires
the DECwindow font format (.dwf). What I need is a program to convert font
format from ".bdf" into ".dwf". I don't know if there's such a program
available.

By the way, does anyone know there's any ftp sites I can get the X11R5 server
for my VAXstation 3100 color display (I'm now using the Xqdsg server from DEC)?

-- Cui-Qing Yang

Dept. of Computer Scinece
University of North Texas
cqyang@ponder.csci.unt.edu
Newsgroups: comp.windows.x
From: qualtrak@netcom.com (Qual Trak)
Subject: Re: FLAME, FLAME ON X!!!
Organization: QualTrak Corporation
Date: Tue, 10 Nov 1992 14:29:06 GMT

In article <1992Nov10.110108.8015@ericsson.se> etxmesa@eos.ericsson.se (Michael Salmon) writes:
>In article <1683@igd.fhg.de>, 
>baumann@igd.fhg.de (Peter Baumann) writes:
>[...]
>|> PS:
>|> Have you ever had something named X in your home directory when
>|> starting xinit? (I figure that each of us has "." at the beginning
>|> of the PATH variable...) - Nice effect.
>
>Unfortunately there are people that have . at the start of their path,
>personally I have it last and often feel that is chancy enough.
>
>-- 
>
>Michael Salmon
>
>#include	<standard.disclaimer>
>#include	<witty.saying>
>#include	<fancy.pseudo.graphics>
>
>Ericsson Telecom AB
>Stockholm
I'm one of those poor unfortunates and have seemed to suffer no ill
effects.  Ain't religion great!
------------------------------------------------------------------------
John Birchfield - QualTrak Corp (408) 730-2674 Home (408) 736-3852
jb@QualTrak.COM
------------------------------------------------------------------------


Newsgroups: comp.windows.x.pex
From: rthomson@mesa.dsd.es.com (Rich Thomson)
Subject: Re: Drawing into DrawingArea widget
Reply-To: rthomson@dsd.es.com (Rich Thomson)
Organization: Design Systems Division, Evans & Sutherland, SLC, UT
Date: Fri, 6 Nov 92 22:10:31 GMT

In article <100874@bu.edu>
	kiki@bass.bu.edu (Keith Baccki) writes:
>P.S. It works with XCreateGC, but to be consistent I tried using
>     the Xt version - however, I couldn't find it in out Xt ref.
>     manual. What's the proper syntax?

The two calls I found in my Xt man pages are XtGetGC and XtReleaseGC.

XtGetGC(3Xt)        RISC/os Reference Manual         XtGetGC(3Xt)

NAME
     XtGetGC, XtReleaseGC - obtain and destroy a sharable GC

SYNTAX
     GC XtGetGC(w, value mask, values)
           Widget w;
           XtGCMask value mask;
           XGCValues *values;

     void XtReleaseGC(w, gc)
           Widget w;
           GC gc;

ARGUMENTS
     gc        Specifies the GC to be deallocated.

     values    Specifies the actual values for this GC.

     value mask
               Specifies which fields of the values are speci-
               fied.

     w         Specifies the widget.

DESCRIPTION
     The XtGetGC function returns a sharable, read-only GC.  The
     parameters to this function are the same as those for
     XCreateGC except that a widget is passed instead of a
     display.  XtGetGC shares only GCs in which all values in the
     GC returned by XCreateGC are the same.  In particular, it
     does not use the value mask provided to determine which
     fields of the GC a widget considers relevant.  The
     value mask is used only to tell the server which fields
     should be filled in with widget data and which it should
     fill in with default values.  For further information about
     value mask and values, see XCreateGC in the Xlib - C
     Language X Interface.

     The XtReleaseGC function deallocate the specified shared GC.

SEE ALSO
     X Toolkit Intrinsics - C Language Interface
     Xlib - C Language X Interface

                         Printed 11/6/92  1 September 1988 Page 1

-- 
		      Don't blame me; I voted Libertarian
Disclaimer: I speak for myself, except as noted; Copyright 1992 Rich Thomson
UUCP: ...!uunet!dsd.es.com!rthomson			Rich Thomson
Internet: rthomson@dsd.es.com	IRC: _Rich_		PEXt Programmer
Newsgroups: comp.windows.x.pex
From: rdcook@dal.mobil.com (R. D. Cook  [Rick])
Subject: Drawing into a Drawing Area
Organization: Mobil Research and Development
Distribution: usa
Date: Wed, 11 Nov 1992 17:24:03 GMT

Several responses to this question were only partially correct.
The widget must first be realized to have a window ID.  This is
NOT the same as mapping the widget.  A mapped widget must
have a window ID (ie, be realized) be the converse is not true. 
Newsgroups: comp.windows.x.pex
From: rthomson@mesa.dsd.es.com (Rich Thomson)
Subject: Re: Drawing into DrawingArea widget
Reply-To: rthomson@dsd.es.com (Rich Thomson)
Organization: Design Systems Division, Evans & Sutherland, SLC, UT
Date: Fri, 6 Nov 92 06:05:30 GMT

In article <1992Nov6.011714.21164@colorado.edu>
	devin@frodo.Colorado.EDU (Sonja Orlavski) writes:
>You need to be doing these
>commands in response to an Expose event (i.e. do an XtAddEventHandler to
>your drawing area and put these commands into the event handler).
>Otherwise, you're drawing into the window before it's shown up on the
>screen.

Oh, good point.  But there is no need to drop down to the level of
XtAddEventHandler; the Motif DrawingArea widget has a redraw callback
called XmNexposeCallback.  You still need to use the Xt GC management
functions, though, or you will end up conflicting with the GCs used
by the widget implementation.

						-- Rich
-- 
		      Don't blame me; I voted Libertarian
Disclaimer: I speak for myself, except as noted; Copyright 1992 Rich Thomson
UUCP: ...!uunet!dsd.es.com!rthomson			Rich Thomson
Internet: rthomson@dsd.es.com	IRC: _Rich_		PEXt Programmer
From: azhao@cs.arizona.edu (Qiang Alex Zhao)
Newsgroups: comp.windows.x.pex
Subject: How to do animation?
Keywords: animation
Date: 12 Nov 92 04:27:09 GMT
Followup-To: comp.windows.x.pex
Organization: Computer Science Dept, Univ of Arizona, Tucson

Will "double-buffering" help? And how to do animation on a PEX-SI
server with no "double-buffering" support? And how to do that on a
Sun's server with d.b. support?

Thanks in advance.

-- 
= Qiang Alex Zhao		   Computer Science Department
  azhao@cs.arizona.edu             University of Arizona, Tucson, AZ 85721
  (602) 621-1815
				   "gtetris" has nothing to do with GNU.
From: paulj@gdwest.gd.com (Paul D Johnston)
Newsgroups: comp.windows.x.pex
Subject: Re: Drawing into DrawingArea widget
Date: 6 Nov 92 22:20:12 GMT
Organization: General Dynamics Corp.

In article <100607@bu.edu> kiki@bass.bu.edu (Keith Baccki) writes:
>
>	Drawing something into the Drawing Area should be a
>trivial task, but nonetheless the following pieces of code
>do NOTHING in the window:
>
>      XtSetArg(...);   /* bunch of these... NOTE: height = 650 */
>                       /*                          width = 400 */
>      ionwindow =XmCreateFormDialog(toplevelshell,"ionwindow",arglist,6);
>      XtManageChild(ionwindow);
>
>      XtSetArg(...);   /* Few more... NOTE: requested height = 460 */
>	               /*                        "     width = 400 */
>      iondrawable = XmCreateDrawingArea(ionwindow,"iondrawable",arglist,4);
>      XtManageChild(iondrawable);
>
>      gcvalues.foreground = BlackPixel(display,DefaultScreen(display));
>      gcvalues.background = WhitePixel(display,DefaultScreen(display));
>
>      gc = XCreateGC(display,XtWindow(iondrawable),GCForeground | GCBackground, &gcvalues);
>
>      XFillRectangle(display,XtWindow(iondrawable),gc,(Position)50,(Position)50,(Dimension)200,(Dimension)200);
>      XDrawLine(display,XtWindow(iondrawable),gc,(Position)
>100,(Position) 100,(Position) 300,(Position) 150);
>      XFlush(display);
>
>Any suggestions? Am I missing something?
>
>
   If this is the exact order of your code, then the problem is that your're
trying to draw into a window (drawable) that hasn't been mapped 
(i.e., realized) yet.  An Expose event is automatically generated (and the
window is erased) when a window is first mapped.  The stuff you drew gets
erased when the DrawingArea is realized.  Add the code that does the 
drawing to an XmNexposeCallback for the DrawingArea and your stuff will
appear in the window every time an Expose event is generated (especially
after the first Expose event).

			- Hope this helps,
			  Paul D. Johnston

-- 
==============================================================================
| Paul D. Johnston			|			|	     |
| paulj@gdwest.gd.com  (619) 592-5150	| My opinions are not	| God Rules! |
| GDE Systems, Inc., San Diego, CA.	| shared by anyone.	|	     |
From: jnaft@hamlet.umd.edu (Joseph Naft)
Newsgroups: comp.windows.x.pex
Subject: availability of PEX servers
Date: 9 Nov 92 06:41:30 GMT
Distribution: usa
Organization: University of Maryland, College Park

Three questions:

What architectures does the PEX sample implementation (X11R5) support?
(Perhaps there is a file somewhere that answers this, and you could direct me
to it.)

Is anyone aware of any commercial X servers that support PEX?

Is there any way to add the PEX extentions to my X11R4 X server using the -x
option?  The machine is an SGI Iris running IRIX 4.0.5F, the X server is from
SGI, the -x option is documented in the man page.

Any help in answering these questions will be appreciated.
From: kiki@bass.bu.edu (Keith Baccki)
Newsgroups: comp.windows.x.pex
Subject: Re: Drawing into DrawingArea widget
Date: 6 Nov 92 19:23:58 GMT
Reply-To: kiki@bass.bu.edu (Keith Baccki)
Followup-To: comp.windows.x.pex
Organization: Boston University


	Thanks a million to all who responded. The Expose event
was the problem - so I just added a callback for drawing.

P.S. It works with XCreateGC, but to be consistent I tried using
     the Xt version - however, I couldn't find it in out Xt ref.
     manual. What's the proper syntax?

		Thanks again,

				keith
Newsgroups: comp.windows.x.pex
From: stefans@bauv106.bauv.unibw-muenchen.de (Stefan Schwarz)
Subject: Re: Drawing into DrawingArea widget
Organization: Universitaet der Bundeswehr Muenchen (Germany)
Date: Fri, 6 Nov 1992 09:54:00 GMT

kiki@bass.bu.edu (Keith Baccki) writes:


>	Hello, I'm working with DEC PHIGS ver. 2.3A on a
>DECstation 5000/133 with PXG+ hardware. I am writing code
>that is half PHIGS and half Motif, and I am having trouble
>drawing non-PHIGS graphics into an initialized Drawing Area
>widget. Sounds pretty idiotic, but I've even had more experienced
>X coders look at my code and shrug there shoulders. Anyway,
>here's the basic structure:

> 	    application shell widget
>		     /     \
>                    /       \
>    PHIGS output widget   Form Dialog
>				\
>				 \
>			      Drawing Area				


>	Drawing something into the Drawing Area should be a
>trivial task, but nonetheless the following pieces of code
>do NOTHING in the window:

>      XtSetArg(...);   /* bunch of these... NOTE: height = 650 */
>                       /*                          width = 400 */
>      ionwindow =XmCreateFormDialog(toplevelshell,"ionwindow",arglist,6);
>      XtManageChild(ionwindow);

>      XtSetArg(...);   /* Few more... NOTE: requested height = 460 */
>	               /*                        "     width = 400 */
>      iondrawable = XmCreateDrawingArea(ionwindow,"iondrawable",arglist,4);
>      XtManageChild(iondrawable);

>      gcvalues.foreground = BlackPixel(display,DefaultScreen(display));
>      gcvalues.background = WhitePixel(display,DefaultScreen(display));

>      gc = XCreateGC(display,XtWindow(iondrawable),GCForeground | GCBackground, &gcvalues);

>      XFillRectangle(display,XtWindow(iondrawable),gc,(Position)50,(Position)50,(Dimension)200,(Dimension)200);
>      XDrawLine(display,XtWindow(iondrawable),gc,(Position)
>100,(Position) 100,(Position) 300,(Position) 150);
>      XFlush(display);

Be aware between the difference of managing a widget and creating the
corresponding window. Only after mapping the window is visible and it
makes sense to do some output.
And further, XtWindow(widget) in the code above could return 0, because the
window doesn't exist at this time.
So, draw only in case of expose-events or wait until you receive a map-notify
for the drawing area.

Stefan
-- 
__
Stefan Schwarz                            University of the armed forces
Laboratory for graphical data processing  W-8014 Neubiberg, FRG
--
Newsgroups: comp.windows.x.pex
From: devin@frodo.Colorado.EDU (Sonja Orlavski)
Subject: Re: Drawing into DrawingArea widget
Organization: University of Colorado, Boulder
X-Newsreader: Tin 1.1 PL5
Date: Fri, 6 Nov 1992 01:17:14 GMT

Keith Baccki (kiki@bass.bu.edu) wrote:
: 
: 	Drawing something into the Drawing Area should be a
: trivial task, but nonetheless the following pieces of code
: do NOTHING in the window:
: 
:       XFillRectangle(display,XtWindow(iondrawable),gc,(Position)50,(Position)50,(Dimension)200,(Dimension)200);
:       XDrawLine(display,XtWindow(iondrawable),gc,(Position)
: 100,(Position) 100,(Position) 300,(Position) 150);
:       XFlush(display);

I'm almost certain that this is your problem.  You need to be doing these
commands in response to an Expose event (i.e. do an XtAddEventHandler to
your drawing area and put these commands into the event handler).
Otherwise, you're drawing into the window before it's shown up on the
screen.

You probably don't need the XFlush.

			-Devin

--
Devin Hooker (RP90)  (SotM 7/91)  DoD #0034  devin@boulder.colorado.edu  ------
"It's being both that's a bitch."                                      --\--- /
"I wanted to take my brain to hell and back and see what I had left."  \  \ //
"This howling in the distance, it's a captivating sound.                \  \/
        Can't tell if it's ecstasy or pain..."  -DW                      \/
Newsgroups: comp.windows.x
From: scornd4@solomon.technet.sg (Joomeng Quek)
Subject: Re: Compiling aXe. anything wrong?
Organization: National University of Singapore
X-Newsreader: TIN [version 1.1 PL6]
Date: Sat, 7 Nov 1992 02:59:28 GMT

: cc -c -O   -I/usr/include  -I.     -DHELPDIR=\"/usr/lib/X11\" AxeEditor.c
: "AxeEditor.c", line 1728: object undefined
: Compilation failed
: *** Error code 1
: make: Fatal error: Command failed for target `AxeEditor.o'

First of all, is AxeEditor.c in the directory, is the file ok?
From: wohler@sapwdf.UUCP (Bill Wohler)
Newsgroups: comp.windows.x
Subject: Re: X Window System bibliography
Date: 9 Nov 92 13:53:37 GMT
Reply-To: Bill Wohler <wohler@sap-ag.de>
Organization: SAP AG, Walldorf, Germany

klee@wsl.dec.com (Ken Lee) writes:
>I wanted the bibliography to be useful to readers, not necessarily to
>publishers.  Do readers really want the O'Reilly books listed
>separately; alphabetically by author?  Or does anyone really care?

>I was under the impression that most readers consider the "Definitive
>Guides" to be a set and prefer them listed together.

hiya ken,

  contrary to your desires, listing them as a set is only useful for
  publishers and not readers as the publisher already knows what books
  are in the set, along with the ISBN numbers ;-).  who do you know
  that have ordered the entire o'reilly set in one go?  seriously, when
  ordering the books, one needs the information for each book
  separately.


Bill Wohler <wohler@sap-ag.de> <sapwdf!wohler>
Heidelberg Red Barons Ultimate Frisbee Team
Newsgroups: comp.windows.x