CVS difference for arm/progs/arm_corr.adb

Differences between 1.18 and version 1.19
Log of other versions for file arm/progs/arm_corr.adb

--- arm/progs/arm_corr.adb	2012/11/06 02:30:36	1.18
+++ arm/progs/arm_corr.adb	2012/12/14 04:15:03	1.19
@@ -65,6 +65,8 @@
     -- 10/25/11 - RLB - Added old insertion version to Revised_Clause_Header.
     --  8/31/12 - RLB - Added Output_Path.
     -- 10/18/12 - RLB - Added additional hanging styles.
+    -- 11/26/12 - RLB - Added subdivision names to Clause_Header and
+    --			Revised_Clause_Header.
 
     LINE_LENGTH : constant := 78;
 	-- Maximum intended line length.
@@ -641,14 +643,16 @@
     end Category_Header;
 
 
-    procedure Clause_Header (Output_Object : in out Corr_Output_Type;
-			     Header_Text : in String;
-			     Level : in ARM_Contents.Level_Type;
-			     Clause_Number : in String;
-			     No_Page_Break : in Boolean := False) is
+    procedure Clause_Header (Output_Object     : in out Corr_Output_Type;
+			     Header_Text       : in String;
+			     Level	       : in ARM_Contents.Level_Type;
+			     Clause_Number     : in String;
+			     Top_Level_Subdivision_Name : in ARM_Output.Top_Level_Subdivision_Name_Kind;
+			     No_Page_Break     : in Boolean := False) is
 	-- Output a Clause header. The level of the header is specified
-	-- in Level. The Clause Number is as specified.
-	-- These should appear in the table of contents.
+	-- in Level. The Clause Number is as specified; the top-level (and
+	-- other) subdivision names are as specified. These should appear in
+	-- the table of contents.
 	-- For hyperlinked formats, this should generate a link target.
 	-- If No_Page_Break is True, suppress any page breaks.
 	-- Raises Not_Valid_Error if in a paragraph.
@@ -705,8 +709,17 @@
 		Ada.Text_IO.Put_Line (Output_Object.Output_File,
 				   Header_Text);
 	    when ARM_Contents.Section =>
-	        Ada.Text_IO.Put_Line (Output_Object.Output_File,
-				   "Section " & Clause_Number & ": " & Header_Text);
+		case Top_Level_Subdivision_Name is
+		    when ARM_Output.Chapter =>
+		        Ada.Text_IO.Put_Line (Output_Object.Output_File,
+					      "Chapter " & Clause_Number & ": " & Header_Text);
+		    when ARM_Output.Section =>
+		        Ada.Text_IO.Put_Line (Output_Object.Output_File,
+					      "Section " & Clause_Number & ": " & Header_Text);
+		    when ARM_Output.Clause =>
+		        Ada.Text_IO.Put_Line (Output_Object.Output_File,
+					      Clause_Number & "   " & Header_Text);
+		end case;
 	    when ARM_Contents.Unnumbered_Section =>
 	        if Header_Text /= "" then
 		    Ada.Text_IO.Put_Line (Output_Object.Output_File,
@@ -726,18 +739,20 @@
     end Clause_Header;
 
 
-    procedure Revised_Clause_Header (Output_Object : in out Corr_Output_Type;
-			     New_Header_Text : in String;
-			     Old_Header_Text : in String;
-			     Level : in ARM_Contents.Level_Type;
-			     Clause_Number : in String;
-			     Version : in ARM_Contents.Change_Version_Type;
-			     Old_Version : in ARM_Contents.Change_Version_Type;
-        		     No_Page_Break : in Boolean := False) is
+    procedure Revised_Clause_Header
+			    (Output_Object     : in out Corr_Output_Type;
+			     New_Header_Text   : in String;
+			     Old_Header_Text   : in String;
+			     Level	       : in ARM_Contents.Level_Type;
+			     Clause_Number     : in String;
+			     Version	       : in ARM_Contents.Change_Version_Type;
+			     Old_Version       : in ARM_Contents.Change_Version_Type;
+			     Top_Level_Subdivision_Name : in ARM_Output.Top_Level_Subdivision_Name_Kind;
+        		     No_Page_Break     : in Boolean := False) is
 	-- Output a revised clause header. Both the original and new text will
 	-- be output. The level of the header is specified in Level. The Clause
-	-- Number is as specified.
-	-- These should appear in the table of contents.
+	-- Number is as specified; the top-level (and other) subdivision names
+	-- are as specified. These should appear in the table of contents.
 	-- For hyperlinked formats, this should generate a link target.
 	-- Version is the insertion version of the new text; Old_Version is
 	-- the insertion version of the old text.
@@ -801,8 +816,18 @@
 		Ada.Text_IO.Put_Line (Output_Object.Output_File,
 				   Header_Text);
 	    when ARM_Contents.Section =>
-	        Ada.Text_IO.Put_Line (Output_Object.Output_File,
-				   "Section " & Clause_Number & ": " & Header_Text);
+		case Top_Level_Subdivision_Name is
+		    when ARM_Output.Chapter =>
+		        Ada.Text_IO.Put_Line (Output_Object.Output_File,
+					      "Chapter " & Clause_Number & ": " & Header_Text);
+		    when ARM_Output.Section =>
+		        Ada.Text_IO.Put_Line (Output_Object.Output_File,
+					      "Section " & Clause_Number & ": " & Header_Text);
+		    when ARM_Output.Clause =>
+		        Ada.Text_IO.Put_Line (Output_Object.Output_File,
+					      Clause_Number & "   " & Header_Text);
+		end case;
+
 	    when ARM_Contents.Unnumbered_Section =>
 	        if Header_Text /= "" then
 		    Ada.Text_IO.Put_Line (Output_Object.Output_File,

Questions? Ask the ACAA Technical Agent