Solved

How I can create Icon in Windows 2000?

Posted on 2001-07-08
5
138 Views
Last Modified: 2010-04-06
Hi,

How I can create an transparent icon in Windows 2000 without using graphics unit?

In other word, I'd like to create transparent icon by using WinApi command only.

btw, I use Delphi 5 Std.

Thank you for your help
0
Comment
Question by:linux2000
5 Comments
 
LVL 2

Expert Comment

by:joepezt
Comment Utility
are you talking about buttons with icons in them?. or icons which can be double clicked in windows?

if you use flatbuttons, i guess  you can try

speedbutton1.Glyph.TransparentColor := clWhite;
0
 
LVL 1

Expert Comment

by:alx512
Comment Utility
The CreateIcon function creates an icon that has the specified size, colors, and bit patterns.

HICON CreateIcon(
  HINSTANCE hInstance,    // handle to application instance
  int nWidth,             // icon width
  int nHeight,            // icon height
  BYTE cPlanes,           // number of planes in XOR bitmask
  BYTE cBitsPixel,        // number of BPP in XOR bitmask
  CONST BYTE *lpbANDbits, // AND bitmask
  CONST BYTE *lpbXORbits  // XOR bitmask
);
Parameters
hInstance [in] Handle to the instance of the module creating the icon.
nWidth [in] Specifies the width, in pixels, of the icon.
nHeight[in] Specifies the height, in pixels, of the icon.
cPlanes[in] Specifies the number of planes in the XOR bitmask of the icon.
cBitsPixel [in] Specifies the number of bits-per-pixel in the XOR bitmask of the icon.
lpbANDbits [in] Pointer to an array of bytes that contains the bit values for the AND bitmask of the icon. This bitmask describes a monochrome bitmap.
lpbXORbits [in] Pointer to an array of bytes that contains the bit values for the XOR bitmask of the icon. This bitmask describes a monochrome or device-dependent color bitmap.
0
 

Author Comment

by:linux2000
Comment Utility
Do you know how I can create a transparent icon in Win2000 by using CreateIconIndirect command?

Thank you for your help

 
0
 
LVL 26

Expert Comment

by:Russell Libby
Comment Utility
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

To be PAQ/Refund

Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
Thank you,
Russell

EE Cleanup Volunteer
0
 

Accepted Solution

by:
PashaMod earned 0 total points
Comment Utility
Per recommendation,

PashaMod
Community Support Moderator @Experts Exchange
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Suggested Solutions

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
This video discusses moving either the default database or any database to a new volume.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now