Merge pull request #149 from ClementTsang/autohide_time_on_small

Autohide time on small
This commit is contained in:
Clement Tsang
2020-05-09 15:28:39 -04:00
committed by GitHub
5 changed files with 29 additions and 1 deletions
+21 -1
View File
@@ -9,7 +9,27 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Features
- [#114](https://github.com/ClementTsang/bottom/pull/114): Process state per process (originally in 0.4.0, moved to later).
- ~~[#114](https://github.com/ClementTsang/bottom/pull/114): Process state per process (originally in 0.4.0, moved to later).~~
- Moving down the CPU list will show only the corresponding graph.
### Changes
- Automatically hide time axis labels if the window gets too small.
### Bug Fixes
- The `<Space>` character can be used as an "AND" again (properly) in queries. For example:
```bash
(btm cpu > 0) (discord mem > 0)
```
is equivalent to:
```bash
(btm AND cpu > 0) AND (discord AND mem > 0)
```
## [0.4.1] - 2020-05-05
+2
View File
@@ -555,3 +555,5 @@ Thanks to all contributors ([emoji key](https://allcontributors.org/docs/en/emoj
- This application was written with many, _many_ libraries, and built on the
work of many talented people. This application would be impossible
without their work.
- And of course, thanks to all contributors!
+2
View File
@@ -123,6 +123,8 @@ impl CpuGraphWidget for Painter {
cpu_widget_state.autohide_timer = None;
Axis::default().bounds([-(cpu_widget_state.current_display_time as f64), 0.0])
}
} else if draw_loc.height < 7 {
Axis::default().bounds([-(cpu_widget_state.current_display_time as f64), 0.0])
} else {
Axis::default()
.bounds([-(cpu_widget_state.current_display_time as f64), 0.0])
+2
View File
@@ -44,6 +44,8 @@ impl MemGraphWidget for Painter {
mem_widget_state.autohide_timer = None;
Axis::default().bounds([-(mem_widget_state.current_display_time as f64), 0.0])
}
} else if draw_loc.height < 7 {
Axis::default().bounds([-(mem_widget_state.current_display_time as f64), 0.0])
} else {
Axis::default()
.bounds([-(mem_widget_state.current_display_time as f64), 0.0])
+2
View File
@@ -94,6 +94,8 @@ impl NetworkGraphWidget for Painter {
Axis::default()
.bounds([-(network_widget_state.current_display_time as f64), 0.0])
}
} else if draw_loc.height < 7 {
Axis::default().bounds([-(network_widget_state.current_display_time as f64), 0.0])
} else {
Axis::default()
.bounds([-(network_widget_state.current_display_time as f64), 0.0])