Re: [Lazarus] External SIGSEGV (random) when assigning TBookmark

2015-11-02 Thread Virgo Pärna
On Sun, 1 Nov 2015 17:06:18 +0100, Luca Olivetti <l...@wetron.es> wrote:
> El 01/11/15 a les 13:25, Leonardo M. Ramé ha escrit:
>
>> To me, the code looks correct, but I'm getting a SIGSEGV while assigning
>> the bookmark. I must add the error only happens the 2nd or 3rd time this
>> method is called:
>
> I suppose that's because the bookmark is only valid while the query is 
> opened, buy you close it between getting the bookmark and setting it.
>


Also: in my experience in Delphi closing with DisableControls
active is a bad idea. I have seen cases, when components are still
referencing old field instances.

-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] samevalue function issue

2015-09-30 Thread Virgo Pärna
On Wed, 30 Sep 2015 13:06:56 +0200, Andrea Mauri <andrea.mauri...@gmail.com> 
wrote:
> Dear all,
>
> I am using samevalue function provided with fpc (math unit).
> I am using samevalue instead of = in order to avoid problems related to 
> precision.
>

Why are you not using your own epsilon value?


>if samevalue(a, 5.1) then // I get FALSE -- I supposed to 
> get TRUE- bad!

Could you try 
samevalue(a, Double(5.1)) 
instead?


-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] How to write an eficient lexical scanner/parser?

2015-03-11 Thread Virgo Pärna
On Wed, 11 Mar 2015 08:18:35 -0700 (MST), leledumbo 
leledumbo_c...@yahoo.co.id wrote:

 No idea with what's default by law or convention, but when I give no
 license, consider it public domain.


By default author has copyright and sole right to redistribute. And
that's what applies, when nothing else is declared.

-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] Default Form placement

2015-03-09 Thread Virgo Pärna
On Mon, 9 Mar 2015 14:08:31 +0100, Kostas Michalopoulos 
badsectorac...@gmail.com wrote:

 I guess old Delphi did that (well, all Delphis i have used did that but i
 only used Delphis up to 7 and most of my Delphi experience is with Delphi
 2).


I can confirm, that in Delphi 5 default is poDesigned. So it really is 
for Delphi compatibility



-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


[Lazarus] Strange problem with Step Over (F8)

2014-09-24 Thread Virgo Pärna

I'm having very strange problem, when debuging under Lazarus. When
program is stopped and is on a method call line, then pressing F8 causes
it to step into method call, instead of going to next line. 
Lazarus 1.2.4 32 bit, Windows 7 64 bit, 64 bit crosscompiling is installed,
 but I'm I'm compiling with build mode's all set to default.

-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] Strange problem with Step Over (F8)

2014-09-24 Thread Virgo Pärna
On Wed, 24 Sep 2014 14:20:58 +0200, Reinier Olislagers 
reinierolislag...@gmail.com wrote:

 What happens if you specify dwarf2 in project options instead of the
 default (which is stabs IIRC)?


Changing debug info type to Dwarf2 made it work. Thank you.

-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] Strange problem with Step Over (F8)

2014-09-24 Thread Virgo Pärna
On Wed, 24 Sep 2014 14:44:16 +0200, Sven Barth pascaldra...@googlemail.com 
wrote:

 Does the method happen to be one of an interface? If so, that's a known
 problem for years...


Yes, it is. I guess my Google skills were not good enaugh to find it.
Anyway, using dwarf2 debug format makse Step Over work. But now Step Into 
does not work anymore.


-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] LazDaemon

2014-07-25 Thread Virgo Pärna
On Fri, 25 Jul 2014 09:18:01 +0300, Juha Manninen juha.mannine...@gmail.com 
wrote:
 On Fri, Jul 25, 2014 at 9:05 AM, Michael Van Canneyt
mich...@freepascal.org wrote:
 I will use now the FPC daemon class, it works.

 Out of curiosity: which class is that ?

 I mean the TCustomDaemon and TCustomDaemonMapper descendants as
 explained in your PDF, without using LazDaemon package.
 LazDaemon uses the same classes internally yet it does not work. Yes,
 it is strange.


Now that I think of it, I actually did not use LazDaemon. It was 
brookframework daemon, that used TCustomDaemonApplication and 
TCustomDaemonMapper. 
But lazarus daemon also inherits from TCustomDaemonApplication.

-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] LazDaemon

2014-07-24 Thread Virgo Pärna
On Thu, 24 Jul 2014 15:06:53 +0300, Juha Manninen juha.mannine...@gmail.com 
wrote:
 I think the LazDaemon package is broken at least on Windows.
 Can someone else start a Windows service made with it? I cannot.

 There is an example project
  C:\SW\lazarus_gitsvn\examples\cleandir\cleandirs.lpi
 that uses it. Trying to install it (cleandirs.exe -i with admin rights) 
 fails.
 Same thing with any other project.


You are running that cleandir.exe -i form cmd Window? Did you start cmd 
with 
Run as Administrator? 
I created a Windows service just resently with Lazarus and it works.

-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] how to TXMLPropStorage SaveToStream() LoadFromStream

2014-07-03 Thread Virgo Pärna
On Thu, 03 Jul 2014 13:26:46 +0300, FreeMan freema...@delphiturkiye.com wrote:

 I add my test project.

 03-07-2014 11:34 tarihinde, Virgo Pärna yazdı:
  At which line that error occured?
 TmyCustomXMLPropStorage(XMP).XMLConfig.SaveToStream(st);//error is hear 
 XMLConfig is NIL !!!


From LCL source TCustomXMLPropStorage.StorageNeeded Creates XMLConfig. And 
now I noticed, that TPropStorageXMLConfig indeed has stream methods. So - 
calling 
StorageNeeded before using XMLConfig should work (I have never used that 
component). 
And also remember to seek to beginning before reading from stream. 

-- 
Virgo Pärna 
virgo.pa...@mail.ee


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


Re: [Lazarus] how to TXMLPropStorage SaveToStream() LoadFromStream

2014-07-02 Thread Virgo Pärna
On Wed, 02 Jul 2014 15:56:57 +0300, FreeMan freema...@delphiturkiye.com wrote:
 without savefile to disk



TMemoryStream

-- 
Virgo Pärna 
virgo.pa...@mail.ee


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