separate (Tracker.Report_Generator)
procedure List_By_Person is
    ----------------------------------------------------------------------
    --|
    --|  NAME:  LIST_BY_PERSON
    --|
    --|  OVERVIEW:
    --|    One report is printed for each person on the project.  Each report
    --|    lists all the elements assigned to that person.  The report includes
    --|    information listed in the List by Milestone Report and also the date
    --|    each element is due (its milestone due date) and the calculated
    --|    finish date for each element.  The finish date for each element was
    --|    computed previously by CALC_TIME_DONE and stored in the element data.
    --|
    --|  EXCEPTIONS HANDLED:
    --|    none
    --|
    --|  HISTORY:
    --|    written by   Bonnie Burkhardt   March 1985
    --|
    ----------------------------------------------------------------------

    use Calendar;
    use Ac_List_Pkg;
    use El_List_Pkg;
    use Pr_List_Pkg;

    Header1 : String (1 .. 132) := (others => ' ');
    Header2 : String (1 .. 132) := (others => ' ');
    Header_Lines : String (1 .. 132) := (others => ' ');

    Ac_Index : Integer := 0;
    Ac_Ptr : Activity_Pointer;
    End_List : Boolean := False;
    Ele_Count : Integer := 0;
    Ele_In_Pr : Integer := 0;
    Ele_Ptr : Element_Pointer;
    Line_Count : Integer := 0;
    Pr_Index : Integer := 0;
    Pr_Ptr : Personnel_Pointer;
    Title : constant String := "LIST BY PERSON REPORT";
    Tot_Currnt : Integer range 0 .. 9_999_999 := 0;
    Tot_Eq_New : Integer range 0 .. 9_999_999 := 0;
    Tot_Orig : Integer range 0 .. 9_999_999 := 0;
    Tot_Cpxy : Float := 0.0;
    Tot_Hours : Float := 0.0;

    procedure Init_Pr_Headers is separate;
    procedure Print_Pr_Element is separate;
    procedure Print_Pr_Total is separate;

begin
    Init_Pr_Headers;

    Start_Walk (Pr_List);

    loop
        Walk (Pr_List, Pr_Ptr, End_List);
        exit when End_List;
        Line_Count := 0;

        -- create the subtitle string
        Start_Page (Title, Pr_Ptr.Name, Header1, Header2, Header_Lines);
        Start_Walk (Pr_Ptr.Element_List);
        Ele_In_Pr := 0;

        loop
            Walk (Pr_Ptr.Element_List, Ele_Ptr, End_List);

            -- if end of list, print out totals
            if End_List then
                if (Ele_In_Pr > 0) then
                    Print_Pr_Total;
                end if;

                exit;
            end if;

            -- update running totals
            Ele_Count := Ele_Count + 1;
            Tot_Currnt := Tot_Currnt + Ele_Ptr.Current_Size;
            Tot_Eq_New := Tot_Eq_New - Ele_Ptr.Size_Done_At_Start +
                             Ele_Ptr.Current_Size;
            Tot_Orig := Tot_Orig + Ele_Ptr.Original_Size;
            Tot_Cpxy := Tot_Cpxy + Ele_Ptr.Complexity;
            Tot_Hours := Tot_Hours + Ele_Ptr.Hours_To_Complete;

            Print_Pr_Element;

            Ele_In_Pr := Ele_In_Pr + 1;
            Line_Count := Line_Count + 1;

            if Line_Count >= Max_Data_Lines - 2 then
                Start_Page (Title, Pr_Ptr.Name, Header1, Header2, Header_Lines);
                Line_Count := 0;
            end if;
        end loop;
    end loop;
exception
    when others =>
        Put_Line ("exception raised in LIST BY PERSON REPORT");
end List_By_Person;


