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/sh | |
# Install this file as: | |
# /usr/lib/pm-utils/sleep.d/95thinkpad_touchpad | |
# and sudo chmod +x it. | |
case "$1" in | |
resume) | |
modprobe -r psmouse | |
modprobe psmouse |
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
# 52-thinkpad.conf | |
# This is a X11 configuration file that tunes up the synaptics touchpad using the | |
# synaptics libinput driver, I made this recopilating settings from different sources. | |
# Tested in elementaryOS 5.1 | |
# Install HWE synaptics driver for Ubuntu 18.04.3+ | |
# sudo apt install xserver-xorg-input-synaptics-hwe-18.04 | |
# Install this file in: | |
# /usr/share/X11/xorg.conf.d/52-thinkpad.conf |
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 | |
def add_whitespaces(image, max_size): | |
""" | |
Adds white spaces until the image reaches the desired max_size. | |
Forked from: https://gist.github.com/fabeat/6621507 | |
:param image: Image | |
:param max_size: [ W , H ] | |
:return: Image |