Unit 'MUIClass.List' Package
[Overview][Types][Classes][Index] [#MUIClass]

TMUIList

[Properties (by Name)] [Methods (by Name)] [Events (by Name)]

List of items drawn as text list

Declaration

Source position: MUIClass.List.pas line 22

type TMUIList = class(TMUIArea)

protected

  procedure GetCreateTags(); override;

  

Fille TagList for creation of the List

  procedure AfterCreateObject; override;

  

Connect Events after MUI object creation

  function CreateImage();

  

Create an Image to use in the List

  procedure DeleteImage();

  

Delete the image pointer returned from CreateImage().

  class function ListImageToString();

  

Convert the Blackbox Image to a string for Display Event

public

  constructor Create; override;

  

Create the List object

  procedure CreateObject; override;

  

Create the MUI List item

  procedure Exchange();

  

Exchange two entries in a list.

  function GetEntry();

  

Get an entry by Index. If the entry is not available (either because you are out of bounds or because there is no active entry), you will receive a nil.

  procedure Insert();

  

Insert new entries into a list.

  procedure InsertSingle();

  

Insert one new entry into a list.

  procedure Jump();

  

Scroll any entry into the visible part of a list.

  procedure Move();

  

Move an entry from one position to another.

  procedure NextSelected();

  

Iterate through the selected entries of a list.

  procedure Redraw();

  

Redraw an List Entry

  procedure Remove();

  

Remove an entry from a list.

  procedure Select();

  

Select/deselect a list entry or ask an entry if its selected.

  procedure Sort;

  

Sort the list. MUI uses an iterative quicksort algorithm, no stack problems will occur.

  function TestPos();

  

Find out which line/column of a listview is currently displayed at a certain position.

  procedure Clear;

  property DropMark: Integer; [r]

  

After a successfull drop operation, this attribute holds the position where we should insert the new entry(ies).

  property Entries: Integer; [r]

  

Get the current number of entries in the list.

  property First: Integer; [r]

  

Get the number of the entry displayed on top of the list.

  property InsertPosition: Integer; [r]

  

Position of the last inserted Entry

  property Pool: Pointer; [rw]

  

Memory Pool for the Entry memory

  property PoolPuddleSize: LongWord; [rw]

  

Specify the puddle size for the lists memory pool.

  property PoolThreshSize: LongWord; [rw]

  

Specify the thresh size for the lists memory pool.

  property Quiet: Boolean; [rw]

  

Block redrawing, when many Entries are added or removed

  property Visible: Integer; [r]

  

Get the current number of visible entries in the list.

published

  property Active: Integer; [rw]

  

Active Entry in the List

  property AdjustHeight: Boolean; [rw]

  

The complete List has the Height of it's Entries, no free Space

  property AdjustWidth: Boolean; [rw]

  

The complete List has the Height of it's longest Entry, no free Space

  property AutoVisible: Boolean; [rw]

  

Set this to make your lists automatically jump to the active entry when they are displayed.

  property DragSortable: Boolean; [rw]

  

Enable Drag and Drop for the Entries

  property Format: string; [rw]

  

Format the Columns of the List

  property MinLineHeight: Integer; [rw]

  

Sets the minimum line height for lists in pixels.

  property ShowDropMarks: Boolean; [rw]

  

Indicate the place where a new line on drag and drop would be inserted with some horizontal lines.

  property SourceStrings: TStringArray; [rw]

  

Initial Contents of the List

  property Title: string; [rw]

  

Specify a title for the current list.

  property OnActiveChange: TNotifyEvent; [rw]

  

Active Changed

  property OnDisplay: TDisplayEvent; [rw]

  

Define what should be printed in a list row

  property OnCompare: TCompareEvent; [rw]

  

Event to compare two entries for sorting

  property OnConstruct: TConstructEvent; [rw]

  

Constrcut a new List Entry

  property OnDestruct: TDestructEvent; [rw]

  

Destroy an Entry which is removed from the List

  property OnMultiTest: TMultiTestEvent; [rw]

  

Check if an Entry can be selected in a multiselection

  property OnDrop: TNotifyEvent; [rw]

  

Drop operation finished, shows where the new Entry should be inserted

end;

Inheritance

TMUIList

  

List of items drawn as text list

|

TMUIArea

  

Super class for every other MUI class except windows and applications

|

TMUIWithParent

  

Subclass of TNotify to introduce the Parent relation

|

TMUINotify

  

Notify class is superclass of all other MUI classes.

|

TMUIRootClass

  

Base class for all MUI Class

|

TObject

Description

MUI's list class is very powerful. It handles all types of entries, from a simple string to a complicated structure with many associated resources. Multi column lists are also supported, the format for a column is adjustable.

Lists support any kind of sorting, multi selection and an active entry that can be controlled with the mouse or the cursor keys.

Note: A list object alone doesn't make much sense, you should always use it as child of a ListView object. This one attaches a scrollbar and handles all user input.


Documentation generated on: 2024-12-21