summaryrefslogtreecommitdiff
path: root/src/editor_windows.ads
diff options
context:
space:
mode:
authorJed Barber <jjbarber@y7mail.com>2016-11-09 09:12:26 +1100
committerJed Barber <jjbarber@y7mail.com>2016-11-09 09:12:26 +1100
commit87063e50bfb3dd69d0806897d5b0d97b7d48f92a (patch)
tree100df0819fbf577dbb4164c7fe77e793551b0a4b /src/editor_windows.ads
parent2b2ed338e7b4f7372fdd74feb33476dd7b94aea5 (diff)
Removed superfluous use clauses, styling now more standardised
Diffstat (limited to 'src/editor_windows.ads')
-rw-r--r--src/editor_windows.ads128
1 files changed, 70 insertions, 58 deletions
diff --git a/src/editor_windows.ads b/src/editor_windows.ads
index 7e6d42c..39ca7a5 100644
--- a/src/editor_windows.ads
+++ b/src/editor_windows.ads
@@ -1,15 +1,12 @@
with FLTK.Widgets.Groups.Windows.Double;
-use FLTK.Widgets.Groups.Windows.Double;
with FLTK.Widgets.Menus;
-use FLTK.Widgets.Menus;
with FLTK.Text_Buffers;
-use FLTK.Text_Buffers;
+private with FLTK.Widgets;
private with FLTK.Widgets.Groups.Text_Displays.Text_Editors;
private with FLTK.Widgets.Menus.Menu_Bars;
private with FLTK.Widgets.Boxes;
-private with FLTK.Widgets;
private with FLTK.Widgets.Inputs;
private with FLTK.Widgets.Buttons;
private with FLTK.Widgets.Buttons.Enter;
@@ -19,11 +16,11 @@ private with FLTK.Widgets.Buttons.Light.Check;
package Editor_Windows is
- type Editor_Window is new Double_Window with private;
+ type Editor_Window is new FLTK.Widgets.Groups.Windows.Double.Double_Window with private;
Min_Editor_Height : Integer := 60;
- Min_Editor_Width : Integer := 300;
+ Min_Editor_Width : Integer := 300;
function Create
@@ -39,37 +36,60 @@ package Editor_Windows is
function Get_Buffer
(This : in Editor_Window)
- return Text_Buffer_Cursor;
+ return FLTK.Text_Buffers.Text_Buffer_Cursor;
procedure Set_Buffer
(This : in out Editor_Window;
- Buff : in out Text_Buffer);
+ Buff : in out FLTK.Text_Buffers.Text_Buffer);
function Get_Menu
(This : in out Editor_Window)
- return Menu_Cursor;
+ return FLTK.Widgets.Menus.Menu_Cursor;
+
+
+ procedure Undo
+ (This : in out Editor_Window);
+
+
+ procedure Cut
+ (This : in out Editor_Window);
+
+
+ procedure Copy
+ (This : in out Editor_Window);
+
+
+ procedure Paste
+ (This : in out Editor_Window);
+
+
+ procedure Delete
+ (This : in out Editor_Window);
- procedure Undo (This : in out Editor_Window);
- procedure Cut (This : in out Editor_Window);
- procedure Copy (This : in out Editor_Window);
- procedure Paste (This : in out Editor_Window);
- procedure Delete (This : in out Editor_Window);
+ function Get_Insert_Position
+ (This : in Editor_Window)
+ return Natural;
+
+
+ procedure Set_Insert_Position
+ (This : in out Editor_Window;
+ Pos : in Natural);
- function Get_Insert_Position (This : in Editor_Window) return Natural;
- procedure Set_Insert_Position (This : in out Editor_Window; Pos : in Natural);
- procedure Show_Insert_Position (This : in out Editor_Window);
+ procedure Show_Insert_Position
+ (This : in out Editor_Window);
- type About_Window is new Double_Window with private;
+ type About_Window is new FLTK.Widgets.Groups.Windows.Double.Double_Window with private;
- function Create return About_Window;
+ function Create
+ return About_Window;
function Create
@@ -85,7 +105,7 @@ package Editor_Windows is
- type Find_Window is new Double_Window with private;
+ type Find_Window is new FLTK.Widgets.Groups.Windows.Double.Double_Window with private;
type Find_Callback is interface;
@@ -95,7 +115,8 @@ package Editor_Windows is
Match_Case : in Boolean) is abstract;
- function Create return Find_Window;
+ function Create
+ return Find_Window;
function Create
@@ -116,7 +137,7 @@ package Editor_Windows is
- type Replace_Window is new Double_Window with private;
+ type Replace_Window is new FLTK.Widgets.Groups.Windows.Double.Double_Window with private;
type Replace_Callback is interface;
@@ -126,7 +147,8 @@ package Editor_Windows is
Match_Case, Rep_All : in Boolean) is abstract;
- function Create return Replace_Window;
+ function Create
+ return Replace_Window;
function Create
@@ -148,67 +170,57 @@ package Editor_Windows is
private
- use FLTK.Widgets.Groups.Text_Displays.Text_Editors;
- use FLTK.Widgets.Menus.Menu_Bars;
- use FLTK.Widgets.Boxes;
- use FLTK.Widgets;
- use FLTK.Widgets.Inputs;
- use FLTK.Widgets.Buttons;
- use FLTK.Widgets.Buttons.Enter;
- use FLTK.Widgets.Buttons.Light.Check;
-
-
- type Editor_Window is new Double_Window with
+ type Editor_Window is new FLTK.Widgets.Groups.Windows.Double.Double_Window with
record
- Bar : aliased Menu_Bar;
- Editor : Text_Editor;
+ Bar : aliased FLTK.Widgets.Menus.Menu_Bars.Menu_Bar;
+ Editor : FLTK.Widgets.Groups.Text_Displays.Text_Editors.Text_Editor;
end record;
- type Hide_Callback is new Widget_Callback with null record;
+ type Hide_Callback is new FLTK.Widgets.Widget_Callback with null record;
overriding procedure Call
(This : in Hide_Callback;
- Item : in out Widget'Class);
+ Item : in out FLTK.Widgets.Widget'Class);
- type About_Window is new Double_Window with
+ type About_Window is new FLTK.Widgets.Groups.Windows.Double.Double_Window with
record
- Picture : Box;
- Heading : Box;
- Blurb : Box;
- Author : Box;
- Dismiss : Enter_Button;
+ Picture : FLTK.Widgets.Boxes.Box;
+ Heading : FLTK.Widgets.Boxes.Box;
+ Blurb : FLTK.Widgets.Boxes.Box;
+ Author : FLTK.Widgets.Boxes.Box;
+ Dismiss : FLTK.Widgets.Buttons.Enter.Enter_Button;
end record;
- type Find_Marshaller is new Widget_Callback with null record;
+ type Find_Marshaller is new FLTK.Widgets.Widget_Callback with null record;
overriding procedure Call
(This : in Find_Marshaller;
- Item : in out Widget'Class);
+ Item : in out FLTK.Widgets.Widget'Class);
- type Find_Window is new Double_Window with
+ type Find_Window is new FLTK.Widgets.Groups.Windows.Double.Double_Window with
record
- Find_What : Input;
- Match_Case : Check_Button;
- Cancel : Button;
- Start : Enter_Button;
+ Find_What : FLTK.Widgets.Inputs.Input;
+ Match_Case : FLTK.Widgets.Buttons.Light.Check.Check_Button;
+ Cancel : FLTK.Widgets.Buttons.Button;
+ Start : FLTK.Widgets.Buttons.Enter.Enter_Button;
Callback : access Find_Callback'Class;
end record;
- type Replace_Marshaller is new Widget_Callback with null record;
+ type Replace_Marshaller is new FLTK.Widgets.Widget_Callback with null record;
overriding procedure Call
(This : in Replace_Marshaller;
- Item : in out Widget'Class);
+ Item : in out FLTK.Widgets.Widget'Class);
- type Replace_Window is new Double_Window with
+ type Replace_Window is new FLTK.Widgets.Groups.Windows.Double.Double_Window with
record
- Find_What, Replace_With : Input;
- Match_Case, Replace_All : Check_Button;
- Cancel : Button;
- Start : Enter_Button;
+ Find_What, Replace_With : FLTK.Widgets.Inputs.Input;
+ Match_Case, Replace_All : FLTK.Widgets.Buttons.Light.Check.Check_Button;
+ Cancel : FLTK.Widgets.Buttons.Button;
+ Start : FLTK.Widgets.Buttons.Enter.Enter_Button;
Callback : access Replace_Callback'Class;
end record;