Recent

Author Topic: Alt-Up in editor not so good  (Read 5438 times)

Guest

  • Guest
Alt-Up in editor not so good
« on: September 06, 2005, 12:59:54 pm »
Hi all,

Using Alt-Up in the code editor takes you to a declaration.
I use this all the time - it's a critical bit of functionality.
Lazarus doesn't seem as good at finding units as Delphi.

For example, if you have structure:

root\delphi\lib\Unit1.pas, Unit2.pas
    |
    \laz\myprog\myprog.lpr, Main.pas

if, say, myprog USES Main, which USES Unit1,
and Unit1 USES Unit2, you can't go from Main to
Unit1 to Unit2 via a sequence of Alt-Ups

I've tried all kinds of relative and absolute
paths in options, and adding files to the project (which
I prefer to avoid - I like just specifying paths),
but Lazarus just won't do it - or at least I can't get it to.

Another thing along the same lines: Laz doesn't seem to like
uses clauses whith IFDEFs, eg

uses
  {IFDEF FPC} Unit1, {ELSE} Unit2 {ENDIF};

Alt-Up on Unit1 doesn't do anything!

I think these problems are similar to a previous thread
"Ctrl+Space gives 'unit not found'", but that thread didn't
seem to go anywhere.

Delphi seems to manage all these fine.

Anyone got any suggestions, or perhaps have the same prob?

felipemdc

  • Administrator
  • Hero Member
  • *
  • Posts: 3538
Re: Alt-Up in editor not so good
« Reply #1 on: October 16, 2005, 09:53:43 pm »
Quote from: "Guest"
Another thing along the same lines: Laz doesn't seem to like
uses clauses whith IFDEFs, eg

uses
  {IFDEF FPC} Unit1, {ELSE} Unit2 {ENDIF};

Alt-Up on Unit1 doesn't do anything!


I don´t think so. My project here works perfectly with IFDEFs on the uses clause. I guess the variable FPC has a different name.

Here is my working uses clause (both on 0.9.10 and 0.9.11):

uses
  Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs, ExtCtrls,
{$IFDEF WIN32}
  Windows,
{$ENDIF}
{$IFDEF Linux}
  ports,
{$ENDIF}
  ComCtrls, StdCtrls, Buttons, ActnList, Spin, controles, Geral, hardware;

 

TinyPortal © 2005-2018