IMAGELIST


PLBCMP GUI Only

square.png Properties

square.png Events

square.png Methods

square.png Instructions

 

The IMAGELIST object manages a collection of bitmaps or icons images. IMAGELIST objects can be used with LISTVIEW, TOOLBAR, TREEVIEW, and NETCONTROL objects. To define an IMAGELIST, use one of the following statement formats:

 

(1)

[label]

IMAGELIST

[%]

(2)

[label]

IMAGELIST

(arraysize)

(3)

[label]

IMAGELIST

^

(4)

[label]

IMAGELIST

^,{target}

(5)

[label]

IMAGELIST

^(arraysize)

(6)

[label]

IMAGELIST

^(arraysize),({target}),...,({target})

 

Where:

label

Optional. A Data Label.

%

Optional. Denotes the item as being GLOBAL.

arraysize

Required. An integer decimal constant, CONST variable, or EQUATEd value indicating the number of array items.

^

Optional. Denotes the item as being a POINTER.

target

Required. The name of a previously defined data item of the same type.

Flags Affected: NONE

Note the following:

  1. The images in the list all must be the same size.

  2. A single wide bitmap contains the images within an image list. To reference a specific image in the bitmap, an index of the image within the IMAGELIST must be used.

  3. IMAGELIST objects can be masked or non-masked.

  4. When a resource id is specified for an IMAGELIST object, the image specified by the resource id is segmented and replaces all the images in the IMAGELIST.

  5. Multi-dimension arrays are supported up to a maximum of fourteen dimensions.

  6. The ^ denotes a Pointer Variable.

  7. IMAGELIST objects may not be added to a COLLECTION.

  8. Although an IMAGELIST may be defined as Global, it is DESTROYed during a CHAIN instruction.

  9. IMAGELISTs can be used used as the assigned imagelist for a .NET property.

  10. Support for an IMAGELIST was added to the PL/B Web Server in version 9.9. This PWS IMAGELIST only identifies a single image which can be sent to the client browser in support of the PWS TREEVIEW object. The PWS IMAGELIST is implemented as a virtual object that is created and maintained on the PWS server side. The PWS IMAGELIST implementation details are described as follows:

  11.  

    Supported properties:

     

    Property

    Note

    IMAGESIZEH

    The support for this property was added in 9.9 for the PWS runtime objects. Use of this property for the PLBWIN\PLBNET Windows runtimes causes indeterminate results and should be avoided.

    IMAGESIZEV

    The support for this property was added in 9.9 for the PWS runtime objects. Use of this property for the PLBWIN\PLBNET Windows runtimes causes indeterminate results and should be avoided.

    OBJECTID

     

    RUNNAME

     

    URLSOURCE

    This property is supported only for the PWS runtimes. This property has no affect or impact on the PLBWIN\PLBNET Windows runtimes.

    USERDATA

     

     

    Unsupported properties:

     

    Any settings for unsupported properties are processed and maintained by the PWS IMAGELIST. However, these settings are ignored and do not affect the image being used by a PWS object.

     

    Property

    BGCOLOR

    IMAGECOLORS

    MASKCOLOR

    RESOURCE

    USECOLORMASK

    USEMASK

     

    Supported event:

     

    Event

    CHANGE

     

    Supported Method

     

    Method

    Note

    LoadStdToolBitMap

    This method sets the URLSOURCE property of the IMAGELIST to the 'plbtools.bmp' image name. The 'plbtools.bmp' must exist in the 'c:\sunbelt\plbwebsrv.9xx\http_root' directory where '9xx' represents the PWS version being used.

     

    Unsupported methods:

     

    Method

    AddBmp

    AddBmpMasked

    AddIcon

    AddLoadIcon

    AddLoadImage

    GetImageCount

    Remove

    RemoveAll

    ReplaceBmp

    ReplaceIcon

    WriteBmpFile

     

    PWS IMAGELIST operational behaviors:

     

    1. The PWS IMAGELIST does not simulate the Windows IMAGELIST control. The Windows IMAGELIST control does not provide operation capilities that are compatible with expected client browser image usage.

    2.  

    3. The PWS IMAGELIST support allows an image to be identified the URLSOURCE which can be downloaded by a client browser. Once the image is loaded to the client browser, the PWS JavaScript utilizes techniques to slice the image which can be referenced by image index for PWS objects using the PWS IMAGELIST.

    4.  

    5. Images identified by the PWS IMAGELIST are expected to be a horizontal combination of image segments combined based on the current IMAGESIZEH and IMAGESIZEV values. The format of the PWS IMAGELIST image is the same as exported by the PL/B Designer. The IMAGELIST image index is a value starting with zero representing the image segment at the left-most position in the image.

    6.  

    7. When an embedded PWS IMAGELIST resource is being used by a PWS object in a PWF form, the embedded resource is dynamically generated as a BMP image named with the following format:

    8.  

      I{guid}{resnum}.bmp

      Where:

      {guid}
      The unique GUID identifier assigned to any PLF or PWF when being saved.
      {resnum}
      The PLF\PWF resource number assigned to the imagelist internal resource by the PL/B Designer. This internal resource number is not available to the end-user.
       
    9. The "I{guid}{res}.bmp" image can be downloaded by a client browser as required by a PWS object using the IMAGELIST resource. It should also be noted that only one instance of the 'I{guid}.bmp' is created which can be reused by any PLB PWS object of the PWF form using the IMAGELIST resource. The "I{guid}{res}.bmp" images are never deleted by the PWS runtimes. The end-user can remove any or all of these resource working images at any time without causing any application problems.

    10.  

    11. The behaviors of the PWS IMAGELIST using the URLSOURCE property versus the internal image resource usage for a PWS IMAGELISTcannot be changed and\or invoked using the SETPROP instruction. These behaviors are determined and used when the PWS IMAGELIST is initially created. Use of the SETPROP to change the PWS IMAGELIST URLSOURCE can result in the indeterminate presentation of PWS objects using the IMAGELIST.

 

 

See Also: Example Code, Object Definitions, Object Output Instructions

 



PL/B Language Reference ICON LABELTEXT