Re: [Lazarus] Jump to implementation
> Tools->Options->CodeTools->General->Jump directly to method body. What a relief :D Regards, Ara -- http://www.fastmail.com - Email service worth paying for. Try it for free -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Jump to implementation
Hi, When you do Ctrl+Click on a procedure you will go to the interface and then you should hit Ctrl+Shift+Down to go to the implementation, How can I make it like Delphi that when you do Ctrl+Click on a procedure it goes to implementation not interface? Regards, Ara -- http://www.fastmail.com - Or how I learned to stop worrying and love email again -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Graphics Contest
If you don't know already there is a graphics contest in Pascal. http://forum.lazarus.freepascal.org/index.php/topic,32626.0.html -- http://www.fastmail.com - The professional email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] JCF advanced record support
Hi, Can we have advanced record support in JCF? is there any bug report about this that I cant find or this is already implemented? JCF has problem like this but CodeTool And FPC have not any problem. > TADVRecord = record > private > function GetProp:boolean; > public > property Prop: boolean read GetProp; > end; Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] How TDBGrid works
> The data will be dupplicated. Yes and it is bad but as I said it is good for even couple thousand record. Regards, Ara -- http://www.fastmail.com - A fast, anti-spam email service. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] How TDBGrid works
A simple way is to make BufferCount=RecordCount so all record will be in buffer, it will be fast and easy to use and good for even couple of thousands records but not a real solution. Regards, Ara -- http://www.fastmail.com - Email service worth paying for. Try it for free -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] How TDBGrid works
> The easy one is probably to make two independent connections to the > database. More elaborated solutions would be for example copy all said > records to a memdataset and only connect that to a dbgrid, OR put the > records in a non-dataset enabled component, like a TDrawGrid or > TStringGrid, browsing that will not trigger any dataset events so > other db controls will be unaffected, etc. The problem here is I think > synchronizing stuff, you will have a funny time getting the updates to > those records into the original source. Jesus I'm afraid your way is not memory efficent. > If the wanted record is in window of > TDataLink.FirstRecord..FirstRecord + BufferCount - 1 you can > temporarily switch the record which supplies the field data by setting > TDatalink.ActiveRecord which doesn't fire any events. I assume you > know that. ;-) See for example the MSEgui functions > TGridDatalink.GetDisplay*Buffer(), BeginGridRow() and EndGridRow(). > https://gitlab.com/mseide-msegui/mseide-msegui/raw/master/lib/common/db/msedbedit.pas > If the wanted records are anywhere in the dataset you need a dataset > with random row data access. TMSEBufDataset supports it, please see > the TMSEBufDataset.Current* properties. > https://gitlab.com/mseide-msegui/mseide-msegui/raw/master/lib/common/db/msebufdataset.pas > The MSEgui dropdownlist DB-edits use this approach for lookups if > Dropdown.OptionsDB odb_directdata is set. Glad to hear from you Martin. Happy to see MSE support this and I will look it up. > A possible workaround could be to call TDataset.DisableControls(), to > fetch the needed records and to restore the DB cursor position before > calling EnableControls(). I fear it is not efficient and has > sideeffects. What side effects do you think about? Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] How TDBGrid works
Thanks. So what is the best way to provide those 100 to 1100 record at least without Dataset calling AfterScroll event? I want to not make any event while scrolling my custom Grid so other connected DB controls change their values otherwise while Im scrolling my custom grid it will cause calling all connected DB controls to update their values. I hope it is more clear now. Regards, Ara -- http://www.fastmail.com - A fast, anti-spam email service. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] How TDBGrid works
Thanks, It seems I should explain better. For RecordCount you are right and it seems DBGrid doesn't know correct number either otherwise it should has a better scroll size. I want to do something like DBGrid and for that I want to get only a part of data for example record 1000 to 1100 and for that I can set BufferCount to 100 but in this case I should navigate dataset to record 1000 to get these value but I prefer to not change RecNo and use something like DataLink's ActiveRecord that changes record you want without changing RecNo of Dataset. So if I have 1 Dataset that is fully load all 1500 record can I just print records from 1000 to 1100 without changing RecNo? Regards, Ara -- http://www.fastmail.com - Faster than the air-speed velocity of an unladen european swallow -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] How TDBGrid works
Jesus, In that demo if I set BufferCount to 9 always get 9 records and even Query.RecordCount will be 9 even result is more. How can I get real count? I can get count before setting the link but is it the best way? How can I move or scroll link without moving Query? I want to scroll the grid and get new data without changing RecNo. In your example if I only got 9 record for example but I want for example 20th record. Regards, Ara -- http://www.fastmail.com - Accessible with your email software or over the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] How TDBGrid works
Thanks for the explanation, with your demo its more clear to me. Regards, Ara -- http://www.fastmail.com - Choose from over 50 domains or use your own -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] How TDBGrid works
Hi, I'm curious about how TDBGrid now what to show in a column as value. I mean if I want to make a custom grid simple solution si going from first to last of TDataset and read columns value. I Browsed TDBGrid code lately but sadly I couldnt find how it works to get data without (as I think) browsing and changing TDataset records. Regards, Ara -- http://www.fastmail.com - Send your email first class -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] HEAPTRACE IFDEF
Thanks for the explanation Michael but I didnt have an idea about this ability. Regards, Ara -- http://www.fastmail.com - Or how I learned to stop worrying and love email again -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] HEAPTRACE IFDEF
> We do have documentation, you know. Is it so much to ask to > look at it ? > http://www.freepascal.org/docs-html/current/prog/progsu128.html No it is not but it is not came to my searches and FPC documentation is not much good for searching at least from google and if I know what I want I couldn't guess there is such like this ability and one way I will be left to know about this is that is reading doc for fun everyday like a book and keep reading it's changelog! > UseHeapTrace is a variable in unit heaptrc, which is silently used > when compiling with -gh. Thanks for the explanation. > $IF DECLARED is not supported by codetools. Should I report it as a bug or it already reported? Regards, Ara -- http://www.fastmail.com - Access all of your messages and folders wherever you are -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] HEAPTRACE IFDEF
> AFAIK, it's because it's not technically possible. As an amateur can I ask why? > Use {$IF DECLARED(useheaptrace)} in your main project file (just like > lazarus.pp uses it). Very interesting! I didnt know this ability,Thanks. How it works? what key names it has? But it has a problem, if you use this define IDE wont color it properly like you use normal defines, it that case it if define is not true it will pale. Regards, Ara -- http://www.fastmail.com - Does exactly what it says on the tin -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] HEAPTRACE IFDEF
My bad, I missed this http://bugs.freepascal.org/view.php?id=24681 But as it marked as "no change required" but I cant understand why we cant benefit from something like this that have an internal option in project option but we cant control to save the output without defining an internal define for project?! I think using heaptrc unit without this option is not useful enough because showing a program hep output in a message box is not even readable! Regards, Ara -- http://www.fastmail.com - Access all of your messages and folders wherever you are -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] HEAPTRACE IFDEF
Hi, Is there any or can we have a HEAPTRACE IFDEF so we can do something like this : > if FileExists('heap.trc') then > DeleteFile('heap.trc'); > SetHeapTraceOutput('heap.trc'); Regards, Ara -- http://www.fastmail.com - Send your email first class -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Remote debugging from Windows to Linux
Hi, As subject said I want to debug from my local Windows machine Lazarus a Linux server and for that I read wiki and all posts like: http://wiki.lazarus.freepascal.org/Remote_Debugging http://forum.lazarus.freepascal.org/index.php/topic,19014.0.html http://forum.lazarus.freepascal.org/index.php/topic,20101.0.html http://www.lazarusforum.de/viewtopic.php?f=4&t=6645 http://www.lazarusforum.de/viewtopic.php?f=9&t=6664 I cant make it work because I dont understand what should I do exactly and these posts seems old, so anyone here can explain in brief steps of doing this so I can update Wiki? Regards, Ara -- http://www.fastmail.com - Choose from over 50 domains or use your own -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Sort Code
Thanks Graeme but it sort line by line but I want to sort procedures and classes but it you choose multiple procedures it will mess the code and even you choose only definitions in class interface and sort them it will not sort implementations. Regards, Ara -- http://www.fastmail.com - Email service worth paying for. Try it for free -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Sort Code
Hi, I see JCF and CodeTool have many abilities and CodeTool also can complete code with declaring needed procedures with Ctrl+C shortcut. Now I have a code with on sorted events and procedures and it made me tired to find them so it made me ask is there a option or tool in one of these or other to make a unit procedures and even classes sort by name or something? Regards, Ara -- http://www.fastmail.com - Or how I learned to stop worrying and love email again -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] jcfidelazarus JEDI Code Formatter cannot handle generic and specialize keywords
What Lazarus version? Regards, Ara -- http://www.fastmail.com - Choose from over 50 domains or use your own -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] where do I put project wide conditional define?
> "-d" is the fpc flag for a define. See "fpc -h". Thanks, Ara -- http://www.fastmail.com - Access all of your messages and folders wherever you are -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] where do I put project wide conditional define?
> Add -dUse_XYZ to Project / Project Options / Compiler Options / > Custom Options Curiosity : Why a "d" in the beginning? Regards, Ara -- http://www.fastmail.com - A no graphics, no pop-ups email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Using libjpeg
Hi, Thanks for explanation Sandro. I checked your demo and even other demos and I can say they are interesting, I wish I had the source specially JPEG demo so I can check your results. Regards, Ara -- http://www.fastmail.com - Does exactly what it says on the tin -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Using libjpeg
Thanks. I will test it. Is there any particular reason that you didnt use official release? Why there is much difference? It seems I miss something! Regards, Ara -- http://www.fastmail.com - A fast, anti-spam email service. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Using libjpeg
Thank you very much for sharing. Clean. I looked into it and its questioning for me how it works? Implementations like I mentioned is not like it and documentations and even dlls in here http://www.libjpeg-turbo.org/Documentation/OfficialBinaries are not like that. Can you explain more? Regards, Ara -- http://www.fastmail.com - The professional email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Using libjpeg
Very interesting! Thanks for sharing, maybe I was wrong in implementation. Do you used any different header or implementation? Can you share it? @All : Is there a way to use libjpeg-*turbo *with Lazarus *without* using an external library like DLL? Regards, Ara -- http://www.fastmail.com - Faster than the air-speed velocity of an unladen european swallow -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Bashing the developers
> I, myself, am very thankful to Lazarus and FPC. Without them, I had to > pay a lot of money to upgrade to Delphi, which I hate after version 7, > for my work to make a living. I make money from a FREE open source > project which developers work without reward. I want to say loudly > here, THANK YOU ALL! Money is just a point, Major point for me is quality. I like FPC and Lazarus more than many programming tools I ever used, thanks to its developers all over the world. Regards, Ara -- http://www.fastmail.com - Choose from over 50 domains or use your own -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Bashing the developers
> As someone who has been active on this list for a few weeks only, I > want to take this opportunity to thank the developers both of Lazarus > and FPC for your work, and also for being among the most approachable > people in open source projects I know. You are part of why I migrated > most of my desktop work to Lazarus by now Me too. Thank you very much dear Juha ;) Regards, Ara -- http://www.fastmail.com - Same, same, but different... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Instalation on win 10
No just install and use it. Regards, Ara -- http://www.fastmail.com - A fast, anti-spam email service. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] PDF generator, try 2
Very good. Thanks. Red line left margin has problem in Google chrome default PDF viewer, maybe it is Chrome problem but I think you should know. Regards, Ara -- http://www.fastmail.com - Faster than the air-speed velocity of an unladen european swallow -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Using libjpeg
Thanks but I need libjpeg using because of speed and fpimage with UsePalette := False is not fast enough. My tests with libjpeg.dll and this header[1] id much faster than fpimage (half the time) so I wanted to have a native way using pasjpeg instead of a dll. Regards, Ara Links: 1. http://www.dev-center.de/header/libjpeg?cat=header&file=libjpeg -- http://www.fastmail.com - Same, same, but different... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Using libjpeg
Hi, I want use libjpeg and I found pasjpeg package in fpc that contains jpeglib.pas unit but I coudnt find a working demo to know how load a jpeg file and show it. Can anyone point me to a better direction? Regards, Ara -- http://www.fastmail.com - mmm... Fastmail... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> What did you use before? --pcp? If that works on commandline but not > in .cfg, then report a bug please. I will check more. > You need to ask them. I tried but he didnt answer this question nor previous one about his custom version so I asked maybe someone else know about that. > So there are good reasons why Lazarus does it the way it does. I can guessed that but my problem from the beginning was finding a better way and now I will edit Wiki for future. Regards, Ara -- http://www.fastmail.com - Does exactly what it says on the tin -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
Aha! If found the problem! I have a config folder in my Lazarus directory that has every config xml files like default Lazarus have in Appdata. When I open Lazarus forms shortcut like I said there was no problem but when I add that path to cfg it has problem until I changed the address to this : --primary-config-path=C:\Trunk\lazarus\config and now it solved and no problem. But Im still curios about how GetLazarus version works without a cfg file and it will be very good if any one can check that. Regards, Ara -- http://www.fastmail.com - mmm... Fastmail... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
Thanks Martin. This is what I done: * Get a Trunk Lazarus version and make it and make a shortcut and install all my packages and settings and ... * Make cfg file and add what you said in it with my Lazarus path something like this : --primary-config-path=C:\Trunk\lazarus * Run Lazarus and it cant find any package and settings! like a complete new install. Regards, Ara -- http://www.fastmail.com - The professional email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> The same as when you specified --pcp > > If you copied the lazarus.exe from another install, then you need to > rebuild it once. And add or remove packages if needed. unfortunately I cant understand you. Regards, Ara -- http://www.fastmail.com - A no graphics, no pop-ups email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> Could you try this: 1) Create shortcut on the desktop. 2) Using > Properties, add the parameters to it (and of course, save it). 3) Use > 'Pin to Taskbar' 4) Delete the shortcut on the desktop. I checked and it doesn't solve the problem and still there will be one opened Lazarus and one shortcut. Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> I understood your remark as "getlazarus offers this functionality > already". Yes and I want to know how. Regards, Ara -- http://www.fastmail.com - Send your email first class -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> That is what the lazarus.cfg file is for. > > Instead of supplying the parameters fer --pcp, you put them into the > cfg file. > > lazarus.exe, when started, looks for a lazarus.cfg file in the same > folder as the exe. If found it adds the content to its command line > params. (one per line). > > so if you have > c:\lazarus installation of 1.6, should use config in the default > location > c:\laz_trunk needs different config > > then you add > c:\laz_trunk\lazarus.cfg > with the --pcp param you need. > > And with that you can start c:\laz_trunk\lazarus.exe anyway you want, > it will use the pcp given in the cfg file. I done that but it will be the reason of many errors about installing packages. and again I cant find any cfg file about this config with GetLazarus version. > Right-click on pinned Lazarus, right-click on Lazarus, properties and > edit the target to add --pcp= (at least it works on my Win7) Thanks but my shortcut have this but problem is still there at least in Windows10. Can anyone with more experience than me if he got time get www.getlazarus.org version and give it a try? Regards, Ara -- http://www.fastmail.com - Same, same, but different... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> The recommende way is and has always been to use the -- > pcp=path/to/config commandline parameter. Why do you insist that it > must be done in another way? Why can you simpy use the mechanismes we > have provided for just that? If you don want a shortcut (why???) then > just start it from the console (as i do with lazarus fixes branch). Ok. One simple reason I dont like to make shortcut with custom parameter with my apps and one good reason for that is, Windows Taskbar that you can pin apps dont accept parameters so if you pin you Lazarus that runs with parameters and next time click on icon on taskbar it will open but keep another shortcut on Taskabr. It is annoying for someone likes me that like to keep my stuff organized. Second reason is Im curious, everytime I saw shortcut way for running multiple reason and it seems there is a better reason out there and Im a programmer I like to find a better way and when I cant I ask from others. Originally I should ask @Anthony about his works but it seems he refuse answering or supporting about his works so I ask here for future needs of others like me. Regards, Ara -- http://www.fastmail.com - Send your email first class -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> How do you know that it works ? What do mean from that? If you mean GetLaarus version I have one installed and if you mean I have another old Lazarus that I tried using cfg. But I want the best way for my trunk version so I can run it beside of stable version without making shortcut. Regards, Ara -- http://www.fastmail.com - Choose from over 50 domains or use your own -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> Of course it looses all the settings, because you just told it to look > in a different directory. Copy your original settings from their > default location over to the new one and you should be good to go. Ichecked and there is not any old cfg file. > Be careful. When copying all settings between too-different versions > it may call for trouble. editoroptions.xml is ok. fpcdefines.xml, > codetoolsoptions.xml and environmentoptions.xml could lead to issues > since they contain absolute paths of the original installation. package- > related files (packagefiles.xml, miscellaneousoptions.xml and > staticpackages.inc) can cause trouble if the new installation does not > support all required features of the old one. Yes I tried that and you are right. It is interesting that how GetLazarus version works. Regards, Ara -- http://www.fastmail.com - Same, same, but different... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Having multiple Lazarus like GetLazarus version
> Put a "lazarus.cfg" into the folder with lazarus.exe and write exactly > this line into this file. Thanks but it seems not a good way. Lazarus will lose all the setting ans installed package and also GetLazarus version doesn't use a cfg file as I searched so it can has a better answer. Regards, Ara -- http://www.fastmail.com - Does exactly what it says on the tin -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Having multiple Lazarus like GetLazarus version
Hi, As Wiki said here http://wiki.freepascal.org/Multiple_Lazarus I should make a shortcut for second Lazarus like this : > --primary-config-path=lazarusconf But I dont want to make a shortcut like this and like GetLazarus version I want to somehow set this config without making a new shortcut. Any one or @Anthony can tell me how? Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] PDF generator
Thank you Michael Van Canneyt. Regards, Ara -- http://www.fastmail.com - A no graphics, no pop-ups email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] How to automatically free classes/objects?
Subject say what I want and as discussed here there are couple of ways to do this and one of them is a custom garbage collector : http://stackoverflow.com/questions/415958/how-to-automatically-free-classes-objects I want to know is there any better way in Lazarus or what should I do? Regards, Ara -- http://www.fastmail.com - Send your email first class -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] TBufDataset CopyFromDataset
Thanks to Thaddy there is a patch that add this ability: http://bugs.freepascal.org/view.php?id=29761 Regards, Ara -- http://www.fastmail.com - The professional email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] TBufDataset CopyFromDataset
Hi, I want CopyFromDataset for TBufDataset so I can copy a dataset to it so I write it now. Problem is I never compile a fpc package before and now fpc dont recognize my new procedure although Lazarus will recognize it. How can I compile fcl-db package? Regards, Ara -- http://www.fastmail.com - A no graphics, no pop-ups email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] A good DB tree view
Hi, For my project I need a good tree view and the best free one was and is VirtualTree but it has not DB component and the only version I can found that could compile with Lazarus is this TVirtualDBTreeEx version[1]. It need a simple change and it will compile but it has a uncompleted demo that I cant compile and I dont have clue how it works and some test shows weird behavior so I want to ask : What is the best choice to have a good DB tree view? is there any component available or should I write code for every DB situation in my projects? Also a good ability of VirtualTree is that t can be used as a grid and the best grid I know is KGrid but it aslo have a not beautiful/weird DB behave and ic compare of VirtualTree abilities and speed will seems not a good choice. So all questions in one : Is there any good DB TreeView/Grid in Lazarus world? Regards, Ara Links: 1. https://github.com/adem0x/virtualdbtreeex -- http://www.fastmail.com - A no graphics, no pop-ups email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Easy to use memory dataset and TMemDataset problems
> Why not ? It should perfectly work without file. It seems I got a problem with changing properties in design time and then opening it. if I make everything in code it works good. But problem with memdatset and memds units still exist. Regards, Ara -- http://www.fastmail.com - Same, same, but different... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Easy to use memory dataset and TMemDataset problems
Hi, I want a memory dataset like VirtualTable [1]and really I cant understand what are these bufdataset and memdataset and wiki[2] page as I cant make bufdataset works without a file. I want an easy to sue memory dataset without any file usage. Yes there is a way to use TMemDataset like this as @Thaddy said: > program memdbtest; {$apptype console}{$mode objfpc} uses db,memds; > var MemDb:TMemDataset; begin MemDb:=TMemDataset.Create(nil); try > MemDb.FieldDefs.Add('NAME',ftString,20); MemDb.CreateTable; > MemDb.Open; MemDb.Append; MemDb.FieldByName('NAME').Value:='Free'; > MemDb.Post; MemDb.Append; > MemDb.FieldByName('NAME').Value:='Pascal'; MemDb.Post; > MemDb.SaveToFile('MemDb.txt'); // as long you do not close, you don't > have to save finally MemDb.Close; MemDb.Free; end; end. But as you can see it use memds unit that CodeTools has problem with memds unit and also it will replace it with MemDataSet unit that has a different TMemDataset without CreateTable option. Also Wiki [3]says that BufDataset is a better choice but is it really? and is it a choice for using as a memory dataset?how? Regards, Ara Links: 1. https://www.devart.com/vtable/ 2. http://wiki.freepascal.org/How_to_write_in-memory_database_applications_in_Lazarus/FPC 3. http://wiki.freepascal.org/How_to_write_in-memory_database_applications_in_Lazarus/FPC#Introduction -- http://www.fastmail.com - Same, same, but different... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Guess the problem with Heap
Hi, Im working on one of my projects and tried to make a release version, so I used shortcut button in build modes and add release mode but when I compile and run I get SIGSEGV error when main form want to be create. After many tries I found out that if I check "Use Heaptrc unit" in project debugging option program will run correctly even it is release mode so there is no debug info. So simple : If I check that option and use Heaptrc, no problem and if I unchecked it, error . Its a old project and I dont remind any code I write about heap so I cant find the problem so I want to ask anyone can guess what code can make such problem? Regards, Ara -- http://www.fastmail.com - Accessible with your email software or over the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Loading OpenGL error
I reinstall everything and tried a new test : 1. add lazopenglcontext 2. add OpenGLContext unit 3. type O:=TOpenGLControl.Create(self); 4. run and no problem. 5. type o.Parent:=self; 6. run and that error again. Regards, Ara -- http://www.fastmail.com - Accessible with your email software or over the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Loading OpenGL error
> I tried to replace old Lazarus and FPC OpenGl components with new one > and clean and recompile but problem is still there. It seemed taht it not used new FPC OpenGL package units because they are precompiled so I tried and delete compiled opengl units from units folder but not Lazarus says it cant find gl unit but gl.pp exists but not compiled and I tried to recompile Lazarus or cleanup but it wont compile FPC files. What should I do? Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Loading OpenGL error
> Are you sure it's in the OpenGL units initialization? Yes. > Can you test the Lazarus examples/openglcontrol/ demo, and see does it crash too? Yes. > we're using FPC OpenGL units on many platforms, including Windows 10, and we often test with latest FPC from trunk. And everything seems to work cool. And me too but in this Laptop its different and only with FPC 3 and above. > FPC OpenGL units did not have any "critical" change since a long time, so I doubt something broke there. But something break it for some computers. > And since you already tested that reverting old Lazarus version > doesn't help, it does indicate the problem is somewhere else... > Old FPC (2.6.4) with Lazarus 1 works OK. I tried to replace old Lazarus and FPC OpenGl components with new one and clean and recompile but problem is still there. Can any one help me to debug this? Regards, Ara -- http://www.fastmail.com - The professional email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Loading OpenGL error
I done two more tests: Get Lazarus 1.6 RC2 and still have problem. Copy and recompile OpenGL package from 1.0 to 1.7 and still have problem. So it seems problem is not because of OpenGL package. Any idea? Regards, Ara -- http://www.fastmail.com - Access your email from home and the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Loading OpenGL error
Hi, I have a new Laptop and with new Windows 10 and tried my old working demos and I tried it with Last Lazarus Trunk 1.7 and FPC 3.1.1 and just tried to run it and its happen : > A dynamic link library (DLL) initialization routine failed It is because OpenGL loading error and I dont have clue how to solve it. I already update all drivers and windows but nothing. Any one know how can I solve this or faced it before? And I tried it with Lazarus 1 and FPC 2.6.2 and it works good and it seems OpenGL units changed but I dont know what changes break it. Regards, Ara -- http://www.fastmail.com - mmm... Fastmail... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Exclude components from localization by path or text
Thanks Denis. Regards, Ara -- http://www.fastmail.com - mmm... Fastmail... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Exclude components from localization by path or text
Very good,Please let us know. Regards, Ara -- http://www.fastmail.com - The professional email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Exclude components from localization by path or text
> Is there any interest in such feature? Yea, sure! It can be very helpful for localization. Regards, Ara -- http://www.fastmail.com - Access your email from home and the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Can I assign items in an array all at once in FreePascal?
I like this one more : > It now is "because we haven't implemented it yet" Because : > A literal such as [10,20,30,40] is a set in pascal, not an array. Is not a good one I think. For example this one works : > function Test(Arr:array of integer); Usage: Test([1,2,3]); Why it cant work for assigning a var but it can be used for parameters? Regards, Ara -- http://www.fastmail.com - Same, same, but different... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Can I assign items in an array all at once in FreePascal?
Michael can I ask why we cant do something like this : > MyArr :=[10, 20, 30, 40]; Regards, Ara -- http://www.fastmail.com - Send your email first class -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Can I assign items in an array all at once in FreePascal?
Hi, As question explained here http://stackoverflow.com/questions/6493727/can-i-assign-items-in-an-array-all-at-once-in-delphi-pascal and the easiest answer is : > type TIntArray =arrayof integer;procedure TForm1.Button1Click(Sender: TObject);var MyArr: TIntArray;begin MyArr := TIntArray.Create(10,20,30,40);end; But problems are : Lazarus doesnt recognize Create for array but FPC will compile it but it seems it doesnt work so I want to ask what should I do for assign items in an array all at once in FreePascal? Regards, Ara -- http://www.fastmail.com - A fast, anti-spam email service. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] CodeTools bug
Hi, It seems CodeTools has a problem with packages that are in address with "#" in the directory name at least in Windows. It cant find package units and do auto complete but program will compile and this problem will happen for only packages and units that are in a folder like this "c:\test\#dir\package.lpk" . Please someone test and confirm it. Regards, Ara -- http://www.fastmail.com - Does exactly what it says on the tin -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Web vs desktop development
> See many threads (on the forum) about integrating ChromeKit or Gecko > into LCL app Of course I saw them but as I said I surprised from that I cant find any particular good one because I have habit that always there will be good thing made with FPC and Lazarus. But if you know a especial one please give me a link. Regards, Ara -- http://www.fastmail.com - Or how I learned to stop worrying and love email again -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Web vs desktop development
> The trend is actually switching to web+desktop applications. I.e. > Steam client or Delphi's "help" window. So each application is a > browser on its own. A smarter framework might suggest an alternative > to html+js, so it could integrate with any application easily, rather > than for a browser application. These app will be better these days because we can use them in as a website and an application with a same source and minor changes but one thing that amused me is that why until now I didnt see anything good from FPC and Lazarus people here? I know its a Open Source world and but I saw many great thing but not this,is there a problem or disagree about making these apps in FPC? As you can see they will be more apps like these and their problem is speed sometimes that it can be solved with FPC easily. Regards, Ara -- http://www.fastmail.com - A fast, anti-spam email service. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] A simple event problem in console program
So why Bart said : > Or define a type TNotifyProc = procedure(Sender: TObject); (Which the will not be of type TNotifyEvent) ? Regards, Ara -- http://www.fastmail.com - Or how I learned to stop worrying and love email again -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] A simple event problem in console program
Thanks it works for me. But a quick question: Why we always make events like "procedure () of object" if we can make without "of object" ? Regards, Ara -- http://www.fastmail.com - Accessible with your email software or over the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] GetLazarus Nightly version
Hi, Is there anyone here to answer about GetLazarus Nightly version? I remember the time that people here was disagree about making a new forum and now seems right to me because that forum and author email seems non responding. I want to know if it can cross compile from Windows 64bit to Linux 64bit? When I try to compile it says : > Fatal: Cannot find system used by fcllaz of package FCL. And also I want to know where can I change its default Delphi mode to objfpc mode. Regards, Ara -- http://www.fastmail.com - Access all of your messages and folders wherever you are -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] A simple event problem in console program
> A TNotifyEvent must be a procedure that is a method of a class. You > have created and tried to use a plain procedure instead. So how can I use a notify in a console program? > Because TNotifyEvent = procedure(Sender: TObject) of object; The 'of object' means you need a method, not a procedure. Yes I know but as you know this way we can use to notify in applications but in console I dont know. I dont write console programs much. Regards, Ara -- http://www.fastmail.com - Or how I learned to stop worrying and love email again -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] A simple event problem in console program
Hi, Maybe Im tierd but could any one tell me what this code wont work: > program Project1; > > {$mode objfpc}{$H+} > > uses Classes, SysUtils; > > type > > { Tbook } > > Tbook = class private fnoti: TNotifyEvent; public property > noti: TNotifyEvent read fnoti write fnoti; end; > > var b: Tbook; > > procedure notievent(Sender: TObject); begin WriteLn('test'); end; > > begin b := Tbook.Create; b.noti := @notievent; //ERROR b.Free; > and give this error: > project1.lpr(30,13) Error: Incompatible types: got " procedure(TObject);Register>" expected " procedure(TObject) of object;Register>" Regards, Ara -- http://www.fastmail.com - Or how I learned to stop worrying and love email again -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Libraries delayed loading
Hi, I have many libraries and all the wrappers are static and I cant change all of them to dynamic loading but I want to put them in different folder my program root. It seems there is "delayed" option is in Delphi that give you time to SetDllDirectory and change the path before loading dll. And as I checked Lazarus hasnt this option so I want to ask is there any alternative way except changing all wrapper to dynamic loading for loading dll from different place without changing system path. http://wiki.lazarus.freepascal.org/Dynamically_loading_headers#Solution_of_Delphi_2010_.28modifying_compiler.29 http://stackoverflow.com/questions/15240729/delphi-dll-organization-static-and-dynamic-loading Regards, Ara -- http://www.fastmail.com - Access your email from home and the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Setting environment variables for libraries
Hi, I have many libraries (dll,so) and they come with wrappers with constant library path and file name. I want to move these libraries to a specific folder and load from there so one way I know is to change them and load them dynamicly but I cant do it every time new library version came out with new changes. So I hope there be a some kind of virtual environment variables so when I call x.dll, it search also there and conenct to it like when you put dll in system32 in windows and your program will find it. I dont want to change system environment variables because these libraries will use only in my program. I tried something like this: > program project1; > > {$mode objfpc}{$H+} > > uses {$IFDEF UNIX} {$IFDEF UseCThreads} cthreads, {$ENDIF} {$ENDIF} > Interfaces, // this includes the LCL widgetset Forms, Unit1 { you > can add units after this }, SysUtils, Windows; > > {$R *.res} > > var s: string; var oldPath: string; // Original PATH value > buildPath: string; // Intermediate path for setting new environment > variable newPath: string; // Retrieve the PATH again and compare > against oldPath begin s := ExtractFilePath(ParamStr(0)) + > 'libra\32\'; //SetDllDirectory(PChar(s)); > > oldPath := SysUtils.GetEnvironmentVariable('PATH'); buildPath := > oldPath + ';' + s; if SetEnvironmentVariable('PATH', > PChar(buildPath)) then begin writeln('PATH updated!'); newPath > := SysUtils.GetEnvironmentVariable('PATH'); end; > > writeln; writeln('Showing old path:'); writeln(oldPath); writeln; > writeln('Showing new path:'); writeln(newPath); //readln; > > > RequireDerivedFormResource := True; Application.Initialize; > Application.CreateForm(TForm1, Form1); Application.Run; end. > > unit Unit1; > > {$mode objfpc}{$H+} > > interface > > uses Classes, SysUtils, FileUtil, Forms, Controls, Graphics, > Dialogs,LCLType,BASS,windows; > > { TForm1 } > > type TForm1 = class(TForm) procedure FormCreate(Sender: > TObject); private { private declarations } public { public > declarations } end; > > var Form1: TForm1; > > implementation > > {$R *.lfm} > > { TForm1 } > > procedure TForm1.FormCreate(Sender: TObject); begin > > if (HIWORD(BASS_GetVersion) <> BASSVERSION) then begin > ShowMessage('BASS_GetVersion'); Halt; end; > > // Initialize audio - default device, 44100hz, stereo, 16 bits > if not BASS_Init(-1, 44100, 0, Handle, nil) then > ShowMessage('BASS_Init'); end; end. As you can see project file uses Unit1 and it uses BASS and it wants to call dll before our path changes! :| How can I solve this? Regards, Ara -- http://www.fastmail.com - Access your email from home and the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Is there any pascal implimentition on websocket comunication?
> Yes. Look for bauglir websocket. It uses synapse. I use it, it works very well Michael it is so old and I cant compile it with FPC 3 and need many changes that I made but they cause many error, Do you know any updated version? Regards, Ara -- http://www.fastmail.com - Or how I learned to stop worrying and love email again -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Getting MySQL process output
> is it maybe sent via something other than STDOUT? STDERR perhaps? for > security reasons maybe? Nothing! :| > Process := TProcess.Create(nil); with Process do begin Executable > := '"C:\Program Files (x86)\MySQL\MySQL Server 5.5\bin\mysql.exe" -u > root -p'; with Parameters do begin Options := [poUsePipes, > poNoConsole]; end; Execute; Sleep(1000); > WriteLn(Process.Output.NumBytesAvailable); // will be 0 but it write > "Enter password" WriteLn(Process.Stderr.NumBytesAvailable); // > will be 0 but it write "Enter password" end; Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Getting MySQL process output
> Did you use the poNoConsole option ? Yes and NumByteAvailable is 0 but it write "Enter Password" message in console. I can understand why this message goes in Lazarus output or wherever except output of TProcess. Regards, Ara -- http://www.fastmail.com - Access all of your messages and folders wherever you are -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Getting MySQL process output
> What is the -WG param ? I could not find it in the documentation. Win32 GUI application in compiler option> conf and target > If you are afraid that it will be visible in the task list, just set > the MYSQL_PWD and USER environment variables in TProcess. Good point. > All in all, I suspect you would probably be better off using the mysql > library. The mysql command is just a front-end to that. As I said in my first question is not just a MySQL problem, for this case I need to connect to mysql cmd not library and for that I need to communicate with it and write SQl query and send and then receive the result. I just dont know how read its output,its not like a simple CMD program that you run and get the output simply. Regards, Ara -- http://www.fastmail.com - Faster than the air-speed velocity of an unladen european swallow -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Getting MySQL process output
> Simple Loop: - Read from program output - interpret the output and - write to program input. That's all the "general" advice we can give. Yea sure I do this and I have no problem with simple CMD programs. Problem is programs like MySQL that can be run from one line command and need reading and writing. When you run this command : '"C:\Program Files (x86)\MySQL\MySQL Server 5.5\bin\mysql.exe" -u root -p'; You will get nothing in the output, it is locked and you even cant call NumByteAvailable but interesting is if you remove -WG param you can see Enter password: it will write in CMD that opens with program it self from Lazarus. Regards, Ara -- http://www.fastmail.com - Same, same, but different... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Getting MySQL process output
> Simply said: You cannot. Sure it doable. For example alternative consoles can work with mysql with help of cmd and runs cmd and then run mysql with cmd and with that they get some kind of control but I dont how to do this with Lazarus. For example if you run this without -WG command you can see that Lazarus cmd gets password message but could nopt write and it run conhost.exe. So I want to know how simulate a console. Regards, Ara -- http://www.fastmail.com - Send your email first class -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Getting MySQL process output
[Cross posted on forum so if you want answer there : http://forum.lazarus.freepascal.org/index.php/topic,30635.0.html ] Hi, I want to play with MySQL process and get what ever it write to console so I write this code: > Process := TProcess.Create(nil); with Process do begin > Executable := 'C:\Program Files (x86)\MySQL\MySQL Server > 5.5\bin\mysql.exe'; with Parameters do begin Options := > [poUsePipes]; Add('-u'); Add('root'); Add('-p'); > end; Execute; while Process.Running do > Memo1.Lines.LoadFromStream(Process.Output); end; But the problem is that this will freeze because there is no output but console window write : > Enter password: How can I get this in my application and all others? As I said I want to work with MySQL executable and read from and write in it, So I dont want to use its library or any other DB component. Regards, Ara -- http://www.fastmail.com - Choose from over 50 domains or use your own -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Strange application startup problem
It seems FPC optimizer know what line will be used so compile them and probably line initialization lines but how I can find out what line will run! It is so ugly that you can not find out what line in your program will run! Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Strange application startup problem
How can I know what lines run from the first line? Regards, Ara -- http://www.fastmail.com - Does exactly what it says on the tin -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Strange application startup problem
I think about that and I checked as I can but neither of them will run and also I add another project and add all the packages and uses units in FormX to it so if any Initialization make the problem I could find it but no, without no problem it will run. Just this project and just this form cause problem and Lazarus it self also doesn't give any error about form error or what ever. Regards, Ara -- http://www.fastmail.com - Choose from over 50 domains or use your own -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Strange application startup problem
Hi, Today I open one of my applications and start working on it and made many changes and hit the run but it will immediately crash! So like a programmer I add a break poit on my main form create and no it will not run and crash will happen. So I add another break point to first line of application: > begin RequireDerivedFormResource:=True; // Here > Application.Initialize; Application.CreateForm(TFormX, FormX); > Application.Run; end. the lpr file is made automatically but even the first line will never run! It was strange so I delete CreateForm line and run again : > begin RequireDerivedFormResource:=True; // Here > Application.Initialize; Application.Run; end. And now everything work! So the problem is form but what? I add a new clean form and make it main form like this : > begin RequireDerivedFormResource:=True; > Application.Initialize; Application.CreateForm(TForm1, Form1); > Application.Run; end. And run and everything OK. So add a button on Form1 and write : > Application.CreateForm(TFormX, FormX); FormX.Show; And again crash without even running the line in button or clicking it. Project is in default mode (made from lazarus and I every debug mode is on and I checked default debug mode ) and nothing, I also uncheck Win32 target platform so maybe it show any message in CMD but nothing. This program is bug and I cant share the code or forms and I dont know what was changed this and I can go back,I just need a debug info. So anyone has a clue on what is the problem or how find it? I do this in a Windows 8 64bit with Lazarus 1.5 and FPC 3.1.1 . Regards, Ara -- http://www.fastmail.com - Choose from over 50 domains or use your own -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] recent Message Delivery Failures
And no annoying email. Thanks Vincent. Ara -- http://www.fastmail.com - Faster than the air-speed velocity of an unladen european swallow -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] recent Message Delivery Failures
A testing mail! Regards, Ara -- http://www.fastmail.com - Does exactly what it says on the tin -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
> Animation effects (like seen on Android and iOS) is another matter - they benefit from the GPU a lot. And this is Im looking to. Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] recent Message Delivery Failures
I shared this problem with admin and until now there isn't any answer. Regards, Ara -- http://www.fastmail.com - Faster than the air-speed velocity of an unladen european swallow -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus MailList maintainer
Thanks,It seems I am tired ;) Regards, Ara -- http://www.fastmail.com - Accessible with your email software or over the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Lazarus MailList maintainer
Hi, Can I know who is Lazarus MailList maintainer? Regards, Ara -- http://www.fastmail.com - Faster than the air-speed velocity of an unladen european swallow -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
> http://tulip-ui.azurewebsites.net/ Not the UI controls but the engine maybe. > AsphyreSphinx is now Pascal eXtended Library. I read about it but I didnt test it,any one here has experince with it? > Doesn't Cairo have a hardware acceleration backend? Then again, you'd > have to have a cairo dependency. It seems it use cario is for Linux(I dont know it),can it used in Windows with fast accelerated graphical functions? Regards, Ara -- http://www.fastmail.com - The professional email service -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Video: Custom Lazarus Help URLs
Thanks for the point. Its good to add this to GetLazarus NightlyBuild. Regards, Ara -- http://www.fastmail.com - IMAP accessible web-mail -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
> Obviously, if you want non standard speed, you need to consider non standard complexity. Yes I think like this.As I guess your products are not for end user client so you could use flash without any problem and in my case I want it for some special case and clients so making an special GUI on OpenGL can be an answer because as I said in this GUI there is many image processing and the best I know is OpenGL. But I be happy to know any other solution or a GUI made already. Regards, Ara -- http://www.fastmail.com - Send your email first class -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
Thanks Graeme. Im not going to make GUI toolkit,Just controls that I need.fpGUI and mse are full and functional kits but I want a simple and with special target very fast GUI. Regards, Ara -- http://www.fastmail.com - The way an email service should be -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
> First of, everything concerning glBegin and friends is ancient stuff, > don't touch them. Don't touch glMatrix* or anything like that, too. Do it on your own (even in JS if you use WebGL). In short: Do the matrix math on the CPU, use the most optimal vertex submission mechanism supported by the targeted version (vertex arrays, VBOs, etc.) and use shaders. Second, every platform has its own flavor of OpenGL: OpenGL for the Desktop, OpenGL ES on mobile and WebGL for the browser. All are similar and yet quite different. All have their own versions and the associated problems. Use OpenGL only if you need its features and then pick your platform and don't try to handle them all in one software. OpenGL is not easy to handle and you really have to dive in deep to make the most of it. You can do a lot of stuff really fast but the API is very old and it shows more and more. You have very little direct control of your graphics hardware and moving data to/from the card is cumbersome. Personally I am waiting for the successor of OpenGL (Vulkan) which does away with the multiple platform versions (Normal, Web, ES), unifies them and is stated to give you much more control of the hardware. I am sure things are not getting much easier in the high speed graphics department but a lot more organized and hopefully better to maintain. R. > Very interesting point about OpenGL and Vulkan.Thanks. By the way do you know any implementation of OpenGL or Vulkan for GUI in pascal for my recent research? Regards, Ara -- http://www.fastmail.com - Email service worth paying for. Try it for free -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
> Just trying to help... Thank you very much Michael and I want to know more about this system.Maybe It not used in this case but be used for my current UI system or next one. Regards, Ara -- http://www.fastmail.com - A fast, anti-spam email service. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
> He had used OpenGL to do the GUI for a project (as he had found by > testing that this was the fastest solution). Exactly. I dont know why but I am fascinated about fast GUIs. I am not a professional game developer but for my projects sometimes I need animations and image processing and Im tired of making a graphical component or a especial painter for a case and want to know is there any work available or it is a sane way to make all of my components from OpenGl or something like this and even used OS theme for my view like getting windows 8 draw for a button but make it as a texture and give it to my imaginary button component. As I said I saw this in Firemonkey .It even make DBGrid 3D! I dont need 3D component but I need fast accelerated OpenGL or something like this for my custom GUI. Regards, Ara -- http://www.fastmail.com - Accessible with your email software or over the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
> That's true but something like 2.0 or 3.2 can most likely nowadays be > reasonably targeted. If you go 1.2 it should work everywhere. On phones you can offen use the current version as people upgrade their phones often. Often more problematic are different driver versions and their bugs. If you want to really handle all versions it gets really cumbersome as you have to implement different render paths as the most optimal path differs greatly between OpenGL (major) versions. Hopefully things get better with Vulkan. > But as I read about this a problem is for example in Android phones their support OpenGl ES and taht is diffent to OpenGL like does have glBegin glEnd and it can be kind of problem? It seems you have experience about this?What you think? Regards, Ara -- http://www.fastmail.com - Accessible with your email software or over the web -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Fast GUI
Thanks Michael,Martin,Reimar and Ondrej. As you said martin it is not easy to use but give you very good performance.I tested it with BGRABitmap OpenGL and it can be very good. But it can have many problems like making text box or memo or whatever. I know there are GUI components with OpenGL even with Pascal but I couldnt test anyone and want to know is there any one here test them or have experience in this field or not. Martin is mse support transparent text box or these component with OpenGL? As I remember you said that mse use no handle per control so what mse do for text component or lists? Regards, Ara -- http://www.fastmail.com - A fast, anti-spam email service. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus