Skip to content

Instantly share code, notes, and snippets.

@iaian
iaian / ctrl + u : Internet Explorer View Source
Last active December 14, 2015 16:58
Autohotkey : if IE is active window map ctrl + u to IE alt+v+c
SetTitleMatchMode, Fast
^u:: ; Hit ctrl+u over IE to show page source
WinGetActiveTitle, MyTitle
If (RegexMatch(MyTitle, "i)(.*)Windows Internet Explorer")) ; If windows internet explorer is found at the end of the window title
{
;run macro for showing source code
Send {Alt}
@iaian
iaian / sublimeText_2-user_prefrences.json
Last active December 15, 2015 13:08
My sublimetext 2 user preferences
{
"auto_complete_commit_on_tab": true,
"color_scheme": "Packages/iaian-theme/solarizedDark-IaianMod.tmTheme",
"detect_slow_plugins": false,
"font_size": 10,
"hot_exit": false,
"ignored_packages":
[
"Vintage",
"Emmet"
@iaian
iaian / sublimeText2_contextMenu.reg
Last active January 15, 2019 15:46
Add SublimeText 2 context menu to windows explorer. If item is folder, context menu has option "open in sublimetext project". If is file, "open in sublime text 2" option is added to context menu. Tested on windows 7
Windows Registry Editor Version 5.00
; This will make it appear when you right click ON a folder
; The "Icon" line can be removed if you don't want the icon to appear
[HKEY_CLASSES_ROOT\Directory\shell\sublime]
@="Open Folder as Sublime Project"
"Icon"="\"C:\\Program Files\\Sublime Text 2\\sublime_text.exe\",0"
[HKEY_CLASSES_ROOT\Directory\shell\sublime\command]
@iaian
iaian / solarizedDark-IaianMod.tmTheme
Created April 1, 2013 17:22
Sublime Text : solarized dark mod ( This makes the selected background color : #FDF6E3 )
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>name</key>
<string>Solarized (dark)</string>
<key>settings</key>
<array>
<dict>
<key>settings</key>
@iaian
iaian / sublime3-pref.json
Last active December 20, 2015 23:29
Sublime text 3 - user prefrences
{
"always_show_minimap_viewport": true,
"auto_complete_commit_on_tab": true,
"auto_complete_with_fields": true,
"color_scheme": "Packages/User/SublimeLinter/solarizedDark-IaianMod (SL).tmTheme",
"folder_exclude_patterns":
[
".svn",
".git",
".hg",
@iaian
iaian / container.css
Created September 25, 2014 17:02
Container css from bootstrap
.container {
margin-right:auto;
margin-left:auto;
padding-left:15px;
padding-right:15px
}
.container:after, .container:before {
content:" ";
display:table
}
@iaian
iaian / getRandomColor.js
Last active August 29, 2015 14:08
GetRandomColor
function get_random_color() {
var letters = '0123456789ABCDEF'.split(''),
color = '#';
for (var i = 0; i < 6; i++ ) {
color += letters[Math.round(Math.random() * 15)];
}
return color;
}
@iaian
iaian / SassMeister-input.scss
Created December 11, 2014 23:59
SRC Wordpress SASS
// ----
// Sass (v3.4.7)
// Compass (v1.0.1)
// ----
#footer-main {
h3 {
text-transform: uppercase;
color: #fff;
}
@iaian
iaian / banks-show-mobile-cart.js
Created April 3, 2015 15:29
banks-show-mobile-cart.js
function showMobileCart() {
var isMobile = $(window).width() < 768 ? true : false,
isNavOpen = $('#mainMenu').hasClass('in');
if (isMobile && !isNavOpen) {
$('.navbar-toggle').click();
setTimeout(function() {
$('#dropDown-cart').click();
}, 400);
}
@iaian
iaian / isWorkday.js
Created May 7, 2015 16:13
isWorkday
function isWorkday() {
var date = new Date,
thisHour = date.getHours();
if (thisHour < 9 || thisHour > 16 ) {
return false;
} else {
return true;
}
}