Tuesday

Blogging from VIM with source code snipplets

1.In Visual or Normal mode use :TOHtml command to get html representation of source code you have selected .
2.in opened buffer surround text with this div:
<div style="background-color:#103040; overflow:scroll;height:200px"> <font color="#e0eee0">
-- created html code here --
</font></div>
3.root font tag has specific color for my vim-color it's "#e0eee0"
and you will have post with source like that :


using System;

using System.Collections.Generic;

using System.Text;



    public abstract class CustomAttribute : Attribute { }



    public class ExcludeFromToXml : CustomAttribute { }

    public class FoldStorage : CustomAttribute{}

    public class FoldableClass : CustomAttribute { }

    public class Folded : CustomAttribute

    {

        public string IntoProperty;

        public Folded(string intoProperty){

            IntoProperty = intoProperty;

        }

    }



    public class CollectionProperty : CustomAttribute { }



    public class EnumeratedProperty : CustomAttribute

    {

        private Type m_enumType;

        public virtual Type EnumType

        {

            get { return m_enumType; }

        }



        public EnumeratedProperty(Type inEnumType)

        {

            m_enumType = inEnumType;

        }

    }







Read how to post from vim into blogger.com over python API in my next post.

No comments:

imagemagic add text to image

rem different types of text annotations on existing images rem cyan yellow orange gold rem -gravity SouthWest rem draw text and anno...