[Xcb] [PATCH x2] Add protocol descriptions for GE and XFree86VidMode
Mariusz Ceier
mceier at gmail.com
Mon May 25 15:02:35 PDT 2009
Peter Harris pisze:
> Mariusz Ceier wrote:
>> Peter Harris pisze:
>>> These two patches add protocol descriptions for Generic Event Extension
>>> and XFree86VidMode.
>>>
>> Shouldn't Generic event be also defined in ge.xml ?
>
> Good question.
>
> From my perspective, xcb_genericevent_generic_event_t shouldn't be
> defined in XML any more than xcb_generic_event_t should be[1]. For that
> matter, xcb_ge_event_t is already defined in libxcb/xcb.h.
Current xcb_ge_event_t have some meaningless members like pad1 ...
What about:
* changing extension-name to GE - so we don't have ridiculously long
names ...
* removing xcb_ge_event_t structure from xcb.h
* including ge.h header generated from ge.xml
* adding "typedef xcb_ge_generic_event_t xcb_ge_event_t;" - for
compatibility with current apps that could already use this struct
?
libxcb seems to use this struct only once ( in xcb_in.c )
>
> I don't see a really compelling reason not to also define it in the XML.
> It just feels redundant.
>
I think it would be better to have xcb_ge_generic_event_t only in XML,
so we could keep all protocol definitions in one place ( xcb-proto ).
That will be important when we would like to generate server-side code,
from those descriptions.
> Peter Harris
>
> [1] Ugh. Feels like a namespace collision. But there was no way to know
> that someone would come up with "Generic Events" years after this name
> was chosen.
Huh, I thought that xcb_generic_event_t is Generic Event ... :)
Mariusz Ceier
More information about the Xcb
mailing list