home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.windows.open-look
- Path: sparky!uunet!destroyer!news.iastate.edu!moharil
- From: moharil@cs.iastate.edu (Vinay Arvind Moharil)
- Subject: Sun SPARC X11/Intrinsic.h HELP!!
- Message-ID: <moharil.715447934@judy.cs.iastate.edu>
- Keywords: Sun SPARC X11/Intrinsic.h
- Sender: news@news.iastate.edu (USENET News System)
- Organization: Iowa State University, Ames IA
- Date: Wed, 2 Sep 1992 15:32:14 GMT
- Lines: 92
-
- Hi netters!
-
- I am sorry if this is an FAQ or a stupid question.
-
-
- I am trying to use the CC 3.0 on the Sun SPARC along with the Open Look. One
- of my applications needs to include the X11/Intrinsic.h file. As I was
- getting the syntax errors *even after* defining the XTFUNCPROTO variable
- above any of the include files and/or putting the #include statement in
- extern "C" { ...}, I tried to walk thru the X11/Intrinsic,h file available on
- my system and thought that at some poins, there is a legitimate reason for
- the syntax errors though I may be wrong. Given below are some of the lines
- where I got syntax errors and I thought a mistake exists. The line numbers are
- the line numbers in the X11/Intrinsic.h file.
-
- 68: #if defined(__cplusplus) || defined(c_plusplus)
- 69: #define CONST const
- 70: /* make const String do the right thing */
- 71: #define String char*
- 72: #else
- 73: #define CONST
- 74: #endif /* __cplusplus */
-
-
- 101: #define XtNumber(arr) ((Cardinal) (sizeof(arr) / sizeof(arr[0])))
-
- 103: typedef char *String;
- As c_plusplus is defined String is defined to char*(line 71). Line 103 typedefs
- char *String and for obvious reasons this should give a syntax error. All
- further occurences of the String give syntax error. Commenting line 71 removes
- this problem.
-
- 174: typedef void (*XtActionProc)(
- 175: #if NeedFunctionPrototypes
- 176: Widget /* widget */,
- 177: XEvent* /* event */,
- 178: String* /* params */,
- 179: Cardinal* /* num_params */
- 180: #endif
- 181: );
-
- 183: typedef XtActionProc* XtBoundActions;
-
- 185: typedef struct _XtActionsRec{
- 186: String string;
- 187: XtActionProc proc;
- 188: } XtActionsRec;
-
- As I said above the occurences of the String are giving sytax errors.
-
- 230: typedef void (*XtConverter)(
- 231: #if NeedFunctionPrototypes
- 232: XrmValue* /* args */,
- 233: Cardinal* /* num_args */,
- 234: XrmValue* /* from */,
- 235: Xrmvalue* /* to */
- 236: #endif
- 237: );
-
- The last Xrmvalue has got a lower case v whereas all others have got Upper case
- V. This also gave syntax errors. Changing v to V removes this error.
-
- 242: XrmValue* /* args */,
- 243: Cardinal* /* num_args */,
- 244: XrmValue* /* from */,
- 245: XrmValue* /* to */,
- 246: XtPointer* /* converter_data */,
- 247: #endif
- 248: );
-
- After the last XtPointer* a comma exists.Why? Removing this comma removes
- syntax error at this point. Also it may be noted that here all XrmValues have
- a upper case V which probably supports what I said earlier.
-
- These are some of the points where I had problems. Unfortunately, on two
- other Sun SPARCs accessible to me I found exactly same file. Is it the case
- that I am making mistake somewhere? I would like to have your expert opinion.
-
- I have thought in terms of two ways to overcome this. If you have a different
- Intrinsic.h file on *SPARC* I would like to copy that. I was also wondering
- if copying the complete X11 directory from DEC stations is going to be
- helpful.(just the X11 and nothing more). I can't ftp the whole X at this
- moment because of some problems.
-
- It would be great if you can help me.
-
- Thanking you,
- vinay
-
- moharil@judy.cs.iastate.edu
- (515)-294-1546
-
-