colors
Version, currently master branch1 version
- master branchlatestJan 26, 2024
github.com/kalinon/colors-and-gradients
A library focused on working with colors and gradients.
0 stars
0 dependents
License: MIT
Installation
# Add this to your shard.yml
dependencies:
colors:
github: kalinon/colors-and-gradients
branch: mastermaster is a branch, not a release, so this tracks it rather than pinning a version.
Then run:
shards installshard.yml
- Crystal
0.25.1- License
- MIT
- Author
- D. Scott Boggs
Dependencies
This version declares no dependencies.
README
colors and gradients
This is a library focused on working with colors and gradients. At this stage it allows you to create an RGB gradient.
Installation
Add this to your application's shard.yml:
dependencies:
colors:
github: dscottboggs/colors-and-gradients
Usage
require "colors"
include Colors
red = Color.red
green = Color.new red: 0, green: 0xFF, blue: 0
gray = Color.gray 0x55
color_based_on_percent = Gradient.new :red, :green, 100
color = color_based_on_percent[50] # => Color red: 127, green: 127, blue: 0
color.to_s # => "#7F7F00"
Development
It's crystal, just check out the repo.
Contributing
- Fork it (https://github.com/dscottboggs/colors/fork)
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create a new Pull Request
Contributors
- dscottboggs D. Scott Boggs - creator, maintainer
Documentation
Built from the current release. The first visit to a release nobody has asked for starts its build.
Links
This branch
- Branch
master- Seen
- Jan 26, 2024
- Crystal
0.25.1- Indexed
- yes
Dependents
No indexed shard depends on this one yet.
Repository
github.com/kalinon/colors-and-gradients
Metadata
- Created
- Aug 16, 2026
- Updated
- Aug 16, 2026
- Synced
- Aug 16, 2026
- Versions
- 1