Skip to content

Instantly share code, notes, and snippets.

View cyrusdargahi's full-sized avatar
💭
zen mode

Cyrus Dargahi cyrusdargahi

💭
zen mode
View GitHub Profile
@cyrusdargahi
cyrusdargahi / SwitchVirtualDesktop.ahk
Created November 14, 2019 12:13
AutoHotKey Script for switching between virtual desktops in Windows 10
; Globals
DesktopCount = 2 ; Windows starts with 2 desktops at boot
CurrentDesktop = 1 ; Desktop count is 1-indexed (Microsoft numbers them this way)
;
; This function examines the registry to build an accurate list of the current virtual desktops and which one we're currently on.
; Current desktop UUID appears to be in HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\SessionInfo\1\VirtualDesktops
; List of desktops appears to be in HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VirtualDesktops
;
mapDesktopsFromRegistry()
{
@cyrusdargahi
cyrusdargahi / MaterialColor.cs
Last active June 7, 2017 14:42
Material Design Color Palette Colors.xml Resource file for use in C#
/**
* Google Material Design Color Palette for use in C#, http://www.google.com/design/spec/style/color.html#color-ui-color-palette
* Color.xml file used to create this resource - http://bit.ly/mdcolorsxml
* Link to this MaterialColor.cs resource file - https://goo.gl/2x6WgH
*
* Author: Cyrus Dargahi
* https://github.com/cyrusdargahi
*/
using System.Collections.Generic;
using System.Linq;
@cyrusdargahi
cyrusdargahi / colors.xml
Created June 1, 2017 10:27
Material Design Color Palette Colors.xml Resource file for Android
<?xml version="1.0" encoding="utf-8"?>
<!--
Google Material Design Color Palette for Android http://www.google.com/design/spec/style/color.html#color-ui-color-palette
Spreadsheet used to create this reosurce - http://bit.ly/mdcolor_spreadsheet
Link to this colors.xml resource file - http://bit.ly/mdcolorsxml
Harshad Kale
https://github.com/kalehv
-->