## Tcl9.0.3/Tk9.0.3 Documentation > Tk C API > CoordToWin

### Tcl/Tk Applications | Tcl Commands | Tk Commands | [incr Tcl] Package Commands | SQLite3 Package Commands | TDBC Package Commands | tdbc::mysql Package Commands | tdbc::odbc Package Commands | tdbc::postgres Package Commands | tdbc::sqlite3 Package Commands | Thread Package Commands | Tcl C API | Tk C API | [incr Tcl] Package C API | TDBC Package C API

  NAME
    Tk_CoordsToWindow — 点を含む窓の調査 Find window containing a point
  SYNOPSIS
    #include <tk.h>
    Tk_Window
    Tk_CoordsToWindow(rootX, rootY, tkwin)
  引数 ARGUMENTS
    int rootX (入力in)
    int rootY (入力in)
    Tk_Window tkwin (入力in)
  説明 DESCRIPTION
  KEYWORDS

### NAME

Tk_CoordsToWindow — 点を含む窓の調査 Find window containing a point

### SYNOPSIS

#include <tk.h>
Tk_Window
Tk_CoordsToWindow(rootX, rootY, tkwin)

### 引数 ARGUMENTS

int rootX (入力in)
  X-座標(根本窓座標) X-coordinate (in root window coordinates).

int rootY (入力in)
  Y-座標(根本窓座標) Y-coordinate (in root window coordinates).

Tk_Window tkwin (入力in)
  応用譜を識別する窓の為の字句｡　 Token for window that identifies application.

### 説明 DESCRIPTION

Tk_CoordsToWindow は与えられた点を含む窓の場所を示す｡その点は根本座標内に rootX と rootY で指定される(もし仮想根本窓管理譜が使用中の場合 rootX と rootY は仮想根本窓の座標系にある)｡手続函数から返される値は与えられた点を含む窓に関する解析字句である｡点がどの窓内にもない場合､又は含んでいる窓が tkwin と同じ応用譜内にない場合は NULL が返される｡ Tk_CoordsToWindow locates the window that contains a given point. The point is specified in root coordinates with rootX and rootY (if a virtual-root window manager is in use then rootX and rootY are in the coordinate system of the virtual root window). The return value from the procedure is a token for the window that contains the given point. If the point is not in any window, or if the containing window is not in the same application as tkwin, then NULL is returned.

含んでいる窓はマウス遊走子を含む窓を定めたと同じ規則をつかって決定される: もし親と子供の両方が点を含む場合､子供が優先権を得る､又もし二つの兄弟の両方が点を含む場合､棚内の順位の最高位のもの(即ち､画面上に可視のもの)が優先権を得る｡ The containing window is decided using the same rules that determine which window contains the mouse cursor: if a parent and a child both contain the point then the child gets preference, and if two siblings both contain the point then the highest one in the stacking order (i.e. the one that's visible on the screen) gets preference.

### KEYWORDS

containing, coordinates, root window
Copyright © 1990-1993 The Regents of the University of California.
Copyright © 1994-1996 Sun Microsystems, Inc.