Skip to content

Instantly share code, notes, and snippets.

@shiweifu
Created April 28, 2013 01:52
Show Gist options
  • Save shiweifu/5475507 to your computer and use it in GitHub Desktop.
Save shiweifu/5475507 to your computer and use it in GitHub Desktop.
split_page
var mySheet = document.styleSheets[0];
function addCSSRule(selector, newRule) {if (mySheet.addRule) {mySheet.addRule(selector, newRule);} else {ruleIndex = mySheet.cssRules.length;mySheet.insertRule(selector + '{' + newRule + ';}', ruleIndex);}}
addCSSRule('html', 'padding: 10px; height: 528.000000px; -webkit-column-gap: 20px; -webkit-column-width: 300.000000px;')
addCSSRule('p', 'text-align: justify;')
addCSSRule('body', '-webkit-text-size-adjust: 100%;')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment