X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=Ada95%2Fsamples%2Fncurses2-acs_and_scroll.adb;fp=Ada95%2Fsamples%2Fncurses2-acs_and_scroll.adb;h=3ffba4462d111cd1b3ffc999786ac8bd58c65ad9;hp=66384cae080cf11539ce53e7a5dc5bbf3996a036;hb=027ae42953e3186daed8f3882da73de48291b606;hpb=55ccd2b959766810cf7db8d1c4462f338ce0afc8 diff --git a/Ada95/samples/ncurses2-acs_and_scroll.adb b/Ada95/samples/ncurses2-acs_and_scroll.adb index 66384cae..3ffba446 100644 --- a/Ada95/samples/ncurses2-acs_and_scroll.adb +++ b/Ada95/samples/ncurses2-acs_and_scroll.adb @@ -7,7 +7,7 @@ -- B O D Y -- -- -- ------------------------------------------------------------------------------ --- Copyright (c) 2000,2004 Free Software Foundation, Inc. -- +-- Copyright (c) 2000-2004,2006 Free Software Foundation, Inc. -- -- -- -- Permission is hereby granted, free of charge, to any person obtaining a -- -- copy of this software and associated documentation files (the -- @@ -35,8 +35,8 @@ ------------------------------------------------------------------------------ -- Author: Eugene V. Melaragno 2000 -- Version Control --- $Revision: 1.6 $ --- $Date: 2004/08/21 21:37:00 $ +-- $Revision: 1.7 $ +-- $Date: 2006/06/25 14:24:40 $ -- Binding Version 01.00 ------------------------------------------------------------------------------ -- Windows and scrolling tester. @@ -56,14 +56,12 @@ with Ada.Streams; use Ada.Streams; procedure ncurses2.acs_and_scroll is - Macro_Quit : constant Key_Code := Character'Pos ('Q') mod 16#20#; Macro_Escape : constant Key_Code := Character'Pos ('[') mod 16#20#; Quit : constant Key_Code := CTRL ('Q'); Escape : constant Key_Code := CTRL ('['); - Botlines : constant Line_Position := 4; type pair is record @@ -97,7 +95,6 @@ procedure ncurses2.acs_and_scroll is use Ada.Streams.Stream_IO; - -- A linked list -- I wish there was a standard library linked list. Oh well. type Frame is record @@ -173,7 +170,6 @@ procedure ncurses2.acs_and_scroll is when Curses_Exception => return False; end HaveScroll; - procedure newwin_legend (curpw : Window) is package p is new genericPuts (200); @@ -273,7 +269,6 @@ procedure ncurses2.acs_and_scroll is Clear_To_End_Of_Line; end newwin_legend; - procedure transient (curpw : Window; msg : String) is begin newwin_legend (curpw); @@ -299,7 +294,6 @@ procedure ncurses2.acs_and_scroll is Clear_To_End_Of_Line; end transient; - procedure newwin_report (win : Window := Standard_Window) is y : Line_Position; x : Column_Position; @@ -402,7 +396,6 @@ procedure ncurses2.acs_and_scroll is end loop; end selectcell; - function getwindow return Window is rwindow : Window; ul, lr : pair; @@ -442,7 +435,6 @@ procedure ncurses2.acs_and_scroll is return rwindow; end getwindow; - procedure newwin_move (win : Window; dy : Line_Position; dx : Column_Position) is @@ -500,8 +492,9 @@ begin case c is when Character'Pos ('c') mod 16#20# => -- Ctrl('c') declare - neww : FrameA := new Frame'(null, null, False, False, - Null_Window); + neww : constant FrameA := new Frame'(null, null, + False, False, + Null_Window); begin neww.wind := getwindow; if neww.wind = Null_Window then