ttx 0.1.0
Loading...
Searching...
No Matches
ttx::terminal::OSC7 Struct Reference

Represents a application current working directory report. More...

#include <ttx/terminal/escapes/osc_7.h>

Public Member Functions

auto clone () const -> OSC7
 
auto serialize () const -> di::String
 
auto operator== (OSC7 const &other) const -> bool=default
 

Static Public Member Functions

static auto parse (di::TransparentStringView data) -> di::Optional< OSC7 >
 

Public Attributes

di::TransparentString hostname
 
di::Path path
 

Static Public Attributes

static constexpr auto file_scheme = "file://"_tsv
 
static constexpr auto kitty_scheme = "kitty-shell-cwd://"_tsv
 

Friends

constexpr friend auto tag_invoke (di::Tag< di::reflect >, di::InPlaceType< OSC7 >)
 

Detailed Description

Represents a application current working directory report.

This is not specified anywhere, because the spec failed to reach consensus. The format for the escape is OSC 7 ; data ST, where data is a URI. We support the following schemes: file and kitty-shell-cwd. The only difference between these two formats is that the kitty-shell-cwd URI is not percent escaped encoded, making it easy to use from a shell script.

Member Function Documentation

◆ clone()

auto ttx::terminal::OSC7::clone ( ) const -> OSC7
inline

◆ operator==()

auto ttx::terminal::OSC7::operator== ( OSC7 const & other) const -> bool=default
default

◆ parse()

auto ttx::terminal::OSC7::parse ( di::TransparentStringView data) -> di::Optional<OSC7>
static

◆ serialize()

auto ttx::terminal::OSC7::serialize ( ) const -> di::String

Friends And Related Symbol Documentation

◆ tag_invoke

friend auto tag_invoke ( di::Tag< di::reflect > ,
di::InPlaceType< OSC7 >  )
friend

Member Data Documentation

◆ file_scheme

auto ttx::terminal::OSC7::file_scheme = "file://"_tsv
staticconstexpr

◆ hostname

di::TransparentString ttx::terminal::OSC7::hostname

◆ kitty_scheme

auto ttx::terminal::OSC7::kitty_scheme = "kitty-shell-cwd://"_tsv
staticconstexpr

◆ path

di::Path ttx::terminal::OSC7::path

The documentation for this struct was generated from the following files: