1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-05 22:43:24 +00:00
freebsd-ports/lang/glade-gpl/files/patch-ab
Neil Blakey-Milner 141cc629a2 Add gnat-glade, the glade companion package to gnat, for building
distributed systems in Ada.

PR:		ports/18374
Submitted by:	Samuel Tardieu <sam@inf.enst.fr>
2000-07-31 15:01:38 +00:00

47 lines
1.3 KiB
Plaintext

--- Garlic/split.adb.orig Wed May 3 19:43:33 2000
+++ Garlic/split.adb Wed May 3 19:45:24 2000
@@ -38,8 +38,20 @@
procedure Split is
- Column : Natural := 0;
- Max_Column : constant := 50;
+ Column : Natural := 0;
+ Max_Column : constant := 65;
+ Hard_Max_Column : constant := 78;
+ Was_Space : Boolean := False;
+
+ procedure Print_Space_Maybe;
+
+ procedure Print_Space_Maybe is
+ begin
+ if Was_Space and then Column /= 0 then
+ Put (' ');
+ Was_Space := False;
+ end if;
+ end Print_Space_Maybe;
begin
if Argument_Count /= 1 then
@@ -50,9 +62,20 @@
if Argument (1) (I) = ' ' and then Column >= Max_Column then
New_Line;
Column := 0;
+ elsif Argument (1) (I) = ' ' and then Column = 0 then
+ null;
+ elsif Column >= Hard_Max_Column then
+ New_Line;
+ Put ("-- " & Argument (1) (I));
+ Column := 5;
+ elsif Argument (1) (I) = ' ' then
+ Was_Space := True;
else
if Column = 0 then
Put ("-- ");
+ Column := 4;
+ else
+ Print_Space_Maybe;
end if;
Put (Argument (1) (I));
Column := Column + 1;