Hermes 0.7.0
Linux game streaming host
Loading...
Searching...
No Matches
window_placement.h File Reference

Identify supported launch commands and build scoped KWin placement scripts. More...

#include <algorithm>
#include <cctype>
#include <cstdint>
#include <filesystem>
#include <string>
#include <string_view>
#include <vector>
Include dependency graph for window_placement.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

bool platf::window_placement::names_program (const std::vector< std::string > &arguments, std::string_view program)
bool platf::window_placement::opens_big_picture (const std::vector< std::string > &arguments)
bool platf::window_placement::launches_gamescope (const std::vector< std::string > &arguments)
bool platf::window_placement::gamescope_runs_steam (const std::vector< std::string > &arguments)
bool platf::window_placement::launches_steam (const std::vector< std::string > &arguments)
std::string platf::window_placement::kwin_script (const std::string &output, const std::vector< std::string > &classes, const std::vector< std::uint32_t > &gamescope_pids)

Detailed Description

Identify supported launch commands and build scoped KWin placement scripts.

Definition in file window_placement.h.

Function Documentation

◆ gamescope_runs_steam()

bool platf::window_placement::gamescope_runs_steam ( const std::vector< std::string > & arguments)
inline

Whether the command starts a Gamescope whose own client is Steam: the shipped launcher, which always runs steam -bigpicture, or a gamescope command that names steam.

Steam runs once per user. A Steam started inside a new Gamescope while another one is running hands its request to that one and exits, and Gamescope exits with it.

Definition at line 49 of file window_placement.h.

◆ kwin_script()

std::string platf::window_placement::kwin_script ( const std::string & output,
const std::vector< std::string > & classes,
const std::vector< std::uint32_t > & gamescope_pids )
inline

Definition at line 74 of file window_placement.h.

◆ launches_gamescope()

bool platf::window_placement::launches_gamescope ( const std::vector< std::string > & arguments)
inline

Definition at line 36 of file window_placement.h.

◆ launches_steam()

bool platf::window_placement::launches_steam ( const std::vector< std::string > & arguments)
inline

Whether a command starts Steam: steam itself (also behind a wrapper such as setsid), the Flatpak, a steam:// link, which the running Steam handles, or a Gamescope whose own client is Steam, the shipped launcher included: its steam -bigpicture is in a script, not the command.

Definition at line 65 of file window_placement.h.

◆ names_program()

bool platf::window_placement::names_program ( const std::vector< std::string > & arguments,
std::string_view program )
inline

Definition at line 20 of file window_placement.h.

◆ opens_big_picture()

bool platf::window_placement::opens_big_picture ( const std::vector< std::string > & arguments)
inline

Definition at line 26 of file window_placement.h.