View Issue Details

IDProjectCategoryView StatusLast Update
0013757FPCTextmode IDEpublic2019-02-06 03:44
ReporterSalvatore LicciardiAssigned ToMichael Van Canneyt 
PrioritynormalSeverityfeatureReproducibilityhave not tried
Status resolvedResolutionfixed 
PlatformDos - Win32 - OS/2 - LinuxOSDos, Win9x/Nt, Linux, OS/2OS Versionall possible
Product VersionProduct Build 
Target Version3.2.0Fixed in Version3.3.1 
Summary0013757: go to line number
DescriptionRun the IDE,
when you do "SEARCH / GO TO LINE NUMBER", can you show previous value?

can you add + and - to skip at a relative row?
If so, can you don't close the windows ? (so you can repeat this function)
TagsNo tags attached.
Fixed in Revision41079
FPCOldBugId
FPCTarget
Attached Files
  • rememberLastGotoLine.patch (635 bytes)
    Index: packages/ide/weditor.pas
    ===================================================================
    --- packages/ide/weditor.pas	(revision 40810)
    +++ packages/ide/weditor.pas	(working copy)
    @@ -5978,12 +5978,11 @@
     end;
     
     procedure TCustomCodeEditor.GotoLine;
    -var
    -  GotoRec: TGotoLineDialogRec;
    +const
    +  GotoRec: TGotoLineDialogRec = (LineNo:'1';Lines:0);  {keep previous goto line number}
     begin
       with GotoRec do
       begin
    -    LineNo:='1';
         Lines:=GetLineCount;
         {Linecount can be 0, but in that case there still is a cursor blinking in top
          of the window, which will become line 1 as soon as sometype hits a key.}
    

Activities

Marco van de Voort

2009-05-19 14:18

manager   ~0027755

Previous "goto" linenumber, or current linenumber?

Salvatore Licciardi

2009-05-27 21:26

reporter   ~0028077

THE Previous "goto" linenumber

Marģers

2019-01-08 21:40

reporter  

rememberLastGotoLine.patch (635 bytes)
Index: packages/ide/weditor.pas
===================================================================
--- packages/ide/weditor.pas	(revision 40810)
+++ packages/ide/weditor.pas	(working copy)
@@ -5978,12 +5978,11 @@
 end;
 
 procedure TCustomCodeEditor.GotoLine;
-var
-  GotoRec: TGotoLineDialogRec;
+const
+  GotoRec: TGotoLineDialogRec = (LineNo:'1';Lines:0);  {keep previous goto line number}
 begin
   with GotoRec do
   begin
-    LineNo:='1';
     Lines:=GetLineCount;
     {Linecount can be 0, but in that case there still is a cursor blinking in top
      of the window, which will become line 1 as soon as sometype hits a key.}

Marģers

2019-01-08 21:42

reporter   ~0113274

patch for first part.

Serge Anvarov

2019-01-26 21:02

reporter   ~0113646

About patch. Although the default typed constants are rewritable, I would, for clarity, add {$PUSH}{$WRITEABLECONST ON}...{$POP}

Marģers

2019-01-27 02:00

reporter   ~0113650

Valid point.
I guess, the reason, why patch is not accepted yet, is because of low priority of Textmode ide. At this point, I will leave it as it is.
If someone from fpc team will tell whats wrong with this patch, I would be happy to do something about it.

Michael Van Canneyt

2019-01-27 09:26

administrator   ~0113655

Applied patch as-is, thank you.

No need for push/pop, the textmode IDE uses mostly old fpc/TP mode, where writeable const is the default.

Margers, many thanks for working on the IDE, it is most welcome !

Issue History

Date Modified Username Field Change
2009-05-19 09:25 Salvatore Licciardi New Issue
2009-05-19 14:18 Marco van de Voort Note Added: 0027755
2009-05-27 19:28 Jonas Maebe Status new => feedback
2009-05-27 21:26 Salvatore Licciardi Note Added: 0028077
2019-01-08 21:40 Marģers File Added: rememberLastGotoLine.patch
2019-01-08 21:42 Marģers Note Added: 0113274
2019-01-26 21:02 Serge Anvarov Note Added: 0113646
2019-01-27 02:00 Marģers Note Added: 0113650
2019-01-27 09:19 Michael Van Canneyt Assigned To => Michael Van Canneyt
2019-01-27 09:19 Michael Van Canneyt Status feedback => assigned
2019-01-27 09:26 Michael Van Canneyt Fixed in Revision => 41079
2019-01-27 09:26 Michael Van Canneyt Note Added: 0113655
2019-01-27 09:26 Michael Van Canneyt Status assigned => resolved
2019-01-27 09:26 Michael Van Canneyt Fixed in Version => 3.3.1
2019-01-27 09:26 Michael Van Canneyt Resolution open => fixed
2019-01-27 09:26 Michael Van Canneyt Target Version => 3.2.0