glyph vs component, functions as replacements, actual regular expressions

Match regular expressions (the docs already say these should work), not just strings.
Allow for functions as the heads of patterns not just symbols.
Make the documentation more accurate about component vs glyph.