Leaper Vision Toolkit
中文 / English 2.x
Public Member Functions | Properties
ILSortedArray Interface Reference

This interface holds the array-sorting result. More...

Inheritance diagram for ILSortedArray:
ILObject LSortedArray

Public Member Functions

void Draw (HDC hdc, LPVSortedArrayDrawFlags drawFlags, double zoomX, double zoomY, double panX, double panY)
 
- Public Member Functions inherited from ILObject
ILObjectCopy ()
 
LPVErrorCode Load (LString filename)
 
void Reset ()
 
LPVErrorCode Save (LString filename)
 
BOOL Valid ()
 

Properties

double AvgColumnSpace [get]
 The average column space between objects in the array.
 
double AvgRowSpace [get]
 The average row space between objects in the array.
 
int ColumnCount [get]
 The count of columns after sorting.
 
ILLine ColumnLine (int columnIndex) [get]
 The column line of the given index. It's the fitting result of all positions on the column. More...
 
int FilteredCount [get]
 The count of the filtered objects after sorting. More...
 
BOOL HasItem (int columnIndex, int rowIndex) [get]
 Query the presence of object for the given column and row index after sorting. More...
 
ILSortable Item (int columnIndex, int rowIndex) [get]
 Get the object for the given column and row index after sorting. More...
 
ILSortable ItemFiltered (int index) [get]
 Get the filtered object after sorting. More...
 
ILPoint Position (int columnIndex, int rowIndex) [get]
 Get the position point for the given column and row index after sorting. If there is an object for the given indexes, the position of the object is returned; otherwise, the intersection point of the corresponding column and row line is returned. More...
 
int RowCount [get]
 The count of rows after sorting.
 
ILLine RowLine (int rowIndex) [get]
 The row line of the given index. It's the fitting result of all positions on the row. More...
 

Detailed Description

This interface holds the array-sorting result.

Usually you get the LSortedArray object from the ILSorter::SortToArray() as sorting result. You can then use this interface for row and column indexing and metrics calculation.

Example Code

Member Function Documentation

◆ Draw()

void Draw ( HDC  hdc,
LPVSortedArrayDrawFlags  drawFlags,
double  zoomX,
double  zoomY,
double  panX,
double  panY 
)

Draw the indexes near the corresponding positions on HDC.

Parameters
[in]drawFlagsFlags to control the drawing behavior, see LPVSortedArrayDrawFlags for usage.
See also
Use Draw Functions
Remarks
This function is currently not available on Linux / MacOS platform.

Property Documentation

◆ ColumnLine

ILLine ColumnLine( int columnIndex)
get

The column line of the given index. It's the fitting result of all positions on the column.

Parameters
[in]columnIndexThe input column index, it should be a 0-based number smaller than total column count.
Return values
columnLineReturn the column line

◆ FilteredCount

int FilteredCount
get

The count of the filtered objects after sorting.

See also
ItemFiltered

◆ HasItem

BOOL HasItem( int columnIndex, int rowIndex)
get

Query the presence of object for the given column and row index after sorting.

Parameters
[in]columnIndexThe input column index, it should be a 0-based number smaller than total column count.
[in]rowIndexThe input column index, it should be a 0-based number smaller than total row count.
Return values
valReturn True if there is an object on the specified row and column, False for absence.
See also
Item, Position, RowCount, ColumnCount

◆ Item

ILSortable Item( int columnIndex, int rowIndex)
get

Get the object for the given column and row index after sorting.

Parameters
[in]columnIndexThe input column index, it should be a 0-based number smaller than total column count.
[in]rowIndexThe input column index, it should be a 0-based number smaller than total row count.
Return values
sortableReturn the object. It may be a null pointer if there's no object on the position.
See also
HasItem, Position, RowCount, ColumnCount

◆ ItemFiltered

ILSortable ItemFiltered( int index)
get

Get the filtered object after sorting.

Parameters
[in]indexThe filtered index, it should be a 0-based number smaller than the filtered count.
Return values
sortableReturn the object.
See also
Item, Position, FilteredCount

◆ Position

ILPoint Position( int columnIndex, int rowIndex)
get

Get the position point for the given column and row index after sorting. If there is an object for the given indexes, the position of the object is returned; otherwise, the intersection point of the corresponding column and row line is returned.

Parameters
[in]columnIndexThe input column index, it should be a 0-based number smaller than total column count.
[in]rowIndexThe input column index, it should be a 0-based number smaller than total row count.
Return values
posPointReturn the position point.
See also
HasItem, Item, RowCount, ColumnCount

◆ RowLine

ILLine RowLine( int rowIndex)
get

The row line of the given index. It's the fitting result of all positions on the row.

Parameters
[in]rowIndexThe input column index, it should be a 0-based number smaller than total row count.
Return values
rowLineReturn the row line