This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Config file stores all the commands as csv data | |
configfile=$HOME/.config/zenlauncher/applist.csv | |
configdir=$(dirname $configfile) | |
# Create the config file if it's not existing and add the first command | |
if [ ! -f $configfile ] ; | |
then | |
mkdir -p $configdir |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from random import choice | |
from PIL import Image, ImageDraw | |
from colorlovers import get_top_pallet | |
from draw_shapes import draw_circle | |
scale_factor = 4 # Resize scaling for antialiasing | |
img_size = (1920, 1080) # Final image size desired | |
img_size_scaled = tuple(x*scale_factor for x in img_size) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from random import choice | |
from PIL import Image, ImageDraw | |
from colorlovers import get_top_pallet | |
from draw_shapes import draw_circle | |
scale_factor = 4 # Resize scaling for antialiasing | |
img_size = (1920, 1080) # Final image size desired | |
img_size_scaled = tuple(x*scale_factor for x in img_size) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from xml.etree import ElementTree as et | |
import requests | |
def get_top_pallet(rank): | |
"""Get a top ranked pallete from colorlovers.com | |
Args: | |
rank (int): The rank of the pallet in the website. | |
Starting with 0. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PIL import Image, ImageDraw | |
scale_factor = 4 # Resize scaling for antialiasing | |
img_size = (1920, 1080) # Final image size desired | |
img_size_scaled = tuple(x*scale_factor for x in img_size) | |
img = Image.new("RGB", img_size_scaled) | |
ic = ImageDraw.Draw(img, "RGBA") # Specified RGBA |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PIL import Image, ImageDraw | |
scale_factor = 4 # Resize scaling for antialiasing | |
img_size = (500, 500) # Final image size desired | |
img_size_scaled = tuple(x*scale_factor for x in img_size) | |
img = Image.new("RGB", img_size_scaled) | |
ic = ImageDraw.Draw(img, "RGBA") # Specified RGBA |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from random import randint | |
from PIL import Image, ImageDraw | |
scale_factor = 4 # Resize scaling for antialiasing | |
img_size = (500, 500) # Final image size desired | |
img_size_scaled = tuple(x*scale_factor for x in img_size) | |
img = Image.new("RGB", img_size_scaled) | |
ic = ImageDraw.Draw(img) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PIL import Image, ImageDraw | |
scale_factor = 4 # Resize scaling for antialiasing | |
img_size = (500, 500) # Final image size desired | |
img_size_scaled = tuple(x*scale_factor for x in img_size) | |
img = Image.new("RGB", img_size_scaled) | |
ic = ImageDraw.Draw(img) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PIL import Image, ImageDraw | |
img = Image.new("RGB", (500, 500)) | |
ic = ImageDraw.Draw(img) | |
ic.ellipse([0, 0, 500, 500], fill="RED") | |
img.save("basic.png") |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
NewerOlder