Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nivalderramas/awesomePalettes
Color Scheme generator for awesomeWM
https://github.com/nivalderramas/awesomePalettes
List: awesomePalettes
Last synced: 4 months ago
JSON representation
Color Scheme generator for awesomeWM
- Host: GitHub
- URL: https://github.com/nivalderramas/awesomePalettes
- Owner: nivalderramas
- Created: 2020-08-22T01:19:42.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-08-29T23:35:43.000Z (over 4 years ago)
- Last Synced: 2024-04-22T14:01:11.160Z (10 months ago)
- Language: Python
- Size: 3.41 MB
- Stars: 6
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-awesomewm-modules-widgets-and-libraries - awesomePalettes
- awesome-awesomewm-modules-widgets-and-libraries - awesomePalettes
README
# Color Scheme Generator for AwesomeWM.
## ScreenShots
![Mountain wallpaper](/screenshots/mountain.png)![Galaxy wallpaper](/screenshots/galaxy.png)
![Nasa Image wallpaper](/screenshots/nasa.png)
## UsageClone this repo under ``` ~/.config/awesome/ ``` and enter into this folder.
Edit the file ``` main.py ``` and pass the wallpaper and theme path that you're gonna use.Then run:
``` python main.py ```
### Optional:
If you don't like the color scheme generated, you always can use the negative colors, changing the last parameter on the function ``` cc.extractColors() ``` from ``` False ``` to ``` True ```As the default ``` theme.lua ``` generates the wallpaper through a function, I do recommend you checking the way in which it sets the wallpaper in the file ``` themeEditor.py ``` to prevent any error.
## Dependencies
```
python > 3.6
PIL (python library)```
## How it works?
### Color Selection:
Here we use a
[K-means clustering](http://google.com)
for finding and selecting the colors from the image and return it sorted in an array.
### Editing the theme:
Actually, it's very simple. Manually we pass the theme's variables to edit, and store it in an array according to it's contrast. For example:
``` theme.bg_normal ```(the bar's color) and ``` theme.fg_normal ``` (the font's color) must contrast, we store ``` theme.bg_normal ``` on the first possition of the array and the ``` theme.bg_normal ``` on the last one.
Then the whole array will be matched with the color's array and the theme file will be edited.