From 8b72f0c6681d0d13506ff56985052b9a81760cdc Mon Sep 17 00:00:00 2001 From: Greg Ercolano Date: Sun, 6 Nov 2022 20:21:46 -0800 Subject: Add doxygen docs for Fl_Int_Vector. While adding the docs, noticed some things that need modification for proper public use. These are highlighted as \todo items and \warning items, which will be fixed in a separate commit forthcoming. -erco --- FL/Fl_Int_Vector.H | 72 ++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 70 insertions(+), 2 deletions(-) (limited to 'FL/Fl_Int_Vector.H') diff --git a/FL/Fl_Int_Vector.H b/FL/Fl_Int_Vector.H index 1ab092a18..89e2d29af 100644 --- a/FL/Fl_Int_Vector.H +++ b/FL/Fl_Int_Vector.H @@ -20,9 +20,51 @@ #include +/** \file FL/Fl_Int_Vector.H + An STL-ish vector implemented without templates. +*/ + +/** + An STL-ish vector without templates. + + Handles dynamic memory management of an integer array, and allows + array elements to be accessed with zero based indexing: v[0], v[1].. + + Common use: + \code + #include + int main() { + Fl_Int_Vector v; + + // Create an array of values 1,2,3: + v.push_back(1); // add first element + v.push_back(2); // add second element + v.push_back(3); // add third element + + // Loop through printing the values + for ( unsigned int i=0; i