← 返回命令列表

Linux command

xkill 命令

文本

复制后可按需替换文件名、目录或参数。

常用示例

Kill window by clicking

xkill

Kill specific window ID

xkill -id [window_id]

Kill all with matching name

xkill -frame

Show button to use

xkill -button any

说明

xkill forcibly closes X11 windows. After running, the cursor changes and the next clicked window is killed. The tool sends a kill request to the X server. This is more forceful than asking the window to close normally. Window manager frames can be targeted. Using -frame kills the window even if clicking the decoration rather than content. Any mouse button can trigger the kill. By default, only button 1 (left click) works. The -button option changes this. Pressing any key cancels xkill without killing a window. This provides an escape if started accidentally. The tool is useful when applications become unresponsive and normal close methods fail.

参数

-id _WINDOWID_
Kill specific window by ID.
-button _BUTTON_
Button to use (any, 1, 2, 3).
-frame
Include window frame.
-all
Kill all matching clients.
-display _DISPLAY_
X server display.

FAQ

What is the xkill command used for?

xkill forcibly closes X11 windows. After running, the cursor changes and the next clicked window is killed. The tool sends a kill request to the X server. This is more forceful than asking the window to close normally. Window manager frames can be targeted. Using -frame kills the window even if clicking the decoration rather than content. Any mouse button can trigger the kill. By default, only button 1 (left click) works. The -button option changes this. Pressing any key cancels xkill without killing a window. This provides an escape if started accidentally. The tool is useful when applications become unresponsive and normal close methods fail.

How do I run a basic xkill example?

Run `xkill` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does -id _WINDOWID_ do in xkill?

Kill specific window by ID.