On Thu, 14 Aug 2003 14:07:54 -0700 (PDT) dd jj <[EMAIL PROTECTED]> babbled:
> Hello everyone,
>
> I hope this is the correct mailing list to post these questions... Could you
> please give some comments on them? thanks.
>
> 1) Now I want to search a button with specific caption, such as "Save" or
> "Cancel".. "Ok" on X window (no matter GNOME or KDE) screen. Can I implement
> this under different desktop enviroments(KDE,GNOME) with Xlib programming? Or
> it's toally impossible?
no. you can't. there is no foolproof generic way of detecting a widget
irrespective of widget set. you'd need to do hacks in each widget set to do
this. not to mention programs that use other widget sets or don't use them at
all.
> As my understanding,
>
> The button in Gnome is built using GTK but that in KDE is built using Qt, they
> are different widgets belong to differen Toolkit, right? But since GTK and Qt
> are both based on Xlib, I am wondering whether we can handle this using lowest
> level Programming - xlib?
>
> Or maybe I can only program using GTK for GNOME, using Qt for KDE separately
> for different desktop enviroment?
>
> 2) I tried to use XMoveResizeWindow to move a X window application such as
> Xclock, or Xcalc, I parsed the window ID "w" got from xwininfo and display
> dsp = XOpenDisplay(NULL) to it like:
>
> XMoveResizeWindow(dsp, w, 0, 0, 200, 200);
>
> it doesn't work, but when I creat my own window application using
first did you flush your x command buffer - XFlush(dsp); or XSync(dsp, False); ?
second. did you get the window id right? ie it was still around? third - was it
managed by the wm? the wm could have it fixed and not allowing resizes (or
swallowed) ?
> XCreateSimpleWindow, then it can work. Seems the display parameter is
> different every time when implement: dsp = XOpenDispaly(ULL) ?
>
> Did I miss something to deal with such existing Application window?
>
> Thank you for help me out.
>
>
>
>
>
> ---------------------------------
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site design software
--
--------------- Codito, ergo sum - "I code, therefore I am" --------------------
The Rasterman (Carsten Haitzler) [EMAIL PROTECTED]
熊耳 - 車君 [EMAIL PROTECTED]
Mobile Phone: +61 (0)413 451 899 Home Phone: 02 9698 8615
_______________________________________________
Devel mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/devel