Skip to content

Instantly share code, notes, and snippets.

<link rel="import" href="../paper-toast/paper-toast.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<polymer-element name="my-element">
<template>
<style>
:host {
<link rel="import" href="../polymer/polymer.html">
<polymer-element name="my-element">
<template>
<style>
:host {
position: absolute;
width: 100%;
height: 100%;
@vicmortelmans
vicmortelmans / get_html.py
Created June 18, 2017 12:54
Python on GAE code for refactoring YQL html table query to lxml xpath query
import cookielib
from lxml import html
import urllib2
def element_to_json(e):
# transform a single element
# returns a tuple tag,content,tail where
# - tag is the name of the element
# - content is a dict with the element's attributes and child elements
@vicmortelmans
vicmortelmans / shortcut-keys.txt
Last active June 1, 2019 20:14
Various shortcut keys for my desktop and applications
ubuntu
xbacklight
system-config-printer
pavucontrol
lxrandr
arandr
blueman-manager
udiskie
udiskie-umount -a
@vicmortelmans
vicmortelmans / assign_parishes.py
Last active May 4, 2018 22:24
QGIS script with as inputs a CRAB address layer and a table defining parishes by address ranges and as output the CRAB layer with parish attribute added
##crab=vector
##parishes=table
##crab_with_parishes=output vector
from qgis.core import *
from PyQt4.QtCore import *
import processing
import re
import csv
import datetime
@vicmortelmans
vicmortelmans / parish-boundaries.model
Last active May 2, 2018 22:51
QGIS model to generate parish borders based on list of addresses
{
"values": {
"inputs": {
"parishes": {
"values": {
"pos": {
"values": {
"y": 369.0,
"x": 351.0
},