<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:12pt;font-family:Monospace">
<p><span style="color:#008000">> >>> import xcb</span></p>
<p><span style="color:#008000">> >>> import render</span></p>
<p><span style="color:#008000">> >>> c = xcb.Connection()</span></p>
<p><span style="color:#008000">> >>> win = c.generate_id()</span></p>
<p><span style="color:#008000">> >>> r = c.get_render_extension() # new method, checking whether</span></p>
<p><span style="color:#008000">> >>> render</span></p>
<p><span style="color:#008000">></span></p>
<p><span style="color:#008000">> ext. exists</span></p>
<p><span style="color:#008000">></span></p>
<p><span style="color:#008000">> >>> r.create_picture(...) # no need to add 'c' explicitly since it</span></p>
<p><span style="color:#008000">> >>> can</span></p>
<p></p>
<p>This does not really solve the problem because c would need to have a "get_render_extension" function right from the start. Which means that I need to program all possible extensions into the basic connection object.</p>
<p></p>
<p><span style="color:#008000">If I just tourn your example around, e.g.</span></p>
<p><span style="color:#008000">>>> import render</span></p>
<p><span style="color:#008000">>>> r = render.from_connection(c)</span></p>
<p></p>
<p>It would solve the problem. So: thanks a lot!</p>
<p></p>
<p>Tom</p>
<p></p>
</body></html>