Solved

ToolBar question

Posted on 2002-07-30
4
167 Views
Last Modified: 2013-11-20
How to create toolbar with non rectangle buttons and different backgrown.
0
Comment
Question by:Nightmare090197
  • 2
4 Comments
 
LVL 8

Expert Comment

by:VinExpert
ID: 7188732
Hi,

Go to the following link.

http://www.codeguru.com/toolbar/index.shtml

U may get some useful samples.
Try it out.
VinExpert
0
 

Author Comment

by:Nightmare090197
ID: 7188759
I have seem that, nothing about my question.
0
 
LVL 8

Accepted Solution

by:
fl0yd earned 200 total points
ID: 7189314
Nightmare,

    There are two parts to your question. Customizing the background to your needs isn't all that hard. All you need to do is override the OnEraseBknd-function. To do so, use the ClassWizard (tm), select the toolbar and doubleclick the WM_ERASEBKGND message. The OnEraseBknd-fxn provides you with the necessary CDC to do all your drawing.

    I don't know how to change the button shape, though. I'm not sure if it is possible at all. All I can give you is a general outline of what you need to do. There are two steps involved. First, you need to retrieve either a CWnd* or a HWND for each button on the toolbar. Once you have that, call the SetWindowRgn to specify the buttons' shapes.

.f
0
 

Author Comment

by:Nightmare090197
ID: 7190831
Thanks for good idea :)
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
bobThere java chalenge 45 94
substring method in java 1 130
format the code in java 6 101
Making an alias 7 101
Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

830 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