Recently a developer friend was wondering why all the built-in App Icons changed colors on his SharePoint 2013 site when he applied a different color scheme using the “Composed Looks” functionality,but Icons for custom apps he had deployed remained their original color. The screenshot below shows the Site Contents page both before (Left Side) and after a Theme has been applied using a Composed Look (Right Side). You can see that all the Icons on the page changed except the last one on the right. This is the App that I installed using the Visual Studio 2012 SharePoint Hosted App project. So the question is Why do all the other Icons change?
The first theory was that the App Icons were being recolored using the Theme CSS support that has been available since SharePoint 2010. But the ability to recolor an image using CSS has always been limited to background images loaded through CSS. These Icons are loaded using an <IMG> element so there is no way to specify the image in CSS and no way to recolor it.
After using IE’s Developer toolbar to examine the HTML and CSS on the pages above I found that the image itself doesn’t get recolored. But the <a> (anchor tag) that surrounds the Icon is a square rectangle occupying the space behind each image that has its background set to one of the theme colors. You can see in the screenshot below that the <a> tag has its background set to a class of “ms-storefront-appiconspan’ which is set to an rgb color from a themable css file. But why does changing the background behind the Icon change the color of the Icon?
The trick is that the Icon file itself is a transparent PNG that is the same size, 90 X 90 pixels, as the anchor tag with the background color behind it. That way the background color shows through the Icon and appears to recolor the icon itself. So let’s see what happens to my Visual Studio project if I replace the blue in my App Icon with a Transparent background. the image below shows the original Icon on the left and the new transparent Icon on the right after I cut the background out using Paint.Net.
After uploading the new Icon image into my visual Studio project and redeploying the custom app you can see that the custom app Icon changes colors along with the Theme in the screenshot below. If you restrict your Icon to white images and text on a transparent background then your Icon should look like it fits no matter what Composed Look is applied to your site.
Last week I presented a talk to the Cleveland SharePoint User’s Group on the new SharePoint 2013 “Apps” model. At the end of the talk I promised to post my slides.
You can download a PDF of the slides from the talk using the link below:
An Introduction to SharePoint 2013 Apps
If you who have been learning to develop the new SharePoint 2013 Apps then you know that the toolset for doing that in Visual Studio 2012 didn’t ship a finished RTM version when SharePoint 2013 shipped its RTM version in November. Instead we’ve all still been working on a Preview 2 version. Well no longer! The final version of Office Developer Tools for Visual Studio shipped today. You can read more about the announcement here:
And more importantly you can download the new tools via web platform Installer from the following URL:
Earlier today Microsoft announced that Office 2013, including SharePoint Server 2013, reached the Release to Manufacturing (RTM) build. That means that coding and testing is complete and work will now commence on getting these products packaged up and into the appropriate distribution channels for customers. YOu can read the full announcement here:
But here are some of the high points and important details covered in the announcement.
- People who purchase Office 2010 after October 19, 2012 will get a free upgrade to Office 2013 when it is released.
- Surface RT tablets will include a preview version of Office 2013 when they ship on October 26th.
- Office 365 customers will begin to see some of the new 2013 capabilities with the next service update in November.
- TechNet and MSDN subscribers should have access to RTM code by mid-November. Which happens to be just after the SharePoint Conference November 12-15, 2012.
I will be speaking at the Cleveland SharePoint User Group on Wednesday, October 24th. The meeting will start at 5:00pm. My topic will be "SharePoint 2013: An Overview of the New Features for IT-Pros”. Here’s a brief description of the talk:
Like every new release the SharePoint 2013 Preview Beta has generated a lot of “buzz” over the last few months. But the important question is, “What’s in it for me and my organization?” In this talk we’ll try to provide an overview, with demos, of the most significant new features for end users and the administrators who manage SharePoint environments. This will not include the new “App” model for developers which will require its own separate discussion. Here are the topics I will cover:
- Search – many of the new features in SharePoint 2013 leverage a new Search engine that incorporates everything Microsoft has learned from its FAST Search acquisition
- Web content management – a new search based page navigation environment that offers better flexibility and control
- Mobile – improvements have been made to how SharePoint is displayed and used on a variety of mobile devices
- Records management – a new eDiscovery process takes records management and compliance to the next level
- Social computing – a more intuitive way to share, follow, and collaborate on information using familiar social networking paradigms
- Upgrade – only the database attach method remains, but there have been significant improvements to the process
You are invited to participate in the Cleveland SharePoint Group! Cleveland’s forum to share and collaborate on SharePoint as an application, development platform, and integration framework.
Cleveland SharePoint Group Presents
Wednesday, October 24th from 5pm – 7pm
Cleveland Microsoft Office at 6050 Oak Tree Blvd.