Re: [Lazarus] Another widget

2015-11-03 Thread JuuS
On 11/03/2015 01:51 AM, Anthony Walter wrote: > > With my last app, a deb package maker > (http://cache.getlazarus.org/images/cpugraph-deb.png) people expressed > interest. I posted the debs and haven't heard anything back, so there's > that. Patience Grasshopper...I'm working out some

Re: [Lazarus] Lazarus implementation of TListView etc?

2015-11-03 Thread Bo Berglund
On Tue, 3 Nov 2015 02:40:11 +0100, José Mejuto wrote: >El 02/11/2015 a las 20:32, Bo Berglund escribió: > >>> IMHO using lnet or Synapse would be a lot "clearer" than using the >>> overly complex Indy Library. >> I had already looked at Synapse, but it is blocking. >> I did

Re: [Lazarus] Lazarus implementation of TListView etc?

2015-11-03 Thread Bo Berglund
On Mon, 02 Nov 2015 20:32:40 +0100, Bo Berglund wrote: >On Mon, 02 Nov 2015 10:24:54 +0100, Michael Schnell > wrote: > >>On 10/31/2015 07:28 PM, Mark Morgan Lloyd wrote: >>> Alternatively look at the lnet code that comes with FPC, ... > >I did not know

Re: [Lazarus] Lazarus implementation of TListView etc?

2015-11-03 Thread Michael Schnell
I answered in a new thread "Thread-to-Mainthread signalizing", as we are getting too far off-topic. -Michael -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Re: [Lazarus] Lazarus implementation of TListView etc?

2015-11-03 Thread Bo Berglund
On Tue, 03 Nov 2015 12:03:38 +0100, Michael Schnell wrote: >For the record: > >I verified that with the gtk2 (Linux) Widget type, "PostMessage()" uses >a different Event Queue ("TGTKMessageQueue") than "TThread.Queue()" and >TThread.Synchronize()". Moved discussion to new

Re: [Lazarus] Lazarus implementation of TListView etc?

2015-11-03 Thread Michael Schnell
For the record: I verified that with the gtk2 (Linux) Widget type, "PostMessage()" uses a different Event Queue ("TGTKMessageQueue") than "TThread.Queue()" and TThread.Synchronize()". So for this, calling "CheckSynchronize() will not help. You need to use the appropriate GUI-based Widget

[Lazarus] Using event driven components in console application

2015-11-03 Thread Bo Berglund
I am moving a discussion that is being conducted in a thread named: "Lazarus implementation of TListview etc?" to this new thread since the topic has shifted away from the original This topic has to do with using communications components which fire off "OnReceive" events when data arrives

[Lazarus] Thread-to-Mainthread singallizing

2015-11-03 Thread Michael Schnell
On 11/03/2015 12:41 PM, Mark Morgan Lloyd wrote: Thanks for that, useful. That's going to impact anybody trying to convert code that uses custom Windows messages to pass events around. For Delphi users, it is a common (bad) habit to use PostMessage() for Thread to MainThread signaling. It

Re: [Lazarus] Patch for TTrayIcon on Ubuntu's Unity

2015-11-03 Thread Juha Manninen
Unfortunately I don't have much info about TrayIcons. Is it possible to add this Unity support to LCL? The idea sounds good but the discussion stopped early. Juha -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org

Re: [Lazarus] Lazarus implementation of TListView etc?

2015-11-03 Thread Mark Morgan Lloyd
Michael Schnell wrote: For the record: I verified that with the gtk2 (Linux) Widget type, "PostMessage()" uses a different Event Queue ("TGTKMessageQueue") than "TThread.Queue()" and TThread.Synchronize()". So for this, calling "CheckSynchronize() will not help. You need to use the

[Lazarus] VirtualTreeView, clicking to expand collapse only on works for first column

2015-11-03 Thread Jürgen Hestermann
In a VirtualTreeView I have icons to expand and collapse subnodes (the + and - in a square). When clicking on them with the mouse it only works when the column with these icons is the first (left) column. When I change the main column or when I move the first column to the right (so that it's not

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

2015-11-03 Thread Leonardo M . Ramé
El 03/11/15 a las 04:40, Michael Van Canneyt escribió: On Mon, 2 Nov 2015, Leonardo M. Ramé wrote: El 01/11/15 a las 09:25, Leonardo M. Ramé escribió: Hi, I don't use data aware controls too often, but as I'm updating a legacy application I have to use them. ... I finally solved this by

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Mattias Gaertner
On Tue, 3 Nov 2015 19:37:04 +0100 Ondrej Pokorny wrote: > On 03.11.2015 17:34, Mattias Gaertner wrote: > > codetools use only a simple heuristic to calculate the type of a > > binary operator. > > The function TFindDeclarationTool.CalculateBinaryOperator needs to be > >

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

2015-11-03 Thread Michael Van Canneyt
On Tue, 3 Nov 2015, Leonardo M. Ramé wrote: El 03/11/15 a las 04:40, Michael Van Canneyt escribió: On Mon, 2 Nov 2015, Leonardo M. Ramé wrote: El 01/11/15 a las 09:25, Leonardo M. Ramé escribió: Hi, I don't use data aware controls too often, but as I'm updating a legacy application I

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Ondrej Pokorny
On 03.11.2015 20:26, Mattias Gaertner wrote: procedure Test; >var >I: Integer; >S: SmallInt; >begin >Res := I + S; >end; > >Something like: >1.) >I = (Integer -> longint) >S = SmallInt >2.) >ResultBasicType = Compare(longint, SmallInt) -> longint -> I >3.) >ResultType =

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Michael Ring
Thank you for the fix, just tried it on fresh trunk, works! Michael Am 03.11.15 um 17:34 schrieb Mattias Gaertner: On Tue, 3 Nov 2015 17:24:02 +0100 Ondrej Pokorny wrote: On 03.11.2015 17:08, Mattias Gaertner wrote: Fixed. How did you find it from the description? I

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Ondrej Pokorny
On 03.11.2015 17:34, Mattias Gaertner wrote: codetools use only a simple heuristic to calculate the type of a binary operator. The function TFindDeclarationTool.CalculateBinaryOperator needs to be extended for Alias types (e.g. 'integer' instead of longint) and for ranges (e.g. if the operands

Re: [Lazarus] Using event driven components in console application

2015-11-03 Thread Bo Berglund
On Tue, 3 Nov 2015 14:55:54 +0100, Mattias Gaertner wrote: > >lnet does not use Post/SendMessage, so it works even with the NoGUI >widgetset. > >You can easily implement your own loop and simply call >Application.ProcessMessages. > Thanks, you mean that

Re: [Lazarus] Using event driven components in console application

2015-11-03 Thread Mattias Gaertner
On Tue, 03 Nov 2015 18:20:53 +0100 Bo Berglund wrote: > On Tue, 3 Nov 2015 14:55:54 +0100, Mattias Gaertner > wrote: > > > > >lnet does not use Post/SendMessage, so it works even with the NoGUI > >widgetset. > > > >You can easily implement your

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Ondrej Pokorny
Probably the best approach is: 1.) Compare base types with the table. 1a.) If they are equal, goto 2. 1b.) If they differ, set winner according to table and go to 3. 2.) Compare aliases with the table, set winner. 3.) Use the original alias of the winner as result. About the table: We need

Re: [Lazarus] Using event driven components in console application

2015-11-03 Thread Bo Berglund
On Tue, 3 Nov 2015 18:39:50 +0100, Mattias Gaertner wrote: >> you mean that Application.Processmessages is available in this console >> program? > >It is available when you use the NoGUI widgetset. How do you change which "widgetset" is used? (I really do not know what

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

2015-11-03 Thread Mark Morgan Lloyd
Leonardo M. Ramé wrote: El 03/11/15 a las 04:40, Michael Van Canneyt escribió: On Mon, 2 Nov 2015, Leonardo M. Ramé wrote: El 01/11/15 a las 09:25, Leonardo M. Ramé escribió: Hi, I don't use data aware controls too often, but as I'm updating a legacy application I have to use them. ...

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Ondrej Pokorny
On 03.11.2015 20:34, Ondrej Pokorny wrote: A problem could be with such code: var i: SizeInt; j: Integer; begin k:=i+j; end; Because obviously on 32bit SizeInt=longint and Integer=longint, so there won't be a deterministic way which type wins. But this is a similar issue like the one

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Mattias Gaertner
On Tue, 3 Nov 2015 20:34:30 +0100 Ondrej Pokorny wrote: > On 03.11.2015 20:26, Mattias Gaertner wrote: > >> procedure Test; > >> >var > >> >I: Integer; > >> >S: SmallInt; > >> >begin > >> >Res := I + S; > >> >end; > >> > > >> >Something like: > >> >1.) > >> >I =

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Mattias Gaertner
On Tue, 3 Nov 2015 21:06:45 +0100 Ondrej Pokorny wrote: > Probably the best approach is: > > 1.) Compare base types with the table. > 1a.) If they are equal, goto 2. > 1b.) If they differ, set winner according to table and go to 3. > > 2.) Compare aliases with the table, set

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Ondrej Pokorny
On 04.11.2015 02:25, Mattias Gaertner wrote: About the table: >We need one table for integer and one for floating-point types. >The integer table could look like ['int64', 'sizeint', 'integer', >'smallint'] (but with all integer types and probably a good idea to >allow the user to modify and

Re: [Lazarus] A big thank you!

2015-11-03 Thread Ondrej Pokorny
On 04.11.2015 08:23, Torsten Bonde Christiansen wrote: Dear Coder of code-completion Today after having updated my trunk Lazarus I started coding and did what I usually do with code completion. I was starting to implement a new OnSomething method and did the normal OnSomething :=

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Ondrej Pokorny
Fixed in r50217. On 04.11.2015 02:14, Mattias Gaertner wrote: A problem could be with such code: > >var >i: SizeInt; >j: Integer; >begin >k:=i+j; >end; > >Because obviously on 32bit SizeInt=longint and Integer=longint, so there >won't be a deterministic way which type wins. Left

[Lazarus] A big thank you!

2015-11-03 Thread Torsten Bonde Christiansen
Dear Coder of code-completion Today after having updated my trunk Lazarus I started coding and did what I usually do with code completion. I was starting to implement a new OnSomething method and did the normal OnSomething := @OnSomethingMethod and pressed CTRL + SHIFT + C and then this

Re: [Lazarus] Patch for TTrayIcon on Ubuntu's Unity

2015-11-03 Thread zeljko
On 11/03/2015 03:17 PM, Anthony Walter wrote: My patch checks for Unity and KDE desktop. Just remove the KDE check and it should be good to go. By the way I tested on Mint 13 Cinnamon (based on 12.04) and it still works.

Re: [Lazarus] Patch for TTrayIcon on Ubuntu's Unity

2015-11-03 Thread Juha Manninen
On Tue, Nov 3, 2015 at 4:37 PM, zeljko wrote: > I'll try to implement it in lazarus during weekend. I promise to test it under various Linux desktop systems. Juha -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org

Re: [Lazarus] Patch for TTrayIcon on Ubuntu's Unity

2015-11-03 Thread Anthony Walter
My patch checks for Unity and KDE desktop. Just remove the KDE check and it should be good to go. By the way I tested on Mint 13 Cinnamon (based on 12.04) and it still works. https://github.com/sysrpl/Lazarus.UnityAppIndicators/blob/master/lazarus/lcl/interfaces/gtk2/unitywsctrls.pas#L264 To

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Mattias Gaertner
On Tue, 3 Nov 2015 11:15:02 +0100 Michael Ring wrote: > Here's the info: > > /usr/local/bin/fpc -i > Free Pascal Compiler version 2.6.4 > > Compiler Date : 2014/02/26 > Compiler CPU Target: i386 > > --- > >LCL_PLATFORM=carbon >CPU_TARGET=i386 >

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Ondrej Pokorny
On 03.11.2015 17:08, Mattias Gaertner wrote: Fixed. How did you find it from the description? You are a wizard :) Sorry for introducing the bug in my code. But I know how it happened: it was introduced by CodeTools variable completion: procedure TIDECommands.PostponeUpdateEvents; begin

Re: [Lazarus] Using event driven components in console application

2015-11-03 Thread Mattias Gaertner
On Tue, 03 Nov 2015 14:21:27 +0100 Bo Berglund wrote: >[...] > >Application.QueuAsyncCall() uses yet an additional Event Queue. Here > >using a WidgetType is not strictly necessary, but calling > >"CheckSynchronize() will not help, either. Here, TApplication provides >

Re: [Lazarus] Patch for TTrayIcon on Ubuntu's Unity

2015-11-03 Thread zeljko
On 11/03/2015 02:22 PM, Juha Manninen wrote: Unfortunately I don't have much info about TrayIcons. Is it possible to add this Unity support to LCL? The idea sounds good but the discussion stopped early. Yes it's possible, but wm recognition should be added...eg maybe you run kde instead of

Re: [Lazarus] Lazarus in trunk not working after Rev 50151 on MacOSX

2015-11-03 Thread Mattias Gaertner
On Tue, 3 Nov 2015 17:24:02 +0100 Ondrej Pokorny wrote: > On 03.11.2015 17:08, Mattias Gaertner wrote: > > Fixed. > > How did you find it from the description? I didn't. I tested on OS X. > You are a wizard :) > Sorry for introducing the bug in my code. But I know how it