mirror of
https://github.com/Llewellynvdm/conky.git
synced 2025-02-04 21:18:33 +00:00
Added lowercase config to match uppercase
This commit is contained in:
parent
435d05dc6e
commit
1924081173
@ -1077,6 +1077,15 @@
|
|||||||
<listitem>Boolean value, if true, text is rendered in upper case.
|
<listitem>Boolean value, if true, text is rendered in upper case.
|
||||||
<para /></listitem>
|
<para /></listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
<varlistentry>
|
||||||
|
<term>
|
||||||
|
<command>
|
||||||
|
<option>lowercase</option>
|
||||||
|
</command>
|
||||||
|
</term>
|
||||||
|
<listitem>Boolean value, if true, text is rendered in lower case.
|
||||||
|
<para /></listitem>
|
||||||
|
</varlistentry>
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term>
|
<term>
|
||||||
<command>
|
<command>
|
||||||
|
11
src/conky.cc
11
src/conky.cc
@ -283,6 +283,9 @@ std::string current_config;
|
|||||||
static conky::simple_config_setting<bool> stuff_in_uppercase("uppercase", false,
|
static conky::simple_config_setting<bool> stuff_in_uppercase("uppercase", false,
|
||||||
true);
|
true);
|
||||||
|
|
||||||
|
static conky::simple_config_setting<bool> stuff_in_lowercase("lowercase", false,
|
||||||
|
true);
|
||||||
|
|
||||||
/* Run how many times? */
|
/* Run how many times? */
|
||||||
static conky::range_config_setting<unsigned long> total_run_times(
|
static conky::range_config_setting<unsigned long> total_run_times(
|
||||||
"total_run_times", 0, std::numeric_limits<unsigned long>::max(), 0, true);
|
"total_run_times", 0, std::numeric_limits<unsigned long>::max(), 0, true);
|
||||||
@ -794,6 +797,14 @@ static void generate_text() {
|
|||||||
*tmp_p = toupper(static_cast<unsigned char>(*tmp_p));
|
*tmp_p = toupper(static_cast<unsigned char>(*tmp_p));
|
||||||
tmp_p++;
|
tmp_p++;
|
||||||
}
|
}
|
||||||
|
} else if (stuff_in_lowercase.get(*state)) {
|
||||||
|
char *tmp_p;
|
||||||
|
|
||||||
|
tmp_p = text_buffer;
|
||||||
|
while (*tmp_p != 0) {
|
||||||
|
*tmp_p = tolower(static_cast<unsigned char>(*tmp_p));
|
||||||
|
tmp_p++;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
double ui = active_update_interval();
|
double ui = active_update_interval();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user