Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ramp-padding capabilities to module/cpu #1472

Merged
merged 6 commits into from Oct 15, 2018

Conversation

theryangeary
Copy link
Contributor

Fixes #1389
Allows "ramp-padding" in polybar config file to adjust spacing between core loads.

memeplex and others added 5 commits July 30, 2018 08:36
This makes polybar play nice with the i3wm feature `workspace_auto_back_and_forth`, and it is harmless when that option isn't set.
Changelog

Fixes:
* fix(ramp): Evenly distribute states (polybar#1340), see polybar#1328
* fix(i3): Play nice with workspace_auto_back_and_forth (polybar#1312)
* fix(controller): don't draw window if writing to stdout (polybar#1322), see polybar#1314
Copy link
Member

@patrick96 patrick96 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your efforts.

@@ -18,6 +18,8 @@ namespace modules {
cpu_module::cpu_module(const bar_settings& bar, string name_) : timer_module<cpu_module>(bar, move(name_)) {
m_interval = m_conf.get<decltype(m_interval)>(name(), "interval", 1s);

m_ramp_padding = m_conf.get<decltype(m_ramp_padding)>(name(), "ramp-padding");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the PR we discussed naming it ramp-coreload-spacing, which also makes more sense, since it only affects the coreload ramp and not the other ramps.

Should also have a default value of 1.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll get right on that! Sorry I missed it the first time.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No worries.

@patrick96 patrick96 changed the base branch from 3.2 to master October 15, 2018 22:52
Copy link
Member

@patrick96 patrick96 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome. Thank you very much!

I had to change the base branch to master because we only merge new stuff into master not into release branches

@patrick96 patrick96 changed the base branch from master to 3.2 October 15, 2018 22:57
@patrick96 patrick96 changed the base branch from 3.2 to master October 15, 2018 22:57
@codecov-io
Copy link

Codecov Report

Merging #1472 into master will decrease coverage by <.01%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #1472      +/-   ##
=========================================
- Coverage    5.78%   5.78%   -0.01%     
=========================================
  Files         162     162              
  Lines        9030    9031       +1     
=========================================
  Hits          522     522              
- Misses       8508    8509       +1
Flag Coverage Δ
#unittests 5.78% <0%> (-0.01%) ⬇️
Impacted Files Coverage Δ
include/modules/cpu.hpp 0% <ø> (ø) ⬆️
src/components/controller.cpp 0.27% <0%> (ø) ⬆️
src/modules/i3.cpp 0.66% <0%> (ø) ⬆️
src/modules/cpu.cpp 1.14% <0%> (-0.02%) ⬇️
src/drawtypes/ramp.cpp 4.34% <0%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update abdd5f9...d8c3867. Read the comment docs.

@patrick96 patrick96 merged commit 06adef1 into polybar:master Oct 15, 2018
patrick96 added a commit that referenced this pull request Oct 15, 2018
patrick96 added a commit that referenced this pull request Oct 15, 2018
@patrick96
Copy link
Member

Oh damn. Because you originally created a PR against the 3.2 branch, it contained a commit that was exclusive to that branch (3.2.1 release commit) and we don't actually want that in master. Will manually add your commits to a new PR.

@theryangeary
Copy link
Contributor Author

So is there anything else I need to do resolve that or is it taken care of?

patrick96 added a commit that referenced this pull request Oct 15, 2018
@patrick96
Copy link
Member

No, everything is taken care of. I have taken the commits you made and applied them to the master branch and openened a PR for that.

patrick96 pushed a commit to patrick96/polybar that referenced this pull request Nov 17, 2018
patrick96 added a commit to patrick96/polybar that referenced this pull request Nov 17, 2018
patrick96 added a commit to patrick96/polybar that referenced this pull request Nov 17, 2018
patrick96 added a commit that referenced this pull request Dec 23, 2018
### Breaking Changes:
None

### Changelog

**New Config Options**
The following config options were added

In the `[settings]` section:
* `pseudo-transparency`

In `internal/cpu`:
* `ramp-coreload-spacing`, spacing between elements in `<ramp-coreload>` elements
* `%percentage-sum%` in `label`. Shows sum of all percentages

In `custom/script`:
* `double-click-left`
* `double-click-middle`
* `double-click-right`

In `internal/pulseaudio`:
* `interval`, volume increase and decrease steps in percentage points

In `internal/memory`:
* `bar-swap-used`
* `bar-swap-free`
* `ramp-swap-used`
* `ramp-swap-free`

**Deprecations**
* `tray-transparent` in the bar section is no longer used. The tray now always uses pseudo-transparency

**Features**
* volume: adjustable volume steps (#1364), see #1361
* memory: Add progress bars and ramps for swap (#1325)
* render: pseudo-transparency (always used in the tray)  (#595)
* cpu: 
    * Configurable spacing in between coreloads (#1472), see #1389
    * Non-normalized cpu load (#1517), see #1516
* script: Double click actions (#1442)
* net: Support for bridge interfaces (#1528), see #1522
* token: zero pad tokens when min-width value starts with a `0` (#1341), see #1332

**Fixes**
* config: Use font patterns detected on system in sample config (#1350)
* net: Disconnected module when SSID is only an emoji (#1371), see #1367
* tray: Tray overlapping with bar (#1392), see #591
* build: Several build errors (#1395, #1454, #1470, polybar/xpp#12, #1493), see #1447, #1469, #750, #1492
* mpd: format-online-prefix not working (#1402), see #1399
* font: Crash for some font-patterns (#1451), see #1435
* script: 
    * Only `%counter%` or `%pid%` token usable, never both (#1456)
    * click actions with colons in them (#1457), see #984
* renderer: Bar locks up when xorg composite extension is disabled (#1430), see #1425
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants