X Windows Programming in C++: Part III
Continuing with our task of creating a C++ version of basicwin.c, we next look at XCreateSimpleWindow. Here’s some code snippets from basicwin.c showing the use of XCreateSimpleWindow:
(more…)
X Windows Programming in C++: Part IIIContinuing with our task of creating a C++ version of basicwin.c, we next look at XCreateSimpleWindow. Here’s some code snippets from basicwin.c showing the use of XCreateSimpleWindow: (more…)X Windows Programming in C++: Part IIContinuing with our task of creating a C++ version of basicwin.c, we next look at XOpenDisplay / XCloseDisplay. Here’s some code snippets from basicwin.c showing the use of these functions: (more…)X Windows Programming in C++: Part IYears ago, I did quite a bit X Windows programming. When I started developing X Windows software, I was also learning C++ (this was a long time ago). Unfortunately , the X Windows system I was developing software for did not have a C++ compiler. This led to some frustration since using C++ would have made some of my tasks easier. A fews years later, I worked on another project using X and Motif. It was mandated that this software be written in C leading to same frustration I experience when I first started learning X (by this time I was a seasoned C++ developer, so writing anything in C seemed like a step backward). I’ve decided to revisit X Windows programming on my own for a few reasons:
My first step in getting back into X Windows programming was to revist the book, Xlib Programming Manual, Rel. 5. The examples in this book are written in C (Kerninghan and Ritchie C, no less). One of these examples, basicwin.c, demonstrates the fundementals of programming with the X library. I figure coming up with a C++ version of basicwin.c would be a useful learning experience for myself and possibly others. I’ll start out by taking pieces of basicwin.c and converting them to C++. I’ll start with following code fragments showing the use of the structures: XSizeHints, XWMHints, and XClassHint. (more…) |
||