Skip to main content

fz_outline_iterator_insert

Function fz_outline_iterator_insert 

Source
pub unsafe extern "C" fn fz_outline_iterator_insert(
    ctx: *mut fz_context,
    iter: *mut fz_outline_iterator,
    item: *mut fz_outline_item,
) -> c_int
Expand description

Call to insert a new item BEFORE the current point.

Ownership of pointers are retained by the caller. The item data will be copied.

After an insert, we do not change where we are pointing.
The return code is the same as for next, it indicates the current iterator position.

Note that for PDF documents at least, the is_open field is ignored. All childless
nodes are considered closed by PDF, hence (given every newly inserted node is
childless by definition) all new nodes are inserted with is_open == false.