Unit 'intuition' Package
[Overview][Constants][Types][Procedures and functions][Variables][Index] [#os4units]

DrawImageState

Draw an (extended) Intuition Image with special visual state.

Declaration

Source position: intuition.pas line 3909

procedure DrawImageState(

  Rp: PRastPort;

  Image: PImage;

  LeftOffset: LongInt;

  TopOffset: LongInt;

  State: LongWord;

  const DrawInfo: PDrawInfo

);

Arguments

Rp

  

RastPort for rendering

Image

  

A pointer to a (preferably custom) image

LeftOffset

  

Left positional offsets in pixels

TopOffset

  

Top positional offsets in pixels

State

  

Visual state selected from above

DrawInfo

  

A pointer to packed of pen selections and resolution.

Description

This function draws an Intuition Image structure in a variety of "visual states", these include:

IDS_NORMAL
like DrawImage()
IDS_SELECTED
represents the "selected state" of a Gadget
IDS_DISABLED
the "ghosted state" of a gadget
IDS_BUSY
for future functionality
IDS_INDETERMINATE
for future functionality
IDS_INACTIVENORMAL
for gadgets in window border
IDS_INACTIVESELECTED
for gadgets in window border
IDS_INACTIVEDISABLED
for gadgets in window border

Only IDS_NORMAL will make sense for traditional Image structures, this function is more useful when applied to new custom images or "object-oriented image classes."

Each class of custom images is responsible for documenting which visual states it supports, and you typically want to use images which support the appropriate states with your custom gadgets.

The DrawInfo parameter provides information invaluable to "rendered" images, such as pen color and resolution. Each image class must document whether this parameter is required.

See also

DrawImage

  

Draw the specified Image structure into a RastPort.

GetScreenDrawInfo

  

Get pointer to rendering information.


Documentation generated on: 2021-07-30