Control Messages

The following table describes the graphic button control messages that can be used by a graphic button window procedure to manipulate a graphic button:

┌──────────────────────────────┬──────────────────────────────┐
│Control Message               │Description                   │
├──────────────────────────────┼──────────────────────────────┤
│GBM_SETGRAPHICDATA            │Sets the graphical data       │
│                              │(graphic button text, bitmaps)│
│                              │for a graphic button and      │
│                              │erases all previous data      │
│                              │relating to the state of the  │
│                              │button.                       │
├──────────────────────────────┼──────────────────────────────┤
│GBM_ANIMATE                   │Sets the animation of an      │
│                              │animated graphic button to    │
│                              │start or stop at the first    │
│                              │bitmap in the series or at a  │
│                              │bitmap within the series.     │
├──────────────────────────────┼──────────────────────────────┤
│GBM_QUERYANIMATIONACTIVE      │Gets the animation state of an│
│                              │animated graphic button.      │
├──────────────────────────────┼──────────────────────────────┤
│GBM_SETANIMATIONRATE          │Sets, in milliseconds, the    │
│                              │period between bitmap updates │
│                              │for an animated graphic       │
│                              │button.                       │
├──────────────────────────────┼──────────────────────────────┤
│GBM_QUERYANIMATIONRATE        │Gets the animation rate that  │
│                              │is set for an animated graphic│
│                              │button.                       │
├──────────────────────────────┼──────────────────────────────┤
│GBM_SETSTATE                  │Sets a two-state graphic      │
│                              │button to up or down, or      │
│                              │toggles its state.            │
├──────────────────────────────┼──────────────────────────────┤
│GBM_QUERYSTATE                │Gets the state of a graphic   │
│                              │button.                       │
│                              │Note: For a graphic button    │
│                              │that does not have a two-state│
│                              │style, its state is always    │
│                              │considered to be "up."        │
├──────────────────────────────┼──────────────────────────────┤
│GBM_SETBITMAPINDEX            │Sets the bitmap index to use  │
│                              │for the various states of the │
│                              │graphic button; up, down,     │
│                              │highlighted, not highlighted, │
│                              │beginning of animation series,│
│                              │end of animation series,      │
│                              │current state (refers to      │
│                              │either the up or down bitmap).│
├──────────────────────────────┼──────────────────────────────┤
│GBM_QUERYBITMAPINDEX          │Gets the bitmap index used for│
│                              │a particular button state.    │
├──────────────────────────────┼──────────────────────────────┤
│GBM_SETTEXTPOSITION           │Sets graphic button text      │
│                              │position above or below the   │
│                              │bitmap.                       │
├──────────────────────────────┼──────────────────────────────┤
│GBM_QUERYTEXTPOSITION         │Gets graphic button text      │
│                              │position relative to the      │
│                              │bitmap.                       │
└──────────────────────────────┴──────────────────────────────┘


[Back: Owner Notifications]
[Next: Creating Graphic Buttons]