From michael at freepascal.org Sun Apr 1 10:49:27 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Sun, 1 Apr 2018 10:49:27 +0200 (CEST) Subject: [Lazarus] First click disappearing Message-ID: Hi, I'm completely puzzled by the following bug: My setup: trunk lazarus, FPC 3.1.1, GTK2 widgetset. in the FPReport report designer the first click almost anywhere is simply not registered in any OnMouseDown handler. I have tried to reproduce this in a more simple program, but failed till now. Stephano (patspiper at gmail.com) can reliably reproduce this as well, and reported that he has observed the same problem for some time in the source editor of the lazarus IDE as well, but it disappeared after some weeks (presumably something was fixed) The strange thing is that it can be reproduced in the dialogs of the program, as well, not just in the main window. To reproduce: * compile the reportdesign program (components/fpreport/design) using FPC 3.1.1. * Start program * Load design attached to bug 33453 (any other will do as well) * click on a field -> nothing happens. (onmousedown is not called, I debugged this) * click again on the field -> field is selected See also https://bugs.freepascal.org/view.php?id=33453 and the 2 related bugs. Michael. From florian at freepascal.org Sun Apr 1 19:37:13 2018 From: florian at freepascal.org (Florian Klaempfl) Date: Sun, 1 Apr 2018 19:37:13 +0200 Subject: [Lazarus] TP-like nested comment handling Message-ID: <03cb3ab9-81f9-73b8-1e0e-9a7ab935aa7c@freepascal.org> I am playing with some old code which assumes TP-like handling of nested comments: i.e. there is only one level of nested comments, the first comment limiter closes a comment. However, Lazarus handles comments like FPC: it counts the nesting level and does syntax highlighting accordingly. Is there any option I am missing so I get correct syntax highlighting for TP-like nested comment handling? From florian at freepascal.org Sun Apr 1 19:38:13 2018 From: florian at freepascal.org (Florian Klaempfl) Date: Sun, 1 Apr 2018 19:38:13 +0200 Subject: [Lazarus] TP-like nested comment handling Message-ID: I am playing with some old code which assumes TP-like handling of nested comments: i.e. there is only one level of nested comments, the first comment limiter closes a comment. However, Lazarus handles comments like FPC: it counts the nesting level and does syntax highlighting accordingly. Is there any option I am missing so I get correct syntax highlighting for TP-like nested comment handling? From florian at freepascal.org Sun Apr 1 20:39:35 2018 From: florian at freepascal.org (=?UTF-8?Q?Florian_Kl=c3=a4mpfl?=) Date: Sun, 1 Apr 2018 20:39:35 +0200 Subject: [Lazarus] TP-like nested comment handling Message-ID: <5fcd2867-84d7-9831-3454-7890d26ba062@freepascal.org> I am playing with some old code which assumes TP-like handling of nested comments: i.e. there is only one level of nested comments, the first comment limiter closes a comment. However, Lazarus handles comments like FPC: it counts the nesting level and does syntax highlighting accordingly. Is there any option I am missing so I get correct syntax highlighting for TP-like nested comment handling? From tc at epidata.info Tue Apr 3 10:52:07 2018 From: tc at epidata.info (Torsten Bonde Christiansen) Date: Tue, 3 Apr 2018 10:52:07 +0200 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour Message-ID: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> Dear List. The bug report: https://bugs.freepascal.org/view.php?id=33331 has completely changed the behavious of how TTreeview behave! The old behaviour (sending OLD current node in OnChanging, sending NEW/SELECTED node in OnChange) is consistent across other components as well. The bug report is closed so i cannot make an objection to this "fix". It has created a heck loads of bug in our programs due to this change - can this please be reverted?!? Kind regards, Torsten Bonde Christiansen From tc at epidata.info Tue Apr 3 12:53:33 2018 From: tc at epidata.info (Torsten Bonde Christiansen) Date: Tue, 3 Apr 2018 12:53:33 +0200 Subject: [Lazarus] Test Message-ID: <78780f5a-7a13-3689-976b-cb0d73fe238d@epidata.info> please disregard this message -Torsten From sysrpl at gmail.com Mon Apr 2 15:51:30 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Mon, 2 Apr 2018 09:51:30 -0400 Subject: [Lazarus] A fix for an annoying problem on Linux Message-ID: Here you go ... ​ -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: fix-gtk2.png Type: image/png Size: 140756 bytes Desc: not available URL: From ganmax at narod.ru Tue Apr 3 14:41:10 2018 From: ganmax at narod.ru (Maxim Ganetsky) Date: Tue, 3 Apr 2018 15:41:10 +0300 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour In-Reply-To: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> References: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> Message-ID: <911910fe-e11b-3fca-931c-134620990198@narod.ru> 03.04.2018 11:52, Torsten Bonde Christiansen via Lazarus пишет: > Dear List. > > The bug report: https://bugs.freepascal.org/view.php?id=33331 > > has completely changed the behavious of how TTreeview behave! > > The old behaviour (sending OLD current node in OnChanging, sending > NEW/SELECTED node in OnChange) is consistent across other components as > well. > > The bug report is closed so i cannot make an objection to this "fix". > > It has created a heck loads of bug in our programs due to this change - > can this please be reverted?!? I reopened this bug report. Please comment there. -- Best regards, Maxim Ganetsky mailto:ganmax at narod.ru From tc at epidata.info Tue Apr 3 14:53:55 2018 From: tc at epidata.info (Torsten Bonde Christiansen) Date: Tue, 3 Apr 2018 14:53:55 +0200 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour In-Reply-To: <911910fe-e11b-3fca-931c-134620990198@narod.ru> References: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> <911910fe-e11b-3fca-931c-134620990198@narod.ru> Message-ID: <55961038-389e-0106-e67d-cf84b875906f@epidata.info> On 2018-04-03 14:41, Maxim Ganetsky via Lazarus wrote: > > 03.04.2018 11:52, Torsten Bonde Christiansen via Lazarus пишет: >> Dear List. >> >> The bug report: https://bugs.freepascal.org/view.php?id=33331 >> >> has completely changed the behavious of how TTreeview behave! >> >> The old behaviour (sending OLD current node in OnChanging, sending >> NEW/SELECTED node in OnChange) is consistent across other components as >> well. >> >> The bug report is closed so i cannot make an objection to this "fix". >> >> It has created a heck loads of bug in our programs due to this change - >> can this please be reverted?!? > I reopened this bug report. Please comment there. > Thank you Maxim! -Torsten. From nc-gaertnma at netcologne.de Tue Apr 3 15:02:31 2018 From: nc-gaertnma at netcologne.de (Mattias Gaertner) Date: Tue, 3 Apr 2018 15:02:31 +0200 Subject: [Lazarus] TP-like nested comment handling In-Reply-To: <03cb3ab9-81f9-73b8-1e0e-9a7ab935aa7c@freepascal.org> References: <03cb3ab9-81f9-73b8-1e0e-9a7ab935aa7c@freepascal.org> Message-ID: <20180403150231.111308f9@limapholos.matflo.wg> On Sun, 1 Apr 2018 19:37:13 +0200 Florian Klaempfl via Lazarus wrote: > I am playing with some old code which assumes TP-like handling of nested > comments: i.e. there is only one level of nested comments, the first > comment limiter closes a comment. However, Lazarus handles comments like > FPC: it counts the nesting level and does syntax highlighting > accordingly. Is there any option I am missing so I get correct syntax > highlighting for TP-like nested comment handling? Here this is highlighted and parsed correctly: {$mode tp} { { } begin end. How do you tell Lazarus that the unit is tp mode? Mattias From wkitty42 at windstream.net Tue Apr 3 15:40:36 2018 From: wkitty42 at windstream.net (wkitty42 at windstream.net) Date: Tue, 3 Apr 2018 09:40:36 -0400 Subject: [Lazarus] A fix for an annoying problem on Linux In-Reply-To: References: Message-ID: <955e9eeb-977a-5da1-7797-2d3ee376be02@windstream.net> On 04/02/2018 09:51 AM, Anthony Walter via Lazarus wrote: > Here you go ... what did you change? i see the code you added but i do not see any difference in the pictures you posted... -- NOTE: No off-list assistance is given without prior approval. *Please keep mailing list traffic on the list unless* *a signed and pre-paid contract is in effect with us.* From michael at freepascal.org Tue Apr 3 15:51:06 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Tue, 3 Apr 2018 15:51:06 +0200 (CEST) Subject: [Lazarus] A fix for an annoying problem on Linux In-Reply-To: <955e9eeb-977a-5da1-7797-2d3ee376be02@windstream.net> References: <955e9eeb-977a-5da1-7797-2d3ee376be02@windstream.net> Message-ID: On Tue, 3 Apr 2018, wkitty42--- via Lazarus wrote: > On 04/02/2018 09:51 AM, Anthony Walter via Lazarus wrote: >> Here you go ... > > > what did you change? i see the code you added but i do not see any difference > in > the pictures you posted... The value for the dropdown in the property editor has now a surrounding rectangle. I also had to look really carefully to see it. Michael. From rik at graficalc.nl Tue Apr 3 15:51:30 2018 From: rik at graficalc.nl (Rik van Kekem) Date: Tue, 3 Apr 2018 15:51:30 +0200 Subject: [Lazarus] A fix for an annoying problem on Linux In-Reply-To: <955e9eeb-977a-5da1-7797-2d3ee376be02@windstream.net> References: <955e9eeb-977a-5da1-7797-2d3ee376be02@windstream.net> Message-ID: Op 03-04-2018 15:40 schreef wkitty42--- via Lazarus: > On 04/02/2018 09:51 AM, Anthony Walter via Lazarus wrote: >> Here you go ... > > > what did you change? i see the code you added but i do not see any > difference in the pictures you posted... It's a very (very) subtle difference... It will add the focus-line at the top and bottom within the edit. (in this case in red but depends on color-scheme) Rik From freedos.la at gmail.com Tue Apr 3 16:38:39 2018 From: freedos.la at gmail.com (Ralf Quint) Date: Tue, 3 Apr 2018 07:38:39 -0700 Subject: [Lazarus] A fix for an annoying problem on Linux In-Reply-To: References: <955e9eeb-977a-5da1-7797-2d3ee376be02@windstream.net> Message-ID: On 4/3/2018 6:51 AM, Rik van Kekem via Lazarus wrote: > Op 03-04-2018 15:40 schreef wkitty42--- via Lazarus: >> On 04/02/2018 09:51 AM, Anthony Walter via Lazarus wrote: >>> Here you go ... >> >> >> what did you change? i see the code you added but i do not see any >> difference in the pictures you posted... > > It's a very (very) subtle difference... > > It will add the focus-line at the top and bottom within the edit. > (in this case in red but depends on color-scheme) Well, would have really helped if the OP mentioned that with one simple sentence. I did not see that either until looking again after Michael mentioned it... :( Ralf --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus From florian at freepascal.org Tue Apr 3 21:18:44 2018 From: florian at freepascal.org (=?UTF-8?Q?Florian_Kl=c3=a4mpfl?=) Date: Tue, 3 Apr 2018 21:18:44 +0200 Subject: [Lazarus] TP-like nested comment handling In-Reply-To: <20180403150231.111308f9@limapholos.matflo.wg> References: <03cb3ab9-81f9-73b8-1e0e-9a7ab935aa7c@freepascal.org> <20180403150231.111308f9@limapholos.matflo.wg> Message-ID: <9d0682ff-5161-cef7-4855-a56d0384e1d9@freepascal.org> Am 03.04.2018 um 15:02 schrieb Mattias Gaertner via Lazarus: > On Sun, 1 Apr 2018 19:37:13 +0200 > Florian Klaempfl via Lazarus wrote: > >> I am playing with some old code which assumes TP-like handling of nested >> comments: i.e. there is only one level of nested comments, the first >> comment limiter closes a comment. However, Lazarus handles comments like >> FPC: it counts the nesting level and does syntax highlighting >> accordingly. Is there any option I am missing so I get correct syntax >> highlighting for TP-like nested comment handling? > > Here this is highlighted and parsed correctly: > > {$mode tp}> { { } > begin > end. > > How do you tell Lazarus that the unit is tp mode? Well, only in the Project options because I didn't want to modify the source, this is why I asked how to switch the behavior (I found out I can do this by changing the highlighter to delphi). BTW: {$mode iso/extpas} do not change the behavior either, only $mode tp does. From werner.pamler at freenet.de Wed Apr 4 09:22:00 2018 From: werner.pamler at freenet.de (Werner Pamler) Date: Wed, 4 Apr 2018 09:22:00 +0200 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour In-Reply-To: <911910fe-e11b-3fca-931c-134620990198@narod.ru> References: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> <911910fe-e11b-3fca-931c-134620990198@narod.ru> Message-ID: Am 03.04.2018 um 14:41 schrieb Maxim Ganetsky via Lazarus: > I reopened this bug report. Please comment there. But since other opinions are required we should discuss here - the bug tracker is not the place for discussion. I applied the change leading to this issue would like to hear other opinions. Here's what I wrote in bug tracker: "I don't see anything wrong in the logics of the new behavior: The OnChanging event is fired before the selected node is changed. It has the node which will become the new selected node as a parameter, and you can do some validation and signal in AllowChange whether the change to the new node will be allowed or not. In the event handler you still have access to the currently selected node as TreeView.Selected. Therefore, there is no need at all to duplicate the currently selected node in the node parameter of the event. This behavior is now compatible with Delphi (it was not before the fix). Like any bugfix the new code breaks backward compatibility - sorry for the inconvenience if you have relied on the old behavior. Which other controls have the OnChanging event? I only found TPageControl/TTabControl but they don't pass the changing tab as a parameter. " From lazarus at kluug.net Wed Apr 4 09:32:13 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Wed, 4 Apr 2018 09:32:13 +0200 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour In-Reply-To: References: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> <911910fe-e11b-3fca-931c-134620990198@narod.ru> Message-ID: <550bbc18-780a-4e88-135b-78666b129729@kluug.net> You have to list all LCL incompatibilities in the release notes. For 1.9/1.10 they are located at http://wiki.freepascal.org/Lazarus_1.10.0_release_notes Ondrej From tc at epidata.info Wed Apr 4 09:32:59 2018 From: tc at epidata.info (Torsten Bonde Christiansen) Date: Wed, 4 Apr 2018 09:32:59 +0200 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour In-Reply-To: References: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> <911910fe-e11b-3fca-931c-134620990198@narod.ru> Message-ID: <10eba6b9-4c99-45f7-48db-c1ced44a7e77@epidata.info> On 2018-04-04 09:22, Werner Pamler via Lazarus wrote: > Am 03.04.2018 um 14:41 schrieb Maxim Ganetsky via Lazarus: >> I reopened this bug report. Please comment there. > > But since other opinions are required we should discuss here - the bug > tracker is not the place for discussion. I applied the change leading > to this issue would like to hear other opinions. Here's what I wrote > in bug tracker: > > "I don't see anything wrong in the logics of the new behavior: The > OnChanging event is fired before the selected node is changed. It has > the node which will become the new selected node as a parameter, and > you can do some validation and signal in AllowChange whether the > change to the new node will be allowed or not. In the event handler > you still have access to the currently selected node as > TreeView.Selected. Therefore, there is no need at all to duplicate the > currently selected node in the node parameter of the event. > > This behavior is now compatible with Delphi (it was not before the fix). > > Like any bugfix the new code breaks backward compatibility - sorry for > the inconvenience if you have relied on the old behavior. > > Which other controls have the OnChanging event? I only found > TPageControl/TTabControl but they don't pass the changing tab as a > parameter. " > I can understand the need for being Delphi compatible, but I'm not a fan of changing a behaviour (which IMHO is not a bug) like this which can potentially affect a lot of places in user code. Regards, Torsten. From juha.manninen62 at gmail.com Wed Apr 4 10:05:38 2018 From: juha.manninen62 at gmail.com (Juha Manninen) Date: Wed, 4 Apr 2018 11:05:38 +0300 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour In-Reply-To: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> References: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> Message-ID: On Tue, Apr 3, 2018 at 11:52 AM, Torsten Bonde Christiansen via Lazarus wrote: > The old behaviour (sending OLD current node in OnChanging, sending > NEW/SELECTED node in OnChange) is consistent across other components as > well. Please list those other components. Juha From werner.pamler at freenet.de Wed Apr 4 10:09:44 2018 From: werner.pamler at freenet.de (Werner Pamler) Date: Wed, 4 Apr 2018 10:09:44 +0200 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour In-Reply-To: <10eba6b9-4c99-45f7-48db-c1ced44a7e77@epidata.info> References: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> <911910fe-e11b-3fca-931c-134620990198@narod.ru> <10eba6b9-4c99-45f7-48db-c1ced44a7e77@epidata.info> Message-ID: <6fdf78cf-d996-0f1f-1e9f-a4752d9195c2@freenet.de> Am 04.04.2018 um 09:32 schrieb Torsten Bonde Christiansen via Lazarus: > OnI can understand the need for being Delphi compatible, but I'm not a > fan of changing a behaviour (which IMHO is not a bug) like this which > can potentially affect a lot of places in user code. Sometimes when Delphi has a bug it makes sense to give up Delphi compatibility. But here the Delphi behavior is very logical, the old Lazarus behavior simply does not make any sense. It is necessary to know the new node in order to be able decide whether the node change should be performed. I doubt whether a "lot of places" is affected in your code - it is only the OnChanging event handler where you must replace "Node" by "TreeView.Selected". Of course, it depends on the number of treeviews involved, but I doubt also that every treeview has an OnChanging handler. So, please be realistic. From tc at epidata.info Wed Apr 4 10:12:21 2018 From: tc at epidata.info (Torsten Bonde Christiansen) Date: Wed, 4 Apr 2018 10:12:21 +0200 Subject: [Lazarus] Changes to bugreport #33331 completely changes long standing behaviour In-Reply-To: References: <69d7d72d-6be8-e068-2236-d37c43a2be30@epidata.info> Message-ID: On 2018-04-04 10:05, Juha Manninen via Lazarus wrote: > On Tue, Apr 3, 2018 at 11:52 AM, Torsten Bonde Christiansen via > Lazarus wrote: >> The old behaviour (sending OLD current node in OnChanging, sending >> NEW/SELECTED node in OnChange) is consistent across other components as >> well. > Please list those other components. I apologize for this - my memory played tricks on me as i though tabcontrol/pagecontrol (and the likes) also passed the items.... -Torsten. -------------- next part -------------- An HTML attachment was scrubbed... URL: From aaa5500 at ya.ru Wed Apr 4 14:23:39 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Wed, 4 Apr 2018 15:23:39 +0300 Subject: [Lazarus] Text for TIdleText in OI Message-ID: - AutoEndEvent - the event that causes the automatic end of the timer what is "end of timer"? Pls write "interrupt of timer tick" or "disabling of timer". -- Regards, Alexey From nc-gaertnma at netcologne.de Wed Apr 4 14:42:54 2018 From: nc-gaertnma at netcologne.de (Mattias Gaertner) Date: Wed, 4 Apr 2018 14:42:54 +0200 Subject: [Lazarus] Text for TIdleText in OI In-Reply-To: References: Message-ID: <20180404144254.13eca2cb@limapholos.matflo.wg> On Wed, 4 Apr 2018 15:23:39 +0300 AlexeyT via Lazarus wrote: > - AutoEndEvent - the event that causes the automatic end of the timer There is no TIdleText. You mean "TCustomIdleTimer.AutoEndEvent". > what is "end of timer"? AutoEndEvent defines, when the timer is stopped by setting Enabled to false. This is one of the following events: - on application becomes idle - on application stops being idle (e.g. user input or some timer fired) - user input, e.g. key press, mouse move I improved the docs. Mattias From j.w.dietrich at medizinische-kybernetik.de Thu Apr 5 00:31:08 2018 From: j.w.dietrich at medizinische-kybernetik.de (Johannes W. Dietrich) Date: Thu, 5 Apr 2018 00:31:08 +0200 Subject: [Lazarus] Foundation dead? Message-ID: There is a discussion in the Forum at http://forum.lazarus.freepascal.org/index.php/topic,40770.0.html about the Free Pascal and Lazarus foundation possibly to be dead. I hope that I am wrong. Can anybody here clarify this issue? Thanks, Johannes -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- PD Dr. med. Johannes W. Dietrich -- Laboratory XU44, Endocrine Research -- Medical Hospital I, Bergmannsheil University Hospitals -- Ruhr University of Bochum -- Buerkle-de-la-Camp-Platz 1, D-44789 Bochum, NRW, Germany -- Phone: +49:234:302-6400, Fax: +49:234:302-6403 -- eMail: "johannes.dietrich at ruhr-uni-bochum.de" -- http://www.thyreologie.com.de -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at freepascal.org Thu Apr 5 00:35:53 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Thu, 5 Apr 2018 00:35:53 +0200 (CEST) Subject: [Lazarus] Foundation dead? In-Reply-To: References: Message-ID: On Thu, 5 Apr 2018, Johannes W. Dietrich via Lazarus wrote: > There is a discussion in the Forum at http://forum.lazarus.freepascal.org/index.php/topic,40770.0.html about the Free Pascal and Lazarus foundation possibly to be dead. > > I hope that I am wrong. Can anybody here clarify this issue? No, it is not dead. Why would people suggest that ? For example, Pas2js is actively developed by the foundation. Michael. From sysrpl at gmail.com Thu Apr 5 08:04:15 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Thu, 5 Apr 2018 02:04:15 -0400 Subject: [Lazarus] Dark themed lazarus Message-ID: I finally got an acceptable darked themed version of Lazarus setup. http://cache.getlazarus.org/images/lazarus-dark.png Running Linux Cinnamon Theme is named Arc Darkest Maxmimus extension added to remove titlebars Code editor colors mostly ripped from VS Code Btw, if anyone runs Linux Gtk2 Lazarus, please let me know if feel you the Object Inspector grid is laggy (actually hits the CPU at 50% on my 2.6 GHz Core2Duo) when mouse dragging through properties. I wrote a fix that reduces the amount of work it does when redrawing items, but since the OI doesn't seem laggy on Windows/Mac/Qt, I hesitate to submit my patch. -------------- next part -------------- An HTML attachment was scrubbed... URL: From hnb.code at gmail.com Thu Apr 5 08:41:06 2018 From: hnb.code at gmail.com (Maciej Izak) Date: Thu, 5 Apr 2018 08:41:06 +0200 Subject: [Lazarus] Dark themed lazarus In-Reply-To: References: Message-ID: 2018-04-05 8:04 GMT+02:00 Anthony Walter via Lazarus < lazarus at lists.lazarus-ide.org>: > I finally got an acceptable darked themed version of Lazarus setup. > Looks good for me :) any link to patch/tests? -- Best regards, Maciej Izak -------------- next part -------------- An HTML attachment was scrubbed... URL: From nc-gaertnma at netcologne.de Thu Apr 5 08:58:24 2018 From: nc-gaertnma at netcologne.de (Mattias Gaertner) Date: Thu, 5 Apr 2018 08:58:24 +0200 Subject: [Lazarus] Dark themed lazarus In-Reply-To: References: Message-ID: <20180405085824.3f504636@limapholos.matflo.wg> On Thu, 5 Apr 2018 02:04:15 -0400 Anthony Walter via Lazarus wrote: > I finally got an acceptable darked themed version of Lazarus setup. > > http://cache.getlazarus.org/images/lazarus-dark.png > > Running Linux Cinnamon > Theme is named Arc Darkest > Maxmimus extension added to remove titlebars > Code editor colors mostly ripped from VS Code > > Btw, if anyone runs Linux Gtk2 Lazarus, please let me know if feel you the > Object Inspector grid is laggy (actually hits the CPU at 50% on my 2.6 GHz > Core2Duo) when mouse dragging through properties. I wrote a fix that > reduces the amount of work it does when redrawing items, but since the OI > doesn't seem laggy on Windows/Mac/Qt, I hesitate to submit my patch. Can you give more details about the gtk2 patch? Mattias From aaa5500 at ya.ru Thu Apr 5 10:40:21 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Thu, 5 Apr 2018 11:40:21 +0300 Subject: [Lazarus] TIdleTimer doc Message-ID: <96530701-dc5b-ea13-40e0-4c9c3e12dc6b@ya.ru> >AutoEnabled - if True, Timer is automatically enabled >Interval - The Interval (in milliseconds) for which the timer is to run (Interval : TTimer, TIdleTimer) I suggest to change: AutoEnabled - allows to use properties AutoStartEvent, AutoEndEvent, i.e. automatically start/stop timer, when events occur. Interval - delay in milliseconds, which passes before firing OnTimer event. -- Regards, Alexey From aaa5500 at ya.ru Thu Apr 5 12:04:51 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Thu, 5 Apr 2018 13:04:51 +0300 Subject: [Lazarus] Suggestion for Pascal SynEdit syntax from SublimeText Message-ID: <8ce27d8b-eb33-089c-91d6-d1e34539655b@ya.ru> Sublime hilites names after procedure/function (also need: constructor/destructor) with special color. Good to have in Lazarus. It's nice. Screenshot: https://postimg.org/image/iho2n957b/ -- Regards, Alexey From sysrpl at gmail.com Thu Apr 5 12:16:57 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Thu, 5 Apr 2018 06:16:57 -0400 Subject: [Lazarus] Dark themed lazarus In-Reply-To: <20180405085824.3f504636@limapholos.matflo.wg> References: <20180405085824.3f504636@limapholos.matflo.wg> Message-ID: About the patch, I am still making some changes, but what I've done is the this. Currently the object inspector draws every row even if it doesn't need redrawing. I modified the SetItemIndex method to InvalidateRect the OldIndex and NewIndex, then only redraw those two rows in DoPaint. I added a public Fast property for testing so that you can toggle between the old behavior and new behavior at runtime, allowing users to measure the difference both in responsiveness and CPU usage. So far with this change if you click, hold down the mouse, and drag up/down quickly in the inspector the lag seems greatly reduced, as well as less CPU usage. I have not testing how this effects Windows/Qt/Mac yet, but as I said in my OP those platforms/widget sets did not suffer from the same laggy like behavior. Either way, shortly I'll submit it with a patch, a stand alone example testing program, and let others try it for themselves. Next I might tackle the lagginess in drag moving controls on the form designer. Does that seem like a laggy problem to anyone else? -------------- next part -------------- An HTML attachment was scrubbed... URL: From hnb.code at gmail.com Thu Apr 5 12:21:05 2018 From: hnb.code at gmail.com (Maciej Izak) Date: Thu, 5 Apr 2018 12:21:05 +0200 Subject: [Lazarus] Dark themed lazarus In-Reply-To: References: <20180405085824.3f504636@limapholos.matflo.wg> Message-ID: 2018-04-05 12:16 GMT+02:00 Anthony Walter via Lazarus < lazarus at lists.lazarus-ide.org>: > Next I might tackle the lagginess in drag moving controls on the form > designer. Does that seem like a laggy problem to anyone else? > Probably you mean : https://bugs.freepascal.org/view.php?id=33486 I was not able to spend enough time on this problem, so any patch is welcome. -- Best regards, Maciej Izak -------------- next part -------------- An HTML attachment was scrubbed... URL: From sysrpl at gmail.com Thu Apr 5 12:33:21 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Thu, 5 Apr 2018 06:33:21 -0400 Subject: [Lazarus] Dark themed lazarus In-Reply-To: References: <20180405085824.3f504636@limapholos.matflo.wg> Message-ID: Maceij, I get the same lag both in the docked form designer and the normal form designer when it comes to dragging controls around the form. My idea is to create a bit, and not actually move the controls when you are dragging, but rather move or resize an overlay window previewing the new shape. Only when you release the mouse would it hide the overlay and reposition or resize the selected controls. As a side enhancement, it would display information about the top, left, width, and height of the changes inside the overlay as you dragged. Also it might display the name and class of the control centered within the overlay. Does that sound reasonable? -------------- next part -------------- An HTML attachment was scrubbed... URL: From lazarus at mfriebe.de Thu Apr 5 13:29:23 2018 From: lazarus at mfriebe.de (Martin Frb) Date: Thu, 5 Apr 2018 13:29:23 +0200 Subject: [Lazarus] Suggestion for Pascal SynEdit syntax from SublimeText In-Reply-To: <8ce27d8b-eb33-089c-91d6-d1e34539655b@ya.ru> References: <8ce27d8b-eb33-089c-91d6-d1e34539655b@ya.ru> Message-ID: On 05/04/2018 12:04, AlexeyT via Lazarus wrote: > Sublime hilites names after procedure/function (also need: > constructor/destructor) with special color. Good to have in Lazarus. > It's nice. Screenshot: > > https://postimg.org/image/iho2n957b/ > Feel free to add a feature request on mantis. It wont be a priority though. patches welcome (but must include option => configure-able color settings) The HL may have to detect if the color is of, so it will not create unnecessary range-objects.  (depends if there are extra objects needed) From j.w.dietrich at medizinische-kybernetik.de Fri Apr 6 09:03:43 2018 From: j.w.dietrich at medizinische-kybernetik.de (Johannes W. Dietrich) Date: Fri, 6 Apr 2018 09:03:43 +0200 Subject: [Lazarus] Foundation dead? In-Reply-To: References: Message-ID: <900A79D1-D520-456B-A3B2-ADE424D1E545@medizinische-kybernetik.de> OK, I am happy to read this. JWD -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- PD Dr. med. Johannes W. Dietrich -- Laboratory XU44, Endocrine Research -- Medical Hospital I, Bergmannsheil University Hospitals -- Ruhr University of Bochum -- Buerkle-de-la-Camp-Platz 1, D-44789 Bochum, NRW, Germany -- Phone: +49:234:302-6400, Fax: +49:234:302-6403 -- eMail: "johannes.dietrich at ruhr-uni-bochum.de" -- http://www.thyreologie.com.de -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -------------- next part -------------- An HTML attachment was scrubbed... URL: From rgschmitt at web.de Fri Apr 6 17:26:22 2018 From: rgschmitt at web.de (Reinhold) Date: Fri, 6 Apr 2018 17:26:22 +0200 Subject: [Lazarus] Lazarus - Windows NT4 Message-ID: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> Hi, I compiled a lazarus project with lazarus 1.8.0 and 1.8.2. This error occurs (s. appendix): With 1.6.4 is no problem. Is this a bug, or is Win NT4 out of time? Thank you. Regard, linkat -------------- next part -------------- A non-text attachment was scrubbed... Name: NT4.PNG Type: image/png Size: 10091 bytes Desc: not available URL: From mailinglists at geldenhuys.co.uk Fri Apr 6 20:29:03 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Fri, 6 Apr 2018 19:29:03 +0100 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> Message-ID: <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> On 2018-04-06 16:26, Reinhold via Lazarus wrote: > I compiled a lazarus project with lazarus 1.8.0 and 1.8.2. This error > occurs (s. appendix): > > With 1.6.4 is no problem. > > Is this a bug, or is Win NT4 out of time? It's not so much about Lazarus as far as I know, but more about which version of FPC (the compiler) you are using. You can install different versions of FPC and use them all with the same copy of Lazarus - I do this all the time. You probably need FPC 2.6.x or FPC 2.4.x to support NT4. I'm sure the wiki will tell you when which Windows versions got dropped. Search the wiki for the FPC changelogs. 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 From kapibara.pas at aol.com Sat Apr 7 06:28:24 2018 From: kapibara.pas at aol.com (kapibara) Date: Sat, 7 Apr 2018 06:28:24 +0200 Subject: [Lazarus] View All a/v Message-ID: Hi guys, is this a bug or a problem with my installation: Right-clicking the component palette, then selecting "View All" results in access violation. GTK2, Debian 9 64bit, latest laz trunk and FPC3.0.4rc1 [2017/08/05] for x86_64 From pascaldragon at googlemail.com Sat Apr 7 08:47:32 2018 From: pascaldragon at googlemail.com (Sven Barth) Date: Sat, 07 Apr 2018 06:47:32 +0000 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> Message-ID: Graeme Geldenhuys via Lazarus schrieb am Fr., 6. Apr. 2018, 20:29: > On 2018-04-06 16:26, Reinhold via Lazarus wrote: > > I compiled a lazarus project with lazarus 1.8.0 and 1.8.2. This error > > occurs (s. appendix): > > > > With 1.6.4 is no problem. > > > > Is this a bug, or is Win NT4 out of time? > > It's not so much about Lazarus as far as I know, but more about which > version of FPC (the compiler) you are using. You can install different > versions of FPC and use them all with the same copy of Lazarus - I do > this all the time. > > You probably need FPC 2.6.x or FPC 2.4.x to support NT4. I'm sure the > wiki will tell you when which Windows versions got dropped. Search the > wiki for the FPC changelogs. > If you'd look at the screenshot you'd see that the function FlashWindowEx is missing. That one is not used by the RTL or the FCL and thus must be used by the LCL. Note: to check if other functions are missing as well you can use the Dependency Walker (google it) *on* the system in question with the binary in question. Regards, Sven > -------------- next part -------------- An HTML attachment was scrubbed... URL: From markMLl.lazarus at telemetry.co.uk Sat Apr 7 09:41:16 2018 From: markMLl.lazarus at telemetry.co.uk (Mark Morgan Lloyd) Date: Sat, 7 Apr 2018 07:41:16 +0000 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> Message-ID: On 06/04/18 18:30, Graeme Geldenhuys via Lazarus wrote: > On 2018-04-06 16:26, Reinhold via Lazarus wrote:> I compiled a lazarus project with lazarus 1.8.0 and 1.8.2. This error > occurs (s. appendix):> > With 1.6.4 is no problem.> > Is this a bug, or is Win NT4 out of time? > It's not so much about Lazarus as far as I know, but more about whichversion of FPC (the compiler) you are using. You can install differentversions of FPC and use them all with the same copy of Lazarus - I dothis all the time. > You probably need FPC 2.6.x or FPC 2.4.x to support NT4. I'm sure thewiki will tell you when which Windows versions got dropped. Search thewiki for the FPC changelogs. I agree, with the caveat that each version of Lazarus tends to work with a fairly tight range of compiler versions. I can't give accurate version numbers without spending time looking things up, but somewhere around 2.6.x FPC started assuming Unicode handling that was documented but unimplemented in NT4. At that point there was a simple patch which could be applied to the RTL (?) to fix it, but realistically it made that version the last that supported NT (and I suspect '98). I appreciate that some people have no choice but to use NT4, typically because it is running on rack-mounted "industrial computers" or similar. But I'd suggest that wherever there is a choice it would be better to look at W2K if at all possible, which while still well out of support at least doesn't "self destruct" like XP. At the very least, use W2K for development and then test on NT4. 18803 is relevant but might not be the only issue. -- Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues] From mailinglists at geldenhuys.co.uk Sat Apr 7 12:22:31 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Sat, 7 Apr 2018 11:22:31 +0100 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> Message-ID: <82ae2982-69c9-b370-69f3-6d9944415ff1@geldenhuys.co.uk> On 2018-04-07 08:41, Mark Morgan Lloyd via Lazarus wrote: > At the very least, use W2K for > development and then test on NT4. I still to this today. Win2000 is my default Win32 development environment (when using FPC) - running in a VM of course. No nag screens, no constant license checks, super low on resources, small install and rock solid. :) It's by far my favourite Windows version of all times. 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 From bartjunk64 at gmail.com Sat Apr 7 19:07:09 2018 From: bartjunk64 at gmail.com (Bart) Date: Sat, 7 Apr 2018 19:07:09 +0200 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> Message-ID: On Sat, Apr 7, 2018 at 8:47 AM, Sven Barth via Lazarus wrote: > If you'd look at the screenshot you'd see that the function FlashWindowEx is > missing. That one is not used by the RTL or the FCL and thus must be used by > the LCL. ($lazarus)\lcl\interfaces\win32\win32callback.inc appr at line 850 Bart From mailinglists at geldenhuys.co.uk Sat Apr 7 19:24:13 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Sat, 7 Apr 2018 18:24:13 +0100 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> Message-ID: <0ee886ee-a96e-2ab3-6c74-e0d7b67df880@geldenhuys.co.uk> On 2018-04-07 18:07, Bart via Lazarus wrote: >> If you'd look at the screenshot you'd see that the function FlashWindowEx is >> missing. That one is not used by the RTL or the FCL and thus must be used by >> the LCL. > > ($lazarus)\lcl\interfaces\win32\win32callback.inc appr at line 850 According to MSDN https://msdn.microsoft.com/en-us/library/windows/desktop/ms679347(v=vs.85).aspx it doesn't look like a very important/critical API call (introduced in Windows XP). So maybe the original poster can comment out that call in LCL-Win32, then recompile LCL and his app and see how it goes. With some luck in might work. 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 From juha.manninen62 at gmail.com Sat Apr 7 20:14:19 2018 From: juha.manninen62 at gmail.com (Juha Manninen) Date: Sat, 7 Apr 2018 21:14:19 +0300 Subject: [Lazarus] View All a/v In-Reply-To: References: Message-ID: On Sat, Apr 7, 2018 at 7:28 AM, kapibara via Lazarus wrote: > Hi guys, is this a bug or a problem with my installation: Right-clicking the > component palette, then selecting "View All" results in access violation. > > GTK2, Debian 9 64bit, latest laz trunk and FPC3.0.4rc1 [2017/08/05] for > x86_64 It works here. Can you open the Component List from View menu or by shortcut Ctrl-Alt-P? Could you provide a debugger backtrace. Juha From kapibara.pas at aol.com Sun Apr 8 07:23:00 2018 From: kapibara.pas at aol.com (kapibara) Date: Sun, 8 Apr 2018 07:23:00 +0200 Subject: [Lazarus] View All a/v In-Reply-To: References: Message-ID: <140cf6b3-d42f-0e41-5496-42676a4d52b3@aol.com> No, the Component List could not be opened with neither Ctrl+Alt+P nor shortcut. I'm not much of a debugger, but opened lazarus.lpi in Lazarus IDE and set a breakpoint for DoShowComponentList. When Lazarus started from Run (without RunLazarus), it used a fresh set of config files and lo and behold, no a/v anymore. So it is the installation, and no bug. If there's no simple trick to fix the config, I just do a re-install. On 04/07/2018 08:14 PM, Juha Manninen via Lazarus wrote: > On Sat, Apr 7, 2018 at 7:28 AM, kapibara via Lazarus > wrote: >> Hi guys, is this a bug or a problem with my installation: Right-clicking the >> component palette, then selecting "View All" results in access violation. >> >> GTK2, Debian 9 64bit, latest laz trunk and FPC3.0.4rc1 [2017/08/05] for >> x86_64 > It works here. Can you open the Component List from View menu or by > shortcut Ctrl-Alt-P? > Could you provide a debugger backtrace. > > Juha -------------- next part -------------- An HTML attachment was scrubbed... URL: From juha.manninen62 at gmail.com Sun Apr 8 08:24:18 2018 From: juha.manninen62 at gmail.com (Juha Manninen) Date: Sun, 8 Apr 2018 09:24:18 +0300 Subject: [Lazarus] View All a/v In-Reply-To: <140cf6b3-d42f-0e41-5496-42676a4d52b3@aol.com> References: <140cf6b3-d42f-0e41-5496-42676a4d52b3@aol.com> Message-ID: On Sun, Apr 8, 2018 at 8:23 AM, kapibara via Lazarus wrote: > No, the Component List could not be opened with neither Ctrl+Alt+P nor > shortcut. > > I'm not much of a debugger, but opened lazarus.lpi in Lazarus IDE and set a > breakpoint for DoShowComponentList. When Lazarus started from Run (without > RunLazarus), it used a fresh set of config files and lo and behold, no a/v > anymore. So it is the installation, and no bug. If there's no simple trick > to fix the config, I just do a re-install. No, you must delete or rename the config directory (~/.lazarus) instead if the problem is there. The installation itself is OK. Reinstallation does not affect the local configuration. Juha From juha.manninen62 at gmail.com Sun Apr 8 10:26:26 2018 From: juha.manninen62 at gmail.com (Juha Manninen) Date: Sun, 8 Apr 2018 11:26:26 +0300 Subject: [Lazarus] View All a/v In-Reply-To: References: <140cf6b3-d42f-0e41-5496-42676a4d52b3@aol.com> Message-ID: I have no idea what configuration setting could cause such an error. The config format was changed a lot when the configurable desktops were introduced. Maybe some leftover setting from before that time can trigger an error. I don't know. You probably need to start with a clean configuration and adjust the needed settings + install needed packages. Juha From kapibara.pas at aol.com Sun Apr 8 22:05:19 2018 From: kapibara.pas at aol.com (kapibara) Date: Sun, 8 Apr 2018 22:05:19 +0200 Subject: [Lazarus] View All a/v In-Reply-To: References: <140cf6b3-d42f-0e41-5496-42676a4d52b3@aol.com> Message-ID: <4f64efd9-e07f-7908-bb8c-8f1df5d3996f@aol.com> The a/v began after an SVN update so you are most likely right. Thanks for help. On 04/08/2018 10:26 AM, Juha Manninen via Lazarus wrote: > I have no idea what configuration setting could cause such an error. > The config format was changed a lot when the configurable desktops > were introduced. Maybe some leftover setting from before that time can > trigger an error. I don't know. > You probably need to start with a clean configuration and adjust the > needed settings + install needed packages. > > Juha From bartjunk64 at gmail.com Sun Apr 8 22:46:47 2018 From: bartjunk64 at gmail.com (Bart) Date: Sun, 8 Apr 2018 22:46:47 +0200 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: <0ee886ee-a96e-2ab3-6c74-e0d7b67df880@geldenhuys.co.uk> References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> <0ee886ee-a96e-2ab3-6c74-e0d7b67df880@geldenhuys.co.uk> Message-ID: On Sat, Apr 7, 2018 at 7:24 PM, Graeme Geldenhuys via Lazarus wrote: > it doesn't look like a very important/critical API call (introduced in > Windows XP). So maybe the original poster can comment out that call in > LCL-Win32, then recompile LCL and his app and see how it goes. With some > luck in might work. IIRC this is about 1.8? Then if I understand the release notes correctly, the NT 4 platform is not supported anymore. Bart From mailinglists at geldenhuys.co.uk Sun Apr 8 23:04:33 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Sun, 8 Apr 2018 22:04:33 +0100 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> <0ee886ee-a96e-2ab3-6c74-e0d7b67df880@geldenhuys.co.uk> Message-ID: <483ce652-3e77-e1ec-7008-d62fa8a96012@geldenhuys.co.uk> On 2018-04-08 21:46, Bart via Lazarus wrote: > Then if I understand the release notes correctly, the NT 4 platform is > not supported anymore. I point was, that if the NT4 support is broken simply because LCL-Win32 is now using the FlashWindowEx API, then it is pretty easy to resolve. Simply comment out the FlashWindowEx usage - it's not a vital API anyway. It simply flashes the application titlebar (actually the icon in the taskbar - if memory serves me) to draw the end-users attention to the application. But like I also mentioned... "you might be lucky" in that that is the only non NT4 API. If you are not so lucky, then there might be other API's that also break NT4 support. In which case it might be worth using an older LCL version for that application, or adding IFDEF's to LCL-Win32 to keep NT4 support going for a while longer. The amount of effort is up to the original poster of this thread. 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 From markMLl.lazarus at telemetry.co.uk Mon Apr 9 10:21:02 2018 From: markMLl.lazarus at telemetry.co.uk (Mark Morgan Lloyd) Date: Mon, 9 Apr 2018 08:21:02 +0000 Subject: [Lazarus] Lazarus - Windows NT4 In-Reply-To: <483ce652-3e77-e1ec-7008-d62fa8a96012@geldenhuys.co.uk> References: <97103ba4-abc6-2d9a-8018-cea98ea7a26f@web.de> <3a9f0147-d94c-e95b-75e5-4fcc7c8d6619@geldenhuys.co.uk> <0ee886ee-a96e-2ab3-6c74-e0d7b67df880@geldenhuys.co.uk> <483ce652-3e77-e1ec-7008-d62fa8a96012@geldenhuys.co.uk> Message-ID: On 08/04/18 21:15, Graeme Geldenhuys via Lazarus wrote: > But like I also mentioned... "you might be lucky" in that that is theonly non NT4 API. If you are not so lucky, then there might be otherAPI's that also break NT4 support. In which case it might be worth usingan older LCL version for that application, or adding IFDEF's toLCL-Win32 to keep NT4 support going for a while longer. The amount ofeffort is up to the original poster of this thread. There's actually two cases here. The first is where a statically-linked entry point is not available, which can only be fixed by an IFDEF. The second is where a function is available but not fully implemented, and where the caller- i.e. code written by an FPC or Lazarus contributor- isn't checking for an error in an ill-considered attempt at efficiency. -- Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues] From aaa5500 at ya.ru Mon Apr 9 18:44:10 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Mon, 9 Apr 2018 19:44:10 +0300 Subject: [Lazarus] LazUtf16.IsUTF16CharValid ok? Message-ID: <0f046aae-de65-cd48-8ce9-5137d6ad817d@ya.ru> function IsUTF16CharValid(AChar, ANextChar: WideChar): Boolean; begin   if AChar = #0 then Exit(False);   Result := ((AChar >= #$D800) and (AChar <= #$DBFF)) and not ((ANextChar >= #$DC00) and (ANextChar <= #$DFFF));   //Result := (Word(AChar) in [$D800..$DBFF]) and not (Word(ANextChar) in [$DC00..$DFFF]); <= generates range check error   Result := not Result; end; maybe better if func also gives True for chars <$D800. -- Regards, Alexey From larrydalton71 at gmail.com Mon Apr 9 19:55:37 2018 From: larrydalton71 at gmail.com (Larry Dalton) Date: Mon, 9 Apr 2018 13:55:37 -0400 Subject: [Lazarus] MySQL table won't update. Message-ID: I am using the following: Linux Mint 17, MySQL 5.5, Lazarus 1.6.2 64 bit. Problem: MySQL Database BankOfAmerica, table Checking won't hold an update. I can update the data in the dbedits or in the dbgrid. When I press refresh button on BOAGator it pulls up the original data and eliminates any new rows. Same thing when I close the form out and re-open it. What step am I missing? Source code: unit CheckingUnit; {$mode objfpc}{$H+} interface uses Classes, SysUtils, mysql55conn, sqldb, db, FileUtil, Forms, Controls, Graphics, Dialogs, ExtCtrls, Buttons, DbCtrls, DBGrids, StdCtrls, DBExtCtrls; type { TCheckingForm } TCheckingForm = class(TForm) CloseButton: TBitBtn; BOAConnection: TMySQL55Connection; BoaSource: TDataSource; BOAQuery: TSQLQuery; BoaTransaction: TSQLTransaction; BOAGator: TDBNavigator; BOAGrid: TDBGrid; CheckNumMemo: TDBMemo; CheckToMemo: TDBMemo; EditBalance: TDBEdit; EditReceived: TDBEdit; EditSpent: TDBEdit; EditEntryDate: TDBDateEdit; EditTransaction: TDBEdit; Label1: TLabel; Label2: TLabel; Label3: TLabel; Label4: TLabel; Label5: TLabel; Label6: TLabel; Label7: TLabel; StatusPanel: TPanel; ToolPanel: TPanel; procedure CloseButtonClick(Sender: TObject); procedure FormClose(Sender: TObject; var CloseAction: TCloseAction); private { private declarations } public { public declarations } end; var CheckingForm: TCheckingForm; implementation {$R *.lfm} { TCheckingForm } procedure TCheckingForm.CloseButtonClick(Sender: TObject); begin Close; end; procedure TCheckingForm.FormClose(Sender: TObject; var CloseAction: TCloseAction ); begin CloseAction:=cafree; end; end. -------------- next part -------------- An HTML attachment was scrubbed... URL: From sysrpl at gmail.com Mon Apr 9 20:15:46 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Mon, 9 Apr 2018 14:15:46 -0400 Subject: [Lazarus] E,bedding a terminal window in Lazarus Message-ID: It looks like adding a terminal window to any Gtk 2/3 application isn't that difficult if you use a library called libvte. I am considering writing an IDE package to do this, but wanted to know if anyone knows if this has been done before, and if the libvte functions already have a pascal declaration, or maybe an LCL compatible exampl somewhere. Here is a brief overview: https://cache.getlazarus.org/videos/libvte-question.mp4 -------------- next part -------------- An HTML attachment was scrubbed... URL: From mailinglists at geldenhuys.co.uk Mon Apr 9 21:39:39 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Mon, 9 Apr 2018 20:39:39 +0100 Subject: [Lazarus] MySQL table won't update. In-Reply-To: References: Message-ID: On 2018-04-09 18:55, Larry Dalton via Lazarus wrote: > What step am I missing? Probably missing the ApplyUpdates() call - to send all local updates to the DB server. 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 From larrydalton71 at gmail.com Mon Apr 9 22:03:52 2018 From: larrydalton71 at gmail.com (larrydalton71) Date: Mon, 09 Apr 2018 16:03:52 -0400 Subject: [Lazarus] MySQL table won't update. In-Reply-To: Message-ID: <5acbc72b.4229810a.96619.24bf@mx.google.com> Apparently wiki.lazarus.freepascal is down. I can't get to the tutorial. Sent from my Verizon, Samsung Galaxy smartphone -------- Original message --------From: Graeme Geldenhuys via Lazarus Date: 4/9/18 15:39 (GMT-05:00) To: lazarus at lists.lazarus-ide.org Cc: Graeme Geldenhuys Subject: Re: [Lazarus] MySQL table won't update. On 2018-04-09 18:55, Larry Dalton via Lazarus wrote: > What step am I missing? Probably missing the ApplyUpdates() call - to send all local updates to the DB server. 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 at lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus -------------- next part -------------- An HTML attachment was scrubbed... URL: From leledumbo_cool at yahoo.co.id Tue Apr 10 05:26:25 2018 From: leledumbo_cool at yahoo.co.id (leledumbo) Date: Mon, 9 Apr 2018 20:26:25 -0700 (MST) Subject: [Lazarus] E,bedding a terminal window in Lazarus In-Reply-To: References: Message-ID: <1523330785900-0.post@n3.nabble.com> > I am considering writing an IDE package to do this, but wanted to know if anyone knows if this has been done before AFAIK, no. Previous attempts don't embed actual terminal, but use a terminal like component with application controlled command to execute. -- Sent from: http://free-pascal-lazarus.989080.n3.nabble.com/ From markMLl.lazarus at telemetry.co.uk Tue Apr 10 10:48:06 2018 From: markMLl.lazarus at telemetry.co.uk (Mark Morgan Lloyd) Date: Tue, 10 Apr 2018 08:48:06 +0000 Subject: [Lazarus] E,bedding a terminal window in Lazarus In-Reply-To: <1523330785900-0.post@n3.nabble.com> References: <1523330785900-0.post@n3.nabble.com> Message-ID: On 10/04/18 03:30, leledumbo via Lazarus wrote: >> I am considering writing an IDE package to do this, but wanted to know ifanyone knows if this has been done before > AFAIK, no. Previous attempts don't embed actual terminal, but use aterminal like component with application controlled command to execute. Could I throw one thing in here which probably isn't immediately helpful. A couple of months ago, working on Linux, I experimented with embedding Xnest/Xephyr sessions in LCL (GTK2?) panels, with the object being to present multiple copies of a program that refused to run more than one instance per X server on the same screen. It didn't work directly, but I was /was/ in the end able to embed an xterm in an LCL panel, then embed Xnest/Xephyr in the xterm... it was crude since I'd put minimal effort into sizing etc. the panels, but it worked as a POC. So I suspect that there's something- possibly a Window Manager hint- that's being unnecessarily propagated into panels that possibly needn't be, and that is likely to cause problems embedding at least some standalone programs (as distinct from specially-written components). -- Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues] From kapibara.pas at aol.com Tue Apr 10 19:34:34 2018 From: kapibara.pas at aol.com (kapibara) Date: Tue, 10 Apr 2018 19:34:34 +0200 Subject: [Lazarus] Lazarus translation Message-ID: <7a789628-9c0d-758a-32ea-5cf334641b6d@aol.com> There is no swedish translation of Lazarus, how can I make one? From sysrpl at gmail.com Tue Apr 10 23:15:39 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Tue, 10 Apr 2018 17:15:39 -0400 Subject: [Lazarus] E,bedding a terminal window in Lazarus In-Reply-To: References: <1523330785900-0.post@n3.nabble.com> Message-ID: Okay, well I got some stuff done. I'm able to create a fully working terminal application using fpc, but when I try to incorporate it into a TWinControl there are some problems: https://cache.getlazarus.org/videos/vte-control.mp4 Notably, I believe the LCL gtk2 widgetset makes some core assumptions about the internal memory layout of any PGtkWidget that do not apply to a PVteTerminal. This is causing access violations when it interacts with the LCL as the LCL tries to access structures and that do not exists. Here is the code for the TTerminal control (designed to work only on gtk2). Maybe someone could recommend a fix? https://pastebin.com/y8wFvKsg A code archive for both projects here: http://cache.getlazarus.org/archives/simterm.7z -------------- next part -------------- An HTML attachment was scrubbed... URL: From sysrpl at gmail.com Wed Apr 11 05:12:52 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Tue, 10 Apr 2018 23:12:52 -0400 Subject: [Lazarus] Terminal Component Available Message-ID: I'm am starting a new thread because I've completed my task. Here is a terminal component for Lazarus that is easy to reuse. https://cache.getlazarus.org/archives/terminal.7z To install, make sure you're on Linux with a Gtk2 copy of Lazarus. Open package terminaldsgn.lpk, install, and rebuild the IDE. You'll have a TTerminal component on your pallet. Drop it on a form, press run, and you have your own terminal program. Here is a longish video walk through of how it works: https://cache.getlazarus.org/videos/vte-finished.mp4 The source code is completely free, copy left, if anyone wants to reuse it. Notes, you need to be using Linux and have libvte for gtk2 installed to use the component. You can be running other platforms, but you'll just see the design time surface it you're not on Linux. -------------- next part -------------- An HTML attachment was scrubbed... URL: From sysrpl at gmail.com Wed Apr 11 08:43:22 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Wed, 11 Apr 2018 02:43:22 -0400 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: I updated my archive to include support for a dockable window inside the Lazarus IDE. https://cache.getlazarus.org/videos/vte-embedded.mp4 -------------- next part -------------- An HTML attachment was scrubbed... URL: From hnb.code at gmail.com Wed Apr 11 08:59:16 2018 From: hnb.code at gmail.com (Maciej Izak) Date: Wed, 11 Apr 2018 08:59:16 +0200 Subject: [Lazarus] Dark themed lazarus In-Reply-To: References: <20180405085824.3f504636@limapholos.matflo.wg> Message-ID: 2018-04-05 12:33 GMT+02:00 Anthony Walter : > As a side enhancement, it would display information about the top, left, > width, and height of the changes inside the overlay as you dragged. Also it > might display the name and class of the control centered within the > overlay. Does that sound reasonable? > Sure! Sorry for late reply, but somehow I overlooked your message. Good idea, this was also in my TODO but with low priority, so feel free to do this :). -- Best regards, Maciej Izak -------------- next part -------------- An HTML attachment was scrubbed... URL: From hnb.code at gmail.com Wed Apr 11 09:15:39 2018 From: hnb.code at gmail.com (Maciej Izak) Date: Wed, 11 Apr 2018 09:15:39 +0200 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: Very good initiative (Visual Studio Code inspired) . I wish to had this for Windows too :) 2018-04-11 8:43 GMT+02:00 Anthony Walter via Lazarus < lazarus at lists.lazarus-ide.org>: > I updated my archive to include support for a dockable window inside the > Lazarus IDE. > > https://cache.getlazarus.org/videos/vte-embedded.mp4 > > > > > -- > _______________________________________________ > Lazarus mailing list > Lazarus at lists.lazarus-ide.org > https://lists.lazarus-ide.org/listinfo/lazarus > > -- Best regards, Maciej Izak -------------- next part -------------- An HTML attachment was scrubbed... URL: From hnb.code at gmail.com Wed Apr 11 09:15:39 2018 From: hnb.code at gmail.com (Maciej Izak) Date: Wed, 11 Apr 2018 09:15:39 +0200 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: Very good initiative (Visual Studio Code inspired) . I wish to had this for Windows too :) 2018-04-11 8:43 GMT+02:00 Anthony Walter via Lazarus < lazarus at lists.lazarus-ide.org>: > I updated my archive to include support for a dockable window inside the > Lazarus IDE. > > https://cache.getlazarus.org/videos/vte-embedded.mp4 > > > > > -- > _______________________________________________ > Lazarus mailing list > Lazarus at lists.lazarus-ide.org > https://lists.lazarus-ide.org/listinfo/lazarus > > -- Best regards, Maciej Izak -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at freepascal.org Wed Apr 11 09:18:34 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Wed, 11 Apr 2018 09:18:34 +0200 (CEST) Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: On Wed, 11 Apr 2018, Maciej Izak via Lazarus wrote: > Very good initiative (Visual Studio Code inspired) . I wish to had this for > Windows too :) Huh ? Slight historical misinformation here. Linux editors had this decennia before Visual Studio came up with it. Michael. From sysrpl at gmail.com Wed Apr 11 09:37:40 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Wed, 11 Apr 2018 03:37:40 -0400 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: By the way, there is a small bug with the IDE I discovered while making this. If you dock a window, then right click and close it, or undock it, window cannot be docked again. You have to restart the IDE to be able to dock that window type. Here is a screen capture of the issue: https://cache.getlazarus.org/videos/dock-bug.mp4 -------------- next part -------------- An HTML attachment was scrubbed... URL: From hnb.code at gmail.com Wed Apr 11 10:29:29 2018 From: hnb.code at gmail.com (Maciej Izak) Date: Wed, 11 Apr 2018 10:29:29 +0200 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: 2018-04-11 9:18 GMT+02:00 Michael Van Canneyt via Lazarus < lazarus at lists.lazarus-ide.org>: > > Huh ? Slight historical misinformation here. > > Linux editors had this decennia before Visual Studio came up with it. > Huh? What is wrong with you? Where you have historical misinformation? It is personal view. It looks similar like in VSC and probably like in many other editors in positive meaning. Feel free to provide full historical context. Insane. -- Best regards, Maciej Izak -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at freepascal.org Wed Apr 11 10:40:30 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Wed, 11 Apr 2018 10:40:30 +0200 (CEST) Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: On Wed, 11 Apr 2018, Maciej Izak via Lazarus wrote: > 2018-04-11 9:18 GMT+02:00 Michael Van Canneyt via Lazarus < > lazarus at lists.lazarus-ide.org>: > >> >> Huh ? Slight historical misinformation here. >> >> Linux editors had this decennia before Visual Studio came up with it. >> > > Huh? What is wrong with you? Where you have historical misinformation? It > is personal view. It looks similar like in VSC and probably like in many > other editors in positive meaning. I cannot speak for others, but I read your statement as stating that the idea of an embedded terminal comes from VSC. If this is not what you meant, I apologize for my reaction. Michael. From kamenlist at abv.bg Wed Apr 11 12:25:57 2018 From: kamenlist at abv.bg (Kamen Ketev) Date: Wed, 11 Apr 2018 13:25:57 +0300 (EEST) Subject: [Lazarus] Encrypted connection between Lazarus and Firebird Message-ID: <93288303.1051944.1523442358015.JavaMail.apache@nm31.abv.bg> Can I make an encrypted connection between Lazarus and Firebird? What components should I use? Can I make an encrypted connection between Lazarus and Microsoft SQL Server? What components should I use? Regards, Kamen -------------- next part -------------- An HTML attachment was scrubbed... URL: From juha.manninen62 at gmail.com Wed Apr 11 12:27:49 2018 From: juha.manninen62 at gmail.com (Juha Manninen) Date: Wed, 11 Apr 2018 13:27:49 +0300 Subject: [Lazarus] Dark themed lazarus In-Reply-To: References: <20180405085824.3f504636@limapholos.matflo.wg> Message-ID: On Thu, Apr 5, 2018 at 1:16 PM, Anthony Walter via Lazarus wrote: > So far with this change if you click, hold down the mouse, and drag up/down > quickly in the inspector the lag seems greatly reduced, as well as less CPU > usage. Do you mean to click on a property name in OI, then drag it on top of other property names? I don't see any serious lag here on my Atom CPU mini-laptop with Linux + LCL-GTK2. Besides, why would you drag the property names or values? OI does not support drag-n-drop between properties. Shortly put: I cannot reproduce. > Either way, shortly I'll submit it with a patch, a stand alone > example testing program, and let others try it for themselves. Yes please. Juha From sysrpl at gmail.com Wed Apr 11 12:55:58 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Wed, 11 Apr 2018 06:55:58 -0400 Subject: [Lazarus] Dark themed lazarus In-Reply-To: References: <20180405085824.3f504636@limapholos.matflo.wg> Message-ID: Juha, no I mean this, reflecting this, the old way the OI handled changes: http://cache.getlazarus.org/videos/drag-inspector.mp4 The lag is visceral. Whenever an item index changes, the entire OI is invalidated. My change repaints 2 items, the previous row, and the new row. It's must faster. -------------- next part -------------- An HTML attachment was scrubbed... URL: From sysrpl at gmail.com Wed Apr 11 13:13:18 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Wed, 11 Apr 2018 07:13:18 -0400 Subject: [Lazarus] Encrypted connection between Lazarus and Firebird In-Reply-To: <93288303.1051944.1523442358015.JavaMail.apache@nm31.abv.bg> References: <93288303.1051944.1523442358015.JavaMail.apache@nm31.abv.bg> Message-ID: Use a socket to connect, and make it encrypted. Or ssl ... it can work on any port, not just 443. https://technet.microsoft.com/en-us/library/ms189067(v=sql.105).aspx Or you could use ssh. http://www.firebirdfaq.org/faq113/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From tony.whyman at mccallumwhyman.com Wed Apr 11 17:39:44 2018 From: tony.whyman at mccallumwhyman.com (Tony Whyman) Date: Wed, 11 Apr 2018 16:39:44 +0100 Subject: [Lazarus] Encrypted connection between Lazarus and Firebird In-Reply-To: <93288303.1051944.1523442358015.JavaMail.apache@nm31.abv.bg> References: <93288303.1051944.1523442358015.JavaMail.apache@nm31.abv.bg> Message-ID: <78f1b8b3-30b1-5a24-7094-4335675e710e@mccallumwhyman.com> The first question is a Firebird question. With Firebird 3, you can configure use of the Srp user authentication module and "over-the-wire" encryption. This should give you an encrypted connection between client and server. The settings for this are in the "firebird.conf" config file. This should work with all Lazarus database components that support the use of a Firebird database (e.g. IBX). As to the second question - I'll let someone else answer that one - but the answer is probably similar. Tony Whyman MWA On 11/04/18 11:25, Kamen Ketev via Lazarus wrote: > > Can I make an encrypted connection between Lazarus and Firebird? What > components should I use? > > Can I make an encrypted connection between Lazarus and Microsoft SQL > Server? What components should I use? > > Regards, > Kamen > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From SAmeis.fpc at web.de Wed Apr 11 21:03:55 2018 From: SAmeis.fpc at web.de (Simon Ameis) Date: Wed, 11 Apr 2018 21:03:55 +0200 Subject: [Lazarus] Lazarus translation In-Reply-To: <7a789628-9c0d-758a-32ea-5cf334641b6d@aol.com> References: <7a789628-9c0d-758a-32ea-5cf334641b6d@aol.com> Message-ID: <20262128-b771-875c-6f99-5b4aec00817b@web.de> Am 10.04.2018 um 19:34 schrieb kapibara via Lazarus: > There is no swedish translation of Lazarus, how can I make one? > You should find a README.txt in the languages directory in your lazarus installation or just read it online at https://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/languages/README.txt?view=markup&revision=48856&root=lazarus From donald at ziesig.org Thu Apr 12 00:02:36 2018 From: donald at ziesig.org (Donald Ziesig) Date: Wed, 11 Apr 2018 18:02:36 -0400 Subject: [Lazarus] Drag (and show) images Message-ID: <52dd89e7-ee2f-7f22-344e-0fcefc6a543c@ziesig.org> Hi All! I am trying to write an app that allows me to drag images and show them while they are being dragged (like the cards in Solitaire). I have been able to drag images (showing only the drag cursor) and drop them appropriately, but I haven't been able to find any recent documentation showing the use of TDragImageList and TDragObject. The only articles that I have found are for Delphi from 2011 (which translates to Lazarus but doesn't work correctly) and some more recent that don't show the dragged image while the drag is taking place (I have that part working). I was able to show a dragged image by adding code to the DragOver event, but that seems to take more time than it should. Can anyone point me in the right direction for this? Thanks, Don Ziesig From mailinglists at geldenhuys.co.uk Thu Apr 12 00:40:02 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Wed, 11 Apr 2018 23:40:02 +0100 Subject: [Lazarus] Drag (and show) images In-Reply-To: <52dd89e7-ee2f-7f22-344e-0fcefc6a543c@ziesig.org> References: <52dd89e7-ee2f-7f22-344e-0fcefc6a543c@ziesig.org> Message-ID: <7295b9e6-9388-6a13-21bd-e028f8ac7ab5@geldenhuys.co.uk> On 2018-04-11 23:02, Donald Ziesig via Lazarus wrote: > Can anyone point me in the right direction for this? I've never really compared LCL's drag-n-drop implementation with fpGUI's - but they might be similar in some way. Anyway, fpGUI' visual forms designer - the fpGUI's UI Designer (/uidesigner/ directory) does just that. You can drag components from the component palette to the designer form, and it shows you the drag cursor and a image of the rendered widget/component while you are dragging. Maybe that might give you some ideas - or not. The above is obviously different from dragging already placed widgets on a form - because that is simply moving the widget. 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 From werner.pamler at freenet.de Thu Apr 12 01:18:39 2018 From: werner.pamler at freenet.de (Werner Pamler) Date: Thu, 12 Apr 2018 01:18:39 +0200 Subject: [Lazarus] Drag (and show) images In-Reply-To: <52dd89e7-ee2f-7f22-344e-0fcefc6a543c@ziesig.org> References: <52dd89e7-ee2f-7f22-344e-0fcefc6a543c@ziesig.org> Message-ID: <55d05d06-4a0b-a353-b23a-d8e6e870f381@freenet.de> Am 12.04.2018 um 00:02 schrieb Donald Ziesig via Lazarus: > I am trying to write an app that allows me to drag images and show > them while they are being dragged (like the cards in Solitaire). > > I have been able to drag images (showing only the drag cursor) and > drop them appropriately, but I haven't been able to find any recent > documentation showing the use of TDragImageList and TDragObject. > > The only articles that I have found are for Delphi from 2011 (which > translates to Lazarus but doesn't work correctly) and some more recent > that don't show the dragged image while the drag is taking place (I > have that part working). > > I was able to show a dragged image by adding code to the DragOver > event, but that seems to take more time than it should. > > Can anyone point me in the right direction for this? There is a sample in folder examples/dragimagelist of your Lazarus installation - maybe it gets close to what you need? From r030t1 at gmail.com Thu Apr 12 07:33:44 2018 From: r030t1 at gmail.com (R0b0t1) Date: Thu, 12 Apr 2018 00:33:44 -0500 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: On Tue, Apr 10, 2018 at 10:12 PM, Anthony Walter via Lazarus wrote: > I'm am starting a new thread because I've completed my task. > > Here is a terminal component for Lazarus that is easy to reuse. > > https://cache.getlazarus.org/archives/terminal.7z > > To install, make sure you're on Linux with a Gtk2 copy of Lazarus. Open > package terminaldsgn.lpk, install, and rebuild the IDE. You'll have a > TTerminal component on your pallet. Drop it on a form, press run, and you > have your own terminal program. > > Here is a longish video walk through of how it works: > > https://cache.getlazarus.org/videos/vte-finished.mp4 > > The source code is completely free, copy left, if anyone wants to reuse it. > > Notes, you need to be using Linux and have libvte for gtk2 installed to use > the component. You can be running other platforms, but you'll just see the > design time surface it you're not on Linux. > I appreciate your work. Did you ever try to make it cross platform? I only ask as I have not found a good way to embed either PowerShell or cmd.exe. From r030t1 at gmail.com Thu Apr 12 07:33:44 2018 From: r030t1 at gmail.com (R0b0t1) Date: Thu, 12 Apr 2018 00:33:44 -0500 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: On Tue, Apr 10, 2018 at 10:12 PM, Anthony Walter via Lazarus wrote: > I'm am starting a new thread because I've completed my task. > > Here is a terminal component for Lazarus that is easy to reuse. > > https://cache.getlazarus.org/archives/terminal.7z > > To install, make sure you're on Linux with a Gtk2 copy of Lazarus. Open > package terminaldsgn.lpk, install, and rebuild the IDE. You'll have a > TTerminal component on your pallet. Drop it on a form, press run, and you > have your own terminal program. > > Here is a longish video walk through of how it works: > > https://cache.getlazarus.org/videos/vte-finished.mp4 > > The source code is completely free, copy left, if anyone wants to reuse it. > > Notes, you need to be using Linux and have libvte for gtk2 installed to use > the component. You can be running other platforms, but you'll just see the > design time surface it you're not on Linux. > I appreciate your work. Did you ever try to make it cross platform? I only ask as I have not found a good way to embed either PowerShell or cmd.exe. From sysrpl at gmail.com Thu Apr 12 09:20:32 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Thu, 12 Apr 2018 03:20:32 -0400 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: R0b0t1, If you look at the sources you'll see I simply wrapped some of the functionality of gnome's terminal component inside a LCL TCustomControl class. Two function calls actually, vte_terminal_new and vte_terminal_fork_command_full. The gnome tool kit, or gtk for short, takes care of the rest. Its functionality includes text styles (bold, underline), colors, keyboard accelerators, hyperlinks, command history, variable expansion, among other things. But as this is implemented by the gnome tool kit for Linux, sorry it's not portable. However, if you just want to embed a text terminal with no features other than typing text and executing command, and have those results shown in the same window, it can be easily done on any platform with a TMemo control and TProcess class using pipes to redirect stdin, stdout, and stderr. -------------- next part -------------- An HTML attachment was scrubbed... URL: From sysrpl at gmail.com Thu Apr 12 09:20:32 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Thu, 12 Apr 2018 03:20:32 -0400 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: R0b0t1, If you look at the sources you'll see I simply wrapped some of the functionality of gnome's terminal component inside a LCL TCustomControl class. Two function calls actually, vte_terminal_new and vte_terminal_fork_command_full. The gnome tool kit, or gtk for short, takes care of the rest. Its functionality includes text styles (bold, underline), colors, keyboard accelerators, hyperlinks, command history, variable expansion, among other things. But as this is implemented by the gnome tool kit for Linux, sorry it's not portable. However, if you just want to embed a text terminal with no features other than typing text and executing command, and have those results shown in the same window, it can be easily done on any platform with a TMemo control and TProcess class using pipes to redirect stdin, stdout, and stderr. -------------- next part -------------- An HTML attachment was scrubbed... URL: From kamenlist at abv.bg Thu Apr 12 14:26:10 2018 From: kamenlist at abv.bg (Kamen Ketev) Date: Thu, 12 Apr 2018 15:26:10 +0300 (EEST) Subject: [Lazarus] Encrypted connection between Lazarus and Firebird In-Reply-To: <78f1b8b3-30b1-5a24-7094-4335675e710e@mccallumwhyman.com> References: <93288303.1051944.1523442358015.JavaMail.apache@nm31.abv.bg> <78f1b8b3-30b1-5a24-7094-4335675e710e@mccallumwhyman.com> Message-ID: <5537130.93765.1523535970262.JavaMail.apache@nm31.abv.bg> Thanks, Anthony Walter and Tony Whyman. Regards, Kamen >-------- Оригинално писмо -------- >От: Tony Whyman via Lazarus lazarus at lists.lazarus-ide.org >Относно: Re: [Lazarus] Encrypted connection between Lazarus and Firebird >До: lazarus at lists.lazarus-ide.org >Изпратено на: 11.04.2018 18:39 The first question is a Firebird question. With Firebird 3, you can configure use of the Srp user authentication module and "over-the-wire" encryption. This should give you an encrypted connection between client and server. The settings for this are in the "firebird.conf" config file. This should work with all Lazarus database components that support the use of a Firebird database (e.g. IBX). As to the second question - I'll let someone else answer that one - but the answer is probably similar. Tony Whyman MWA On 11/04/18 11:25, Kamen Ketev via Lazarus wrote: Can I make an encrypted connection between Lazarus and Firebird? What components should I use? Can I make an encrypted connection between Lazarus and Microsoft SQL Server? What components should I use? Regards, Kamen -------------- next part -------------- An HTML attachment was scrubbed... URL: From markMLl.lazarus at telemetry.co.uk Thu Apr 12 20:50:53 2018 From: markMLl.lazarus at telemetry.co.uk (Mark Morgan Lloyd) Date: Thu, 12 Apr 2018 18:50:53 +0000 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: On 12/04/18 05:45, R0b0t1 via Lazarus wrote: > Did you ever try to make it cross platform? I only ask as I have notfound a good way to embed either PowerShell or cmd.exe. I did it years ago for cmd.exe on Delphi, I think it used pipes in some form. -- Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues] From r030t1 at gmail.com Thu Apr 12 21:22:52 2018 From: r030t1 at gmail.com (R0b0t1) Date: Thu, 12 Apr 2018 14:22:52 -0500 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: There is a bit more to adapt all features of cmd.exe, especially colors. The interface is handled by a windows DLL and kind of clunky, so you need to hook functions. That is why I was wondering if it had already been done. On Thu, Apr 12, 2018 at 1:50 PM, Mark Morgan Lloyd via Lazarus wrote: > On 12/04/18 05:45, R0b0t1 via Lazarus wrote: > >> Did you ever try to make it cross platform? I only ask as I have notfound >> a good way to embed either PowerShell or cmd.exe. > > > I did it years ago for cmd.exe on Delphi, I think it used pipes in some > form. > > -- > 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 at lists.lazarus-ide.org > https://lists.lazarus-ide.org/listinfo/lazarus From donald at ziesig.org Fri Apr 13 02:40:57 2018 From: donald at ziesig.org (Donald Ziesig) Date: Thu, 12 Apr 2018 20:40:57 -0400 Subject: [Lazarus] Drag (and show) images In-Reply-To: <55d05d06-4a0b-a353-b23a-d8e6e870f381@freenet.de> References: <52dd89e7-ee2f-7f22-344e-0fcefc6a543c@ziesig.org> <55d05d06-4a0b-a353-b23a-d8e6e870f381@freenet.de> Message-ID: On 04/11/2018 07:18 PM, Werner Pamler via Lazarus wrote: > Am 12.04.2018 um 00:02 schrieb Donald Ziesig via Lazarus: >> I am trying to write an app that allows me to drag images and show >> them while they are being dragged (like the cards in Solitaire). >> >> I have been able to drag images (showing only the drag cursor) and >> drop them appropriately, but I haven't been able to find any recent >> documentation showing the use of TDragImageList and TDragObject. >> >> The only articles that I have found are for Delphi from 2011 (which >> translates to Lazarus but doesn't work correctly) and some more >> recent that don't show the dragged image while the drag is taking >> place (I have that part working). >> >> I was able to show a dragged image by adding code to the DragOver >> event, but that seems to take more time than it should. >> >> Can anyone point me in the right direction for this? > > There is a sample in folder examples/dragimagelist of your Lazarus > installation - maybe it gets close to what you need? You're right.  It gets *close* but not quite there.  I can move the control so long as the mouse is *not* over the control while it is moving :-(. I will look at this closer in the morning and see if I can work around it (or if there is something I am missing). Thanks! Don -------------- next part -------------- An HTML attachment was scrubbed... URL: From giuliano.colla at fastwebnet.it Fri Apr 13 10:45:42 2018 From: giuliano.colla at fastwebnet.it (Giuliano Colla) Date: Fri, 13 Apr 2018 10:45:42 +0200 Subject: [Lazarus] Drag (and show) images In-Reply-To: References: <52dd89e7-ee2f-7f22-344e-0fcefc6a543c@ziesig.org> <55d05d06-4a0b-a353-b23a-d8e6e870f381@freenet.de> Message-ID: <344bdd77-875c-4ca9-42ac-c256762dae97@fastwebnet.it> Il 13/04/2018 02:40, Donald Ziesig via Lazarus ha scritto: > You're right.  It gets *close* but not quite there.  I can move the > control so long as the mouse is *not* over the control while it is > moving :-(. I will look at this closer in the morning and see if I can > work around it (or if there is something I am missing). > You might find useful, as a guideline, the code I'm using in one of my application to drag a button so that it doesn't cover the useful part of an image. Just using the OnMouseDown, OnMouseMove and OnMouseUp of your TImage, and getting rid of the code you don't need, to perform an extra action on OnMouseUp, you should be able to do the trick. >   TErrForm = class(TForm) > ...... >   protected >     ResetDragged: Boolean; >     CursorPos: TPoint; >     ObjectPos: TPoint; > .... > > procedure TErrForm.ResetBtnMouseDown(Sender: TObject; Button: > TMouseButton; >   Shift: TShiftState; X: LongInt; Y: LongInt); > begin >   ResetDragged := True; >   CursorPos.X := Mouse.CursorPos.X; >   CursorPos.Y := Mouse.CursorPos.Y; >   with ResetBtn do begin; >     ObjectPos.X := Left; >     ObjectPos.Y := Top; >     end; > end; > > procedure TErrForm.ResetBtnMouseMove(Sender: TObject; Shift: TShiftState; >   X: LongInt; Y: LongInt); > begin >   if ResetDragged then begin >     with ResetBtn do begin >       Left := ObjectPos.X + (Mouse.CursorPos.X - CursorPos.X); >       Top := ObjectPos.Y +  (Mouse.CursorPos.Y - CursorPos.Y); >       ResetPos.X := (Left * NormalGeometry.ClientWidth div > CurrImage.Width) + HorzScrollBar.Position; >       ResetPos.Y := (Top * NormalGeometry.ClientHeight div > CurrImage.Height) + VertScrollBar.Position; >       end; >     end; > end; > > procedure TErrForm.ResetBtnMouseUp(Sender: TObject; Button: TMouseButton; >   Shift: TShiftState; X: LongInt; Y: LongInt); > begin >   if ResetDragged then begin >     ResetDragged := False; >     Paint; >     end; >   if (abs(Mouse.CursorPos.X - CursorPos.X) < 10) and > (abs(Mouse.CursorPos.Y - CursorPos.Y)< 10) then Close; > end; Hope that it helps. Giuliano -------------- next part -------------- An HTML attachment was scrubbed... URL: From sysrpl at gmail.com Fri Apr 13 15:30:48 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Fri, 13 Apr 2018 09:30:48 -0400 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: I've posted this project to github: https://github.com/sysrpl/Lazarus.Terminal Enhancements now include custom colors and fonts. -------------- next part -------------- An HTML attachment was scrubbed... URL: From donald at ziesig.org Fri Apr 13 18:14:46 2018 From: donald at ziesig.org (Donald Ziesig) Date: Fri, 13 Apr 2018 12:14:46 -0400 Subject: [Lazarus] Drag (and show) images In-Reply-To: <344bdd77-875c-4ca9-42ac-c256762dae97@fastwebnet.it> References: <52dd89e7-ee2f-7f22-344e-0fcefc6a543c@ziesig.org> <55d05d06-4a0b-a353-b23a-d8e6e870f381@freenet.de> <344bdd77-875c-4ca9-42ac-c256762dae97@fastwebnet.it> Message-ID: <82e69bd7-f4a3-0a9b-eb75-b4e1dabbf30a@ziesig.org> On 04/13/2018 04:45 AM, Giuliano Colla via Lazarus wrote: > > Il 13/04/2018 02:40, Donald Ziesig via Lazarus ha scritto: > >> You're right.  It gets *close* but not quite there.  I can move the >> control so long as the mouse is *not* over the control while it is >> moving :-(. I will look at this closer in the morning and see if I >> can work around it (or if there is something I am missing). >> > > You might find useful, as a guideline, the code I'm using in one of my > application to drag a button so that it doesn't cover the useful part > of an image. Just using the OnMouseDown, OnMouseMove and OnMouseUp of > your TImage, and getting rid of the code you don't need, to perform an > extra action on OnMouseUp, you should be able to do the trick. > >>   TErrForm = class(TForm) >> ...... >>   protected >>     ResetDragged: Boolean; >>     CursorPos: TPoint; >>     ObjectPos: TPoint; >> .... >> >> procedure TErrForm.ResetBtnMouseDown(Sender: TObject; Button: >> TMouseButton; >>   Shift: TShiftState; X: LongInt; Y: LongInt); >> begin >>   ResetDragged := True; >>   CursorPos.X := Mouse.CursorPos.X; >>   CursorPos.Y := Mouse.CursorPos.Y; >>   with ResetBtn do begin; >>     ObjectPos.X := Left; >>     ObjectPos.Y := Top; >>     end; >> end; >> >> procedure TErrForm.ResetBtnMouseMove(Sender: TObject; Shift: TShiftState; >>   X: LongInt; Y: LongInt); >> begin >>   if ResetDragged then begin >>     with ResetBtn do begin >>       Left := ObjectPos.X + (Mouse.CursorPos.X - CursorPos.X); >>       Top := ObjectPos.Y +  (Mouse.CursorPos.Y - CursorPos.Y); >>       ResetPos.X := (Left * NormalGeometry.ClientWidth div >> CurrImage.Width) + HorzScrollBar.Position; >>       ResetPos.Y := (Top * NormalGeometry.ClientHeight div >> CurrImage.Height) + VertScrollBar.Position; >>       end; >>     end; >> end; >> >> procedure TErrForm.ResetBtnMouseUp(Sender: TObject; Button: TMouseButton; >>   Shift: TShiftState; X: LongInt; Y: LongInt); >> begin >>   if ResetDragged then begin >>     ResetDragged := False; >>     Paint; >>     end; >>   if (abs(Mouse.CursorPos.X - CursorPos.X) < 10) and >> (abs(Mouse.CursorPos.Y - CursorPos.Y)< 10) then Close; >> end; > > Hope that it helps. > > Giuliano > > > Hi Giuliano! It works perfectly. 8-) The best part is that it doesn't use any poorly documented library code and it doesn't hog the CPU either. Many thanks, Don -------------- next part -------------- An HTML attachment was scrubbed... URL: From mailinglists at geldenhuys.co.uk Fri Apr 13 21:23:21 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Fri, 13 Apr 2018 20:23:21 +0100 Subject: [Lazarus] A fix for an annoying problem on Linux In-Reply-To: References: <955e9eeb-977a-5da1-7797-2d3ee376be02@windstream.net> Message-ID: <2712539c-cbfb-1c3c-7238-460cac19fc99@geldenhuys.co.uk> On 2018-04-03 15:38, Ralf Quint via Lazarus wrote: > I did not see that either until looking again after Michael > mentioned it... :( You guys really should develop more GUI widgets. I spotted that difference immediately. :-P 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 From sysrpl at gmail.com Sat Apr 14 01:48:16 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Fri, 13 Apr 2018 19:48:16 -0400 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: This was just posted on reddit: https://www.reddit.com/r/linux/comments/8bz9p4/a_look_at_terminal_emulators_part_1/ https://anarc.at/blog/2018-04-12-terminal-emulators-1/ A comparison of terminal emulators. Most are using VTE. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jmlandmesser at gmx.de Sat Apr 14 11:08:14 2018 From: jmlandmesser at gmx.de (John Landmesser) Date: Sat, 14 Apr 2018 11:08:14 +0200 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: for Lazarus 1.9.0 r57653 FPC 3.0.4 x86_64-linux-gtk2 you need also dynlibs in gtk2term: uses   GLib2, Gtk2, dynlibs; Am 11.04.2018 um 05:12 schrieb Anthony Walter via Lazarus: > I'm am starting a new thread because I've completed my task. > > Here is a terminal component for Lazarus that is easy to reuse. > > https://cache.getlazarus.org/archives/terminal.7z > > To install, make sure you're on Linux with a Gtk2 copy of Lazarus. > Open package terminaldsgn.lpk, install, and rebuild the IDE. You'll > have a TTerminal component on your pallet. Drop it on a form, press > run, and you have your own terminal program. > > Here is a longish video walk through of how it works: > > https://cache.getlazarus.org/videos/vte-finished.mp4 > > The source code is completely free, copy left, if anyone wants to > reuse it. > > Notes, you need to be using Linux and have libvte for gtk2 installed > to use the component. You can be running other platforms, but you'll > just see the design time surface it you're not on Linux. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mailinglists at geldenhuys.co.uk Sat Apr 14 17:39:34 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Sat, 14 Apr 2018 16:39:34 +0100 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: On 2018-04-11 09:40, Michael Van Canneyt via Lazarus wrote: > I cannot speak for others, but I read your statement as stating that the idea > of an embedded terminal comes from VSC. That is how I read his message as well. And I fully agree Michael - I think Linux editors beat Visual Studio on that one by quite a few years. :-) 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 From mailinglists at geldenhuys.co.uk Sat Apr 14 17:47:33 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Sat, 14 Apr 2018 16:47:33 +0100 Subject: [Lazarus] Cool IDE add-on idea Message-ID: Hi, I just discover this add-on for Eclipse. Every time you use the mouse to do something, it pops up (without interrupting your workflow) and lists the keyboard shortcut you could have used to accomplish that same task you just did with the mouse. That's an excellent way to learn shortcuts - which ultimately should make you work faster (at least that is normally true for developers). I wouldn't even know where to start with such a add-on for Lazarus IDE, but I just thought I would mention it - in case somebody wants to take up the challenge. :-) 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 From r030t1 at gmail.com Sat Apr 14 18:23:40 2018 From: r030t1 at gmail.com (R0b0t1) Date: Sat, 14 Apr 2018 11:23:40 -0500 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: Message-ID: On Sat, Apr 14, 2018 at 10:47 AM, Graeme Geldenhuys via Lazarus wrote: > Hi, > > I just discover this add-on for Eclipse. Every time you use the mouse to > do something, it pops up (without interrupting your workflow) and lists > the keyboard shortcut you could have used to accomplish that same task > you just did with the mouse. > > That's an excellent way to learn shortcuts - which ultimately should > make you work faster (at least that is normally true for developers). > > I wouldn't even know where to start with such a add-on for Lazarus IDE, > but I just thought I would mention it - in case somebody wants to take > up the challenge. > > :-) > > Regards, > Graeme I would be extremely thankful if anyone had the time to at least start on this. One of my main complains with Lazarus/FPC is that it is IDE centric. The IDE is not that bad, but it is kind of hard to integrate into my normal desktop (a tiling window manager). Cheers, R0b0t1 From r030t1 at gmail.com Sat Apr 14 18:23:40 2018 From: r030t1 at gmail.com (R0b0t1) Date: Sat, 14 Apr 2018 11:23:40 -0500 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: Message-ID: On Sat, Apr 14, 2018 at 10:47 AM, Graeme Geldenhuys via Lazarus wrote: > Hi, > > I just discover this add-on for Eclipse. Every time you use the mouse to > do something, it pops up (without interrupting your workflow) and lists > the keyboard shortcut you could have used to accomplish that same task > you just did with the mouse. > > That's an excellent way to learn shortcuts - which ultimately should > make you work faster (at least that is normally true for developers). > > I wouldn't even know where to start with such a add-on for Lazarus IDE, > but I just thought I would mention it - in case somebody wants to take > up the challenge. > > :-) > > Regards, > Graeme I would be extremely thankful if anyone had the time to at least start on this. One of my main complains with Lazarus/FPC is that it is IDE centric. The IDE is not that bad, but it is kind of hard to integrate into my normal desktop (a tiling window manager). Cheers, R0b0t1 From michael at freepascal.org Sat Apr 14 19:02:46 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Sat, 14 Apr 2018 19:02:46 +0200 (CEST) Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: Message-ID: On Sat, 14 Apr 2018, R0b0t1 via Lazarus wrote: > On Sat, Apr 14, 2018 at 10:47 AM, Graeme Geldenhuys via Lazarus > wrote: >> Hi, >> >> I just discover this add-on for Eclipse. Every time you use the mouse to >> do something, it pops up (without interrupting your workflow) and lists >> the keyboard shortcut you could have used to accomplish that same task >> you just did with the mouse. >> >> That's an excellent way to learn shortcuts - which ultimately should >> make you work faster (at least that is normally true for developers). >> >> I wouldn't even know where to start with such a add-on for Lazarus IDE, >> but I just thought I would mention it - in case somebody wants to take >> up the challenge. >> >> :-) >> >> Regards, >> Graeme > > I would be extremely thankful if anyone had the time to at least start > on this. One of my main complains with Lazarus/FPC is that it is IDE > centric. The IDE is not that bad, but it is kind of hard to integrate > into my normal desktop (a tiling window manager). Would you mind explaining what you mean with IDE centric ? You can code in notepad++ or "joe" - something which I still do frequently for small things ? Michael. From sysrpl at gmail.com Sat Apr 14 22:04:34 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Sat, 14 Apr 2018 16:04:34 -0400 Subject: [Lazarus] Terminal Component Available In-Reply-To: References: Message-ID: Maybe someone can clarify the Dynlibs unit issue, because I'm on the same toolkit, platform, and compiler, yet there is no need to include Dynlibs. -------------- next part -------------- An HTML attachment was scrubbed... URL: From adrian at veith-system.de Sun Apr 15 10:42:28 2018 From: adrian at veith-system.de (Adrian Veith) Date: Sun, 15 Apr 2018 10:42:28 +0200 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? Message-ID: Hi, there is an article on phoronix https://www.phoronix.com/scan.php?page=news_item&px=Oracle-vs-Google-Wine-API, which shows that the Google vs Oracle case is concerning Wine developers because Wine mimics the Windows-API with the function names and parameters. Under this light the LCL might also be affected because it mimics the VCL to a large degree - and many fcl libraries mimic corresponding Delphi libraries. What do you think ? Adrian. From michael at freepascal.org Sun Apr 15 12:15:57 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Sun, 15 Apr 2018 12:15:57 +0200 (CEST) Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: On Sun, 15 Apr 2018, Adrian Veith via Lazarus wrote: > Hi, > > there is an article on phoronix > https://www.phoronix.com/scan.php?page=news_item&px=Oracle-vs-Google-Wine-API, > which shows that the Google vs Oracle case is concerning Wine developers > because Wine mimics the Windows-API with the function names and > parameters. Under this light the LCL might also be affected because it > mimics the VCL to a large degree - and many fcl libraries mimic > corresponding Delphi libraries. What do you think ? For starters, most of FPC based developers are not in the US. So the rulings of a US court do not apply to them. Many of them are based in Europe, where different laws apply. So, strictly speaking, if it turns out the ruling applies to LCL/FCL, it means that US citizens will not be allowed to use the LCL/FCL. Michael. From mailinglists at geldenhuys.co.uk Sun Apr 15 12:18:27 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Sun, 15 Apr 2018 11:18:27 +0100 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: <474821cd-a2bf-1d44-0cf5-84e5a01b5db0@geldenhuys.co.uk> On 2018-04-15 09:42, Adrian Veith via Lazarus wrote: > What do you think ? It will never concern or worry use. Why...? If Embarcadero can't even bother, or simply can't stop Code Typhon in shipping a leaked FMX framework, why would Google, Oracle or Microsoft bother with something as small as FPC or Lazarus. They just wont - it will be a colossal waste of time for them with no financial reward. 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 From cappellettogabriele at yahoo.it Sun Apr 15 14:04:14 2018 From: cappellettogabriele at yahoo.it (Gabriele Cappelletto) Date: Sun, 15 Apr 2018 14:04:14 +0200 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: <4e9dcfaa-8514-abdc-e2d1-6fa0629d830b@yahoo.it> An HTML attachment was scrubbed... URL: From markMLl.lazarus at telemetry.co.uk Sun Apr 15 14:11:54 2018 From: markMLl.lazarus at telemetry.co.uk (Mark Morgan Lloyd) Date: Sun, 15 Apr 2018 12:11:54 +0000 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: <474821cd-a2bf-1d44-0cf5-84e5a01b5db0@geldenhuys.co.uk> References: <474821cd-a2bf-1d44-0cf5-84e5a01b5db0@geldenhuys.co.uk> Message-ID: On 15/04/18 10:30, Graeme Geldenhuys via Lazarus wrote: > On 2018-04-15 09:42, Adrian Veith via Lazarus wrote:> What do you think ? > It will never concern or worry use. Why...? If Embarcadero can't evenbother, or simply can't stop Code Typhon in shipping a leaked FMXframework, why would Google, Oracle or Microsoft bother with somethingas small as FPC or Lazarus. They just wont - it will be a colossal wasteof time for them with no financial reward. I'd suggest that that is not a safe assumption: "We didn't think anybody would notice" has never been a valid defence, and copyright is governed by international treaties. Leaving aside the question of jurisdiction and differing tolerance of reverse engineering etc. in different countries, I'd suggest that the most relevant thing is that at one point the company that owned the rights to Delphi made commercial use of the FPC compiler. They cannot claim to be ignorant of the function and structure names in the FCL, and the fact that they (presumably) did not challenge the FPC developers at that point would probably make it more difficult to do so now. -- Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues] From adrian at vtim.de Sun Apr 15 15:14:23 2018 From: adrian at vtim.de (Adrian Veith) Date: Sun, 15 Apr 2018 15:14:23 +0200 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: <474821cd-a2bf-1d44-0cf5-84e5a01b5db0@geldenhuys.co.uk> References: <474821cd-a2bf-1d44-0cf5-84e5a01b5db0@geldenhuys.co.uk> Message-ID: <060c952f-b0c1-7ad5-42e9-7af187af03b3@vtim.de> Am 15.04.2018 um 12:18 schrieb Graeme Geldenhuys via Lazarus: > why would Google, Oracle or Microsoft bother with something > as small as FPC or Lazarus. They just wont - it will be a colossal waste > of time for them with no financial reward. > It wouldn't be Google, Oracle or Microsoft, but Embarcadero/Idera. I don't think they would tackle the FPC or Lazarus developers directly, but if there are financial successful applications in the US written in Lazarus/fpc it might be interesting for them. Adrian. From sysrpl at gmail.com Sun Apr 15 15:26:15 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Sun, 15 Apr 2018 09:26:15 -0400 Subject: [Lazarus] How to solve this coding problem? Message-ID: So I am writing a tool to share with the community and found a problem with using Lazarus and packages. I hope someone has an answer to this. The problem is that when you are using packages, often there is no practical way to find the methods and properties even if you have the source code. Here is an example of the problem: https://cache.getlazarus.org/videos/code-tools-problem.mp4 Whats happening here is there is a VERY deep hierarchy of inherited classes, there is no documentation, and the IDE provides no tool or way to view the methods and properties of a type, except for what's actually declared on the class. This makes it near impossible to effectively make use of many things unless you are the original author and know the methods and proeprties of the entire hierarchy by memorization. What we need is a tool window in the IDE that shows you a list of all classes/interfaces/types/vars/consts in the packages loaded in a project, and selecting said class/interface shows you all its methods and properties. Both the methods and properties on the class, but also inherited methods and properties in one single list, all the way down to TObject/IInterface. Without the need to open the inherited class or method to view them separately. It needs to be a single list, otherwise your chasing a bunch of different windows/tree nodes jsut to figure things out. So, we should be able to view these methods and properties in a single window that isn't a hint window. In a window that can stay open for browsing. In a window hopefully with the ability to be docked so it can be used as a reference or guide while writing code. Let me know your thoughts. Thanks. -------------- next part -------------- An HTML attachment was scrubbed... URL: From mailinglists at geldenhuys.co.uk Sun Apr 15 16:37:49 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Sun, 15 Apr 2018 15:37:49 +0100 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: <474821cd-a2bf-1d44-0cf5-84e5a01b5db0@geldenhuys.co.uk> Message-ID: On 2018-04-15 13:11, Mark Morgan Lloyd via Lazarus wrote: > and copyright is governed > by international treaties. And like Michael said, the majority of FPC and Lazarus developers are all based outside of the USA - and most in the EU. Very different laws in the EU. > Leaving aside the question of jurisdiction and differing tolerance of > reverse engineering etc. Nothing was reversed engineered. The API's are openly documented in help files, wiki pages etc. > the company that owned the > rights to Delphi made commercial use of the FPC compiler. And with that EMBT probably doesn't have a leg to stand on. The only game EMBT can now play is purposely change behaviour or implement things differently to FPC and Lazarusu - which EMBT is already doing. Maybe live harder for the open source projects. 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 From mailinglists at geldenhuys.co.uk Sun Apr 15 16:40:19 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Sun, 15 Apr 2018 15:40:19 +0100 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: <060c952f-b0c1-7ad5-42e9-7af187af03b3@vtim.de> References: <474821cd-a2bf-1d44-0cf5-84e5a01b5db0@geldenhuys.co.uk> <060c952f-b0c1-7ad5-42e9-7af187af03b3@vtim.de> Message-ID: On 2018-04-15 14:14, Adrian Veith via Lazarus wrote: > but if there are financial successful applications in the US written in > Lazarus/fpc it might be interesting for them. Creating commercial software, you don't have to divulge what tools you used to develop that software. At least the FPC and LCL licenses don't require that. 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 From skalogryz.lists at gmail.com Sun Apr 15 17:02:34 2018 From: skalogryz.lists at gmail.com (Dmitry Boyarintsev) Date: Sun, 15 Apr 2018 11:02:34 -0400 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: On Sun, Apr 15, 2018 at 4:42 AM, Adrian Veith via Lazarus < lazarus at lists.lazarus-ide.org> wrote: > there is an article on phoronix > https://www.phoronix.com/scan.php?page=news_item&px=Oracle- > vs-Google-Wine-API, > which shows that the Google vs Oracle case is concerning Wine developers > because Wine mimics the Windows-API with the function names and > parameters. Under this light the LCL might also be affected because it > mimics the VCL to a large degree - and many fcl libraries mimic > corresponding Delphi libraries. What do you think ? > Reading the wikipedia article (referenced from the article above): "The Court found that as a matter of law, Google's use of Java could not have fallen within fair use,..." ..."It was not transformative in the sense of a new platform either, since other Java smartphones predated Android" In case if Wine, this is actually the case. Because no Windows API existed on Linux platforms, except for Wine. It's also the case for FPC and LCL. I guess the bigger complaint is about: "It was not within any example of transformation, nor intended to permit third party interoperability, since Google had made no substantial efforts to use them for the purpose of third party interoperability. (In fact it found that Google had tried to prevent interoperability with other Java and had previously been refused a license by Sun for that reason)" Btw, the same wikipedia article references POSIX interface. That's actually an example of copyrighted API. In my opinion, having API copyrighted makes sense. It's similar copyrighting hardware interfaces such as USB, COM and HDMI ports. (there was quite a fight around those in the past) A well written API helps dramatically, while poorly written API requires a lot of work with every new version of API released (compare OpenGL vs DirectX) At the same time both POSIX and OpenGL were created as "API" (interface) standards. I'm not sure with WindowsAPI or Delphi were intended as as such. They are more platform specific interfaces (rather than cross-platform) Borland couldn't reuse VCL with Kylix, instead they came up with CLX instead. Where Lazarus with sweat-and-blood keeps up with LCL. Naturally, interfaces between FPC/Lazarus and Delphi are already quite far from one another. thanks, Dmitry -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at freepascal.org Sun Apr 15 18:33:32 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Sun, 15 Apr 2018 18:33:32 +0200 (CEST) Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: On Sun, 15 Apr 2018, Dmitry Boyarintsev via Lazarus wrote: > > Btw, the same wikipedia article references POSIX interface. That's actually > an example of copyrighted API. > In my opinion, having API copyrighted makes sense. Of course not. Copyright is theft. Ideas should always be free. Michael. From skalogryz.lists at gmail.com Sun Apr 15 19:03:37 2018 From: skalogryz.lists at gmail.com (Dmitry Boyarintsev) Date: Sun, 15 Apr 2018 13:03:37 -0400 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: On Sunday, April 15, 2018, Michael Van Canneyt via Lazarus < lazarus at lists.lazarus-ide.org> wrote: > > Of course not. Copyright is theft. Ideas should always be free. API is an implementation of an idea, and it’s up to the author to define license of use. Thanks, Dmitry -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at freepascal.org Sun Apr 15 19:24:16 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Sun, 15 Apr 2018 19:24:16 +0200 (CEST) Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: On Sun, 15 Apr 2018, Dmitry Boyarintsev via Lazarus wrote: > On Sunday, April 15, 2018, Michael Van Canneyt via Lazarus < > lazarus at lists.lazarus-ide.org> wrote: >> >> Of course not. Copyright is theft. Ideas should always be free. > > > API is an implementation of an idea, and it’s up to the author to define > license of use. Take a routine that converts an integer to a string: Why would you force someone to change what is an obvious name, simply because someone else already used it ? Ridiculous. Michael. From sysrpl at gmail.com Sun Apr 15 19:35:19 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Sun, 15 Apr 2018 13:35:19 -0400 Subject: [Lazarus] How to solve this coding problem? In-Reply-To: References: Message-ID: A follow up. I remember Delphi 3 had an object browser and managed to get a screen capture: https://cache.getlazarus.org/images/object-browser.gif It had a few useful features. 1) It listed the entire hierarchy of classes at your disposal, unlimited by unit selection. Therefore you could look at classes and their methods, rather than picking through unit names. 2) When a class was selected you could see all its properties and methods, even if they were defined in a parent class. Also it would note whether methods were virtual and display their visibility level. I can't remember was references was, but if it listed places in code where the type was referenced, now that would be cool. I think this could be done for Lazarus using CodeTools. Improvements I'd like to see would be to include method and property argument signatures in the list on the right. For example: TCustomForm [PU] procedure GetPreferredSize(var PreferredWidth, PreferredHeight: Integer; Raw: Boolean = False; WithThemeSpace: Boolean = True); Where [PU] would be an icon denoting it's public. Also, a would be nice to have would be making members searchable. That is you could type "Size", and all fields, methods, and properties of known with the partial match "Size" in their identifying name would show up. And clicking one that one result would take you to the entire list of members for that type. So if you were to search for "Size", and double clicked on the "[PU] procedure TCustomForm.GetPreferredSize" line, which was one of may results, you'd be taken to the entire listing of TCustomForm inside the same object browser window. Your thoughts? -------------- next part -------------- An HTML attachment was scrubbed... URL: From skalogryz.lists at gmail.com Sun Apr 15 19:58:40 2018 From: skalogryz.lists at gmail.com (Dmitry Boyarintsev) Date: Sun, 15 Apr 2018 13:58:40 -0400 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: On Sun, Apr 15, 2018 at 1:24 PM, Michael Van Canneyt via Lazarus < lazarus at lists.lazarus-ide.org> wrote: > Take a routine that converts an integer to a string: Why would you > force someone to change what is an obvious name, simply because someone > else already used it ? > I don't think that API is reviewed on per routine basis. API is reviewed as a whole. Also, in 2010 the first trial in US (if jurisdiction matters) court decision was that APIs cannot be copyrighted. So later the case was changed from a copyright violation to unfair use. That's actually contained in the court ruling as well: ( https://en.wikipedia.org/wiki/Oracle_America,_Inc._v._Google,_Inc.#Appeals_Court_and_finding_of_non-fair-use ) "Instead, the Court found that Google's purpose had been to enhance its nascent Android platform's attractiveness to existing developers, who were often familiar with Java, and to avoid the "drudgery" of rewriting the code (which they could have done) needed to implement the 170 lines of API detail which were indeed required." In general, they're not trying to impose a copyright on each function declaration owned by Oracle. Instead, they're claiming that Google made an unfair use of Oracle's (Sun) work. The unfairness is driven by Google competing with the Oracle with its Android system. If Microsoft will try to come up with its own "windows emulator" for Linux, then they might run into issues with Wine (but Wine would likely win, because they were there first, providing binary compatibility) thanks, Dmitry -------------- next part -------------- An HTML attachment was scrubbed... URL: From r030t1 at gmail.com Sun Apr 15 20:22:03 2018 From: r030t1 at gmail.com (R0b0t1) Date: Sun, 15 Apr 2018 13:22:03 -0500 Subject: [Lazarus] Google vs Oracle case - does it affect LCL ? In-Reply-To: References: Message-ID: On Sun, Apr 15, 2018 at 12:58 PM, Dmitry Boyarintsev via Lazarus wrote: > On Sun, Apr 15, 2018 at 1:24 PM, Michael Van Canneyt via Lazarus > wrote: >> >> Take a routine that converts an integer to a string: Why would you >> force someone to change what is an obvious name, simply because someone >> else already used it ? > > > I don't think that API is reviewed on per routine basis. API is reviewed as > a whole. > Also, in 2010 the first trial in US (if jurisdiction matters) court decision > was that APIs cannot be copyrighted. > To further clarify in the case of Wine, reverse engineering for interoperability and the results thereof can not violate any IP law. So this could not possibly affect either Wine or the LCL. From aaa5500 at ya.ru Tue Apr 17 17:44:43 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Tue, 17 Apr 2018 18:44:43 +0300 Subject: [Lazarus] TmacOSFormProp name Message-ID: <3a3d703b-d05f-b514-7d47-0f87292957bf@ya.ru> @Dmitry I know that OS name is "macOS". but I suggest component name with caps M, TMacOSFormProp. or better TMacFormProp. reason: new component name "macOSFormProp1" with lowercase m is not nice. TMacFormProp reads nicer that TMacOSFormProp, "OS" no need, all get idea that it's macOS. -- Regards, Alexey From aaa5500 at ya.ru Sat Apr 21 10:58:29 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Sat, 21 Apr 2018 11:58:29 +0300 Subject: [Lazarus] Autocompletion - ":" char spaces Message-ID: <63ac8f9d-d3b5-e110-0ed5-819a92bcb5e8@ya.ru> In the pic you see that some vars shown with " : ", and some with ":", different number of spaces near ":". Pls make one style. -- Regards, Alexey -------------- next part -------------- A non-text attachment was scrubbed... Name: autocomp--spaces-bad.png Type: image/png Size: 20602 bytes Desc: not available URL: From lazarus at kluug.net Sat Apr 21 11:04:54 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Sat, 21 Apr 2018 11:04:54 +0200 Subject: [Lazarus] Autocompletion - ":" char spaces In-Reply-To: <63ac8f9d-d3b5-e110-0ed5-819a92bcb5e8@ya.ru> References: <63ac8f9d-d3b5-e110-0ed5-819a92bcb5e8@ya.ru> Message-ID: On 21.04.2018 10:58, AlexeyT via Lazarus wrote: > In the pic you see that some vars shown with " : ", and some with ":", > different number of spaces near ":". Pls make one style. Yes, that's true - the code style should be polished in the identifier completion window, including the parameters section. Patches are welcome! Ondrej From giuliano.colla at fastwebnet.it Sat Apr 21 17:18:31 2018 From: giuliano.colla at fastwebnet.it (Giuliano Colla) Date: Sat, 21 Apr 2018 17:18:31 +0200 Subject: [Lazarus] A bitmap strange issue Message-ID: <70099bb6-c13b-eed8-e534-a71c03849d95@fastwebnet.it> An HTML attachment was scrubbed... URL: From luca at wetron.es Sat Apr 21 18:06:44 2018 From: luca at wetron.es (Luca Olivetti) Date: Sat, 21 Apr 2018 18:06:44 +0200 Subject: [Lazarus] A bitmap strange issue In-Reply-To: <70099bb6-c13b-eed8-e534-a71c03849d95@fastwebnet.it> References: <70099bb6-c13b-eed8-e534-a71c03849d95@fastwebnet.it> Message-ID: <3a6f3fe3-03ea-7745-375b-609fa0471085@wetron.es> El 21/04/18 a les 17:18, Giuliano Colla via Lazarus ha escrit: > > Here's a snippet of code used to show the issue: > >> procedure TForm1.Button1Click(Sender: TObject); var Filename: String; >> begin if OpenPictureDialog1.Execute then begin // MyBitmap := >> Image1.Picture.Bitmap; <-------This causes a sigsev in FreeImage If you follow the implementation of Image1.Picture.LoadFromFile you'll see that it frees the current bitmap, that's the cause of the sigsev. If you want to save the bitmap for later use, you should probably make a copy instead. >> Filename:= OpenPictureDialog1.FileName; >> Image1.Picture.LoadFromFile(Filename); If assigned(MyBitmap) then >> begin MyBitmap.FreeImage; FreeAndNil(MyBitmap); end; end; end; >> procedure TForm1.Button2Click(Sender: TObject); begin If not >> Assigned(MyBitmap) then MyBitmap:= TBitmap.Create; MyBitmap.Width:= >> Image1.Width; MyBitmap.Height:= Image1.Height; >> MyBitmap.Canvas.Brush.Color:= clNavy; MyBitmap.Canvas.Brush.Style:= >> bsSolid; >> MyBitmap.Canvas.FillRect(0,0,MyBitmap.Width,MyBitmap.Height); >> Image1.Picture.Bitmap := MyBitmap; And this assignment makes a copy of MyBitmap >> //MyBitmap.FreeImage; Useless FreeAndNil(MyBitmap); end; Bye -- Luca Olivetti Wetron Automation Technology http://www.wetron.es/ Tel. +34 93 5883004 (Ext.3010) Fax +34 93 5883007 From vojtech.cihak at atlas.cz Sat Apr 21 18:07:24 2018 From: vojtech.cihak at atlas.cz (=?utf-8?q?Vojt=C4=9Bch_=C4=8Cih=C3=A1k?=) Date: Sat, 21 Apr 2018 18:07:24 +0200 Subject: [Lazarus] =?utf-8?q?A_bitmap_strange_issue?= In-Reply-To: 0000000088c000014c7c016d5060 References: 0000000088c000014c7c016d5060 Message-ID: <20180421180724.027DDBC2@atlas.cz> Hi,   @ MyBitmap := Image1.Picture.Bitmap; This line only copies pointer, but Image1.Picture.Bitmap belongs to Image1 and it should care itself. If you need copy of the bitmap you shoud use: MyBitmap.Assign(Image1.Picture.Bitmap);   V.   ______________________________________________________________ > Od: Giuliano Colla via Lazarus > Komu: Lazarus mailing list > Datum: 21.04.2018 17:18 > Předmět: [Lazarus] A bitmap strange issue >   procedure TForm1.Button1Click(Sender: TObject); var Filename: String; begin if OpenPictureDialog1.Execute then begin // MyBitmap := Image1.Picture.Bitmap; <-------This causes a sigsev in FreeImage Filename:= OpenPictureDialog1.FileName; Image1.Picture.LoadFromFile(Filename); If assigned(MyBitmap) then begin MyBitmap.FreeImage; FreeAndNil(MyBitmap); end; end; end;Giuliano ---------- -- _______________________________________________ Lazarus mailing list Lazarus at lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus -------------- next part -------------- An HTML attachment was scrubbed... URL: From giuliano.colla at fastwebnet.it Sun Apr 22 12:38:26 2018 From: giuliano.colla at fastwebnet.it (Giuliano Colla) Date: Sun, 22 Apr 2018 12:38:26 +0200 Subject: [Lazarus] A bitmap strange issue In-Reply-To: <20180421180724.027DDBC2@atlas.cz> References: <20180421180724.027DDBC2@atlas.cz> Message-ID: <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> Il 21/04/2018 18:07, Vojtěch Čihák via Lazarus ha scritto: > @ MyBitmap := Image1.Picture.Bitmap; > > This line only copies pointer, but Image1.Picture.Bitmap belongs to > Image1 and it should care itself. > That's what I had guessed, but this means that there's a patent inconsistency, as shown in the Button2Click part of my test: > Image1.Picture.Bitmap := MyBitmap; FreeAndNil(MyBitmap); doesn't generate any error. If I don't free MyBitmap I see a memory leakage in heaptrc. IOW Image1.Picture.Bitmap := MyBitmap; performs an implicit assign, creating a new Bitmap Object for Image1. The apparently symmetrical MyBitmap := Image1.Picture.Bitmap; just copies the pointer. Timage.Picture.GetBitmap and TImage.Picture.SetBitmap do not follow the same logic. All of this is maybe somewhat Delphi compatible. Actually Delphi (Rad Studio 10.1) doesn't generate a SIGSEV with the same code, but rather just an "Illegal Pointer Operation" warning. However IMO it still remains quite inconsistent. Giuliano -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at freepascal.org Sun Apr 22 13:22:17 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Sun, 22 Apr 2018 13:22:17 +0200 (CEST) Subject: [Lazarus] A bitmap strange issue In-Reply-To: <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> References: <20180421180724.027DDBC2@atlas.cz> <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> Message-ID: On Sun, 22 Apr 2018, Giuliano Colla via Lazarus wrote: > Il 21/04/2018 18:07, Vojtěch Čihák via Lazarus ha scritto: > >> @ MyBitmap := Image1.Picture.Bitmap; >> >> This line only copies pointer, but Image1.Picture.Bitmap belongs to Image1 >> and it should care itself. >> > > That's what I had guessed, but this means that there's a patent > inconsistency, as shown in the Button2Click part of my test: > >> Image1.Picture.Bitmap := MyBitmap; FreeAndNil(MyBitmap); > > doesn't generate any error. If I don't free MyBitmap I see a memory leakage > in heaptrc. > > IOW > > Image1.Picture.Bitmap := MyBitmap; > > performs an implicit assign, creating a new Bitmap Object for Image1. > > The apparently symmetrical > > MyBitmap := Image1.Picture.Bitmap; This is how all properties that are TPersistent descendents work, so this behaviour should not come as a surprise. Michael. From lazarus at kluug.net Sun Apr 22 13:49:25 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Sun, 22 Apr 2018 13:49:25 +0200 Subject: [Lazarus] A bitmap strange issue In-Reply-To: <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> References: <20180421180724.027DDBC2@atlas.cz> <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> Message-ID: On 22.04.2018 12:38, Giuliano Colla via Lazarus wrote: > > Il 21/04/2018 18:07, Vojtěch Čihák via Lazarus ha scritto: > >> @ MyBitmap := Image1.Picture.Bitmap; >> >> This line only copies pointer, but Image1.Picture.Bitmap belongs to >> Image1 and it should care itself. >> > > That's what I had guessed, but this means that there's a patent > inconsistency, as shown in the Button2Click part of my test: >> Image1.Picture.Bitmap := MyBitmap; FreeAndNil(MyBitmap); > doesn't generate any error. If I don't free MyBitmap I see a memory > leakage in heaptrc. > > IOW > Image1.Picture.Bitmap := MyBitmap; > performs an implicit assign, creating a new Bitmap Object for Image1. > > The apparently symmetrical > MyBitmap := Image1.Picture.Bitmap; > just copies the pointer. Timage.Picture.GetBitmap and > TImage.Picture.SetBitmap do not follow the same logic. Do you really mean that Image1.Picture.Bitmap.SomeProperty := SomeValue; should apply SomeProperty := SomeValue on a copied object of Bitmap and produce a memory leak? And the same, that Image1.Picture.Bitmap := Image2.Picture.Bitmap; should produce a memory leak because of the temporary bitmap object? ...and taking it into detail because Picture is a property of TImage as well: Image1.Picture.Bitmap := Image2.Picture.Bitmap; would actually produce 3 memory leaks: 2x TPicture and 1x TBitmap. Ondrej -------------- next part -------------- An HTML attachment was scrubbed... URL: From giuliano.colla at fastwebnet.it Sun Apr 22 17:06:43 2018 From: giuliano.colla at fastwebnet.it (Giuliano Colla) Date: Sun, 22 Apr 2018 17:06:43 +0200 Subject: [Lazarus] A bitmap strange issue In-Reply-To: References: <20180421180724.027DDBC2@atlas.cz> <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> Message-ID: <0de4c0da-def9-f4ba-bba4-c46fb6b7174b@fastwebnet.it> Il 22/04/2018 13:49, Ondrej Pokorny via Lazarus ha scritto: > Do you really mean that > Image1.Picture.Bitmap.SomeProperty := SomeValue; > should apply SomeProperty := SomeValue on a copied object of Bitmap > and produce a memory leak? No, I mean that like Image1.Picture.Bitmap := SomeBitmap; actually executes a Image1.Picture.Bitmap.assign(SomeBitmap); (see TPicture.SetGraphic called by TPicture.SetBitmap in picture.inc), so SomeBitmap := Image1.Picture.BItmap; should execute (with proper checks) SomeBitmap.assign(Image1.Picture.Bitmap); I speak about manipulating the Tpicture.Bitmap property itself, not the TBitmap properties, which would not be affected. Giuliano From giuliano.colla at fastwebnet.it Sun Apr 22 17:36:19 2018 From: giuliano.colla at fastwebnet.it (Giuliano Colla) Date: Sun, 22 Apr 2018 17:36:19 +0200 Subject: [Lazarus] A bitmap strange issue In-Reply-To: References: <20180421180724.027DDBC2@atlas.cz> <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> Message-ID: Il 22/04/2018 13:22, Michael Van Canneyt via Lazarus ha scritto: > This is how all properties that are  TPersistent descendents work, so > this > behaviour should not come as a surprise. I wouldn't say so. E.g. TCanvas is a TPersistent descendent, but the Canvas property of a TCustomControl is declared like that: >     property Canvas: TCanvas read FCanvas write FCanvas; This means that after a SomeControl.Canvas := MyCanvas; or MyCanvas := SomeControl.Canvas; SomeControl.Canvas and MyCanvas will be the same object. Only a pointer is copied. On the contrary, the property Bitmap of a TPicture is declare like that: >     property Bitmap: TBitmap read GetBitmap write SetBitmap; where GetBitmap actually returns the TPicture.Bitmap Object, while SetBitmap creates a different Bitmap Object, and assigns it the content of the supplied bitmap (see TPicture.SetGraphic, called by TPicture.SetBitmap). This means that after a MyBitmap := SomePicture.Bitmap; MyBitmap and SomePicture.Bitmap will represent the same Object, while after a SomePicture.Bitmap := MyBitmap; MyBitmap and SomePicture.Bitmap will represent different Objects. This is IMHO a TPicture specific inconsistency. Giuliano -------------- next part -------------- An HTML attachment was scrubbed... URL: From nc-gaertnma at netcologne.de Sun Apr 22 17:39:34 2018 From: nc-gaertnma at netcologne.de (Mattias Gaertner) Date: Sun, 22 Apr 2018 17:39:34 +0200 Subject: [Lazarus] A bitmap strange issue In-Reply-To: <0de4c0da-def9-f4ba-bba4-c46fb6b7174b@fastwebnet.it> References: <20180421180724.027DDBC2@atlas.cz> <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> <0de4c0da-def9-f4ba-bba4-c46fb6b7174b@fastwebnet.it> Message-ID: <20180422173934.577f5712@limapholos.matflo.wg> On Sun, 22 Apr 2018 17:06:43 +0200 Giuliano Colla via Lazarus wrote: >[...] > SomeBitmap := Image1.Picture.BItmap; > > should execute (with proper checks) > > SomeBitmap.assign(Image1.Picture.Bitmap); > > I speak about manipulating the Tpicture.Bitmap property itself, not the > TBitmap properties, which would not be affected. And what to do with W := Image1.Picture.BItmap.Width? Mattias From giuliano.colla at fastwebnet.it Sun Apr 22 18:55:47 2018 From: giuliano.colla at fastwebnet.it (Giuliano Colla) Date: Sun, 22 Apr 2018 18:55:47 +0200 Subject: [Lazarus] A bitmap strange issue In-Reply-To: <20180422173934.577f5712@limapholos.matflo.wg> References: <20180421180724.027DDBC2@atlas.cz> <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> <0de4c0da-def9-f4ba-bba4-c46fb6b7174b@fastwebnet.it> <20180422173934.577f5712@limapholos.matflo.wg> Message-ID: <6d432a37-2363-2090-dec2-3b11b2853738@fastwebnet.it> Il 22/04/2018 17:39, Mattias Gaertner via Lazarus ha scritto: > And what to do with > > W := Image1.Picture.BItmap.Width? You're right, there's no easy way out. The original sin has been maybe to call Bitmap a TPicture property which isn't really a TBitmap, as the GetBitmap and SetBitmap methods show. This makes it easy to put any image into a picture, but creates unavoidable inconsistencies. Giuliano From lazarus at kluug.net Sun Apr 22 19:43:42 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Sun, 22 Apr 2018 19:43:42 +0200 Subject: [Lazarus] A bitmap strange issue In-Reply-To: <0de4c0da-def9-f4ba-bba4-c46fb6b7174b@fastwebnet.it> References: <20180421180724.027DDBC2@atlas.cz> <31703db8-f433-dcb4-be73-6346f4cb1c63@fastwebnet.it> <0de4c0da-def9-f4ba-bba4-c46fb6b7174b@fastwebnet.it> Message-ID: On 22.04.2018 17:06, Giuliano Colla via Lazarus wrote: > Il 22/04/2018 13:49, Ondrej Pokorny via Lazarus ha scritto: > >> Do you really mean that >> Image1.Picture.Bitmap.SomeProperty := SomeValue; >> should apply SomeProperty := SomeValue on a copied object of Bitmap >> and produce a memory leak? > > No, I mean that like > > Image1.Picture.Bitmap := SomeBitmap; > > actually executes a > > Image1.Picture.Bitmap.assign(SomeBitmap); > > (see TPicture.SetGraphic called by TPicture.SetBitmap in picture.inc), so > > SomeBitmap := Image1.Picture.BItmap; > > should execute (with proper checks) > > SomeBitmap.assign(Image1.Picture.Bitmap); You can definitely do this - but not on on the Image1.Picture side and on the other side - SomeBitmap: property SomeBitmap: TBitmap read GetSomeBitmap write SetSomeBitmap; -> implement SetSomeBitmap to execute .Assign() and you are good. Ondrej From kapibara.pas at aol.com Mon Apr 23 00:08:39 2018 From: kapibara.pas at aol.com (kapibara) Date: Mon, 23 Apr 2018 00:08:39 +0200 Subject: [Lazarus] View All a/v In-Reply-To: References: Message-ID: <8ccb74b2-c699-01c2-645f-2a45215898be@aol.com> Update: After installing newest RX lib, the a/v on View Components returned. But uninstalling RX made View All components work again. So I guess the problem lies within RX package? On 04/07/2018 06:28 AM, kapibara via Lazarus wrote: > Hi guys, is this a bug or a problem with my installation: > Right-clicking the component palette, then selecting "View All" > results in access violation. > > GTK2, Debian 9 64bit, latest laz trunk and FPC3.0.4rc1 [2017/08/05] > for x86_64 > From alexs75 at yandex.ru Mon Apr 23 09:51:05 2018 From: alexs75 at yandex.ru (=?utf-8?B?0JvQsNCz0YPQvdC+0LIg0JDQu9C10LrRgdC10Lk=?=) Date: Mon, 23 Apr 2018 10:51:05 +0300 Subject: [Lazarus] View All a/v References: <8ccb74b2-c699-01c2-645f-2a45215898be@aol.com> Message-ID: <6096001524469865@web55g.yandex.ru> An HTML attachment was scrubbed... URL: From svaa at ciberpiula.net Mon Apr 23 17:53:03 2018 From: svaa at ciberpiula.net (Santiago A.) Date: Mon, 23 Apr 2018 17:53:03 +0200 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: Message-ID: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> El 14/04/2018 a las 17:47, Graeme Geldenhuys via Lazarus escribió: > That's an excellent way to learn shortcuts - which ultimately should > make you work faster (at least that is normally true for developers). off-topic http://dl.acm.org/citation.cfm?id=1978942.1979351&coll=DL&dl=GUIDE&CFID=231586142&CFTOKEN=80641087 http://facweb.cs.depaul.edu/sjost/csc423/examples/anova/efficiency.pdf These studies show that the most efficient is toolbar; second, keyboard shortcuts; third, second level menu option. With the objection that shortcuts needs a lot of practice to be better than menu. Time ago I read that interviews to developers after tests show consistently that shortcuts are faster, and clock consistently shows that mouse is faster. The theory that explains this cognitive dissonance is that while using shortcuts your brain works in the program and in remembering shortcuts, but with mouse, you brains stops working to do visual action. The feeling is that with shortcut your brain is always humming, but with mouse you feel you have a lot of interruptions. But the fact is that the time you spend thinking the combinations and typing it is longer than moving the mouse. Conclusion: Good toolbars and a few well known shortcuts. -- Saludos Santiago A. From aaa5500 at ya.ru Tue Apr 24 17:04:20 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Tue, 24 Apr 2018 18:04:20 +0300 Subject: [Lazarus] Unix PageSetupDialog border fix Message-ID: <4baba4be-c5c5-6518-d70c-d7d5c18b32d6@ya.ru> fix for BorderStyle, dialog was resizable and preview rect is not resizable (dont fit to big size)- looks bad. -- Regards, Alexey -------------- next part -------------- A non-text attachment was scrubbed... Name: pg1.diff Type: text/x-patch Size: 428 bytes Desc: not available URL: From mailinglists at geldenhuys.co.uk Tue Apr 24 19:28:53 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Tue, 24 Apr 2018 18:28:53 +0100 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> Message-ID: On 2018-04-23 16:53, Santiago A. via Lazarus wrote: > These studies show that the most efficient is toolbar; second, keyboard > shortcuts; third, second level menu option. With the objection that > shortcuts needs a lot of practice to be better than menu. Maybe for other programs, but for programming IDE's the rules tend to be slightly different - they are not "normal" programs, and the user of an IDE mostly have there hands on the keyboard. My personal experience is that I absolutely fly when doing editing actions, searching, debugging etc with only the keyboard. Using the mouse will slow me down considerably. I primarily use 3 different editors. I made it my mission to know their shortcuts well, and when possible configure them that the same action as the same shortcut in all three editors - that makes my life a bit easier. Saying that, designing a UI in Lazarus or Delphi is obviously faster with a mouse. ;-) But I also know of layout managers in Java where visual designers are not needed, and you can knock-up a well designed and scalable UI in no time using only code (eg: MiG Layout). Back to Lazarus - there are some dialogs that totally annoying me because they were not designed with keyboard users in mind. ie: Wrong default actions, or no default actions, wrong default focus item, incorrect tab order etc. The "Source -> Enclose in IFDEF" dialog comes to mind. The Package windows too. Some of these I have tweaked locally to suite my needs better - that goodness for open source projects. Hell, you can't even configure/customise shortcuts in Delphi IDE!!! 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 From r030t1 at gmail.com Tue Apr 24 20:22:12 2018 From: r030t1 at gmail.com (R0b0t1) Date: Tue, 24 Apr 2018 13:22:12 -0500 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> Message-ID: On Mon, Apr 23, 2018 at 10:53 AM, Santiago A. via Lazarus wrote: > These studies show that the most efficient is toolbar; second, keyboard > shortcuts; third, second level menu option. With the objection that > shortcuts needs a lot of practice to be better than menu. > How well did those studies account for potentially incomparable workflows? I think I agree with what I think to be their conclusion - if you have two similar workflows, graphical navigation may be faster, because it is easier to guide thought with. But what if I can skip all of the intermediate steps and go straight to the action? Lots of CLI interfaces especially are domain specific languages, and the actions can be encoded into key combinations. On Tue, Apr 24, 2018 at 12:28 PM, Graeme Geldenhuys via Lazarus wrote: > Saying that, designing a UI in Lazarus or Delphi is obviously faster > with a mouse. ;-) But I also know of layout managers in Java where > visual designers are not needed, and you can knock-up a well designed > and scalable UI in no time using only code (eg: MiG Layout). > > Back to Lazarus - there are some dialogs that totally annoying me > because they were not designed with keyboard users in mind. ie: Wrong > default actions, or no default actions, wrong default focus item, > incorrect tab order etc. The "Source -> Enclose in IFDEF" dialog comes > to mind. The Package windows too. Some of these I have tweaked locally > to suite my needs better - that goodness for open source projects. Hell, > you can't even configure/customise shortcuts in Delphi IDE!!! > The things in the last paragraph especially are what I do not like. It may be that taking inspiration from either Visual Studio or JetBrains IDEs would be a good idea. I am willing to help, but not very familiar with the Lazarus codebase. Cheers, R0b0t1 From lazarus at kluug.net Tue Apr 24 20:36:13 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Tue, 24 Apr 2018 20:36:13 +0200 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> Message-ID: <4a3f4094-0956-1892-55c4-64c2ea74c861@kluug.net> On 24.04.2018 19:28, Graeme Geldenhuys via Lazarus wrote: > Back to Lazarus - there are some dialogs that totally annoying me > because they were not designed with keyboard users in mind. ie: Wrong > default actions, or no default actions, wrong default focus item, > incorrect tab order etc. I am quite sure patches that fix these issues will be applied. > The "Source -> Enclose in IFDEF" dialog comes to mind. I don't see a problem here. Can you be specific? > The Package windows too. This one is better to be used with mouse. Honestly, I don't know how you want to redesign it to be usable with the keyboard. Ondrej From svaa at ciberpiula.net Tue Apr 24 20:57:58 2018 From: svaa at ciberpiula.net (Santiago A.) Date: Tue, 24 Apr 2018 20:57:58 +0200 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> Message-ID: <7bd8ec34-161d-86bc-e52f-b2f15c7d83c0@ciberpiula.net> El 23/04/2018 a las 17:53, Santiago A. via Lazarus escribió: > Time ago I read that interviews to developers after tests show > consistently that shortcuts are faster, and clock consistently shows > that mouse is faster. http://www.asktog.com/TOI/toi06KeyboardVMouse1.html We’ve done a cool $50 million of R & D on the Apple Human Interface. We discovered, among other things, two pertinent facts: * Test subjects consistently report that keyboarding is faster than mousing. * The stopwatch consistently proves mousing is faster than keyboarding. This contradiction between user-experience and reality apparently forms the basis for many user/developers’ belief that the keyboard is faster. from https://www.itworld.com/article/2826902/enterprise-software/7-days-using-only-keyboard-shortcuts--no-mouse--no-trackpad--no-problem-.html "I watch numerous times a day as colleagues take their hands from the keyboard, reach for the mouse, and either (1) click in the next field of a form and recommence typing, or (2) click 'Submit.' It'd take a lot more than $50 mil worth of research to convince me that (1) tab and (2) enter are not faster. " And a little more modern: https://blog.codinghorror.com/revisiting-keyboard-vs-the-mouse-pt-1/ First, understand that this is a very old quote. In 1989 (apple quote), the current desktop operating systems were Windows 2.0, DOS 4.0, and Mac System 6. The "people new to the mouse" ------- Well, this off- topic was a little tongue in tech in the cheek. Nevertheless, I don't think memorizing a lot of shortcuts is always superior to a toolbar click. -- Saludos Santiago A. -------------- next part -------------- An HTML attachment was scrubbed... URL: From mailinglists at geldenhuys.co.uk Tue Apr 24 21:28:26 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Tue, 24 Apr 2018 20:28:26 +0100 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> Message-ID: <78f67c43-c82f-3c75-fab3-11cd815c8231@geldenhuys.co.uk> On 2018-04-24 19:22, R0b0t1 wrote: >> Back to Lazarus - there are some dialogs that totally annoying me >> because they were not designed with keyboard users in mind. >> ...snip... > > The things in the last paragraph especially are what I do not like. It > may be that taking inspiration from either Visual Studio or JetBrains > IDEs would be a good idea. There are already many dialogs that work very well with keyboard users in mind. Excuse me blowing my own horn. ;-) The "Procedure List" dialog comes to mind. Default focus, default actions etc are all in place. For myself, that dialog is my primary way of navigating units. > I am willing to help, but not very familiar with the Lazarus codebase. The issues I listed are all very minor things. Any programmer should be able to fix those. You do not require deep knowledge of Lazarus IDE internals. 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 From aaa5500 at ya.ru Tue Apr 24 21:32:58 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Tue, 24 Apr 2018 22:32:58 +0300 Subject: [Lazarus] IDE dialogs bugs In-Reply-To: References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> Message-ID: <492b912f-242f-2d17-5c48-f7a915284b22@ya.ru> @Graeme > The "Source -> Enclose in IFDEF" dialog comes > to mind. The Package windows too. Some of these I have tweaked locally > to suite my needs better Pls, list issues [easy] with all IDE dialogs- i will try to fix em. -- Regards, Alexey From mailinglists at geldenhuys.co.uk Tue Apr 24 21:33:35 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Tue, 24 Apr 2018 20:33:35 +0100 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: <7bd8ec34-161d-86bc-e52f-b2f15c7d83c0@ciberpiula.net> References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> <7bd8ec34-161d-86bc-e52f-b2f15c7d83c0@ciberpiula.net> Message-ID: On 2018-04-24 19:57, Santiago A. via Lazarus wrote: > * Test subjects consistently report that keyboarding is faster than > mousing. > * The stopwatch consistently proves mousing is faster than keyboarding. > > This contradiction between user-experience and reality apparently forms > the basis for many user/developers’ belief that the keyboard is faster. Speed is only one part of it. And yes, I believe I am faster with shortcuts. :-) The other very important point is... while coding I want that flow of ideas to continue uninterrupted. The ideas and code should flow from by brain to the IDE. Leaving the keyboard and switching to the mouse (trackball in my case) breaks that flow. 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 From mailinglists at geldenhuys.co.uk Tue Apr 24 21:41:23 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Tue, 24 Apr 2018 20:41:23 +0100 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: <4a3f4094-0956-1892-55c4-64c2ea74c861@kluug.net> References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> <4a3f4094-0956-1892-55c4-64c2ea74c861@kluug.net> Message-ID: On 2018-04-24 19:36, Ondrej Pokorny via Lazarus wrote: >> The "Source -> Enclose in IFDEF" dialog comes to mind. > > I don't see a problem here. Can you be specific? I've just retested with Lazarus Trunk, and indeed it is keyboard friendly now. It definitely wasn't so before. Not sure when it got improved, but I'm very glad it is. I'll start using it again. >> The Package windows too. > > This one is better to be used with mouse. Honestly, I don't know how you > want to redesign it to be usable with the keyboard. The ability to quickly search and open a package (probably project dependies only) and then be able to quickly do actions like Build, Search for unit etc. And the ability to switch back to the main editor windows again. Currently I can't tab between toolbar buttons, can't trigger the "More" dropdown. I can't even figure out how to tab between IDE windows (I can tab between ALL applications currently open, but not just Lazarus). 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 From lazarus at kluug.net Tue Apr 24 22:14:53 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Tue, 24 Apr 2018 22:14:53 +0200 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> <4a3f4094-0956-1892-55c4-64c2ea74c861@kluug.net> Message-ID: <9b1c2331-12f6-d320-0813-fd2fd67ec8ac@kluug.net> On 24.04.2018 21:41, Graeme Geldenhuys via Lazarus wrote: > On 2018-04-24 19:36, Ondrej Pokorny via Lazarus wrote: >>> The "Source -> Enclose in IFDEF" dialog comes to mind. >> I don't see a problem here. Can you be specific? > I've just retested with Lazarus Trunk, and indeed it is keyboard > friendly now. It definitely wasn't so before. Not sure when it got > improved, but I'm very glad it is. I'll start using it again. Yes, people have actually improved many dialog's UX. AlexeyT has been one of them. >>> The Package windows too. >> This one is better to be used with mouse. Honestly, I don't know how you >> want to redesign it to be usable with the keyboard. > The ability to quickly search and open a package (probably project > dependies only) and then be able to quickly do actions like Build, > Search for unit etc. For "Search for unit" there is a new feature in trunk: Menu -> File -> Open Unit. It lists all available units for current file that you can quickly open. Maybe you can use it instead. > And the ability to switch back to the main editor > windows again. > > Currently I can't tab between toolbar buttons, can't trigger the "More" > dropdown. Unfortunately that's how the TToolBar works. No chance to change it. We'd need a new toolbar component that would accept focus for the tool buttons. > I can't even figure out how to tab between IDE windows (I can > tab between ALL applications currently open, but not just Lazarus). I don't know about other OS than Windows, but it is indeed not possible yet (on Windows). For now, you have to declare a shortcut to show/focus a specific IDE window. But it should be easily possible to add support for this. E.g. take a look how the tabbing through recent editor files is done (Ctrl+~, Ctrl+Shift+~). A similar function could be easily adapted to tab through open IDE windows as well. Ondrej From lazarus at kluug.net Tue Apr 24 22:20:25 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Tue, 24 Apr 2018 22:20:25 +0200 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: <9b1c2331-12f6-d320-0813-fd2fd67ec8ac@kluug.net> References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> <4a3f4094-0956-1892-55c4-64c2ea74c861@kluug.net> <9b1c2331-12f6-d320-0813-fd2fd67ec8ac@kluug.net> Message-ID: On 24.04.2018 22:14, Ondrej Pokorny via Lazarus wrote: > On 24.04.2018 21:41, Graeme Geldenhuys via Lazarus wrote: >> Currently I can't tab between toolbar buttons, can't trigger the "More" >> dropdown. > > Unfortunately that's how the TToolBar works. No chance to change it. > We'd need a new toolbar component that would accept focus for the tool > buttons. There is one way to do it more simply: add &-hotkeys to the buttons. E.g. the help button can be triggered with Alt+H (because the caption is &Help). Adding &-hotkeys to other buttons will allow to trigger them with a keyboard as well. Ondrej From mailinglists at geldenhuys.co.uk Wed Apr 25 00:03:56 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Tue, 24 Apr 2018 23:03:56 +0100 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> <4a3f4094-0956-1892-55c4-64c2ea74c861@kluug.net> <9b1c2331-12f6-d320-0813-fd2fd67ec8ac@kluug.net> Message-ID: <68a04059-fb83-8557-ce80-0e1c095f4a19@geldenhuys.co.uk> On 2018-04-24 21:20, Ondrej Pokorny via Lazarus wrote: >> Unfortunately that's how the TToolBar works. No chance to change it. >> We'd need a new toolbar component that would accept focus for the tool >> buttons. > There is one way to do it more simply: add &-hotkeys to the buttons. > E.g. the help button can be triggered with Alt+H (because the caption is > &Help). Adding &-hotkeys to other buttons will allow to trigger them > with a keyboard as well. I was just going to suggest that, then read your second reply. :-) My other suggestion was to simply place a TActionList on each Package windows. Then define all the actions with associated shortcuts. The Captions of each TAction doesn't need to contain the & symbol for a hotkey (though highly recommended). The defined TAction.Shortcut property works just fine without the & in the TAction.Caption. The for should then process those shortcuts as part of any keyboard event in the form. That's all part of the benefits in using actions. 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 From sysrpl at gmail.com Wed Apr 25 02:35:23 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Tue, 24 Apr 2018 20:35:23 -0400 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? Message-ID: I am going to file a bug for this, but wanted to check with other people first to see if I'm overlooking something. So the problem is you cannot draw properly to any canvas backed by alpha channel. For example, if you have 2 TPortableNetworkGraphic images with images that contain alpha channels and try to draw from one to another using Canvas.Draw, the destination will be filled with black. The expected result should be the source image be copied over. I'm not sure, but I think all TCanvas drawing operations on graphic objects with a pf32bit pixel format don't work. Essentially that are read only surfaces. Is this intended and a won't fix problem or is there a chance someone is willing to fix this problem? On Windows the fix is to use the AlphaBlend function instead of BitBlt https://msdn.microsoft.com/en-us/library/windows/desktop/dd183351(v=vs.85).aspx On Gtk2 the fix is to use a temporary Cairo surface with cairo_set_source, and cairo_fill or cairo_paint_with_alpha instead of Gdk graphic commands. I'm not sure about Qt or Carbon. -------------- next part -------------- An HTML attachment was scrubbed... URL: From vojtech.cihak at atlas.cz Wed Apr 25 03:01:58 2018 From: vojtech.cihak at atlas.cz (=?utf-8?q?Vojt=C4=9Bch_=C4=8Cih=C3=A1k?=) Date: Wed, 25 Apr 2018 03:01:58 +0200 Subject: [Lazarus] =?utf-8?q?Selection_block/brace?= Message-ID: <20180425030158.6ABBF57C@atlas.cz> Hi,   I tried two items from Lazarus Edit menu: Select to Brace and Select Code Block. Both seem do nothing. Are they broken? I didn't use them before so I expexted they would do what their name say. I have Lazarus 1.9.0 r57693M FPC 3.1.1 x86_64-linux-qt.   Thanks   V. From lazarus at kluug.net Wed Apr 25 06:12:17 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Wed, 25 Apr 2018 06:12:17 +0200 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: References: Message-ID: On 25.04.2018 2:35, Anthony Walter via Lazarus wrote: > I'm not sure, but I think all TCanvas drawing operations on graphic > objects with a pf32bit pixel format don't work. Essentially that are > read only surfaces. Is this intended and a won't fix problem or is > there a chance someone is willing to fix this problem? You have 2 options to overcome this problem: 1.) Use a decent Graphics library. E.g. Graphics32. 2.) Use FPC graphics classes/functions without the LCL overhead. Ondrej From lazarus at kluug.net Wed Apr 25 06:14:47 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Wed, 25 Apr 2018 06:14:47 +0200 Subject: [Lazarus] Cool IDE add-on idea In-Reply-To: <68a04059-fb83-8557-ce80-0e1c095f4a19@geldenhuys.co.uk> References: <01747e40-4b0f-9db6-e708-31dd3eadcec3@ciberpiula.net> <4a3f4094-0956-1892-55c4-64c2ea74c861@kluug.net> <9b1c2331-12f6-d320-0813-fd2fd67ec8ac@kluug.net> <68a04059-fb83-8557-ce80-0e1c095f4a19@geldenhuys.co.uk> Message-ID: <43e7a1f7-431e-b0da-0eab-e226db6738ed@kluug.net> On 25.04.2018 0:03, Graeme Geldenhuys via Lazarus wrote: > My other suggestion was to simply place a TActionList on each Package > windows. Then define all the actions with associated shortcuts. The > Captions of each TAction doesn't need to contain the & symbol for a > hotkey (though highly recommended). The defined TAction.Shortcut > property works just fine without the & in the TAction.Caption. The for > should then process those shortcuts as part of any keyboard event in the > form. That's all part of the benefits in using actions. Don't forget that every shortcut needs to be editable in Key Mappings in IDE options. The &-hotkeys don't. Ondrej From juha.manninen62 at gmail.com Wed Apr 25 09:47:54 2018 From: juha.manninen62 at gmail.com (Juha Manninen) Date: Wed, 25 Apr 2018 10:47:54 +0300 Subject: [Lazarus] Unix PageSetupDialog border fix In-Reply-To: <4baba4be-c5c5-6518-d70c-d7d5c18b32d6@ya.ru> References: <4baba4be-c5c5-6518-d70c-d7d5c18b32d6@ya.ru> Message-ID: On Tue, Apr 24, 2018 at 6:04 PM, AlexeyT via Lazarus wrote: > fix for BorderStyle, dialog was resizable and preview rect is not resizable > (dont fit to big size)- looks bad. I applied the patch in r57703. Thanks. Juha From sysrpl at gmail.com Wed Apr 25 12:18:32 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Wed, 25 Apr 2018 06:18:32 -0400 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: References: Message-ID: Ondrej, For years I have my own solution that works , but I am interested in LCL TCanvas someday working correctly without 3rd party add ins. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lazarus at kluug.net Wed Apr 25 12:24:39 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Wed, 25 Apr 2018 12:24:39 +0200 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: References: Message-ID: <55b8f877-985b-d387-6dc5-d309d95aab13@kluug.net> On 25.04.2018 12:18, Anthony Walter wrote: > For years I have my own solution that works > , but I am interested in > LCL TCanvas someday working correctly without 3rd party add ins. Unfortunately, I have experienced the same issues. Ondrej -------------- next part -------------- An HTML attachment was scrubbed... URL: From lazarus at kluug.net Wed Apr 25 12:34:54 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Wed, 25 Apr 2018 12:34:54 +0200 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: <55b8f877-985b-d387-6dc5-d309d95aab13@kluug.net> References: <55b8f877-985b-d387-6dc5-d309d95aab13@kluug.net> Message-ID: On 25.04.2018 12:24, Ondrej Pokorny via Lazarus wrote: > On 25.04.2018 12:18, Anthony Walter wrote: >> For years I have my own solution that works >> , but I am interested in >> LCL TCanvas someday working correctly without 3rd party add ins. > > Unfortunately, I have experienced the same issues. > But if you don't want to use 3rd party add ins, use the FCL directly. It supports transparency, smooth resize etc etc. Actually it supports more than you would think at the first glance :) The LCL graphic classes/methods are very OS-specific. The FCL graphic classes/methods are OS-independent. I'd love to have full transparency support in LCL TBitmap/TCanvas as well but it all depends on the underlying OS. If you can fix it (at least for some OS/WS), feel free to post a patch. Ondrej -------------- next part -------------- An HTML attachment was scrubbed... URL: From giuliano.colla at fastwebnet.it Wed Apr 25 13:00:42 2018 From: giuliano.colla at fastwebnet.it (Giuliano Colla) Date: Wed, 25 Apr 2018 13:00:42 +0200 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: References: Message-ID: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> Il 25/04/2018 06:12, Ondrej Pokorny via Lazarus ha scritto: > 2.) Use FPC graphics classes/functions without the LCL overhead. Where are they located? Giuliano From lazarus at kluug.net Wed Apr 25 13:04:28 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Wed, 25 Apr 2018 13:04:28 +0200 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> References: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> Message-ID: <10da2701-e963-376d-dc79-297acc219b9d@kluug.net> On 25.04.2018 13:00, Giuliano Colla via Lazarus wrote: > Il 25/04/2018 06:12, Ondrej Pokorny via Lazarus ha scritto: > >> 2.) Use FPC graphics classes/functions without the LCL overhead. > Where are they located? FPC\packages\fcl-image\src\ Ondrej From michael at freepascal.org Wed Apr 25 13:05:06 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Wed, 25 Apr 2018 13:05:06 +0200 (CEST) Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> References: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> Message-ID: On Wed, 25 Apr 2018, Giuliano Colla via Lazarus wrote: > Il 25/04/2018 06:12, Ondrej Pokorny via Lazarus ha scritto: > >> 2.) Use FPC graphics classes/functions without the LCL overhead. > Where are they located? packages/fcl-image Michael. From giuliano.colla at fastwebnet.it Wed Apr 25 13:11:54 2018 From: giuliano.colla at fastwebnet.it (Giuliano Colla) Date: Wed, 25 Apr 2018 13:11:54 +0200 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: References: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> Message-ID: <82083ab5-dac2-4568-0854-347036a2c6b5@fastwebnet.it> Il 25/04/2018 13:05, Michael Van Canneyt via Lazarus ha scritto: >> Where are they located? > > packages/fcl-image Thanks to you and to Ondrej. Giuliano -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at freepascal.org Wed Apr 25 15:20:41 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Wed, 25 Apr 2018 15:20:41 +0200 (CEST) Subject: [Lazarus] Next language feature for pas2js... Message-ID: Hello, Now that interface support has been added to the list of implemented language features of pas2js, we're looking to get feedback on what best to tackle next. This time, the poll is not on the forum, so you do not need to have an account to vote. Here is a link to the poll: https://docs.google.com/forms/d/e/1FAIpQLScPVu6Y_X1QhOrYLWia4TVeKoZ3wiu-_PiMqJ0Zm8KW39FdCQ/viewform?usp=sf_link Michael. From sysrpl at gmail.com Wed Apr 25 16:30:55 2018 From: sysrpl at gmail.com (Anthony Walter) Date: Wed, 25 Apr 2018 10:30:55 -0400 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: <82083ab5-dac2-4568-0854-347036a2c6b5@fastwebnet.it> References: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> <82083ab5-dac2-4568-0854-347036a2c6b5@fastwebnet.it> Message-ID: I am trying to paint controls, so I need to eventually Canvas.Draw() to get a graphic onto a control. I've been working on creating a fully featured web browser for Lazarus and have been looking at the underlying widgetset interface code. Gtk3, which my project currently works great on, uses the now required Cairo system for painting Gtk widgets. I've already had to patch the Gtk3 LCL interface section quite a bit to fix errors and I'll submit those changes when I publish my project. However, the LCL Gtk2 widgetset is stuck using the Gdk system for drawing, even though that was deprecated early on in the Gtk2 lifetime and Cairo has been recommend for a decade or more. I would like to submit a patch for Gtk2 replacing Gdk with Cairo, but using a swtich setting that could be changed at runtime. GDI+ has been available for Windows since XP was released in 2001, and Direct2D since Windows 7 in 2009. I think it's about time we upgrade the Windows graphics from GDI to at least GDI+. I am willing to contribute to these changes, but I would want assurances that we would accept a common interface for the advanced features all these improved graphics back-ends include. They all include alpha blending, gradient brushes, matrix transforms, vector shaped clipping paths, and more. My recommend approach to adding these features to the core LCL Canvas class would be to: A) Change the underlying widgetset to operate with these new graphic backends and operate the same as before, but fixing a few problems like allowing Canavs.Draw to work between 32 bits per pixel surfaces correctly. B) Add an advanced canvas interface for new features like gradient brushes, vector clipping paths and such. Widgetsets can implement the advanced interface and use it in conjunction with the original TCanvas class. Examples: Canvas.Matrix.Rotate(PI / 6); Canvas.AddPath(Polygon); Canvas.Clip; Canvas.Fill(Gradient); TPolygon = array of TPointF; IAdvancedCanvas = interface ... procedure AddPath(Polygon: TPolygon); procedure Clip; procedure Fill(Brush: IBrush); property Matrix: IMatrix read GetMatrix write SetMatrix; .... end; Suggestions? -------------- next part -------------- An HTML attachment was scrubbed... URL: From werner.pamler at freenet.de Wed Apr 25 19:56:52 2018 From: werner.pamler at freenet.de (Werner Pamler) Date: Wed, 25 Apr 2018 19:56:52 +0200 Subject: [Lazarus] Component editors and related Message-ID: <2e8e9aae-dc4b-cc10-e398-9c078195cc70@freenet.de> Hi all, currently I am porting those JVCL components which look interesting to me (https://sourceforge.net/p/lazarus-ccr/svn/HEAD/tree/components/jvcllaz/), but at the moment I am stuck with the component editor of the TJvOutlookBar. This is some kind of two-level vertical menu. The top level is a list of TJvOutlookBarPage items, and each page has a list of TJvOutlookbarButton items as second level. Both lists inherit from TCollection. My problem is that in the component tree of the object inspector I see only the page items, but not the button "sub-items". See attached screen shot of Lazarus and the Delphi version for comparison. How can I make the button subnodes appear in the component tree? Another problem: The component comes with a ComponentEditor for the entire class, which looks similar to that of a TCollection, but contains a treeview to display the page-button relationships. After some twiddling around I was able to make this work in Lazarus, i.e. when I add nodes to the tree in the component editor the corresponding buttons or pages are added to the control on the form designer; and when I navigate in the component editor's tree the selected object follows in the component tree and in the object inspector. But the opposite direction does not work:  When I add a page or button in the object inspector (by using the Pages and Buttons collection property editors) the tree in the component editor is not updated. How can I do this? Any hints greatly appreciated. Werner -------------- next part -------------- A non-text attachment was scrubbed... Name: JvOutlookBar_Delphi.png Type: image/png Size: 12397 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: JvOutlookBar_Laz.png Type: image/png Size: 15851 bytes Desc: not available URL: From zeljko at holobit.net Wed Apr 25 20:01:01 2018 From: zeljko at holobit.net (zeljko) Date: Wed, 25 Apr 2018 20:01:01 +0200 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: References: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> <82083ab5-dac2-4568-0854-347036a2c6b5@fastwebnet.it> Message-ID: On 25.04.2018 16:30, Anthony Walter via Lazarus wrote: > I am trying to paint controls, so I need to eventually Canvas.Draw() to > get a graphic onto a control. I've been working on creating a fully > featured web browser for Lazarus and have been looking at the underlying > widgetset interface code. > > Gtk3, which my project currently works great on, uses the now required > Cairo system for painting Gtk widgets. I've already had to patch the > Gtk3 LCL interface section quite a bit to fix errors and I'll submit > those changes when I publish my project. That would be nice. > > However, the LCL Gtk2 widgetset is stuck using the Gdk system for > drawing, even though that was deprecated early on in the Gtk2 lifetime > and Cairo has been recommend for a decade or more. I would like to > submit a patch for Gtk2 replacing Gdk with Cairo, but using a swtich > setting that could be changed at runtime. +1, maybe add Gtk2UseCairo as default. .... paths are also welcome, afair win32,qt and gtk2/3 supports paths and it can be implemented inside widgetsets. zeljko From vojtech.cihak at atlas.cz Wed Apr 25 20:40:17 2018 From: vojtech.cihak at atlas.cz (=?utf-8?q?Vojt=C4=9Bch_=C4=8Cih=C3=A1k?=) Date: Wed, 25 Apr 2018 20:40:17 +0200 Subject: [Lazarus] =?utf-8?q?Component_editors_and_related?= In-Reply-To: 00000000893000022400016e4fc8 References: 00000000893000022400016e4fc8 Message-ID: <20180425204017.1C3573CE@atlas.cz> Hi,   ad 1: I never tried two level collection. Are they all published (both collections and their items)?   ad 2: You can do (in your component editor) something like:   var aHook: TPropertyEditorHook; begin   ...   aHook:=nil;       if not GetHook(aHook) then exit;   ...   //add or insert:     AddedItem:=aComponent.Columns.Add;     aHook.PersistentAdded(AddedItem, True);  //this notifies component tree     aHook.SelectOnlyThis(AddedItem);   //this selects added object   //deleting    DeletedItem:=aComponent.Columns[aIndex];    aHook.DeletePersistent(TPersistent(DeletedItem));   //this notifies component tree   V.      ______________________________________________________________ > Od: Werner Pamler via Lazarus > Komu: Lazarus mailing list > Datum: 25.04.2018 19:56 > Předmět: [Lazarus] Component editors and related > Hi all, currently I am porting those JVCL components which look interesting to me (https://sourceforge.net/p/lazarus-ccr/svn/HEAD/tree/components/jvcllaz/ ), but at the moment I am stuck with the component editor of the TJvOutlookBar. This is some kind of two-level vertical menu. The top level is a list of TJvOutlookBarPage items, and each page has a list of TJvOutlookbarButton items as second level. Both lists inherit from TCollection. My problem is that in the component tree of the object inspector I see only the page items, but not the button "sub-items". See attached screen shot of Lazarus and the Delphi version for comparison. How can I make the button subnodes appear in the component tree? Another problem: The component comes with a ComponentEditor for the entire class, which looks similar to that of a TCollection, but contains a treeview to display the page-button relationships. After some twiddling around I was able to make this work in Lazarus, i.e. when I add nodes to the tree in the component editor the corresponding buttons or pages are added to the control on the form designer; and when I navigate in the component editor's tree the selected object follows in the component tree and in the object inspector. But the opposite direction does not work:  When I add a page or button in the object inspector (by using the Pages and Buttons collection property editors) the tree in the component editor is not updated. How can I do this? Any hints greatly appreciated. Werner ---------- -- _______________________________________________ Lazarus mailing list Lazarus at lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus -------------- next part -------------- An HTML attachment was scrubbed... URL: From werner.pamler at freenet.de Wed Apr 25 22:07:26 2018 From: werner.pamler at freenet.de (Werner Pamler) Date: Wed, 25 Apr 2018 22:07:26 +0200 Subject: [Lazarus] Component editors and related In-Reply-To: <20180425204017.1C3573CE@atlas.cz> References: <20180425204017.1C3573CE@atlas.cz> Message-ID: <75e68054-b8f6-cbae-7959-42fba73ee5ff@freenet.de> Am 25.04.2018 um 20:40 schrieb Vojtěch Čihák via Lazarus: > > ad 1: I never tried two level collection. Are they all published (both > collections and their items)? > Yes. And both collections are accessible in the object inspector: The JvOutlookBar has a property "Pages", the ellipsis button next to it opens the usual collection property editor which can be used to add, delete or rearrange pages. And when one of the pages is selected the object inspector displays the property "Buttons", again with an ellipsis button to open another collection property editor, now for the buttons. This part is working out of the box. The problem is the component tree which only shows the page nodes but no button nodes. > ad 2: You can do (in your component editor) something like: > > var aHook: TPropertyEditorHook; > > begin > >   ... > >   aHook:=nil; > >       if not GetHook(aHook) then exit; > >   ... > >   //add or insert: > > AddedItem:=aComponent.Columns.Add; > > aHook.PersistentAdded(AddedItem, True);  //this notifies component tree > > aHook.SelectOnlyThis(AddedItem);   //this selects added object > >   //deleting > >    DeletedItem:=aComponent.Columns[aIndex]; > >  aHook.DeletePersistent(TPersistent(DeletedItem)); //this notifies > component tree > This is for notification of the component tree by the component editor and this code is already there and working. What I want is notification of the component editor by the designer if pages or buttons are added while the component editor is open (the component editor is not modal). -------------- next part -------------- An HTML attachment was scrubbed... URL: From lazarus at kluug.net Thu Apr 26 07:26:31 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Thu, 26 Apr 2018 07:26:31 +0200 Subject: [Lazarus] Canvas cannot draw properly if has an alpha channel? In-Reply-To: References: <6bc0febe-d0e2-390b-1886-8a9463c98cb4@fastwebnet.it> <82083ab5-dac2-4568-0854-347036a2c6b5@fastwebnet.it> Message-ID: On 25.04.2018 16:30, Anthony Walter via Lazarus wrote: > Suggestions? You obviously know much more in this topic than I do, so it's hard to comment for me. Just a note about win32: AFAIK the LCL supports only Windows XP and up officially since 1.8. So there is no problem to switch to GDI+. I am quite sure any improvements will be highly appreciated. Ondrej From dec12 at avidsoft.com.hk Thu Apr 26 12:00:48 2018 From: dec12 at avidsoft.com.hk (Dennis) Date: Thu, 26 Apr 2018 18:00:48 +0800 Subject: [Lazarus] What is the hot key to jump to the unit's implementation uses clause Message-ID: <42cf403a-5c2f-9fc9-29ae-435a99415dfb@avidsoft.com.hk> From time to time, I need to add an unit to the uses clause of the implement section of the unit. Dennis -------------- next part -------------- An HTML attachment was scrubbed... URL: From lazarus at kluug.net Thu Apr 26 12:02:56 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Thu, 26 Apr 2018 12:02:56 +0200 Subject: [Lazarus] What is the hot key to jump to the unit's implementation uses clause In-Reply-To: <42cf403a-5c2f-9fc9-29ae-435a99415dfb@avidsoft.com.hk> References: <42cf403a-5c2f-9fc9-29ae-435a99415dfb@avidsoft.com.hk> Message-ID: On 26.04.2018 12:00, Dennis via Lazarus wrote: > From time to time, I need to add an unit to the uses clause of the > implement section of the unit. Just use the search function of the Key Mappings IDE options... It has a tool button as well. Ondrej -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: migibbidgdjocjio.png Type: image/png Size: 12334 bytes Desc: not available URL: From nc-gaertnma at netcologne.de Thu Apr 26 12:07:25 2018 From: nc-gaertnma at netcologne.de (Mattias Gaertner) Date: Thu, 26 Apr 2018 12:07:25 +0200 Subject: [Lazarus] What is the hot key to jump to the unit's implementation uses clause In-Reply-To: <42cf403a-5c2f-9fc9-29ae-435a99415dfb@avidsoft.com.hk> References: <42cf403a-5c2f-9fc9-29ae-435a99415dfb@avidsoft.com.hk> Message-ID: <20180426120725.04a6e566@limapholos.matflo.wg> On Thu, 26 Apr 2018 18:00:48 +0800 Dennis via Lazarus wrote: > From time to time, I need to add an unit to the uses clause of the > implement section of the unit. Tools / Options / Editor / Key Mappings. Search for "impl" and set a key. Or alternatively use Cody's identifier dictionary, which adds the unit automatically, so you don't need to jump at all. Mattias From werner.pamler at freenet.de Thu Apr 26 14:33:15 2018 From: werner.pamler at freenet.de (Werner Pamler) Date: Thu, 26 Apr 2018 14:33:15 +0200 Subject: [Lazarus] Component editors and related In-Reply-To: <75e68054-b8f6-cbae-7959-42fba73ee5ff@freenet.de> References: <20180425204017.1C3573CE@atlas.cz> <75e68054-b8f6-cbae-7959-42fba73ee5ff@freenet.de> Message-ID: <1c87df41-b7b0-f942-40f3-753eec8f3a2a@freenet.de> Am 25.04.2018 um 22:07 schrieb Werner Pamler via Lazarus: > Am 25.04.2018 um 20:40 schrieb Vojtěch Čihák via Lazarus: >> >> ad 1: I never tried two level collection. Are they all published >> (both collections and their items)? >> > > Yes. And both collections are accessible in the object inspector: The > JvOutlookBar has a property "Pages", the ellipsis button next to it > opens the usual collection property editor which can be used to add, > delete or rearrange pages. And when one of the pages is selected the > object inspector displays the property "Buttons", again with an > ellipsis button to open another collection property editor, now for > the buttons. This part is working out of the box. The problem is the > component tree which only shows the page nodes but no button nodes. I am getting the impression that this is a bug of the component tree. The listed page items inherit from TCollectionItem, not from TComponent. The component tree somehow must be instructed to look for another collection within each page colletionItem. >> ad 2: You can do (in your component editor) something like: >> >> var aHook: TPropertyEditorHook; >> >> begin >> >>   ... >> >>   aHook:=nil; >> >>       if not GetHook(aHook) then exit; >> >>   ... >> >>   //add or insert: >> >> AddedItem:=aComponent.Columns.Add; >> >> aHook.PersistentAdded(AddedItem, True);  //this notifies component tree >> >> aHook.SelectOnlyThis(AddedItem);   //this selects added object >> >>   //deleting >> >>    DeletedItem:=aComponent.Columns[aIndex]; >> >>  aHook.DeletePersistent(TPersistent(DeletedItem)); //this notifies >> component tree >> > > This is for notification of the component tree by the component editor > and this code is already there and working. What I want is > notification of the component editor by the designer if pages or > buttons are added while the component editor is open (the component > editor is not modal). I was able to solve this based on code I found in unit components/ideintf/fieldseditor. The key point is that handlers for GlobalDesignHook events/notifications must be added. BTW, there is a "GlobalDesignHook" and a "FDesigner.PropertyEditorHook" - are they the same, or: what is the difference? -------------- next part -------------- An HTML attachment was scrubbed... URL: From nc-gaertnma at netcologne.de Thu Apr 26 14:57:18 2018 From: nc-gaertnma at netcologne.de (Mattias Gaertner) Date: Thu, 26 Apr 2018 14:57:18 +0200 Subject: [Lazarus] Component editors and related In-Reply-To: <1c87df41-b7b0-f942-40f3-753eec8f3a2a@freenet.de> References: <20180425204017.1C3573CE@atlas.cz> <75e68054-b8f6-cbae-7959-42fba73ee5ff@freenet.de> <1c87df41-b7b0-f942-40f3-753eec8f3a2a@freenet.de> Message-ID: <20180426145718.2a466255@limapholos.matflo.wg> On Thu, 26 Apr 2018 14:33:15 +0200 Werner Pamler via Lazarus wrote: >[...]there is a > "GlobalDesignHook" and a "FDesigner.PropertyEditorHook" - are they the > same, or: what is the difference? They are the same. Mattias From lazarus at mfriebe.de Thu Apr 26 18:35:29 2018 From: lazarus at mfriebe.de (Martin Frb) Date: Thu, 26 Apr 2018 18:35:29 +0200 Subject: [Lazarus] Selection block/brace In-Reply-To: <20180425030158.6ABBF57C@atlas.cz> References: <20180425030158.6ABBF57C@atlas.cz> Message-ID: On 25/04/2018 03:01, Vojtěch Čihák via Lazarus wrote: > Hi, > > I tried two items from Lazarus Edit menu: Select to Brace and Select Code Block. Both seem do nothing. Are they broken? I didn't use them before so I expexted they would do what their name say. I have Lazarus 1.9.0 r57693M FPC 3.1.1 x86_64-linux-qt. > Select to brace works well, if the caret is at a brace ()[]{} "Code block" may not yet be implemented (check console output), needs to be verified. If so should be hidden.... From aaa5500 at ya.ru Thu Apr 26 11:00:56 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Thu, 26 Apr 2018 12:00:56 +0300 Subject: [Lazarus] LCL TImageList method wish Message-ID: Ondrej, this patch https://github.com/graemeg/lazarus/commit/0ff493e8cf2b6e4f1c971561db87d2579396eacd makes the same for 4 WS'es: it gets bitmap from imagelist for some resolution. Wish: make TImageList.GetBitmapForResulution and make this patch simpler. -- Regards, Alexey From lazarus at kluug.net Thu Apr 26 20:05:14 2018 From: lazarus at kluug.net (Ondrej Pokorny) Date: Thu, 26 Apr 2018 20:05:14 +0200 Subject: [Lazarus] LCL TImageList method wish In-Reply-To: References: Message-ID: <5e328d89-14cf-d169-8983-8ac01586ce37@kluug.net> On 26.04.2018 11:00, AlexeyT via Lazarus wrote: > this patch > https://github.com/graemeg/lazarus/commit/0ff493e8cf2b6e4f1c971561db87d2579396eacd > makes the same for 4 WS'es: it gets bitmap from imagelist for some > resolution. > Wish: make TImageList.GetBitmapForResulution and make this patch simpler. You mean you want to simplify 2 calls: AValue.GetImageIndexAndEffect AImageRes.GetBitmap into one call: AValue.GetBitmap ? OK, if you feel it is really worth it, feel free to send a patch. + You will need to keep GetImageIndexAndEffect anyway. Ondrej From vojtech.cihak at atlas.cz Thu Apr 26 21:56:45 2018 From: vojtech.cihak at atlas.cz (=?utf-8?q?Vojt=C4=9Bch_=C4=8Cih=C3=A1k?=) Date: Thu, 26 Apr 2018 21:56:45 +0200 Subject: [Lazarus] =?utf-8?q?Selection_block/brace?= In-Reply-To: 00000000894300024898016e4fe3 References: <20180425030158.6ABBF57C@atlas.cz> 00000000894300024898016e4fe3 Message-ID: <20180426215645.E90E26EF@atlas.cz> Hi, Select to Brace does nothing, no matter if caret is outside or inside (),[] or {}. What it shoulld do?   (abc|def) should select "def"?   Thanks,   V. ______________________________________________________________ > Od: Martin Frb via Lazarus > Komu: lazarus at lists.lazarus-ide.org > Datum: 26.04.2018 18:35 > Předmět: Re: [Lazarus] Selection block/brace > On 25/04/2018 03:01, Vojtěch Čihák via Lazarus wrote: > Hi, >   > I tried two items from Lazarus Edit menu: Select to Brace and Select Code Block. Both seem do nothing. Are they broken? I didn't use them before so I expexted they would do what their name say. I have Lazarus 1.9.0 r57693M FPC 3.1.1 x86_64-linux-qt. > Select to brace works well, if the caret is at a brace ()[]{} "Code block" may not yet be implemented (check console output), needs to be verified. If so should be hidden.... -- _______________________________________________ Lazarus mailing list Lazarus at lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus -------------- next part -------------- An HTML attachment was scrubbed... URL: From lazarus at mfriebe.de Thu Apr 26 22:12:00 2018 From: lazarus at mfriebe.de (Martin Frb) Date: Thu, 26 Apr 2018 22:12:00 +0200 Subject: [Lazarus] Selection block/brace In-Reply-To: <20180426215645.E90E26EF@atlas.cz> References: <20180425030158.6ABBF57C@atlas.cz> <20180426215645.E90E26EF@atlas.cz> Message-ID: <759b48cc-94da-144c-a7f0-7fd2a54eba6d@mfriebe.de> On 26/04/2018 21:56, Vojtěch Čihák via Lazarus wrote: > > Hi, > > Select to Brace does nothing, no matter if caret is outside or inside > (),[] or {}. > > What it shoulld do? > > (abc|def) should select "def"? > > It seems to only work, if the caret is either before the opening ( or behind the ) It then selects the entire text (both brackets, and the content) This is just from a quick test, using trunk (but a few weeks old) -------------- next part -------------- An HTML attachment was scrubbed... URL: From mailinglists at geldenhuys.co.uk Thu Apr 26 23:44:19 2018 From: mailinglists at geldenhuys.co.uk (Graeme Geldenhuys) Date: Thu, 26 Apr 2018 22:44:19 +0100 Subject: [Lazarus] What is the hot key to jump to the unit's implementation uses clause In-Reply-To: <20180426120725.04a6e566@limapholos.matflo.wg> References: <42cf403a-5c2f-9fc9-29ae-435a99415dfb@avidsoft.com.hk> <20180426120725.04a6e566@limapholos.matflo.wg> Message-ID: On 2018-04-26 11:07, Mattias Gaertner via Lazarus wrote: > Or alternatively use Cody's identifier dictionary, which adds the unit > automatically, so you don't need to jump at all. For us poor sods that are forced to work with Delphi XE3, can't you port Cody, CodeTools and basically the whole Lazarus IDE to work with the delphi compiler? ;-) Regards, Graeme From michael at freepascal.org Thu Apr 26 23:48:52 2018 From: michael at freepascal.org (Michael Van Canneyt) Date: Thu, 26 Apr 2018 23:48:52 +0200 (CEST) Subject: [Lazarus] What is the hot key to jump to the unit's implementation uses clause In-Reply-To: References: <42cf403a-5c2f-9fc9-29ae-435a99415dfb@avidsoft.com.hk> <20180426120725.04a6e566@limapholos.matflo.wg> Message-ID: On Thu, 26 Apr 2018, Graeme Geldenhuys via Lazarus wrote: > On 2018-04-26 11:07, Mattias Gaertner via Lazarus wrote: >> Or alternatively use Cody's identifier dictionary, which adds the unit >> automatically, so you don't need to jump at all. > > For us poor sods that are forced to work with Delphi XE3, can't you port > Cody, CodeTools and basically the whole Lazarus IDE to work with the > delphi compiler? ;-) You should be able to do so in the same way that it currently uses pas2js. Michael. From Special at Joepgen.com Fri Apr 27 11:05:49 2018 From: Special at Joepgen.com (Joe) Date: Fri, 27 Apr 2018 11:05:49 +0200 Subject: [Lazarus] Lazarus still not usable with VNC under Raspbian Message-ID: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> Hi, community, on Pi computers under Raspbian controlled over VNC the Lazarus code editor doesn't recognize keystrokes with AltGr and therefore characters like {[]}\ can't be put in. That's a known issue since 2016 (https://bugs.freepascal.org/view.php?id=30544#c107874). Unfortunately, this report is still unassigned and it seems nobody of the developers cares about it. So, the 70+ million Raspberry Pi users all over the world cant' develop Lazarus programs when controlling their Pis over the VNC Server built into Raspbian. The contributor of the VNC Server built into Raspian Stretch is RealVNC. I asked them for help concerning this problem. Yesterday I got this from Linda, RealVNC Product Support: "We did manage to reproduce this from Windows with a German keyboard layout. We can confirm that it only affects this particular application. Lazarus does appear to discard key events with the same timestamp, which I think is not correct behaviour, which they would need to fix to make this work. There's not really much we can do to fix this, since we don't explicitly generate the timestamps on the events - the X server is doing this. Given that the X server is ok with sending the key events to the Lazarus application with the same timestamp, I think it should be handling this ... Please log a bug with the Lazarus developer." Steps to reproduce the problem: Prepare a SD card with Raspbian Stretch, current version, and boot a Pi with it. Enable VNC and install Lazarus (current version under Raspian  is Lazarus 1.6.2). Now, from a Windows 10 computer, using VNCViewer 6.0.3. x64 from RealVNC, connect to the Pi, open Lazarus, click in the code Editor Window and depress AltGr + {. The charcter is not shown. Please, could one of the developers have a look at this? Regards --  Joe -------------- next part -------------- An HTML attachment was scrubbed... URL: From aaa5500 at ya.ru Sat Apr 28 12:19:59 2018 From: aaa5500 at ya.ru (AlexeyT) Date: Sat, 28 Apr 2018 13:19:59 +0300 Subject: [Lazarus] FormStyle=fsStayOnTop: broken? Message-ID: <0f085731-8d28-a675-7fb9-af196a0b2f7c@ya.ru> Win32 and gtk2 app cannot show form on top. Pls confirm somebody? -- Regards, Alexey From vojtech.cihak at atlas.cz Sun Apr 29 02:54:08 2018 From: vojtech.cihak at atlas.cz (=?utf-8?q?Vojt=C4=9Bch_=C4=8Cih=C3=A1k?=) Date: Sun, 29 Apr 2018 02:54:08 +0200 Subject: [Lazarus] =?utf-8?q?FormStyle=3DfsStayOnTop=3A_broken=3F?= In-Reply-To: 00000000894d00025b84016e503a References: 00000000894d00025b84016e503a Message-ID: <20180429025408.1225D3F1@atlas.cz> Hi, it works here for GTk2, i.e. normal main form + fsStayOnTop form (a tool window). I have Plasma (KDE). Isn't it related to your window manager?   V. ______________________________________________________________ > Od: AlexeyT via Lazarus > Komu: Lazarus mailing list > Datum: 28.04.2018 12:19 > Předmět: [Lazarus] FormStyle=fsStayOnTop: broken? > Win32 and gtk2 app cannot show form on top. Pls confirm somebody? -- Regards, Alexey -- _______________________________________________ Lazarus mailing list Lazarus at lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus -------------- next part -------------- An HTML attachment was scrubbed... URL: From nc-gaertnma at netcologne.de Sun Apr 29 08:43:29 2018 From: nc-gaertnma at netcologne.de (Mattias Gaertner) Date: Sun, 29 Apr 2018 08:43:29 +0200 Subject: [Lazarus] Lazarus still not usable with VNC under Raspbian In-Reply-To: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> References: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> Message-ID: <20180429084329.6ce8a81c@limapholos.matflo.wg> On Fri, 27 Apr 2018 11:05:49 +0200 Joe via Lazarus wrote: >[...] > on Pi computers under Raspbian controlled over VNC the Lazarus code > editor doesn't recognize keystrokes with AltGr and therefore characters > like {[]}\ can't be put in. That's a known issue since 2016 > (https://bugs.freepascal.org/view.php?id=30544#c107874). I added a comment. Can you help me? Mattias From Special at Joepgen.com Sun Apr 29 11:56:09 2018 From: Special at Joepgen.com (Joe) Date: Sun, 29 Apr 2018 11:56:09 +0200 Subject: [Lazarus] Lazarus still not usable with VNC under Raspbian In-Reply-To: <20180429084329.6ce8a81c@limapholos.matflo.wg> References: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> <20180429084329.6ce8a81c@limapholos.matflo.wg> Message-ID: <9a914a90-f020-6d10-e519-3cf2eb02fee0@Joepgen.com> Am 29.04.2018 um 08:43 schrieb Mattias Gaertner via Lazarus: > On Fri, 27 Apr 2018 11:05:49 +0200 > Joe via Lazarus wrote: > >> [...] >> on Pi computers under Raspbian controlled over VNC the Lazarus code >> editor doesn't recognize keystrokes with AltGr and therefore characters >> like {[]}\ can't be put in. That's a known issue since 2016 >> (https://bugs.freepascal.org/view.php?id=30544#c107874). > I added a comment. Can you help me? > > Mattias Mattias, Unfortunately, actually I don't know how to get and compile Lazarus code. Is there a step by step introduction anywhere how to do it under Raspian Stretch or a script helping with this? Another possibility: I can open a Pi 3B+ via RDP for you, so you could have complete control over this system. One possible way to connect to this Pi over RDP is: Under Windows 10 (64), start c:\windows\system32\mstsc.exe. Joe From r030t1 at gmail.com Sun Apr 29 18:00:08 2018 From: r030t1 at gmail.com (R0b0t1) Date: Sun, 29 Apr 2018 11:00:08 -0500 Subject: [Lazarus] Lazarus still not usable with VNC under Raspbian In-Reply-To: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> References: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> Message-ID: On Fri, Apr 27, 2018 at 4:05 AM, Joe via Lazarus wrote: > Hi, community, > > on Pi computers under Raspbian controlled over VNC the Lazarus code editor > doesn't recognize keystrokes with AltGr and therefore characters like {[]}\ > can't be put in. That's a known issue since 2016 > (https://bugs.freepascal.org/view.php?id=30544#c107874). > This sounds like an issue with VNC. Can you ask there? VNC needs to accurately reproduce what you are typing for Lazarus to see it. Cheers, R0b0t1 From zmuogs at gmail.com Sun Apr 29 18:16:12 2018 From: zmuogs at gmail.com (=?UTF-8?Q?Valdas_Jank=c5=abnas?=) Date: Sun, 29 Apr 2018 19:16:12 +0300 Subject: [Lazarus] Runtime error: INCLOCKED Message-ID: <0910fc41-c5a6-cf44-eefe-8c6074888698@gmail.com> Hello, I'm stuck. I always getting weird error when executing this code (stripped down to minimum): program project1; type TElement = record strr: String; end; TList = array of TElement; Plist = ^TList; TSetting = record list: Plist; end; const _List: array [0..1] of TElement = ( (strr: 'a'), (strr: 'b')); _Settings: array [0..0] of TSetting = ( (list: @_List)); procedure Display(a: TList); begin // <-------------------------------- line 23 writeln(' +++ ', a[0].strr); end; var setting: TSetting; begin setting := _Settings[0]; writeln(' ---- ', Assigned(setting.list), ' ', Length(setting.list^)); Display(setting.list^); end. In console I get: ---- TRUE 2 Runtime error 216 at $0000000000400BD5 $0000000000400BD5 INCLOCKED $0000000000400216 DISPLAY, line 23 of project1.lpr $0000000000400360 main, line 32 of project1.lpr $000000000042BE00 SYSENTRY, line 129 of system.pp $00000000004001D2 Why I getting that error? Something wrong with records and constant initialization? My system is: Linux 4.13.0-39-generic #44-Ubuntu SMP Thu Apr 5 14:25:01 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux FPC (from SVN): 3.1.1 [2018/02/21] for x86_64 -- Valdas Jankūnas From nc-gaertnma at netcologne.de Sun Apr 29 18:39:44 2018 From: nc-gaertnma at netcologne.de (Mattias Gaertner) Date: Sun, 29 Apr 2018 18:39:44 +0200 Subject: [Lazarus] Lazarus still not usable with VNC under Raspbian In-Reply-To: <9a914a90-f020-6d10-e519-3cf2eb02fee0@Joepgen.com> References: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> <20180429084329.6ce8a81c@limapholos.matflo.wg> <9a914a90-f020-6d10-e519-3cf2eb02fee0@Joepgen.com> Message-ID: <20180429183944.7baccba4@limapholos.matflo.wg> On Sun, 29 Apr 2018 11:56:09 +0200 Joe via Lazarus wrote: >[...] > Unfortunately, actually I don't know how to get and compile Lazarus > code. Is there a step by step introduction anywhere how to do it under > Raspian Stretch or a script helping with this? Try this: http://wiki.freepascal.org/Getting_Lazarus#Getting_Lazarus_SVN_development_version svn co https://lazarus.svn.sourceforge.net/svnroot/lazarus/trunk lazarus cd lazarus make clean all OPT=-dLCLGtk2Fix30544 ./lazarus Mattias From vojtech.cihak at atlas.cz Sun Apr 29 19:38:38 2018 From: vojtech.cihak at atlas.cz (=?utf-8?q?Vojt=C4=9Bch_=C4=8Cih=C3=A1k?=) Date: Sun, 29 Apr 2018 19:38:38 +0200 Subject: [Lazarus] =?utf-8?q?Runtime_error=3A_INCLOCKED?= In-Reply-To: 00000000895200019094016f4fdc References: 00000000895200019094016f4fdc Message-ID: <20180429193838.EEACB7EE@atlas.cz> Hi,   I changed line 7:   TElement = record       strr: String;   end;   TList = array[0..1] of TElement;  //HERE   Plist = ^TList;      and demo works. Simply, static and dynamic arrays are not the same. AFAIR, dynamic array is just pointer while static array are data. I guess someone else will give you more detailed answer.   V. ______________________________________________________________ > Od: Valdas Jankūnas via Lazarus > Komu: Lazarus at lists.lazarus-ide.org > Datum: 29.04.2018 18:16 > Předmět: [Lazarus] Runtime error: INCLOCKED > type   TElement = record       strr: String;   end;   TList = array of TElement;   Plist = ^TList; ..... Why I getting that error? Something wrong with records and constant initialization? My system is: Linux 4.13.0-39-generic #44-Ubuntu SMP Thu Apr 5 14:25:01 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux FPC (from SVN): 3.1.1 [2018/02/21] for x86_64 --   Valdas Jankūnas -- _______________________________________________ Lazarus mailing list Lazarus at lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus -------------- next part -------------- An HTML attachment was scrubbed... URL: From robin.listas at telefonica.net Sun Apr 29 21:00:31 2018 From: robin.listas at telefonica.net (Carlos E. R.) Date: Sun, 29 Apr 2018 21:00:31 +0200 Subject: [Lazarus] Unknown error codes. Message-ID: <0a674747-22e9-ae1b-e304-31a590c87b7d@telefonica.net> Hi, The other day I got this error in a program (on Linux): cer at Telcontar:~/bin/lazarus/mios> ./crc32test ./crc32test An unhandled exception occurred at $0000000000400951: EInOutError: Unknown Run-Time error : 026 $0000000000400951 line 26 of crc32test.lpr $0000000000400A5C line 42 of crc32test.lpr crc32 = cer at Telcontar:~/bin/lazarus/mios> Notice the "Unknown" there. And indeed, error 26 is not listed here: A friend pointed me to this file: /usr/include/asm-generic/errno-base.h and there it is indeed listed: #define ETXTBSY 26 /* Text file busy */ The error number does match the situation: the IDE has hold of that file for debugging. Interesting. But the problem is, why is that error not listed, unknown? Today a poster wrote about this other error (subject: [Lazarus] Runtime error: INCLOCKED): Runtime error 216 at $0000000000400BD5 $0000000000400BD5 INCLOCKED $0000000000400216 DISPLAY, line 23 of project1.lpr $0000000000400360 main, line 32 of project1.lpr $000000000042BE00 SYSENTRY, line 129 of system.pp $00000000004001D2 which is not listed. I do not know if he is running Linux or Windows, so I have no idea either what the error is in his case. Do we know of more places that list those error numbers? Can we compose a full list? By the way, C has a function: "strerror(26)" which returns the text message for the error. I don't know if we have. -- Cheers / Saludos, Carlos E. R. (from 42.3 x86_64 "Malachite" at Telcontar) -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 181 bytes Desc: OpenPGP digital signature URL: From donald at ziesig.org Sun Apr 29 22:07:56 2018 From: donald at ziesig.org (Donald Ziesig) Date: Sun, 29 Apr 2018 16:07:56 -0400 Subject: [Lazarus] Unknown error codes. In-Reply-To: <0a674747-22e9-ae1b-e304-31a590c87b7d@telefonica.net> References: <0a674747-22e9-ae1b-e304-31a590c87b7d@telefonica.net> Message-ID: <43a9e561-88c3-5e58-6fea-bccea73fc53a@ziesig.org> On 04/29/2018 03:00 PM, Carlos E. R. via Lazarus wrote: > Hi, > > The other day I got this error in a program (on Linux): > > cer at Telcontar:~/bin/lazarus/mios> ./crc32test ./crc32test > An unhandled exception occurred at $0000000000400951: > EInOutError: Unknown Run-Time error : 026 > $0000000000400951 line 26 of crc32test.lpr > $0000000000400A5C line 42 of crc32test.lpr > > crc32 = cer at Telcontar:~/bin/lazarus/mios> > > > Notice the "Unknown" there. And indeed, error 26 is not listed here: > > > > > A friend pointed me to this file: > > /usr/include/asm-generic/errno-base.h > > and there it is indeed listed: > > #define ETXTBSY 26 /* Text file busy */ > > The error number does match the situation: the IDE has hold of that file > for debugging. Interesting. > > > But the problem is, why is that error not listed, unknown? > > Today a poster wrote about this other error (subject: [Lazarus] Runtime > error: INCLOCKED): > > Runtime error 216 at $0000000000400BD5 > $0000000000400BD5 INCLOCKED > $0000000000400216 DISPLAY, line 23 of project1.lpr > $0000000000400360 main, line 32 of project1.lpr > $000000000042BE00 SYSENTRY, line 129 of system.pp > $00000000004001D2 > > > which is not listed. I do not know if he is running Linux or Windows, so > I have no idea either what the error is in his case. > > Do we know of more places that list those error numbers? Can we compose > a full list? > > By the way, C has a function: "strerror(26)" which returns the text > message for the error. I don't know if we have. > > > > > 216 is a General Protection Fault. for other errors see: https://freepascal.org/docs-html/user/userap4.html Don Ziesig -------------- next part -------------- An HTML attachment was scrubbed... URL: From robin.listas at telefonica.net Sun Apr 29 23:55:59 2018 From: robin.listas at telefonica.net (Carlos E. R.) Date: Sun, 29 Apr 2018 23:55:59 +0200 Subject: [Lazarus] Unknown error codes. In-Reply-To: <43a9e561-88c3-5e58-6fea-bccea73fc53a@ziesig.org> References: <0a674747-22e9-ae1b-e304-31a590c87b7d@telefonica.net> <43a9e561-88c3-5e58-6fea-bccea73fc53a@ziesig.org> Message-ID: On 2018-04-29 22:07, Donald Ziesig via Lazarus wrote: > On 04/29/2018 03:00 PM, Carlos E. R. via Lazarus wrote: >> Hi, >> >> The other day I got this error in a program (on Linux): >> >> cer at Telcontar:~/bin/lazarus/mios> ./crc32test ./crc32test >> An unhandled exception occurred at $0000000000400951: >> EInOutError: Unknown Run-Time error : 026 >> $0000000000400951 line 26 of crc32test.lpr >> $0000000000400A5C line 42 of crc32test.lpr >> >> crc32 = cer at Telcontar:~/bin/lazarus/mios> >> >> >> Notice the "Unknown" there. And indeed, error 26 is not listed here: >> >> >> >> >> A friend pointed me to this file: >> >> /usr/include/asm-generic/errno-base.h ... >> Runtime error 216 at $0000000000400BD5 >> $0000000000400BD5 INCLOCKED >> $0000000000400216 DISPLAY, line 23 of project1.lpr >> $0000000000400360 main, line 32 of project1.lpr >> $000000000042BE00 SYSENTRY, line 129 of system.pp >> $00000000004001D2 ... > 216 is a General Protection Fault. > > for other errors see:  https://freepascal.org/docs-html/user/userap4.html It does not list the error 26 I got. It is possible that there are different numbers on different operating systems? That list seems to be related to Windows, but the link does not say. -- Cheers / Saludos, Carlos E. R. (from 42.3 x86_64 "Malachite" at Telcontar) -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 181 bytes Desc: OpenPGP digital signature URL: From bo.berglund at gmail.com Mon Apr 30 17:44:01 2018 From: bo.berglund at gmail.com (Bo Berglund) Date: Mon, 30 Apr 2018 17:44:01 +0200 Subject: [Lazarus] Lazarus still not usable with VNC under Raspbian References: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> Message-ID: <9ldeedl9d3atk9v45ll5o4ui4bk89agj20@4ax.com> On Fri, 27 Apr 2018 11:05:49 +0200, Joe via Lazarus wrote: >on Pi computers under Raspbian controlled over VNC the Lazarus code >editor doesn't recognize keystrokes with AltGr and therefore characters >like {[]}\ can't be put in. That's a known issue since 2016 >(https://bugs.freepascal.org/view.php?id=30544#c107874). In actual fact it is older than this.... I stareted a few threads on this very issue years ago: 2015-10-11: "Lazarus eats comment characters using Swedish keyboard" 2015-10-24: "Clipboard problem with Lazarus using VNC" 2016-02-24: "Keys not recognized by Lazarus 1.6 code editor" I made extensive tests to narrow down the problem and it condenses to this: 1) Appears when the Raspberry Pi is accessed via VNC (TightVNC in these discussions, I never tested RealVNC at the time). When using the RPi in console mode with a display and keyboard attached there are no problems at all. 2) Problem: The non-US characters cannot be entered into the Lazarus code editor window, nothing at all happens when one tries. 3) But in the Lazarus property editor window they arrive just fine! So Lazarus itself can handle them but the code editor apparently discards these characters if sent via VNC. 4) In all other editors or other applications I tested that are bundled with Raspbian there are no problems whatsoever with these characters. So the characters are properly supplied to the operating system and should appear inside Lazarus as well, but do no. 5) There is also a clipboard problem, where the copied text needs to be passed through for example GEdit in order to be possible to paste into the Lazarus code editor Since the community was not able to come up with a solution I have had to use the GEdit trick such that I open a Gedit window in Raspbian and there I enter the problem characters. Then when I need them in Lazarus I switch to GEdit, copy the appropriate character and then return to the Lazarus code editor to paste it in. This works, but is a bit of a tedious workaround. -- Bo Berglund Developer in Sweden From Special at Joepgen.com Mon Apr 30 23:54:38 2018 From: Special at Joepgen.com (Joe) Date: Mon, 30 Apr 2018 23:54:38 +0200 Subject: [Lazarus] Lazarus still not usable with VNC under Raspbian In-Reply-To: <9ldeedl9d3atk9v45ll5o4ui4bk89agj20@4ax.com> References: <1d2b3e5f-7781-7436-5a64-95a0eb49a0d9@Joepgen.com> <9ldeedl9d3atk9v45ll5o4ui4bk89agj20@4ax.com> Message-ID: Am 30.04.2018 um 17:44 schrieb Bo Berglund via Lazarus: > Since the community was not able to come up with a solution I have had > to use the GEdit trick such that I open a Gedit window in Raspbian and > there I enter the problem characters. Bo, there is another (ugly?) work around: In the code editor, type Control+Shift+M to open the Character Map, and in this map click on the character you want to insert. --  Joe