summaryrefslogtreecommitdiffstats
path: root/modules/codepoints.py
diff options
context:
space:
mode:
authorSean B. Palmer <http://inamidst.com/sbp/>2008-03-10 19:58:28 +0000
committerSean B. Palmer <http://inamidst.com/sbp/>2008-03-10 19:58:28 +0000
commitfb2cd452e963b8bc048161036903cd82d3b113f0 (patch)
tree81182d25fc19f538292b52a9e7c697447d5e6548 /modules/codepoints.py
parent5cad6661c9437832e23469aba2c9f04d94b734ee (diff)
downloadbot-fb2cd452e963b8bc048161036903cd82d3b113f0.tar.gz
bot-fb2cd452e963b8bc048161036903cd82d3b113f0.tar.bz2
bot-fb2cd452e963b8bc048161036903cd82d3b113f0.zip
Some documentation and minor fixes.
Diffstat (limited to 'modules/codepoints.py')
-rwxr-xr-xmodules/codepoints.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/modules/codepoints.py b/modules/codepoints.py
index 89ea078..797fada 100755
--- a/modules/codepoints.py
+++ b/modules/codepoints.py
@@ -65,6 +65,7 @@ def codepoint_extended(arg):
yield about(u, cp, name)
def u(phenny, input):
+ """Look up unicode information."""
arg = input.bytes[3:]
# phenny.msg('#inamidst', '%r' % arg)
if not arg:
@@ -115,11 +116,14 @@ def u(phenny, input):
phenny.reply(' '.join('U+%04X' % ord(c) for c in text))
else: phenny.reply('Sorry, your input is too long!')
u.commands = ['u']
+u.example = '.u 203D'
def bytes(phenny, input):
+ """Show the input as pretty printed bytes."""
b = input.bytes
phenny.reply('%r' % b[b.find(' ') + 1:])
bytes.commands = ['bytes']
+bytes.example = '.bytes \xe3\x8b\xa1'
if __name__ == '__main__':
print __doc__.strip()