# LibTmux::Model::SessionRef.next-window

- **Module:** LibTmux::Model
- **Package:** LibTmux
- **Language:** Raku
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-raku/blob/0b5dd3d32e20f83a0069874e33eab0eb48f55962/lib/LibTmux/Model.rakumod#L153
- **Page:** https://libtmux.org/en/raku/latest/reference/libtmux-model-sessionref-next-window/

```
method next-window(Bool :$activity = False --> Result:D)
```

Select the next session window, optionally restricting to activity alerts.

Select the next session window, optionally restricting to activity alerts.

## Parameters

- `$activity?` (`Bool`)

## tmux command

The tmux commands behind `next-window`.

- [`next-window`](/en/tmux/latest/manual/next-window/)

## tmux C API

The C declarations in tmux that implement these commands.

- [`cmd_next_window_entry`](/en/tmux/latest/reference/c-variable-cmd_next_window_entry/) (attribute)
- [`cmd_select_window_exec`](/en/tmux/latest/reference/c-function-cmd-select-window-c-cmd_select_window_exec/) (function)

## In other ports

Move to the next window of a session

| Language | Equivalent |
| --- | --- |
| Python | [`libtmux.Session.next_window`](/en/py/latest/reference/libtmux-session-next_window/) (method) |
| Haskell | No public Haskell equivalent is implemented; the current modules expose scalar values and version parsing. |
| TypeScript | `Session.selectWindow` takes `next`, `previous` or `last` |
| Rust | [`session.Session.next_window`](/en/rs/latest/reference/session-session-next_window/) (method) |
| Go | [`tmux.Session.NextWindow`](/en/go/latest/reference/tmux-session-nextwindow/) (method) |
| Java | [`io.github.libtmux.Session.nextWindow`](/en/java/latest/reference/io-github-libtmux-session-session-nextwindow/) (method) |
| C# | [`LibTmux.Session.SelectNextWindowAsync`](/en/csharp/latest/reference/libtmux-session-selectnextwindowasync/) (method) |
| C++ | [`libtmux::Session::select_next_window`](/en/cxx/latest/reference/libtmux-session-select_next_window/) (method) |
| Swift | [`Server.selectNextWindow(in:)`](/en/swift/latest/reference/server-selectnextwindow(in-)/) (method) |
| OCaml | No direct public OCaml equivalent is recorded for this operation. |
| Perl | No dedicated equivalent in the selected Perl surface. Explicit Server::cmd remains available for native tmux commands. |

No equivalent is recorded in Ruby, Lua, PowerShell, Julia, Erlang, Elixir, Common Lisp, Clojure, Kotlin, Scala or F#.
