Skip to content

Instantly share code, notes, and snippets.

@zlrc
zlrc / nextwallpaper.ahk
Last active September 1, 2024 21:47
An AutoHotkey v2 script for Windows 10 that advances a wallpaper slideshow to the next background. This automates right-clicking the desktop and selecting "Next desktop background" from the context menu.
; This script advances the wallpaper slideshow to the next image. Requires AutoHotkey v2.
; Author: Mike "ZiRC" K. (https://github.com/zlrc)
; License: CC0 (https://creativecommons.org/publicdomain/zero/1.0/)
;
; Relevant AutoHotkey Documentation:
; - ComObject: https://www.autohotkey.com/docs/v2/lib/ComObject.htm
; - ComValue: https://www.autohotkey.com/docs/v2/lib/ComValue.htm
; - ComCall: https://www.autohotkey.com/docs/v2/lib/ComCall.htm
; - DllCall: https://www.autohotkey.com/docs/v2/lib/DllCall.htm
@drewbaker
drewbaker / functions.php
Created January 29, 2016 18:24
Blurring image using WordPress
/**
* Several functions relatting to blurring images on uploaded.
* @see https://codeable.io/community/how-to-watermark-wordpress-images-with-imagemagick/
*/
add_image_size( 'background-image-blurred', 1920, 1080, true );
function generate_blurred_image( $meta ) {
$time = substr( $meta['file'], 0, 7); // Extract the date in form "2015/04"
$upload_dir = wp_upload_dir( $time ); // Get the "proper" upload dir