Core LibraryAPI Reference

Choose documentation 3

latest

Current version

latest
English

Prerelease This site documents an alpha of libtmux. Its structure, URLs and APIs are subject to change.

C# API

method libtmux-dotnet latest

Server.IsValidLayoutCandidate

Namespace LibTmux.Server.IsValidLayoutCandidate LibTmux

Checks a layout's syntax without contacting a server.

View as Markdown

Source and package
Module
LibTmux
Declared in
Server
Package
LibTmux
Source
src/LibTmux/Server.Layout.cs
IsValidLayoutCandidate ( layout : string , paneCount : int ) → bool
methodstatic [source]

Description#

This is the version-independent half of ValidateLayoutsAsync : it never contacts tmux, so it cannot catch a named layout that only some daemon versions accept. Call it at parse time, before a document is otherwise trusted; call ValidateLayoutsAsync afterward to catch a version-sensitive name.

Parameters
  • layout ( string ) – A custom layout string or a named layout.

  • paneCount ( int ) – The number of panes the layout must accommodate.

Returns

true when the checksum, cell tree and cell count are consistent for a custom layout, or the name is an unambiguous prefix of a named layout.

Esc

Type to search.