Skip to content

Instantly share code, notes, and snippets.

@niftydigits
niftydigits / gist:2204150
Created March 26, 2012 09:27
Output of fc-list
Verdana:style=Regular,Normal,obyčejné,Standard,Κανονικά,Normaali,Normál,Normale,Standaard,Normalny,Обычный,Normálne,Navadno,Arrunta
Liberation Mono:style=Regular
Nimbus Sans L:style=Regular Italic
Times New Roman:style=Regular,Normal,obyčejné,Standard,Κανονικά,Normaali,Normál,Normale,Standaard,Normalny,Обычный,Normálne,Navadno,thường,Arrunta
Webdings:style=Regular
URW Palladio L:style=Roman
Century Schoolbook L:style=Bold Italic
Verdana:style=Bold Italic,Negreta cursiva,tučné kurzíva,fed kursiv,Fett Kursiv,Έντονα Πλάγια,Negrita Cursiva,Lihavoitu Kursivoi,Gras Italique,Félkövér dőlt,Grassetto Corsivo,Vet Cursief,Halvfet Kursiv,Pogrubiona kursywa,Negrito Itálico,Полужирный Курсив,Tučná kurzíva,Fet Kursiv,Kalın İtalik,Krepko poševno,Lodi etzana
Liberation Sans:style=Regular
Georgia:style=Italic,Cursiva,kurzíva,kursiv,Πλάγια,Kursivoitu,Italique,Dőlt,Corsivo,Cursief,Kursywa,Itálico,Курсив,İtalik,Poševno,Etzana
Verdana:style=Regular,Normal,obyčejné,Standard,Κανονικά,Normaali,Normál,Normale,Standaard,Normalny,Обычный,Normálne,Navadno,Arrunta
Liberation Mono:style=Regular
Nimbus Sans L:style=Regular Italic
LMMathSymbols8:style=Regular
LMMathSymbols9:style=Regular
LMMathSymbols6:style=Regular
LMMathSymbols7:style=Regular
LMMathSymbols5:style=Regular
Times New Roman:style=Regular,Normal,obyčejné,Standard,Κανονικά,Normaali,Normál,Normale,Standaard,Normalny,Обычный,Normálne,Navadno,thường,Arrunta
LMMathItalic9:style=Regular
@niftydigits
niftydigits / map
Created February 11, 2012 22:27
CouchDB Map / Reduce for Answers to Straw Poll Questions
function(doc) {
emit(doc.constituency, doc);
}
h1= title
#articles
- each article in articles
div.article
div.created_at= article.created_at
- var articlelink = 'blog/view/' + article._id;
a(href=articlelink)
div.title= article.title
div.body= article.body
div.article
h1= article.title
div.created_at= article.created_at
div.body= article.body
app.get('/blog/view/:id', function(req,res){
articleProvider.findById(req.params.id,
function(error, doc){
res.render('blog_view', {
locals: {
title: 'New Post',
article: doc
}
});
});
var cradle = require('cradle');
ArticleProvider = function(host, port) {
this.connection= new (cradle.Connection)(host, port, {
cache: true,
raw: false
});
this.db = this.connection.database('articles');
};
app.get('/blog/new', function(req,res){
res.render('blog_new', {
locals: {
title: 'New Post'
}
});
});
app.post('/blog/new', function(req,res){
articleProvider.save({
h1= title
form( method= 'post' )
div
div
span Title :
input(type='text', name= 'title', id= 'editArticleTitle' )
div
span Body :
textarea( name= 'body', rows= 20, id= 'editArticleBody' )
div#editArticleSubmit
html
head
title= title
link(rel: 'stylesheet', href: '/style.css' )
body
#wrapper
!= body