Re: [Lazarus] operator overloading

2013-02-24 Thread leledumbo
FPC operator overloading doesn't work inside classes, it must be declared globally, so method2 should work. What error do you get? What FPC version do you use? -- View this message in context: http://free-pascal-lazarus.989080.n3.nabble.com/Lazarus-operator-overloading-tp4029399p4029400.html

Re: [Lazarus] WinINet STDCALL callback crash

2013-02-24 Thread Ludo Brands
On 02/23/2013 09:49 PM, matt...@accordancebible.com wrote: Hello Lazarus Community, I am implementing asynchronous file download using WinINet's STDCALL callback. However, when the callback function recursively calls itself, it generates a crash around fpc_popaddrstack. I hypothesize

[Lazarus] Checkgroup behaviour

2013-02-24 Thread Mark Morgan Lloyd
I notice that if the CheckGroup Edit right-click is used to disable all lines, that right-click stops working so it is impossible to reenable any of them. Trunk r40343. Also at runtime, the OnMouseUp event fires if the mouse is clicked over the group background, but not over one of the

Re: [Lazarus] Checkgroup behaviour

2013-02-24 Thread zeljko
On Sunday 24 of February 2013 13:00:51 Mark Morgan Lloyd wrote: I notice that if the CheckGroup Edit right-click is used to disable all lines, that right-click stops working so it is impossible to reenable any of them. Trunk r40343. Also at runtime, the OnMouseUp event fires if the mouse is

Re: [Lazarus] Checkgroup behaviour

2013-02-24 Thread Mark Morgan Lloyd
zeljko wrote: On Sunday 24 of February 2013 13:00:51 Mark Morgan Lloyd wrote: I notice that if the CheckGroup Edit right-click is used to disable all lines, that right-click stops working so it is impossible to reenable any of them. Trunk r40343. Also at runtime, the OnMouseUp event fires if

Re: [Lazarus] operator overloading

2013-02-24 Thread Wildfire
From: xrfang Sent: Sunday, February 24, 2013 7:31 AM To: Lazarus@lists.lazarus.freepascal.org Subject: [Lazarus] operator overloading operator (p1, p2: TPainter) b: Boolean; —method2 Close, but no cigar... operator (p1, p2: TPainter): Boolean;

Re: [Lazarus] operator overloading

2013-02-24 Thread Sven Barth
On 24.02.2013 15:51, Wildfire wrote: *From:* xrfang mailto:xrf...@gmail.com *Sent:* Sunday, February 24, 2013 7:31 AM *To:* Lazarus@lists.lazarus.freepascal.org mailto:Lazarus@lists.lazarus.freepascal.org *Subject:* [Lazarus] operator overloading operator (p1, p2: TPainter) b: Boolean;

Re: [Lazarus] operator overloading

2013-02-24 Thread xrfang
I will test again tomorrow to find out what's wrong with my code.  For now, one more queston: I noticed that generics does not work without {$mode objfpc}.  I wonder what is the default mode without $mode? Why objfpc is not the default mode? 在 日, 2月 24, 2013 at 11:00 下午,Sven Barth

Re: [Lazarus] operator overloading

2013-02-24 Thread Sven Barth
On 24.02.2013 08:31, xrfang wrote: Hi All, How can I use operator overloading? I know the syntax, but it simply does not compile... My situation is: 1. I wrote a TTreap generic class, which is a binary tree. 2. TTreap defines a Compare() with involves and operation on its keys. 3. I try to

Re: [Lazarus] operator overloading

2013-02-24 Thread Wildfire
Both variants will work. The variant with b: Boolean was originally introduced for the non-Object-Pascal modes (fpc, tp), because there you only have the name of the procedure/function as a result variable and as operators don't have names (in that sense) you can specify the name of the

Re: [Lazarus] operator overloading

2013-02-24 Thread Sven Barth
On 24.02.2013 16:02, xrfang wrote: I will test again tomorrow to find out what's wrong with my code. For now, one more queston: I noticed that generics does not work without {$mode objfpc}. I wonder what is the default mode without $mode? Why objfpc is not the default mode? The default mode

Re: [Lazarus] Ide add-ons licensing issue

2013-02-24 Thread Giuliano Colla
Il 23/02/2013 18:05, Alexsander Rosa ha scritto: Just send the components along with your source code. Add some kind of README.TXT explaining: 1) the requirements (Lazarus and FPC versions, etc) PLUS your components 2) step-by-step instructions to install your custom components on Lazarus. If

Re: [Lazarus] LazReport Band.name patch

2013-02-24 Thread Jesus Reyes
--- El jue 21-feb-13, Giuliano Colla giuliano.co...@fastwebnet.it escribió: I've tested a different approach, i.e. not *setting* the Band name, but just *getting* Band name from BandView, (a Name property in TfrBand which just returns the name of the corresponding Bandview, i.e.

[Lazarus] Where are the fpc sources for fpc 2.6.2?

2013-02-24 Thread Donald Ziesig
Hi All: I just got a new laptop and decided to put the latest and greatest Lazarus/FPC on it. I got FPC 2.6.2, installed it and used it to compile Lazarus 1.1. When I run Lazarus it asks for (as an example) rtl/linux/system.pp. I found rtl/linux/system.pp in

Re: [Lazarus] Where are the fpc sources for fpc 2.6.2?

2013-02-24 Thread Sven Barth
On 24.02.2013 23:18, Donald Ziesig wrote: Hi All: I just got a new laptop and decided to put the latest and greatest Lazarus/FPC on it. I got FPC 2.6.2, installed it and used it to compile Lazarus 1.1. When I run Lazarus it asks for (as an example) rtl/linux/system.pp. I found

Re: [Lazarus] Where are the fpc sources for fpc 2.6.2?

2013-02-24 Thread Reimar Grabowski
On Sun, 24 Feb 2013 17:18:21 -0500 Donald Ziesig don...@ziesig.org wrote: Hi All: I just got a new laptop and decided to put the latest and greatest Lazarus/FPC on it. Not true. If that was really your decision you would already have the sources as you would get both via SVN. And it would

Re: [Lazarus] Where are the fpc sources for fpc 2.6.2?

2013-02-24 Thread Mattias Gaertner
On Sun, 24 Feb 2013 17:18:21 -0500 Donald Ziesig don...@ziesig.org wrote: Hi All: I just got a new laptop and decided to put the latest and greatest Lazarus/FPC on it. I got FPC 2.6.2, installed it and used it to compile Lazarus 1.1. When I run Lazarus it asks for (as an example)

Re: [Lazarus] Where are the fpc sources for fpc 2.6.2?

2013-02-24 Thread Donald Ziesig
On 02/24/2013 05:40 PM, Mattias Gaertner wrote: On Sun, 24 Feb 2013 17:18:21 -0500 Donald Ziesig don...@ziesig.org wrote: Hi All: I just got a new laptop and decided to put the latest and greatest Lazarus/FPC on it. I got FPC 2.6.2, installed it and used it to compile Lazarus 1.1. When I

Re: [Lazarus] operator overloading

2013-02-24 Thread xrfang
I confirm that it does not work.  Test program below, and the class source is attached. ==Test Program=== program test; {$mode objfpc}{$H+} uses   Classes, treap; type   TSLCounter = specialize TTreapTStringList, Integer; operator (sl1, sl2: TStringList): Boolean; begin