Download Menu Button control

Menu Button control

Menu Button control 1.0

License :
Freeware
File Size :
5KB
Language :
English
Publisher :
viksoe.dk
Last Updated :
2008-12-22
OS Support :
Windows XP, 98
Downloads :
Total : 1 , Last Week : 1
Free Download
Get a faster PC in 3 easy steps

Publisher's Description

“A menu button control. Ownerdrawn button painting.”

By viksoe.dk about Menu Button control

This is a Menu Button control. Menu Button controls are not rocket-science, but this control is also a demonstration on how to draw an ownerdrawn button in both Windows 98 and Windows XP.
The control displays itself as a regular button, except that it has a Glyph (a Little arrow) on the right signalling that it displays something when you click it. All it does is to display a popup menu. The popup menu is custom drawn because I wanted to be able to add colourful icons to it. The button is also ownerdrawn because it needs to Paint the dropdown-glyph on the right.
The problem with ownerdrawn buttons is that on Windows XP and greater we need to paint it with the current theme. Before Windows XP it was simply a matter of using the BS_OWNERDRAWN style. Unfortunately this also meant that we had to repaint the entire button exterior as well. Since a button always behaved the same, we could use the DrawFrameControl() API to do much of the drawing.
Along came Windows XP and changed all that. The DrawFrameControl() no longer works and we'll have to dip into the Theme API to get the job done. Well, not quite... because the old Windows Common Controls ListView and TreeView introduced a new ownerdraw method: the NM_CUSTOMDRAW notifications. And in Windows XP the Button control inherits this behaviour too (as well as supporting the old WM_DRAWITEM-range of messages).
The trick to drawing an ownerdraw button under Windows XP is not to draw the button at all.
The Button sends WM_NOTIFY / NM_CUSTOMDRAW notifications to the parent. If we wanted to drastically change the look of the button, we would start to custom paint here but since we just want to add an icon and some visual decorations, we'll answer the notification with the CDRF_NOTIFYPOSTPAINT code. This instructs Windows to paint the button entirely. When done, Windows calls us again with NM_CUSTOMDRAW and allows us to paint on top of the button image.
System Requirements :
(Not available)
Recent changes :
(Not available)

Menu Button control Screenshots

Currently no screenshot.

Similar to Menu Button control

Compare++
Structured compare and merge code, files and folders, detect function changes....
VBBubble
Add multiline and text alignment support to your VB tooltips...

Menu Button control Review and rate

  • Review and rate
  • Just rate
    • Review needs to contain at least 100 characters ,current 0 characters

    • One item per line.

    • One item per line.

    • Minimum 4 maximum 20 characters

    • Please enter a valid email address to receive our confirmation email.

      We will not show your email address to public.

    Your rating of Menu Button control :

    Please fill in all fields

    • Usability:

    • Stability:

    • Installation:

    • Functionality:

    • Appearance:

    Click here to refresh
You are not allowed to share serial numbers, cracks, etc. or link to pages that contain them. If you do, your user account will be deleted, your IP address logged and legal action will be taken.
User Rating
0/5

Click the stars to rate

( 0 rating , 0 review )
A FREE client from Apponic.com
  • Keep your apps up to date
  • Plus choice for installed apps
  • Newest and most popular apps
  • Essential apps
Review Source Code Editors
  • Top Reviewed
  • New Reviewed
Searches Related to Menu Button control

ownerdrawn menu |

Source Code Editors Essential Downloads
Go Left Go Right
  • Notepad++

    Notepad++ is a free source code editor.

  • NetBeans IDE

    Fully-featured Java IDE written completely in Java, with many modules available.

  • Eclipse Classic (64-bit)

    Eclipse Classic is the most recent release from the Eclipse top-level project. It contains what you need to build applications based on Eclipse technology, including integrated development environment...

  • Eclipse Classic

    Complete environment for Java.

  • ArgoUML

    ArgoUML is the leading open source UML modeling tool.

  • TopStyle

    TopStyle contains powerful tools for building standards-compliant web sites.

  • UEStudio

    Offers all the functionality of UltraEdit plus other features.

  • UltraCompare

    Offer features to compare text files and folders.

  • UltraEdit

    Powerful Text, HEX, HTML, PHP and Programmer's Editor