text
stringlengths
0
234
exit when the_Lines.Length = 25;
next (Cursor);
end loop;
Function Definition: procedure choice_is (Self : in out Item; Now : in String;
Function Body: package_Name : in String)
is
full_Name : constant Identifier := Identifier (package_Name & "." & Now);
begin
recent_Types.register_Usage (full_Name);
Self.build_recent_List;
Self.Invoked_by.set_Label (assist.type_button_Name_of (full_Name));
Self.Invoked_by.set_Tooltip_Text (String (full_Name));
-- Self.Target.all := +full_Name;
-- declare
-- use type Class.view;
-- the_Class : constant Class.view := aIDE.fetch_Class (named => package_Name);
-- begin
-- if the_Class = null then
Self.Target.all := aIDE.the_entity_Environ.find (full_Name); -- .Name_is (full_Name);
-- Self.Target.all.Class_is (null);
-- else
-- -- Self.Target.all.Name_is ("");
-- Self.Target.all := a_Type.class_type.new_Type.all'Access; -- .Class_is (the_Class);
-- Self.Target.all.Class_is (the_Class);
-- end if;
-- end;
Self.Top.hide;
end choice_is;
procedure show (Self : in out Item; Invoked_by : in gtk.Button.gtk_Button;
Target : access adam.a_Type.view)
is
begin
Self.Invoked_by := Invoked_by;
Self.Target := Target;
Self.Top.show_All;
end show;
procedure freshen (Self : in out Item)
is
type a_Package;
type Package_view is access all a_Package;
package package_Vectors is new ada.Containers.Vectors (Positive, Package_view);
subtype Package_vector is package_Vectors.Vector;
type a_Package is
record
Name : Text;
Parent : Package_view;
Children : Package_vector;
Types : adam.text_Lines;
end record;
the_Types : constant adam.a_Type.Vector := aIDE.the_entity_Environ.all_Types;
Root : aliased a_Package;
function full_Name (the_Package : in Package_view) return String
is
use ada.Strings.Unbounded,
text_Vectors;
the_Name : Text;
Parent : Package_view := the_Package.Parent;
begin
the_Name := the_Package.Name;
while Parent /= null
loop
if Parent.Parent /= null then
insert (the_Name, 1, +Parent.Name & ".");
end if;
Parent := Parent.Parent;
end loop;
return +the_Name;
end full_Name;
function find_Child (Parent : in Package_view;
Named : in String) return Package_view
is
use Adam.Assist;
Names : text_Lines := Split (Named);
begin
-- put_Line ("Finding '" & Named & "' in '" & full_Name (Parent) & "'");