Skip to content

Commit 5066910

Browse files
committed
docs(Pane): Tighten docstrings
1 parent 66a6e8e commit 5066910

File tree

1 file changed

+9
-18
lines changed

1 file changed

+9
-18
lines changed

Diff for: src/libtmux/pane.py

+9-18
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@
2727

2828
@dataclasses.dataclass()
2929
class Pane(Obj):
30-
"""
31-
A :term:`tmux(1)` :term:`Pane` [pane_manual]_.
30+
""":term:`tmux(1)` :term:`Pane` [pane_manual]_.
3231
3332
``Pane`` instances can send commands directly to a pane, or traverse
3433
between linked tmux objects.
@@ -124,8 +123,7 @@ def cmd(self, cmd: str, *args: t.Any, **kwargs: t.Any) -> tmux_cmd:
124123
"""
125124

126125
def resize_pane(self, *args: t.Any, **kwargs: t.Any) -> "Pane":
127-
"""
128-
``$ tmux resize-pane`` of pane and return ``self``.
126+
"""Resize tmux pane.
129127
130128
Parameters
131129
----------
@@ -161,8 +159,7 @@ def capture_pane(
161159
start: t.Union["t.Literal['-']", t.Optional[int]] = None,
162160
end: t.Union["t.Literal['-']", t.Optional[int]] = None,
163161
) -> t.Union[str, t.List[str]]:
164-
"""
165-
Capture text from pane.
162+
"""Capture text from pane.
166163
167164
``$ tmux capture-pane`` to pane.
168165
``$ tmux capture-pane -S -10`` to pane.
@@ -259,8 +256,7 @@ def display_message(self, cmd: str, get_text: "t.Literal[False]") -> None:
259256
def display_message(
260257
self, cmd: str, get_text: bool = False
261258
) -> t.Optional[t.Union[str, t.List[str]]]:
262-
"""
263-
``$ tmux display-message`` to the pane.
259+
"""Display message to pane.
264260
265261
Displays a message in target-client status line.
266262
@@ -286,8 +282,7 @@ def display_message(
286282
"""
287283

288284
def select_pane(self) -> "Pane":
289-
"""
290-
Select pane. Return ``self``.
285+
"""Select pane.
291286
292287
To select a window object asynchrously. If a ``pane`` object exists
293288
and is no longer longer the current window, ``w.select_pane()``
@@ -306,8 +301,7 @@ def split_window(
306301
start_directory: t.Optional[str] = None,
307302
percent: t.Optional[int] = None,
308303
) -> "Pane": # New Pane, not self
309-
"""
310-
Split window at pane and return newly created :class:`Pane`.
304+
"""Split window at pane and return newly created :class:`Pane`.
311305
312306
Parameters
313307
----------
@@ -333,8 +327,7 @@ def split_window(
333327
"""
334328

335329
def set_width(self, width: int) -> "Pane":
336-
"""
337-
Set width of pane.
330+
"""Set pane width.
338331
339332
Parameters
340333
----------
@@ -345,8 +338,7 @@ def set_width(self, width: int) -> "Pane":
345338
return self
346339

347340
def set_height(self, height: int) -> "Pane":
348-
"""
349-
Set height of pane.
341+
"""Set pane height.
350342
351343
Parameters
352344
----------
@@ -357,8 +349,7 @@ def set_height(self, height: int) -> "Pane":
357349
return self
358350

359351
def enter(self) -> "Pane":
360-
"""
361-
Send carriage return to pane.
352+
"""Send carriage return to pane.
362353
363354
``$ tmux send-keys`` send Enter to the pane.
364355
"""

0 commit comments

Comments
 (0)