On Wed, 17 Jul 2002, Annie Luo wrote:
> Hi All,
>
> I am working on a modified DDX layer project and I met some problem. Any
> kind of help or hint from you will be greatly appreciated.
>
> I tried to get the information (origin, width and height) of the current
> window of focus by doing:
>
>
> extern InputInfo inputInfo;
> ....
> short x, y;
> x = inputInfo.keyboard->focus->win->origin.x;
> y = inputInfo.keyboard->focus->win->origin.y;
> ....
> fprintf(stderr, "%h%h", x, y);
>
>
>
> I tried to print out the value of x and y but the program crashes when the
> printf is called. I tried different formats of x and y and changed in
> fprintf accordingly, the crash persists. If fprintf is not used, the
> program runs well. Did I do anything wrong or miss anything? It doesn't
> matter if the values print or not, I'd like to know if this works for
> getting the information of window of focus.
>
At least in XFree86, you can't call fprintf. ErrorF is the
standard error reporting function, even in the SI.
Mark.
_______________________________________________
Xpert mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/xpert