Re: x window programming
From: Last2Know (grokkalot_at_yahoo.com)
Date: Mon, 23 Aug 2004 20:39:19 -0500
On Mon, 23 Aug 2004 18:17:27 +0100, scott wrote:
> "Last2Know" <firstname.lastname@example.org> wrote in message
>> On Mon, 23 Aug 2004 16:46:59 +0100, news.freeserve.com wrote:
>>> thx for any help that is given.
>>> iv been programming in Microsoft windows for some time now but want to
>>> over to Linux using x windows.
>>> I can write simple command prompt type programs in Linux but iv yet to
>>> figure out how to do windows programming in x window(I don't even know
>>> to compile an x windows program)
>>> is there a site some one could point me to plz to make me better
>>> what I have to do ?
>>> thx for any help
>> One of the first things to realize is that from the viewpoint of
>> actually programming a modern GUI app, using the X11 (core XWindows)
>> API is is analogous to programming at the assembly language level.
>> It is helpful to have a fundamental understanding of how it works
>> but it is isn't the best route to productivity. It has commands
>> at the level of drawing lines and boxes rather than working with
>> So in order to answer your question effectively, it would helpful
>> if you could specify whether
>> 1) you want to learn the low level X11 API or work with a modern
>> 2) you prefer to program in C, C++, or some other higher level
>> interpreted language.
> hi thx for the replys. i would be doing it in c++ but using the lowe level
> X11 API. If i could just figure out how to create a window and compile it,
> it would be a step in the right direction.
For a tutorial introduction to the Xlib C API and concepts, Adrian
Nye's O'Reilly Book, Volume 1 : Xlib Programming Manual is still
probably the best source.
You can download the source code examples from the O'Reilly
Postscript versions of the various specs are here:
(can be read with the gv program or printed directly).
Be sure to install the X11 development man pages on your
Kenton Lee has a lot of good links:
including some tutorials.
Here is a nice book on using the most common
Linux C/C++ compiler that you can buy or download
in pdf form:
Three other tools that you will want to be acquainted
with are gdb, a source level debugger, gprof, a
profiler, and valgrind, a tool for detecting memory
access violations and leaks (somewhat similar to
Rational's Purify product).