You can check out the following link for designing Stylable controls,
http://msdn2.microsoft.com/en-us/library/ms752339.aspx