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

Text overlay colours #1781

Merged
merged 4 commits into from
Jul 6, 2021
Merged

Text overlay colours #1781

merged 4 commits into from
Jul 6, 2021

Conversation

dagewa
Copy link
Member

@dagewa dagewa commented Jul 1, 2021

The resolution rings and Miller index text overlays switched between white and black to provide contrast with the image, but the basis vector labels were always black. Fix that by providing a function to choose a suitable text colour and use that in each place.

Also, change to light vs dark grey rather than white vs black. The extremes (white and black) are common for pixels in diffraction images where the contrast is tuned to a narrow part of the full dynamic range. Better to choose a colour that is still visible even against a solid white or black background.

dagewa and others added 3 commits July 1, 2021 19:40
Set this to work for resolution rings, Miller indices and basis
vector labels. Also make the colours just off white and black for
better visibility, as the pixels often have these extreme colours
@codecov
Copy link

codecov bot commented Jul 1, 2021

Codecov Report

Merging #1781 (913661f) into main (211624e) will increase coverage by 0.06%.
The diff coverage is 0.00%.

❗ Current head 913661f differs from pull request most recent head 6d93c34. Consider uploading reports for the commit 6d93c34 to get more accurate results

@@            Coverage Diff             @@
##             main    #1781      +/-   ##
==========================================
+ Coverage   67.23%   67.29%   +0.06%     
==========================================
  Files         616      616              
  Lines       69014    69270     +256     
  Branches     9619     9675      +56     
==========================================
+ Hits        46399    46617     +218     
- Misses      20671    20705      +34     
- Partials     1944     1948       +4     

@ndevenish ndevenish merged commit 51c191c into main Jul 6, 2021
@ndevenish ndevenish deleted the text-overlay-colour branch July 6, 2021 11:25
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

3 participants