[fpc-devel] Xlib and XCB: any plans?

Graeme Geldenhuys graemeg.lists at gmail.com
Sun Mar 4 21:46:38 CET 2012


On 4 March 2012 19:42, Giuliano Colla  wrote:
> Xlib units of fpc. However Xorg discourages the usage of Xlib for new
> developments, and suggests the usage of XCB instead. What's the situation of
> fpc in respect of XCB?


Why, when the current XLib already uses XCB. The current XLib
implementation is not a "pure" xlib any more, it is more like  a
wrapper for XCB (at least that is so under Linux). I've wanted to
implement a pure XCB backend for fpGUI too, and after doing some
research I found about the Xlib wrapper over XCB under Linux.

Just take a look at an fpGUI application compiled with XLib as
backend. Note the dependency in libxcb.so in the list, yet I did not
use XCB at all in fpGUI.

----------------------------------------
$ ldd docview
	linux-gate.so.1 =>  (0x00e6c000)
	libX11.so.6 => /usr/lib/libX11.so.6 (0x00131000)
	libXft.so.2 => /usr/lib/libXft.so.2 (0x00f16000)
	libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0x0024e000)
	libfontconfig.so.1 => /usr/lib/libfontconfig.so.1 (0x005be000)
	libxcb.so.1 => /usr/lib/libxcb.so.1 (0x00110000)
	libdl.so.2 => /lib/tls/i686/cmov/libdl.so.2 (0x0012a000)
	libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0x003a8000)
	libXrender.so.1 => /usr/lib/libXrender.so.1 (0x00dad000)
	/lib/ld-linux.so.2 (0x007d6000)
	libz.so.1 => /lib/libz.so.1 (0x0092c000)
	libexpat.so.1 => /lib/libexpat.so.1 (0x0063f000)
	libXau.so.6 => /usr/lib/libXau.so.6 (0x0060d000)
	libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0x0041e000)

----------------------------------------


I wouldn't waste my time on XCB. XLib is not going to disappear. Plus
Wayland is on it's way, which means you would probably have to change
to that anyway.

-- 
Regards,
  - Graeme -


_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net



More information about the fpc-devel mailing list