Summary : Create Custom Theme in SharePoint 2013 (Step-by-Step Tutorial), Create Theme in SharePoint 2013, Create new Composed look, SPColor.xml, SPFont.xml in SharePoint,Create Custom Theme in SharePoint 2013 – Step-by-Step Tutorial
In SharePoint 2013, the theming engine was highly improved. You can Create Custom Themes by Creating Color palettes and Font Schemes, and uploading them to the Themes Gallery.
Themes in SharePoint 2013 are defined two XML files:
- SPColor.xml – defines the color palette, in which slots now have semantic names so that it’s more clear what UI elements will be affected when you change a color value. Also, themes now support setting opacity.
- SPFont.xml – defines the font scheme and supports multiple languages, web-safe fonts, and web fonts.
How it Works – The Theming model uses Comment-style markup in the CSS and then replaces parts of the CSS based on parameters such as fonts and color schemes that users select.
Theme Gallery – Theme Gallery Contains the list of Color Palettes and Font Schemes that are make up Themes in SharePoint 2013. SharePoint looks in the 15 folder (/_catalogs/theme/15/) to determine the available Color palettes and Font schemes.
To access the Theme Gallery navigate to Site Settings -> under Web Designer Galleries -> Themes.
Composed Look – A Composed Look is a List where Structure and Components of a Theme are defined.You can define the following for a Theme –
- Color palette
- Font Scheme
- Background Image
- Master Page
Theme Gallery VS Composed Look – Theme Gallery Contains Core files that make a Theme – SPColor.xml and SPFont.xml whereas Composed look Contains Links to these files in a structured way.
How to Create a new Theme – To Create a new Theme, you would need to Create Copies of SPColor, SPFont, Master Page and Image files and Create a new Composed Look with references to these files. Lets look the Steps to Create a Custom theme in SharePoint 2013 –
Open this SPColor file in SharePoint 2013 Designer or in a Notepad.
3. In the Notepad Change the Values or Colors for the Site Name Properties. We modified the WebPartHeading & PageBackground properties highlighted below.
4. Once modified re-name the file and Upload in the “Themes” folder.
5. Next register a new Theme in Composed Look. Navigate to Site Settings -> under Web Designer Galleries -> Composed Looks. Click new Item to create a new Composed Look.
6. In your new Composed Look Page you would add the following –
- Name: the name of your composed look;
- Master page: the master page that you want to use;
- Theme URL: the URL to your color palette;
- Image URL: the URL to your background image;
- Font Scheme URL: the URL to your font scheme;
- Display Order: this will be used to arrange your composed looks ordering.
7. Once done, Navigate to “Change a Look” at Site Settings -> under Look and Feel -> Change a Look and select the newly Created Theme “Custom Theme” (it was on the 2nd Page)
Migrating Themes from SharePoint 2010 – SharePoint 2013 does not support “THMX” Themes that are Created in SharePoint 2010. If you are looking to migrate a Custom Theme from SharePoint 2010 to SharePoint 2013, you would have to re-design the Theme with new structure, defined by XML files – SPColor.xml and SPFont.xml and then apply to the new SharePoint 2013 site.
Please Note – The Custom theme from SharePoint 2010 after upgrade will remain in place but the theme will no longer be applied to the site, and the site reverts to the default theme.
Original article : Here