# HG changeset patch # User Jeff Hammel # Date 1393202889 28800 # Node ID de314841219106d75c7bba5a3de4275ca6707cc4 # Parent 929a5e97af3edc9fb5c353a11d811c57221703ca STUB: textshaper/commands.py diff -r 929a5e97af3e -r de3148412191 textshaper/commands.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/textshaper/commands.py Sun Feb 23 16:48:09 2014 -0800 @@ -0,0 +1,23 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +""" +CLI commands for textshaper +""" + +class Shaper(object): + """individual text shaper component""" + + def __init__(self, function): + self.function = function + +class Commands(object): + + def __init__(self): + self.shapers = [] + self.keys = {} + + def add(self, function, key=None): + self.shapers.append(Shaper(function)) + if key: + self.keys[key] = self.shapers[-1]