Re: [Lazarus] StringGrid1.LoadFromCSVFile problem

2015-10-22 Thread fecske fecske
Lazarus SVN Rev 49771 (embed in CpdeTyphon 5.5 r49844 with FPC 3.1.1)

and csv in the attache



On Thu, Oct 22, 2015 at 9:14 PM, Jesus Reyes A.  wrote:

> On Thu, 22 Oct 2015 12:13:17 -0500, fecske fecske 
> wrote:
>
> I like to use the StringGrid1.LoadFromCSVFile() function.
> It works but also randomly ​set to a last line of strange characters
>
> ..
>
> In the CSV file normail view are not these characters. I checked csv files
> in hex viewer and  are not these characters.
>
> I did a test, I wrote a Delphi code in a delphi IDE with unique function
> and stringgrid, and  are not these characters.too.
> I use the same csv files.
>
> What's wrong in the LoadFromCSVFile() function?
>
> Please help me?
>
>
> What Lazarus version/revision do you use?. Please attach a sample csv file.
>
> Jesus Reyes A.
>
> --
> ___
> Lazarus mailing list
> Lazarus@lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
>
>


2015_10_15.log
Description: Binary data
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] StringGrid1.LoadFromCSVFile problem

2015-10-22 Thread Mattias Gaertner
On Thu, 22 Oct 2015 19:13:17 +0200
fecske fecske  wrote:

> I like to use the StringGrid1.LoadFromCSVFile() function.
> It works but also randomly ​set to a last line of strange characters
> 
> ​
> In the CSV file normail view are not these characters. I checked csv files
> in hex viewer and  are not these characters.
> 
> 
> I did a test, I wrote a Delphi code in a delphi IDE with unique function
> and stringgrid, and  are not these characters.too.
> I use the same csv files.
> 
> What's wrong in the LoadFromCSVFile() function?

In LoadFromCSVStream.StorePart the Inc(leadPtr) needs to check if at end
of stream. I added that in revision 50144.

Mattias

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


Re: [Lazarus] *SPAM* Re: How does one add an event to a blocking system?

2015-10-22 Thread Michael Schnell

On 10/21/2015 05:27 PM, Sven Barth wrote:


CheckSynchronize checks for MainThreadID which is determined 
independently of CheckSynchronize.


I see. I suppose the would-be MainThread is just the thread that is used 
to start the application. That does make sense. For the internal logic 
of the Lazarus application the fact that it calls CheckSynchronize() is 
what makes the difference.


Better usage of terms: Exceptions are thrown (or raised), events are 
signaled.
You are right. "thrown" is not a good wording for Events. I mostly read 
"fired" on that behalf.



CheckSynchronize completely walks the lost before it returns.

Thanks a lot for the correction. This is very important to me (see below).

> AFAIK the return parameter of CheckSynchronize() does not give any 
decent result and needs to be ignored.


That is indeed always "false" right now. I should check sometime what 
it is supposed to return... Probably whether at least one event got 
executed :/




Maybe the original idea was to have CheckSynchronize execute only one 
Event and return TRUE if more events up are to be handled.


With this (not existing) design, I would need to do something like:

procedure TmyApplication.ProcessMessages;
begin
while CheckSynchronize() do (*nothing*) ;
end;

With the current design just

procedure TmyApplication.ProcessMessages;
begin
CheckSynchronize();
end;

would be OK, but the code above would work, as well and maybe should be 
preferred for possible future extension.


-Michael

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


Re: [Lazarus] How does one add an event to a blocking system?

2015-10-22 Thread Mark Morgan Lloyd

Michael Schnell wrote:

On 10/21/2015 05:27 PM, Sven Barth wrote:


Better usage of terms: Exceptions are thrown (or raised), events are 
signaled.
You are right. "thrown" is not a good wording for Events. I mostly read 
"fired" on that behalf.


"Signalled" is not a good choice IMO, because of unix-style signals and 
their handlers (e.g. sending a HUP signal to a process, to get it to 
re-read its configuration).


"Triggered" can have problems if a database is being used.

"Fired" seems like a fairly good choice, since it also implies immediacy.

--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]

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


[Lazarus] The GDB command: "-gdb-set confirm off" did not return any result

2015-10-22 Thread Bo Berglund
When I try to run a very small Console Application for testing Indy10
using the green arrow run button I get a pop-up message box saying:
The GDB command: "-gdb-set confirm off" did not return any result

If I build the program instead and go to a terminal window to execute
it, then it works as it should.

Environment:

Platform: Raspberry Pi2 with ARM7 running Raspbian Jessie
FPC 3.1.1 built from sources as root
Lazarus 1.5 SVN 50059 built inside the Pi home as user pi
Test sources in Pi hme as well
TCPIP: Using Indy10 copied over from my PC using a samba share
(so the files for Indy have Windows line endings)

What could cause the GDB problem? Line endings or what?

The active code apart from what Lazarus entered:

  { add your program here }
  Writeln('Creating TCP client');
  FComm := TIdTCPClient.Create;
  try
Writeln('Connecting to www.mydomain.com on port 80');
T1 := GetTickCount;
FComm.Connect('www.mydomain.com', 80);
T2 := GetTickCount;
T2 := T2 - T1;
Writeln('Connection succeeded in ' + IntToStr(T2) + ' ms, now
closing down');
  finally
if FComm.Connected then
   FComm.Disconnect;
FComm.Free;
  end;

BTW, Indy10 seems to work fine so far


-- 
Bo Berglund
Developer in Sweden


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


Re: [Lazarus] StringGrid1.LoadFromCSVFile problem

2015-10-22 Thread Jesus Reyes A.
On Thu, 22 Oct 2015 12:13:17 -0500, fecske fecske   
wrote:



I like to use the StringGrid1.LoadFromCSVFile() function.
It works but also randomly ​set to a last line of strange characters

..
In the CSV file normail view are not these characters. I checked csv  
files in hex viewer and  are not these >characters.


I did a test, I wrote a Delphi code in a delphi IDE with unique function  
and stringgrid, and  are not these >characters.too.

I use the same csv files.

What's wrong in the LoadFromCSVFile() function?

Please help me?


What Lazarus version/revision do you use?. Please attach a sample csv file.

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


Re: [Lazarus] *SPAM* Re: Win 10 IOT Core

2015-10-22 Thread Michael Schnell

On 10/20/2015 02:22 PM, Michael Van Canneyt wrote:

Silverlight is discontinued.


To me this is the death of .NET.

Silverlight was the only excuse to call the CIL runtime ".Net 
Framework". In fact, to me, Silverlight was the only reason to consider 
".Net", because deploying a browser-plugin - in the moment it is to be 
executed -  needs to do this in an architecture and OS independent way, 
and needs for running the stuff in a "managed" environment. Here, CIL 
does make sense as it runs complex applications that way with 
close-to-native speed. (If course Java can do the same, but for obvious 
reasons M$ wanted to fight Java). Of course it's nice to be able to 
deploy such a plugin unchanged for local use, but in a local 
environment, native code deployment usually can easily be done. (An for 
those who think different, Java/Dalvik has taken it all, anyway).


It's really funny to see how the M$ marketing loves the word "Net", 
calling the (technical named CIL) perfectly normal virtual processor 
runtime-environment ".NET" and renaming plain old embedded computing 
"Internet Of Things", even though (or right because) Linux always 
technically was preferable in networking, while Windows for a long time 
was the better choice for desktop computing


-Michael

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Graeme Geldenhuys
On 2015-10-21 20:45, Aradeonas wrote:
> I Just work on one of my units with about 10,000 line of code that have
> 7 class and it makes me crazy moving in it and adding procedure or

"big" is a relative term I guess. I don't consider 10,000 lines big
these days. :)

Take a look at "Procedure List" found in the Search menu, or simply use
Alt+G  (I've changed mine to Ctrl+G). This allows you to type any text,
and the list shown will be reduced to show any partial matches. Down
arrow to highlight what you want, and ENTER to go to that code. No mouse
usage is needed. You can also use the combobox to limit matches to a
specific class.

I ported this to Lazarus many years ago, because this is by far the
fastest way to find specific code in large units - at least that is my
personal experience.

Using Editor Bookmarks are also a vital tool I use to jump to different
location in a unit, or even to other units.

Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Aradeonas
> "big" is a relative term I guess. I don't consider 10,000 lines big
> these days. :)

Yea for you its just a normal unit but for someone like me writing this
code from start and managing it is kind of hard (not much,but I want
easier!) Very good point!I didnt saw that,Thank you. I tried it (And
changed the shortcut to Ctrl+G) and it is easy to use,maybe you can add
some shortcut or a tree view for moving faster between classes.

Regards, Ara


-- 
http://www.fastmail.com - mmm... Fastmail...

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


[Lazarus] Hour of Code 2015

2015-10-22 Thread Johannes W. Dietrich

The Hour of Code is coming again!

The Hour of Code, a one-hour introduction to computer science, is a  
global movement reaching tens of millions of students in more than 180  
countries. In celebration of the Computer Science Education Week  
during December 7-13, 2015, its goal is to give every student the  
opportunity to learn the foundations of programming and information  
technology.


Anyone can organize an Hour of Code event, anywhere in the world. If  
you are a teacher, parent or potential tutorial partner you might want  
to register at http://hourofcode.com to support the movement.


The broad support of Lazarus and Free Pascal for a plethora of  
operating systems and platforms opens a great opportunity to  
communicate solid programming skills to students.


J. W. Dietrich



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


Re: [Lazarus] Hour of Code 2015

2015-10-22 Thread Sven Barth
Am 22.10.2015 22:39 schrieb "Johannes W. Dietrich" <
j.w.dietr...@medizinische-kybernetik.de>:
>
> The Hour of Code is coming again!
>
> The Hour of Code, a one-hour introduction to computer science, is a
global movement reaching tens of millions of students in more than 180
countries. In celebration of the Computer Science Education Week during
December 7-13, 2015, its goal is to give every student the opportunity to
learn the foundations of programming and information technology.
>
> Anyone can organize an Hour of Code event, anywhere in the world. If you
are a teacher, parent or potential tutorial partner you might want to
register at http://hourofcode.com to support the movement.
>
> The broad support of Lazarus and Free Pascal for a plethora of operating
systems and platforms opens a great opportunity to communicate solid
programming skills to students.
>

That "Hour of Code" project is a really nice idea (I especially loved last
year's Frozen related tutorials ^^). I hope someone finds the time and
inspiration to do something Pascal related :D

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


Re: [Lazarus] The GDB command: "-gdb-set confirm off" did not return any result

2015-10-22 Thread Bo Berglund
On Thu, 22 Oct 2015 15:07:10 +, Mark Morgan Lloyd
 wrote:

>> What could cause this? Am I not supposed to see a terminal window or
>> similar pop up?
>
>Terminal window as in controlling your program interactively (or at 
>least seeing output) or as in showing you what GDB is doing?
>

Regarding the GDB it seems like the problem disappeared when I changed
the line endings on the files I had copied from my PC via the samba
share and therefore had Windows line endings. I ran dos2unix on all of
them (except the binary files of course) and then restarted Lazarus
and tried again and now there was no GDB error message anymore.

What I really wonder about next is the fact that it is different from
in Delphi when one starts a command line program while developing.
In Delphi the black terminal window shows up and one can see the
progress of the execution there. In this case there was nothing, not
even a single message in the messages window. It was as if the program
did not run at all.
But it might be intended to be like this on Linux, this is my first
try really.

-- 
Bo Berglund
Developer in Sweden


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


Re: [Lazarus] The GDB command: "-gdb-set confirm off" did not return any result

2015-10-22 Thread Martin Frb

On 22/10/2015 22:04, Bo Berglund wrote:
What I really wonder about next is the fact that it is different from 
in Delphi when one starts a command line program while developing. In 
Delphi the black terminal window shows up and one can see the progress 
of the execution there. In this case there was nothing, not even a 
single message in the messages window. It was as if the program did 
not run at all. But it might be intended to be like this on Linux, 
this is my first try really. 


On Windows you should get a terminal, if your app was compiled as console.

On linux the terminal is just a device /dev/pty,  and the terminal in 
which the command is running does the display.


Lazarus on linux has a debug window (menu view) to show the console output

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Juha Manninen
On Thu, Oct 22, 2015 at 1:36 PM, Aradeonas  wrote:
> Yes I do because it will be unformatted while writing.
> About codetools really I dont know what it does and I never used  it and
> I read Wiki page and didnt understand how it help code formatting.

Ok, Codetools is used for many things but I meant the settings
affecting automatic code generation. See pic.
Easily half of your code gets generated automatically when you learn
to use the IDE properly.
Now you are using it wrong.

JCF is only good for importing code from somebody using strange
indentation style or something.

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


Re: [Lazarus] Lazarus implementation of TListView etc?

2015-10-22 Thread Bo Berglund
On Thu, 22 Oct 2015 17:32:30 +0100, Graeme Geldenhuys
 wrote:

>That still doesn't explain why the original Delphi code required a
>TListView instance. TListView is purely a GUI component - so I'm very
>puzzled.
>
>If you needed a list of objects, and maybe an associated text string or
>something, then use TObjectList instead. I honestly don't see why
>TListView is need in any Console application.

Is it so hard to understand that the class units were developed (a
long time ago) in Delphi7 with a target of a GUI program? Tens of
thousands of lines of code...
So it had helpers to show the recorded data in listviews and other
such GUI related stuff (like handling progressbars etc).
All of which does exactly nothing unless they have such components
assigned to them.

In this case I do not want to re-invent all of the communications and
data parsing code that is the main part of these units and which I
need to use in the lean and mean communications program I have to
build. So I do not want to rip the units apart and rewrite them if I
can avoid it. This is the only reason.
And I did get a working way to handle this by including LCL. No more
compile errors caused by these classes.

And my post at a late time in this thread was just to clarify this
situation, not to ask any more questions so there was no need for more
commenting.

-- 
Bo Berglund
Developer in Sweden


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


Re: [Lazarus] StringGrid1.LoadFromCSVFile problem

2015-10-22 Thread fecske fecske
I patch the lcsvutils.pas file based on LoadFromCSVStream:  quote from here:
https://github.com/graemeg/lazarus/commit/90eaed173991cdb8f8209726a71081299833392d

I compiled it in the ide but the problem still remains...

this video presents the phenomenon
https://youtu.be/GLXUkcrA-AA

On Thu, Oct 22, 2015 at 9:39 PM, Mattias Gaertner
 wrote:
> On Thu, 22 Oct 2015 19:13:17 +0200
> fecske fecske  wrote:
>
>> I like to use the StringGrid1.LoadFromCSVFile() function.
>> It works but also randomly set to a last line of strange characters
>>
>>
>> In the CSV file normail view are not these characters. I checked csv files
>> in hex viewer and  are not these characters.
>>
>>
>> I did a test, I wrote a Delphi code in a delphi IDE with unique function
>> and stringgrid, and  are not these characters.too.
>> I use the same csv files.
>>
>> What's wrong in the LoadFromCSVFile() function?
>
> In LoadFromCSVStream.StorePart the Inc(leadPtr) needs to check if at end
> of stream. I added that in revision 50144.
>
> Mattias
>
> --
> ___
> Lazarus mailing list
> Lazarus@lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

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


Re: [Lazarus] The GDB command: "-gdb-set confirm off" did not return any result

2015-10-22 Thread Bo Berglund
On Thu, 22 Oct 2015 22:08:18 +0100, Martin Frb 
wrote:

>On linux the terminal is just a device /dev/pty,  and the terminal in 
>which the command is running does the display.
>
>Lazarus on linux has a debug window (menu view) to show the console output

Thanks!
I did not realize that, but now I found it. I will use that in the
future!


-- 
Bo Berglund
Developer in Sweden


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


Re: [Lazarus] StringGrid1.LoadFromCSVFile problem

2015-10-22 Thread Mattias Gaertner
On Thu, 22 Oct 2015 23:18:58 +0200
fecske fecske  wrote:

> I patch the lcsvutils.pas file based on LoadFromCSVStream:  quote from here:
> https://github.com/graemeg/lazarus/commit/90eaed173991cdb8f8209726a71081299833392d
> 
> I compiled it in the ide but the problem still remains...

Yes, my issue sounded like yours, but when I saw your example I
realized you found a different bug.

The UTF16 conversion was wrong. It was missing the ending #0 wide char.
I fixed that in revision 50146.

Mattias

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Aradeonas
Thanks Juha and I checked that but still code will unformated after some
time specially tab and indent and from Delphi7 Days I always use code
formaters.Maybe its just me  

Regards,
Ara


-- 
http://www.fastmail.com - Send your email first class


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


Re: [Lazarus] The GDB command: "-gdb-set confirm off" did not return any result

2015-10-22 Thread Bo Berglund
On Thu, 22 Oct 2015 09:29:26 +, Mark Morgan Lloyd
 wrote:

>> using the green arrow run button I get a pop-up message box saying:
>> The GDB command: "-gdb-set confirm off" did not return any result
>> 
>> What could cause the GDB problem? Line endings or what?
>
>What version of gdb i.e. use the  gdb --version  command.
>
GNU gdb (Raspbian 7.7.1+dfsg-5) 7.7.1


-- 
Bo Berglund
Developer in Sweden


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


Re: [Lazarus] The GDB command: "-gdb-set confirm off" did not return any result

2015-10-22 Thread Mark Morgan Lloyd

Bo Berglund wrote:

When I try to run a very small Console Application for testing Indy10
using the green arrow run button I get a pop-up message box saying:
The GDB command: "-gdb-set confirm off" did not return any result

If I build the program instead and go to a terminal window to execute
it, then it works as it should.

Environment:

Platform: Raspberry Pi2 with ARM7 running Raspbian Jessie
FPC 3.1.1 built from sources as root
Lazarus 1.5 SVN 50059 built inside the Pi home as user pi
Test sources in Pi hme as well
TCPIP: Using Indy10 copied over from my PC using a samba share
(so the files for Indy have Windows line endings)

What could cause the GDB problem? Line endings or what?


What version of gdb i.e. use the  gdb --version  command.

--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]

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


Re: [Lazarus] *SPAM* Re: Win 10 IOT Core

2015-10-22 Thread Sven Barth
Am 22.10.2015 10:18 schrieb "Michael Schnell" :
>
> On 10/20/2015 02:22 PM, Michael Van Canneyt wrote:
>>
>> Silverlight is discontinued.
>>
> To me this is the death of .NET.
>
> Silverlight was the only excuse to call the CIL runtime ".Net Framework".
In fact, to me, Silverlight was the only reason to consider ".Net", because
deploying a browser-plugin - in the moment it is to be executed -  needs to
do this in an architecture and OS independent way, and needs for running
the stuff in a "managed" environment. Here, CIL does make sense as it runs
complex applications that way with close-to-native speed. (If course Java
can do the same, but for obvious reasons M$ wanted to fight Java). Of
course it's nice to be able to deploy such a plugin unchanged for local
use, but in a local environment, native code deployment usually can easily
be done. (An for those who think different, Java/Dalvik has taken it all,
anyway).

You are aware that even during its existance Silverlight was only a small
part of the .Net ecosystem? There are GUI desktop applications, server
applications including ASP.net, Windows Store apps, XBox games. Saying that
the discontinuation of Silverlight is the end of .Net appears very far
fetched to me. That's a bit as if the end of Symbian would have been used
to proclaim the end of Java...

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


Re: [Lazarus] *SPAM* Re: *SPAM* Re: Win 10 IOT Core

2015-10-22 Thread Michael Schnell

On 10/22/2015 11:35 AM, Sven Barth wrote:


You are aware that even during its existance Silverlight was only a 
small part of the .Net ecosystem?



Of course I am.

"Death of .NET" was a really bad wording of mine. I meant "Death of the 
.NET (CIL) Framework.



There are GUI desktop applications, ...



Yep I know. I am using several of them myself. and always am unhappy 
about their extreme slow  starting. :(


IMHO Using CIL/.NET for local applications is not a good idea at all.

-Michael

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


Re: [Lazarus] How does one add an event to a blocking system?

2015-10-22 Thread Sven Barth
Am 22.10.2015 10:21 schrieb "Mark Morgan Lloyd" <
markmll.laza...@telemetry.co.uk>:
>
> Michael Schnell wrote:
>
>> On 10/21/2015 05:27 PM, Sven Barth wrote:
>
>
>>> Better usage of terms: Exceptions are thrown (or raised), events are
signaled.
>>
>> You are right. "thrown" is not a good wording for Events. I mostly read
"fired" on that behalf.
>
>
> "Signalled" is not a good choice IMO, because of unix-style signals and
their handlers (e.g. sending a HUP signal to a process, to get it to
re-read its configuration).
>
> "Triggered" can have problems if a database is being used.
>
> "Fired" seems like a fairly good choice, since it also implies immediacy.

Yes, there is a bit of ambiguity with "signaled" and "fired" indeed seems
best :)

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Aradeonas
Yes I do because it will be unformatted while writing.
About codetools really I dont know what it does and I never used  it and
I read Wiki page and didnt understand how it help code formatting.

Regards,
Ara


-- 
http://www.fastmail.com - The professional email service


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


Re: [Lazarus] *SPAM* Re: *SPAM* Re: Win 10 IOT Core

2015-10-22 Thread Sven Barth
Am 22.10.2015 11:46 schrieb "Michael Schnell" :
>
> On 10/22/2015 11:35 AM, Sven Barth wrote:
>>
>>
>> You are aware that even during its existance Silverlight was only a
small part of the .Net ecosystem?
>>
> Of course I am.
>
> "Death of .NET" was a really bad wording of mine. I meant "Death of the
.NET (CIL) Framework.

Doesn't change anything of my argumentation... Silverlight was only a small
part of the Framework as well and most other parts are still used by others.

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Alexsander Rosa
>From my 600+ KLOC project:

Total Files:961Average File Size:629,3 lines

Source: StatSVN report

2015-10-21 17:45 GMT-02:00 Aradeonas :

> Hi,
>
> I Just work on one of my units with about 10,000 line of code that have 7
> class and it makes me crazy moving in it and adding procedure or editing
> and sometimes I get lost that where am I. Just want to ask you how you work
> with big units? how you move,browse and edit?
>
> Regards,
> Ara
>
>
> -- http://www.fastmail.com - Same, same, but different...
>
>
> --
> ___
> Lazarus mailing list
> Lazarus@lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
>
>


-- 
Atenciosamente,
Alexsander da Rosa
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus implementation of TListView etc?

2015-10-22 Thread Bo Berglund
On Wed, 21 Oct 2015 14:38:54 +0200, Michael Schnell
 wrote:

>On 10/21/2015 02:18 PM, Mattias Gaertner wrote:
>> And even if you use the Win32 widgetset, you can still have a command 
>> line program.
>Of course any executable can be started from the command line. But I 
>don't suppose that this is what Bo meant when he said he wants do do a 
>"command line program".

Right, my target is a command line program started by cron and with no
user interaction whatever. Could be thought of as a service.

But when programming it I need to use existing classes from Delphi in
which I will use a subset of the functionality only. No functions
dealing with user interface will be used at all, but in the same class
is embedded the bulk of the communications protocol and data
interpretation and translation and these I do need.

In any case adding LCL solved the compile problem for that unit.

My development machine is now also the target, a Raspberry Pi2, with
FPC and Lazarus installed but it is headless. So my interface is PuTTY
for command line work in Raspbian Jessie and for GUI (= Lazarus) I use
tightvncserver on the Pi and TightVNCclient on Windows 7.

It works fine except for some small glitches like the inability to
type { } [ ] $ @ \ | into the Lazarus code editor. I have to open the
system text editor and type it there then copy paste it into the
Lazarus editor
It seems to be some kind of problem with the way keystrokes are sent
in VNC and interpreted in the Lazarus code editor.
I can enter these chars into the Lazarus property editors of GUI
components though as well as in the Raspbian Text editor, all via VNC.

There is a separate thread about this here...

-- 
Bo Berglund
Developer in Sweden


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


Re: [Lazarus] Lazarus implementation of TListView etc?

2015-10-22 Thread Michael Schnell

On 10/22/2015 04:33 PM, Bo Berglund wrote:
Could be thought of as a service. But when programming it I need to 
use existing classes from Delphi

Poor chap.

I have been investigating exactly this for years.

I posted the results in many answers to your forum messages.

-Michael

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


Re: [Lazarus] The GDB command: "-gdb-set confirm off" did not return any result

2015-10-22 Thread Bo Berglund
On Thu, 22 Oct 2015 12:07:33 +0200, Bo Berglund
 wrote:

>On Thu, 22 Oct 2015 09:29:26 +, Mark Morgan Lloyd
> wrote:
>
>>> using the green arrow run button I get a pop-up message box saying:
>>> The GDB command: "-gdb-set confirm off" did not return any result
>>> 
>>> What could cause the GDB problem? Line endings or what?
>>
>>What version of gdb i.e. use the  gdb --version  command.
>>
>GNU gdb (Raspbian 7.7.1+dfsg-5) 7.7.1

I  have now shut down Lazarus, then used a utility to change line
endings on all text files in the Indy10 directories.
When I now start Lazarus and hit the Run button, absolutely nothing is
shown, not even pop-up error
So I made a Clean Build operation and this succeeded, so then I hit
Run again and nothing happens.

What could cause this? Am I not supposed to see a terminal window or
similar pop up?


-- 
Bo Berglund
Developer in Sweden


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


Re: [Lazarus] Working on big units

2015-10-22 Thread Graeme Geldenhuys
On 2015-10-22 12:34, Aradeonas wrote:
> changed the shortcut to Ctrl+G) and it is easy to use,maybe you can add
> some shortcut or a tree view for moving faster between classes.

When I wrote it, immediate typing reduced the search results (partial
matching anywhere was automatically enabled - matching at start is
optional from toolbar), up or down arrow (while edit had focus)
automatically moved the selection focus in the result list. Pressing TAB
(while edit had focus) switched to the ComboBox, where up and down
arrows can be used.

Others have modified the code (sometimes good, sometimes bad) since it
got integrated with Lazarus IDE. Some of the original functionality got
lost (no icons in result list any more, doesn't remember column widths
etc), but the above mentioned keyboard actions should still work (I hope).

Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Aradeonas
No shortcut and search behave badly. Doesn't search very good and for me
cant find anything good.
For now I dont know how to edit Lazarus add ones and codes (and making
patches and ... ) but it is easy to make these works. I just good at
making from scratch not updating others code (Just using :p ) .
Maybe I do that when I began to make patch for Lazarus.

Regards,
Ara


-- 
http://www.fastmail.com - Same, same, but different...


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


Re: [Lazarus] The GDB command: "-gdb-set confirm off" did not return any result

2015-10-22 Thread Mark Morgan Lloyd

Bo Berglund wrote:

On Thu, 22 Oct 2015 12:07:33 +0200, Bo Berglund
 wrote:


On Thu, 22 Oct 2015 09:29:26 +, Mark Morgan Lloyd
 wrote:


using the green arrow run button I get a pop-up message box saying:
The GDB command: "-gdb-set confirm off" did not return any result

What could cause the GDB problem? Line endings or what?

What version of gdb i.e. use the  gdb --version  command.


GNU gdb (Raspbian 7.7.1+dfsg-5) 7.7.1


I  have now shut down Lazarus, then used a utility to change line
endings on all text files in the Indy10 directories.
When I now start Lazarus and hit the Run button, absolutely nothing is
shown, not even pop-up error
So I made a Clean Build operation and this succeeded, so then I hit
Run again and nothing happens.

What could cause this? Am I not supposed to see a terminal window or
similar pop up?


Terminal window as in controlling your program interactively (or at 
least seeing output) or as in showing you what GDB is doing?


--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Aradeonas
> From my 600+ KLOC project:
>
> Total Files: 961 Average File Size: 629,3 lines
>
> Source: StatSVN report
How,Why?! ;)

Graeme I will send you screenshots.

Regards, Ara


-- 
http://www.fastmail.com - Or how I learned to stop worrying and
  love email again

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Graeme Geldenhuys
On 2015-10-22 14:23, Aradeonas wrote:
> No shortcut and search behave badly. Doesn't search very good and for me
> cant find anything good.

Can you please supply a screenshot of your Procedure List dialog with
the text you entered and what the results where And very
importantly, an example of what wasn't found that you expected it too
(eg: procedure, function or method name). I'll then take a look at what
went wrong.

I use Procedure List daily, and it finds whatever I'm looking for.

NOTE:
  Procedure List only searches the current unit (what will include
  Include files used in that unit), and only searches for procedure
  names, function names or method names. Nested (local) procedures work
  too.

  If you want to find something in all units, then you need to use
  "Search -> Find in Files..."


Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp

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


Re: [Lazarus] Lazarus implementation of TListView etc?

2015-10-22 Thread Mark Morgan Lloyd

Bo Berglund wrote:


My development machine is now also the target, a Raspberry Pi2, with
FPC and Lazarus installed but it is headless. So my interface is PuTTY
for command line work in Raspbian Jessie and for GUI (= Lazarus) I use
tightvncserver on the Pi and TightVNCclient on Windows 7.

It works fine except for some small glitches like the inability to
type { } [ ] $ @ \ | into the Lazarus code editor. I have to open the
system text editor and type it there then copy paste it into the
Lazarus editor
It seems to be some kind of problem with the way keystrokes are sent
in VNC and interpreted in the Lazarus code editor.
I can enter these chars into the Lazarus property editors of GUI
components though as well as in the Raspbian Text editor, all via VNC.


As I've already said, that's a VNC problem. And again as I've already 
said, in most cases you'll do better running Lazarus over the SSH link.


--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]

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


Re: [Lazarus] *SPAM* Re: Lazarus implementation of TListView etc?

2015-10-22 Thread Michael Schnell

On 10/21/2015 05:14 PM, Graeme Geldenhuys wrote:


  So too is the LCL-NoGUI hack.
That is why I am doing  the "Active NoGUI" LCL Widget Type that is 
supposed to be a real application

Then refactor / clean-up the code to remove such "gui" dependencies
As I pointed out in the beginning of the discussion with Bo, a (IMHO the 
only) decent way to port a "RAD" Delphi application to a headless system 
is to first modify the application (without changing the environment and 
the functionality to a "non RAD" design by separating the business logic 
and the GUI in a different set of units. Now even the original project 
has improved.


In the next step the GUI units can be modified to be dummy or provide a 
minimal local or remote monitoring/debugging user interface.


-Michael

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


Re: [Lazarus] Working on big units

2015-10-22 Thread Juha Manninen
On Thu, Oct 22, 2015 at 8:52 AM, Aradeonas  wrote:
> Very good! But sadly for me if I use JCF when I have a folded code it will
> messed up.
> It seems there are tools that I cant use because of JCF. But code formatting
> is a lot more important for me, I can write a line without!

You use JCF for your own code while editing? It makes no sense.
Adjust the Codetools code generation settings to match your coding
style instead.

Using JCF will limit you even more if you start to use the new
language features like advanced generics, class helpers etc.
JCF's parser does not understand some of the syntax and nobody
maintains it actively.
Codetool parser on the other hand is maintained. That's why I have
created this report :
 http://bugs.freepascal.org/view.php?id=19754


Regards,
Juha

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


Re: [Lazarus] Lazarus implementation of TListView etc?

2015-10-22 Thread Graeme Geldenhuys
On 2015-10-22 15:33, Bo Berglund wrote:
> But when programming it I need to use existing classes from Delphi in
> which I will use a subset of the functionality only. No functions
> dealing with user interface will be used at all, but in the same class
> is embedded the bulk of the communications protocol and data
> interpretation and translation and these I do need.


That still doesn't explain why the original Delphi code required a
TListView instance. TListView is purely a GUI component - so I'm very
puzzled.

If you needed a list of objects, and maybe an associated text string or
something, then use TObjectList instead. I honestly don't see why
TListView is need in any Console application.

Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp

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


[Lazarus] StringGrid1.LoadFromCSVFile problem

2015-10-22 Thread fecske fecske
I like to use the StringGrid1.LoadFromCSVFile() function.
It works but also randomly ​set to a last line of strange characters

​
In the CSV file normail view are not these characters. I checked csv files
in hex viewer and  are not these characters.


I did a test, I wrote a Delphi code in a delphi IDE with unique function
and stringgrid, and  are not these characters.too.
I use the same csv files.

What's wrong in the LoadFromCSVFile() function?

Please help me?


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