Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Graeme Geldenhuys
On Wednesday 23/10/2013 at 19:41, ListMember wrote: As I wrote in my post: See the CRT unit. It does exactly that. You need maybe 20 lines of code to do as you want. If I used the CRT unit, would I need to add it to every single unit in the project that uses WriteLn? Please read the repl

Re: [Lazarus] Can't compile Lazarus on Linux Mint 15

2013-10-23 Thread Sven Barth
Am 24.10.2013 03:39 schrieb "silvioprog" : > > 2013/10/23 Marco van de Voort >> >> On Tue, Oct 15, 2013 at 01:52:44PM -0300, silvioprog wrote: >> > I'm trying to compila Lazarus in Linux Mint 15 ( http://www.linuxmint.com/), >> > but: >> >> Try adding >> -XLAcairo=cairo,cairo-gobject > > >

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Hans-Peter Diettrich
ListMember schrieb: On 2013-10-23 23:20, Hans-Peter Diettrich wrote: ListMember schrieb: Frankly, I agree that I should not have to modify the compiler or the RTL; especially for something like redirecting the WriteLn output from console to my own application. But, doing it through text dri

Re: [Lazarus] Can't compile Lazarus on Linux Mint 15

2013-10-23 Thread silvioprog
2013/10/23 Marco van de Voort > On Tue, Oct 15, 2013 at 01:52:44PM -0300, silvioprog wrote: > > I'm trying to compila Lazarus in Linux Mint 15 ( > http://www.linuxmint.com/), > > but: > > Try adding > -XLAcairo=cairo,cairo-gobject Sorry for my ignorance, but when I try: silvioprog@silv

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
On 2013-10-23 23:20, Hans-Peter Diettrich wrote: ListMember schrieb: Frankly, I agree that I should not have to modify the compiler or the RTL; especially for something like redirecting the WriteLn output from console to my own application. But, doing it through text drivers etc. is --how ca

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
On 2013-10-23 22:36, Sven Barth wrote: I've attached my own version of EditText which I just adjusted. It works very similar to the original version I linked, but allows to use any TCustomEdit descendant (TMemo is one of them). Thank you. But, I am still getting "exception class: 'External:

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Hans-Peter Diettrich
ListMember schrieb: Frankly, I agree that I should not have to modify the compiler or the RTL; especially for something like redirecting the WriteLn output from console to my own application. But, doing it through text drivers etc. is --how can I put it-- almost inhuman. It's basic OOP to

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Sven Barth
On 23.10.2013 21:14, ListMember wrote: On 2013-10-23 21:46, Sven Barth wrote: "Writeln" is a complex functionality. So you should better trust us (hint: I'm a compiler developer) when we say this is more difficult than you imagine. I know you're a compiler developer; and, I have no intention o

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Sven Barth
On 23.10.2013 21:01, ListMember wrote: type TMyWriteLnCallback = procedure(AText: String); var GMyWriteLnCallback: TMyCallback = nil; and then, wherever the 'compiler magic' for WriteLn is, use something like if Assigned(GMyWriteLnCallback) then GMyWriteLnCallback(TextStuff) else {do the

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Luca Olivetti
Al 23/10/13 21:01, En/na ListMember ha escrit: > > I could use the sample code you posted a link to (and, thank you also > for that), and I adapted it to use TMemo for my use. > > But, why would I have to write 100+ lines of code just to capture the > output of WriteLn. You already did that and

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Sven Barth
On 23.10.2013 18:30, leledumbo wrote: If I understood correctly, you want to override the meaning of WriteLn (for programs and units using globals.pas), right? In that case, just create Write(Ln) procedure in globals unit. That will override the system unit one. However, you can't have the one wi

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
On 2013-10-23 21:11, Marco van de Voort wrote: On Wed, Oct 23, 2013 at 09:59:04AM +0300, ListMember wrote: My ultimate goal, after finding where it is declared, is to locally modify that part of the sources so that (instead of writing to the console) it will use a global callback to display what

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
On 2013-10-23 21:46, Sven Barth wrote: "Writeln" is a complex functionality. So you should better trust us (hint: I'm a compiler developer) when we say this is more difficult than you imagine. I know you're a compiler developer; and, I have no intention of challenging you on that front --actu

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
On 2013-10-23 18:58, Sven Barth wrote: Am 23.10.2013 17:50, schrieb ListMember: This is far too (incredibly) elaborate. It's a bit like giving me plans to set up an army to invade a country when all I want to do is to visit it as a tourist :) No, this is the officially supported way to interfe

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Mark Morgan Lloyd
ListMember wrote: As I wrote in my post: See the CRT unit. It does exactly that. You need maybe 20 lines of code to do as you want. Will do, thanks. But, let me ask this: If I used the CRT unit, would I need to add it to every single unit in the project that uses WriteLn? He didn't say *

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Sven Barth
On 23.10.2013 19:39, ListMember wrote: On 2013-10-23 18:55, Michael Van Canneyt wrote: On Wed, 23 Oct 2013, ListMember wrote: And I just found an example which already does this for TCustomEdit descendants: http://kd5col.info/swag/DELPHI/0017.PAS.html I've not tested it in FPC, so maybe small

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Marco van de Voort
On Wed, Oct 23, 2013 at 09:59:04AM +0300, ListMember wrote: > > My ultimate goal, after finding where it is declared, is to locally > modify that part of the sources so that (instead of writing to the > console) it will use a global callback to display whatever WriteLn'ed in > a TMemo. There i

Re: [Lazarus] Can't compile Lazarus on Linux Mint 15

2013-10-23 Thread Marco van de Voort
On Tue, Oct 15, 2013 at 01:52:44PM -0300, silvioprog wrote: > I'm trying to compila Lazarus in Linux Mint 15 (http://www.linuxmint.com/), > but: Try adding -XLAcairo=cairo,cairo-gobject -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepasc

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
On 2013-10-23 18:55, Michael Van Canneyt wrote: On Wed, 23 Oct 2013, ListMember wrote: And I just found an example which already does this for TCustomEdit descendants: http://kd5col.info/swag/DELPHI/0017.PAS.html I've not tested it in FPC, so maybe small adjustments might be necessary... Wow

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread leledumbo
If I understood correctly, you want to override the meaning of WriteLn (for programs and units using globals.pas), right? In that case, just create Write(Ln) procedure in globals unit. That will override the system unit one. However, you can't have the one with variable number of arguments, at leas

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Sven Barth
Am 23.10.2013 17:50, schrieb ListMember: On 2013-10-23 18:10, Sven Barth wrote: Am 23.10.2013 17:06, schrieb Sven Barth: Am 23.10.2013 08:59, schrieb ListMember: Hello, I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'F

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Michael Van Canneyt
On Wed, 23 Oct 2013, ListMember wrote: And I just found an example which already does this for TCustomEdit descendants: http://kd5col.info/swag/DELPHI/0017.PAS.html I've not tested it in FPC, so maybe small adjustments might be necessary... Wow. This is far too (incredibly) elaborate. It'

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
On 2013-10-23 18:10, Sven Barth wrote: Am 23.10.2013 17:06, schrieb Sven Barth: Am 23.10.2013 08:59, schrieb ListMember: Hello, I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'Find Declaration' requests --at least that

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Anton Kavalenka
On 23.10.2013 09:59, ListMember wrote: Hello, I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'Find Declaration' requests --at least that's how it behaves (latest Lazarus stable) on my side. My ultimate goal, after fin

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Sven Barth
Am 23.10.2013 17:06, schrieb Sven Barth: Am 23.10.2013 08:59, schrieb ListMember: Hello, I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'Find Declaration' requests --at least that's how it behaves (latest Lazarus stabl

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Sven Barth
Am 23.10.2013 08:59, schrieb ListMember: Hello, I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'Find Declaration' requests --at least that's how it behaves (latest Lazarus stable) on my side. My ultimate goal, after f

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Mark Morgan Lloyd
Hans-Peter Diettrich wrote: ListMember schrieb: I'd rather find the unit where WriteLn() procedure is defined and alter it once and recompile FPC/Lazarus. But, I just can't locate where WriteLn procedure is defined. I did a grep (equivalent in Windows) but came up with nothing usable. The

Re: [Lazarus] FPPkg correction and help with TListView

2013-10-23 Thread zeljko
Citiram Geoffray « fatalerrors » Levasseur : Hi everybody, As I updated Lazarus this morning, I've seen that FPPkg is not compiling anymore. Unless the package maintener is working on this, I've made a patch, attached to that mail, to correct that. I have a more personal concern as well : I

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Hans-Peter Diettrich
ListMember schrieb: I'd rather find the unit where WriteLn() procedure is defined and alter it once and recompile FPC/Lazarus. But, I just can't locate where WriteLn procedure is defined. I did a grep (equivalent in Windows) but came up with nothing usable. The Write... procedures are compi

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread leledumbo
> I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'Find Declaration' requests --at least that's how it behaves (latest Lazarus stable) on my side. WriteLn is NOT a regular procedure. It's rather a special command for the

[Lazarus] FPPkg correction and help with TListView

2013-10-23 Thread Geoffray « fatalerrors » Levasseur
Hi everybody, As I updated Lazarus this morning, I've seen that FPPkg is not compiling anymore. Unless the package maintener is working on this, I've made a patch, attached to that mail, to correct that. I have a more personal concern as well : I would like to colorise some lines of a TListVie

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Michael Van Canneyt
On Wed, 23 Oct 2013, ListMember wrote: On 2013-10-23 11:33, Lukasz Sokol wrote: On 23/10/13 07:59, ListMember wrote: Hello, I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'Find Declaration' requests --at least that's

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
On 2013-10-23 11:33, Lukasz Sokol wrote: On 23/10/13 07:59, ListMember wrote: Hello, I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'Find Declaration' requests --at least that's how it behaves (latest Lazarus stable) on m

[Lazarus] Lazarus DOS support: success + exeinfo "problem" & debugging

2013-10-23 Thread Reinier Olislagers
I've finally managed to get my fpcup win32=>DOS crosscompiler generator going[1] and am now turning to Lazarus. After applying the patch in 25220: Support for OS msdos/CPU i8086 I tried opening a simple project with a console mode program: set target to msdos/i8086. Compiling, I get missing units

Re: [Lazarus] WriteLn back to the GUI

2013-10-23 Thread Lukasz Sokol
On 23/10/13 07:59, ListMember wrote: > Hello, > > I am trying to find where WriteLn is declared; but, apparently, > WriteLn is among the select few that Lazarus will ignore 'Find > Declaration' requests --at least that's how it behaves (latest > Lazarus stable) on my side. > > My ultimate goal, a

Re: [Lazarus] UTF8 string compare with correct locale sorting

2013-10-23 Thread Michael Schnell
I forgot to mention that in fact I like to busy myself both with Unicode Strings handling in Pascal and with String theory in theoretical physics.Otherwise I would not take part in this discussion.) But in every-day life - mostly because of Unicode - I prefer using the old Turbo-Delphi rather

Re: [Lazarus] UTF8 string compare with correct locale sorting

2013-10-23 Thread Michael Schnell
On 10/22/2013 03:21 PM, Bart wrote: "string theory is a theoretical framework in which the point-like particles of particle physics are replaced by one-dimensional objects called strings." And it's grade of complexity resembles that of Unicode ;-) . And, IMHO,both can be avoided in (my) every-d

Re: [Lazarus] Snapshots been discontinued?

2013-10-23 Thread Reinier Olislagers
On 23/10/2013 03:04, silvioprog wrote: > 2013/10/22 Reinier Olislagers > > > On 22/10/2013 14:03, silvioprog wrote: > > It is very difficult to generate a setup Lazarus? If no, I'll generate > > my own snapshots. > > FYI: fpcup can generate Win

[Lazarus] WriteLn back to the GUI

2013-10-23 Thread ListMember
Hello, I am trying to find where WriteLn is declared; but, apparently, WriteLn is among the select few that Lazarus will ignore 'Find Declaration' requests --at least that's how it behaves (latest Lazarus stable) on my side. My ultimate goal, after finding where it is declared, is to locally