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

feature: support custom widget borders #1642

Merged
merged 8 commits into from
Dec 5, 2024
Merged

Conversation

ClementTsang
Copy link
Owner

@ClementTsang ClementTsang commented Dec 5, 2024

Description

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

Support setting custom border types. This doesn't support "no" borders for now, since I need to come up with a nice way of making it look good - I'll likely incorporate #1470 as the closest thing.

Examples

Normal:
image
image

Rounded corners:

image
image

Double lines:

image
image

Thick:
image
image

Issue

If applicable, what issue does this address?

Closes: #

Testing

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

If this is a code change, please also indicate which platforms were 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, doc pages, etc.)
  • The pull request passes the provided CI pipeline
  • There are no merge conflicts
  • If relevant, new tests were added (don't worry too much about coverage)

@ClementTsang ClementTsang marked this pull request as ready for review December 5, 2024 06:42
Copy link

codecov bot commented Dec 5, 2024

Codecov Report

Attention: Patch coverage is 28.07571% with 228 lines in your changes missing coverage. Please review.

Project coverage is 42.07%. Comparing base (1fe17dd) to head (ca39bde).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
src/canvas/widgets/process_table.rs 0.00% 36 Missing ⚠️
src/canvas/widgets/battery_display.rs 16.66% 35 Missing ⚠️
src/canvas/components/data_table/draw.rs 0.00% 24 Missing ⚠️
src/options/config/style/borders.rs 0.00% 21 Missing ⚠️
src/canvas/dialogs/dd_dialog.rs 0.00% 18 Missing ⚠️
src/canvas/widgets/network_graph.rs 0.00% 18 Missing ⚠️
src/canvas/widgets/mem_basic.rs 0.00% 11 Missing ⚠️
src/canvas/drawing_utils.rs 47.36% 10 Missing ⚠️
src/canvas/dialogs/help_dialog.rs 0.00% 9 Missing ⚠️
src/canvas/widgets/mem_graph.rs 0.00% 9 Missing ⚠️
... and 9 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1642      +/-   ##
==========================================
+ Coverage   42.03%   42.07%   +0.04%     
==========================================
  Files         116      117       +1     
  Lines       17625    17569      -56     
==========================================
- Hits         7409     7393      -16     
+ Misses      10216    10176      -40     
Flag Coverage Δ
macos-14 37.39% <18.92%> (-0.07%) ⬇️
ubuntu-latest 43.87% <28.07%> (+0.05%) ⬆️
windows-2019 37.32% <18.98%> (-0.07%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ClementTsang ClementTsang enabled auto-merge (squash) December 5, 2024 06:49
@ClementTsang ClementTsang merged commit 0d182e4 into main Dec 5, 2024
37 checks passed
@ClementTsang ClementTsang deleted the border_type_configuration branch December 5, 2024 06:52
ClementTsang added a commit that referenced this pull request Dec 5, 2024
ClementTsang added a commit that referenced this pull request Dec 5, 2024
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.

1 participant