[Xcb] Library for access to the resource manager

Ingo Bürk admin at airblader.de
Thu Jan 21 13:54:49 PST 2016


Hi,

thank you for the reply. Things like cairo-xcb and xcb-util-cursor could
be migrated to it fairly soon I would assume, once the basics are there.
Migrating awesome we should take our time testing it as in awesome the
full capability of the algorithm could be used. But I definitely
appreciate your support on this. Let's just get it actually working
first. :)

You're right that awesome and cairo-xcb would do it twice, but my plan
is of course to build a database from the RESOURCE_MANAGER once for each
context, so there's going to be exactly two parse steps here. Unless
your xrdb contains a thousand lines, that should be OK. Not that I have
any performance data yet, it just seems hard to imagine :)

I'll gladly move it over to fdo, but I want to have at least some
working version first. Once that's in place, we can start whatever
procedure to get it moved there. I'll get back to you guys! :)


Ingo

P.S.: WIlldo

On 01/21/2016 06:47 PM, Uli Schlachter wrote:
> Am 11.01.2016 um 10:52 schrieb Ingo Bürk:
>> Hi everyone,
>>
>> I noticed that there currently seems to be nothing within the area of
>> XCB that offers access to the resource manager and its contents. In [1],
>> Michael Stapelberg also noted that some tools such as cairo-xcb and
>> xcb-util-cursor currently parse the RESOURCE_MANAGER property of the
>> root window by hand, which is duplicated work, rather ugly and AFAICT
>> won't work if the configuration uses wildcards (as allowed by the spec).
>>
>> We therefore had the idea of writing a library ("xcb-util-xrm") to allow
>> access to the resource manager contents without having to use Xlib's
>> Xrm* (X11/Xresources.h). Is this something worth doing – or is there
>> even already something that I haven't been able to find?
>>
>> I'd love to get this started, but would also appreciate help / guidance
>> in terms of setting up the project or anything worthy knowing before
>> doing so. For the start, I'd like to focus on a (spec conforming) way to
>> query resources from the database (not anything to modify them). I'd
>> also appreciate discussions about the API for this, but this is
>> something for after the work on this started.
>>
>> [1] https://github.com/i3/i3/issues/2130
> Hi,
>
> I see you started a GitHub repo for your work [1], nice. Thanks for working on
> this and I think this is a really good idea to have. I'll definitely make
> cairo-xcb and awesome use this when it's finished.
>
> However, this makes me wonder about duplicate work... Awesome uses cairo-xcb so
> your library would be initialized twice and will parse the RESOURCE_MANAGER
> property twice. On the other hand, this should be quick and nothing to really
> worry about.
>
> If you want, I'd suggest to host the resulting library on freedesktop.org,
> together with the other xcb-util libraries. Since I'm not sure about the
> procedure for this, you should talk to Michael Stapelberg who went through the
> same thing for his util-cursor.
>
> Also, if no one complains about this idea, then due to review by crickets it's
> settled that the XCB project participants agree to this plan. :-)
>
> Thanks & Cheers,
> Uli
>
> [1]: https://github.com/Airblader/xcb-util-xrm
>
> P.S.: And say hi to Christian from me. :-)



More information about the Xcb mailing list