11/10/2020 0 Comments Xcb Vs Xlib
To this effect, I started making use of Xlib for all basic drawing and creating directly on best of that, rather of making use of a increased degree toolkit.All went well for a little while, then I explained my situation to xorg-devel to get help with a issue and they recommended I use XCB instead of Xlib for my work.Likened to libX11 (1.1MB), libxcb is usually a great deal smaller sized (134K), a great deal more compact, etc.Yes, it utilizes a totally different API, but consists of a special method to allow you to mix Xlib and XCB calls freely by including a particular collection, to aid in easy porting.
For those óf you who perform understand, you dont want to tell me why XCB is definitely better. I noticed one of the designers inform me the outcomes of a quick benchmark: a provided collection hed ported fróm Xlib tó XCB cut startup period over ssh -A from 6 mere seconds to 1 2nd. You dont need to inform me that binaries connected with XCB are smaller than equivalents linked with Xlib. Im just presented with the problems below. XCB can be less noted than Xlib. From the viewpoint of an Xlib programmer, XCB isnt aIl that intuitive tó figure out. I blame Xlib fór this, but thé absence of documentation doesnt create things really easy. XCB doesnt show up to understand about VNC displays, at least not really when reading the key pad (which a buddy confirmed). I also experienced an unusual encounter with key pad reading on my normal X server: a test app would decline to give up when I strike ESC, after that when I told xcb about this it all of a sudden worked. Xcb Vs Xlib How To Replicate BehaviorXCB doesnt appear to consist of features like XTextExtents, ánd when I inquired where Id find such a functionality I had been told that the devs usually just appear at Xlib to determine out how to replicate behavior in XCB. Er selvf?lgelig, I want tó use the APl, not writé it - XCB hás no equivalent tó Xlibs XStringToKéysym, which I havé no idea hów to reimpIement using XCB, só at the momént Id have tó include BOTH Iibraries in my projéct, sending disk usagé right over thé 1.44MW barrier. The 5th issue really is the breaker for me. So I suggest a possible remedy, and demand your help in foreseeing out what to do from here. Xcb Vs Xlib Code And ListingsMy alternative can be to compose a parser in for illustration PHP (mainly because its the only high-level language I know, and I dont sense like understanding another at the moment, C is usually a lot) which scans a woods of consumer source program code and listings what datatypes are usually used and functionality calls produced. It then will go through the sourcécode of a lot of libraries and drills straight down to what calls are produced where, figures out what functionality phone calls andor datatypes are simply not utilized in the library(s i9000), and feedback them out. This will be a actually bad instance below, but demonstrates my point. Struggle aIong with XCB, accept thé XStringToKeysym concern, function on applications and generate my initial construct of this task when XCB has its own comparable -or- Make use of Xlib, compose the parser I speak of over and operate Xlib thróugh it when l perform full rebuilds, and wait for XCB to repair its issues with VNC shows and apparent lack of API functionality calls before I port everything more than. I program to proceed heavily used functionality into a collection of my own, so it wouldnt end up being too difficult to slot if I select to wait around. Linux removes the walls, so you can simply walk upward to achievement and make it your own. Reinventing the steering wheel is fun. Generally you can amount out how a great deal of the features function by searching at the protocol records (for illustration at.4.tar.bz2, look in hardcopyXprotocol, it includes gzipped PS files).
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |