Lumail - The console email client

Lua primitives: index_offset()

NOTE: Lumail-legacy has been superseded by Lumail 2.x, which has a wholly unified Lua API.

When a folder has been opened this function will return the currently selected message offset.

The offset will range from 0 to count_messages().

For example:

-- Iterate over every message from the current position to the end of the list.
function do_stuff()
   i = index_offset();
   while( i < count_messages() )
       jump_index_to( i )
       -- do stuff
       i = i + 1


This function has been available since version 0.18.

See Also

See also jump_index_to, scroll_index_down, scroll_index_to, scroll_index_up.