[fpc-pascal] CodeTools complete code
Hairy Pixels
genericptr at gmail.com
Tue Oct 4 09:10:29 CEST 2022
I’m trying to use the CompleteCode function in the CodeTools library and doing some formatting I don’t want.
Calling it over the “MyProcedure” method in the class it added a comment and moved the declaration under the variable section instead of directly under the class declaration like I would have expected. Basically I would just like the most minimal amount of changes to implement the method instead of reformatting things.
I see there is a beautifier class but it could it be used for this and if so how may that look?
Starting text:
/////////////////////////////////////////////////////////////////////////////////////////////
type
TMyClass = class
procedure MyProcedure;
end;
var
i: integer;
Modified text:
/////////////////////////////////////////////////////////////////////////////////////////////
type
{ TMyClass }
TMyClass = class
procedure MyProcedure;
end;
var
i: integer;
procedure TMyClass.MyProcedure;
begin
end;
Regards,
Ryan Joseph
More information about the fpc-pascal
mailing list