TryParse(string, Style) Method

Converts the string representation of a style to its Style equivalent. A return value indicates whether the operation succeeded.
public static bool TryParse(string text, out Style result)
Namespace
Spectre.Console
Containing Type
Style

Parameters

string text
A string containing a style to parse.
Style result
When this method returns, contains the Style equivalent of the text contained in text, if the conversion succeeded, or null if the conversion failed.

Returns

bool