Fcitx
Public Types | Public Member Functions | List of all members
fcitx::RegexConstrain Class Reference

String constrain that requires the value to be a valid regular expression. More...

#include <fcitx-config/option.h>

Public Types

using Type = std::string
 

Public Member Functions

bool check (const std::string &value) const
 
void dumpDescription (RawConfig &config) const
 

Detailed Description

String constrain that requires the value to be a valid regular expression.

Use it directly on a String option, or wrapped in ListConstrain for a list of regular expressions. Frontends that understand the IsRegex marker can validate the value before saving, while other frontends simply treat it as a plain string and rely on this constrain to reject invalid values on save.

Definition at line 227 of file option.h.


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