Merge branch 'aristocratos:main' into main

This commit is contained in:
Jos Dehaes 2021-10-03 22:08:34 +02:00 committed by GitHub
commit 78bce5b5a6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 35 additions and 9 deletions

View file

@ -1,3 +1,13 @@
## v1.0.13
* Changed: Graph empty symbol is now regular whitespace
## v1.0.12
* Fixed: Exception handling for faulty net download/upload speed
* Fixed: Cpu percent formatting if over 10'000
## v1.0.11
* Changed: atomic_wait to use while loop instead of wait() because of rare stall when a signal handler is triggered while waiting

View file

@ -124,7 +124,6 @@ Also needs a UTF8 locale and a font that covers:
* Unicode Block “Braille Patterns” U+2800 - U+28FF (Not needed in TTY mode or with graphs set to type: block or tty.)
* Unicode Block “Geometric Shapes” U+25A0 - U+25FF
* Unicode Block "Box Drawing" and "Block Elements" U+2500 - U+259F
* Unicode Block "General punctuation" U+2005
### **Notice (Text rendering issues)**
@ -208,6 +207,22 @@ Also needs a UTF8 locale and a font that covers:
make help
```
**Binary release (from native os repo)**
* **openSUSE**
* **Add repo**
```bash
sudo zypper ar --refresh obs://home:Werwolf2517 home:Werwolf2517
```
* **Refresh metadata**
```bash
sudo zypper ref
```
* **Install package**
```bash
sudo zypper in btop
```
## Compilation
Needs GCC 10 or higher, (GCC 11 or above strongly recommended for better CPU efficiency in the compiled binary).

View file

@ -55,7 +55,7 @@ namespace Global {
{"#801414", "██████╔╝ ██║ ╚██████╔╝██║ ╚═╝ ╚═╝"},
{"#000000", "╚═════╝ ╚═╝ ╚═════╝ ╚═╝"},
};
const string Version = "1.0.12";
const string Version = "1.0.13";
int coreCount;
string overlay;

View file

@ -43,42 +43,42 @@ namespace Symbols {
const unordered_flat_map<string, vector<string>> graph_symbols = {
{ "braille_up", {
"", "", "", "", "",
" ", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", ""
}},
{"braille_down", {
"", "", "", "", "",
" ", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", ""
}},
{"block_up", {
"", "", "", "", "",
" ", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", ""
}},
{"block_down", {
"", "", "", "", "",
" ", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", ""
}},
{"tty_up", {
"", "", "", "", "",
" ", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", ""
}},
{"tty_down", {
"", "", "", "", "",
" ", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
@ -431,7 +431,7 @@ namespace Draw {
//? Populate the two switching graph vectors and fill empty space if data size < width
for (const int& i : iota(0, height * 2)) {
if (tty_mode and i % 2 != current) continue;
graphs[(i % 2 != 0)].push_back((value_width < width) ? ((height == 1) ? Mv::r(1) : ""s) * (width - value_width) : "");
graphs[(i % 2 != 0)].push_back((value_width < width) ? ((height == 1) ? Mv::r(1) : " "s) * (width - value_width) : "");
}
if (data.size() == 0) return;
this->_create(data, data_offset);
@ -444,6 +444,7 @@ namespace Draw {
if (not tty_mode) current = not current;
for (const int& i : iota(0, height)) {
if (graphs.at(current).at(i).at(1) == '[') graphs.at(current).at(i).erase(0, 4);
else if (graphs.at(current).at(i).at(0) == ' ') graphs.at(current).at(i).erase(0, 1);
else graphs.at(current).at(i).erase(0, 3);
}
this->_create(data, (int)data.size() - 1);