Differences between revisions 3 and 4
Revision 3 as of 2005-10-10 08:58:27
Size: 11839
Editor: 211
Comment:
Revision 4 as of 2005-10-11 08:58:00
Size: 11841
Editor: 211
Comment: text can contain ':'
Deletions are marked like this. Additions are marked like this.
Line 157: Line 157:
        color, text = args.split(':')         color, text = args.split(':',1)

글자에 색깔넣기 매크로

해당 문장에 색을 넣고자 할때 사용한다.

사용법

[[Color(blue:Hello World!)]] or [[Color(#8844aa:Hello World!)]] 

이렇게 하면 그 글자의 색이 바뀌게 된다. ':'을 중심으로 바꾸고자 하는 색, 문장을 기록한다.

색상표

매크로 코드

   1 """macro/Color.py"""
   2 def execute(macro, args):
   3     try:
   4         color, text = args.split(':',1)
   5     except:
   6         return args
   7     return """<font color="%s">%s</font>"""%(color,text)


CategoryMacro

ColorMacro (last edited 2011-08-03 11:00:41 by localhost)

web biohackers.net