[Lazarus] Howto close my Bugreport in Mantis??

2015-01-25 Thread John Landmesser

sorry, i couldn't find a way to close my own Bugreport 0027202

It's no bug!!
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [fpc-pascal] character escaping with ^LETTER

2015-01-25 Thread C Western

On 24/01/15 20:33, Martin Frb wrote:

On 19/01/2015 17:09, Martin Frb wrote:

On 19/01/2015 13:17, Dmitry Boyarintsev wrote:


CodeTools syntax highlighter won't recognize the syntax as characters
either (delphi 7 highlighter doesn't recognize it as a character
escaping as well)



Add  that to the bugtracker please (as synedit HL issue).

It is probably easy to fix, simple a question of not forgetting it


Implemented in Lazarus trunk
^C now highlights as char, except, for things like type x = ^C;

Note there are places where neither are char, nor a ^SomeType are legal,
in those cases there is no rule as what it will be highlighted.


There seems to be a corner case that needs a little work:

TypeData :=
GetTypeData(PropInfo^.PropType{$IFNDEF FPC}^{$ENDIF});

causes all the rest of the file after FPC to show as grayed out, i.e. 
as if it was one big conditional.


Colin


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [fpc-pascal] character escaping with ^LETTER

2015-01-25 Thread Mattias Gaertner
On Sun, 25 Jan 2015 13:00:17 +
C Western l...@c-m-w.me.uk wrote:

 On 24/01/15 20:33, Martin Frb wrote:
  On 19/01/2015 17:09, Martin Frb wrote:
  On 19/01/2015 13:17, Dmitry Boyarintsev wrote:
 
  CodeTools syntax highlighter won't recognize the syntax as characters
  either (delphi 7 highlighter doesn't recognize it as a character
  escaping as well)
 
 
  Add  that to the bugtracker please (as synedit HL issue).
 
  It is probably easy to fix, simple a question of not forgetting it
 
  Implemented in Lazarus trunk
  ^C now highlights as char, except, for things like type x = ^C;
 
  Note there are places where neither are char, nor a ^SomeType are legal,
  in those cases there is no rule as what it will be highlighted.
 
 There seems to be a corner case that needs a little work:
 
 TypeData :=
 GetTypeData(PropInfo^.PropType{$IFNDEF FPC}^{$ENDIF});
 
 causes all the rest of the file after FPC to show as grayed out, i.e. 
 as if it was one big conditional.

That is because the highlighter now treats ^{ as constant and so the
{$endif} is not seen by the highlighter code.

AFAIK only ^A..^Z are constants.

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Howto close my Bugreport in Mantis??

2015-01-25 Thread Giuliano Colla

Il 25/01/2015 17:19, John Landmesser ha scritto:

sorry, i couldn't find a way to close my own Bugreport 0027202

It's no bug!!


I did it. Now the issue is closed.

Thank you

Giuliano

--
Giuliano Colla

Project planning question: when it's 90% done, are we halfway or not yet?

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [fpc-pascal] character escaping with ^LETTER

2015-01-25 Thread C Western

Thanks for the quick fix.

Colin

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [fpc-pascal] character escaping with ^LETTER

2015-01-25 Thread Mattias Gaertner
On Sat, 24 Jan 2015 20:33:18 +
Martin Frb laza...@mfriebe.de wrote:

 On 19/01/2015 17:09, Martin Frb wrote:
  On 19/01/2015 13:17, Dmitry Boyarintsev wrote:
 
  CodeTools syntax highlighter won't recognize the syntax as characters 
  either (delphi 7 highlighter doesn't recognize it as a character 
  escaping as well)
 
 
  Add  that to the bugtracker please (as synedit HL issue).
 
  It is probably easy to fix, simple a question of not forgetting it
 
 Implemented in Lazarus trunk
 ^C now highlights as char, except, for things like type x = ^C;
 
 Note there are places where neither are char, nor a ^SomeType are legal, 
 in those cases there is no rule as what it will be highlighted.

The following is now highlighted as constant:
c:=p^;

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [fpc-pascal] character escaping with ^LETTER

2015-01-25 Thread Martin Frb

On 25/01/2015 13:23, Mattias Gaertner wrote:

That is because the highlighter now treats ^{ as constant and so the
{$endif} is not seen by the highlighter code.

AFAIK only ^A..^Z are constants.



No,

program Project1;
begin
  writeln( ^{ );
end.

compiles. Also
  writeln( ^^ );
  writeln( ^. );
even space
  writeln( ^  );
are ok

But
  writeln( ^{ $);
does not.

Seems than directives have a special priority.

Also other multi char tokens (* are split
  writeln( ^(* 8 );
project1.lpr(4,12) Error: Incompatible types: got Char expected LongInt

So this is:  char * 8




--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [fpc-pascal] character escaping with ^LETTER

2015-01-25 Thread Martin Frb

On 25/01/2015 13:14, Mattias Gaertner wrote:

The following is now highlighted as constant:
c:=p^;



Fixed.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Declaration of an event type inside a class

2015-01-25 Thread Alexander Klenin
On Mon, Jan 26, 2015 at 7:12 AM, Werner Pamler werner.pam...@freenet.de wrote:
 The declaration of TDrawEvent is part of the TChart declaration! As reported
 in the German Lazarus forum
 (http://www.lazarusforum.de/viewtopic.php?f=18t=8474), an error Unable to
 show method... is generated because of this construction: If I move the
 TDrawEvent out of the TChart context everything works fine.

 I cannot reach Alexander S Klenin for clarification. But what could have
 been his intention of doing it this way? (Or maybe it is just a typo?)
Yes, it was, to lower the namespace pollution (and to play with a
modern FPC feature along the way :-) ).
If this event is moved out of TChart, it should probably be called
TChartDrawEvent or similar.

-- 
Alexander S. Klenin

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] Declaration of an event type inside a class

2015-01-25 Thread Werner Pamler
Fine, I'll do it like that. BTW: Nice to hear from you again, Alexander, 
you seem to have been extremely busy.


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Declaration of an event type inside a class

2015-01-25 Thread Alexander Klenin
On Mon, Jan 26, 2015 at 8:08 AM, Werner Pamler werner.pam...@freenet.de wrote:
 Fine, I'll do it like that.
FWIW, in my my opinion it is preferable to fix CodeTools, since it
feels awkward to avoid legitimate language
feature just because IDE does not like it.

BTW: Nice to hear from you again, Alexander, you
 seem to have been extremely busy.
There were a several unexpected health and job issues that prevented
me from doing open-source work, sorry.
Now that they are mostly resolved, maybe I will return to Lazarus project.

-- 
Alexander S. Klenin

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] Declaration of an event type inside a class

2015-01-25 Thread Werner Pamler

The TAChart code contains a strange declaration:

  TChart = class(TCustomChart, ICoordTransformer)
  public
  type
TDrawEvent = procedure (ASender: TChart; ADrawer: IChartDrawer) of 
object;

  strict private // Property fields
FOnAfterDraw: TDrawEvent;

  published
property OnAfterDraw: TDrawEvent read FOnAfterDraw write 
SetOnAfterDraw;


The declaration of TDrawEvent is part of the TChart declaration! As 
reported in the German Lazarus forum 
(http://www.lazarusforum.de/viewtopic.php?f=18t=8474), an error Unable 
to show method... is generated because of this construction: If I move 
the TDrawEvent out of the TChart context everything works fine.


I cannot reach Alexander S Klenin for clarification. But what could have 
been his intention of doing it this way? (Or maybe it is just a typo?)


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus