aboutsummaryrefslogtreecommitdiff
path: root/src/toolkit.py
diff options
context:
space:
mode:
authortassaron2017-07-16 14:06:11 -0400
committertassaron2017-07-16 14:06:11 -0400
commitec0abd190273b7b636c7085d7caed8220ab09172 (patch)
treee29097e79504a1f03feda28483dd18acbeb09587 /src/toolkit.py
parent17c8a6703a8093d31c6772ba3b8d9ee01adaa0da (diff)
apply complex filters to audio streams from components
tons of sound options could be given now, + installation using setup.py
Diffstat (limited to 'src/toolkit.py')
-rw-r--r--src/toolkit.py11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/toolkit.py b/src/toolkit.py
index 589d8e6..5493f37 100644
--- a/src/toolkit.py
+++ b/src/toolkit.py
@@ -13,11 +13,14 @@ def badName(name):
return any([letter in string.punctuation for letter in name])
+def alphabetizeDict(dictionary):
+ '''Alphabetizes a dict into OrderedDict '''
+ return OrderedDict(sorted(dictionary.items(), key=lambda t: t[0]))
+
+
def presetToString(dictionary):
- '''Alphabetizes a dict into OrderedDict & returns string repr'''
- return repr(
- OrderedDict(sorted(dictionary.items(), key=lambda t: t[0]))
- )
+ '''Returns string repr of a preset'''
+ return repr(alphabetizeDict(dictionary))
def presetFromString(string):