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 option to sort cpus #707

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

add option to sort cpus #707

wants to merge 2 commits into from

Conversation

acxz
Copy link

@acxz acxz commented Apr 23, 2022

Description

A description of the change and what it does. If relevant (such as any change that modifies the UI), please provide screenshots of the change:

Sorts the CPU Legend based on highest ranking CPU%.
Note, the colors are attached to the order of the entries rather than the CPUs themselves causing the CPU line graphs to constantly change color. I believe it would be important for this feature to ensure the colors are attached to the entries rather than the order of the entries.

Issue

If applicable, what issue does this address?

From #703 (comment)

sort the CPU core entries by current usage

Testing

If relevant, please state how this was tested. All changes must be tested to work:

Please also indicate which platforms were tested. All platforms directly affected by the change must be tested:

  • Windows
  • macOS
  • Linux

Checklist

If relevant, ensure the following have been met:

  • Areas your change affects have been linted using rustfmt (cargo fmt)
  • The change has been tested and doesn't appear to cause any unintended breakage
  • Documentation has been added/updated if needed (README.md, help menu, etc.)
  • The pull request passes the provided CI pipeline
  • There are no merge conflicts

@acxz acxz changed the title Sort cpu add option to sort cpus Apr 23, 2022
@ClementTsang
Copy link
Owner

Will take a look at this in a bit. Again, feel free to ignore the codecov check, it's fine.

@ClementTsang
Copy link
Owner

Hmm, if I'm understanding this correctly, this is tying the feature behind a flag/option, which is the only way to configure whether it is sorted/not sorted? I was thinking of putting this as a standalone feature into the legend table (similar to how you can sort the process widget), as opposed to having to enable/disable it through a flag/option.

@acxz
Copy link
Author

acxz commented May 4, 2022

I see, that does seem like a better idea.

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

2 participants