Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Michael Schnell
On 02/26/2010 04:10 PM, Mattias Gaertner wrote: ' There are several tools in Lazarus for this: - click compile, fpc will give identifier not found, right click on the message - popup menu - search identifier. This will search all units. On first time it may take a minute to scan the

Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Michael Schnell
On 02/26/2010 10:21 AM, Mattias Gaertner wrote: PostMessage is threadsafe, dispatch is not. Not only thread-save, but thread traversing, which is the proper function of the message delivering library service. Seemingly the function names are wisely chose (regarding the work of a parcel

Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Juha Manninen
Hi, All these are very interesting options I was not aware of, but unfortunately no search for identifiers. You must first select the error saying identifier not found and then right click on it. I tested it with some broken code and it gave no feedback at all. I think it should always give

Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Mattias Gaertner
On Mon, 01 Mar 2010 10:14:50 +0100 Michael Schnell mschn...@lumino.de wrote: On 02/26/2010 04:10 PM, Mattias Gaertner wrote: ' There are several tools in Lazarus for this: - click compile, fpc will give identifier not found, right click on the message - popup menu - search identifier.

Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Mattias Gaertner
On Mon, 1 Mar 2010 11:43:23 +0200 Juha Manninen juha.manni...@phnet.fi wrote: Hi, All these are very interesting options I was not aware of, but unfortunately no search for identifiers. You must first select the error saying identifier not found and then right click on it. I tested

Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Juha Manninen
Hi, What gave no feedback? Ok, I tested again with a non-typical situation. I worked with lazarus.lpi and built Lazarus from tools - Configure Build Lazarus. The error messages show up just like when compiling a normal project but search identifier does nothing. Now I tested with a normal

Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Michael Schnell
On 03/01/2010 10:43 AM, Juha Manninen wrote: You must first select the error saying identifier not found and then right click on it. I only can select a complete line in the message window. -Michael ___ fpc-devel maillist -

Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Mattias Gärtner
Zitat von Juha Manninen juha.manni...@phnet.fi: Hi, What gave no feedback? Ok, I tested again with a non-typical situation. I worked with lazarus.lpi and built Lazarus from tools - Configure Build Lazarus. The error messages show up just like when compiling a normal project but search

Re: [fpc-devel] procedure ... message(); in Linux

2010-03-01 Thread Mattias Gärtner
Zitat von Michael Schnell mschn...@lumino.de: On 03/01/2010 10:36 AM, Mattias Gaertner wrote: You need lazarus 0.9.29. I might try to get this running some day soon Try that on PostMessage. I get a method in unit InterfaceBase and a procedure in unit LCLIntf. Obviously you want

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Michael Schnell
On 02/25/2010 06:59 PM, Mattias Gärtner wrote: Maybe if you provide a more complete example, some Linux users can help you. Sorry, but an example how procedure ... message can be used in Linux is what I am requesting. A working example in Windows is trivial. Here it works exactly as in Delphi

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Michael Schnell
On 02/25/2010 07:47 PM, David W Noon wrote: for a couple of years. Provided you are using Lazarus classes, it works just like Windows: the PostMessage() and SendMessage() functions in the LCLIntf unit provide closely analogous functionality to their Win32 API namesakes. [In all the

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Michael Schnell
OK, Thisa does take me one step further. 1) procedure...message does wok in Linux 2) it can be triggered by Dispatch. This is good news, as FPC/Lazarus is confirmed to work as expected. :) This is bad news as now I need to consider procedure...message when doing the NoGUIApplication package. ;)

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Graeme Geldenhuys
Michael Schnell wrote: 1) procedure...message does wok in Linux 2) it can be triggered by Dispatch. And this is what I have been telling you since the start! :-) Regards, - Graeme - -- fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Mattias Gaertner
On Fri, 26 Feb 2010 09:41:15 +0100 Michael Schnell mschn...@lumino.de wrote: On 02/25/2010 07:47 PM, David W Noon wrote: for a couple of years. Provided you are using Lazarus classes, it works just like Windows: the PostMessage() and SendMessage() functions in the LCLIntf unit provide

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Mattias Gaertner
On Fri, 26 Feb 2010 09:53:44 +0100 Michael Schnell mschn...@lumino.de wrote: OK, Thisa does take me one step further. 1) procedure...message does wok in Linux 2) it can be triggered by Dispatch. This is good news, as FPC/Lazarus is confirmed to work as expected. :) This is bad news as

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Michael Schnell
On 02/26/2010 10:03 AM, Graeme Geldenhuys wrote: Michael Schnell wrote: 1) procedure...message does wok in Linux 2) it can be triggered by Dispatch. And this is what I have been telling you since the start! :-) I did not see the relevance, as I did not suppose that Dispatch is

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Michael Schnell
On 02/26/2010 10:21 AM, Mattias Gaertner wrote: PostMessage is threadsafe, dispatch is not. This is what I did suppose. Now I need to find out how to call PostMessage (as uses Classes does not make it visible). -Michael ___ fpc-devel maillist -

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Michael Schnell
On 02/26/2010 10:19 AM, Mattias Gaertner wrote: SendMessage is defined in unit LCLIntf and implemented in the LCL interfaces. Great ! This is the info I needed. with uses LCLIntf it gets compiled. Thanks, -Michael ___ fpc-devel maillist -

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-26 Thread Mattias Gaertner
On Fri, 26 Feb 2010 10:46:09 +0100 Michael Schnell mschn...@lumino.de wrote: On 02/26/2010 10:19 AM, Mattias Gaertner wrote: SendMessage is defined in unit LCLIntf and implemented in the LCL interfaces. Great ! This is the info I needed. with uses LCLIntf it gets compiled.

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-25 Thread Mattias Gärtner
Zitat von Michael Schnell mschn...@lumino.de: Can't anyone answer the question if in Linux the legal and compilable construct procedure... message; either is not supposed to be working or how I can have such a procedure be executed (e.g. by posting a message from a thread or another

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-25 Thread Nikolai Zhubr
25.02.2010 19:59, Michael Schnell: Can't anyone answer the question if in Linux the legal and compilable construct procedure... message; either is not supposed to be working Is is working fine on linux, see my example below. or how I can have such a procedure be executed (e.g. by posting

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-24 Thread Michael Schnell
So about a week ago I setup a .htaccess in the opensoft.homeip.net root website to block some of those domains. Is your domain listed in any of these? --- # Deny hosts or spam domains RewriteCond %{REMOTE_HOST} sputnikmedia.net [NC,OR] RewriteCond %{REMOTE_HOST}

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-24 Thread Michael Schnell
P.S.: I found out that homeip,net is banned here in the company's network, as in the past, there have been some frauds using this. -Michael ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-19 Thread Michael Schnell
On 02/18/2010 10:16 PM, Nikolai Zhubr wrote: ... if you are going to make this messaging work to some degree in non-main thread on windows, you'll probably need to take care of some things manually. Of course you are right that the Delphi / Windows paradigm only allows for a single message

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-19 Thread Michael Schnell
I suppose it's a glitch of our office's ID. Sorry for the inconvenience. Thanks, -Michael ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-19 Thread Michael Schnell
On 02/18/2010 10:26 PM, Graeme Geldenhuys wrote: Just thought of something else. Not sure if this is a solution, Thanks a lot for your support, but in fact I am not seeking for a solution, but the question is if the compilable FPC construct procedure ... message works at all in (Lazarus /)

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-19 Thread Graeme Geldenhuys
Michael Schnell wrote: On 02/18/2010 05:35 PM, Michael Schnell wrote: I'll try at home It works at home, No idea why it is blocked here. Is this a kind of spam-prone server ? In this last month I was bombarded with web crawlers even though I have a robots.txt file setup. So about a

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Graeme Geldenhuys
I hope I understand your question correctly... Michael Schnell wrote: What messages does it capture ? Anything that fits into 'var message' parameter. fpGUI uses the following base structure for the event queue. TfpgMessageRec = record MsgCode: integer; Sender: TObject; Dest:

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Michael Schnell
On 02/17/2010 05:46 PM, Marco van de Voort wrote: Afaik it is nothing more than a table that says for msg with value xxx call method yyy. IOW it is abstract. In Windows obviously an msg is a Windows message. But what is a msg in Linux ? -Michael

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Michael Schnell
Thanks for your valuable hints ! On 02/18/2010 09:21 AM, Graeme Geldenhuys wrote: You can obviously use other custom communications methods too. Of course I do know this, my current goal is to explore if/how I need to support procedure...message with the upcoming NoGUIApplication package.

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Michael Schnell
On 02/18/2010 09:21 AM, Graeme Geldenhuys wrote: How to send a message from another process ? On example would be to use IPC as defined in the SimpleIPC unit - part of FCL. SimpleIPC documentation can be found at: http://www.freepascal.org/docs-html/fcl/simpleipc/index.html

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Michael Schnell
On 02/18/2010 09:21 AM, Graeme Geldenhuys wrote: fpGUI has an internal event queue which later gets dispatched to the target using TObject.Dispatch(). fpGUI v0.4 and earlier used a Object based even system and had it's own distribution functions. Later version of fpGUI uses Record based

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Sergei Gorelkin
Michael Schnell wrote: Yep. Here you need to do a server and a client and it does not seem to use procedure message. But In Delphi/Windows you don't need to create a server. Just using procedure message is enough o receive a message from another process. Things are more complicated

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Jonas Maebe
On 18 Feb 2010, at 14:41, Michael Schnell wrote: Lazarus does have a directory /lazarus/lcl/interfaces/fpgui/ but it does not contain a file fpg_main.* and fpgPostMessage is not mentioned in any file :(. http://www.google.com/search?q=fpgui Jonas

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Michael Schnell
On 02/18/2010 02:48 PM, Sergei Gorelkin wrote:If this is possible with FPC/Linux, I should make sure that it's still possible with the NoGUIApplication package. Windows has a built-in transport for the messages, Linux doesn't. Of course there are libraries providing similar or even better

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Michael Schnell
On 02/18/2010 02:49 PM, Jonas Maebe wrote: http://www.google.com/search?q=fpgui Of course I did try this, but the project seems to be abandoned: http://opensoft.homeip.net/fpgui/ ERROR The requested URL could not be retrieved ___

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Jonas Maebe
On 18 Feb 2010, at 16:44, Michael Schnell wrote: Of course I did try this, but the project seems to be abandoned: http://opensoft.homeip.net/fpgui/ ERROR The requested URL could not be retrieved It works fine here. Jonas ___ fpc-devel

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Marc Weustink
Michael Schnell wrote: On 02/18/2010 02:48 PM, Sergei Gorelkin wrote:If this is possible with FPC/Linux, I should make sure that it's still possible with the NoGUIApplication package. Windows has a built-in transport for the messages, Linux doesn't. Of course there are libraries providing

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Michael Schnell
On 02/18/2010 05:12 PM, Marc Weustink wrote: Nope. On non windows widgetrsets, lazarus implements its own messagequeue which is handled in application.Idle. I'll try to find out how this works(and how things like Timer and the waiting for events are done). Maybe it's an alternative to use

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Michael Schnell
On 02/18/2010 04:50 PM, Jonas Maebe wrote: On 18 Feb 2010, at 16:44, Michael Schnell wrote: Of course I did try this, but the project seems to be abandoned: http://opensoft.homeip.net/fpgui/ ERROR The requested URL could not be retrieved It works fine here. I'll try at home

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Graeme Geldenhuys
On 18 February 2010 15:41, Michael Schnell mschn...@** wrote: my fpc sources don't have any fpg* files other than fpglibc* and fpgtk*. Lazarus does have a directory /lazarus/lcl/interfaces/fpgui/ but it does not contain a file fpg_main.* and fpgPostMessage is not mentioned in any file

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Nikolai Zhubr
18.02.2010 16:16, Michael Schnell: [trim] use procedure message. But In Delphi/Windows you don't need to create a server. Just using procedure message is enough o receive a message from another process. No. AFAIK even in Delphi, message procedures for non-components are pretty much

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-18 Thread Graeme Geldenhuys
On 17 February 2010 16:47, Michael Schnell mschn...@lumino.de wrote: What messages does it capture ? How to send a message from a thread ? Just thought of something else. Not sure if this is a solution, but it might head you in the right direction. Have a look at two behavioural design

Re: [fpc-devel] procedure ... message(); in Linux

2010-02-17 Thread Marco van de Voort
In our previous episode, Michael Schnell said: How to send a message from a thread ? How to send a message from another process ? I do know that there are other (supposedly more decent) ways to do inter-thread and inter-process communication, But as procedure...message(), does compile in

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Michael Schnell
peter green wrote: What does the compiler do when translating procedure ... message ? I need to know this as I want to create a non-GUI workalike of the TApplication class that can do things like TTimer TThread.Synchronize, Message events, etc, using Windows messages in Windows (for testing

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Vincent Snijders
Michael Schnell schreef: peter green wrote: What does the compiler do when translating procedure ... message ? I need to know this as I want to create a non-GUI workalike of the TApplication class that can do things like TTimer TThread.Synchronize, Message events, etc, using Windows messages

RE: [fpc-devel] procedure ... message

2007-02-13 Thread Thorsten Engler
That is the result of what is happening. Most of it is done by the library (the compiler can't do this by itself), and I am trying to use some home-brew library functions here. What I wanted to know is how the compiler does this (or how I can find out what exactly it

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Michael Schnell
I see you are still a bit lost. Maybe the documentation can help: http://www.freepascal.org/docs-html/ref/refsu24.html I in fact am lost (as I still don't dare to try to look into the compiler's source code). Unfortunately the docs text does not say what code the compiler generates to make

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Michael Schnell
What happens is that the compiler creates an try in the message table of the RTTI for the class. Check out the implementation of Tobject.Dispatch to see how that is used. Thanks. That seems to give me a clue. I have no idea what creates a try means but maybe I'll find out. Thanks again,

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Vincent Snijders
Michael Schnell schreef: I see you are still a bit lost. Maybe the documentation can help: http://www.freepascal.org/docs-html/ref/refsu24.html I in fact am lost (as I still don't dare to try to look into the compiler's source code). Unfortunately the docs text does not say what code the

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Michael Schnell
See implementation of dispatch. It gets the message number and looks for the corresponding method in a table. The compiler generates this table at compile time. Thanks. I did try to find it but am lost up till now. regarding Thorsten's message I assume it is a member function to some class

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Micha Nelissen
Michael Schnell wrote: What happens is that the compiler creates an try in the message table of the RTTI for the class. Check out the implementation of Tobject.Dispatch to see how that is used. Thanks. That seems to give me a clue. I have no idea what creates a try means but maybe I'll

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Michael Schnell
Thorsten Engler wrote: Thanks. That seems to give me a clue. I have no idea what creates a try means but maybe I'll find out. Should have been an entry Sorry for not guessing this :-\ . Now I need to find out what exactly it puts into the RTTI and how to extract it from there. Also I

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Michael Schnell
creates an entry most probably. Right. Thanks. -Michael (not a native speaker :-( ) ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Michael Schnell
Thanks. I did try to find it but am lost up till now. regarding Thorsten's message I assume it is a member function to some class (e.g. TObject), but my usual means to find such functions don't show it to me. Sorry. Found it ! Thanks again. -Michael

Re: [fpc-devel] procedure ... message

2007-02-13 Thread Michael Schnell
Somewhere user code must call MyObject.Dispatch(MyMessage); This looks as if this might be good news. The dispatch mechanism seems to be completely platform independent and so it seems I just need to fire the normal (obviously hierarchical) dispatch mechanism when a message arrives.

RE: [fpc-devel] procedure ... message

2007-02-12 Thread peter green
What does the compiler do when translating procedure ... message ? I need to know this as I want to create a non-GUI workalike of the TApplication class that can do things like TTimer TThread.Synchronize, Message events, etc, using Windows messages in Windows (for testing purpose) and