Creating 256 color icons/cursors of any color using DevStudio

Environment: VC5, VC6


This short article is a "how to" article describing the process of creating 256 color icons and cursors of any color using nothing but DevStudio.

Back in the Windows 3.x days icons were limited to 16 colors and cursors were limited to monochrome. Starting in Windows95 you could use icons and cursors of 256 colors, but they weren't always that easy to create. DevStudio allows you to create 256 color icons and cursors, but you are forced to use their default palette of pastel colors. The palette entries can not be changed. So if the color you want is not there, then all you can do is find the closest color to it.

Creating your own palette

The key to creating icons and cursors of any color is that you can only edit the palette while working on a bitmap file.

Step 1: First start DevStudio.

Step 2: Create a new bitmap by selecting File | New from the menus. (Bitmaps are under the "Files" tab of the New File Dialog.) It doesn't matter the file name or path, because it's just a temporary file.

Step 3: Turn the bitmap into a 256 color bitmap using the properties dialog. Click on the bitmap then press Alt+Enter. On the "General" tab change the colors to 256.

Step 4: Edit the palette. Switch from the "General" tab to the "Palette" tab. Double-click on any color entry to change the color value.

Step 5: Save the palette by selecting Image | Save Palette from the menus.

Step 6: Close the bitmap and create a new icon or cursor, or open an existing icon or cursor.

Step 7: Load the palette you saved in step 5 by selecting Image | Load Palette from the menus. You now can create or edit your icon/cursor using a palette of up to 256 colors of your choice, not defaults from Microsoft.

Note: if you change the palette on an existing icon/cursor you may have to re-paint all the bits in the image. This is because icons and cursors work like GIFs in that the pixel is actually an index into a color table. Since you changed the palette (which is the color table), the indexes now point to different colors.

To help you get started creating custom 256 color icons and cursors, below you can download a "clean" palette. In this palette the first 16 colors are the standard 16 colors used in Windows. The remaining 240 palette entries are all blank (set to white). You can edit these entries and put whatever color you want in there. To use this clean palette; in between steps 3 and 4 load the palette from the Image menu.


Download a clean palette - 1 Kb


  • Excellent

    Posted by Legacy on 06/05/2003 12:00am

    Originally posted by: Manuel

    Very useful!.

  • Legend!

    Posted by Legacy on 11/12/2002 12:00am

    Originally posted by: Vince Buttigieg

    Wether the author still checks this listing or not, I'd like to thankyou... been trying to find this solution for a while now ;-)

  • Good.

    Posted by Legacy on 08/19/2002 12:00am

    Originally posted by: Nemesis.

    that's great

  • Creating 256 color icons/cursors of any color using DevStudio

    Posted by Legacy on 02/26/2002 12:00am

    Originally posted by: Cory

    Thank you!

    I can know create an interface with some style. This has boogled me for a few days now. Why only 16 colors without needing ActiveX.


Leave a Comment
  • Your email address will not be published. All fields are required.

Top White Papers and Webcasts

  • Anthony Christie, the Chief Marketing Officer for Level Communications, is responsible for customer experience, worldwide marketing and product management. In this informative asset, he shares his insights into why a private network connection to cloud-bases applications is the right decision for your enterprise. Download now to find out more.

  • Enterprises are increasingly looking to platform as a service (PaaS) to lower their costs and speed their time to market for new applications. Developing, deploying, and managing applications in the cloud eliminates the time and expense of managing a physical infrastructure to support them. PaaS offerings must deliver additional long-term benefits, such as a lower total cost of ownership (TCO), rapid scalability, and ease of integration, all while providing robust security and availability. This report …

Most Popular Programming Stories

More for Developers

RSS Feeds

Thanks for your registration, follow us on our social networks to keep up-to-date