home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / windows / x / 19387 < prev    next >
Encoding:
Internet Message Format  |  1992-11-20  |  3.9 KB

  1. Path: sparky!uunet!news.univie.ac.at!blekul11!stud05
  2. Newsgroups: comp.windows.x
  3. From: stud05@cc4.kuleuven.ac.be (Ton Hospel)
  4. Distribution: world
  5. References:  <GATESWK.722138813@CRAFT.CAMP.CLARKSON.EDU>
  6. Date: Friday, 20 Nov 1992 15:28:37 +01
  7. Message-ID: <1992Nov20.145148@cc4.kuleuven.ac.be>
  8. Organization: K.U.Leuven - Academic Computing Center
  9. Subject: Re: Some people record there knowledge.
  10. Nntp-Posting-Host: 134.58.8.1
  11. Lines: 68
  12.  
  13. In article <GATESWK.722138813@CRAFT.CAMP.CLARKSON.EDU>, gateswk@craft.camp.clarkson.edu writes:
  14. >
  15. >
  16. >
  17. > I don't know if anyone out there is like I am but when I am learning stuff
  18. > I tend to keep the basic info in a file so I can look at it and if someone
  19. > wants to know it they can look in that file.  What I'm wondering is if anyone
  20. > has something along these lines on the basic programming of windows in x.
  21. > You know how to open a window and put strings etc in it.  How to make the
  22. > colors different and the geometry and such.  I'm more concerned with
  23. > syntax than anything.  I know the c.  I need the main commands and the parameters that those commands take and the like.  I would appreciate it if someone
  24. > would share some of this info with me.  We have xwindows here at school now
  25. > but to the best of my knowledge we still don't have a course in programming
  26. > them.  Here they are use them....  We run X11R4 and 3 on two different systems
  27. > with Aix 3.1 on one and Aix 3.2 on the other. So if you could help me out
  28. > I'd appreciate it.  Thanx a lot.
  29. >
  30. > Walker
  31. > gateswk@craft.camp.clarkson.edu
  32. >
  33. > If you're ever lost in la la land look me up....
  34. >   I'm sure I'll be there....
  35. >     -Walker
  36. >
  37. > CUL8R and I'm out....
  38. >
  39.  
  40. If you are just starting X, I would say that you should teach yourself Xt
  41. programming, and not Xlib programming. Xlib  is very nice for rather simple
  42. window programs (you have full control), but as soon as more sophisticated
  43. things are asked, the programs tend to become filled with X details and the
  44. structure gets lost. Better to use the toolkit and some widgetset (I prefer the
  45. athena 3d widgets (Xaw3d), but others are fine too). This allows you to
  46. concentrate on the structure of your program and the structure of whatever
  47. you want to display. It also makes configurability so much easier (it should
  48. take care of almost all your color and geometry problems, since you can set
  49. reasonable defaults in a very simple way, and the user can still change them if
  50. (s)he prefers). Label, command an text widgets (or the equivalent in other
  51. toolkits) should solve most of your text related problems. Xt has one drawback:
  52. the code size grows a lot (not a real problem on systems with lots of memory or
  53. shared libraries).
  54.  
  55. Drawing (the thing most beginning X programmers want to do) can be done in some
  56. sort of canvas widget (I can send you my Xaw/Xaw3d version if you want). In the
  57. window of this widget you can do all your normal X drawing stuff (so you'll
  58. still have to learn a bit about that).
  59.  
  60. For documentation, I refer you to the X FAQ, which is very good (it was posted
  61. recently, otherwise look in news.answers). Once you have read some starter
  62. book(s) to understand the concepts, you can find almost anything you want
  63. to know in the documentation that should be online in the files intrinsics.man,
  64. widgets.man, xlib.man and xmu.man (if you don't have them, ftp them from
  65. export.lcs.mit.edu). If you don't want a paper copy, these can take the place
  66. of a reference manual (and you can print them out of course).
  67.  
  68. Examples can be found on the ftp site export.lcs.mit.edu in the directory
  69. /pub/R5untarred/contrib/examples . I learned a lot from the examples in Xaw
  70. subdirectory there when I was starting with X.
  71.  
  72. Hope this helps, and also gets other people to consider using Xt instead of
  73. Xlib (These Xlib programs tend to be unconfigurable. It's also terrible to have
  74. to understand/change some Xlib programs, while with an Xt program rarely
  75. presents a problem).
  76.  
  77.                                                                Ton
  78.  
  79.  
  80.  
  81.