|
6 | 6 | #include "util/textModifier.h" |
7 | 7 | #include "util/stringUtils.h" |
8 | 8 |
|
9 | | -void ffPercentAppendBar(FFstrbuf* buffer, double percent, FFPercentConfig config) |
| 9 | +void ffPercentAppendBar(FFstrbuf* buffer, double percent, FFColorRangeConfig config) |
10 | 10 | { |
11 | 11 | uint8_t green = config.green, yellow = config.yellow; |
12 | 12 | assert(green <= 100 && yellow <= 100); |
@@ -75,7 +75,7 @@ void ffPercentAppendBar(FFstrbuf* buffer, double percent, FFPercentConfig config |
75 | 75 | ffStrbufAppendS(buffer, FASTFETCH_TEXT_MODIFIER_RESET); |
76 | 76 | } |
77 | 77 |
|
78 | | -void ffPercentAppendNum(FFstrbuf* buffer, double percent, FFPercentConfig config, bool parentheses) |
| 78 | +void ffPercentAppendNum(FFstrbuf* buffer, double percent, FFColorRangeConfig config, bool parentheses) |
79 | 79 | { |
80 | 80 | uint8_t green = config.green, yellow = config.yellow; |
81 | 81 | assert(green <= 100 && yellow <= 100); |
@@ -126,7 +126,7 @@ void ffPercentAppendNum(FFstrbuf* buffer, double percent, FFPercentConfig config |
126 | 126 | ffStrbufAppendC(buffer, ')'); |
127 | 127 | } |
128 | 128 |
|
129 | | -bool ffPercentParseCommandOptions(const char* key, const char* subkey, const char* value, FFPercentConfig* config) |
| 129 | +bool ffPercentParseCommandOptions(const char* key, const char* subkey, const char* value, FFColorRangeConfig* config) |
130 | 130 | { |
131 | 131 | if (!ffStrStartsWithIgnCase(subkey, "percent-")) |
132 | 132 | return false; |
@@ -160,7 +160,7 @@ bool ffPercentParseCommandOptions(const char* key, const char* subkey, const cha |
160 | 160 | return false; |
161 | 161 | } |
162 | 162 |
|
163 | | -bool ffPercentParseJsonObject(const char* key, yyjson_val* value, FFPercentConfig* config) |
| 163 | +bool ffPercentParseJsonObject(const char* key, yyjson_val* value, FFColorRangeConfig* config) |
164 | 164 | { |
165 | 165 | if (!ffStrEqualsIgnCase(key, "percent")) |
166 | 166 | return false; |
@@ -198,7 +198,7 @@ bool ffPercentParseJsonObject(const char* key, yyjson_val* value, FFPercentConfi |
198 | 198 | return true; |
199 | 199 | } |
200 | 200 |
|
201 | | -void ffPercentGenerateJsonConfig(yyjson_mut_doc* doc, yyjson_mut_val* module, FFPercentConfig defaultConfig, FFPercentConfig config) |
| 201 | +void ffPercentGenerateJsonConfig(yyjson_mut_doc* doc, yyjson_mut_val* module, FFColorRangeConfig defaultConfig, FFColorRangeConfig config) |
202 | 202 | { |
203 | 203 | if (config.green == defaultConfig.green && config.yellow == defaultConfig.yellow) |
204 | 204 | return; |
|
0 commit comments