another apps window access with shell

ok i will try and thanks again for giving your valuable time.

i have tried to opening window2 from window1 by using window2.show
i successfully open window2 from window1.
Now i have the situation that i have window1 with graphics drawn on it and window2 also opening.
how i can make window2 transparent so that window1 graphics can be shown in background.

you can change the opacity of Window2 ( change 0.5 to what you need(from 0.0 to 1.0))

Window2.Open

  Declare Sub gtk_window_set_opacity lib "libgtk-x11-2" _
  (windowRef As Integer, opacity as Double)
  
  Declare Function gtk_widget_is_composited lib "libgtk-x11-2" _
  (windowRef As Integer) As Boolean
  
  if gtk_widget_is_composited(self.Handle) then
    gtk_window_set_opacity(self.Handle, 0.5)
  else
    MsgBox "Not Composited"
  end if

Nevertheless, I understand the concept not really.
Why not arrange the windows next to each other?

i executed as per above but the window2 is getting in background and window1 is in front.