Home  /  Autodocs  /  ListBrowser.gadget

NAME

AllocLBColumnInfoA
Allocate column info array. (V45)

SYNOPSIS

struct ColumnInfo *AllocLBColumnInfoA(UWORD cols,
struct TagItem *tags);

struct ColumnInfo *AllocLBColumnInfo(UWORD cols, Tag tag1, ...);

FUNCTION

Allocates a ColumnInfo array that can be passed to the list browser via the LISTBROWSER_ColumnInfo tag. This is a future friendly way of allocating and initializing the ColumnInfo array.

TAGS

See SetLBColumnInfoAttrsA() for the list of supported tags. AllocLBColumnInfoA() supports the following additional tags:

LBCIA_MemPool (APTR)
Specifies a custom memory pool to allocate ColumnInfo structs from.

Defaults to NULL (internal pool).

INPUTS

cols
How many columns your ListBrowser has.

tags
A tag list of attributes to set.

RESULT

Returns a pointer to the ColumnInfo array or NULL on error.

NOTES

The use of the LBCIA_MemPool tag is strongly discouraged because no arbitration mechanism for safely allocating/freeing memory from the supplied pool is available in AmigaOS versions prior to AmigaOS4. This feature was never ever safe to use on AmigaOS versions 2.x through 3.x!

SEE ALSO

FreeLBColumnInfo(), GetLBColumnInfoAttrsA(), SetLBColumnInfoAttrsA()