From gambas at ...1... Sun Oct 1 10:52:03 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 1 Oct 2006 10:52:03 +0200 Subject: [Gambas-user] Wiki documentation update Message-ID: <200610011052.03865.gambas@...1...> Hi all, I have wrote the documentation of the gb.form and the gb.form.mdi component. I have added some pretty pictures of controls too. :-) The DateBox and TimeBox controls documentation were not written, as these controls will be removed and replaced in the future. The GridView documentation has no picture, as there will be a merge between GridView and TableView soon. I have wrote a quick & dirty documentation on the behaviour of Window for Daniel Campos, but everybody can read it at: http://gambasdoc.org/help/api/guicomp/window The information included in that page will be put in the Window class documenation in the future. Regards, -- Benoit Minisini From rolf.frogs at ...221... Sun Oct 1 12:21:43 2006 From: rolf.frogs at ...221... (rolf) Date: Sun, 1 Oct 2006 12:21:43 +0200 Subject: [Gambas-user] Wiki documentation update In-Reply-To: <200610011052.03865.gambas@...1...> References: <200610011052.03865.gambas@...1...> Message-ID: <200610011221.43442.rolf.frogs@...221...> Hi Benoit > I have wrote the documentation of the gb.form and the gb.form.mdi > component. > > I have added some pretty pictures of controls too. :-) > > The DateBox and TimeBox controls documentation were not written, as these > controls will be removed and replaced in the future. > > The GridView documentation has no picture, as there will be a merge between > GridView and TableView soon. > > I have wrote a quick & dirty documentation on the behaviour of Window for > Daniel Campos, but everybody can read it at: > > http://gambasdoc.org/help/api/guicomp/window > > The information included in that page will be put in the Window class > documenation in the future. I think documentation is the most important "to do" for gambas. And - my whish is - to have a search function in the documentation wiki. Many thanks for GAMBAS and a nice day Rolf From leonardo at ...1237... Sun Oct 1 14:49:37 2006 From: leonardo at ...1237... (Leonardo Miliani) Date: Sun, 01 Oct 2006 14:49:37 +0200 Subject: [Gambas-user] How to speed up Gambas? Message-ID: <451FB961.4010405@...1237...> I think that this is a well known problem but... how can I speed up Gambas executables? I've noticed that if I run a program inside the Gambas IDE I get the SAME performances that running its binary executable via console... In VB there is a LOT of difference between the same code executed inside the VB IDE or via executable... And, second question: I think that Gambas is not very fast itself... Similar testing code on the same computer gives me different times under Windows/VB and Linux/Gambas. Is there in the near future a plan to "wake up" Gambas? :-) -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software From gambas at ...1... Sun Oct 1 15:02:07 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 1 Oct 2006 15:02:07 +0200 Subject: [Gambas-user] How to speed up Gambas? In-Reply-To: <451FB961.4010405@...1237...> References: <451FB961.4010405@...1237...> Message-ID: <200610011502.07630.gambas@...1...> On Sunday 01 October 2006 14:49, Leonardo Miliani wrote: > I think that this is a well known problem but... how can I speed up > Gambas executables? > I've noticed that if I run a program inside the Gambas IDE I get the > SAME performances that running its binary executable via console... > In VB there is a LOT of difference between the same code executed inside > the VB IDE or via executable... Gambas is not VB, and running a Gambas program in the IDE is the same as running it outside of the IDE. > > And, second question: I think that Gambas is not very fast itself... > Similar testing code on the same computer gives me different times under > Windows/VB and Linux/Gambas. Is there in the near future a plan to "wake > up" Gambas? :-) I think that the Gambas interpreter is lower than the VB interpreter. But I couldn't have done a developmenent environment like Gambas IDE in VB. It would have been far too slow! So there is speed and speed. :-) Do you have some number? I.e. some code and some time measurement? Anyway, there is no plan to "wake up" Gambas at the moment. Maybe in Gambas 3.0 or 4.0? :-) Regards, -- Benoit Minisini From nando_f at ...1382... Sun Oct 1 21:32:02 2006 From: nando_f at ...1382... (nando) Date: Sun, 1 Oct 2006 15:32:02 -0400 Subject: [Gambas-user] How to speed up Gambas? In-Reply-To: <200610011502.07630.gambas@...1...> References: <451FB961.4010405@...1237...> <200610011502.07630.gambas@...1...> Message-ID: <20061001192635.M2140@...1382...> One thing I am using Gambas for is real-time wireless data reception and transmission. Although it is version 1.0.6, it is very stable and has run for months continuous. We all know that there are different methods to solve the same problem. For an interpreter, Gambas has pretty good speed and is reasonable and Benoit has done an excellent job. I suggest you look at ways to optimize your code on how you solve your problem. -Fernando ---------- Original Message ----------- From: Benoit Minisini To: mailing list for gambas users Sent: Sun, 1 Oct 2006 15:02:07 +0200 Subject: Re: [Gambas-user] How to speed up Gambas? > On Sunday 01 October 2006 14:49, Leonardo Miliani wrote: > > I think that this is a well known problem but... how can I speed up > > Gambas executables? > > I've noticed that if I run a program inside the Gambas IDE I get the > > SAME performances that running its binary executable via console... > > In VB there is a LOT of difference between the same code executed inside > > the VB IDE or via executable... > > Gambas is not VB, and running a Gambas program in the IDE is the same as > running it outside of the IDE. > > > > > And, second question: I think that Gambas is not very fast itself... > > Similar testing code on the same computer gives me different times under > > Windows/VB and Linux/Gambas. Is there in the near future a plan to "wake > > up" Gambas? :-) > > I think that the Gambas interpreter is lower than the VB interpreter. But I > couldn't have done a developmenent environment like Gambas IDE in VB. It > would have been far too slow! So there is speed and speed. :-) > > Do you have some number? I.e. some code and some time measurement? > > Anyway, there is no plan to "wake up" Gambas at the moment. Maybe in Gambas > 3.0 or 4.0? :-) > > Regards, > > -- > Benoit Minisini > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From gambas at ...1... Sun Oct 1 21:37:41 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 1 Oct 2006 21:37:41 +0200 Subject: [Gambas-user] How to speed up Gambas? In-Reply-To: <451FB961.4010405@...1237...> References: <451FB961.4010405@...1237...> Message-ID: <200610012137.41299.gambas@...1...> On Sunday 01 October 2006 14:49, Leonardo Miliani wrote: > I think that this is a well known problem but... how can I speed up > Gambas executables? > I've noticed that if I run a program inside the Gambas IDE I get the > SAME performances that running its binary executable via console... > In VB there is a LOT of difference between the same code executed inside > the VB IDE or via executable... > > And, second question: I think that Gambas is not very fast itself... > Similar testing code on the same computer gives me different times under > Windows/VB and Linux/Gambas. Is there in the near future a plan to "wake > up" Gambas? :-) Maybe can you tell us which process is slow exactly? -- Benoit Minisini From sourceforge-raindog2 at ...94... Sun Oct 1 22:11:17 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sun, 1 Oct 2006 16:11:17 -0400 Subject: [Gambas-user] How to speed up Gambas? In-Reply-To: <451FB961.4010405@...1237...> References: <451FB961.4010405@...1237...> Message-ID: <200610011611.17946.sourceforge-raindog2@...94...> On Sunday 01 October 2006 08:49, Leonardo Miliani wrote: > I've noticed that if I run a program inside the Gambas IDE I > get the SAME performances that running its binary executable > via console... In VB there is a LOT of difference between the > same code executed inside the VB IDE or via executable... Gambas executables aren't Linux binaries, they're compiled into pseudocode with #!env gbr2 (or something) at the top. Unlike VB, what you're running in the IDE is the exact same code that you're running in production. > And, second question: I think that Gambas is not very fast > itself... Similar testing code on the same computer gives me > different times under Windows/VB and Linux/Gambas. Is there in > the near future a plan to "wake up" Gambas? :-) I've found that for some things VB is faster and for other things Gambas is faster. I actually amazed one client with how much faster a Gambas reimplementation of one of their in-house VB programs was. Rob From leonardo at ...1237... Sun Oct 1 23:27:59 2006 From: leonardo at ...1237... (Leonardo Miliani) Date: Sun, 01 Oct 2006 23:27:59 +0200 Subject: [Gambas-user] How to speed up Gambas? In-Reply-To: <200610012137.41299.gambas@...1...> References: <451FB961.4010405@...1237...> <200610012137.41299.gambas@...1...> Message-ID: <452032DF.5000609@...1237...> Benoit Minisini ha scritto: > On Sunday 01 October 2006 14:49, Leonardo Miliani wrote: >> I think that this is a well known problem but... how can I speed up >> Gambas executables? >> I've noticed that if I run a program inside the Gambas IDE I get the >> SAME performances that running its binary executable via console... >> In VB there is a LOT of difference between the same code executed inside >> the VB IDE or via executable... >> >> And, second question: I think that Gambas is not very fast itself... >> Similar testing code on the same computer gives me different times under >> Windows/VB and Linux/Gambas. Is there in the near future a plan to "wake >> up" Gambas? :-) > > Maybe can you tell us which process is slow exactly? > No particular process at all. It seems to me that Gambas is fast but not faster enough... Maybe am I pretending too much? :-) -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software From rolf.frogs at ...221... Mon Oct 2 14:44:19 2006 From: rolf.frogs at ...221... (rolf) Date: Mon, 2 Oct 2006 14:44:19 +0200 Subject: [Gambas-user] Error when selecting a picture in a picturebox Message-ID: <200610021444.20184.rolf.frogs@...221...> Hi Benoit, hi everybody else when I try to select a picture in the property dialog the ide breaks with a stack overflow error. The picturebox has Drop set to TRUE and a plain border. I use GAMBAS 1.9.43 on debian testing. Many thanks Rolf BTW: How can I show a droped picture with the given path of "file:///home/pictures/test.jpg" in a drop event. From wdahn at ...1000... Tue Oct 3 08:56:18 2006 From: wdahn at ...1000... (Werner) Date: Tue, 03 Oct 2006 14:56:18 +0800 Subject: [Gambas-user] Selections in Columnview (and maybe other controls) in Multi mode Message-ID: <45220992.9070200@...1000...> ISTR that selections in multi mode were made such that the shift and control keys had an effect; the shift key for selecting a range of columns and control key for toggling the selection of an individual column on/off. That was about a year ago(1.0.10?). It seems that now (1.9.43) these modifier keys are ignored. What am I missing? Thanks and Best Regards Werner Dahn From amsoft at ...683... Tue Oct 3 10:57:35 2006 From: amsoft at ...683... (Amnon) Date: Tue, 03 Oct 2006 08:57:35 GMT Subject: [Gambas-user] parse out the mount-points of fstab - how? Message-ID: <20061003085736.21602.qmail@...1590...> I need some help here. I wounder how I can parse the fstab to get all mount-points in a listbox. Thats what I have: PUBLIC SUB dvddrives_Click() DIM devar AS String[] DIM i AS Integer DIM procLoad AS String mountpoint = "" ' fstab search IF mountpoint = "" THEN IF Exist ("/etc/fstab") = TRUE THEN listbox1.clear SHELL "cat /etc/fstab >" & sTemp WAIT ProcLoad = file.Load (sTemp) KILL sTemp listbox1.contents=ProcLoad FOR i = 0 TO listbox1.count-1 IF Instr(listbox1[i].Text , drives.text) > 0 THEN devar=Split(listbox1[i].text, "") mountpoint=devar[1] mountpointlist.add(mountpoint) END IF NEXT END IF END IF IF dvdsource = "" THEN logtext.Insert("[Debug message] No VIDEODVD found!"& "\n") ELSE logtext.Insert("[Debug message] VIDEODVD source: " & dvdsource & "\n") END IF END I don't get the string-value I can use to split. --------------------------------------------- Free POP3 Email from www.Gawab.com Sign up NOW and get your account @gawab.com!! From rospolosco at ...152... Tue Oct 3 11:23:26 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Tue, 3 Oct 2006 11:23:26 +0200 Subject: [Gambas-user] parse out the mount-points of fstab - how? In-Reply-To: <20061003085736.21602.qmail@...1590...> References: <20061003085736.21602.qmail@...1590...> Message-ID: <200610031123.26628.rospolosco@...152...> Alle 10:57, marted? 3 ottobre 2006, Amnon ha scritto: > devar=Split(listbox1[i].text, " here, but what one?>") > ? ?mountpoint=devar[1] > ? ?mountpointlist.add(mountpoint) > ? ?END IF > ? ?NEXT > ? ?END IF > ? ?END IF > ? ? Hi. Try this. devar=Split(listbox1[i].text, " ", "", TRUE) Saluti, Stefano From rospolosco at ...152... Tue Oct 3 11:28:44 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Tue, 3 Oct 2006 11:28:44 +0200 Subject: [Gambas-user] parse out the mount-points of fstab - how? In-Reply-To: <200610031126.52838.rospolosco@...152...> References: <20061003085736.21602.qmail@...1590...> <200610031123.26628.rospolosco@...152...> <200610031126.52838.rospolosco@...152...> Message-ID: <200610031128.44926.rospolosco@...152...> Alle 11:26, marted? 3 ottobre 2006, hai scritto: > Alle 11:23, marted? 3 ottobre 2006, hai scritto: > > Alle 10:57, marted? 3 ottobre 2006, Amnon ha scritto: > > > devar=Split(listbox1[i].text, " > > here, but what one?>") > > > ? ?mountpoint=devar[1] > > > ? ?mountpointlist.add(mountpoint) > > > ? ?END IF > > > ? ?NEXT > > > ? ?END IF > > > ? ?END IF > > > ? ? > > Hi. > > > > Try this. > > > > devar=Split(listbox1[i].text, " ", "", TRUE) > > > > Saluti, > > > > Stefano > > This works with Gambas2. From leonardo at ...1237... Tue Oct 3 15:10:32 2006 From: leonardo at ...1237... (Leonardo Miliani) Date: Tue, 03 Oct 2006 15:10:32 +0200 Subject: [Gambas-user] Maybe 2 errors in Gambas 1.9.43 Message-ID: <45226148.7020009@...1237...> Hi Benoit, maybe I've found 2 bugs in Gambas 1.9.43. Check them for sure.. 1) Even if I open an existing project or I have create a new one, if I click on Project/Properties and try to change the program icon, I get this error: "This application has raised an unexpected error and must abort. [3] Stack overflow. FSelectIcon.cmbSize_Click.77" I can confirm that it didn't exist on older versions because I have a project that I'm working on that has the icon changed. 2) I cannot translate any project I made with Gambas... I work on the italian localization of Gambas and if I choose to translate my project, Gambas tells me that it cannot find the italian localization file, getting this error: "Non riesco a leggere il file di traduzione per la lingua 'italiano (Italia)' .Fatto." (in english, it means: "I can't read the translation file for the language 'italian (Italy)'". Same error if I try to add a language (in the example, I've tried to add the english language). You can see in the screenshot I've sent that in the combomenu (red arrow) I haven't any language that I can choose from.. -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software -------------- next part -------------- A non-text attachment was scrubbed... Name: Immagine.jpg Type: image/jpeg Size: 48074 bytes Desc: not available URL: From joe1962 at ...626... Tue Oct 3 18:21:28 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Tue, 3 Oct 2006 12:21:28 -0400 Subject: [Gambas-user] How to authenticate and switch to root user from within gambas application? In-Reply-To: <6c208f950610021337i482bba6doe7f46ef172c0f336@...627...> References: <6c208f950610021337i482bba6doe7f46ef172c0f336@...627...> Message-ID: <6c208f950610030921u631d6bf8w4579f1457e4ad67c@...627...> On 10/2/06, Jose J. Rodriguez wrote: > Anybody have an idea how to switch to the root user from within a > Gambas application? There would be a dialog asking for the password, > of course, but how to authenticate and switch to running as root > afterwards? > I've checked the gksu source code and it execs "su". When I try to EXEC or SHELL it in Gambas however, I get "su: must be run from a terminal" in the Gambas console. Regards, Joe1962 From joe1962 at ...626... Mon Oct 2 22:37:50 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Mon, 2 Oct 2006 16:37:50 -0400 Subject: [Gambas-user] How to authenticate and switch to root user from within gambas application? Message-ID: <6c208f950610021337i482bba6doe7f46ef172c0f336@...627...> Anybody have an idea how to switch to the root user from within a Gambas application? There would be a dialog asking for the password, of course, but how to authenticate and switch to running as root afterwards? From gambas.fr at ...626... Wed Oct 4 08:00:00 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Wed, 4 Oct 2006 08:00:00 +0200 Subject: [Gambas-user] parse out the mount-points of fstab - how? In-Reply-To: <20061003085736.21602.qmail@...1590...> References: <20061003085736.21602.qmail@...1590...> Message-ID: <6324a42a0610032300t76793a86l860bdd9c4ea45c93@...627...> 2006/10/3, Amnon : > > > I need some help here. I wounder how I can parse the fstab to > get all mount-points in a listbox. > > Thats what I have: > > > PUBLIC SUB dvddrives_Click() > DIM devar AS String[] > DIM i AS Integer > DIM procLoad AS String > > > mountpoint = "" > > > ' fstab search > IF mountpoint = "" THEN > IF Exist ("/etc/fstab") = TRUE THEN > listbox1.clear > SHELL "cat /etc/fstab >" & sTemp WAIT > ProcLoad = file.Load (sTemp) > KILL sTemp > listbox1.contents=ProcLoad > FOR i = 0 TO listbox1.count-1 > IF Instr(listbox1[i].Text , drives.text) > 0 THEN > devar=Split(listbox1[i].text, " here, but what one?>") > mountpoint=devar[1] > mountpointlist.add(mountpoint) > END IF > NEXT > END IF > END IF > > IF dvdsource = "" THEN > logtext.Insert("[Debug message] No VIDEODVD found!"& "\n") > ELSE > logtext.Insert("[Debug message] VIDEODVD source: " & > dvdsource & "\n") > END IF > > END > > I don't get the string-value I can use to split. > --------------------------------------------- > Free POP3 Email from www.Gawab.com > Sign up NOW and get your account @gawab.com!! > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > SHELL "cat /etc/fstab >" & sTemp WAIT ProcLoad = file.Load (sTemp) KILL sTemp = ProcLoad = file.Load ("/etc/fstab") no ? From gambas.fr at ...626... Wed Oct 4 08:03:25 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Wed, 4 Oct 2006 08:03:25 +0200 Subject: [Gambas-user] How to authenticate and switch to root user from within gambas application? In-Reply-To: <6c208f950610030921u631d6bf8w4579f1457e4ad67c@...627...> References: <6c208f950610021337i482bba6doe7f46ef172c0f336@...627...> <6c208f950610030921u631d6bf8w4579f1457e4ad67c@...627...> Message-ID: <6324a42a0610032303y51d4f18au9cb672262411229b@...627...> look at the console example ! you can run a virtual shell and then execute something in it ! maybe it can work ! And you need it as the instance for the program need to be the same as the su one ! Fabien 2006/10/3, Jose J. Rodriguez : > > On 10/2/06, Jose J. Rodriguez wrote: > > Anybody have an idea how to switch to the root user from within a > > Gambas application? There would be a dialog asking for the password, > > of course, but how to authenticate and switch to running as root > > afterwards? > > > > I've checked the gksu source code and it execs "su". When I try to > EXEC or SHELL it in Gambas however, I get "su: must be run from a > terminal" in the Gambas console. > > Regards, > Joe1962 > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From joe1962 at ...626... Wed Oct 4 08:15:09 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 02:15:09 -0400 Subject: [Gambas-user] How to authenticate and switch to root user from within gambas application? In-Reply-To: <6324a42a0610032303y51d4f18au9cb672262411229b@...627...> References: <6c208f950610021337i482bba6doe7f46ef172c0f336@...627...> <6c208f950610030921u631d6bf8w4579f1457e4ad67c@...627...> <6324a42a0610032303y51d4f18au9cb672262411229b@...627...> Message-ID: <6c208f950610032315oaa1a8b2m3a1ccffed8d29063@...627...> On 10/4/06, Fabien Bodard wrote: > look at the console example ! > > you can run a virtual shell and then execute something in it ! > > maybe it can work ! And you need it as the instance for the program need to > be the same as the su one ! > > Thanks Fabien. I was starting to think my emails weren't making it to the list, because I keep getting mail delivery errors from gmail. I'll look at the console example. Best thing would be for the app itself to "escalate" priviledge to root if it has the password. There should be some api call to do this in Linux, but I can't find the info. Still, even gksu calls su, lol. Problem is how to make sure the password doesn't show up anywhere.... Regards, Joe1962 From joe1962 at ...626... Wed Oct 4 08:35:33 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 02:35:33 -0400 Subject: [Gambas-user] How to authenticate and switch to root user from within gambas application? In-Reply-To: <6324a42a0610032303y51d4f18au9cb672262411229b@...627...> References: <6c208f950610021337i482bba6doe7f46ef172c0f336@...627...> <6c208f950610030921u631d6bf8w4579f1457e4ad67c@...627...> <6324a42a0610032303y51d4f18au9cb672262411229b@...627...> Message-ID: <6c208f950610032335oabb4448s30c0906c83abb5e5@...627...> On 10/4/06, Fabien Bodard wrote: > look at the console example ! > > you can run a virtual shell and then execute something in it ! > > maybe it can work ! And you need it as the instance for the program need to > be the same as the su one ! > Checked out the console example. I'm afraid running "su" in it gives the same error as SHELL: "su: su must be run from a terminal". Regards, Joe1962 From erwinpogz at ...43... Wed Oct 4 08:39:33 2006 From: erwinpogz at ...43... (Erwin Pogz) Date: Tue, 3 Oct 2006 23:39:33 -0700 (PDT) Subject: [Gambas-user] IRC Server and Channel for Gambas HelpDesk and Discussion Message-ID: <20061004063933.4590.qmail@...1591...> Hello, Is there any IRC Servers and Channels where Gambas people have some Discussion? I think with IRC, we can provide and get a quick help and discuss things about Gambas on real time. Just a suggestion. Regards, Erwin --------------------------------- Do you Yahoo!? Everyone is raving about the all-new Yahoo! Mail. From gambas at ...1... Wed Oct 4 09:04:30 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 4 Oct 2006 09:04:30 +0200 Subject: [Gambas-user] How to authenticate and switch to root user from within gambas application? In-Reply-To: <6c208f950610032335oabb4448s30c0906c83abb5e5@...627...> References: <6c208f950610021337i482bba6doe7f46ef172c0f336@...627...> <6324a42a0610032303y51d4f18au9cb672262411229b@...627...> <6c208f950610032335oabb4448s30c0906c83abb5e5@...627...> Message-ID: <200610040904.30893.gambas@...1...> On Wednesday 04 October 2006 08:35, Jose J. Rodriguez wrote: > On 10/4/06, Fabien Bodard wrote: > > look at the console example ! > > > > you can run a virtual shell and then execute something in it ! > > > > maybe it can work ! And you need it as the instance for the program need > > to be the same as the su one ! > > Checked out the console example. I'm afraid running "su" in it gives > the same error as SHELL: "su: su must be run from a terminal". > > Regards, > Joe1962 > In the development version, you can EXEC or SHELL application in a virtual terminal when they are needed: EXEC [ "su" ] FOR INPUT OUTPUT instead of EXEC [ "su" ] FOR READ WRITE Then 'su' should not complain anymore, and you will be able to send it login and password. The better, and maybe only good solution is to configurate and use the 'sudo' command. Because it is better for security reason to centralize all applications that need to be run as root and to define which users can use them. Regards, -- Benoit Minisini From timothy.marshal-nichols at ...247... Wed Oct 4 09:15:38 2006 From: timothy.marshal-nichols at ...247... (Timothy Marshal-Nichols) Date: Wed, 4 Oct 2006 08:15:38 +0100 Subject: [Gambas-user] How to authenticate and switch to root user fromwithin gambas application? In-Reply-To: <6c208f950610032335oabb4448s30c0906c83abb5e5@...627...> Message-ID: <000001c6e784$ebe9b860$66301b52@...1587...> Hello Not sure how you can switch to being root user when the application is running. But you could test if the current user is root and provide a warning message and also disable option only available to root: ' root user always has an Id of 0 IF User.Id = 0 THEN ' Disable options that can only be run by root Message.Info("Not root user - you would have a better message") END IF In KDE you can create desktop shortcuts and menu items that will run an application as root and prompt for the root password. Thanks 8-) Timothy Marshal-Nichols > -----Original Message----- > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > bounces at lists.sourceforge.net] On Behalf Of Jose J. Rodriguez > Sent: 04 October 2006 07:36 > To: mailing list for gambas users > Subject: Re: [Gambas-user] How to authenticate and switch to root user > fromwithin gambas application? > > On 10/4/06, Fabien Bodard wrote: > > look at the console example ! > > > > you can run a virtual shell and then execute something in it ! > > > > maybe it can work ! And you need it as the instance for the program need > to > > be the same as the su one ! > > > > Checked out the console example. I'm afraid running "su" in it gives > the same error as SHELL: "su: su must be run from a terminal". > > Regards, > Joe1962 > > ------------------------------------------------------------------------ - > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDE V > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From gambas at ...1... Wed Oct 4 09:44:38 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 4 Oct 2006 09:44:38 +0200 Subject: [Gambas-user] Selections in Columnview (and maybe other controls) in Multi mode In-Reply-To: <45220992.9070200@...1000...> References: <45220992.9070200@...1000...> Message-ID: <200610040944.38965.gambas@...1...> On Tuesday 03 October 2006 08:56, Werner wrote: > ISTR that selections in multi mode were made such that the shift and > control keys had an effect; the shift key for selecting a range of > columns and control key for toggling the selection of an individual > column on/off. > > That was about a year ago(1.0.10?). It seems that now (1.9.43) these > modifier keys are ignored. What am I missing? > > Thanks and Best Regards > Werner Dahn > The 1.9.44 is frozen, so that behaviour will return in the 1.9.45. Regards, -- Benoit Minisini From f.demarchi at ...1592... Wed Oct 4 12:02:28 2006 From: f.demarchi at ...1592... (Francesco De Marchi) Date: Wed, 04 Oct 2006 12:02:28 +0200 Subject: [Gambas-user] Maybe 2 errors in Gambas 1.9.43 In-Reply-To: <45226148.7020009@...1237...> References: <45226148.7020009@...1237...> Message-ID: <452386B4.3040100@...1592...> Leonardo Miliani ha scritto: > Hi Benoit, > maybe I've found 2 bugs in Gambas 1.9.43. > Check them for sure.. > > > 1) > Even if I open an existing project or I have create a new one, if I > click on Project/Properties and try to change the program icon, I get > this error: > "This application has raised an unexpected > error and must abort. > [3] Stack overflow. > FSelectIcon.cmbSize_Click.77" > > I can confirm that it didn't exist on older versions because I have a > project that I'm working on that has the icon changed. > > Confirm this error. I have a 1.9.43 version and can not add an icon in my application project kgbmencoder. :( Best Regard Francesco De Marchi From joe1962 at ...626... Wed Oct 4 15:38:07 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 09:38:07 -0400 Subject: [Gambas-user] How to authenticate and switch to root user from within gambas application? In-Reply-To: <200610040904.30893.gambas@...1...> References: <6c208f950610021337i482bba6doe7f46ef172c0f336@...627...> <6324a42a0610032303y51d4f18au9cb672262411229b@...627...> <6c208f950610032335oabb4448s30c0906c83abb5e5@...627...> <200610040904.30893.gambas@...1...> Message-ID: <6c208f950610040638r7b96fbf9tef5bcdfbb32a0f55@...627...> On 10/4/06, Benoit Minisini wrote: > On Wednesday 04 October 2006 08:35, Jose J. Rodriguez wrote: > > On 10/4/06, Fabien Bodard wrote: > > > look at the console example ! > > > > > > you can run a virtual shell and then execute something in it ! > > > > > > maybe it can work ! And you need it as the instance for the program need > > > to be the same as the su one ! > > > > Checked out the console example. I'm afraid running "su" in it gives > > the same error as SHELL: "su: su must be run from a terminal". > > > > Regards, > > Joe1962 > > > > In the development version, you can EXEC or SHELL application in a virtual > terminal when they are needed: > > EXEC [ "su" ] FOR INPUT OUTPUT > > instead of EXEC [ "su" ] FOR READ WRITE > > Then 'su' should not complain anymore, and you will be able to send it login > and password. > I'll give it a try, but I'm trying to stick to 1.0.x for utilities to be included as part of the next Vector Linux release, 1.9.x is still changing to much... ;) > The better, and maybe only good solution is to configurate and use the 'sudo' > command. Because it is better for security reason to centralize all > applications that need to be run as root and to define which users can use > them. > Basically, I'm trying to replace gksu in the menu items of configuration utilities for the upcoming Standard version of Vector Linux, which will be XFCE only. Other options won't work because they need kdelibs (maybe even more) in the case of kdesu, or quite a bit of gnome in all the others, including the new gksu 2.0. It just happens that gksu 1.x does not handle being called as root very well, it simply hangs. This bug would mean separating the root and user menus, something that could be done for the apps inside the iso, but is a lot more trouble for any package to be installed or upgraded from the repository. Regards, Joe1962 From joe1962 at ...626... Wed Oct 4 15:42:46 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 09:42:46 -0400 Subject: [Gambas-user] How to authenticate and switch to root user fromwithin gambas application? In-Reply-To: <000001c6e784$ebe9b860$66301b52@...1587...> References: <6c208f950610032335oabb4448s30c0906c83abb5e5@...627...> <000001c6e784$ebe9b860$66301b52@...1587...> Message-ID: <6c208f950610040642w54c2e246t76edd216e927020e@...627...> On 10/4/06, Timothy Marshal-Nichols wrote: > > Hello > > Not sure how you can switch to being root user when the application is > running. I need to check the source code of "su" I guess, see how it pulls off this bit of magic. > But you could test if the current user is root and provide a > warning message and also disable option only available to root: > > ' root user always has an Id of 0 > IF User.Id = 0 THEN > ' Disable options that can only be run by root > Message.Info("Not root user - you would have a better > message") > END IF > That's mostly what I do, except I check for username "root". Is it safer to check for id = 0 because the name of root can be changed? I never thought of that. > In KDE you can create desktop shortcuts and menu items that will run an > application as root and prompt for the root password. > Unfortunately, that's a KDE-specific .desktop file setting. It doesn't work in XFCE. Regards, Joe1962 From gambas.fr at ...626... Wed Oct 4 18:23:05 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Wed, 4 Oct 2006 18:23:05 +0200 Subject: [Gambas-user] IRC Server and Channel for Gambas HelpDesk and Discussion In-Reply-To: <20061004063933.4590.qmail@...1591...> References: <20061004063933.4590.qmail@...1591...> Message-ID: <6324a42a0610040923n194fdacas37b554776650710a@...627...> on freenodes server on #gambas there is sometime laurent or me :) Lordheavy or gambix But we have not many time me i will be or the air in tow week not before ! fabien 2006/10/4, Erwin Pogz : > > Hello, > > Is there any IRC Servers and Channels where Gambas people have some > Discussion? I think with IRC, we can provide and get a quick help and > discuss things about Gambas on real time. > > Just a suggestion. > > Regards, > > Erwin > > > > > --------------------------------- > Do you Yahoo!? > Everyone is raving about the all-new Yahoo! Mail. > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Wed Oct 4 22:14:39 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 4 Oct 2006 22:14:39 +0200 Subject: [Gambas-user] Release of gambas2 1.9.44 Message-ID: <200610042214.39438.gambas@...1...> Hi, This is the first release generated from the subversion repository. So I hope you won't get too many problems. This is mainly a bug fixes release: * Some optimizations in various places. The main one is that now the interpreter main loop is compiled with -O3 flag, making the interpreter about 5% faster. * The IDE image selector has been fixed. * Editing an image in the IDE works again. * There is a new component too: gb.gtk.svg. Here is the full ChangeLog: ------------------------------------------------------------------------------- DEVELOPMENT ENVIRONMENT * NEW: Adds the 96 pixels size to the IDE select icon dialog box. * NEW: Swedish translation updated. * BUG: Popup balloon is hidden when a debugging session stops. * BUG: You can edit an image again. * BUG: The IDE translation dialog is not displayed if the 'msgmerge' tool is not installed. * BUG: An hidden symbol, in the IDE, is a symbol begining with an underscore, or a symbol with an uderscore inside but that is not a constant. * BUG: Create project dialog saves the settings of its directory chooser. * BUG: Fix automatic completion with constants having underscore, without preventing automatic completion of events from working. * BUG: A void string selected during debugging is not sent to the debugger anymore. EXAMPLES * BUG: ServerSocket example works again. INTERPRETER * NEW: A little optimization in hash table routines. * NEW: The main interpreter loop is now always compiled with -03. This speeds up the interpreter by about 5%. * BUG: The '#' debugger command should work correctly now. GB.DEBUG COMPONENT * BUG: The '#' debugger command should work correctly now. GB.EVAL COMPONENT * BUG: Evaluating a void string does not crash anymore. * BUG: The evaluator does not crash or behave badly anymore when evaluating an expression with a missing operand. GB.QT COMPONENT * NEW: The disabled icon creation routine has been optimized. * NEW: The UserControl and UserContainer now have a '_Container' hidden property that replaces the old 'Container' visible property. * NEW: Old ListBox mode constants were removed. * BUG: GTK+ stock icons were fixed. * BUG: TrayIcon.Width and TrayIcon.Height now return accurate values. * BUG: The IconView default arrangement is 'Row'. * BUG: Fixed a round error in ProgressBar value. * BUG: Control.Parent now always returns NULL when the control is a top-level window. Consequently, Settings.Read() and Settings.Write() now use the correct key. * BUG: Settings ComboBox.Text property when ComboBox is read-only does not raise useless events anymore. GB.FORM COMPONENT * NEW: ColorButton control has returned. It now has a Value property that is a synonymous of the Color property. * NEW: DateChooser has a new Activate event. GB.FORM.MDI COMPONENT * NEW: Workspace tab bar now has the correct height when it opens the first time. GB.DB.FIREBIRD * NEW: A standalone version of ibpp 2.5.2.2 is used now. GB.SDL COMPONENT * Updated. GB.GTK.SVG COMPONENT * New component. ------------------------------------------------------------------------------- You may get two problems: * Help files seems to not fully display correctly. * The gb.db.firebird component was modified to use a embedded newer version of the ibbp library. Tell me if it works, as I can't test. Enjoy it anyway! -- Benoit Minisini From apeters at ...1593... Wed Oct 4 22:43:55 2006 From: apeters at ...1593... (Alexander Peters) Date: Wed, 04 Oct 2006 22:43:55 +0200 Subject: [Gambas-user] how to extend a component? Message-ID: <45241D0B.1050908@...1593...> Hello! I?ve a little question, how can inherit a component like a textfield to add new Features? Is there a way or does i need to do this in the gambas source? Greetings Alex P. From lordheavy at ...512... Wed Oct 4 22:58:19 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Wed, 4 Oct 2006 22:58:19 +0200 Subject: [Gambas-user] how to extend a component? In-Reply-To: <45241D0B.1050908@...1593...> References: <45241D0B.1050908@...1593...> Message-ID: <200610042258.19157.lordheavy@...512...> Le mercredi 4 octobre 2006 22:43, Alexander Peters a ?crit?: > Hello! > I?ve a little question, how can inherit a component like a textfield to > add new Features? > Is there a way or does i need to do this in the gambas source? > > Greetings > Alex P. > First you can take a look in documentation like : http://64.128.110.55/help/lang/inherits and take a look at gb.form component : comp/src/gb.form (you can open it in the IDE) Regards, From joe1962 at ...626... Thu Oct 5 00:16:00 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 18:16:00 -0400 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) Message-ID: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> Seems there really was a problem between Gmail and SourceForge mailing lists: http://it.slashdot.org/article.pl?sid=06/10/04/1324214&from=rss So I gather this post never made it before, repeating the email here: The Help menu wasn't working in 1.9.43 running on XFCE 4.4 RC1. It would work from the console, but not from the XFCE menu. I figured that the run environment from the menu wasn't setting the $BROWSER from my $HOME/.bashrc for some reason, the fix was to create a file (I called it env.sh) in /etc/profile.d (has to be set executable) to set $BROWSER. To Benoit: The setup for the Help browser does not show SeaMonkey, what is needed to get it on the list? Regards, Joe1962 From lordheavy at ...512... Thu Oct 5 00:22:22 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Thu, 5 Oct 2006 00:22:22 +0200 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> Message-ID: <200610050022.22369.lordheavy@...512...> Le jeudi 5 octobre 2006 00:16, Jose J. Rodriguez a ?crit?: > Seems there really was a problem between Gmail and SourceForge mailing > lists: http://it.slashdot.org/article.pl?sid=06/10/04/1324214&from=rss > > So I gather this post never made it before, repeating the email here: > > The Help menu wasn't working in 1.9.43 running on XFCE 4.4 RC1. It > would work from the console, but not from the XFCE menu. I figured > that the run environment from the menu wasn't setting the $BROWSER > from my $HOME/.bashrc for some reason, the fix was to create a file > (I called it env.sh) in /etc/profile.d (has to be set executable) to > set $BROWSER. > > To Benoit: The setup for the Help browser does not show SeaMonkey, > what is needed to get it on the list? > > Regards, > Joe1962 > What is the command line to launch it ? From joe1962 at ...626... Thu Oct 5 00:32:03 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 18:32:03 -0400 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <200610050022.22369.lordheavy@...512...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <200610050022.22369.lordheavy@...512...> Message-ID: <6c208f950610041532g256690a1o41fcf11869240ba7@...627...> On 10/4/06, Laurent Carlier wrote: > Le jeudi 5 octobre 2006 00:16, Jose J. Rodriguez a ?crit: > > Seems there really was a problem between Gmail and SourceForge mailing > > lists: http://it.slashdot.org/article.pl?sid=06/10/04/1324214&from=rss > > > > So I gather this post never made it before, repeating the email here: > > > > The Help menu wasn't working in 1.9.43 running on XFCE 4.4 RC1. It > > would work from the console, but not from the XFCE menu. I figured > > that the run environment from the menu wasn't setting the $BROWSER > > from my $HOME/.bashrc for some reason, the fix was to create a file > > (I called it env.sh) in /etc/profile.d (has to be set executable) to > > set $BROWSER. > > > > To Benoit: The setup for the Help browser does not show SeaMonkey, > > what is needed to get it on the list? > > > > Regards, > > Joe1962 > > > > What is the command line to launch it ? > > seamonkey %u Regards, Joe1962 From lordheavy at ...512... Thu Oct 5 00:47:40 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Thu, 5 Oct 2006 00:47:40 +0200 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <6c208f950610041532g256690a1o41fcf11869240ba7@...627...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <200610050022.22369.lordheavy@...512...> <6c208f950610041532g256690a1o41fcf11869240ba7@...627...> Message-ID: <200610050047.40988.lordheavy@...512...> Le jeudi 5 octobre 2006 00:32, Jose J. Rodriguez a ?crit?: > On 10/4/06, Laurent Carlier wrote: > > Le jeudi 5 octobre 2006 00:16, Jose J. Rodriguez a ?crit: > > > Seems there really was a problem between Gmail and SourceForge mailing > > > lists: http://it.slashdot.org/article.pl?sid=06/10/04/1324214&from=rss > > > > > > So I gather this post never made it before, repeating the email here: > > > > > > The Help menu wasn't working in 1.9.43 running on XFCE 4.4 RC1. It > > > would work from the console, but not from the XFCE menu. I figured > > > that the run environment from the menu wasn't setting the $BROWSER > > > from my $HOME/.bashrc for some reason, the fix was to create a file > > > (I called it env.sh) in /etc/profile.d (has to be set executable) to > > > set $BROWSER. > > > > > > To Benoit: The setup for the Help browser does not show SeaMonkey, > > > what is needed to get it on the list? > > > > > > Regards, > > > Joe1962 > > > > What is the command line to launch it ? > > seamonkey %u > > Regards, > Joe1962 > Thks, will add it in the svn. test with the following files in app/src/gambas2 , if it work, i will commit them. Regards, -------------- next part -------------- A non-text attachment was scrubbed... Name: FOption.class Type: application/x-java Size: 5419 bytes Desc: not available URL: -------------- next part -------------- # Gambas Form File 1.0 { Form Form MoveScaled(0,0,54,47) 'Move(0,0,378,329) Action = "option" Text = ("Preferences") Icon = Picture["icon:/16/options"] Persistent = True Border = Window.Fixed ToolBox = True SkipTaskbar = True { TabStrip1 TabStrip MoveScaled(1,1,52,45) 'Move(7,7,364,315) Arrangement = Arrange.Fill Padding = 8 Count = 4 Index = 0 Text = ("General") { ScrollView1 ScrollView MoveScaled(1,1,49,26) 'Move(7,7,343,182) Border = Border.None ScrollBar = Scroll.Vertical { Label2 Label MoveScaled(0,12,30,3) 'Move(0,84,210,21) Padding = 2 Text = ("Show mascot") } { Label10 Label MoveScaled(0,0,30,3) 'Move(0,0,210,21) Padding = 2 Text = ("Show tooltips") } { cmbTooltip ComboBox MoveScaled(31,0,10,3) 'Move(217,0,70,21) Text = ("") ReadOnly = True List = [("Yes"), ("No")] } { Label11 Label MoveScaled(0,4,30,3) 'Move(0,28,210,21) Padding = 2 Text = ("Font size") } { cmbGlobalFont ComboBox MoveScaled(31,4,17,3) 'Move(217,28,119,21) Text = ("") ReadOnly = True List = [("Normal"), ("Small")] } { cmbMascot ComboBox MoveScaled(31,12,10,3) 'Move(217,84,70,21) Text = ("") ReadOnly = True List = [("Yes"), ("No")] } { Label12 Label MoveScaled(0,16,30,3) 'Move(0,112,210,21) Padding = 2 Text = ("Icon theme") } { cmbIconTheme ComboBox MoveScaled(31,16,17,3) 'Move(217,112,119,21) Text = ("") ReadOnly = True List = [("Desktop"), ("Gnome"), ("KDE")] } { Label13 Label MoveScaled(0,20,30,3) 'Move(0,140,210,21) Padding = 2 Text = ("Browser") } { cmbBrowser ComboBox MoveScaled(31,20,17,3) 'Move(217,140,119,21) Text = ("") ReadOnly = True List = [("(Default)"), ("Konqueror"), ("Epiphany"), ("Firefox"), ("Seamonkey")] } { Label1 Label MoveScaled(0,8,30,3) 'Move(0,56,210,21) Padding = 2 Text = ("Toolbox size") } { cmbToolbox ComboBox MoveScaled(31,8,17,3) 'Move(217,56,119,21) Text = ("") ReadOnly = True List = [("Normal"), ("Small")] } } Index = 1 Text = ("Editor") { Panel14 Panel MoveScaled(1,1,49,29) 'Move(7,7,343,203) { Label40 Label MoveScaled(0,20,30,3) 'Move(0,140,210,21) Padding = 2 Text = ("Default tab size") } { Label3 Label MoveScaled(38,20,10,3) 'Move(266,140,70,21) Text = ("spaces") } { txtTabSize SpinBox MoveScaled(31,20,6,3) 'Move(217,140,42,21) MinValue = 1 MaxValue = 16 Value = 2 } { Label4 Label MoveScaled(0,0,30,3) 'Move(0,0,210,21) Padding = 2 Text = ("Automatic completion") } { cmbCompletion ComboBox MoveScaled(31,0,10,3) 'Move(217,0,70,21) Text = ("") ReadOnly = True List = [("Yes"), ("No")] } { Label5 Label MoveScaled(0,4,30,3) 'Move(0,28,210,21) Padding = 2 Text = ("Procedure separation") } { cmbProcLimit ComboBox MoveScaled(31,4,17,3) 'Move(217,28,119,21) Text = ("") ReadOnly = True List = [("None"), ("Line"), ("Blend")] } { Label6 Label MoveScaled(0,8,30,3) 'Move(0,56,210,21) Padding = 2 Text = ("Highlight current line") } { cmbShowCurrent ComboBox MoveScaled(31,8,10,3) 'Move(217,56,70,21) Text = ("") ReadOnly = True List = [("Yes"), ("No")] } { Label7 Label MoveScaled(0,12,30,3) 'Move(0,84,210,21) Padding = 2 Text = ("Highlight modified lines") } { cmbShowChange ComboBox MoveScaled(31,12,10,3) 'Move(217,84,70,21) Text = ("") ReadOnly = True List = [("Yes"), ("No")] } { Label8 Label MoveScaled(0,16,30,3) 'Move(0,112,210,21) Padding = 2 Text = ("Show line numbers") } { cmbLineNumber ComboBox MoveScaled(31,16,10,3) 'Move(217,112,70,21) Text = ("") ReadOnly = True List = [("Yes"), ("No")] } } Index = 2 Text = ("Font") { fntEditor FontChooser MoveScaled(2,2,47,35) 'Move(14,14,329,245) FixedOnly = True ShowStyle = False } Index = 3 Text = ("Colors") { VBox1 VBox MoveScaled(1,1,49,39) 'Move(7,7,343,273) Spacing = 8 { HBox1 HBox MoveScaled(0,0,48,3) 'Move(0,0,336,21) { cmbTheme ComboBox MoveScaled(0,0,29,3) 'Move(0,0,203,21) Expand = True Text = ("") ReadOnly = True } { Panel1 Panel MoveScaled(32,0,1,3) 'Move(224,0,7,21) } { btnImport ToolButton MoveScaled(37,0,3,3) 'Move(259,0,21,21) ToolTip = ("Import theme") Text = ("") Picture = Picture["icon:/16/open"] } { btnExport ToolButton MoveScaled(40,0,3,3) 'Move(280,0,21,21) ToolTip = ("Export theme") Text = ("") Picture = Picture["icon:/16/save"] } { btnUndo ToolButton MoveScaled(43,0,3,3) 'Move(301,0,21,21) ToolTip = ("Undo") Text = ("") Picture = Picture["icon:/16/undo"] } } { Panel4 Panel MoveScaled(1,4,46,35) 'Move(7,28,322,245) Background = Color.TextBackground Expand = True Arrangement = Arrange.Horizontal Padding = 8 Border = Border.Sunken { Panel3 Panel MoveScaled(1,1,17,33) 'Move(7,7,119,231) Expand = True Arrangement = Arrange.Vertical Spacing = 8 { Label26 Label MoveScaled(0,0,17,3) 'Move(0,0,119,21) Expand = True Padding = 2 Text = ("Background") } { Label31 Label MoveScaled(0,4,17,3) 'Move(0,28,119,21) Expand = True Padding = 2 Text = ("Normal text") } { Label33 Label MoveScaled(0,8,17,3) 'Move(0,56,119,21) Expand = True Padding = 2 Text = ("Selection") } { Label58 Label MoveScaled(0,12,17,3) 'Move(0,84,119,21) Expand = True Padding = 2 Text = ("Highlighting") } { Label35 Label MoveScaled(0,16,17,3) 'Move(0,112,119,21) Expand = True Padding = 2 Text = ("Keywords") } { Label37 Label MoveScaled(0,20,17,3) 'Move(0,140,119,21) Expand = True Padding = 2 Text = ("Data types") } { Label39 Label MoveScaled(0,24,17,3) 'Move(0,168,119,21) Expand = True Padding = 2 Text = ("Subroutines") } { Label41 Label MoveScaled(0,28,17,3) 'Move(0,196,119,21) Expand = True Padding = 2 Text = ("Operators") } } { panColor1 Panel MoveScaled(16,1,5,33) 'Move(112,7,35,231) Arrangement = Arrange.Vertical Spacing = 8 { Panel2 Panel btnColor MoveScaled(0,0,5,3) 'Move(0,0,35,21) Tag = "Background" Expand = True Border = Border.Raised } { Panel5 Panel btnColor MoveScaled(0,4,5,3) 'Move(0,28,35,21) Tag = "Normal" Expand = True Border = Border.Raised } { Panel6 Panel btnColor MoveScaled(0,8,5,3) 'Move(0,56,35,21) Tag = "Selection" Expand = True Border = Border.Raised } { Panel7 Panel btnColor MoveScaled(0,12,5,3) 'Move(0,84,35,21) Tag = "Highlight" Expand = True Border = Border.Raised } { Panel8 Panel btnColor MoveScaled(0,16,5,3) 'Move(0,112,35,21) Tag = "Keyword" Expand = True Border = Border.Raised } { Panel9 Panel btnColor MoveScaled(0,20,5,3) 'Move(0,140,35,21) Tag = "Datatype" Expand = True Border = Border.Raised } { Panel10 Panel btnColor MoveScaled(0,24,5,3) 'Move(0,168,35,21) Tag = "Subr" Expand = True Border = Border.Raised } { Panel11 Panel btnColor MoveScaled(0,28,5,3) 'Move(0,196,35,21) Tag = "Operator" Expand = True Border = Border.Raised } } { Panel12 Panel MoveScaled(21,12,3,2) 'Move(147,84,21,14) } { Panel13 Panel MoveScaled(24,1,16,33) 'Move(168,7,112,231) Expand = True Arrangement = Arrange.Vertical Spacing = 8 { Label19 Label MoveScaled(0,0,17,3) 'Move(0,0,119,21) Expand = True Padding = 2 Text = ("Symbols") } { Label20 Label MoveScaled(0,4,17,3) 'Move(0,28,119,21) Expand = True Padding = 2 Text = ("Numbers") } { Label21 Label MoveScaled(0,8,17,3) 'Move(0,56,119,21) Expand = True Padding = 2 Text = ("Strings") } { Label22 Label MoveScaled(0,12,17,3) 'Move(0,84,119,21) Expand = True Padding = 2 Text = ("Comments") } { Label23 Label MoveScaled(0,16,17,3) 'Move(0,112,119,21) Expand = True Padding = 2 Text = ("Breakpoints") } { Label24 Label MoveScaled(0,20,17,3) 'Move(0,140,119,21) Expand = True Padding = 2 Text = ("Current line") } { Label27 Label MoveScaled(0,24,17,3) 'Move(0,168,119,21) Expand = True Padding = 2 Text = ("Editing line") } { Label28 Label MoveScaled(0,28,17,3) 'Move(0,196,119,21) Expand = True Padding = 2 Text = ("Error") } } { panColor2 Panel MoveScaled(40,1,5,33) 'Move(280,7,35,231) Arrangement = Arrange.Vertical Spacing = 8 { Panel25 Panel btnColor MoveScaled(0,0,5,3) 'Move(0,0,35,21) Tag = "Symbol" Expand = True Border = Border.Raised } { Panel26 Panel btnColor MoveScaled(0,4,5,3) 'Move(0,28,35,21) Tag = "Number" Expand = True Border = Border.Raised } { Panel27 Panel btnColor MoveScaled(0,8,5,3) 'Move(0,56,35,21) Tag = "String" Expand = True Border = Border.Raised } { Panel28 Panel btnColor MoveScaled(0,12,5,3) 'Move(0,84,35,21) Tag = "Comment" Expand = True Border = Border.Raised } { Panel29 Panel btnColor MoveScaled(0,16,5,3) 'Move(0,112,35,21) Tag = "Breakpoint" Expand = True Border = Border.Raised } { Panel30 Panel btnColor MoveScaled(0,20,5,3) 'Move(0,140,35,21) Tag = "Current" Expand = True Border = Border.Raised } { Panel31 Panel btnColor MoveScaled(0,24,5,3) 'Move(0,168,35,21) Tag = "Line" Expand = True Border = Border.Raised } { Panel32 Panel btnColor MoveScaled(0,28,5,3) 'Move(0,196,35,21) Tag = "Error" Expand = True Border = Border.Raised } } } } Index = 0 } } -------------- next part -------------- ' Gambas module file PUBLIC ProjectTree AS ColumnView PUBLIC ProjectMessage AS Label PUBLIC Workspace AS Workspace PUBLIC ActiveForm AS Object PUBLIC Path AS String PUBLIC Name AS String PUBLIC Dir AS String PUBLIC ReadOnly AS Boolean PUBLIC Title AS String PUBLIC Startup AS String PUBLIC Libraries AS String[] PUBLIC Arguments AS String[] PUBLIC CurrentArgument AS Integer PUBLIC KeepDebugInfo AS Boolean PUBLIC CreateShortcut AS Boolean PUBLIC ControlPublic AS Boolean PUBLIC MajorVersion AS Integer PUBLIC MinorVersion AS Integer PUBLIC ReleaseVersion AS Integer 'PUBLIC SnapToGrid AS Boolean 'PUBLIC ShowGrid AS Boolean PUBLIC Snap AS Integer PUBLIC Localize AS Boolean PUBLIC Description AS String PUBLIC Icon AS String PUBLIC Systems AS String[] PUBLIC Menus AS Collection PUBLIC Groups AS Collection PUBLIC Prefix AS Boolean PUBLIC TabSize AS Integer PUBLIC Version AS String PUBLIC ExecPath AS String PUBLIC Language AS String PUBLIC CreateComponent AS Boolean PUBLIC Stack AS Integer PUBLIC Authors AS String PUBLIC VersionProgram AS String PUBLIC Running AS Boolean PUBLIC Recent AS NEW String[] PRIVATE CONST MAX_RECENT AS Integer = 32 PUBLIC CONST FORM_MAGIC AS String = "# Gambas Form File 1.0" PUBLIC CONST PROJECT_MAGIC AS String = "# Gambas Project File 1.0" PUBLIC CONST DEFAULT_FONT AS String = "Monospace,10" PUBLIC Files AS NEW Collection PUBLIC AboutToQuit AS Boolean PUBLIC Positions AS NEW String[] PUBLIC CONST MAX_ICON_SIZE AS Integer = 8192 PUBLIC EXAMPLES_DIR AS String PUBLIC RPMBUILD_PROG AS String PUBLIC ShowAlwaysProperty AS Boolean PRIVATE CONST IMAGE_DIR AS String = "img/16" PRIVATE CONST KEY_MODULE AS String = "$M" PRIVATE CONST KEY_CLASS AS String = "$C" PUBLIC CONST KEY_FORM AS String = "$F" PUBLIC CONST KEY_MISC AS String = "$O" PUBLIC CONST KEY_FIND AS String = "$@" PRIVATE CONST CLASS_AUTH_CAR AS String = "abcdefghijklmnopqrstuvwxyz0123456789" PRIVATE CONST FILE_AUTH_CAR AS String = "abcdefghijklmnopqrstuvwxyz0123456789-.+_" PRIVATE CONST PROJECT_FILE AS String = ".project" 'PRIVATE $bGetSource AS Boolean 'PRIVATE $bDisplayForm AS Boolean PRIVATE TMP_FILE AS String '= "/tmp/.gambas.ver" PRIVATE OUTPUT_FILE AS String '= "/tmp/.gambas.out" PUBLIC Browser AS String PRIVATE $iFound AS Integer PRIVATE $bDoNotSavePosition AS Boolean PRIVATE $sOldRefreshLibrary AS String PUBLIC ExampleTitle AS NEW Collection PUBLIC ComponentFromType AS NEW Collection PUBLIC FormType AS NEW Collection PUBLIC TimeStamp AS Integer PRIVATE $aRefreshAfter AS NEW String[] PRIVATE $bNoRefresh AS Boolean PUBLIC SUB _init() ExampleTitle["Automation"] = ("Automation") ExampleTitle["Basic"] = ("Basic") ExampleTitle["Database"] = ("Database") ExampleTitle["Drawing"] = ("Drawing") ExampleTitle["Games"] = ("Games") ExampleTitle["Misc"] = ("Miscellaneous") ExampleTitle["Networking"] = ("Networking") ExampleTitle["OpenGL"] = ("OpenGL") ExampleTitle["Printing"] = ("Printing") ExampleTitle["Sound"] = ("Sound") ExampleTitle["Video"] = ("Video") END PUBLIC SUB Main() DIM sPath AS String DIM hGambas AS FGambas DIM iTest AS Integer Application.Theme = Settings["/Theme"] TMP_FILE = Temp$() OUTPUT_FILE = Temp$() 'CLASSES_FILE = Temp$() EXAMPLES_DIR = System.Path &/ "share/gambas" & System.Version & "/examples" 'Config = NEW Config '(User.Home &/ ".gambas") Application.Tooltip.Enabled = Settings["/ShowTooltip", TRUE] 'Application.Font = Font["10"] InitVersion LoadRecent FMain.Load FGambas.Load IF Application.Args.Count >= 2 THEN sPath = Application.Args[1] ENDIF DO IF NOT sPath THEN sPath = FWelcome.Run() 'sPath = User.Home &/ "gambas/test/gambas" IF sPath THEN Project.Open(sPath) ELSE FMain.Close RETURN ENDIF IF Project.Name THEN BREAK sPath = "" LOOP INC Application.Busy 'FProperty.Show 'FToolBox.Show 'FFormStack.Load IF Settings["/ShowMascot", TRUE] THEN FGambas.Show FMain.UpdateRecentMenu FMain.Show DEC Application.Busy IF Settings["/ShowTipOnStartup", TRUE] THEN FTips.Run ENDIF Project.Activate(NULL) END PRIVATE SUB InitVersion() DIM sVer AS String Version = "?" 'SHELL "gbx" & System.Version & " -V > " & TMP_FILE 'WAIT 'sVer = File.Load(TMP_FILE) 'KILL TMP_FILE SHELL "gbx" & System.Version & " -V" TO sVer Version = Trim(Mid$(sVer, InStr(sVer, "-") + 1)) END PUBLIC FUNCTION Open(sDir AS String) AS Boolean DIM sOldPath AS String DIM sOldName AS String IF NOT Exist(sDir &/ ".project") THEN FGambas.Error(("This project does not exist.") & "\n\n" & sDir) RETURN TRUE ENDIF sOldPath = Project.Path sOldName = Project.Name IF CloseProject() THEN RETURN TRUE IF Exist(sDir &/ ".lock") THEN IF Message.Warning(("This project seems to be already opened.\n\nOpening the same project twice can lead to data loss."), ("Open after all"), ("Do not open")) = 2 THEN RETURN TRUE ENDIF TRY KILL sDir &/ ".lock" ENDIF ReadOnly = NOT Access(sDir, gb.write) Path = sDir &/ PROJECT_FILE Name = File.Name(sDir) Project.Dir = sDir $bNoRefresh = TRUE ReadProject $bNoRefresh = FALSE Project.TimeStamp = 1 Refresh AddRecent(sDir) Positions.Clear FMain.OnProjectChange FFind.Hide 'FFind.OnProjectChange 'FExplorer.ProjectChange Design.Clear TRY File.Save(sDir &/ ".lock", "") IF ReadOnly THEN FGambas.Warning(("This project is read-only.")) SetMessage(("OK")) RETURN CATCH IF Error.Text THEN FGambas.Error(("Cannot open project file :\n") & sDir & "\n\n" & Error.Text & "\n" & Error.Where) ENDIF Path = sOldPath Project.Dir = File.Dir(Path) Name = sOldName IF Path THEN ReadProject RETURN TRUE END PUBLIC SUB CloseAll() DIM hForm AS Object FOR EACH hForm IN Files hForm.Close NEXT END PRIVATE FUNCTION CloseProject() AS Boolean DIM hForm AS Object DIM bModif AS Boolean 'IF Len(Path) = 0 THEN RETURN IF Running THEN Design.Stop 'WAIT 0.5 ENDIF FOR EACH hForm IN Files IF hForm.IsModified() THEN bModif = TRUE BREAK ENDIF NEXT IF bModif THEN IF FSave.Run(AboutToQuit) THEN RETURN TRUE ENDIF 'FFind.Close INC Application.Busy FOR EACH hForm IN Files hForm.Delete NEXT Files.Clear ActiveForm = NULL DEC Application.Busy IF NOT AboutToQuit THEN FProperty.HideAll FFormStack.HideAll ENDIF TRY KILL Project.Dir &/ ".lock" RETURN FALSE END PUBLIC FUNCTION Close() AS Boolean DIM hForm AS Form DIM iInd AS Integer DIM sLig AS String AboutToQuit = TRUE IF CloseProject() THEN AboutToQuit = FALSE RETURN TRUE ENDIF 'Design.Close 'FOR EACH hForm IN Windows ' TRY hForm.Close 'NEXT 'FOR EACH hForm IN Windows ' TRY hForm.Delete 'NEXT ' FToolBox.Delete ' FExplorer.Delete ' FFind.Delete ' FGambas.Delete ' FIconTool.Delete ' Design.Delete ' FProperty.Delete CComponent.Exit END PUBLIC SUB GetFileIcon(sPath AS String, OPTIONAL iSize AS Integer) AS Picture DIM hImage AS Image DIM hPict AS Picture DIM hStartup AS Picture DIM sKey AS String DIM bLink AS Boolean DIM sIcon AS String DIM sExt AS String DIM bStartup AS Boolean DIM iFileSize AS Long DIM hFile AS File DIM sPrefix AS String DIM bNoStartup AS Boolean DIM iDim AS Integer IF iSize THEN sPrefix = "icon:/" & iSize bNoStartup = iSize <> 16 ELSE sPrefix = "icon:/16" ENDIF WITH Stat(sPath) bLink = .Type = gb.Link IF .Type = gb.Directory THEN sIcon = sPrefix &/ "directory" IF NOT sIcon THEN sIcon = sPrefix &/ "file" sExt = File.Ext(sPath) SELECT CASE sExt CASE "form", "class", "module" IF File.Dir(sPath) = Project.Dir THEN IF iSize > 16 THEN sIcon = "img/32" &/ sExt & ".png" ELSE sIcon = "img/16" &/ sExt & ".png" ENDIF bStartup = File.BaseName(sPath) = Startup AND NOT bNoStartup ENDIF CASE "jpg", "jpeg", "xpm", "bmp", "png", "gif" IF bLink THEN hFile = OPEN sPath iFileSize = Lof(hFile) CLOSE hFile ELSE iFileSize = .Size ENDIF IF iFileSize > MAX_ICON_SIZE THEN sIcon = sPrefix &/ "image" ELSE sIcon = sPath ENDIF CASE "svg" sIcon = sPrefix &/ "image" CASE "htm", "html" sIcon = sPrefix &/ "html" CASE "txt", "text" sIcon = sPrefix &/ "text" END SELECT ENDIF END WITH IF Left$(sIcon) = "/" THEN TRY hImage = Image.Load(sIcon) IF hImage THEN IF iSize THEN hImage = hImage.Stretch(hImage.Width * iSize / hImage.Height, iSize, TRUE) ELSE iSize = 32 IF hImage.Height > iSize THEN hImage = hImage.Stretch(hImage.Width * iSize / hImage.Height, iSize, TRUE) ENDIF IF hImage.Width > iSize THEN hImage = hImage.Stretch(iSize, hImage.Height * iSize / hImage.Width, TRUE) ENDIF ENDIF hPict = hImage.Picture ELSE hPict = Picture[sPrefix &/ "image"].Copy() ENDIF IF bLink THEN Draw.Begin(hPict) Draw.Picture(Picture["img/16/link.png"], 0, hPict.Height - 16) Draw.End ENDIF ELSE sKey = sIcon IF bLink THEN sKey = File.BaseName(sKey) & "-link" IF bStartup THEN sKey = File.BaseName(sKey) & "-startup" hPict = NULL IF NOT bNoStartup THEN hPict = Picture[sKey] IF NOT hPict THEN hPict = Picture[sIcon].Copy() IF bStartup THEN hStartup = NEW Picture(hPict.Width + 8, hPict.Height, TRUE) 'hStartup.Fill(Color.TextBackground) Draw.Begin(hStartup) Draw.Picture(hPict, 8, 0) Draw.Image(Image.Load("img/16/startup.png"), 0, 0) Draw.End 'hImage = hStartup.Image 'hImage.Replace(Color.TextBackground, Color.Transparent) hPict = hStartup ENDIF IF iSize THEN hPict = hPict.Image.Stretch(hPict.Width * iSize / hPict.Height, iSize, TRUE).Picture ENDIF IF bLink THEN Draw.Begin(hPict) Draw.Picture(Picture["img/16/link.png"], 0, hPict.Height - 16) Draw.End ENDIF IF NOT bNoStartup THEN Picture[sKey] = hPict ENDIF ENDIF RETURN hPict END PRIVATE SUB GetParentClass(sPath AS String) AS String DIM hFile AS File DIM sLine AS String hFile = OPEN sPath WHILE NOT Eof(hFile) LINE INPUT #hFile, sLine sLine = Trim(sLine) IF NOT sLine THEN CONTINUE IF Left(sLine) = "'" THEN CONTINUE IF sLine LIKE "INHERITS *" THEN 'Highlight.Analyze(sLine) 'RETURN Highlight.Symbols[1] sLine = Scan(sLine, "INHERITS *")[0] IF Comp(sLine, File.BaseName(sPath), gb.Text) = 0 THEN sLine = "" RETURN sLine ENDIF IF sLine LIKE "CREATE" THEN CONTINUE IF sLine LIKE "EXPORT" THEN CONTINUE BREAK WEND END PRIVATE SUB AddFile(sDir AS String, sFile AS String, OPTIONAL bAfter AS String, OPTIONAL bIgnoreInheritance AS Boolean) AS Boolean DIM bAllowForm AS Boolean DIM bIgnore AS Boolean DIM sPath AS String DIM sKey AS String DIM bShow AS Boolean DIM sExt AS String DIM sParent AS String DIM hImage AS Image DIM hPict AS Picture DIM bChecked AS Boolean DIM bDir AS Boolean DIM sAfter AS String DIM hForm AS Object bAllowForm = AllowForm() sPath = sDir &/ sFile sKey = sPath sParent = sDir IF sDir = Project.Dir THEN sParent = KEY_MISC ENDIF WITH Stat(sPath) IF .Hidden THEN RETURN bShow = FALSE IF .Type = gb.Directory THEN IF sFile = "CVS" THEN RETURN 'IF cDir THEN cDir.Add(sPath) bDir = TRUE 'sIcon = "icon:/16/directory" 'IMAGE_DIR &/ "close.png" bShow = TRUE ELSE 'IF InStr(.Perm.User & .Perm.Group & .Perm.Other, "x") THEN CONTINUE sExt = Lower(File.Ext(sFile)) bChecked = FALSE IF sDir = Project.Dir THEN SELECT CASE sExt CASE "form", "class", "module" 'sIcon = IMAGE_DIR &/ sExt & ".png" bShow = TRUE bChecked = TRUE IF sExt = "form" THEN sParent = KEY_FORM IF NOT bAllowForm THEN bIgnore = TRUE ELSE IF sExt = "class" THEN sParent = "" IF Exist(sDir &/ File.BaseName(sFile) & ".form") THEN bIgnore = TRUE ELSE 'IF sFile = "ReportContainer.class" THEN STOP sParent = FindKey(GetParentClass(sPath)) IF sParent THEN IF File.Ext(sParent) <> "class" THEN sParent = "" ELSE IF NOT ProjectTree.Exist(sParent) THEN IF NOT bIgnoreInheritance THEN $aRefreshAfter.Add(sPath) bIgnore = TRUE ELSE sParent = "" ENDIF ENDIF ENDIF ENDIF IF NOT sParent THEN sParent = KEY_CLASS ELSE IF sExt = "module" THEN sParent = KEY_MODULE ENDIF sFile = File.BaseName(sFile) END SELECT ENDIF IF NOT bChecked THEN bIgnore = sExt = "gambas" OR Right$(sFile) = "~" ENDIF ENDIF IF NOT bIgnore THEN hPict = GetFileIcon(sPath) IF bAfter THEN WITH ProjectTree .MoveTo(sParent) .MoveChild IF NOT bDir THEN WHILE .Available IF NOT IsDir(.Item.Key) THEN BREAK sAfter = .Item.Key .MoveNext WEND ENDIF WHILE .Available IF Comp(.Item.Text, sFile, gb.Text) > 0 THEN BREAK IF bDir AND IF NOT IsDir(.Item.Key) THEN BREAK sAfter = .Item.Key .MoveNext WEND END WITH ENDIF WITH ProjectTree.Add(sKey, sFile, hPict, sParent) .Editable = TRUE IF bAfter THEN .MoveAfter(sAfter) IF bShow THEN ProjectTree.MoveTo(sKey) ProjectTree.MoveParent ProjectTree.Item.Expanded = TRUE ENDIF END WITH hForm = Files[sKey] IF hForm THEN hForm.Icon = GetFileIcon(sKey, 16) IF sParent = KEY_FORM THEN hForm = Files[File.SetExt(sKey, "class")] IF hForm THEN hForm.Icon = GetFileIcon(sKey, 16) ENDIF ENDIF END WITH RETURN bDir END PRIVATE SUB DoRefreshAfter() DIM sKey AS String DIM iInd AS Integer DIM iCount AS Integer IF $aRefreshAfter.Count = 0 THEN RETURN DO iCount = $aRefreshAfter.Count FOR iInd = 0 TO iCount - 1 sKey = $aRefreshAfter[0] $aRefreshAfter.Remove(0) AddFile(File.Dir(sKey), File.Name(sKey), TRUE) NEXT IF $aRefreshAfter.Count >= iCount THEN BREAK LOOP IF $aRefreshAfter.Count THEN FOR iInd = 0 TO $aRefreshAfter.Max sKey = $aRefreshAfter[iInd] AddFile(File.Dir(sKey), File.Name(sKey), TRUE, TRUE) $aRefreshAfter[iInd] = File.BaseName(sKey) NEXT FGambas.Error(("The following classes have circular inheritance:") & "\n\n" & $aRefreshAfter.Join(", ")) $aRefreshAfter.Clear ENDIF END PRIVATE PROCEDURE AddDir(OPTIONAL sDir AS String) DIM cDir AS NEW String[] DIM sFile AS String DIM aFile AS NEW String[] IF sDir THEN cDir.Add(sDir) ELSE cDir.Add(Project.Dir) ENDIF REPEAT sDir = cDir[0] aFile.Clear '$bGetSource = FALSE FOR EACH sFile IN Dir(sDir, "*") IF IsDir(sDir &/ sFile) THEN aFile.Add("D" & sFile) NEXT FOR EACH sFile IN Dir(sDir, "*") IF NOT IsDir(sDir &/ sFile) THEN aFile.Add("F" & sFile) NEXT aFile.Sort $aRefreshAfter.Clear FOR EACH sFile IN aFile sFile = Mid$(sFile, 2) IF AddFile(sDir, sFile) THEN cDir.Add(sDir &/ sFile) NEXT DoRefreshAfter cDir.Remove(0) UNTIL cDir.Count = 0 END PUBLIC SUB SelectKey(sKey AS String) IF NOT ProjectTree.Exist(sKey) THEN IF Right$(sKey, 6) = ".class" THEN sKey = Left$(sKey, -6) & ".form" ENDIF ENDIF TRY ProjectTree[sKey].Selected = TRUE TRY ProjectTree[sKey].EnsureVisible END ' PRIVATE SUB UpdateInheritance() ' ' DIM sPath AS String ' DIM sParent AS String ' ' FOR EACH sPath IN Dir(Project.Dir, "*.class") ' ' IF Exist(Project.Dir &/ File.SetExt(sPath, "form")) THEN CONTINUE ' ' sParent = GetParentClass(sPath) ' IF sParent THEN ' sParent = FindKey(sParent) ' IF File.Ext(sParent) <> "class" THEN sParent = "" ' ENDIF ' ENDIF ' IF NOT sParent THEN ' sParent = KEY_CLASS ' ENDIF ' ' NEXT ' ' END PUBLIC PROCEDURE Refresh(OPTIONAL bReset AS Boolean) DIM sFile AS String DIM sDir AS String DIM sKey AS String DIM sKeyReset AS String '$bDisplayForm = Settings["/DisplayForm"] IF $bNoRefresh THEN RETURN IF NOT bReset THEN sKeyReset = ProjectTree.Key ENDIF WITH ProjectTree .Clear() sKey = Project.Dir .Add(sKey, Name, Picture["img/32/../16/gambas.png"]).Expanded = TRUE .Add(KEY_MODULE, ("Modules"), Picture["icon:/16/directory"], sKey) .Add(KEY_CLASS, ("Classes"), Picture["icon:/16/directory"], sKey) IF AllowForm() THEN .Add(KEY_FORM, ("Forms"), Picture["icon:/16/directory"], sKey) ENDIF .Add(KEY_MISC, ("Data"), Picture["icon:/16/directory"], sKey) '$bGetSource = TRUE AddDir() END WITH IF sKeyReset THEN sKey = sKeyReset TRY ProjectTree[sKey].EnsureVisible DefineStartup(Startup, TRUE) WITH ProjectTree .MoveFirst WHILE .Available .Current.Expanded = .Current.Children > 0 .MoveNext WEND END WITH 'STOP FMain.Title = Name & If(ReadOnly, " [" & ("Read only") & "]", "") & " - " & Application.Title END PUBLIC FUNCTION IsEditor(hFile AS Object) AS Boolean RETURN Object.Type(hFile) = "FEditor" END PUBLIC FUNCTION IsForm(hFile AS Object) AS Boolean IF hFile THEN RETURN Object.Type(hFile) = "FForm" END PUBLIC FUNCTION LoadFile(sPath AS String) AS Object DIM hForm AS Object 'DIM hActive AS Object INC Application.Busy hForm = Files[sPath] IF NOT hForm THEN 'PRINT "Load: "; sPath 'hActive = ActiveForm IF File.Dir(sPath) = Project.Dir THEN SELECT CASE File.Ext(sPath) CASE "module", "class" hForm = NEW FEditor(sPath) CASE "form" IF AllowForm() THEN hForm = NEW FForm(sPath) ENDIF END SELECT ENDIF IF NOT hForm THEN SELECT CASE Lower(File.Ext(sPath)) CASE "png", "gif", "jpg", "jpeg", "bmp", "xpm" hForm = NEW FIconEditor(sPath) CASE ELSE hForm = NEW FTextEditor(sPath) END SELECT ENDIF Files[sPath] = hForm hForm.Icon = GetFileIcon(sPath, 16) ENDIF DEC Application.Busy RETURN hForm CATCH DEC Application.Busy FGambas.Error(("Cannot open file.") & "\n\n" & Error.Text & "\n" & Error.Where) END PUBLIC FUNCTION FindPath(sClass AS String) AS String DIM sPath AS String DIM aDir AS String[] DIM iInd AS Integer aDir = Dir(Project.Dir) iInd = aDir.Find(sClass & ".class", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] iInd = aDir.Find(sClass & ".module", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] 'PRINT "FindPath: "; sClass; " ?" END PRIVATE SUB FindKey(sClass AS String) AS String DIM sPath AS String DIM aDir AS String[] DIM iInd AS Integer IF NOT sClass THEN RETURN aDir = Dir(Project.Dir) iInd = aDir.Find(sClass & ".form", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] iInd = aDir.Find(sClass & ".class", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] iInd = aDir.Find(sClass & ".module", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] END PUBLIC SUB ShowFile(hForm AS Form) SELECT CASE Object.Type(hForm) CASE "FEditor", "FTextEditor", "FIconEditor", "FForm" Workspace.Add(hForm) Workspace.ActiveWindow = hForm hForm.SetFocus ' CASE "FForm" ' Workspace.Add(hForm, TRUE) ' Workspace.SetResizable(hForm, TRUE, Project.Snap) ' Workspace.ActiveWindow = hForm END SELECT END PUBLIC SUB OpenFile(sPath AS String, OPTIONAL iLine AS Integer) DIM hForm AS Object IF InStr(sPath, "/") = 0 THEN sPath = FindPath(sPath) IF NOT Exist(sPath) THEN FGambas.Warning("File not found!") Project.Refresh RETURN ENDIF 'IF File.Ext(sPath) = "form" THEN ' FProperty.Show ' FToolBox.Show 'ENDIF LoadFile(sPath) hForm = Files[sPath] IF NOT hForm THEN RETURN ShowFile(hForm) 'hForm.Show 'IF Object.Type(hForm) = "FEditor" THEN ' hForm.Editor.SetFocus 'ENDIF IF iLine THEN hForm.GotoCenter(iLine - 1, 0) ENDIF END PUBLIC FUNCTION ExistForm(sClass AS String) AS Boolean RETURN Dir(Project.Dir, "*.form").Find(sClass & ".form", gb.Text) >= 0 END PUBLIC SUB FindForm(sClass AS String) AS FForm DIM sPath AS String sPath = Project.Dir &/ sClass & ".form" IF Exist(sPath) THEN RETURN LoadFile(sPath) END PUBLIC SUB OpenForm(sName AS String) DIM sPath AS String sPath = Project.Dir &/ sName & ".form" IF Exist(sPath) THEN OpenFile(sPath) END PRIVATE FUNCTION AddMessage(sVoid AS String) AS String DIM hFic AS File DIM sLig AS String IF Stat(OUTPUT_FILE).Size = 0 THEN SetMessage(sVoid) RETURN ELSE OPEN OUTPUT_FILE FOR READ AS #hFic WHILE NOT Eof(hFic) LINE INPUT #hFic, sLig 'ProjectMessage.Add(sLig) WEND CLOSE #hFic ENDIF 'ProjectMessage.Index = ProjectMessage.Count - 1 'SetMessage(sLig) RETURN sLig END PRIVATE SUB CompileError(sMsg AS String) DIM iPos AS Integer DIM sFile AS String DIM iLine AS Integer iPos = InStr(sMsg, ":") 'if iPos = 0 then return sFile = Left$(sMsg, iPos - 1) sMsg = Mid$(sMsg, iPos + 1) iPos = InStr(sMsg, ":") 'if iPos = 0 then return iLine = Val(Left$(sMsg, iPos - 1)) 'if iLine = 0 then return sFile = File.Dir(Path) &/ File.Name(sFile) SetMessage(File.BaseName(sFile) & "." & CStr(iLine) & ": " & Trim(Mid$(sMsg, iPos + 1))) OpenFile(sFile, iLine) sMsg = Trim(Mid$(sMsg, iPos + 1)) & "\n" & Subst(("at line &1 in &2"), CStr(iLine), File.Name(sFile)) IF FGambas.Visible THEN FGambas.Animate("Depressive", sMsg) ELSE Message.Warning(sMsg) ENDIF OpenFile(sFile, iLine) CATCH END PUBLIC FUNCTION Quote(sPath AS String) AS String DIM sQuote AS String DIM iInd AS Integer DIM sCar AS String sPath = SConv$(sPath) 'DEBUG sPath FOR iInd = 1 TO Len(sPath) sCar = Mid$(sPath, iInd, 1) IF InStr("0123456789abcdefghijklmnopqrstuvwxyz.-/_~", LCase(sCar)) = 0 THEN sCar = "\\" & sCar ENDIF sQuote = sQuote & sCar NEXT RETURN sQuote END PUBLIC FUNCTION Escape(sStr AS String) AS String DIM sRes AS String DIM iInd AS Integer DIM sCar AS String DIM iPos AS Integer FOR iInd = 1 TO Len(sStr) sCar = Mid$(sStr, iInd, 1) iPos = InStr("'\"\\\n\r\t", sCar) IF iPos THEN sCar = "\\" & Mid$("'\"\\nrt", iPos, 1) sRes = sRes & sCar NEXT RETURN sRes END PUBLIC SUB Process_Read() DIM sLig AS String LINE INPUT #LAST, sLig PRINT sLig END PUBLIC SUB DeleteCompiledFiles() DIM sFile AS String EXEC ["rm", "-rf", Project.Dir &/ ".gambas"] WAIT IF Exist(Project.Dir &/ ".lang") THEN FOR EACH sFile IN Dir(Project.Dir &/ ".lang", "*.pot") TRY KILL Project.Dir &/ ".lang" &/ sFile NEXT ENDIF END PUBLIC FUNCTION GetCompileCommand(bAll AS Boolean, bNoDebug AS Boolean, bIDE AS Boolean) AS String DIM sExec AS String sExec = System.Path &/ "bin/gbc" & System.Version & " " IF bAll THEN sExec = sExec & "-a " IF NOT bNoDebug THEN sExec = sExec & "-g " IF Localize THEN sExec = sExec & "-t " IF ControlPublic THEN sExec = sExec & "-p " 'sExec = sExec & "-c " & Quote(CLASSES_FILE) & " " & Quote(Project.Dir) & " > " & OUTPUT_FILE & " 2>&1" IF bIDE THEN sExec = sExec & Quote(Project.Dir) sExec = sExec & " > " & OUTPUT_FILE & " 2>&1" ENDIF RETURN sExec END PUBLIC FUNCTION Compile(OPTIONAL bAll AS Boolean, OPTIONAL bNoDebug AS Boolean) AS Boolean DIM sExec AS String DIM sRes AS String DIM sDir AS String IF Project.ReadOnly THEN RETURN IF Project.Running THEN RETURN 'TRUE IF LockIt() THEN RETURN TRUE sDir = Project.Dir FProperty.SaveProperty Save SetMessage(("Compiling project") & " " & Project.Name & "...") IF bAll THEN CleanUpProject DeleteCompiledFiles WriteProject(TRUE) ENDIF sExec = GetCompileCommand(bAll, bNoDebug, TRUE) SHELL sExec WAIT 'Stat(OUTPUT_FILE) sRes = AddMessage(("Nothing to do.")) IF sRes THEN IF sRes <> "OK" THEN UnlockIt() CompileError(sRes) RETURN TRUE ELSE IF Localize THEN TRY MKDIR sDir &/ ".lang" SHELL "msgcat " & Quote(sDir) &/ ".lang/*.pot > " & Quote(sDir &/ ".lang/.pot") & " 2>/dev/null" WAIT ENDIF SetMessage(("OK")) FGambas.Animate("Happy") ENDIF ENDIF UnlockIt() END PRIVATE FUNCTION CheckRunning(OPTIONAL bCompileAll AS Boolean) AS Boolean IF Project.Running THEN RETURN IF Compile(bCompileAll) THEN RETURN TRUE IF CheckStartupClass() THEN RETURN TRUE END PUBLIC SUB Run(OPTIONAL bCompileAll AS Boolean, OPTIONAL iDebug AS Integer) IF CheckRunning(bCompileAll) THEN RETURN IF iDebug = 1 THEN Design.Step ELSE IF iDebug = 2 THEN Design.Forward ELSE IF iDebug = 3 THEN Design.ReturnFrom ELSE Design.Run ENDIF END PUBLIC SUB Forward() IF CheckRunning() THEN RETURN Design.Forward END PUBLIC SUB ReturnFrom() IF CheckRunning() THEN RETURN Design.ReturnFrom END PUBLIC SUB RunUntil(hForm AS FEditor, iLine AS Integer) IF CheckRunning() THEN RETURN Design.RunUntil(hForm, iLine) END PUBLIC SUB Step() IF Compile() THEN RETURN IF CheckStartupClass() THEN RETURN Design.Step END PUBLIC SUB Save() DIM hForm AS Object INC Application.Busy FOR EACH hForm IN Files IF Object.Type(hForm) = "FEditor" THEN IF hForm.Save(TRUE) THEN BREAK ELSE IF hForm.Save() THEN BREAK ENDIF NEXT DEC Application.Busy END PUBLIC SUB Insert(sName AS String, sType AS String, OPTIONAL sTemplate AS String, OPTIONAL bNoRefresh AS Boolean, OPTIONAL bNoOpen AS Boolean, OPTIONAL bLink AS Boolean) DIM sPath AS String DIM sData AS String sPath = Project.Dir &/ File.BaseName(sName) & "." & sType IF Exist(sPath) THEN FGambas.Warning(("File already exists.")) RETURN ENDIF IF bLink THEN LINK sPath TO sTemplate ELSE IF Left(sTemplate) = "/" THEN TRY COPY sTemplate TO sPath ELSE File.Save(sPath, sTemplate) ENDIF IF NOT bNoRefresh THEN Refresh IF NOT bNoOpen THEN OpenFile(sPath) END PUBLIC SUB InsertFile(sName AS String, sDir AS String, OPTIONAL sTemplate AS String, OPTIONAL bNoOpen AS Boolean, OPTIONAL bLink AS Boolean) DIM sPath AS String DIM sData AS String sPath = sDir &/ sName IF Len(sTemplate) THEN IF Exist(sPath) THEN FGambas.Warning(("File already exists.")) RETURN ENDIF 'SHELL "cp " & Quote(sTemplate) & " " & Quote(sPath) WAIT IF bLink THEN TRY LINK sPath TO sTemplate ELSE TRY COPY sTemplate TO sPath ENDIF IF NOT Exist(sPath) THEN FGambas.Error(("Cannot copy template file.") & "\n\n" & Error.Text) RETURN ENDIF ENDIF Refresh 'RefreshLibrary IF NOT bNoOpen THEN OpenFile(sPath) END PUBLIC SUB InsertDirectory(sPath AS String) IF Exist(sPath) THEN FGambas.Warning(("Directory already exists.")) RETURN ENDIF MKDIR sPath RefreshKey(sPath) END PUBLIC SUB Activate(hForm AS Object) DIM sType AS String DIM bEditor AS Boolean DIM bTextEditor AS Boolean IF AboutToQuit THEN RETURN IF hForm THEN SelectKey(hForm.Path) IF ActiveForm = hForm THEN RETURN 'ELSE 'IF NOT ActiveForm THEN RETURN ENDIF ActiveForm = hForm IF NOT ActiveForm THEN FProperty.HideAll FFormStack.HideAll FMain.ShowTool(FALSE) sType = "" ELSE FProperty.RefreshAll FFormStack.RefreshAll sType = Object.Type(ActiveForm) FMain.ShowTool(sType = "FForm" OR ShowAlwaysProperty) ENDIF bEditor = sType = "FEditor" bTextEditor = sType = "FTextEditor" Action["break"].Visible = bEditor Action["watch"].Visible = bEditor Action["until"].Visible = bEditor Action["find-comment"].Visible = NOT bTextEditor Action["find-in"].Visible = bEditor Action["find-previous"].Visible = bEditor OR bTextEditor Action["find-next"].Visible = bEditor OR bTextEditor Action["replace"].Visible = bEditor OR bTextEditor 'Action["replace-all"].Visible = bEditor OR bTextEditor END PUBLIC SUB Deactivate(hForm AS Object) IF ActiveForm <> hForm THEN RETURN 'DEBUG hForm 'DEBUG "DeActivate: "; hForm.Title SELECT CASE Object.Type(hForm) CASE "FForm" FProperty.HideAll FFormStack.HideAll 'FProperty.Hide ' FToolBox.Hide END SELECT END ' PUBLIC FUNCTION NewProject(sDir AS String, OPTIONAL aOption AS String[]) AS Boolean ' ' DIM sName AS String ' DIM iInd AS Integer ' DIM sPath AS String ' DIM sOption AS String ' ' sName = File.Name(sDir) ' ' MKDIR sDir ' sPath = sDir &/ PROJECT_FILE ' IF aOption THEN sOption = aOption.Join("\n") ' File.Save(sPath, PROJECT_MAGIC & "\nProject=" & sName & "\n" & sOption) ' ' 'BrowseForm.AddProject(sDir) ' ' RETURN ' ' CATCH ' ' FGambas.Error(("Cannot create project!") & "\n\n" & Error.Text) ' RETURN TRUE ' ' END PUBLIC FUNCTION CopyProject(sSrc AS String, sDst AS String) AS Boolean DIM sName AS String DIM iInd AS Integer DIM sPath AS String DIM sOut AS String sOut = Temp$ SHELL "cp -r " & Quote(sSrc) & " " & Quote(sDst) & " 2> " & Quote(sOut) WAIT sOut = File.Load(sOut) IF sOut THEN Error.Raise(sOut) RETURN CATCH Message.Warning(("Cannot copy project!") & "\n\n" & Error.Text) RETURN TRUE END PRIVATE SUB GetVersion() DIM sVer AS String DIM aVer AS String[] DIM iMajor AS Integer DIM iMinor AS Integer DIM iRelease AS Integer IF NOT VersionProgram THEN RETURN SHELL VersionProgram TO sVer aVer = Split(Trim(sVer), ".") iMajor = aVer[0] iMinor = aVer[1] TRY iRelease = aVer[2] MajorVersion = iMajor MinorVersion = iMinor IF iRelease THEN ReleaseVersion = iRelease CATCH DEBUG "Unable to get version from: "; VersionProgram END PUBLIC FUNCTION MakeExecutable(OPTIONAL bDoNotIncVersion AS Boolean, OPTIONAL bSilent AS Boolean) AS Boolean DIM sExec AS String DIM sPath AS String IF CheckStartupClass() THEN RETURN TRUE sPath = Project.Dir &/ Project.Name & ".gambas" IF NOT bSilent THEN IF Exist(File.Dir(ExecPath)) THEN sPath = ExecPath 'IF Dialog.SaveFile() THEN RETURN TRUE sPath = FMakeExecutable.Run(sPath) IF NOT sPath THEN RETURN ExecPath = File.SetExt(sPath, "gambas") ENDIF EXEC ["rm", "-rf", Project.Dir &/ ".gambas.save"] WAIT TRY MOVE Project.Dir &/ ".gambas" TO Project.Dir &/ ".gambas.save" IF Compile(TRUE, NOT KeepDebugInfo) THEN RETURN TRUE SetMessage(("Making executable...")) GetVersion() sExec = System.Path &/ "bin/gba" & System.Version & " -o " & Project.Quote(ExecPath) & " " & Project.Quote(Project.Dir) & " > " & OUTPUT_FILE & " 2>&1" SHELL sExec WAIT SetMessage(("OK")) 'Compile(TRUE, FALSE) EXEC ["rm", "-rf", Project.Dir &/ ".gambas"] WAIT TRY MOVE Project.Dir &/ ".gambas.save" TO Project.Dir &/ ".gambas" IF NOT bDoNotIncVersion THEN INC ReleaseVersion WriteProject(TRUE, TRUE) 'MakeShortcut(TRUE) END PUBLIC FUNCTION GetClasses(OPTIONAL bFullPath AS Boolean) AS String[] DIM sFile AS String DIM aModule AS NEW String[] DIM aClass AS NEW String[] DIM bStop AS Boolean FOR EACH sFile IN Dir(Project.Dir, "*.module") IF bFullPath THEN aModule.Add(Project.Dir &/ sFile) ELSE aModule.Add(File.BaseName(sFile)) ENDIF NEXT aModule.Sort FOR EACH sFile IN Dir(Project.Dir, "*.class") IF bFullPath THEN aClass.Add(Project.Dir &/ sFile) ELSE aClass.Add(File.BaseName(sFile)) ENDIF NEXT aClass.Sort aModule.Insert(aClass) IF NOT bFullPath THEN aModule.Sort RETURN aModule END PUBLIC SUB ReadProject() DIM hFic AS File DIM sLig AS String DIM iPos AS Integer DIM sKey AS String DIM sVal AS String DIM cVer AS String[] DIM sElt AS String DIM iElt AS Integer DIM aMissing AS NEW String[] DIM sMsg AS String Libraries = NEW String[] Title = "" TabSize = Settings["/DefaultTabSize", 2] Arguments = NEW String[] CurrentArgument = 0 MajorVersion = 0 MinorVersion = 0 ReleaseVersion = 1 'SnapToGrid = TRUE 'ShowGrid = TRUE Snap = Desktop.Scale 'Settings["/DefaultGridResolution", 8] ControlPublic = FALSE KeepDebugInfo = FALSE Localize = FALSE Description = "" Authors = "" Icon = "" Systems = NEW String[] Menus = NEW Collection Groups = NEW Collection Prefix = FALSE ExecPath = Project.Dir &/ Project.Name & ".gambas" CreateComponent = FALSE CreateShortcut = FALSE Language = "" VersionProgram = "" Stack = 0 hFic = OPEN Path FOR READ WHILE NOT Eof(hFic) LINE INPUT #hFic, sLig sLig = Trim(sLig) IF Len(sLig) = 0 THEN CONTINUE IF Left$(sLig, 1) = "#" THEN CONTINUE iPos = InStr(sLig, "=") IF iPos = 0 THEN CONTINUE sKey = Lower$(Trim(Left$(sLig, iPos - 1))) sVal = Trim(Mid$(sLig, iPos + 1)) SELECT sKey CASE "title" Title = sVal CASE "startup" DefineStartup(sVal, TRUE) CASE "library" IF CComponent.All.Exist(sVal) THEN Libraries.Add(sVal) ELSE aMissing.Add(sVal) ENDIF CASE "tabsize" TabSize = Val(sVal) CASE "argument" Arguments.Add(Replace(sVal, "\\n", "\n")) CASE "currentargument" CurrentArgument = Val(sVal) CASE "version" cVer = Split(sVal, ".") TRY MajorVersion = Val(cVer[0]) TRY MinorVersion = Val(cVer[1]) TRY ReleaseVersion = Val(cVer[2]) CASE "versionprogram" VersionProgram = sVal CASE "localize", "translate" Localize = Val(sVal) <> 0 CASE "language" Language = sVal CASE "keepdebuginfo" KeepDebugInfo = Val(sVal) <> 0 CASE "createshortcut" CreateShortcut = Val(sVal) <> 0 CASE "makecomponent" CreateComponent = Val(sVal) <> 0 CASE "controlpublic" ControlPublic = Val(sVal) <> 0 CASE "description" Description = Replace(sVal, "\\n", "\n") CASE "authors" Authors = Replace(sVal, "\\n", "\n") CASE "icon" Icon = sVal CASE "systems" Systems = Split(sVal, ",") CASE "menus" iElt = 0 FOR EACH sElt IN Split(sVal, ",") IF iElt >= Systems.Count THEN BREAK Menus[Systems[iElt]] = sElt INC iElt NEXT CASE "groups" iElt = 0 FOR EACH sElt IN Split(sVal, ",") IF iElt >= Systems.Count THEN BREAK Groups[Systems[iElt]] = sElt INC iElt NEXT CASE "prefix" Prefix = Val(sVal) CASE "execpath" ExecPath = sVal CASE "stack" Stack = Val(sVal) END SELECT WEND CLOSE hFic IF aMissing.Count THEN sMsg = Subst(("Some components are missing: &1"), aMissing.Join(", ")) IF Message.Error(sMsg, ("Continue"), ("Cancel")) = 2 THEN Error.Raise("") ENDIF ENDIF FMain.UpdateTranslate FMain.UpdateRunWithMenu RefreshLibrary END PUBLIC SUB WriteProject(OPTIONAL bComponentDoNotChange AS Boolean, OPTIONAL bMakeShortcut AS Boolean) DIM hFic AS File DIM sLib AS String DIM sSys AS String DIM sElt AS String DIM sPath AS String DIM sArg AS String DIM iKey AS Integer DIM iCount AS Integer DIM hComp AS CComponent DIM sShortcut AS String IF Project.ReadOnly THEN RETURN hFic = OPEN Path & ".tmp" FOR CREATE PRINT #hFic, PROJECT_MAGIC 'PRINT #hFic, "Project="; Name IF Title THEN PRINT #hFic, "Title="; Title IF Startup THEN PRINT #hFic, "Startup="; Startup IF Stack THEN PRINT #hFic, "Stack="; Stack IF Icon THEN PRINT #hFic, "Icon="; Icon PRINT #hFic, "Version="; CStr(MajorVersion) & "." & CStr(MinorVersion) & "." & CStr(ReleaseVersion) IF VersionProgram THEN PRINT #hFic, "VersionProgram="; VersionProgram FOR EACH hComp IN CComponent.All IF Libraries.Find(hComp.Key) >= 0 THEN PRINT #hFic, "Library="; hComp.Key ENDIF NEXT IF Description THEN PRINT #hFic, "Description="; Replace(Description, "\n", "\\n") IF Authors THEN PRINT #hFic, "Authors="; Replace(Authors, "\n", "\\n") FOR EACH sArg IN Arguments PRINT #hFic, "Argument="; Replace(sArg, "\n", "\\n") NEXT IF CurrentArgument THEN PRINT #hFic, "CurrentArgument="; CurrentArgument PRINT #hFic, "TabSize="; CStr(TabSize) IF Localize THEN PRINT #hFic, "Translate=1" IF Language THEN PRINT #hFic, "Language="; Language IF KeepDebugInfo THEN PRINT #hFic, "KeepDebugInfo=1" IF CreateShortcut THEN PRINT #hFic, "CreateShortcut=1" IF CreateComponent THEN PRINT #hFic, "MakeComponent=1" IF ControlPublic THEN PRINT #hFic, "ControlPublic=1" IF ExecPath <> (Project.Dir &/ Project.Name & ".gambas") THEN PRINT #hFic, "ExecPath="; ExecPath ENDIF IF Systems.Count THEN PRINT #hFic, "Systems="; Systems.Join(",") sElt = "" FOR EACH sSys IN Systems sElt = sElt & "," & Menus[sSys] NEXT PRINT #hFic, "Menus="; Mid$(sElt, 2) sElt = "" FOR EACH sSys IN Systems sElt = sElt & "," & Groups[sSys] NEXT PRINT #hFic, "Groups="; Mid$(sElt, 2) ENDIF IF Prefix THEN PRINT #hFic, "Prefix=1" CLOSE #hFic KILL Path MOVE Path & ".tmp" TO Path sPath = Project.Dir &/ ".lang/#project.pot" TRY KILL sPath IF Localize THEN TRY MKDIR File.Dir(sPath) OPEN sPath FOR CREATE AS #hFic PRINT #hFic, "# "; Path PRINT #hFic, File.Load("pot-header.txt") IF Title THEN PRINT #hFic, "#: .project:1" PRINT #hFic, "msgid \""; Escape(Title); "\"" PRINT #hFic, "msgstr \"\"\n" ENDIF IF Description THEN PRINT #hFic, "#: .project:2" PRINT #hFic, "msgid \""; Escape(Description); "\"" PRINT #hFic, "msgstr \"\"\n" ENDIF CLOSE #hFic ENDIF IF CreateComponent IF Project.CreateShortcut THEN IF bMakeShortcut THEN InstallComponent ELSE UninstallComponent ENDIF ELSE MakeShortcut(bMakeShortcut) ENDIF IF NOT bComponentDoNotChange THEN RefreshLibrary FMain.UpdateTranslate CATCH FGambas.Error(("Cannot write project file.") & "\n\n" & Error.Text) END PUBLIC SUB MakeShortcut(OPTIONAL bForce AS Boolean) DIM sPath AS String DIM sShortcut AS String IF NOT CreateShortcut THEN RETURN sPath = "~/Desktop" &/ Name & ".desktop" IF NOT bForce THEN IF NOT Exist(sPath) THEN RETURN ENDIF sShortcut = File.Load("shortcut.desktop") sShortcut = Replace(sShortcut, "$(NAME)", If(Title, Title, Name)) sShortcut = Replace(sShortcut, "$(EXEC)", ExecPath) sPath = "" IF Icon AND IF Exist(Project.Dir &/ Icon) THEN sPath = Project.Dir &/ Icon ENDIF sShortcut = Replace(sShortcut, "$(ICON)", sPath) File.Save("~/Desktop" &/ Name & ".desktop", sShortcut) CATCH FGambas.Error(("Unable to create desktop shortcut.") & "\n\n" & Error.Text & "\n" & Error.Where) END PUBLIC SUB MakeDir(sDir AS String) AS Boolean DIM sPath AS String DIM sElt AS String FOR EACH sElt IN Split(sDir, "/") sPath &/= sElt TRY MKDIR "/" & sPath NEXT IF NOT Exist(sDir) OR IF NOT IsDir(sDir) THEN RETURN TRUE END PRIVATE SUB MakeLink(sSrc AS String, sDst AS String) IF NOT Exist(sSrc) THEN LINK sSrc TO sDst END PUBLIC SUB InstallComponent() DIM sDir AS String = Component.UserPath MakeDir(sDir) MakeLink(sDir &/ Name & ".gambas", Project.ExecPath) MakeLink(sDir &/ Name & ".component", Project.Dir &/ ".component") sDir = File.Dir(File.Dir(sDir)) &/ "share/gambas" & System.Version & "/info" MakeDir(sDir) MakeLink(sDir &/ Name & ".info", Project.Dir &/ ".info") MakeLink(sDir &/ Name & ".list", Project.Dir &/ ".list") CATCH FGambas.Error(("Unable to install component.") & "\n\n" & Error.Text & "\n" & Error.Where) END PUBLIC SUB UninstallComponent() DIM sDir AS String = Component.UserPath 'MakeDir(sDir) TRY KILL sDir &/ Name & ".gambas" TRY KILL sDir &/ Name & ".component" sDir = File.Dir(File.Dir(sDir)) &/ "share/gambas" & System.Version & "/info" TRY KILL sDir &/ Name & ".info" TRY KILL sDir &/ Name & ".list" CATCH FGambas.Error(("Unable to uninstall component.") & "\n\n" & Error.Text & "\n" & Error.Where) END PUBLIC FUNCTION GetNextEditor(sKey AS String) AS String DIM sFirst AS String DIM sFile AS String DIM bNext AS Boolean IF NOT sKey THEN bNext = TRUE FOR EACH sFile IN GetClasses(TRUE) IF bNext THEN RETURN sFile IF NOT sFirst THEN sFirst = sFile ENDIF IF sFile = sKey THEN bNext = TRUE ENDIF NEXT IF bNext THEN RETURN sFirst END PUBLIC FUNCTION GetPreviousEditor(sKey AS String) AS String DIM sLast AS String DIM sFile AS String FOR EACH sFile IN GetClasses(TRUE) IF sFile = sKey THEN IF sLast THEN RETURN sLast ENDIF ENDIF sLast = sFile NEXT RETURN sLast END PUBLIC SUB SetMessage(sMsg AS String) IF FGambas.Visible AND IF sMsg <> ("OK") THEN FGambas.Info(sMsg) ENDIF ProjectMessage.Text = sMsg WAIT END PUBLIC SUB DeleteFile(sPath AS String) DIM sExt AS String DIM hForm AS Object DIM bLink AS Boolean DIM bProject AS Boolean IF NOT Exist(sPath) THEN RETURN bLink = Stat(sPath).Type = gb.Link bProject = File.Dir(sPath) = Project.Dir hForm = Files[sPath] IF hForm THEN hForm.Delete Files[sPath] = NULL ENDIF TRY ProjectTree.Remove(sPath) IF NOT bLink THEN TRY KILL sPath & "~" TRY MOVE sPath TO sPath & "~" ELSE TRY KILL sPath ENDIF IF bProject THEN sExt = File.Ext(sPath) IF sExt = "form" OR sExt = "class" OR sExt = "module" THEN TRY KILL Project.Dir &/ ".gambas" &/ UCase(File.BaseName(sPath)) TRY KILL Project.Dir &/ ".lang" &/ File.BaseName(sPath) & ".pot" ENDIF IF sExt = "form" THEN DeleteFile(File.Dir(sPath) &/ File.BaseName(sPath) & ".class") ELSE IF sExt = "class" THEN DeleteFile(File.Dir(sPath) &/ File.BaseName(sPath) & ".form") ENDIF IF File.BaseName(sPath) = Startup THEN DefineStartup("") ENDIF ENDIF 'CATCH 'Message("*Unable to delete file.||" & sPath) 'Refresh END PUBLIC SUB DeleteDir(sDir AS String) DIM sFile AS String FOR EACH sFile IN Dir(sDir, "*~") TRY KILL sDir &/ sFile NEXT RMDIR sDir Project.RefreshKey(sDir) END PRIVATE FUNCTION CheckStartupClass() AS Boolean IF Startup THEN RETURN FGambas.Warning(("You must define a startup class or form!")) RETURN TRUE END PUBLIC FUNCTION CheckFileName(sName AS String, OPTIONAL sDir AS String) AS String DIM iInd AS Integer IF NOT sName THEN GOTO VOID_NAME FOR iInd = 1 TO Len(sName) IF InStr(FILE_AUTH_CAR & "-._+()", LCase(Mid$(sName, iInd, 1))) = 0 THEN GOTO BAD_CHAR NEXT IF Len(sDir) THEN IF Exist(sDir &/ sName) THEN GOTO ALREADY_EXIST ENDIF RETURN VOID_NAME: RETURN ("Please type a name.") BAD_CHAR: RETURN ("This name contains a forbidden character :") & " [ " & Mid$(sName, iInd, 1) & " ]" ALREADY_EXIST: RETURN ("This name is already used. Choose another one.") END PUBLIC FUNCTION CheckClassName(sName AS String, OPTIONAL bCheckNotExist AS Boolean) AS String DIM iInd AS Integer IF NOT sName THEN GOTO VOID_NAME FOR iInd = 1 TO Len(sName) IF InStr(CLASS_AUTH_CAR, LCase(Mid$(sName, iInd, 1))) = 0 THEN GOTO BAD_CHAR NEXT IF InStr("0123456789", Left$(sName)) THEN iInd = 1 GOTO BAD_CHAR ENDIF IF bCheckNotExist THEN IF Project.Exist(sName) THEN GOTO ALREADY_EXIST ENDIF RETURN VOID_NAME: RETURN ("Please type a name.") BAD_CHAR: RETURN ("This name contains a forbidden character :") & " [ " & Mid$(sName, iInd, 1) & " ] \n\n" & ("A name must begin with a letter, followed by any letter or digit.") ALREADY_EXIST: RETURN ("This name is already used. Choose another one.") END PRIVATE FUNCTION RenameOneFile(sDir AS String, sName AS String, sNewName AS String, OPTIONAL sExt AS String) AS String DIM sPath AS String DIM hForm AS Object DIM sNewPath AS String sPath = sDir &/ sName IF sExt THEN sPath = sPath & "." & sExt IF NOT Exist(sPath) THEN RETURN sNewPath = sDir &/ sNewName IF sExt THEN sNewPath = sNewPath & "." & sExt MOVE sPath TO sNewPath IF sExt THEN TRY KILL sDir &/ ".gambas" &/ UCase(sName) ENDIF hForm = Files[sPath] IF hForm THEN hForm.Rename(sNewName, sNewPath) Files[sPath] = NULL Files[sNewPath] = hForm ENDIF RETURN sNewPath END PUBLIC SUB GetClassesOnly() AS String[] DIM sFile AS String DIM sKey AS String DIM aClass AS NEW String[] FOR EACH sFile IN Dir(Project.Dir, "*.class") IF Exist(Project.Dir &/ File.BaseName(sFile) & ".form") THEN CONTINUE aClass.Add(File.BaseName(sFile)) NEXT RETURN aClass.Sort() END PRIVATE SUB RefreshInheritance() DIM sClass AS String DIM sKey AS String $aRefreshAfter.Clear FOR EACH sClass IN GetClassesOnly() sKey = Project.Dir &/ sClass & ".class" TRY ProjectTree[sKey].Delete $aRefreshAfter.Add(sKey) NEXT DoRefreshAfter END PUBLIC SUB RefreshKey(sKey AS String, OPTIONAL sOld AS String) IF NOT sKey THEN RETURN IF NOT sOld THEN sOld = sKey TRY ProjectTree[sOld].Delete IF NOT Exist(sKey) THEN RETURN IF File.Dir(sKey) = Project.Dir AND IF file.Ext(sKey) = "class" AND IF NOT Exist(File.Dir(sKey) &/ File.BaseName(sKey) & ".form") THEN RefreshInheritance RETURN ENDIF AddFile(File.Dir(sKey), File.Name(sKey), TRUE) IF IsDir(sKey) THEN AddDir(sKey) END PUBLIC SUB RenameFile(sPath AS String, sNewName AS String) DIM sName AS String DIM sExt AS String DIM sDir AS String DIM sNewPath AS String sDir = File.Dir(sPath) sExt = File.Ext(sPath) IF Project.IsClassName(sPath) THEN sName = File.BaseName(sPath) IF sName = sNewName THEN RETURN IF sName = Startup THEN Startup = sNewName WriteProject(TRUE) ENDIF sNewPath = RenameOneFile(sDir, sName, sNewName, sExt) IF sExt = "form" THEN RenameOneFile(sDir, sName, sNewName, "class") ELSE IF sExt = "class" THEN RenameOneFile(sDir, sName, sNewName, "form") ENDIF ELSE sName = File.Name(sPath) IF sName = sNewName THEN RETURN sNewPath = RenameOneFile(sDir, sName, sNewName) ENDIF RefreshKey(sNewPath, sPath) 'AddFile(File.Dir(sNewPath), File.Name(sNewPath), TRUE) 'IF IsDir(sNewPath) THEN AddDir(sNewPath) TRY ProjectTree[sNewPath].Selected = TRUE TRY ProjectTree[sNewPath].EnsureVisible CATCH FGambas.Error(Subst(("Unable to rename '&1'") & "\n\n" & Error.Text, File.Name(sPath))) END PUBLIC FUNCTION Exist(sName AS String) AS Boolean RETURN Project.GetClasses().Find(sName, gb.Text) >= 0 END PRIVATE FUNCTION LockIt() AS Boolean IF Application.Busy THEN RETURN TRUE INC Application.Busy 'PRINT "Lock" END PRIVATE SUB UnLockIt() DEC Application.Busy END PUBLIC FUNCTION GetProject() AS String RETURN FOpenProject.Run() END PRIVATE SUB LoadRecent() DIM nRecent AS Integer DIM hMenu AS Menu DIM iInd AS Integer DIM sPath AS String nRecent = Settings["/Recent/Count", 0] Recent.Clear FOR iInd = 1 TO nRecent sPath = Settings["/Recent/File[" & CStr(iInd) & "]"] IF sPath THEN IF Exist(sPath) THEN Recent.Add(sPath) IF Recent.Count >= MAX_RECENT THEN BREAK ENDIF ENDIF NEXT END PRIVATE SUB AddRecent(sPath AS String) DIM iInd AS Integer IF Right$(sPath) = "/" THEN sPath = Left$(sPath, -1) 'sPath = "(" & File.BaseName(sPath) & ") " & File.Dir(sPath) WHILE iInd < Recent.Count IF Recent[iInd] = sPath THEN Recent.Remove(iInd) ELSE INC iind ENDIF WEND Recent.Add(sPath, 0) WHILE Recent.Count > MAX_RECENT Recent.Remove(Recent.Count - 1) WEND SaveRecent END PRIVATE SUB SaveRecent() DIM iInd AS Integer Settings.Clear("/Recent") Settings["/Recent/Count"] = Recent.Count FOR iInd = 0 TO Recent.Count - 1 Settings["/Recent/File[" & CStr(iInd + 1) & "]"] = Recent[iInd] NEXT Settings.Save END PUBLIC SUB ClearRecent() Recent.Clear SaveRecent END PUBLIC FUNCTION CheckProjectName(sName AS String, OPTIONAL sDir AS String) AS String DIM iInd AS Integer DIM sCar AS String sName = Trim(sName) IF NOT sName THEN RETURN ("Please type a project name.") ENDIF FOR iInd = 1 TO Len(sName) sCar = Mid$(sName, iInd, 1) IF iInd = 1 THEN IF sCar = "." THEN RETURN ("The project name cannot begin with a dot.") ENDIF IF Asc(sCar) > 127 THEN RETURN ("Non-ASCII characters are forbidden in a project name.") IF InStr(" ?*/\\", sCar) THEN RETURN ("The following characters are forbidden in a project name: ? * / \\ SPACE") NEXT IF sDir THEN sDir &/= sName IF Exist(sDir &/ PROJECT_FILE) THEN RETURN ("This project already exists.") ELSE IF Exist(sDir) THEN IF IsDir(sDir) THEN RETURN Subst(("The project directory already exists."), sDir) ELSE RETURN Subst(("The project directory cannot be created because a file with the same name already exists."), sDir) ENDIF ENDIF ENDIF END PUBLIC SUB MakeSourcePackageTo(sPath AS String) DIM sCmd AS String DIM sOpt AS String INC Application.Busy IF Right$(sPath, 3) = ".gz" THEN sOpt = "z" ELSE IF Right$(sPath, 4) = ".bz2" THEN sOpt = "j" ENDIF sCmd = "cd " & Quote(File.Dir(Project.Dir)) & ";" sCmd = sCmd & " tar cfvh" & sOpt & " " & Quote(sPath) sCmd = sCmd & " --exclude=" & ".gambas/*" sCmd = sCmd & " --exclude=" & "*~" sCmd = sCmd & " --exclude=" & ".lock" sCmd = sCmd & " --exclude=" & ".lang/*.pot" sCmd = sCmd & " --exclude=" & ".lang/.pot" sCmd = sCmd & " --exclude=" & "*/.xvpics/*" sCmd = sCmd & " --exclude=" & ".xvpics/*" sCmd = sCmd & " " & Quote(File.Name(Project.Dir)) & " > /dev/null" SHELL sCmd WAIT DEC Application.Busy END PUBLIC SUB MakePackage() Dialog.Path = User.Home &/ Name & "-" & Subst("&1.&2", MajorVersion, MinorVersion) & IIf(ReleaseVersion > 0, "." & ReleaseVersion, "") & ".tar.gz" Dialog.Title = ("Create source package") Dialog.Filter = ["*.tar.gz", ("Source packages")] '& " (*.tar.gz)", ("All files") & " (*)"] IF Dialog.SaveFile() THEN RETURN MakeSourcePackageTo(Dialog.Path) END PUBLIC SUB RefreshForm() DIM hFile AS Object FOR EACH hFile IN Project.Files IF Object.Type(hFile) = "FForm" THEN hFile.Refresh ENDIF NEXT END PUBLIC SUB RefreshEditor() DIM hFile AS Object FOR EACH hFile IN Project.Files IF Project.IsEditor(hFile) THEN hFile.Refresh ENDIF NEXT END PUBLIC SUB RefreshLibrary() DIM sLib AS String DIM sClass AS String DIM aLib AS NEW String[] DIM hComp AS CComponent DIM sLibComp AS String ' Sort components FOR EACH hComp IN CComponent.All IF Libraries.Find(hComp.Key) >= 0 THEN aLib.Add(hComp.Key) ENDIF NEXT Libraries = aLib sLibComp = aLib.Join(" ") IF sLibComp <> $sOldRefreshLibrary THEN CComponent.Reset ComponentFromType.Clear FormType.Clear FOR EACH sLib IN Libraries 'IF NOT CComponent.All.Exist(sLib) THEN CONTINUE WITH CComponent.All[sLib] .Load IF .Type THEN ComponentFromType[.Type] = sLib ENDIF END WITH NEXT FToolBox.RefreshToolbar FCompletion.RefreshLibrary 'FExplorer.RefreshTree Project.Refresh $sOldRefreshLibrary = sLibComp ENDIF END PUBLIC FUNCTION IsClassName(sName AS String) AS Boolean DIM sExt AS String IF Left(sName) = "/" THEN IF File.Dir(sName) <> Project.Dir THEN RETURN ENDIF sExt = File.Ext(sName) IF sExt = "class" THEN RETURN TRUE IF sExt = "module" THEN RETURN TRUE IF sExt = "form" THEN RETURN TRUE END PUBLIC FUNCTION StripPath(sPath AS String) AS String DIM sDir AS String sDir = Project.Dir IF Right$(sDir) <> "/" THEN sDir = sDir & "/" IF Left$(sPath, Len(sDir)) = sDir THEN RETURN Mid$(sPath, Len(sDir) + 1) ELSE RETURN sPath ENDIF END PUBLIC SUB RunTool(sTool AS String) DIM aExec AS NEW String[] aExec.Add(System.Path &/ "bin" &/ sTool & ".gambas") aExec.Add(Project.Dir) EXEC aExec END PUBLIC FUNCTION GetExamples() AS String[] DIM sFile AS String DIM sFile2 AS String DIM aList AS NEW String[] FOR EACH sFile IN Dir(EXAMPLES_DIR) IF Left(sFile) = "." THEN CONTINUE IF Exist(EXAMPLES_DIR &/ sFile &/ ".project") THEN aList.Add(sFile) ELSE FOR EACH sFile2 IN Dir(EXAMPLES_DIR &/ sFile) IF Left(sFile2) = "." THEN CONTINUE aList.Add(sFile &/ sFile2) NEXT ENDIF NEXT aList.Sort FINALLY RETURN aList END PUBLIC SUB DefineStartup(sPath AS String, OPTIONAL bDoNotWrite AS Boolean) sPath = File.BaseName(sPath) IF NOT Project.Exist(sPath) THEN sPath = "" SWAP Startup, sPath IF sPath THEN RefreshKey(FindKey(sPath)) IF Startup THEN RefreshKey(FindKey(Startup)) IF NOT bDoNotWrite THEN WriteProject(TRUE) CATCH END PUBLIC SUB GetUniqueName(sDir AS String, sName AS String, OPTIONAL sSuffix AS String = "&1") AS String DIM iInd AS Integer DIM sDest AS String DIM sExt AS String DIM sPath AS String sDest = sDir &/ sName WHILE Exist(sDest) INC iInd sExt = File.Ext(sName) IF sExt THEN sDest = sDir &/ File.BaseName(sName) & Subst(sSuffix, CStr(iInd)) & "." & sExt ELSE sDest = sDir &/ sName & Subst(sSuffix, CStr(iInd)) ENDIF WEND RETURN File.Name(sDest) END PUBLIC SUB CopyFile(sSrc AS String, sDst AS String) DIM sDest AS String sDest = File.Dir(sDst) &/ GetUniqueName(File.Dir(sDst), File.Name(sDst), " (&1)") COPY sSrc TO sDest RefreshKey(sDest) SelectKey(sDest) CATCH Message.Error(Subst(("Cannot copy file &1."), sSrc) & "\n\n" & Error.Text) END PUBLIC SUB LinkFile(sSrc AS String, sDst AS String) DIM sDest AS String DIM aDst AS String[] DIM aSrc AS String[] DIM sDir AS String IF IsDir(sSrc) THEN Message.Warning(("Linking a directory is forbidden.")) RETURN ENDIF sDest = File.Dir(sDst) &/ GetUniqueName(File.Dir(sDst), File.Name(sDst), " (&1)") IF sSrc LIKE (Project.Dir & "/*") THEN aDst = Split(File.Dir(Mid$(sDest, Len(Project.Dir) + 2)), "/") sSrc = Mid$(sSrc, Len(Project.Dir) + 2) aSrc = Split(File.Dir(sSrc), "/") WHILE aDst.Count > 0 AND aSrc.Count > 0 IF aSrc[0] <> aDst[0] THEN BREAK aDst.Remove(0) aSrc.Remove(0) WEND sSrc = String(aDst.Count, "../") & aSrc.Join("/") &/ File.Name(sSrc) ENDIF LINK sDest TO sSrc RefreshKey(sDest) SelectKey(sDest) CATCH Message.Error(Subst(("Cannot create link &1."), sSrc) & "\n\n" & Error.Text) END PUBLIC SUB MoveFile(sSrc AS String, sDst AS String) DIM hForm AS Object DIM sLink AS String DIM sDir AS String IF sSrc = sDst THEN RETURN IF Len(sDst) > Len(sSrc) AND IF Left(sDst, Len(sSrc)) = sSrc THEN Message.Error(("Cannot move a directory inside itself.")) RETURN ENDIF WITH Stat(sSrc) IF .Type = gb.Link THEN sLink = .Link IF Left(sLink) <> "/" THEN sDir = File.Dir(sSrc) WHILE Left(sLink, 3) = "../" sLink = Mid(sLink, 4) sDir = File.Dir(sDir) WEND sLink = sDir &/ sLink ENDIF DeleteFile(sSrc) LinkFile(sLink, sDst) RETURN ENDIF END WITH MOVE sSrc TO sDst hForm = Files[sSrc] IF hForm THEN hForm.Rename(File.Name(sDst), sDst) Files[sSrc] = NULL Files[sDst] = hForm ENDIF RefreshKey(sDst, sSrc) 'Refresh SelectKey(sDst) CATCH Message.Error(Subst(("Cannot move file &1."), sSrc) & "\n\n" & Error.Text) END ' PUBLIC SUB RefreshToolbox() ' ' FToolBox.ClearToolbar ' ' END PUBLIC FUNCTION GetNewName(sPrefix AS String) AS String DIM iInd AS Integer DIM sName AS String DO INC iInd sName = sPrefix & iInd IF NOT Project.Exist(sName) THEN RETURN sName LOOP END PUBLIC SUB ResetScan() DIM hFile AS Object FOR EACH hFile IN Files TRY hFile.Scan = NULL NEXT END PUBLIC FUNCTION AllowForm() AS Boolean RETURN ComponentFromType.Exist("Form") END PUBLIC SUB MakeInstall() IF MakeExecutable(TRUE, TRUE) THEN RETURN IF NOT CheckProgram("rpmbuild") THEN RPMBUILD_PROG = "rpmbuild" ELSE IF NOT CheckProgram("rpm") THEN RPMBUILD_PROG = "rpm" ELSE Message.Error(("rpmbuild is not installed on your system.")) RETURN ENDIF FMakeInstall.ShowModal END PUBLIC SUB InitMove(hForm AS Form) 'hForm.Move(Int(Rnd(0, Max(0, Workspace.Width - hForm.Width - 8))), Int(Rnd(0, Max(0, Workspace.Height - hForm.Height - 8)))) END PUBLIC FUNCTION GetIcon(sPath AS String, OPTIONAL iSize AS Integer) AS Picture DIM hFile AS File DIM sLig AS String DIM hImage AS Image DIM hPict AS Picture OPEN sPath &/ ".project" FOR READ AS #hFile WHILE NOT Eof(hFile) LINE INPUT #hFile, sLig IF Left$(sLig, 5) = "Icon=" THEN sPath = sPath &/ Mid$(sLig, 6) TRY hImage = Image.Load(sPath) IF ERROR THEN hImage = NULL BREAK ENDIF WEND CLOSE #hFile FINALLY IF NOT hImage THEN hImage = Image.Load("img/32/gambas.png") ENDIF IF iSize = 0 THEN RETURN hImage.Picture ELSE RETURN hImage.Stretch(iSize, iSize, TRUE).Picture ENDIF END PRIVATE SUB CleanUpProject() DIM aDir AS NEW String[] DIM sFile AS String DIM sPath AS String aDir.Add(Project.Dir) WHILE aDir.Count FOR EACH sFile IN Dir(aDir[0]) sPath = aDir[0] &/ sFile IF IsDir(sPath) THEN aDir.Add(sPath) ELSE IF Right(sPath) = "~" THEN TRY KILL sPath ENDIF NEXT aDir.Remove(0) WEND CATCH Message.Error(("Cannot clean the project.") & "\n\n" & Error.Text) END PUBLIC SUB SetFormIcon(hForm AS FForm) ' ' DIM hPict AS Picture ' DIM eRap AS Float ' ' 'hForm.Raise ' hPict = hForm.Grab() ' hForm.Refresh ' eRap = hPict.Width / hPict.Height ' IF eRap > 4 THEN ' eRap = 4 ' hPict = hPict.Copy(0, 0, hPict.Height * eRap, hPict.Height) ' ELSE IF eRap < 0.5 THEN ' eRap = 0.5 ' hPict = hPict.Copy(0, 0, hPict.Width, hPict.Width / eRap) ' ENDIF ' IF eRap > 1 THEN ' hPict = hPict.Image.Stretch(32 * eRap, 32).Picture ' ELSE ' hPict = hPict.Image.Stretch(32, 32 / eRap).Picture ' ENDIF ' ' Draw.Begin(hPict) ' Draw.Foreground = &H808080& ' Draw.Rect(0, 0, hPict.Width, hPict.Height) ' Draw.End ' ' ProjectTree[Project.Dir &/ hForm.Name & ".form"].Picture = hPict ' ' CATCH ' ' PRINT Error.Text ' END PUBLIC FUNCTION CheckProgram(sProg AS String) AS Boolean DIM sTemp AS String DIM bError AS Boolean DIM iPos AS Integer iPos = InStr(sProg, " ") IF iPos THEN sProg = Left(sProg, iPos - 1) sTemp = Temp$ SHELL "which " & sProg & " > " & sTemp WAIT bError = Trim(File.Load(sTemp)) LIKE "which: *" KILL sTemp RETURN bError END PUBLIC FUNCTION OpenWebPage(sLink AS String) AS String DIM sExec AS String DIM aTest AS String[] DIM bCheck AS Boolean IF NOT Browser THEN SELECT CASE Settings["/Browser"] CASE "konqueror" aTest = ["konqueror"] CASE "epiphany" aTest = ["epiphany"] CASE "firefox" aTest = ["firefox", "mozilla-firefox"] CASE "seamonkey" aTest = ["seamonkey"] CASE ELSE aTest = [Application.Env["BROWSER"]] IF Application.Env["KDE_FULL_SESSION"] THEN aTest.Add("konqueror") ELSE IF Application.Env["GNOME_SESSION_ID"] THEN aTest.Add("epiphany") ENDIF END SELECT aTest.Add("konqueror") aTest.Add("mozilla-firefox") aTest.Add("firefox") aTest.Add("mozilla") aTest.Add("seamonkey") aTest.Add("opera") FOR EACH sExec IN aTest bCheck = NOT CheckProgram(sExec) IF bCheck THEN BREAK NEXT IF NOT bCheck THEN RETURN Browser = sExec ENDIF IF Left(sLink) = "/" THEN sLink = "file://" & Replace(sLink, "?", "%3F") ENDIF SHELL Browser & " " & Chr$(34) & sLink & Chr$(34) CATCH Message.Error(Error.Text) END ' PUBLIC SUB ClearFound() ' ' DIM aKey AS NEW String[] ' DIM sKey AS String ' ' IF $iFound = 0 THEN RETURN ' ' WITH ProjectTree ' .MoveFirst ' ' DO ' ' IF NOT .MoveChild() THEN CONTINUE ' .MoveBack ' ' IF Left(.Item.Key, 2) = KEY_FIND THEN aKey.Add(.Item.Key) ' ' NEXT_PARENT: ' ' IF NOT .MoveNext() THEN CONTINUE ' .MoveBack ' ' IF .MoveParent() THEN BREAK ' GOTO NEXT_PARENT ' ' LOOP ' ' FOR EACH sKey IN aKey ' ProjectTree.Remove(sKey) ' NEXT ' ' END WITH ' ' $iFound = 0 ' ProjectTree.Columns.Count = 1 ' ' END ' ' PUBLIC SUB AddFound(sName AS String, iLine AS Integer, iCol AS Integer, iLen AS Integer, sText AS String) ' ' DIM sKey AS String ' 'DIM sAfter AS String ' DIM sParent AS String ' ' sParent = FindKey(sName) ' IF NOT sParent THEN RETURN ' ' ProjectTree.Columns.Count = 2 ' ' sKey = KEY_FIND & sParent & "@" & Format(iLine, "000000") & "." & Format(iCol, "00000") & "." & iLen ' ' ' ProjectTree.MoveTo(sParent) ' ' IF NOT ProjectTree.MoveChild() THEN ' ' WHILE ProjectTree.Available ' ' ProjectTree.MoveNext ' ' WEND ' ' ProjectTree.MoveBack ' ' sAfter = ProjectTree.Item.Key ' ' ENDIF ' ' ' ' DEBUG sKey;; ":";; sAfter ' ' ProjectTree.Add(sKey, (iLine + 1) & ":" & iCol, Picture["icon:/16/find"], sParent) ' ProjectTree[sKey][1] = sText ' ProjectTree[sParent].Expanded = TRUE ' ' INC $iFound ' ' END ' ' PUBLIC SUB SelectFound(sName AS String, iLine AS Integer, iCol AS Integer, iLen AS Integer) ' ' DIM sKey AS String ' ' sKey = FindKey(sName) ' IF NOT sKey THEN RETURN ' ' sKey = KEY_FIND & sKey & "@" & Format(iLine, "000000") & "." & Format(iCol, "00000") & "." & iLen ' TRY ProjectTree[sKey].Selected = TRUE ' ' END PUBLIC SUB LastPosition() DIM aPos AS String[] DIM iPos AS Integer WITH Positions IF .Count = 0 THEN RETURN aPos = Split(.Pop(), " ") ' IF aPos[0] = Path AND (Val(aPos[1]) = edtEditor.Line) AND (Val(aPos[2]) = edtEditor.Column) THEN ' LastPosition ' RETURN ' ENDIF 'PRINT "-> "; aPos.Join(" ") OpenFile(aPos[0]) Files[aPos[0]].GotoCenter(Val(aPos[1]), Val(aPos[2])) END WITH END PUBLIC SUB SavePosition() DIM hEditor AS FEditor DIM sPos AS String IF $bDoNotSavePosition THEN RETURN TRY hEditor = ActiveForm IF ERROR THEN RETURN sPos = hEditor.Path & " " & hEditor.Editor.Line & " " & hEditor.Editor.Column IF Positions.Count > 0 THEN IF Positions[Positions.Max] = sPos THEN RETURN ENDIF ENDIF Positions.Push(sPos) 'PRINT "Save: "; Project.Positions[Project.Positions.Count - 1] END PUBLIC SUB GetPicture(sPict AS String) AS Picture IF NOT sPict THEN RETURN IF sPict LIKE "icon:/*" THEN RETURN Picture[sPict] ELSE RETURN Picture.Load(Project.Dir &/ sPict) ENDIF END PUBLIC SUB HasTranslation(sLang AS String) AS Boolean RETURN Exist(Project.Dir &/ ".lang" &/ sLang & ".po") END PUBLIC SUB MakeDirectoryIcon(OPTIONAL sDir AS String) DIM sIcon AS String DIM hPict AS Picture DIM hIcon AS Image IF NOT sDir THEN sDir = Project.Dir IF Project.Icon THEN sIcon = sDir &/ Project.Icon ENDIF hPict = Image.Load("img/logo/icon-background.png").Picture Draw.Begin(hPict) IF sIcon THEN hIcon = Image.Load(sIcon).Stretch(32, 32) Draw.Image(hIcon, 6, 29) ENDIF Draw.Image(Image.Load("img/logo/corner.png"), 42, 45) Draw.End hPict.Save(sDir &/ ".icon.png") File.Save(sDir &/ ".directory", "[Desktop Entry]\nIcon=./.icon.png\n") END From joe1962 at ...626... Thu Oct 5 01:07:04 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 19:07:04 -0400 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <200610050047.40988.lordheavy@...512...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <200610050022.22369.lordheavy@...512...> <6c208f950610041532g256690a1o41fcf11869240ba7@...627...> <200610050047.40988.lordheavy@...512...> Message-ID: <6c208f950610041607i65191b34l605321ce1e92c100@...627...> On 10/4/06, Laurent Carlier wrote: > Le jeudi 5 octobre 2006 00:32, Jose J. Rodriguez a ?crit: > > On 10/4/06, Laurent Carlier wrote: > > > Le jeudi 5 octobre 2006 00:16, Jose J. Rodriguez a ?crit: > > > > Seems there really was a problem between Gmail and SourceForge mailing > > > > lists: http://it.slashdot.org/article.pl?sid=06/10/04/1324214&from=rss > > > > > > > > So I gather this post never made it before, repeating the email here: > > > > > > > > The Help menu wasn't working in 1.9.43 running on XFCE 4.4 RC1. It > > > > would work from the console, but not from the XFCE menu. I figured > > > > that the run environment from the menu wasn't setting the $BROWSER > > > > from my $HOME/.bashrc for some reason, the fix was to create a file > > > > (I called it env.sh) in /etc/profile.d (has to be set executable) to > > > > set $BROWSER. > > > > > > > > To Benoit: The setup for the Help browser does not show SeaMonkey, > > > > what is needed to get it on the list? > > > > > > > > Regards, > > > > Joe1962 > > > > > > What is the command line to launch it ? > > > > seamonkey %u > > > > Regards, > > Joe1962 > > > > Thks, will add it in the svn. > > test with the following files in app/src/gambas2 , if it work, i will commit > them. > Thanks! But... I'm getting an error when trying to open the gambas2 project in gambas2: Null Object Project.GetFileIcon.479 Seems I'm going to have to build gambas to test your changes, but that will have to be a bit later, or possibly tomorrow. Regards, Joe1962 From lordheavy at ...512... Thu Oct 5 01:11:30 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Thu, 5 Oct 2006 01:11:30 +0200 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <6c208f950610041607i65191b34l605321ce1e92c100@...627...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <200610050047.40988.lordheavy@...512...> <6c208f950610041607i65191b34l605321ce1e92c100@...627...> Message-ID: <200610050111.31045.lordheavy@...512...> Le jeudi 5 octobre 2006 01:07, Jose J. Rodriguez a ?crit?: > On 10/4/06, Laurent Carlier wrote: > > Le jeudi 5 octobre 2006 00:32, Jose J. Rodriguez a ?crit: > > > On 10/4/06, Laurent Carlier wrote: > > > > Le jeudi 5 octobre 2006 00:16, Jose J. Rodriguez a ?crit: > > > > > Seems there really was a problem between Gmail and SourceForge > > > > > mailing lists: > > > > > http://it.slashdot.org/article.pl?sid=06/10/04/1324214&from=rss > > > > > > > > > > So I gather this post never made it before, repeating the email > > > > > here: > > > > > > > > > > The Help menu wasn't working in 1.9.43 running on XFCE 4.4 RC1. It > > > > > would work from the console, but not from the XFCE menu. I figured > > > > > that the run environment from the menu wasn't setting the $BROWSER > > > > > from my $HOME/.bashrc for some reason, the fix was to create a file > > > > > (I called it env.sh) in /etc/profile.d (has to be set executable) > > > > > to set $BROWSER. > > > > > > > > > > To Benoit: The setup for the Help browser does not show SeaMonkey, > > > > > what is needed to get it on the list? > > > > > > > > > > Regards, > > > > > Joe1962 > > > > > > > > What is the command line to launch it ? > > > > > > seamonkey %u > > > > > > Regards, > > > Joe1962 > > > > Thks, will add it in the svn. > > > > test with the following files in app/src/gambas2 , if it work, i will > > commit them. > > Thanks! But... I'm getting an error when trying to open the gambas2 > project in gambas2: > > Null Object > Project.GetFileIcon.479 > Perhaps because the file i've post are from the svn ...... > Seems I'm going to have to build gambas to test your changes, but that > will have to be a bit later, or possibly tomorrow. > > Regards, > Joe1962 From joe1962 at ...626... Thu Oct 5 01:16:19 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 19:16:19 -0400 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <200610050111.31045.lordheavy@...512...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <200610050047.40988.lordheavy@...512...> <6c208f950610041607i65191b34l605321ce1e92c100@...627...> <200610050111.31045.lordheavy@...512...> Message-ID: <6c208f950610041616t32eb21e2o8cd66c4f228ea962@...627...> On 10/4/06, Laurent Carlier wrote: > Le jeudi 5 octobre 2006 01:07, Jose J. Rodriguez a ?crit: > > On 10/4/06, Laurent Carlier wrote: > > > Le jeudi 5 octobre 2006 00:32, Jose J. Rodriguez a ?crit: > > > > On 10/4/06, Laurent Carlier wrote: > > > > > Le jeudi 5 octobre 2006 00:16, Jose J. Rodriguez a ?crit: > > > > > > Seems there really was a problem between Gmail and SourceForge > > > > > > mailing lists: > > > > > > http://it.slashdot.org/article.pl?sid=06/10/04/1324214&from=rss > > > > > > > > > > > > So I gather this post never made it before, repeating the email > > > > > > here: > > > > > > > > > > > > The Help menu wasn't working in 1.9.43 running on XFCE 4.4 RC1. It > > > > > > would work from the console, but not from the XFCE menu. I figured > > > > > > that the run environment from the menu wasn't setting the $BROWSER > > > > > > from my $HOME/.bashrc for some reason, the fix was to create a file > > > > > > (I called it env.sh) in /etc/profile.d (has to be set executable) > > > > > > to set $BROWSER. > > > > > > > > > > > > To Benoit: The setup for the Help browser does not show SeaMonkey, > > > > > > what is needed to get it on the list? > > > > > > > > > > > > Regards, > > > > > > Joe1962 > > > > > > > > > > What is the command line to launch it ? > > > > > > > > seamonkey %u > > > > > > > > Regards, > > > > Joe1962 > > > > > > Thks, will add it in the svn. > > > > > > test with the following files in app/src/gambas2 , if it work, i will > > > commit them. > > > > Thanks! But... I'm getting an error when trying to open the gambas2 > > project in gambas2: > > > > Null Object > > Project.GetFileIcon.479 > > > > Perhaps because the file i've post are from the svn ...... > No, it happens even before replacing those files. Regards, Joe1962 From lordheavy at ...512... Thu Oct 5 01:22:38 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Thu, 5 Oct 2006 01:22:38 +0200 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <6c208f950610041616t32eb21e2o8cd66c4f228ea962@...627...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <200610050111.31045.lordheavy@...512...> <6c208f950610041616t32eb21e2o8cd66c4f228ea962@...627...> Message-ID: <200610050122.38358.lordheavy@...512...> Le jeudi 5 octobre 2006 01:16, Jose J. Rodriguez a ?crit?: > > > > > > Thanks! But... I'm getting an error when trying to open the gambas2 > > > project in gambas2: > > > > > > Null Object > > > Project.GetFileIcon.479 > > > > Perhaps because the file i've post are from the svn ...... > > No, it happens even before replacing those files. > > Regards, > Joe1962 > http://svn.sourceforge.net/viewvc/gambas?view=rev&revision=68 Perhaps your problem is fixed in 1.9.44 version. ++ From joe1962 at ...626... Thu Oct 5 01:29:17 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 19:29:17 -0400 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <200610050122.38358.lordheavy@...512...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <200610050111.31045.lordheavy@...512...> <6c208f950610041616t32eb21e2o8cd66c4f228ea962@...627...> <200610050122.38358.lordheavy@...512...> Message-ID: <6c208f950610041629k729ff9cel993d153bab919849@...627...> On 10/4/06, Laurent Carlier wrote: > Le jeudi 5 octobre 2006 01:16, Jose J. Rodriguez a ?crit: > > > > > > > > Thanks! But... I'm getting an error when trying to open the gambas2 > > > > project in gambas2: > > > > > > > > Null Object > > > > Project.GetFileIcon.479 > > > > > > Perhaps because the file i've post are from the svn ...... > > > > No, it happens even before replacing those files. > > > > Regards, > > Joe1962 > > > > http://svn.sourceforge.net/viewvc/gambas?view=rev&revision=68 > > Perhaps your problem is fixed in 1.9.44 version. > You're right, I'd better get busy downloading... ;). Regards, Joe1962 From joe1962 at ...626... Thu Oct 5 04:22:11 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Wed, 4 Oct 2006 22:22:11 -0400 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <6c208f950610041629k729ff9cel993d153bab919849@...627...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <200610050111.31045.lordheavy@...512...> <6c208f950610041616t32eb21e2o8cd66c4f228ea962@...627...> <200610050122.38358.lordheavy@...512...> <6c208f950610041629k729ff9cel993d153bab919849@...627...> Message-ID: <6c208f950610041922t5126c67cq1d2234f9abe2c52c@...627...> On 10/4/06, Jose J. Rodriguez wrote: > On 10/4/06, Laurent Carlier wrote: > > Le jeudi 5 octobre 2006 01:16, Jose J. Rodriguez a ?crit: > > > > > > > > > > Thanks! But... I'm getting an error when trying to open the gambas2 > > > > > project in gambas2: > > > > > > > > > > Null Object > > > > > Project.GetFileIcon.479 > > > > > > > > Perhaps because the file i've post are from the svn ...... > > > > > > No, it happens even before replacing those files. > > > > > > Regards, > > > Joe1962 > > > > > > > http://svn.sourceforge.net/viewvc/gambas?view=rev&revision=68 > > > > Perhaps your problem is fixed in 1.9.44 version. > > > > You're right, I'd better get busy downloading... ;). > OK, built 1.9.44 without your SeaMonkey fixes, then loaded 1.9.44 IDE project in it with your fixes (no more error :) ) and they work beautifully. You may commit... ;) though for correctness' sake, you might first want to use the official capitalization in the name SeaMonkey, not Seamonkey. Regards, Joe1962 From timothy.marshal-nichols at ...247... Thu Oct 5 09:07:40 2006 From: timothy.marshal-nichols at ...247... (Timothy Marshal-Nichols) Date: Thu, 5 Oct 2006 08:07:40 +0100 Subject: [Gambas-user] How to authenticate and switch to root userfromwithin gambas application? In-Reply-To: <6c208f950610040642w54c2e246t76edd216e927020e@...627...> Message-ID: <000001c6e84c$f7cfd830$66301b52@...1587...> > -----Original Message----- > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > bounces at lists.sourceforge.net] On Behalf Of Jose J. Rodriguez > Sent: 04 October 2006 14:43 > To: mailing list for gambas users > Subject: Re: [Gambas-user] How to authenticate and switch to root > userfromwithin gambas application? > > On 10/4/06, Timothy Marshal-Nichols > wrote: > > > > Hello > > > > Not sure how you can switch to being root user when the application is > > running. > > I need to check the source code of "su" I guess, see how it pulls off > this bit of magic. > > > But you could test if the current user is root and provide a > > warning message and also disable option only available to root: > > > > ' root user always has an Id of 0 > > IF User.Id = 0 THEN > > ' Disable options that can only be run by root > > Message.Info("Not root user - you would have a better > > message") > > END IF > > > > That's mostly what I do, except I check for username "root". Is it > safer to check for id = 0 because the name of root can be changed? I > never thought of that. You can change the name of the root user. Also some Linux distributions, especially those that try to emulate Window look and feel, sometime call the root user something like 'administrator' or 'admin'. Of course there is an error in the above code fragment. It should be: IF User.Id <> 0 THEN to take action if the current user id is not the root user id. > > > In KDE you can create desktop shortcuts and menu items that will run an > > application as root and prompt for the root password. > > > > Unfortunately, that's a KDE-specific .desktop file setting. It doesn't > work in XFCE. > > Regards, > Joe1962 > Thanks 8-) Timothy Marshal-Nichols From f.demarchi at ...1592... Thu Oct 5 09:16:18 2006 From: f.demarchi at ...1592... (Francesco De Marchi) Date: Thu, 05 Oct 2006 09:16:18 +0200 Subject: [Gambas-user] Maybe 2 errors in Gambas 1.9.43 In-Reply-To: <452386B4.3040100@...1592...> References: <45226148.7020009@...1237...> <452386B4.3040100@...1592...> Message-ID: <4524B142.9040303@...1592...> Francesco De Marchi ha scritto: > > Confirm this error. I have a 1.9.43 version and can not add an icon in > my application project kgbmencoder. :( > With the 1.9.44 release this error is resolve. Tnks a lot. Francesco De Marchi From lordheavy at ...512... Thu Oct 5 17:04:55 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Thu, 5 Oct 2006 17:04:55 +0200 Subject: [Gambas-user] Gambas Help problem with $BROWSER (just FYI, not Gambas' fault...) In-Reply-To: <6c208f950610041922t5126c67cq1d2234f9abe2c52c@...627...> References: <6c208f950610041516u6f95955dw8a8ec5283a5f14a0@...627...> <6c208f950610041629k729ff9cel993d153bab919849@...627...> <6c208f950610041922t5126c67cq1d2234f9abe2c52c@...627...> Message-ID: <200610051704.55850.lordheavy@...512...> Le jeudi 5 octobre 2006 04:22, Jose J. Rodriguez a ?crit?: > On 10/4/06, Jose J. Rodriguez wrote: > > On 10/4/06, Laurent Carlier wrote: > > > Le jeudi 5 octobre 2006 01:16, Jose J. Rodriguez a ?crit: > > > > > > Thanks! But... I'm getting an error when trying to open the > > > > > > gambas2 project in gambas2: > > > > > > > > > > > > Null Object > > > > > > Project.GetFileIcon.479 > > > > > > > > > > Perhaps because the file i've post are from the svn ...... > > > > > > > > No, it happens even before replacing those files. > > > > > > > > Regards, > > > > Joe1962 > > > > > > http://svn.sourceforge.net/viewvc/gambas?view=rev&revision=68 > > > > > > Perhaps your problem is fixed in 1.9.44 version. > > > > You're right, I'd better get busy downloading... ;). > > OK, built 1.9.44 without your SeaMonkey fixes, then loaded 1.9.44 IDE > project in it with your fixes (no more error :) ) and they work > beautifully. You may commit... ;) though for correctness' sake, you > might first want to use the official capitalization in the name > SeaMonkey, not Seamonkey. > > Regards, > Joe1962 > Thanks, fix done and commit to svn ! ++ From gambas at ...1... Thu Oct 5 19:13:51 2006 From: gambas at ...1... (Benoit Minisini) Date: Thu, 5 Oct 2006 19:13:51 +0200 Subject: [Gambas-user] how to extend a component? In-Reply-To: <45241D0B.1050908@...1593...> References: <45241D0B.1050908@...1593...> Message-ID: <200610051913.51601.gambas@...1...> On Wednesday 04 October 2006 22:43, Alexander Peters wrote: > Hello! > I?ve a little question, how can inherit a component like a textfield to > add new Features? > Is there a way or does i need to do this in the gambas source? > > Greetings > Alex P. > Can you be more precise in what you want to do exactly? -- Benoit Minisini From gambas at ...1... Thu Oct 5 19:14:25 2006 From: gambas at ...1... (Benoit Minisini) Date: Thu, 5 Oct 2006 19:14:25 +0200 Subject: [Gambas-user] Maybe 2 errors in Gambas 1.9.43 In-Reply-To: <45226148.7020009@...1237...> References: <45226148.7020009@...1237...> Message-ID: <200610051914.25830.gambas@...1...> On Tuesday 03 October 2006 15:10, Leonardo Miliani wrote: > Hi Benoit, > maybe I've found 2 bugs in Gambas 1.9.43. > Check them for sure.. > > > 1) > Even if I open an existing project or I have create a new one, if I > click on Project/Properties and try to change the program icon, I get > this error: > "This application has raised an unexpected > error and must abort. > [3] Stack overflow. > FSelectIcon.cmbSize_Click.77" > > I can confirm that it didn't exist on older versions because I have a > project that I'm working on that has the icon changed. > > 2) > I cannot translate any project I made with Gambas... > I work on the italian localization of Gambas and if I choose to > translate my project, Gambas tells me that it cannot find the italian > localization file, getting this error: > "Non riesco a leggere il file di traduzione per la lingua 'italiano > (Italia)' > > .Fatto." > > (in english, it means: "I can't read the translation file for the > language 'italian (Italy)'". > Same error if I try to add a language (in the example, I've tried to add > the english language). You can see in the screenshot I've sent that in > the combomenu (red arrow) I haven't any language that I can choose from.. Did 1.9.44 fix the error #2? -- Benoit Minisini From apeters at ...1593... Thu Oct 5 22:14:03 2006 From: apeters at ...1593... (Alexander Peters) Date: Thu, 05 Oct 2006 22:14:03 +0200 Subject: [Gambas-user] how to extend a component? In-Reply-To: <200610051913.51601.gambas@...1...> References: <45241D0B.1050908@...1593...> <200610051913.51601.gambas@...1...> Message-ID: <4525678B.70704@...1593...> Benoit Minisini schrieb: > On Wednesday 04 October 2006 22:43, Alexander Peters wrote: > >> Hello! >> I?ve a little question, how can inherit a component like a textfield to >> add new Features? >> Is there a way or does i need to do this in the gambas source? >> >> Greetings >> Alex P. >> >> > > Can you be more precise in what you want to do exactly? > > Hello Benoit, i want to create some database controls. Example: If i scroll in a Database Result i want that all Textfields show the values. I want to have some controls like the dbcontrols in Borland Delphi where i give a Textfield the Datasource and the Field to show and thats all. But this is future planing. I code (try it) the first week and if the controls allready can do this, please tell me how. I find it hard do fill the controls hardcoded the the values from my database. Greetings A. Peters Germany From apeters at ...1593... Thu Oct 5 22:15:38 2006 From: apeters at ...1593... (Alexander Peters) Date: Thu, 05 Oct 2006 22:15:38 +0200 Subject: [Gambas-user] how to extend a component? In-Reply-To: <200610042258.19157.lordheavy@...512...> References: <45241D0B.1050908@...1593...> <200610042258.19157.lordheavy@...512...> Message-ID: <452567EA.7010500@...1593...> Laurent Carlier schrieb: > Le mercredi 4 octobre 2006 22:43, Alexander Peters a ?crit : > >> Hello! >> I?ve a little question, how can inherit a component like a textfield to >> add new Features? >> Is there a way or does i need to do this in the gambas source? >> >> Greetings >> Alex P. >> >> > > First you can take a look in documentation like : > http://64.128.110.55/help/lang/inherits > > and take a look at gb.form component : > comp/src/gb.form (you can open it in the IDE) > > Regards, > > Hello Laurent, thanks for the link. I think thats all what i need. Greetings A. Peters From wdahn at ...1000... Fri Oct 6 06:09:46 2006 From: wdahn at ...1000... (Werner) Date: Fri, 06 Oct 2006 12:09:46 +0800 Subject: [Gambas-user] Observations on Message.Warning (1.9.43) Message-ID: <4525D70A.3080709@...1000...> Consider this: Dim i as Integer i = Message.Warning ("Are you sure you want to delete all the records in the database?" , "Cancel" , "Delete") The first button is apparently the default so if the user just hits Enter a 1 is returned. Cancel button returns 1 Delete button returns 2 So far, so good. But if the user does not click any button and just closes the window by clicking on the top right close square a 2 is also returned. How about in this case returning something this is not in the range of buttons say 0 or -1? Regards Werner Dahn From gambas at ...1... Fri Oct 6 18:10:00 2006 From: gambas at ...1... (Benoit Minisini) Date: Fri, 6 Oct 2006 18:10:00 +0200 Subject: [Gambas-user] how to extend a component? In-Reply-To: <4525678B.70704@...1593...> References: <45241D0B.1050908@...1593...> <200610051913.51601.gambas@...1...> <4525678B.70704@...1593...> Message-ID: <200610061810.00659.gambas@...1...> On Thursday 05 October 2006 22:14, Alexander Peters wrote: > Benoit Minisini schrieb: > > On Wednesday 04 October 2006 22:43, Alexander Peters wrote: > >> Hello! > >> I?ve a little question, how can inherit a component like a textfield to > >> add new Features? > >> Is there a way or does i need to do this in the gambas source? > >> > >> Greetings > >> Alex P. > > > > Can you be more precise in what you want to do exactly? > > Hello Benoit, > i want to create some database controls. Example: If i scroll in a > Database Result i want that all Textfields show the values. I want to > have some controls like the dbcontrols in Borland Delphi where i give a > Textfield the Datasource and the Field to show and thats all. > > But this is future planing. I code (try it) the first week and if the > controls allready can do this, please tell me how. I find it hard do > fill the controls hardcoded the the values from my database. > > Greetings > A. Peters > Germany > Did you try the gb.db.form component? -- Benoit Minisini From rospolosco at ...152... Fri Oct 6 19:04:24 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Fri, 6 Oct 2006 19:04:24 +0200 Subject: [Gambas-user] just a mail test - do not read Message-ID: <200610061904.25129.rospolosco@...152...> Test mail From gambas at ...1... Fri Oct 6 20:59:21 2006 From: gambas at ...1... (Benoit Minisini) Date: Fri, 6 Oct 2006 20:59:21 +0200 Subject: [Gambas-user] About sending keys to other windows Message-ID: <200610062059.21981.gambas@...1...> I have heard about a program named 'xte' on Gentoo that can insert keyboard and mouse events into the X11 server event queue. Then these events are dispatched to the windows as if the user has used its mouse or keyboard. It is based on a X11 extension named 'XTEST'. Alas I didn't find it on the net. If someone have any information about it, tell me! Thanks in advance. -- Benoit Minisini From rospolosco at ...152... Fri Oct 6 21:20:46 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Fri, 6 Oct 2006 21:20:46 +0200 Subject: [Gambas-user] About sending keys to other windows In-Reply-To: <200610062059.21981.gambas@...1...> References: <200610062059.21981.gambas@...1...> Message-ID: <200610062120.46449.rospolosco@...152...> Alle 20:59, venerd? 6 ottobre 2006, Benoit Minisini ha scritto: > I have heard about a program named 'xte' on Gentoo that can insert keyboard > and mouse events into the X11 server event queue. Then these events are > dispatched to the windows as if the user has used its mouse or keyboard. > > It is based on a X11 extension named 'XTEST'. > > Alas I didn't find it on the net. If someone have any information about it, > tell me! > > Thanks in advance. > > -- > Benoit Minisini Hi, Benoit. It seems that "xte" is part of "xautomation" package... http://hoopajoo.net/projects/xautomation.html Regards, Stefano Palmeri > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From Karl.Reinl at ...9... Fri Oct 6 22:12:01 2006 From: Karl.Reinl at ...9... (Charlie Reinl) Date: Fri, 06 Oct 2006 22:12:01 +0200 Subject: [Gambas-user] About sending keys to other windows In-Reply-To: <200610062059.21981.gambas@...1...> References: <200610062059.21981.gambas@...1...> Message-ID: <1160165522.5345.3.camel@...40...> Am Freitag, den 06.10.2006, 20:59 +0200 schrieb Benoit Minisini: > I have heard about a program named 'xte' on Gentoo that can insert keyboard > and mouse events into the X11 server event queue. Then these events are > dispatched to the windows as if the user has used its mouse or keyboard. > > It is based on a X11 extension named 'XTEST'. > > Alas I didn't find it on the net. If someone have any information about it, > tell me! > > Thanks in advance. > Salut , found somethig, look if thats the information you need Unless you know that you absolutely need it, disable the XTEST extension. Disabling XTEST eliminates a potential security loophole opened up by Step 5, whereby an authenticated user on the server could theoretically send key/mouse events into the server's local display. Even with XTEST disabled, it is generally a good idea to leave the server's local display logged out when not in use. Disabling XTEST is accomplished by passing an argument of -tst on the command line used to launch the X server. The location of this command line varies depending on the particular Linux distribution and display manager being used. The following table lists some common locations: found at VirtualGL User's Guide searched with 'XTest extension' the net. Amicalment Charlie From htakada at ...626... Sat Oct 7 00:21:01 2006 From: htakada at ...626... (Hugo) Date: Fri, 6 Oct 2006 18:21:01 -0400 Subject: [Gambas-user] cannot open project after instalation of gambas2(1.9.44) Message-ID: Hi everybody, After compilation of gambas2 1.9.44 on FedoraCore4 I get this error when I try to open my project: Cannot open project file: /path/goes/here/.. Null Object Project.GetFileIcon.479 is this a bug ? or am I doing something wrong? thanks for any advise Hugo From lordheavy at ...512... Sat Oct 7 00:37:01 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Sat, 7 Oct 2006 00:37:01 +0200 Subject: [Gambas-user] cannot open project after instalation of gambas2(1.9.44) In-Reply-To: References: Message-ID: <200610070037.02728.lordheavy@...512...> Le samedi 7 octobre 2006 00:21, Hugo a ?crit?: > Hi everybody, > After compilation of gambas2 1.9.44 on FedoraCore4 I get this error when I > try to open my project: > Cannot open project file: > /path/goes/here/.. > Null Object > Project.GetFileIcon.479 > > is this a bug ? or am I doing something wrong? > > thanks for any advise > > Hugo What was the previous version of gambas2 (which your project was created ?) Regards, From htakada at ...626... Sat Oct 7 00:41:03 2006 From: htakada at ...626... (Hugo) Date: Fri, 6 Oct 2006 18:41:03 -0400 Subject: [Gambas-user] cannot open project after instalation of gambas2(1.9.44) In-Reply-To: <200610070037.02728.lordheavy@...512...> References: <200610070037.02728.lordheavy@...512...> Message-ID: gambas2(1.9.42) On 10/6/06, Laurent Carlier wrote: > > Le samedi 7 octobre 2006 00:21, Hugo a ?crit: > > Hi everybody, > > After compilation of gambas2 1.9.44 on FedoraCore4 I get this error when > I > > try to open my project: > > Cannot open project file: > > /path/goes/here/.. > > Null Object > > Project.GetFileIcon.479 > > > > is this a bug ? or am I doing something wrong? > > > > thanks for any advise > > > > Hugo > > What was the previous version of gambas2 (which your project was created > ?) > > Regards, > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From htakada at ...626... Sat Oct 7 00:43:06 2006 From: htakada at ...626... (Hugo) Date: Fri, 6 Oct 2006 18:43:06 -0400 Subject: [Gambas-user] cannot open project after instalation of gambas2(1.9.44) In-Reply-To: References: <200610070037.02728.lordheavy@...512...> Message-ID: Actually, the project was created with gambas2(1.9.16 I believe) and was migrating from version to version till 1.9.44 regards Hugo On 10/6/06, Hugo wrote: > > gambas2(1.9.42) > > On 10/6/06, Laurent Carlier wrote: > > > > Le samedi 7 octobre 2006 00:21, Hugo a ?crit: > > > Hi everybody, > > > After compilation of gambas2 1.9.44 on FedoraCore4 I get this error > > when I > > > try to open my project: > > > Cannot open project file: > > > /path/goes/here/.. > > > Null Object > > > Project.GetFileIcon.479 > > > > > > is this a bug ? or am I doing something wrong? > > > > > > thanks for any advise > > > > > > Hugo > > > > What was the previous version of gambas2 (which your project was created > > ?) > > > > Regards, > > > > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > > your > > opinions on IT & business topics through brief surveys -- and earn cash > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > From lordheavy at ...512... Sat Oct 7 00:53:27 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Sat, 7 Oct 2006 00:53:27 +0200 Subject: [Gambas-user] cannot open project after instalation of gambas2(1.9.44) In-Reply-To: References: Message-ID: <200610070053.27474.lordheavy@...512...> Le samedi 7 octobre 2006 00:43, Hugo a ?crit?: > Actually, the project was created with gambas2(1.9.16 I believe) and was > migrating from version to version till 1.9.44 > > regards > > Hugo > > On 10/6/06, Hugo wrote: > > gambas2(1.9.42) > > > > On 10/6/06, Laurent Carlier wrote: > > > Le samedi 7 octobre 2006 00:21, Hugo a ?crit: > > > > Hi everybody, > > > > After compilation of gambas2 1.9.44 on FedoraCore4 I get this error > > > > > > when I > > > > > > > try to open my project: > > > > Cannot open project file: > > > > /path/goes/here/.. > > > > Null Object > > > > Project.GetFileIcon.479 > > > > > > > > is this a bug ? or am I doing something wrong? > > > > > > > > thanks for any advise > > > > > > > > Hugo > > > > > > What was the previous version of gambas2 (which your project was > > > created ?) > > > > > > Regards, > > > Can you open your project ? I see two possibilities : - you can, there is a menu entry under projet -> Update all forms, so save you project. - you can't, create a new project and copy in it all your datas, so as before, update all forms :) Regards, From gambas at ...1... Sat Oct 7 10:31:00 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 7 Oct 2006 10:31:00 +0200 Subject: [Gambas-user] cannot open project after instalation of gambas2(1.9.44) In-Reply-To: References: Message-ID: <200610071031.00697.gambas@...1...> On Saturday 07 October 2006 00:21, Hugo wrote: > Hi everybody, > After compilation of gambas2 1.9.44 on FedoraCore4 I get this error when I > try to open my project: > Cannot open project file: > /path/goes/here/.. > Null Object > Project.GetFileIcon.479 > > is this a bug ? or am I doing something wrong? > > thanks for any advise > > Hugo Project.GetFileIcon() associates an icon to a project file. It seems that it fails sometimes. Try this patch and tells me if it fails again or not. Regards, -- Benoit Minisini -------------- next part -------------- ' Gambas module file PUBLIC ProjectTree AS ColumnView PUBLIC ProjectMessage AS Label PUBLIC Workspace AS Workspace PUBLIC ActiveForm AS Object PUBLIC Path AS String PUBLIC Name AS String PUBLIC Dir AS String PUBLIC ReadOnly AS Boolean PUBLIC Title AS String PUBLIC Startup AS String PUBLIC Libraries AS String[] PUBLIC Arguments AS String[] PUBLIC CurrentArgument AS Integer PUBLIC KeepDebugInfo AS Boolean PUBLIC CreateShortcut AS Boolean PUBLIC ControlPublic AS Boolean PUBLIC MajorVersion AS Integer PUBLIC MinorVersion AS Integer PUBLIC ReleaseVersion AS Integer 'PUBLIC SnapToGrid AS Boolean 'PUBLIC ShowGrid AS Boolean PUBLIC Snap AS Integer PUBLIC Localize AS Boolean PUBLIC Description AS String PUBLIC Icon AS String PUBLIC Systems AS String[] PUBLIC Menus AS Collection PUBLIC Groups AS Collection PUBLIC Prefix AS Boolean PUBLIC TabSize AS Integer PUBLIC Version AS String PUBLIC ExecPath AS String PUBLIC Language AS String PUBLIC CreateComponent AS Boolean PUBLIC Stack AS Integer PUBLIC Authors AS String PUBLIC VersionProgram AS String PUBLIC Running AS Boolean PUBLIC Recent AS NEW String[] PRIVATE CONST MAX_RECENT AS Integer = 32 PUBLIC CONST FORM_MAGIC AS String = "# Gambas Form File 1.0" PUBLIC CONST PROJECT_MAGIC AS String = "# Gambas Project File 1.0" PUBLIC CONST DEFAULT_FONT AS String = "Monospace,10" PUBLIC Files AS NEW Collection PUBLIC AboutToQuit AS Boolean PUBLIC Positions AS NEW String[] PUBLIC CONST MAX_ICON_SIZE AS Integer = 8192 PUBLIC EXAMPLES_DIR AS String PUBLIC RPMBUILD_PROG AS String PUBLIC ShowAlwaysProperty AS Boolean PRIVATE CONST IMAGE_DIR AS String = "img/16" PRIVATE CONST KEY_MODULE AS String = "$M" PRIVATE CONST KEY_CLASS AS String = "$C" PUBLIC CONST KEY_FORM AS String = "$F" PUBLIC CONST KEY_MISC AS String = "$O" PUBLIC CONST KEY_FIND AS String = "$@" PRIVATE CONST CLASS_AUTH_CAR AS String = "abcdefghijklmnopqrstuvwxyz0123456789" PRIVATE CONST FILE_AUTH_CAR AS String = "abcdefghijklmnopqrstuvwxyz0123456789-.+_" PRIVATE CONST PROJECT_FILE AS String = ".project" 'PRIVATE $bGetSource AS Boolean 'PRIVATE $bDisplayForm AS Boolean PRIVATE TMP_FILE AS String '= "/tmp/.gambas.ver" PRIVATE OUTPUT_FILE AS String '= "/tmp/.gambas.out" PUBLIC Browser AS String PRIVATE $iFound AS Integer PRIVATE $bDoNotSavePosition AS Boolean PRIVATE $sOldRefreshLibrary AS String PUBLIC ExampleTitle AS NEW Collection PUBLIC ComponentFromType AS NEW Collection PUBLIC FormType AS NEW Collection PUBLIC TimeStamp AS Integer PRIVATE $aRefreshAfter AS NEW String[] PRIVATE $bNoRefresh AS Boolean PUBLIC SUB _init() ExampleTitle["Automation"] = ("Automation") ExampleTitle["Basic"] = ("Basic") ExampleTitle["Database"] = ("Database") ExampleTitle["Drawing"] = ("Drawing") ExampleTitle["Games"] = ("Games") ExampleTitle["Misc"] = ("Miscellaneous") ExampleTitle["Networking"] = ("Networking") ExampleTitle["OpenGL"] = ("OpenGL") ExampleTitle["Printing"] = ("Printing") ExampleTitle["Sound"] = ("Sound") ExampleTitle["Video"] = ("Video") END PUBLIC SUB Main() DIM sPath AS String DIM hGambas AS FGambas DIM iTest AS Integer Application.Theme = Settings["/Theme"] TMP_FILE = Temp$() OUTPUT_FILE = Temp$() 'CLASSES_FILE = Temp$() EXAMPLES_DIR = System.Path &/ "share/gambas" & System.Version & "/examples" 'Config = NEW Config '(User.Home &/ ".gambas") Application.Tooltip.Enabled = Settings["/ShowTooltip", TRUE] 'Application.Font = Font["10"] InitVersion LoadRecent FMain.Load FGambas.Load IF Application.Args.Count >= 2 THEN sPath = Application.Args[1] ENDIF DO IF NOT sPath THEN sPath = FWelcome.Run() 'sPath = User.Home &/ "gambas/test/gambas" IF sPath THEN Project.Open(sPath) ELSE FMain.Close RETURN ENDIF IF Project.Name THEN BREAK sPath = "" LOOP INC Application.Busy 'FProperty.Show 'FToolBox.Show 'FFormStack.Load IF Settings["/ShowMascot", TRUE] THEN FGambas.Show FMain.UpdateRecentMenu FMain.Show DEC Application.Busy IF Settings["/ShowTipOnStartup", TRUE] THEN FTips.Run ENDIF Project.Activate(NULL) END PRIVATE SUB InitVersion() DIM sVer AS String Version = "?" 'SHELL "gbx" & System.Version & " -V > " & TMP_FILE 'WAIT 'sVer = File.Load(TMP_FILE) 'KILL TMP_FILE SHELL "gbx" & System.Version & " -V" TO sVer Version = Trim(Mid$(sVer, InStr(sVer, "-") + 1)) END PUBLIC FUNCTION Open(sDir AS String) AS Boolean DIM sOldPath AS String DIM sOldName AS String IF NOT Exist(sDir &/ ".project") THEN FGambas.Error(("This project does not exist.") & "\n\n" & sDir) RETURN TRUE ENDIF sOldPath = Project.Path sOldName = Project.Name IF CloseProject() THEN RETURN TRUE IF Exist(sDir &/ ".lock") THEN IF Message.Warning(("This project seems to be already opened.\n\nOpening the same project twice can lead to data loss."), ("Open after all"), ("Do not open")) = 2 THEN RETURN TRUE ENDIF TRY KILL sDir &/ ".lock" ENDIF ReadOnly = NOT Access(sDir, gb.write) Path = sDir &/ PROJECT_FILE Name = File.Name(sDir) Project.Dir = sDir $bNoRefresh = TRUE ReadProject $bNoRefresh = FALSE Project.TimeStamp = 1 Refresh AddRecent(sDir) Positions.Clear FMain.OnProjectChange FFind.Hide 'FFind.OnProjectChange 'FExplorer.ProjectChange Design.Clear TRY File.Save(sDir &/ ".lock", "") IF ReadOnly THEN FGambas.Warning(("This project is read-only.")) SetMessage(("OK")) RETURN CATCH IF Error.Text THEN FGambas.Error(("Cannot open project file :\n") & sDir & "\n\n" & Error.Text & "\n" & Error.Where) ENDIF Path = sOldPath Project.Dir = File.Dir(Path) Name = sOldName IF Path THEN ReadProject RETURN TRUE END PUBLIC SUB CloseAll() DIM hForm AS Object FOR EACH hForm IN Files hForm.Close NEXT END PRIVATE FUNCTION CloseProject() AS Boolean DIM hForm AS Object DIM bModif AS Boolean 'IF Len(Path) = 0 THEN RETURN IF Running THEN Design.Stop 'WAIT 0.5 ENDIF FOR EACH hForm IN Files IF hForm.IsModified() THEN bModif = TRUE BREAK ENDIF NEXT IF bModif THEN IF FSave.Run(AboutToQuit) THEN RETURN TRUE ENDIF 'FFind.Close INC Application.Busy FOR EACH hForm IN Files hForm.Delete NEXT Files.Clear ActiveForm = NULL DEC Application.Busy IF NOT AboutToQuit THEN FProperty.HideAll FFormStack.HideAll ENDIF TRY KILL Project.Dir &/ ".lock" RETURN FALSE END PUBLIC FUNCTION Close() AS Boolean DIM hForm AS Form DIM iInd AS Integer DIM sLig AS String AboutToQuit = TRUE IF CloseProject() THEN AboutToQuit = FALSE RETURN TRUE ENDIF 'Design.Close 'FOR EACH hForm IN Windows ' TRY hForm.Close 'NEXT 'FOR EACH hForm IN Windows ' TRY hForm.Delete 'NEXT ' FToolBox.Delete ' FExplorer.Delete ' FFind.Delete ' FGambas.Delete ' FIconTool.Delete ' Design.Delete ' FProperty.Delete CComponent.Exit END PUBLIC SUB GetFileIcon(sPath AS String, OPTIONAL iSize AS Integer) AS Picture DIM hImage AS Image DIM hPict AS Picture DIM hStartup AS Picture DIM sKey AS String DIM bLink AS Boolean DIM sIcon AS String DIM sExt AS String DIM bStartup AS Boolean DIM iFileSize AS Long DIM hFile AS File DIM sPrefix AS String DIM bNoStartup AS Boolean DIM iDim AS Integer IF iSize THEN sPrefix = "icon:/" & iSize bNoStartup = iSize <> 16 ELSE sPrefix = "icon:/16" ENDIF WITH Stat(sPath) bLink = .Type = gb.Link IF .Type = gb.Directory THEN sIcon = sPrefix &/ "directory" IF NOT sIcon THEN sIcon = sPrefix &/ "file" sExt = File.Ext(sPath) SELECT CASE sExt CASE "form", "class", "module" IF File.Dir(sPath) = Project.Dir THEN IF iSize > 16 THEN sIcon = "img/32" &/ sExt & ".png" ELSE sIcon = "img/16" &/ sExt & ".png" ENDIF bStartup = File.BaseName(sPath) = Startup AND NOT bNoStartup ENDIF CASE "jpg", "jpeg", "xpm", "bmp", "png", "gif" IF bLink THEN hFile = OPEN sPath iFileSize = Lof(hFile) CLOSE hFile ELSE iFileSize = .Size ENDIF IF iFileSize > MAX_ICON_SIZE THEN sIcon = sPrefix &/ "image" ELSE sIcon = sPath ENDIF CASE "svg" sIcon = sPrefix &/ "image" CASE "htm", "html" sIcon = sPrefix &/ "html" CASE "txt", "text" sIcon = sPrefix &/ "text" END SELECT ENDIF END WITH IF Left$(sIcon) = "/" THEN TRY hImage = Image.Load(sIcon) IF hImage THEN IF iSize THEN hImage = hImage.Stretch(hImage.Width * iSize / hImage.Height, iSize, TRUE) ELSE iSize = 32 IF hImage.Height > iSize THEN hImage = hImage.Stretch(hImage.Width * iSize / hImage.Height, iSize, TRUE) ENDIF IF hImage.Width > iSize THEN hImage = hImage.Stretch(iSize, hImage.Height * iSize / hImage.Width, TRUE) ENDIF ENDIF hPict = hImage.Picture ELSE hPict = Picture[sPrefix &/ "image"].Copy() ENDIF IF bLink THEN Draw.Begin(hPict) Draw.Picture(Picture["img/16/link.png"], 0, hPict.Height - 16) Draw.End ENDIF ELSE sKey = sIcon IF bLink THEN sKey = File.BaseName(sKey) & "-link" IF bStartup THEN sKey = File.BaseName(sKey) & "-startup" hPict = NULL IF NOT bNoStartup THEN hPict = Picture[sKey] IF NOT hPict THEN hPict = Picture[sIcon] IF NOT hPict THEN hPict = Picture[sPrefix &/ "file"] hPict = hPict.Copy() IF bStartup THEN hStartup = NEW Picture(hPict.Width + 8, hPict.Height, TRUE) 'hStartup.Fill(Color.TextBackground) Draw.Begin(hStartup) Draw.Picture(hPict, 8, 0) Draw.Image(Image.Load("img/16/startup.png"), 0, 0) Draw.End 'hImage = hStartup.Image 'hImage.Replace(Color.TextBackground, Color.Transparent) hPict = hStartup ENDIF IF iSize THEN hPict = hPict.Image.Stretch(hPict.Width * iSize / hPict.Height, iSize, TRUE).Picture ENDIF IF bLink THEN Draw.Begin(hPict) Draw.Picture(Picture["img/16/link.png"], 0, hPict.Height - 16) Draw.End ENDIF IF NOT bNoStartup THEN Picture[sKey] = hPict ENDIF ENDIF RETURN hPict END PRIVATE SUB GetParentClass(sPath AS String) AS String DIM hFile AS File DIM sLine AS String hFile = OPEN sPath WHILE NOT Eof(hFile) LINE INPUT #hFile, sLine sLine = Trim(sLine) IF NOT sLine THEN CONTINUE IF Left(sLine) = "'" THEN CONTINUE IF sLine LIKE "INHERITS *" THEN 'Highlight.Analyze(sLine) 'RETURN Highlight.Symbols[1] sLine = Scan(sLine, "INHERITS *")[0] IF Comp(sLine, File.BaseName(sPath), gb.Text) = 0 THEN sLine = "" RETURN sLine ENDIF IF sLine LIKE "CREATE" THEN CONTINUE IF sLine LIKE "EXPORT" THEN CONTINUE BREAK WEND END PRIVATE SUB AddFile(sDir AS String, sFile AS String, OPTIONAL bAfter AS String, OPTIONAL bIgnoreInheritance AS Boolean) AS Boolean DIM bAllowForm AS Boolean DIM bIgnore AS Boolean DIM sPath AS String DIM sKey AS String DIM bShow AS Boolean DIM sExt AS String DIM sParent AS String DIM hImage AS Image DIM hPict AS Picture DIM bChecked AS Boolean DIM bDir AS Boolean DIM sAfter AS String DIM hForm AS Object bAllowForm = AllowForm() sPath = sDir &/ sFile sKey = sPath sParent = sDir IF sDir = Project.Dir THEN sParent = KEY_MISC ENDIF WITH Stat(sPath) IF .Hidden THEN RETURN bShow = FALSE IF .Type = gb.Directory THEN IF sFile = "CVS" THEN RETURN 'IF cDir THEN cDir.Add(sPath) bDir = TRUE 'sIcon = "icon:/16/directory" 'IMAGE_DIR &/ "close.png" bShow = TRUE ELSE 'IF InStr(.Perm.User & .Perm.Group & .Perm.Other, "x") THEN CONTINUE sExt = Lower(File.Ext(sFile)) bChecked = FALSE IF sDir = Project.Dir THEN SELECT CASE sExt CASE "form", "class", "module" 'sIcon = IMAGE_DIR &/ sExt & ".png" bShow = TRUE bChecked = TRUE IF sExt = "form" THEN sParent = KEY_FORM IF NOT bAllowForm THEN bIgnore = TRUE ELSE IF sExt = "class" THEN sParent = "" IF Exist(sDir &/ File.BaseName(sFile) & ".form") THEN bIgnore = TRUE ELSE 'IF sFile = "ReportContainer.class" THEN STOP sParent = FindKey(GetParentClass(sPath)) IF sParent THEN IF File.Ext(sParent) <> "class" THEN sParent = "" ELSE IF NOT ProjectTree.Exist(sParent) THEN IF NOT bIgnoreInheritance THEN $aRefreshAfter.Add(sPath) bIgnore = TRUE ELSE sParent = "" ENDIF ENDIF ENDIF ENDIF IF NOT sParent THEN sParent = KEY_CLASS ELSE IF sExt = "module" THEN sParent = KEY_MODULE ENDIF sFile = File.BaseName(sFile) END SELECT ENDIF IF NOT bChecked THEN bIgnore = sExt = "gambas" OR Right$(sFile) = "~" ENDIF ENDIF IF NOT bIgnore THEN hPict = GetFileIcon(sPath) IF bAfter THEN WITH ProjectTree .MoveTo(sParent) .MoveChild IF NOT bDir THEN WHILE .Available IF NOT IsDir(.Item.Key) THEN BREAK sAfter = .Item.Key .MoveNext WEND ENDIF WHILE .Available IF Comp(.Item.Text, sFile, gb.Text) > 0 THEN BREAK IF bDir AND IF NOT IsDir(.Item.Key) THEN BREAK sAfter = .Item.Key .MoveNext WEND END WITH ENDIF WITH ProjectTree.Add(sKey, sFile, hPict, sParent) .Editable = TRUE IF bAfter THEN .MoveAfter(sAfter) IF bShow THEN ProjectTree.MoveTo(sKey) ProjectTree.MoveParent ProjectTree.Item.Expanded = TRUE ENDIF END WITH hForm = Files[sKey] IF hForm THEN hForm.Icon = GetFileIcon(sKey, 16) IF sParent = KEY_FORM THEN hForm = Files[File.SetExt(sKey, "class")] IF hForm THEN hForm.Icon = GetFileIcon(sKey, 16) ENDIF ENDIF END WITH RETURN bDir END PRIVATE SUB DoRefreshAfter() DIM sKey AS String DIM iInd AS Integer DIM iCount AS Integer IF $aRefreshAfter.Count = 0 THEN RETURN DO iCount = $aRefreshAfter.Count FOR iInd = 0 TO iCount - 1 sKey = $aRefreshAfter[0] $aRefreshAfter.Remove(0) AddFile(File.Dir(sKey), File.Name(sKey), TRUE) NEXT IF $aRefreshAfter.Count >= iCount THEN BREAK LOOP IF $aRefreshAfter.Count THEN FOR iInd = 0 TO $aRefreshAfter.Max sKey = $aRefreshAfter[iInd] AddFile(File.Dir(sKey), File.Name(sKey), TRUE, TRUE) $aRefreshAfter[iInd] = File.BaseName(sKey) NEXT FGambas.Error(("The following classes have circular inheritance:") & "\n\n" & $aRefreshAfter.Join(", ")) $aRefreshAfter.Clear ENDIF END PRIVATE PROCEDURE AddDir(OPTIONAL sDir AS String) DIM cDir AS NEW String[] DIM sFile AS String DIM aFile AS NEW String[] IF sDir THEN cDir.Add(sDir) ELSE cDir.Add(Project.Dir) ENDIF REPEAT sDir = cDir[0] aFile.Clear '$bGetSource = FALSE FOR EACH sFile IN Dir(sDir, "*") IF IsDir(sDir &/ sFile) THEN aFile.Add("D" & sFile) NEXT FOR EACH sFile IN Dir(sDir, "*") IF NOT IsDir(sDir &/ sFile) THEN aFile.Add("F" & sFile) NEXT aFile.Sort $aRefreshAfter.Clear FOR EACH sFile IN aFile sFile = Mid$(sFile, 2) IF AddFile(sDir, sFile) THEN cDir.Add(sDir &/ sFile) NEXT DoRefreshAfter cDir.Remove(0) UNTIL cDir.Count = 0 END PUBLIC SUB SelectKey(sKey AS String) IF NOT ProjectTree.Exist(sKey) THEN IF Right$(sKey, 6) = ".class" THEN sKey = Left$(sKey, -6) & ".form" ENDIF ENDIF TRY ProjectTree[sKey].Selected = TRUE TRY ProjectTree[sKey].EnsureVisible END ' PRIVATE SUB UpdateInheritance() ' ' DIM sPath AS String ' DIM sParent AS String ' ' FOR EACH sPath IN Dir(Project.Dir, "*.class") ' ' IF Exist(Project.Dir &/ File.SetExt(sPath, "form")) THEN CONTINUE ' ' sParent = GetParentClass(sPath) ' IF sParent THEN ' sParent = FindKey(sParent) ' IF File.Ext(sParent) <> "class" THEN sParent = "" ' ENDIF ' ENDIF ' IF NOT sParent THEN ' sParent = KEY_CLASS ' ENDIF ' ' NEXT ' ' END PUBLIC PROCEDURE Refresh(OPTIONAL bReset AS Boolean) DIM sFile AS String DIM sDir AS String DIM sKey AS String DIM sKeyReset AS String '$bDisplayForm = Settings["/DisplayForm"] IF $bNoRefresh THEN RETURN IF NOT bReset THEN sKeyReset = ProjectTree.Key ENDIF WITH ProjectTree .Clear() sKey = Project.Dir .Add(sKey, Name, Picture["img/32/../16/gambas.png"]).Expanded = TRUE .Add(KEY_MODULE, ("Modules"), Picture["icon:/16/directory"], sKey) .Add(KEY_CLASS, ("Classes"), Picture["icon:/16/directory"], sKey) IF AllowForm() THEN .Add(KEY_FORM, ("Forms"), Picture["icon:/16/directory"], sKey) ENDIF .Add(KEY_MISC, ("Data"), Picture["icon:/16/directory"], sKey) '$bGetSource = TRUE AddDir() END WITH IF sKeyReset THEN sKey = sKeyReset TRY ProjectTree[sKey].EnsureVisible DefineStartup(Startup, TRUE) WITH ProjectTree .MoveFirst WHILE .Available .Current.Expanded = .Current.Children > 0 .MoveNext WEND END WITH 'STOP FMain.Title = Name & If(ReadOnly, " [" & ("Read only") & "]", "") & " - " & Application.Title END PUBLIC FUNCTION IsEditor(hFile AS Object) AS Boolean RETURN Object.Type(hFile) = "FEditor" END PUBLIC FUNCTION IsForm(hFile AS Object) AS Boolean IF hFile THEN RETURN Object.Type(hFile) = "FForm" END PUBLIC FUNCTION LoadFile(sPath AS String) AS Object DIM hForm AS Object 'DIM hActive AS Object INC Application.Busy hForm = Files[sPath] IF NOT hForm THEN 'PRINT "Load: "; sPath 'hActive = ActiveForm IF File.Dir(sPath) = Project.Dir THEN SELECT CASE File.Ext(sPath) CASE "module", "class" hForm = NEW FEditor(sPath) CASE "form" IF AllowForm() THEN hForm = NEW FForm(sPath) ENDIF END SELECT ENDIF IF NOT hForm THEN SELECT CASE Lower(File.Ext(sPath)) CASE "png", "gif", "jpg", "jpeg", "bmp", "xpm" hForm = NEW FIconEditor(sPath) CASE ELSE hForm = NEW FTextEditor(sPath) END SELECT ENDIF Files[sPath] = hForm hForm.Icon = GetFileIcon(sPath, 16) ENDIF DEC Application.Busy RETURN hForm CATCH DEC Application.Busy FGambas.Error(("Cannot open file.") & "\n\n" & Error.Text & "\n" & Error.Where) END PUBLIC FUNCTION FindPath(sClass AS String) AS String DIM sPath AS String DIM aDir AS String[] DIM iInd AS Integer aDir = Dir(Project.Dir) iInd = aDir.Find(sClass & ".class", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] iInd = aDir.Find(sClass & ".module", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] 'PRINT "FindPath: "; sClass; " ?" END PRIVATE SUB FindKey(sClass AS String) AS String DIM sPath AS String DIM aDir AS String[] DIM iInd AS Integer IF NOT sClass THEN RETURN aDir = Dir(Project.Dir) iInd = aDir.Find(sClass & ".form", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] iInd = aDir.Find(sClass & ".class", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] iInd = aDir.Find(sClass & ".module", gb.Text) IF iInd >= 0 THEN RETURN Project.Dir &/ aDir[iInd] END PUBLIC SUB ShowFile(hForm AS Form) SELECT CASE Object.Type(hForm) CASE "FEditor", "FTextEditor", "FIconEditor", "FForm" Workspace.Add(hForm) Workspace.ActiveWindow = hForm hForm.SetFocus ' CASE "FForm" ' Workspace.Add(hForm, TRUE) ' Workspace.SetResizable(hForm, TRUE, Project.Snap) ' Workspace.ActiveWindow = hForm END SELECT END PUBLIC SUB OpenFile(sPath AS String, OPTIONAL iLine AS Integer) DIM hForm AS Object IF InStr(sPath, "/") = 0 THEN sPath = FindPath(sPath) IF NOT Exist(sPath) THEN FGambas.Warning("File not found!") Project.Refresh RETURN ENDIF 'IF File.Ext(sPath) = "form" THEN ' FProperty.Show ' FToolBox.Show 'ENDIF LoadFile(sPath) hForm = Files[sPath] IF NOT hForm THEN RETURN ShowFile(hForm) 'hForm.Show 'IF Object.Type(hForm) = "FEditor" THEN ' hForm.Editor.SetFocus 'ENDIF IF iLine THEN hForm.GotoCenter(iLine - 1, 0) ENDIF END PUBLIC FUNCTION ExistForm(sClass AS String) AS Boolean RETURN Dir(Project.Dir, "*.form").Find(sClass & ".form", gb.Text) >= 0 END PUBLIC SUB FindForm(sClass AS String) AS FForm DIM sPath AS String sPath = Project.Dir &/ sClass & ".form" IF Exist(sPath) THEN RETURN LoadFile(sPath) END PUBLIC SUB OpenForm(sName AS String) DIM sPath AS String sPath = Project.Dir &/ sName & ".form" IF Exist(sPath) THEN OpenFile(sPath) END PRIVATE FUNCTION AddMessage(sVoid AS String) AS String DIM hFic AS File DIM sLig AS String IF Stat(OUTPUT_FILE).Size = 0 THEN SetMessage(sVoid) RETURN ELSE OPEN OUTPUT_FILE FOR READ AS #hFic WHILE NOT Eof(hFic) LINE INPUT #hFic, sLig 'ProjectMessage.Add(sLig) WEND CLOSE #hFic ENDIF 'ProjectMessage.Index = ProjectMessage.Count - 1 'SetMessage(sLig) RETURN sLig END PRIVATE SUB CompileError(sMsg AS String) DIM iPos AS Integer DIM sFile AS String DIM iLine AS Integer iPos = InStr(sMsg, ":") 'if iPos = 0 then return sFile = Left$(sMsg, iPos - 1) sMsg = Mid$(sMsg, iPos + 1) iPos = InStr(sMsg, ":") 'if iPos = 0 then return iLine = Val(Left$(sMsg, iPos - 1)) 'if iLine = 0 then return sFile = File.Dir(Path) &/ File.Name(sFile) SetMessage(File.BaseName(sFile) & "." & CStr(iLine) & ": " & Trim(Mid$(sMsg, iPos + 1))) OpenFile(sFile, iLine) sMsg = Trim(Mid$(sMsg, iPos + 1)) & "\n" & Subst(("at line &1 in &2"), CStr(iLine), File.Name(sFile)) IF FGambas.Visible THEN FGambas.Animate("Depressive", sMsg) ELSE Message.Warning(sMsg) ENDIF OpenFile(sFile, iLine) CATCH END PUBLIC FUNCTION Quote(sPath AS String) AS String DIM sQuote AS String DIM iInd AS Integer DIM sCar AS String sPath = SConv$(sPath) 'DEBUG sPath FOR iInd = 1 TO Len(sPath) sCar = Mid$(sPath, iInd, 1) IF InStr("0123456789abcdefghijklmnopqrstuvwxyz.-/_~", LCase(sCar)) = 0 THEN sCar = "\\" & sCar ENDIF sQuote = sQuote & sCar NEXT RETURN sQuote END PUBLIC FUNCTION Escape(sStr AS String) AS String DIM sRes AS String DIM iInd AS Integer DIM sCar AS String DIM iPos AS Integer FOR iInd = 1 TO Len(sStr) sCar = Mid$(sStr, iInd, 1) iPos = InStr("'\"\\\n\r\t", sCar) IF iPos THEN sCar = "\\" & Mid$("'\"\\nrt", iPos, 1) sRes = sRes & sCar NEXT RETURN sRes END PUBLIC SUB Process_Read() DIM sLig AS String LINE INPUT #LAST, sLig PRINT sLig END PUBLIC SUB DeleteCompiledFiles() DIM sFile AS String EXEC ["rm", "-rf", Project.Dir &/ ".gambas"] WAIT IF Exist(Project.Dir &/ ".lang") THEN FOR EACH sFile IN Dir(Project.Dir &/ ".lang", "*.pot") TRY KILL Project.Dir &/ ".lang" &/ sFile NEXT ENDIF END PUBLIC FUNCTION GetCompileCommand(bAll AS Boolean, bNoDebug AS Boolean, bIDE AS Boolean) AS String DIM sExec AS String sExec = System.Path &/ "bin/gbc" & System.Version & " " IF bAll THEN sExec = sExec & "-a " IF NOT bNoDebug THEN sExec = sExec & "-g " IF Localize THEN sExec = sExec & "-t " IF ControlPublic THEN sExec = sExec & "-p " 'sExec = sExec & "-c " & Quote(CLASSES_FILE) & " " & Quote(Project.Dir) & " > " & OUTPUT_FILE & " 2>&1" IF bIDE THEN sExec = sExec & Quote(Project.Dir) sExec = sExec & " > " & OUTPUT_FILE & " 2>&1" ENDIF RETURN sExec END PUBLIC FUNCTION Compile(OPTIONAL bAll AS Boolean, OPTIONAL bNoDebug AS Boolean) AS Boolean DIM sExec AS String DIM sRes AS String DIM sDir AS String DIM sPath AS String DIM iPos AS Integer DIM sTrans AS String IF Project.ReadOnly THEN RETURN IF Project.Running THEN RETURN 'TRUE IF LockIt() THEN RETURN TRUE sDir = Project.Dir FProperty.SaveProperty Save SetMessage(("Compiling project") & " " & Project.Name & "...") IF bAll THEN CleanUpProject DeleteCompiledFiles WriteProject(TRUE) ENDIF sExec = GetCompileCommand(bAll, bNoDebug, TRUE) SHELL sExec WAIT 'Stat(OUTPUT_FILE) sRes = AddMessage(("Nothing to do.")) IF sRes THEN IF sRes <> "OK" THEN UnlockIt() CompileError(sRes) RETURN TRUE ELSE IF Localize THEN TRY MKDIR sDir &/ ".lang" sPath = sDir &/ ".lang/.pot" SHELL "msgcat " & Quote(sDir) &/ ".lang/*.pot > " & Quote(sPath) & " 2>/dev/null" WAIT sTrans = File.Load(sPath) iPos = InStr(sTrans, "#,") IF iPos THEN sTrans = Mid$(sTrans, iPos) File.Save(sDir &/ ".lang/.pot", sTrans) ENDIF SetMessage(("OK")) FGambas.Animate("Happy") ENDIF ENDIF UnlockIt() END PRIVATE FUNCTION CheckRunning(OPTIONAL bCompileAll AS Boolean) AS Boolean IF Project.Running THEN RETURN IF Compile(bCompileAll) THEN RETURN TRUE IF CheckStartupClass() THEN RETURN TRUE END PUBLIC SUB Run(OPTIONAL bCompileAll AS Boolean, OPTIONAL iDebug AS Integer) IF CheckRunning(bCompileAll) THEN RETURN IF iDebug = 1 THEN Design.Step ELSE IF iDebug = 2 THEN Design.Forward ELSE IF iDebug = 3 THEN Design.ReturnFrom ELSE Design.Run ENDIF END PUBLIC SUB Forward() IF CheckRunning() THEN RETURN Design.Forward END PUBLIC SUB ReturnFrom() IF CheckRunning() THEN RETURN Design.ReturnFrom END PUBLIC SUB RunUntil(hForm AS FEditor, iLine AS Integer) IF CheckRunning() THEN RETURN Design.RunUntil(hForm, iLine) END PUBLIC SUB Step() IF Compile() THEN RETURN IF CheckStartupClass() THEN RETURN Design.Step END PUBLIC SUB Save() DIM hForm AS Object INC Application.Busy FOR EACH hForm IN Files IF Object.Type(hForm) = "FEditor" THEN IF hForm.Save(TRUE) THEN BREAK ELSE IF hForm.Save() THEN BREAK ENDIF NEXT DEC Application.Busy END PUBLIC SUB Insert(sName AS String, sType AS String, OPTIONAL sTemplate AS String, OPTIONAL bNoRefresh AS Boolean, OPTIONAL bNoOpen AS Boolean, OPTIONAL bLink AS Boolean) DIM sPath AS String DIM sData AS String sPath = Project.Dir &/ File.BaseName(sName) & "." & sType IF Exist(sPath) THEN FGambas.Warning(("File already exists.")) RETURN ENDIF IF bLink THEN LINK sPath TO sTemplate ELSE IF Left(sTemplate) = "/" THEN TRY COPY sTemplate TO sPath ELSE File.Save(sPath, sTemplate) ENDIF IF NOT bNoRefresh THEN Refresh IF NOT bNoOpen THEN OpenFile(sPath) END PUBLIC SUB InsertFile(sName AS String, sDir AS String, OPTIONAL sTemplate AS String, OPTIONAL bNoOpen AS Boolean, OPTIONAL bLink AS Boolean) DIM sPath AS String DIM sData AS String sPath = sDir &/ sName IF Len(sTemplate) THEN IF Exist(sPath) THEN FGambas.Warning(("File already exists.")) RETURN ENDIF 'SHELL "cp " & Quote(sTemplate) & " " & Quote(sPath) WAIT IF bLink THEN TRY LINK sPath TO sTemplate ELSE TRY COPY sTemplate TO sPath ENDIF IF NOT Exist(sPath) THEN FGambas.Error(("Cannot copy template file.") & "\n\n" & Error.Text) RETURN ENDIF ENDIF Refresh 'RefreshLibrary IF NOT bNoOpen THEN OpenFile(sPath) END PUBLIC SUB InsertDirectory(sPath AS String) IF Exist(sPath) THEN FGambas.Warning(("Directory already exists.")) RETURN ENDIF MKDIR sPath RefreshKey(sPath) END PUBLIC SUB Activate(hForm AS Object) DIM sType AS String DIM bEditor AS Boolean DIM bTextEditor AS Boolean IF AboutToQuit THEN RETURN IF hForm THEN SelectKey(hForm.Path) IF ActiveForm = hForm THEN RETURN 'ELSE 'IF NOT ActiveForm THEN RETURN ENDIF ActiveForm = hForm IF NOT ActiveForm THEN FProperty.HideAll FFormStack.HideAll FMain.ShowTool(FALSE) sType = "" ELSE FProperty.RefreshAll FFormStack.RefreshAll sType = Object.Type(ActiveForm) FMain.ShowTool(sType = "FForm" OR ShowAlwaysProperty) ENDIF bEditor = sType = "FEditor" bTextEditor = sType = "FTextEditor" Action["break"].Visible = bEditor Action["watch"].Visible = bEditor Action["until"].Visible = bEditor Action["find-comment"].Visible = NOT bTextEditor Action["find-in"].Visible = bEditor Action["find-previous"].Visible = bEditor OR bTextEditor Action["find-next"].Visible = bEditor OR bTextEditor Action["replace"].Visible = bEditor OR bTextEditor 'Action["replace-all"].Visible = bEditor OR bTextEditor END PUBLIC SUB Deactivate(hForm AS Object) IF ActiveForm <> hForm THEN RETURN 'DEBUG hForm 'DEBUG "DeActivate: "; hForm.Title SELECT CASE Object.Type(hForm) CASE "FForm" FProperty.HideAll FFormStack.HideAll 'FProperty.Hide ' FToolBox.Hide END SELECT END ' PUBLIC FUNCTION NewProject(sDir AS String, OPTIONAL aOption AS String[]) AS Boolean ' ' DIM sName AS String ' DIM iInd AS Integer ' DIM sPath AS String ' DIM sOption AS String ' ' sName = File.Name(sDir) ' ' MKDIR sDir ' sPath = sDir &/ PROJECT_FILE ' IF aOption THEN sOption = aOption.Join("\n") ' File.Save(sPath, PROJECT_MAGIC & "\nProject=" & sName & "\n" & sOption) ' ' 'BrowseForm.AddProject(sDir) ' ' RETURN ' ' CATCH ' ' FGambas.Error(("Cannot create project!") & "\n\n" & Error.Text) ' RETURN TRUE ' ' END PUBLIC FUNCTION CopyProject(sSrc AS String, sDst AS String) AS Boolean DIM sName AS String DIM iInd AS Integer DIM sPath AS String DIM sOut AS String sOut = Temp$ SHELL "cp -r " & Quote(sSrc) & " " & Quote(sDst) & " 2> " & Quote(sOut) WAIT sOut = File.Load(sOut) IF sOut THEN Error.Raise(sOut) RETURN CATCH Message.Warning(("Cannot copy project!") & "\n\n" & Error.Text) RETURN TRUE END PRIVATE SUB GetVersion() DIM sVer AS String DIM aVer AS String[] DIM iMajor AS Integer DIM iMinor AS Integer DIM iRelease AS Integer IF NOT VersionProgram THEN RETURN SHELL VersionProgram TO sVer aVer = Split(Trim(sVer), ".") iMajor = aVer[0] iMinor = aVer[1] TRY iRelease = aVer[2] MajorVersion = iMajor MinorVersion = iMinor IF iRelease THEN ReleaseVersion = iRelease CATCH DEBUG "Unable to get version from: "; VersionProgram END PUBLIC FUNCTION MakeExecutable(OPTIONAL bDoNotIncVersion AS Boolean, OPTIONAL bSilent AS Boolean) AS Boolean DIM sExec AS String DIM sPath AS String IF CheckStartupClass() THEN RETURN TRUE sPath = Project.Dir &/ Project.Name & ".gambas" IF NOT bSilent THEN IF Exist(File.Dir(ExecPath)) THEN sPath = ExecPath 'IF Dialog.SaveFile() THEN RETURN TRUE sPath = FMakeExecutable.Run(sPath) IF NOT sPath THEN RETURN ExecPath = File.SetExt(sPath, "gambas") ENDIF EXEC ["rm", "-rf", Project.Dir &/ ".gambas.save"] WAIT TRY MOVE Project.Dir &/ ".gambas" TO Project.Dir &/ ".gambas.save" IF Compile(TRUE, NOT KeepDebugInfo) THEN RETURN TRUE SetMessage(("Making executable...")) GetVersion() sExec = System.Path &/ "bin/gba" & System.Version & " -o " & Project.Quote(ExecPath) & " " & Project.Quote(Project.Dir) & " > " & OUTPUT_FILE & " 2>&1" SHELL sExec WAIT SetMessage(("OK")) 'Compile(TRUE, FALSE) EXEC ["rm", "-rf", Project.Dir &/ ".gambas"] WAIT TRY MOVE Project.Dir &/ ".gambas.save" TO Project.Dir &/ ".gambas" IF NOT bDoNotIncVersion THEN INC ReleaseVersion WriteProject(TRUE, TRUE) 'MakeShortcut(TRUE) END PUBLIC FUNCTION GetClasses(OPTIONAL bFullPath AS Boolean) AS String[] DIM sFile AS String DIM aModule AS NEW String[] DIM aClass AS NEW String[] DIM bStop AS Boolean FOR EACH sFile IN Dir(Project.Dir, "*.module") IF bFullPath THEN aModule.Add(Project.Dir &/ sFile) ELSE aModule.Add(File.BaseName(sFile)) ENDIF NEXT aModule.Sort FOR EACH sFile IN Dir(Project.Dir, "*.class") IF bFullPath THEN aClass.Add(Project.Dir &/ sFile) ELSE aClass.Add(File.BaseName(sFile)) ENDIF NEXT aClass.Sort aModule.Insert(aClass) IF NOT bFullPath THEN aModule.Sort RETURN aModule END PUBLIC SUB ReadProject() DIM hFic AS File DIM sLig AS String DIM iPos AS Integer DIM sKey AS String DIM sVal AS String DIM cVer AS String[] DIM sElt AS String DIM iElt AS Integer DIM aMissing AS NEW String[] DIM sMsg AS String Libraries = NEW String[] Title = "" TabSize = Settings["/DefaultTabSize", 2] Arguments = NEW String[] CurrentArgument = 0 MajorVersion = 0 MinorVersion = 0 ReleaseVersion = 1 'SnapToGrid = TRUE 'ShowGrid = TRUE Snap = Desktop.Scale 'Settings["/DefaultGridResolution", 8] ControlPublic = FALSE KeepDebugInfo = FALSE Localize = FALSE Description = "" Authors = "" Icon = "" Systems = NEW String[] Menus = NEW Collection Groups = NEW Collection Prefix = FALSE ExecPath = Project.Dir &/ Project.Name & ".gambas" CreateComponent = FALSE CreateShortcut = FALSE Language = "" VersionProgram = "" Stack = 0 hFic = OPEN Path FOR READ WHILE NOT Eof(hFic) LINE INPUT #hFic, sLig sLig = Trim(sLig) IF Len(sLig) = 0 THEN CONTINUE IF Left$(sLig, 1) = "#" THEN CONTINUE iPos = InStr(sLig, "=") IF iPos = 0 THEN CONTINUE sKey = Lower$(Trim(Left$(sLig, iPos - 1))) sVal = Trim(Mid$(sLig, iPos + 1)) SELECT sKey CASE "title" Title = sVal CASE "startup" DefineStartup(sVal, TRUE) CASE "library" IF CComponent.All.Exist(sVal) THEN Libraries.Add(sVal) ELSE aMissing.Add(sVal) ENDIF CASE "tabsize" TabSize = Val(sVal) CASE "argument" Arguments.Add(Replace(sVal, "\\n", "\n")) CASE "currentargument" CurrentArgument = Val(sVal) CASE "version" cVer = Split(sVal, ".") TRY MajorVersion = Val(cVer[0]) TRY MinorVersion = Val(cVer[1]) TRY ReleaseVersion = Val(cVer[2]) CASE "versionprogram" VersionProgram = sVal CASE "localize", "translate" Localize = Val(sVal) <> 0 CASE "language" Language = sVal CASE "keepdebuginfo" KeepDebugInfo = Val(sVal) <> 0 CASE "createshortcut" CreateShortcut = Val(sVal) <> 0 CASE "makecomponent" CreateComponent = Val(sVal) <> 0 CASE "controlpublic" ControlPublic = Val(sVal) <> 0 CASE "description" Description = Replace(sVal, "\\n", "\n") CASE "authors" Authors = Replace(sVal, "\\n", "\n") CASE "icon" Icon = sVal CASE "systems" Systems = Split(sVal, ",") CASE "menus" iElt = 0 FOR EACH sElt IN Split(sVal, ",") IF iElt >= Systems.Count THEN BREAK Menus[Systems[iElt]] = sElt INC iElt NEXT CASE "groups" iElt = 0 FOR EACH sElt IN Split(sVal, ",") IF iElt >= Systems.Count THEN BREAK Groups[Systems[iElt]] = sElt INC iElt NEXT CASE "prefix" Prefix = Val(sVal) CASE "execpath" ExecPath = sVal CASE "stack" Stack = Val(sVal) END SELECT WEND CLOSE hFic IF aMissing.Count THEN sMsg = Subst(("Some components are missing: &1"), aMissing.Join(", ")) IF Message.Error(sMsg, ("Continue"), ("Cancel")) = 2 THEN Error.Raise("") ENDIF ENDIF FMain.UpdateTranslate FMain.UpdateRunWithMenu RefreshLibrary END PUBLIC SUB WriteProject(OPTIONAL bComponentDoNotChange AS Boolean, OPTIONAL bMakeShortcut AS Boolean) DIM hFic AS File DIM sLib AS String DIM sSys AS String DIM sElt AS String DIM sPath AS String DIM sArg AS String DIM iKey AS Integer DIM iCount AS Integer DIM hComp AS CComponent DIM sShortcut AS String IF Project.ReadOnly THEN RETURN hFic = OPEN Path & ".tmp" FOR CREATE PRINT #hFic, PROJECT_MAGIC 'PRINT #hFic, "Project="; Name IF Title THEN PRINT #hFic, "Title="; Title IF Startup THEN PRINT #hFic, "Startup="; Startup IF Stack THEN PRINT #hFic, "Stack="; Stack IF Icon THEN PRINT #hFic, "Icon="; Icon PRINT #hFic, "Version="; CStr(MajorVersion) & "." & CStr(MinorVersion) & "." & CStr(ReleaseVersion) IF VersionProgram THEN PRINT #hFic, "VersionProgram="; VersionProgram FOR EACH hComp IN CComponent.All IF Libraries.Find(hComp.Key) >= 0 THEN PRINT #hFic, "Library="; hComp.Key ENDIF NEXT IF Description THEN PRINT #hFic, "Description="; Replace(Description, "\n", "\\n") IF Authors THEN PRINT #hFic, "Authors="; Replace(Authors, "\n", "\\n") FOR EACH sArg IN Arguments PRINT #hFic, "Argument="; Replace(sArg, "\n", "\\n") NEXT IF CurrentArgument THEN PRINT #hFic, "CurrentArgument="; CurrentArgument PRINT #hFic, "TabSize="; CStr(TabSize) IF Localize THEN PRINT #hFic, "Translate=1" IF Language THEN PRINT #hFic, "Language="; Language IF KeepDebugInfo THEN PRINT #hFic, "KeepDebugInfo=1" IF CreateShortcut THEN PRINT #hFic, "CreateShortcut=1" IF CreateComponent THEN PRINT #hFic, "MakeComponent=1" IF ControlPublic THEN PRINT #hFic, "ControlPublic=1" IF ExecPath <> (Project.Dir &/ Project.Name & ".gambas") THEN PRINT #hFic, "ExecPath="; ExecPath ENDIF IF Systems.Count THEN PRINT #hFic, "Systems="; Systems.Join(",") sElt = "" FOR EACH sSys IN Systems sElt = sElt & "," & Menus[sSys] NEXT PRINT #hFic, "Menus="; Mid$(sElt, 2) sElt = "" FOR EACH sSys IN Systems sElt = sElt & "," & Groups[sSys] NEXT PRINT #hFic, "Groups="; Mid$(sElt, 2) ENDIF IF Prefix THEN PRINT #hFic, "Prefix=1" CLOSE #hFic KILL Path MOVE Path & ".tmp" TO Path sPath = Project.Dir &/ ".lang/#project.pot" TRY KILL sPath IF Localize THEN TRY MKDIR File.Dir(sPath) OPEN sPath FOR CREATE AS #hFic PRINT #hFic, "# "; Path PRINT #hFic, File.Load("pot-header.txt") IF Title THEN PRINT #hFic, "#: .project:1" PRINT #hFic, "msgid \""; Escape(Title); "\"" PRINT #hFic, "msgstr \"\"\n" ENDIF IF Description THEN PRINT #hFic, "#: .project:2" PRINT #hFic, "msgid \""; Escape(Description); "\"" PRINT #hFic, "msgstr \"\"\n" ENDIF CLOSE #hFic ENDIF IF CreateComponent IF Project.CreateShortcut THEN IF bMakeShortcut THEN InstallComponent ELSE UninstallComponent ENDIF ELSE MakeShortcut(bMakeShortcut) ENDIF IF NOT bComponentDoNotChange THEN RefreshLibrary FMain.UpdateTranslate CATCH FGambas.Error(("Cannot write project file.") & "\n\n" & Error.Text) END PUBLIC SUB MakeShortcut(OPTIONAL bForce AS Boolean) DIM sPath AS String DIM sShortcut AS String IF NOT CreateShortcut THEN RETURN sPath = "~/Desktop" &/ Name & ".desktop" IF NOT bForce THEN IF NOT Exist(sPath) THEN RETURN ENDIF sShortcut = File.Load("shortcut.desktop") sShortcut = Replace(sShortcut, "$(NAME)", If(Title, Title, Name)) sShortcut = Replace(sShortcut, "$(EXEC)", ExecPath) sPath = "" IF Icon AND IF Exist(Project.Dir &/ Icon) THEN sPath = Project.Dir &/ Icon ENDIF sShortcut = Replace(sShortcut, "$(ICON)", sPath) File.Save("~/Desktop" &/ Name & ".desktop", sShortcut) CATCH FGambas.Error(("Unable to create desktop shortcut.") & "\n\n" & Error.Text & "\n" & Error.Where) END PUBLIC SUB MakeDir(sDir AS String) AS Boolean DIM sPath AS String DIM sElt AS String FOR EACH sElt IN Split(sDir, "/") sPath &/= sElt TRY MKDIR "/" & sPath NEXT IF NOT Exist(sDir) OR IF NOT IsDir(sDir) THEN RETURN TRUE END PRIVATE SUB MakeLink(sSrc AS String, sDst AS String) IF NOT Exist(sSrc) THEN LINK sSrc TO sDst END PUBLIC SUB InstallComponent() DIM sDir AS String = Component.UserPath MakeDir(sDir) MakeLink(sDir &/ Name & ".gambas", Project.ExecPath) MakeLink(sDir &/ Name & ".component", Project.Dir &/ ".component") sDir = File.Dir(File.Dir(sDir)) &/ "share/gambas" & System.Version & "/info" MakeDir(sDir) MakeLink(sDir &/ Name & ".info", Project.Dir &/ ".info") MakeLink(sDir &/ Name & ".list", Project.Dir &/ ".list") CATCH FGambas.Error(("Unable to install component.") & "\n\n" & Error.Text & "\n" & Error.Where) END PUBLIC SUB UninstallComponent() DIM sDir AS String = Component.UserPath 'MakeDir(sDir) TRY KILL sDir &/ Name & ".gambas" TRY KILL sDir &/ Name & ".component" sDir = File.Dir(File.Dir(sDir)) &/ "share/gambas" & System.Version & "/info" TRY KILL sDir &/ Name & ".info" TRY KILL sDir &/ Name & ".list" CATCH FGambas.Error(("Unable to uninstall component.") & "\n\n" & Error.Text & "\n" & Error.Where) END PUBLIC FUNCTION GetNextEditor(sKey AS String) AS String DIM sFirst AS String DIM sFile AS String DIM bNext AS Boolean IF NOT sKey THEN bNext = TRUE FOR EACH sFile IN GetClasses(TRUE) IF bNext THEN RETURN sFile IF NOT sFirst THEN sFirst = sFile ENDIF IF sFile = sKey THEN bNext = TRUE ENDIF NEXT IF bNext THEN RETURN sFirst END PUBLIC FUNCTION GetPreviousEditor(sKey AS String) AS String DIM sLast AS String DIM sFile AS String FOR EACH sFile IN GetClasses(TRUE) IF sFile = sKey THEN IF sLast THEN RETURN sLast ENDIF ENDIF sLast = sFile NEXT RETURN sLast END PUBLIC SUB SetMessage(sMsg AS String) IF FGambas.Visible AND IF sMsg <> ("OK") THEN FGambas.Info(sMsg) ENDIF ProjectMessage.Text = sMsg WAIT END PUBLIC SUB DeleteFile(sPath AS String) DIM sExt AS String DIM hForm AS Object DIM bLink AS Boolean DIM bProject AS Boolean IF NOT Exist(sPath) THEN RETURN bLink = Stat(sPath).Type = gb.Link bProject = File.Dir(sPath) = Project.Dir hForm = Files[sPath] IF hForm THEN hForm.Delete Files[sPath] = NULL ENDIF TRY ProjectTree.Remove(sPath) IF NOT bLink THEN TRY KILL sPath & "~" TRY MOVE sPath TO sPath & "~" ELSE TRY KILL sPath ENDIF IF bProject THEN sExt = File.Ext(sPath) IF sExt = "form" OR sExt = "class" OR sExt = "module" THEN TRY KILL Project.Dir &/ ".gambas" &/ UCase(File.BaseName(sPath)) TRY KILL Project.Dir &/ ".lang" &/ File.BaseName(sPath) & ".pot" ENDIF IF sExt = "form" THEN DeleteFile(File.Dir(sPath) &/ File.BaseName(sPath) & ".class") ELSE IF sExt = "class" THEN DeleteFile(File.Dir(sPath) &/ File.BaseName(sPath) & ".form") ENDIF IF File.BaseName(sPath) = Startup THEN DefineStartup("") ENDIF ENDIF 'CATCH 'Message("*Unable to delete file.||" & sPath) 'Refresh END PUBLIC SUB DeleteDir(sDir AS String) DIM sFile AS String FOR EACH sFile IN Dir(sDir, "*~") TRY KILL sDir &/ sFile NEXT RMDIR sDir Project.RefreshKey(sDir) END PRIVATE FUNCTION CheckStartupClass() AS Boolean IF Startup THEN RETURN FGambas.Warning(("You must define a startup class or form!")) RETURN TRUE END PUBLIC FUNCTION CheckFileName(sName AS String, OPTIONAL sDir AS String) AS String DIM iInd AS Integer IF NOT sName THEN GOTO VOID_NAME FOR iInd = 1 TO Len(sName) IF InStr(FILE_AUTH_CAR & "-._+()", LCase(Mid$(sName, iInd, 1))) = 0 THEN GOTO BAD_CHAR NEXT IF Len(sDir) THEN IF Exist(sDir &/ sName) THEN GOTO ALREADY_EXIST ENDIF RETURN VOID_NAME: RETURN ("Please type a name.") BAD_CHAR: RETURN ("This name contains a forbidden character :") & " [ " & Mid$(sName, iInd, 1) & " ]" ALREADY_EXIST: RETURN ("This name is already used. Choose another one.") END PUBLIC FUNCTION CheckClassName(sName AS String, OPTIONAL bCheckNotExist AS Boolean) AS String DIM iInd AS Integer IF NOT sName THEN GOTO VOID_NAME FOR iInd = 1 TO Len(sName) IF InStr(CLASS_AUTH_CAR, LCase(Mid$(sName, iInd, 1))) = 0 THEN GOTO BAD_CHAR NEXT IF InStr("0123456789", Left$(sName)) THEN iInd = 1 GOTO BAD_CHAR ENDIF IF bCheckNotExist THEN IF Project.Exist(sName) THEN GOTO ALREADY_EXIST ENDIF RETURN VOID_NAME: RETURN ("Please type a name.") BAD_CHAR: RETURN ("This name contains a forbidden character :") & " [ " & Mid$(sName, iInd, 1) & " ] \n\n" & ("A name must begin with a letter, followed by any letter or digit.") ALREADY_EXIST: RETURN ("This name is already used. Choose another one.") END PRIVATE FUNCTION RenameOneFile(sDir AS String, sName AS String, sNewName AS String, OPTIONAL sExt AS String) AS String DIM sPath AS String DIM hForm AS Object DIM sNewPath AS String sPath = sDir &/ sName IF sExt THEN sPath = sPath & "." & sExt IF NOT Exist(sPath) THEN RETURN sNewPath = sDir &/ sNewName IF sExt THEN sNewPath = sNewPath & "." & sExt MOVE sPath TO sNewPath IF sExt THEN TRY KILL sDir &/ ".gambas" &/ UCase(sName) ENDIF hForm = Files[sPath] IF hForm THEN hForm.Rename(sNewName, sNewPath) Files[sPath] = NULL Files[sNewPath] = hForm ENDIF RETURN sNewPath END PUBLIC SUB GetClassesOnly() AS String[] DIM sFile AS String DIM sKey AS String DIM aClass AS NEW String[] FOR EACH sFile IN Dir(Project.Dir, "*.class") IF Exist(Project.Dir &/ File.BaseName(sFile) & ".form") THEN CONTINUE aClass.Add(File.BaseName(sFile)) NEXT RETURN aClass.Sort() END PRIVATE SUB RefreshInheritance() DIM sClass AS String DIM sKey AS String $aRefreshAfter.Clear FOR EACH sClass IN GetClassesOnly() sKey = Project.Dir &/ sClass & ".class" TRY ProjectTree[sKey].Delete $aRefreshAfter.Add(sKey) NEXT DoRefreshAfter END PUBLIC SUB RefreshKey(sKey AS String, OPTIONAL sOld AS String) IF NOT sKey THEN RETURN IF NOT sOld THEN sOld = sKey TRY ProjectTree[sOld].Delete IF NOT Exist(sKey) THEN RETURN IF File.Dir(sKey) = Project.Dir AND IF file.Ext(sKey) = "class" AND IF NOT Exist(File.Dir(sKey) &/ File.BaseName(sKey) & ".form") THEN RefreshInheritance RETURN ENDIF AddFile(File.Dir(sKey), File.Name(sKey), TRUE) IF IsDir(sKey) THEN AddDir(sKey) END PUBLIC SUB RenameFile(sPath AS String, sNewName AS String) DIM sName AS String DIM sExt AS String DIM sDir AS String DIM sNewPath AS String sDir = File.Dir(sPath) sExt = File.Ext(sPath) IF Project.IsClassName(sPath) THEN sName = File.BaseName(sPath) IF sName = sNewName THEN RETURN IF sName = Startup THEN Startup = sNewName WriteProject(TRUE) ENDIF sNewPath = RenameOneFile(sDir, sName, sNewName, sExt) IF sExt = "form" THEN RenameOneFile(sDir, sName, sNewName, "class") ELSE IF sExt = "class" THEN RenameOneFile(sDir, sName, sNewName, "form") ENDIF ELSE sName = File.Name(sPath) IF sName = sNewName THEN RETURN sNewPath = RenameOneFile(sDir, sName, sNewName) ENDIF RefreshKey(sNewPath, sPath) 'AddFile(File.Dir(sNewPath), File.Name(sNewPath), TRUE) 'IF IsDir(sNewPath) THEN AddDir(sNewPath) TRY ProjectTree[sNewPath].Selected = TRUE TRY ProjectTree[sNewPath].EnsureVisible CATCH FGambas.Error(Subst(("Unable to rename '&1'") & "\n\n" & Error.Text, File.Name(sPath))) END PUBLIC FUNCTION Exist(sName AS String) AS Boolean RETURN Project.GetClasses().Find(sName, gb.Text) >= 0 END PRIVATE FUNCTION LockIt() AS Boolean IF Application.Busy THEN RETURN TRUE INC Application.Busy 'PRINT "Lock" END PRIVATE SUB UnLockIt() DEC Application.Busy END PUBLIC FUNCTION GetProject() AS String RETURN FOpenProject.Run() END PRIVATE SUB LoadRecent() DIM nRecent AS Integer DIM hMenu AS Menu DIM iInd AS Integer DIM sPath AS String nRecent = Settings["/Recent/Count", 0] Recent.Clear FOR iInd = 1 TO nRecent sPath = Settings["/Recent/File[" & CStr(iInd) & "]"] IF sPath THEN IF Exist(sPath) THEN Recent.Add(sPath) IF Recent.Count >= MAX_RECENT THEN BREAK ENDIF ENDIF NEXT END PRIVATE SUB AddRecent(sPath AS String) DIM iInd AS Integer IF Right$(sPath) = "/" THEN sPath = Left$(sPath, -1) 'sPath = "(" & File.BaseName(sPath) & ") " & File.Dir(sPath) WHILE iInd < Recent.Count IF Recent[iInd] = sPath THEN Recent.Remove(iInd) ELSE INC iind ENDIF WEND Recent.Add(sPath, 0) WHILE Recent.Count > MAX_RECENT Recent.Remove(Recent.Count - 1) WEND SaveRecent END PRIVATE SUB SaveRecent() DIM iInd AS Integer Settings.Clear("/Recent") Settings["/Recent/Count"] = Recent.Count FOR iInd = 0 TO Recent.Count - 1 Settings["/Recent/File[" & CStr(iInd + 1) & "]"] = Recent[iInd] NEXT Settings.Save END PUBLIC SUB ClearRecent() Recent.Clear SaveRecent END PUBLIC FUNCTION CheckProjectName(sName AS String, OPTIONAL sDir AS String) AS String DIM iInd AS Integer DIM sCar AS String sName = Trim(sName) IF NOT sName THEN RETURN ("Please type a project name.") ENDIF FOR iInd = 1 TO Len(sName) sCar = Mid$(sName, iInd, 1) IF iInd = 1 THEN IF sCar = "." THEN RETURN ("The project name cannot begin with a dot.") ENDIF IF Asc(sCar) > 127 THEN RETURN ("Non-ASCII characters are forbidden in a project name.") IF InStr(" ?*/\\", sCar) THEN RETURN ("The following characters are forbidden in a project name: ? * / \\ SPACE") NEXT IF sDir THEN sDir &/= sName IF Exist(sDir &/ PROJECT_FILE) THEN RETURN ("This project already exists.") ELSE IF Exist(sDir) THEN IF IsDir(sDir) THEN RETURN Subst(("The project directory already exists."), sDir) ELSE RETURN Subst(("The project directory cannot be created because a file with the same name already exists."), sDir) ENDIF ENDIF ENDIF END PUBLIC SUB MakeSourcePackageTo(sPath AS String) DIM sCmd AS String DIM sOpt AS String INC Application.Busy IF Right$(sPath, 3) = ".gz" THEN sOpt = "z" ELSE IF Right$(sPath, 4) = ".bz2" THEN sOpt = "j" ENDIF sCmd = "cd " & Quote(File.Dir(Project.Dir)) & ";" sCmd = sCmd & " tar cfvh" & sOpt & " " & Quote(sPath) sCmd = sCmd & " --exclude=" & ".gambas/*" sCmd = sCmd & " --exclude=" & "*~" sCmd = sCmd & " --exclude=" & ".lock" sCmd = sCmd & " --exclude=" & ".lang/*.pot" sCmd = sCmd & " --exclude=" & ".lang/.pot" sCmd = sCmd & " --exclude=" & "*/.xvpics/*" sCmd = sCmd & " --exclude=" & ".xvpics/*" sCmd = sCmd & " " & Quote(File.Name(Project.Dir)) & " > /dev/null" SHELL sCmd WAIT DEC Application.Busy END PUBLIC SUB MakePackage() Dialog.Path = User.Home &/ Name & "-" & Subst("&1.&2", MajorVersion, MinorVersion) & IIf(ReleaseVersion > 0, "." & ReleaseVersion, "") & ".tar.gz" Dialog.Title = ("Create source package") Dialog.Filter = ["*.tar.gz", ("Source packages")] '& " (*.tar.gz)", ("All files") & " (*)"] IF Dialog.SaveFile() THEN RETURN MakeSourcePackageTo(Dialog.Path) END PUBLIC SUB RefreshForm() DIM hFile AS Object FOR EACH hFile IN Project.Files IF Object.Type(hFile) = "FForm" THEN hFile.Refresh ENDIF NEXT END PUBLIC SUB RefreshEditor() DIM hFile AS Object FOR EACH hFile IN Project.Files IF Project.IsEditor(hFile) THEN hFile.Refresh ENDIF NEXT END PUBLIC SUB RefreshLibrary() DIM sLib AS String DIM sClass AS String DIM aLib AS NEW String[] DIM hComp AS CComponent DIM sLibComp AS String ' Sort components FOR EACH hComp IN CComponent.All IF Libraries.Find(hComp.Key) >= 0 THEN aLib.Add(hComp.Key) ENDIF NEXT Libraries = aLib sLibComp = aLib.Join(" ") IF sLibComp <> $sOldRefreshLibrary THEN CComponent.Reset ComponentFromType.Clear FormType.Clear FOR EACH sLib IN Libraries 'IF NOT CComponent.All.Exist(sLib) THEN CONTINUE WITH CComponent.All[sLib] .Load IF .Type THEN ComponentFromType[.Type] = sLib ENDIF END WITH NEXT FToolBox.RefreshToolbar FCompletion.RefreshLibrary 'FExplorer.RefreshTree Project.Refresh $sOldRefreshLibrary = sLibComp ENDIF END PUBLIC FUNCTION IsClassName(sName AS String) AS Boolean DIM sExt AS String IF Left(sName) = "/" THEN IF File.Dir(sName) <> Project.Dir THEN RETURN ENDIF sExt = File.Ext(sName) IF sExt = "class" THEN RETURN TRUE IF sExt = "module" THEN RETURN TRUE IF sExt = "form" THEN RETURN TRUE END PUBLIC FUNCTION StripPath(sPath AS String) AS String DIM sDir AS String sDir = Project.Dir IF Right$(sDir) <> "/" THEN sDir = sDir & "/" IF Left$(sPath, Len(sDir)) = sDir THEN RETURN Mid$(sPath, Len(sDir) + 1) ELSE RETURN sPath ENDIF END PUBLIC SUB RunTool(sTool AS String) DIM aExec AS NEW String[] aExec.Add(System.Path &/ "bin" &/ sTool & ".gambas") aExec.Add(Project.Dir) EXEC aExec END PUBLIC FUNCTION GetExamples() AS String[] DIM sFile AS String DIM sFile2 AS String DIM aList AS NEW String[] FOR EACH sFile IN Dir(EXAMPLES_DIR) IF Left(sFile) = "." THEN CONTINUE IF Exist(EXAMPLES_DIR &/ sFile &/ ".project") THEN aList.Add(sFile) ELSE FOR EACH sFile2 IN Dir(EXAMPLES_DIR &/ sFile) IF Left(sFile2) = "." THEN CONTINUE aList.Add(sFile &/ sFile2) NEXT ENDIF NEXT aList.Sort FINALLY RETURN aList END PUBLIC SUB DefineStartup(sPath AS String, OPTIONAL bDoNotWrite AS Boolean) sPath = File.BaseName(sPath) IF NOT Project.Exist(sPath) THEN sPath = "" SWAP Startup, sPath IF sPath THEN RefreshKey(FindKey(sPath)) IF Startup THEN RefreshKey(FindKey(Startup)) IF NOT bDoNotWrite THEN WriteProject(TRUE) CATCH END PUBLIC SUB GetUniqueName(sDir AS String, sName AS String, OPTIONAL sSuffix AS String = "&1") AS String DIM iInd AS Integer DIM sDest AS String DIM sExt AS String DIM sPath AS String sDest = sDir &/ sName WHILE Exist(sDest) INC iInd sExt = File.Ext(sName) IF sExt THEN sDest = sDir &/ File.BaseName(sName) & Subst(sSuffix, CStr(iInd)) & "." & sExt ELSE sDest = sDir &/ sName & Subst(sSuffix, CStr(iInd)) ENDIF WEND RETURN File.Name(sDest) END PUBLIC SUB CopyFile(sSrc AS String, sDst AS String) DIM sDest AS String sDest = File.Dir(sDst) &/ GetUniqueName(File.Dir(sDst), File.Name(sDst), " (&1)") COPY sSrc TO sDest RefreshKey(sDest) SelectKey(sDest) CATCH Message.Error(Subst(("Cannot copy file &1."), sSrc) & "\n\n" & Error.Text) END PUBLIC SUB LinkFile(sSrc AS String, sDst AS String) DIM sDest AS String DIM aDst AS String[] DIM aSrc AS String[] DIM sDir AS String IF IsDir(sSrc) THEN Message.Warning(("Linking a directory is forbidden.")) RETURN ENDIF sDest = File.Dir(sDst) &/ GetUniqueName(File.Dir(sDst), File.Name(sDst), " (&1)") IF sSrc LIKE (Project.Dir & "/*") THEN aDst = Split(File.Dir(Mid$(sDest, Len(Project.Dir) + 2)), "/") sSrc = Mid$(sSrc, Len(Project.Dir) + 2) aSrc = Split(File.Dir(sSrc), "/") WHILE aDst.Count > 0 AND aSrc.Count > 0 IF aSrc[0] <> aDst[0] THEN BREAK aDst.Remove(0) aSrc.Remove(0) WEND sSrc = String(aDst.Count, "../") & aSrc.Join("/") &/ File.Name(sSrc) ENDIF LINK sDest TO sSrc RefreshKey(sDest) SelectKey(sDest) CATCH Message.Error(Subst(("Cannot create link &1."), sSrc) & "\n\n" & Error.Text) END PUBLIC SUB MoveFile(sSrc AS String, sDst AS String) DIM hForm AS Object DIM sLink AS String DIM sDir AS String IF sSrc = sDst THEN RETURN IF Len(sDst) > Len(sSrc) AND IF Left(sDst, Len(sSrc)) = sSrc THEN Message.Error(("Cannot move a directory inside itself.")) RETURN ENDIF WITH Stat(sSrc) IF .Type = gb.Link THEN sLink = .Link IF Left(sLink) <> "/" THEN sDir = File.Dir(sSrc) WHILE Left(sLink, 3) = "../" sLink = Mid(sLink, 4) sDir = File.Dir(sDir) WEND sLink = sDir &/ sLink ENDIF DeleteFile(sSrc) LinkFile(sLink, sDst) RETURN ENDIF END WITH MOVE sSrc TO sDst hForm = Files[sSrc] IF hForm THEN hForm.Rename(File.Name(sDst), sDst) Files[sSrc] = NULL Files[sDst] = hForm ENDIF RefreshKey(sDst, sSrc) 'Refresh SelectKey(sDst) CATCH Message.Error(Subst(("Cannot move file &1."), sSrc) & "\n\n" & Error.Text) END ' PUBLIC SUB RefreshToolbox() ' ' FToolBox.ClearToolbar ' ' END PUBLIC FUNCTION GetNewName(sPrefix AS String) AS String DIM iInd AS Integer DIM sName AS String DO INC iInd sName = sPrefix & iInd IF NOT Project.Exist(sName) THEN RETURN sName LOOP END PUBLIC SUB ResetScan() DIM hFile AS Object FOR EACH hFile IN Files TRY hFile.Scan = NULL NEXT END PUBLIC FUNCTION AllowForm() AS Boolean RETURN ComponentFromType.Exist("Form") END PUBLIC SUB MakeInstall() IF MakeExecutable(TRUE, TRUE) THEN RETURN IF NOT CheckProgram("rpmbuild") THEN RPMBUILD_PROG = "rpmbuild" ELSE IF NOT CheckProgram("rpm") THEN RPMBUILD_PROG = "rpm" ELSE Message.Error(("rpmbuild is not installed on your system.")) RETURN ENDIF FMakeInstall.ShowModal END PUBLIC SUB InitMove(hForm AS Form) 'hForm.Move(Int(Rnd(0, Max(0, Workspace.Width - hForm.Width - 8))), Int(Rnd(0, Max(0, Workspace.Height - hForm.Height - 8)))) END PUBLIC FUNCTION GetIcon(sPath AS String, OPTIONAL iSize AS Integer) AS Picture DIM hFile AS File DIM sLig AS String DIM hImage AS Image DIM hPict AS Picture OPEN sPath &/ ".project" FOR READ AS #hFile WHILE NOT Eof(hFile) LINE INPUT #hFile, sLig IF Left$(sLig, 5) = "Icon=" THEN sPath = sPath &/ Mid$(sLig, 6) TRY hImage = Image.Load(sPath) IF ERROR THEN hImage = NULL BREAK ENDIF WEND CLOSE #hFile FINALLY IF NOT hImage THEN hImage = Image.Load("img/32/gambas.png") ENDIF IF iSize = 0 THEN RETURN hImage.Picture ELSE RETURN hImage.Stretch(iSize, iSize, TRUE).Picture ENDIF END PRIVATE SUB CleanUpProject() DIM aDir AS NEW String[] DIM sFile AS String DIM sPath AS String aDir.Add(Project.Dir) WHILE aDir.Count FOR EACH sFile IN Dir(aDir[0]) sPath = aDir[0] &/ sFile IF IsDir(sPath) THEN aDir.Add(sPath) ELSE IF Right(sPath) = "~" THEN TRY KILL sPath ENDIF NEXT aDir.Remove(0) WEND CATCH Message.Error(("Cannot clean the project.") & "\n\n" & Error.Text) END PUBLIC SUB SetFormIcon(hForm AS FForm) ' ' DIM hPict AS Picture ' DIM eRap AS Float ' ' 'hForm.Raise ' hPict = hForm.Grab() ' hForm.Refresh ' eRap = hPict.Width / hPict.Height ' IF eRap > 4 THEN ' eRap = 4 ' hPict = hPict.Copy(0, 0, hPict.Height * eRap, hPict.Height) ' ELSE IF eRap < 0.5 THEN ' eRap = 0.5 ' hPict = hPict.Copy(0, 0, hPict.Width, hPict.Width / eRap) ' ENDIF ' IF eRap > 1 THEN ' hPict = hPict.Image.Stretch(32 * eRap, 32).Picture ' ELSE ' hPict = hPict.Image.Stretch(32, 32 / eRap).Picture ' ENDIF ' ' Draw.Begin(hPict) ' Draw.Foreground = &H808080& ' Draw.Rect(0, 0, hPict.Width, hPict.Height) ' Draw.End ' ' ProjectTree[Project.Dir &/ hForm.Name & ".form"].Picture = hPict ' ' CATCH ' ' PRINT Error.Text ' END PUBLIC FUNCTION CheckProgram(sProg AS String) AS Boolean DIM sTemp AS String DIM bError AS Boolean DIM iPos AS Integer iPos = InStr(sProg, " ") IF iPos THEN sProg = Left(sProg, iPos - 1) sTemp = Temp$ SHELL "which " & sProg & " > " & sTemp WAIT bError = Trim(File.Load(sTemp)) LIKE "which: *" KILL sTemp RETURN bError END PUBLIC FUNCTION OpenWebPage(sLink AS String) AS String DIM sExec AS String DIM aTest AS String[] DIM bCheck AS Boolean IF NOT Browser THEN SELECT CASE Settings["/Browser"] CASE "konqueror" aTest = ["konqueror"] CASE "epiphany" aTest = ["epiphany"] CASE "firefox" aTest = ["firefox", "mozilla-firefox"] CASE "seamonkey" aTest = ["seamonkey"] CASE ELSE aTest = [Application.Env["BROWSER"]] IF Application.Env["KDE_FULL_SESSION"] THEN aTest.Add("konqueror") ELSE IF Application.Env["GNOME_SESSION_ID"] THEN aTest.Add("epiphany") ENDIF END SELECT aTest.Add("konqueror") aTest.Add("mozilla-firefox") aTest.Add("firefox") aTest.Add("mozilla") aTest.Add("seamonkey") aTest.Add("opera") FOR EACH sExec IN aTest bCheck = NOT CheckProgram(sExec) IF bCheck THEN BREAK NEXT IF NOT bCheck THEN RETURN Browser = sExec ENDIF IF Left(sLink) = "/" THEN sLink = "file://" & Replace(sLink, "?", "%3F") ENDIF SHELL Browser & " " & Chr$(34) & sLink & Chr$(34) CATCH Message.Error(Error.Text) END ' PUBLIC SUB ClearFound() ' ' DIM aKey AS NEW String[] ' DIM sKey AS String ' ' IF $iFound = 0 THEN RETURN ' ' WITH ProjectTree ' .MoveFirst ' ' DO ' ' IF NOT .MoveChild() THEN CONTINUE ' .MoveBack ' ' IF Left(.Item.Key, 2) = KEY_FIND THEN aKey.Add(.Item.Key) ' ' NEXT_PARENT: ' ' IF NOT .MoveNext() THEN CONTINUE ' .MoveBack ' ' IF .MoveParent() THEN BREAK ' GOTO NEXT_PARENT ' ' LOOP ' ' FOR EACH sKey IN aKey ' ProjectTree.Remove(sKey) ' NEXT ' ' END WITH ' ' $iFound = 0 ' ProjectTree.Columns.Count = 1 ' ' END ' ' PUBLIC SUB AddFound(sName AS String, iLine AS Integer, iCol AS Integer, iLen AS Integer, sText AS String) ' ' DIM sKey AS String ' 'DIM sAfter AS String ' DIM sParent AS String ' ' sParent = FindKey(sName) ' IF NOT sParent THEN RETURN ' ' ProjectTree.Columns.Count = 2 ' ' sKey = KEY_FIND & sParent & "@" & Format(iLine, "000000") & "." & Format(iCol, "00000") & "." & iLen ' ' ' ProjectTree.MoveTo(sParent) ' ' IF NOT ProjectTree.MoveChild() THEN ' ' WHILE ProjectTree.Available ' ' ProjectTree.MoveNext ' ' WEND ' ' ProjectTree.MoveBack ' ' sAfter = ProjectTree.Item.Key ' ' ENDIF ' ' ' ' DEBUG sKey;; ":";; sAfter ' ' ProjectTree.Add(sKey, (iLine + 1) & ":" & iCol, Picture["icon:/16/find"], sParent) ' ProjectTree[sKey][1] = sText ' ProjectTree[sParent].Expanded = TRUE ' ' INC $iFound ' ' END ' ' PUBLIC SUB SelectFound(sName AS String, iLine AS Integer, iCol AS Integer, iLen AS Integer) ' ' DIM sKey AS String ' ' sKey = FindKey(sName) ' IF NOT sKey THEN RETURN ' ' sKey = KEY_FIND & sKey & "@" & Format(iLine, "000000") & "." & Format(iCol, "00000") & "." & iLen ' TRY ProjectTree[sKey].Selected = TRUE ' ' END PUBLIC SUB LastPosition() DIM aPos AS String[] DIM iPos AS Integer WITH Positions IF .Count = 0 THEN RETURN aPos = Split(.Pop(), " ") ' IF aPos[0] = Path AND (Val(aPos[1]) = edtEditor.Line) AND (Val(aPos[2]) = edtEditor.Column) THEN ' LastPosition ' RETURN ' ENDIF 'PRINT "-> "; aPos.Join(" ") OpenFile(aPos[0]) Files[aPos[0]].GotoCenter(Val(aPos[1]), Val(aPos[2])) END WITH END PUBLIC SUB SavePosition() DIM hEditor AS FEditor DIM sPos AS String IF $bDoNotSavePosition THEN RETURN TRY hEditor = ActiveForm IF ERROR THEN RETURN sPos = hEditor.Path & " " & hEditor.Editor.Line & " " & hEditor.Editor.Column IF Positions.Count > 0 THEN IF Positions[Positions.Max] = sPos THEN RETURN ENDIF ENDIF Positions.Push(sPos) 'PRINT "Save: "; Project.Positions[Project.Positions.Count - 1] END PUBLIC SUB GetPicture(sPict AS String) AS Picture IF NOT sPict THEN RETURN IF sPict LIKE "icon:/*" THEN RETURN Picture[sPict] ELSE RETURN Picture.Load(Project.Dir &/ sPict) ENDIF END PUBLIC SUB HasTranslation(sLang AS String) AS Boolean RETURN Exist(Project.Dir &/ ".lang" &/ sLang & ".po") END PUBLIC SUB MakeDirectoryIcon(OPTIONAL sDir AS String) DIM sIcon AS String DIM hPict AS Picture DIM hIcon AS Image IF NOT sDir THEN sDir = Project.Dir IF Project.Icon THEN sIcon = sDir &/ Project.Icon ENDIF hPict = Image.Load("img/logo/icon-background.png").Picture Draw.Begin(hPict) IF sIcon THEN hIcon = Image.Load(sIcon).Stretch(32, 32) Draw.Image(hIcon, 6, 29) ENDIF Draw.Image(Image.Load("img/logo/corner.png"), 42, 45) Draw.End hPict.Save(sDir &/ ".icon.png") File.Save(sDir &/ ".directory", "[Desktop Entry]\nIcon=./.icon.png\n") END From rospolosco at ...152... Sat Oct 7 10:33:14 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Sat, 7 Oct 2006 10:33:14 +0200 Subject: [Gambas-user] 1.9.44 translation tool bug Message-ID: <200610071033.14818.rospolosco@...152...> Hi, Benoit. I've just compiled 1.9.44. It seems that the already posted translation bug (Leonardo Miliani) is still present. The bug doesn't effects all projects. If you want an example of an untranslatable project here is the address: http://sourceforge.net/projects/gbxgol it's just 90 kb. Make it translatable and then try to translate it. You will have the error popup (attached). Then you can't quit Gambas2 in normal way, but you have to kill gbr2. Regards, Stefano Palmeri -------------- next part -------------- A non-text attachment was scrubbed... Name: translate_bug.jpg Type: image/jpeg Size: 12055 bytes Desc: not available URL: From gambas at ...1... Sat Oct 7 10:52:46 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 7 Oct 2006 10:52:46 +0200 Subject: [Gambas-user] Observations on Message.Warning (1.9.43) In-Reply-To: <4525D70A.3080709@...1000...> References: <4525D70A.3080709@...1000...> Message-ID: <200610071052.46469.gambas@...1...> On Friday 06 October 2006 06:09, Werner wrote: > Consider this: > > Dim i as Integer > i = Message.Warning ("Are you sure you want to delete all the records in > the database?" , "Cancel" , "Delete") > > The first button is apparently the default so if the user just hits > Enter a 1 is returned. > Cancel button returns 1 > Delete button returns 2 > > So far, so good. > > But if the user does not click any button and just closes the window by > clicking on the top right close square a 2 is also returned. > > How about in this case returning something this is not in the range of > buttons say 0 or -1? > > > Regards > Werner Dahn > This is because the default button is always the last one. I just need to add a syntax so that the default button can be specified. Regards, -- Benoit Minisini From gambas at ...1... Sat Oct 7 12:01:01 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 7 Oct 2006 12:01:01 +0200 Subject: [Gambas-user] 1.9.44 translation tool bug In-Reply-To: <200610071033.14818.rospolosco@...152...> References: <200610071033.14818.rospolosco@...152...> Message-ID: <200610071201.02174.gambas@...1...> On Saturday 07 October 2006 10:33, Stefano Palmeri wrote: > Hi, Benoit. > > I've just compiled 1.9.44. > > It seems that the already posted translation bug (Leonardo Miliani) > is still present. The bug doesn't effects all projects. > > If you want an example of an untranslatable project > here is the address: > > http://sourceforge.net/projects/gbxgol > > it's just 90 kb. > > Make it translatable and then try to translate it. > You will have the error popup (attached). > > Then you can't quit Gambas2 in normal way, but you have to kill gbr2. > > Regards, > > Stefano Palmeri I found the bug. As a temporary workaround, just remove the quote character in the project description, and all should be fine! Regards, -- Benoit Minisini From rospolosco at ...152... Sat Oct 7 12:22:10 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Sat, 7 Oct 2006 12:22:10 +0200 Subject: [Gambas-user] 1.9.44 translation tool bug In-Reply-To: <200610071201.02174.gambas@...1...> References: <200610071033.14818.rospolosco@...152...> <200610071201.02174.gambas@...1...> Message-ID: <200610071222.10552.rospolosco@...152...> Alle 12:01, sabato 7 ottobre 2006, Benoit Minisini ha scritto: > I found the bug. As a temporary workaround, just remove the quote character in > the project description, and all should be fine! > > Regards, > > -- > Benoit Minisini > Yes, you're right. Thanks, Stefano Palmeri From gambas.fr at ...626... Sat Oct 7 14:46:22 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 7 Oct 2006 14:46:22 +0200 Subject: [Gambas-user] test Message-ID: <200610071446.22217.sirfabien@...626...> From gambas.fr at ...626... Sat Oct 7 14:51:47 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 7 Oct 2006 14:51:47 +0200 Subject: [Gambas-user] test Message-ID: <200610071451.47887.sirfabien@...626...> From leonardo at ...1237... Sat Oct 7 17:04:34 2006 From: leonardo at ...1237... (Leonardo Miliani) Date: Sat, 07 Oct 2006 17:04:34 +0200 Subject: [Gambas-user] just a mail test - do not read In-Reply-To: <200610061904.25129.rospolosco@...152...> References: <200610061904.25129.rospolosco@...152...> Message-ID: <4527C202.5030909@...1237...> Stefano Palmeri ha scritto: > Test mail > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > Another test... -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software From leonardo at ...1237... Sat Oct 7 17:09:42 2006 From: leonardo at ...1237... (Leonardo Miliani) Date: Sat, 07 Oct 2006 17:09:42 +0200 Subject: [Gambas-user] Maybe 2 errors in Gambas 1.9.43 In-Reply-To: <200610051914.25830.gambas@...1...> References: <45226148.7020009@...1237...> <200610051914.25830.gambas@...1...> Message-ID: <4527C336.4010208@...1237...> Benoit Minisini ha scritto: > On Tuesday 03 October 2006 15:10, Leonardo Miliani wrote: >> Hi Benoit, >> maybe I've found 2 bugs in Gambas 1.9.43. >> Check them for sure.. >> >> >> 1) >> Even if I open an existing project or I have create a new one, if I >> click on Project/Properties and try to change the program icon, I get >> this error: >> "This application has raised an unexpected >> error and must abort. >> [3] Stack overflow. >> FSelectIcon.cmbSize_Click.77" >> >> I can confirm that it didn't exist on older versions because I have a >> project that I'm working on that has the icon changed. >> >> 2) >> I cannot translate any project I made with Gambas... >> I work on the italian localization of Gambas and if I choose to >> translate my project, Gambas tells me that it cannot find the italian >> localization file, getting this error: >> "Non riesco a leggere il file di traduzione per la lingua 'italiano >> (Italia)' >> >> .Fatto." >> >> (in english, it means: "I can't read the translation file for the >> language 'italian (Italy)'". >> Same error if I try to add a language (in the example, I've tried to add >> the english language). You can see in the screenshot I've sent that in >> the combomenu (red arrow) I haven't any language that I can choose from.. > > > Did 1.9.44 fix the error #2? > Sorry, Benoit, if I answer your question only today but I've had a lot of problems with SpamCop.net that checks the mails sent to this mailing list. It refused all of the mails coming from my SMTP (or maybe my ISP, I don't know)... I hope that this was a bug of SpamCop but I feel that I'm wrong because this is the 2nd time that it happens in just a couple of weeks.... So, for the bug: it's still present. But I've just read the solution tht you suggested to Stefano so I'll try it too... Regards. -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software From andrea_bortolan at ...325... Mon Oct 9 16:49:20 2006 From: andrea_bortolan at ...325... (Andrea Bortolan) Date: Mon, 9 Oct 2006 16:49:20 +0200 (CEST) Subject: [Gambas-user] Gambas 1.9.44 problem Message-ID: <20061009144920.82341.qmail@...907...> Hi all, I'm facing a strange problem using Gambas 1.9.44. I started a new project, in the FMain Form I added a new Separator, this is showed correclty but, when I try to change its Foreground color gambas raises this error : This appication has raised an unexpected error and must abort. [11] Unknow symbol 'Container' in class 'ListContainer', FColorChooser.AddColor.45 Any idea about what I'm doing wrong ? Thanks a lot, Andrea. __________________________________________________ Do You Yahoo!? Poco spazio e tanto spam? Yahoo! Mail ti protegge dallo spam e ti da tanto spazio gratuito per i tuoi file e i messaggi http://mail.yahoo.it -------------- next part -------------- A non-text attachment was scrubbed... Name: gambas1.9.44.JPG Type: image/jpeg Size: 74748 bytes Desc: 2246757728-gambas1.9.44.JPG URL: From gambas at ...1... Mon Oct 9 18:16:33 2006 From: gambas at ...1... (Benoit Minisini) Date: Mon, 9 Oct 2006 18:16:33 +0200 Subject: [Gambas-user] Gambas 1.9.44 problem In-Reply-To: <20061009144920.82341.qmail@...907...> References: <20061009144920.82341.qmail@...907...> Message-ID: <200610091816.34034.gambas@...1...> On Monday 09 October 2006 16:49, Andrea Bortolan wrote: > Hi all, > I'm facing a strange problem using Gambas 1.9.44. > I started a new project, in the FMain Form I added a new Separator, this is > showed correclty but, when I try to change its Foreground color gambas > raises this error : This appication has raised an unexpected error and must > abort. > [11] Unknow symbol 'Container' in class 'ListContainer', > FColorChooser.AddColor.45 > > Any idea about what I'm doing wrong ? > Thanks a lot, Andrea. > > This bug has been fixed in the svn repository. You must edit the line 45 of FColorChooser.class and remove '.Container'. Regards, -- Benoit Minisini From mandrakeron at ...43... Mon Oct 9 18:54:52 2006 From: mandrakeron at ...43... (Ron Gottstein) Date: Mon, 9 Oct 2006 09:54:52 -0700 (PDT) Subject: [Gambas-user] Help Browser in 1.9.44 Message-ID: <20061009165452.27463.qmail@...1594...> Help...Somehow I lost the Help Browser ver 9.44....It no longer works. Ron G From brian at ...1334... Mon Oct 9 19:05:16 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 09 Oct 2006 10:05:16 -0700 (PDT) Subject: [Gambas-user] (no subject) Message-ID: <20061009100009.F92800@...1337...> I'm having extreme problems getting 2.9.44 to build under SuSE 10.0 Seems despite having every delvopment pakage install I cannot get SDL or MySQL support and just three tiers into the configure chain (I'm wondering at this point what else it won't find). I've tried the build about 20 times. Unless some other soul has gotten the 2.9.44 dev build of gambas to compile and has a binary package I could use I'm ready to give up. Qt/KDE2+ (3.5 preferably), MySQL, all SDL support are necessities for my needs. About to pull out all hair, Brian .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Mon Oct 9 19:08:15 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 09 Oct 2006 10:08:15 -0700 (PDT) Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 Message-ID: <20061009100734.W92800@...1337...> I'm having extreme problems getting 1.9.44 to build under SuSE 10.0 Seems despite having every delvopment pakage install I cannot get SDL or MySQL support and just three tiers into the configure chain (I'm wondering at this point what else it won't find). I've tried the build about 20 times. Unless some other soul has gotten the 1.9.44 dev build of gambas to compile and has a binary package I could use I'm ready to give up. Qt/KDE2+ (3.5 preferably), MySQL, all SDL support are necessities for my needs. About to pull out all hair, Brian .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Gambas-user mailing list Gambas-user at lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user From brian at ...1334... Mon Oct 9 19:11:56 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 09 Oct 2006 10:11:56 -0700 (PDT) Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 In-Reply-To: <20061009100734.W92800@...1337...> References: <20061009100734.W92800@...1337...> Message-ID: <20061009100911.Q92800@...1337...> On Mon, 9 Oct 2006, Christopher Brian Jack wrote: If I have to use non-Yast packages, can a list of wget'able URIs be provided in order of build dependency (with the first one needed to be built listed first). On another note. Does the 1.9.44 of this massive cretacian build OK under Ubuntu? > Date: Mon, 09 Oct 2006 10:08:15 -0700 (PDT) > From: Christopher Brian Jack > Reply-To: mailing list for gambas users > > To: Gambas-Users List > Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 > > > I'm having extreme problems getting 1.9.44 to build under SuSE 10.0 > > Seems despite having every delvopment pakage install I cannot get SDL or > MySQL support and just three tiers into the configure chain (I'm wondering > at this point what else it won't find). > > I've tried the build about 20 times. Unless some other soul has gotten > the 1.9.44 dev build of gambas to compile and has a binary package I could > use I'm ready to give up. > > Qt/KDE2+ (3.5 preferably), MySQL, all SDL support are necessities for my > needs. > > About to pull out all hair, > Brian > > .=================================================. > | Christopher BRIAN Jack aka "Gau of the Veldt" | > +=================================================' > | oevna at ...1544... > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Mon Oct 9 19:18:12 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 09 Oct 2006 10:18:12 -0700 (PDT) Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 In-Reply-To: <20061009100911.Q92800@...1337...> References: <20061009100734.W92800@...1337...> <20061009100911.Q92800@...1337...> Message-ID: <20061009101739.N92891@...1337...> On Mon, 9 Oct 2006, Christopher Brian Jack wrote: Is there someone I could donate to to get this working for me? > Date: Mon, 09 Oct 2006 10:11:56 -0700 (PDT) > From: Christopher Brian Jack > Reply-To: mailing list for gambas users > > To: mailing list for gambas users > Subject: Re: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 > > On Mon, 9 Oct 2006, Christopher Brian Jack wrote: > > If I have to use non-Yast packages, can a list of wget'able URIs be > provided in order of build dependency (with the first one needed to be > built listed first). > > On another note. Does the 1.9.44 of this massive cretacian build OK under > Ubuntu? > > > Date: Mon, 09 Oct 2006 10:08:15 -0700 (PDT) > > From: Christopher Brian Jack > > Reply-To: mailing list for gambas users > > > > To: Gambas-Users List > > Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 > > > > > > I'm having extreme problems getting 1.9.44 to build under SuSE 10.0 > > > > Seems despite having every delvopment pakage install I cannot get SDL or > > MySQL support and just three tiers into the configure chain (I'm wondering > > at this point what else it won't find). > > > > I've tried the build about 20 times. Unless some other soul has gotten > > the 1.9.44 dev build of gambas to compile and has a binary package I could > > use I'm ready to give up. > > > > Qt/KDE2+ (3.5 preferably), MySQL, all SDL support are necessities for my > > needs. > > > > About to pull out all hair, > > Brian > > > > .=================================================. > > | Christopher BRIAN Jack aka "Gau of the Veldt" | > > +=================================================' > > | oevna at ...1544... > > `=================================================- > > Hi Spambots, my email address is sputnik at ...1334... > > Hi Humans, my email address uses rot13 cipher > > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share your > > opinions on IT & business topics through brief surveys -- and earn cash > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share your > > opinions on IT & business topics through brief surveys -- and earn cash > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > .=================================================. > | Christopher BRIAN Jack aka "Gau of the Veldt" | > +=================================================' > | oevna at ...1544... > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Mon Oct 9 19:24:41 2006 From: gambas at ...1... (Benoit Minisini) Date: Mon, 9 Oct 2006 19:24:41 +0200 Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 In-Reply-To: <20061009100734.W92800@...1337...> References: <20061009100734.W92800@...1337...> Message-ID: <200610091924.42042.gambas@...1...> On Monday 09 October 2006 19:08, Christopher Brian Jack wrote: > I'm having extreme problems getting 1.9.44 to build under SuSE 10.0 > > Seems despite having every delvopment pakage install I cannot get SDL or > MySQL support and just three tiers into the configure chain (I'm wondering > at this point what else it won't find). > > I've tried the build about 20 times. Unless some other soul has gotten > the 1.9.44 dev build of gambas to compile and has a binary package I could > use I'm ready to give up. > > Qt/KDE2+ (3.5 preferably), MySQL, all SDL support are necessities for my > needs. > > About to pull out all hair, > Brian > > .=================================================. > > | Christopher BRIAN Jack aka "Gau of the Veldt" | > > +=================================================' > > | oevna at ...1544... > > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > To know what configure looks for, you must read the configure.ac file. For SDL: --8<----------- GB_COMPONENT( Xcursor, XCURSOR, [Xcursor], [], [GB_FIND(Xcursor.h, /usr /usr/local /usr/X11R6, include/X11/Xcursor)], [GB_FIND(libXcursor.$SHLIBEXT, /usr /usr/local /usr/X11R6, lib lib/X11R6/)], [-lXcursor], [], ["Support for colorized cursors"]) GB_COMPONENT( sdl, SDL, [SDL], [src], [GB_FIND(SDL_opengl.h SDL.h SDL_image.h, `sdl-config --prefix`, include/SDL)], [GB_FIND(libSDL_image.$SHLIBEXT , /usr /usr/X11R6 /usr/local `sdl-config --prefix`, lib)], [`sdl-config --libs` -lSDL_image -lGL -lGLU], [`sdl-config --cflags`]) GB_COMPONENT( sdl_sound, SDL_SOUND, [SDL sound], [sound], [GB_FIND(SDL_mixer.h SDL_cdrom.h, `sdl-config --prefix`, include/SDL)], [GB_FIND(libSDL_mixer.$SHLIBEXT, /usr /usr/local `sdl-config --prefix`, lib)], [`sdl-config --libs` -lSDL_mixer], [`sdl-config --cflags`]) --8<----------- GB_FIND(F1 F2 F3, A1 A2 A3, B1 B2 B3) means that the files F1, F2 and F3 must be located in all combinations of (A1 A2 A3)*(B1 B2 B3) directories. So there, libXCursor.so is searched into: * /usr/lib * /usr/local/lib * /usr/X11R6/lib * /usr/lib/X11R6 * /usr/local/lib/X11R6 * /usr/X11R6/lib/X11R6 For all SDL components, the searched files are: * XCursor.h * libXCursor.so * SDL_opengl.h * SDL.h * SDL_image.h * libSDL_image.so * SDL_mixer.h * SDL_cdrom.h * libSDL_mixer.so You can see to that the 'sdl-config' program is needed. For MySQL component: --8<----------- GB_COMPONENT( mysql, MYSQL, [MySQL driver], [src], [GB_FIND(mysql.h my_config.h, /usr/local/lib /usr/local /opt /usr/lib /usr, include mysql*/include)], [GB_FIND(libmysqlclient.$SHLIBEXT, /usr/local /opt /usr, lib mysql*/lib)], [$C_LIB -lmysqlclient -lz]) --8<----------- The files mysql.h and my_config.h are searched in a bunch of different directorys, as well the libmysqlclient.so library. In a few words, you must check: 1) That all these files are installed on your system. On Mandriva, I can search a package from a file included in it. 2) That the files are located in a directory specified by the GB_FIND() macro. Otherwise, tell me which directory is missing so that I add it in the macro call. Regards, -- Benoit Minisini From timothy.marshal-nichols at ...247... Mon Oct 9 19:43:21 2006 From: timothy.marshal-nichols at ...247... (Timothy Marshal-Nichols) Date: Mon, 9 Oct 2006 18:43:21 +0100 Subject: [Gambas-user] Gambas 1.9.44 problem In-Reply-To: <200610091816.34034.gambas@...1...> Message-ID: <000901c6ebca$6b489d80$6401a8c0@...1587...> > -----Original Message----- > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > bounces at lists.sourceforge.net] On Behalf Of Benoit Minisini > Sent: 09 October 2006 17:17 > To: mailing list for gambas users > Subject: Re: [Gambas-user] Gambas 1.9.44 problem > > On Monday 09 October 2006 16:49, Andrea Bortolan wrote: > > Hi all, > > I'm facing a strange problem using Gambas 1.9.44. > > I started a new project, in the FMain Form I added a new Separator, this > is > > showed correclty but, when I try to change its Foreground color gambas > > raises this error : This appication has raised an unexpected error and > must > > abort. > > [11] Unknow symbol 'Container' in class 'ListContainer', > > FColorChooser.AddColor.45 > > > > Any idea about what I'm doing wrong ? > > Thanks a lot, Andrea. > > > > > > This bug has been fixed in the svn repository. You must edit the line 45 > of > FColorChooser.class and remove '.Container'. > > Regards, > > -- > Benoit Minisini > > I have just updated Gambas from 1.9.43 to 1.9.44. Now I can not open the Gambas IDE at all. This is the full text of message box that is shown: This application has raised an unexpected error and must abort [11] Unknown symbol 'Container' in class 'ToolBar'. ToolBar._new.26 I can run Gambas projects that have already been compiled. But the IDE will not open. Any ideas? Thanks 8-) Timothy Marshal-Nichols From brian at ...1334... Mon Oct 9 19:43:05 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 09 Oct 2006 10:43:05 -0700 (PDT) Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 In-Reply-To: <200610091924.42042.gambas@...1...> References: <20061009100734.W92800@...1337...> <200610091924.42042.gambas@...1...> Message-ID: <20061009102641.I92913@...1337...> On Mon, 9 Oct 2006, Benoit Minisini wrote: I'm really clueless about the whole configure/automake system. I tried to use it once for one of my own projects and it really didn't simplify the process any. I just endup up pulling out hair and going to handcrafted build scripts. Configure.ac (and all its macros) read to me like Greek (and no, I don't know Greek). Is XCursor a separate package? SDL requires it but having all the SDL devs installed does not make this file present anywhere on my system. When I need to look for a file I use: find / -name "" 2>/dev/null (the redirect of stderr is becuase find / looks in things like devnodes and /var which includes a lot of things that find won't be able to stat) Hence: cowboy at ...56...:~> find / -name XCursor.h 2>/dev/null cowboy at ...56...:~> Indicates the abosulte abscence of this file anywhere on my system. > To know what configure looks for, you must read the configure.ac file. > > For SDL: > > --8<----------- > GB_COMPONENT( > Xcursor, > XCURSOR, > [Xcursor], > [], > [GB_FIND(Xcursor.h, /usr /usr/local /usr/X11R6, include/X11/Xcursor)], > [GB_FIND(libXcursor.$SHLIBEXT, /usr /usr/local /usr/X11R6, lib lib/X11R6/)], > [-lXcursor], > [], > ["Support for colorized cursors"]) > > GB_COMPONENT( > sdl, > SDL, > [SDL], > [src], > [GB_FIND(SDL_opengl.h SDL.h SDL_image.h, `sdl-config --prefix`, > include/SDL)], > [GB_FIND(libSDL_image.$SHLIBEXT , /usr /usr/X11R6 /usr/local > `sdl-config --prefix`, lib)], > [`sdl-config --libs` -lSDL_image -lGL -lGLU], > [`sdl-config --cflags`]) > > GB_COMPONENT( > sdl_sound, > SDL_SOUND, > [SDL sound], > [sound], > [GB_FIND(SDL_mixer.h SDL_cdrom.h, `sdl-config --prefix`, include/SDL)], > [GB_FIND(libSDL_mixer.$SHLIBEXT, /usr /usr/local `sdl-config --prefix`, > lib)], > [`sdl-config --libs` -lSDL_mixer], > [`sdl-config --cflags`]) > --8<----------- > > GB_FIND(F1 F2 F3, A1 A2 A3, B1 B2 B3) means that the files F1, F2 and F3 must > be located in all combinations of (A1 A2 A3)*(B1 B2 B3) directories. > > So there, libXCursor.so is searched into: > * /usr/lib > * /usr/local/lib > * /usr/X11R6/lib > * /usr/lib/X11R6 > * /usr/local/lib/X11R6 > * /usr/X11R6/lib/X11R6 > > For all SDL components, the searched files are: > * XCursor.h > * libXCursor.so > * SDL_opengl.h > * SDL.h > * SDL_image.h > * libSDL_image.so > * SDL_mixer.h > * SDL_cdrom.h > * libSDL_mixer.so > > You can see to that the 'sdl-config' program is needed. > > For MySQL component: > > --8<----------- > GB_COMPONENT( > mysql, > MYSQL, > [MySQL driver], > [src], > [GB_FIND(mysql.h my_config.h, /usr/local/lib /usr/local /opt /usr/lib /usr, > include mysql*/include)], > [GB_FIND(libmysqlclient.$SHLIBEXT, /usr/local /opt /usr, lib mysql*/lib)], > [$C_LIB -lmysqlclient -lz]) > --8<----------- > > The files mysql.h and my_config.h are searched in a bunch of different > directorys, as well the libmysqlclient.so library. > > In a few words, you must check: > > 1) That all these files are installed on your system. On Mandriva, I can > search a package from a file included in it. > > 2) That the files are located in a directory specified by the GB_FIND() macro. > Otherwise, tell me which directory is missing so that I add it in the macro > call. > > Regards, > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Mon Oct 9 20:14:49 2006 From: gambas at ...1... (Benoit Minisini) Date: Mon, 9 Oct 2006 20:14:49 +0200 Subject: [Gambas-user] Gambas 1.9.44 problem In-Reply-To: <000901c6ebca$6b489d80$6401a8c0@...1587...> References: <000901c6ebca$6b489d80$6401a8c0@...1587...> Message-ID: <200610092014.50026.gambas@...1...> On Monday 09 October 2006 19:43, Timothy Marshal-Nichols wrote: > > -----Original Message----- > > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > > bounces at lists.sourceforge.net] On Behalf Of Benoit Minisini > > Sent: 09 October 2006 17:17 > > To: mailing list for gambas users > > Subject: Re: [Gambas-user] Gambas 1.9.44 problem > > > > On Monday 09 October 2006 16:49, Andrea Bortolan wrote: > > > Hi all, > > > I'm facing a strange problem using Gambas 1.9.44. > > > I started a new project, in the FMain Form I added a new Separator, > > this > > > is > > > > > showed correclty but, when I try to change its Foreground color > > gambas > > > > raises this error : This appication has raised an unexpected error > > and > > > must > > > > > abort. > > > [11] Unknow symbol 'Container' in class 'ListContainer', > > > FColorChooser.AddColor.45 > > > > > > Any idea about what I'm doing wrong ? > > > Thanks a lot, Andrea. > > > > This bug has been fixed in the svn repository. You must edit the line > > 45 > > > of > > FColorChooser.class and remove '.Container'. > > > > Regards, > > > > -- > > Benoit Minisini > > I have just updated Gambas from 1.9.43 to 1.9.44. Now I can not open the > Gambas IDE at all. This is the full text of message box that is shown: > > This application has raised an unexpected > error and must abort > [11] Unknown symbol 'Container' in class 'ToolBar'. > ToolBar._new.26 > > I can run Gambas projects that have already been compiled. But the IDE > will not open. > > Any ideas? > > Thanks > > 8-) Timothy Marshal-Nichols > > I think you didn't correctly uninstall the 1.9.43 and install correctly the 1.9.44. The error message is on a code that exists in 1.9.43 but not in 1.9.44. Regards, -- Benoit Minisini From brian at ...1334... Mon Oct 9 20:27:10 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 09 Oct 2006 11:27:10 -0700 (PDT) Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 In-Reply-To: <200610091924.42042.gambas@...1...> References: <20061009100734.W92800@...1337...> <200610091924.42042.gambas@...1...> Message-ID: <20061009112559.I93171@...1337...> On Mon, 9 Oct 2006, Benoit Minisini wrote: Here's my SDL files: cowboy at ...56...:~> find /usr/include/ -name "SDL*" 2>/dev/null /usr/include/SDL /usr/include/SDL/SDL_mouse.h /usr/include/SDL/SDL_syswm.h /usr/include/SDL/SDL_version.h /usr/include/SDL/SDL.h /usr/include/SDL/SDL_net.h /usr/include/SDL/SDL_mutex.h /usr/include/SDL/SDL_gfxPrimitives.h /usr/include/SDL/SDL_ttf.h /usr/include/SDL/SDL_cpuinfo.h /usr/include/SDL/SDL_types.h /usr/include/SDL/SDL_framerate.h /usr/include/SDL/SDL_video.h /usr/include/SDL/SDL_main.h /usr/include/SDL/SDL_name.h /usr/include/SDL/SDL_gfxPrimitives_font.h /usr/include/SDL/SDL_rotozoom.h /usr/include/SDL/SDL_imageFilter.h /usr/include/SDL/SDL_endian.h /usr/include/SDL/SDL_quit.h /usr/include/SDL/SDL_audio.h /usr/include/SDL/SDL_image.h /usr/include/SDL/SDL_getenv.h /usr/include/SDL/SDL_cdrom.h /usr/include/SDL/SDL_events.h /usr/include/SDL/SDL_active.h /usr/include/SDL/SDL_byteorder.h /usr/include/SDL/SDL_loadso.h /usr/include/SDL/SDL_opengl.h /usr/include/SDL/SDL_thread.h /usr/include/SDL/SDL_joystick.h /usr/include/SDL/SDL_keyboard.h /usr/include/SDL/SDL_rwops.h /usr/include/SDL/SDL_keysym.h /usr/include/SDL/SDL_error.h /usr/include/SDL/SDL_copying.h /usr/include/SDL/SDL_mixer.h /usr/include/SDL/SDL_timer.h /usr/include/SDLmm cowboy at ...56...:~> sdl-config --prefix /usr cowboy at ...56...:~> The configure script for 1.9.44 is indicating the sdl compnent will not be built. > Date: Mon, 9 Oct 2006 19:24:41 +0200 > From: Benoit Minisini > Reply-To: mailing list for gambas users > > To: mailing list for gambas users > Subject: Re: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 > > On Monday 09 October 2006 19:08, Christopher Brian Jack wrote: > > I'm having extreme problems getting 1.9.44 to build under SuSE 10.0 > > > > Seems despite having every delvopment pakage install I cannot get SDL or > > MySQL support and just three tiers into the configure chain (I'm wondering > > at this point what else it won't find). > > > > I've tried the build about 20 times. Unless some other soul has gotten > > the 1.9.44 dev build of gambas to compile and has a binary package I could > > use I'm ready to give up. > > > > Qt/KDE2+ (3.5 preferably), MySQL, all SDL support are necessities for my > > needs. > > > > About to pull out all hair, > > Brian > > > > .=================================================. > > > > | Christopher BRIAN Jack aka "Gau of the Veldt" | > > > > +=================================================' > > > > | oevna at ...1544... > > > > `=================================================- > > Hi Spambots, my email address is sputnik at ...1334... > > Hi Humans, my email address uses rot13 cipher > > > > To know what configure looks for, you must read the configure.ac file. > > For SDL: > > --8<----------- > GB_COMPONENT( > Xcursor, > XCURSOR, > [Xcursor], > [], > [GB_FIND(Xcursor.h, /usr /usr/local /usr/X11R6, include/X11/Xcursor)], > [GB_FIND(libXcursor.$SHLIBEXT, /usr /usr/local /usr/X11R6, lib lib/X11R6/)], > [-lXcursor], > [], > ["Support for colorized cursors"]) > > GB_COMPONENT( > sdl, > SDL, > [SDL], > [src], > [GB_FIND(SDL_opengl.h SDL.h SDL_image.h, `sdl-config --prefix`, > include/SDL)], > [GB_FIND(libSDL_image.$SHLIBEXT , /usr /usr/X11R6 /usr/local > `sdl-config --prefix`, lib)], > [`sdl-config --libs` -lSDL_image -lGL -lGLU], > [`sdl-config --cflags`]) > > GB_COMPONENT( > sdl_sound, > SDL_SOUND, > [SDL sound], > [sound], > [GB_FIND(SDL_mixer.h SDL_cdrom.h, `sdl-config --prefix`, include/SDL)], > [GB_FIND(libSDL_mixer.$SHLIBEXT, /usr /usr/local `sdl-config --prefix`, > lib)], > [`sdl-config --libs` -lSDL_mixer], > [`sdl-config --cflags`]) > --8<----------- > > GB_FIND(F1 F2 F3, A1 A2 A3, B1 B2 B3) means that the files F1, F2 and F3 must > be located in all combinations of (A1 A2 A3)*(B1 B2 B3) directories. > > So there, libXCursor.so is searched into: > * /usr/lib > * /usr/local/lib > * /usr/X11R6/lib > * /usr/lib/X11R6 > * /usr/local/lib/X11R6 > * /usr/X11R6/lib/X11R6 > > For all SDL components, the searched files are: > * XCursor.h > * libXCursor.so > * SDL_opengl.h > * SDL.h > * SDL_image.h > * libSDL_image.so > * SDL_mixer.h > * SDL_cdrom.h > * libSDL_mixer.so > > You can see to that the 'sdl-config' program is needed. > > For MySQL component: > > --8<----------- > GB_COMPONENT( > mysql, > MYSQL, > [MySQL driver], > [src], > [GB_FIND(mysql.h my_config.h, /usr/local/lib /usr/local /opt /usr/lib /usr, > include mysql*/include)], > [GB_FIND(libmysqlclient.$SHLIBEXT, /usr/local /opt /usr, lib mysql*/lib)], > [$C_LIB -lmysqlclient -lz]) > --8<----------- > > The files mysql.h and my_config.h are searched in a bunch of different > directorys, as well the libmysqlclient.so library. > > In a few words, you must check: > > 1) That all these files are installed on your system. On Mandriva, I can > search a package from a file included in it. > > 2) That the files are located in a directory specified by the GB_FIND() macro. > Otherwise, tell me which directory is missing so that I add it in the macro > call. > > Regards, > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Tue Oct 10 02:04:13 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 09 Oct 2006 17:04:13 -0700 (PDT) Subject: [Gambas-user] gamabs2 configure cannot find firebird Message-ID: <20061009170122.S94429@...1337...> Why isn't gambas2 1.9.44 recognizing my install of firebird? System: Debian/Sarge Linux ================================ 8x ================================= checking for firebird driver headers... checking for firebird driver libraries... no configure: WARNING: *** firebird driver is disabled configure: creating ./config.status config.status: creating Makefile config.status: creating src/Makefile config.status: creating config.h config.status: config.h is unchanged config.status: executing depfiles commands nall:/home/brian/gambas2-1.9.44/gb.db.firebird# cat gb.db.firebird/configure.ac cat: gb.db.firebird/configure.ac: No such file or directory nall:/home/brian/gambas2-1.9.44/gb.db.firebird# configure.ac bash: configure.ac: command not found nall:/home/brian/gambas2-1.9.44/gb.db.firebird# cat configure.ac dnl ---- configure.ac for gb.db.firebird driver AC_INIT(configure.ac) GB_INIT(gb.db.firebird) AC_PROG_LIBTOOL dnl -- Only the presence of libfbclient.so.2 is tested. Apparently, no link is needed? GB_COMPONENT( firebird, FIREBIRD, [firebird driver], [src], [], [GB_FIND(libfbclient.$SHLIBEXT.2, /usr/local /opt /usr, lib firebird2*/lib firebird*/lib lib/firebird2* lib/firebird*)], []) AC_OUTPUT( \ Makefile \ src/Makefile \ ) nall:/home/brian/gambas2-1.9.44/gb.db.firebird# find /usr -name "libfbc*" /usr/lib/libfbclient.so /usr/lib/libfbclient.so.1.5.3 /usr/lib/libfbclient.so.1 /usr/lib/firebird2/lib/libfbclient.so /usr/share/doc/libfbclient1 nall:/home/brian/gambas2-1.9.44/gb.db.firebird# find /usr/ -name "libfbcl*" /usr/lib/libfbclient.so /usr/lib/libfbclient.so.1.5.3 /usr/lib/libfbclient.so.1 /usr/lib/firebird2/lib/libfbclient.so /usr/share/doc/libfbclient1 nall:/home/brian/gambas2-1.9.44/gb.db.firebird# ================================ 8x ================================= .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Tue Oct 10 02:05:12 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 09 Oct 2006 17:05:12 -0700 (PDT) Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 Message-ID: <20061009170426.X94429@...1337...> Here's my SDL files: cowboy at ...56...:~> find /usr/include/ -name "SDL*" 2>/dev/null /usr/include/SDL /usr/include/SDL/SDL_mouse.h /usr/include/SDL/SDL_syswm.h /usr/include/SDL/SDL_version.h /usr/include/SDL/SDL.h /usr/include/SDL/SDL_net.h /usr/include/SDL/SDL_mutex.h /usr/include/SDL/SDL_gfxPrimitives.h /usr/include/SDL/SDL_ttf.h /usr/include/SDL/SDL_cpuinfo.h /usr/include/SDL/SDL_types.h /usr/include/SDL/SDL_framerate.h /usr/include/SDL/SDL_video.h /usr/include/SDL/SDL_main.h /usr/include/SDL/SDL_name.h /usr/include/SDL/SDL_gfxPrimitives_font.h /usr/include/SDL/SDL_rotozoom.h /usr/include/SDL/SDL_imageFilter.h /usr/include/SDL/SDL_endian.h /usr/include/SDL/SDL_quit.h /usr/include/SDL/SDL_audio.h /usr/include/SDL/SDL_image.h /usr/include/SDL/SDL_getenv.h /usr/include/SDL/SDL_cdrom.h /usr/include/SDL/SDL_events.h /usr/include/SDL/SDL_active.h /usr/include/SDL/SDL_byteorder.h /usr/include/SDL/SDL_loadso.h /usr/include/SDL/SDL_opengl.h /usr/include/SDL/SDL_thread.h /usr/include/SDL/SDL_joystick.h /usr/include/SDL/SDL_keyboard.h /usr/include/SDL/SDL_rwops.h /usr/include/SDL/SDL_keysym.h /usr/include/SDL/SDL_error.h /usr/include/SDL/SDL_copying.h /usr/include/SDL/SDL_mixer.h /usr/include/SDL/SDL_timer.h /usr/include/SDLmm cowboy at ...56...:~> sdl-config --prefix /usr cowboy at ...56...:~> The configure script for 1.9.44 is indicating the sdl compnent will not be built. On Mon, 9 Oct 2006, Benoit Minisini wrote: > Date: Mon, 9 Oct 2006 19:24:41 +0200 > From: Benoit Minisini > Reply-To: mailing list for gambas users > > To: mailing list for gambas users > Subject: Re: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 > > On Monday 09 October 2006 19:08, Christopher Brian Jack wrote: > > I'm having extreme problems getting 1.9.44 to build under SuSE 10.0 > > > > Seems despite having every delvopment pakage install I cannot get SDL or > > MySQL support and just three tiers into the configure chain (I'm wondering > > at this point what else it won't find). > > > > I've tried the build about 20 times. Unless some other soul has gotten > > the 1.9.44 dev build of gambas to compile and has a binary package I could > > use I'm ready to give up. > > > > Qt/KDE2+ (3.5 preferably), MySQL, all SDL support are necessities for my > > needs. > > > > About to pull out all hair, > > Brian > > > > .=================================================. > > > > | Christopher BRIAN Jack aka "Gau of the Veldt" | > > > > +=================================================' > > > > | oevna at ...1544... > > > > `=================================================- > > Hi Spambots, my email address is sputnik at ...1334... > > Hi Humans, my email address uses rot13 cipher > > > > To know what configure looks for, you must read the configure.ac file. > > For SDL: > > --8<----------- > GB_COMPONENT( > Xcursor, > XCURSOR, > [Xcursor], > [], > [GB_FIND(Xcursor.h, /usr /usr/local /usr/X11R6, include/X11/Xcursor)], > [GB_FIND(libXcursor.$SHLIBEXT, /usr /usr/local /usr/X11R6, lib lib/X11R6/)], > [-lXcursor], > [], > ["Support for colorized cursors"]) > > GB_COMPONENT( > sdl, > SDL, > [SDL], > [src], > [GB_FIND(SDL_opengl.h SDL.h SDL_image.h, `sdl-config --prefix`, > include/SDL)], > [GB_FIND(libSDL_image.$SHLIBEXT , /usr /usr/X11R6 /usr/local > `sdl-config --prefix`, lib)], > [`sdl-config --libs` -lSDL_image -lGL -lGLU], > [`sdl-config --cflags`]) > > GB_COMPONENT( > sdl_sound, > SDL_SOUND, > [SDL sound], > [sound], > [GB_FIND(SDL_mixer.h SDL_cdrom.h, `sdl-config --prefix`, include/SDL)], > [GB_FIND(libSDL_mixer.$SHLIBEXT, /usr /usr/local `sdl-config --prefix`, > lib)], > [`sdl-config --libs` -lSDL_mixer], > [`sdl-config --cflags`]) > --8<----------- > > GB_FIND(F1 F2 F3, A1 A2 A3, B1 B2 B3) means that the files F1, F2 and F3 must > be located in all combinations of (A1 A2 A3)*(B1 B2 B3) directories. > > So there, libXCursor.so is searched into: > * /usr/lib > * /usr/local/lib > * /usr/X11R6/lib > * /usr/lib/X11R6 > * /usr/local/lib/X11R6 > * /usr/X11R6/lib/X11R6 > > For all SDL components, the searched files are: > * XCursor.h > * libXCursor.so > * SDL_opengl.h > * SDL.h > * SDL_image.h > * libSDL_image.so > * SDL_mixer.h > * SDL_cdrom.h > * libSDL_mixer.so > > You can see to that the 'sdl-config' program is needed. > > For MySQL component: > > --8<----------- > GB_COMPONENT( > mysql, > MYSQL, > [MySQL driver], > [src], > [GB_FIND(mysql.h my_config.h, /usr/local/lib /usr/local /opt /usr/lib /usr, > include mysql*/include)], > [GB_FIND(libmysqlclient.$SHLIBEXT, /usr/local /opt /usr, lib mysql*/lib)], > [$C_LIB -lmysqlclient -lz]) > --8<----------- > > The files mysql.h and my_config.h are searched in a bunch of different > directorys, as well the libmysqlclient.so library. > > In a few words, you must check: > > 1) That all these files are installed on your system. On Mandriva, I can > search a package from a file included in it. > > 2) That the files are located in a directory specified by the GB_FIND() macro. > Otherwise, tell me which directory is missing so that I add it in the macro > call. > > Regards, > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From ronstk at ...239... Tue Oct 10 02:30:04 2006 From: ronstk at ...239... (Ron Onstenk) Date: Tue, 10 Oct 2006 02:30:04 +0200 Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 In-Reply-To: <200610091924.42042.gambas@...1...> References: <20061009100734.W92800@...1337...> <200610091924.42042.gambas@...1...> Message-ID: <200610100230.04670.ronstk@...239...> On Monday 09 October 2006 19:24, Benoit Minisini wrote: > GB_COMPONENT( > ? sdl_sound, > ? SDL_SOUND, > ? [SDL sound], > ? [sound], > ? [GB_FIND(SDL_mixer.h SDL_cdrom.h, `sdl-config --prefix`, include/SDL)], > ? [GB_FIND(libSDL_mixer.$SHLIBEXT, /usr /usr/local `sdl-config --prefix`, > ? lib)], > ? [`sdl-config --libs` -lSDL_mixer], > ? [`sdl-config --cflags`]) > May I interupt this? I'm using SuSE 1.0 (extreme case) and my packages compiled by SuSE using SDL v1.0. Now I find a nice program thet need SDL v 8.8 so I downloas the source and compile myself. SuSE make sure the result it is in /usr/local/bin /usr/bin is the standard distribution global place for system wide on the box /usr/local/bin is the private place for system wide on the box done by owner. /home/ron/bin when the user only should touch it and is approved to be correct. /home/ron/local/bin the same for the user for trial before it is actulized into bin (if he wants) I can never compile gambas 1.9.44 because the SDL version is to low. Compiling SDL into /usr/bin with --prefix=/usr/bin is also not allowed because it breaks the precompiled packages from SuSE (or other distributions) When I do compile SDL with --prefix=/usr/local ( as SuSE does default) then no conflict will occur. > [GB_FIND(libSDL_mixer.$SHLIBEXT, /usr /usr/local `sdl-config --prefix`, > lib)], > [`sdl-config --libs` -lSDL_mixer], [`sdl-config --cflags`]) This could find "libSDL_mixer.$SHLIBEXT" in /usr /usr/local `sdl-config --prefix` Which one will be used? If it is the first one this is/could be wrong regarding the private updated box to higher versions without conflict to the basic version of the distribution. > --8<----------- > GB_COMPONENT( >? mysql, >? MYSQL, > ? [MySQL driver], >? [src], >? [GB_FIND(mysql.h my_config.h, /usr/local/lib /usr/local /opt /usr/lib /usr, > include mysql*/include)], > ? [GB_FIND(libmysqlclient.$SHLIBEXT, /usr/local /opt /usr, lib mysql*/lib)], > ? [$C_LIB -lmysqlclient -lz]) > --8<----------- Here the order of search is reversed. I had very long ago the same version problem with CURL requirements against available SuSE version where the packet manager (Yast) had strong dependency on. `curl-config --prefix` returns the updated version location for new compile actions. Reversing the order as /usr/local /usr `curl-config --prefix` solved the problem As far I know it is recommended to do all private updates of programs and libraries in /usr/local to keep the distributions tree as clean as possible with non global (real world wide installations) except if the distribution require this global update. Ron From ronstk at ...239... Tue Oct 10 02:48:02 2006 From: ronstk at ...239... (Ron Onstenk) Date: Tue, 10 Oct 2006 02:48:02 +0200 Subject: [Gambas-user] Compiling Gamabas2 (1.9.44) in SuSE 10.0 In-Reply-To: <20061009102641.I92913@...1337...> References: <20061009100734.W92800@...1337...> <200610091924.42042.gambas@...1...> <20061009102641.I92913@...1337...> Message-ID: <200610100248.02718.ronstk@...239...> On Monday 09 October 2006 19:43, Christopher Brian Jack wrote: > On Mon, 9 Oct 2006, Benoit Minisini wrote: > > I'm really clueless about the whole configure/automake system. I tried to > use it once for one of my own projects and it really didn't simplify the > process any. I just endup up pulling out hair and going to handcrafted > build scripts. > > Configure.ac (and all its macros) read to me like Greek (and no, I don't > know Greek). I feel with you. It looks almost stupid those *.am/*.ac It is however you need to understand what the macros should do. In most cases it should simplify lot of bash script lines into functions. For the 'autoxxxx' there are some more special substitutes and methods special for this kind of bash scripts. After my understanding how the config.ac, made by Benoit, works I must tell he did a clever job also in that range of programming. It would be nice to get a full correct description of this part for people to add the relevant part for there component. > > Is XCursor a separate package? SDL requires it but having all the SDL > devs installed does not make this file present anywhere on my system. > When I need to look for a file I use: > > find / -name "" 2>/dev/null > (the redirect of stderr is becuase find / looks in things like devnodes > and /var which includes a lot of things that find won't be able to stat) > > Hence: > cowboy at ...56...:~> find / -name XCursor.h 2>/dev/null > cowboy at ...56...:~> > > Indicates the abosulte abscence of this file anywhere on my system. > Hi. I do use "locate" ron at ...1311...:~> locate Xcursor /usr/X11R6/include/X11/Xcursor /usr/X11R6/include/X11/Xcursor/Xcursor.h /usr/X11R6/lib/libXcursor.a /usr/X11R6/lib/libXcursor.so /usr/X11R6/lib/libXcursor.so.1 /usr/X11R6/lib/libXcursor.so.1.0.2 /usr/X11R6/lib/X11/doc/html/Xcursor.3.html /usr/X11R6/man/man3/Xcursor.3x.gz I had to install the 'find' package to get 'locate' on SuSE 8.2 and 9.2. Ron From ronstk at ...239... Tue Oct 10 02:55:26 2006 From: ronstk at ...239... (Ron Onstenk) Date: Tue, 10 Oct 2006 02:55:26 +0200 Subject: [Gambas-user] gamabs2 configure cannot find firebird In-Reply-To: <20061009170122.S94429@...1337...> References: <20061009170122.S94429@...1337...> Message-ID: <200610100255.26654.ronstk@...239...> On Tuesday 10 October 2006 02:04, Christopher Brian Jack wrote: > ? [GB_FIND(libfbclient.$SHLIBEXT.2, /usr/local /opt /usr, lib > firebird2*/lib firebird*/lib lib/firebird2* lib/firebird*)], > ? []) > > AC_OUTPUT( \ > Makefile \ > src/Makefile \ > ) > nall:/home/brian/gambas2-1.9.44/gb.db.firebird# find /usr -name "libfbc*" > /usr/lib/libfbclient.so > /usr/lib/libfbclient.so.1.5.3 > /usr/lib/libfbclient.so.1 > /usr/lib/firebird2/lib/libfbclient.so > /usr/share/doc/libfbclient1 > > nall:/home/brian/gambas2-1.9.44/gb.db.firebird# find /usr/ -name "libfbcl*" and what about: find /usr/ -name "libfbc2*" <-- not the 2 instead 1 configure.ac looks for lib/firebird2* and lib/firebird* Ron From leonardo at ...1237... Tue Oct 10 10:57:05 2006 From: leonardo at ...1237... (Leonardo Miliani) Date: Tue, 10 Oct 2006 10:57:05 +0200 Subject: [Gambas-user] test In-Reply-To: <200610071446.22217.sirfabien@...626...> References: <200610071446.22217.sirfabien@...626...> Message-ID: <452B6061.5060802@...1237...> Fabien Bodard ha scritto: > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > TEST -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software From leonardo at ...1237... Tue Oct 10 11:02:15 2006 From: leonardo at ...1237... (Leonardo Miliani) Date: Tue, 10 Oct 2006 11:02:15 +0200 Subject: [Gambas-user] Again problems with SpamCop. Message-ID: <452B6197.9010508@...1237...> Sorry if I write again against about the SpamCop service but it's very ANNOYNG! A day I can write to the mailing list, the next one no because it tells me that my SMTP/ISP is in its black list! ---------------------------------------- This is an automatically generated Delivery Status Notification. Delivery to the following recipients failed. gambas-user at lists.sourceforge.net Reporting-MTA: dns;smtp-out03.alice.it Received-From-MTA: dns;FBCMMO03.fbc.local Arrival-Date: Mon, 9 Oct 2006 23:42:46 +0200 Final-Recipient: rfc822;gambas-user at lists.sourceforge.net Action: failed Status: 5.5.0 Diagnostic-Code: smtp;550-"rejected because your SMTP server, xx.xx.xx.xx, is in the Spamcop RBL. 550 See http://www.spamcop.net/bl.shtml for more information." --------------------------------- Yesterday it refused a mail of mine, today it accepts my mails. problems... Is there a way to solve this problem??? -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software From andrea_bortolan at ...325... Tue Oct 10 11:18:48 2006 From: andrea_bortolan at ...325... (Andrea Bortolan) Date: Tue, 10 Oct 2006 11:18:48 +0200 (CEST) Subject: [Gambas-user] Gambas 1.9.44 problem In-Reply-To: <200610091816.34034.gambas@...1...> Message-ID: <20061010091848.6952.qmail@...905...> Thanks a lot Benoit, it worked fine..... Just another silly question : I need to create a big form but the IDE stop me at 1024 x 1024 what I'm doing wrong this time ? Ciao, Andrea. Benoit Minisini ha scritto: On Monday 09 October 2006 16:49, Andrea Bortolan wrote: > Hi all, > I'm facing a strange problem using Gambas 1.9.44. > I started a new project, in the FMain Form I added a new Separator, this is > showed correclty but, when I try to change its Foreground color gambas > raises this error : This appication has raised an unexpected error and must > abort. > [11] Unknow symbol 'Container' in class 'ListContainer', > FColorChooser.AddColor.45 > > Any idea about what I'm doing wrong ? > Thanks a lot, Andrea. > > This bug has been fixed in the svn repository. You must edit the line 45 of FColorChooser.class and remove '.Container'. Regards, -- Benoit Minisini ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Gambas-user mailing list Gambas-user at lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user __________________________________________________ Do You Yahoo!? Poco spazio e tanto spam? Yahoo! Mail ti protegge dallo spam e ti da tanto spazio gratuito per i tuoi file e i messaggi http://mail.yahoo.it From ronstk at ...239... Tue Oct 10 16:35:52 2006 From: ronstk at ...239... (Ron Onstenk) Date: Tue, 10 Oct 2006 16:35:52 +0200 Subject: [Gambas-user] Again problems with SpamCop. In-Reply-To: <452B6197.9010508@...1237...> References: <452B6197.9010508@...1237...> Message-ID: <200610101635.53410.ronstk@...239...> On Tuesday 10 October 2006 11:02, Leonardo Miliani wrote: > Sorry if I write again against about the SpamCop service but it's very > ANNOYNG! > A day I can write to the mailing list, the next one no because it tells > me that my SMTP/ISP is in its black list! > > ---------------------------------------- > > This is an automatically generated Delivery Status Notification. > > Delivery to the following recipients failed. > > ? ? ? ?gambas-user at lists.sourceforge.net > > > > > > Reporting-MTA: dns;smtp-out03.alice.it > Received-From-MTA: dns;FBCMMO03.fbc.local > Arrival-Date: Mon, 9 Oct 2006 23:42:46 +0200 > > Final-Recipient: rfc822;gambas-user at lists.sourceforge.net > Action: failed > Status: 5.5.0 > Diagnostic-Code: smtp;550-"rejected because your SMTP server, > xx.xx.xx.xx, is in the Spamcop RBL. > 550 See http://www.spamcop.net/bl.shtml for more information." > > --------------------------------- > Yesterday it refused a mail of mine, today it accepts my mails. problems... > > Is there a way to solve this problem??? > Yes but you don't like it. The ISP alice.it is well known to be a source of spammers. liberto.it is also on that list :( The change of your ISP or using at least a email account at another ISP could solve the problem. Ron From gambas at ...1... Tue Oct 10 18:04:50 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 10 Oct 2006 18:04:50 +0200 Subject: [Gambas-user] Again problems with SpamCop. In-Reply-To: <452B6197.9010508@...1237...> References: <452B6197.9010508@...1237...> Message-ID: <200610101804.50882.gambas@...1...> On Tuesday 10 October 2006 11:02, Leonardo Miliani wrote: > Sorry if I write again against about the SpamCop service but it's very > ANNOYNG! > A day I can write to the mailing list, the next one no because it tells > me that my SMTP/ISP is in its black list! > With wanadoo, I solved the problem by using one of their SMTP server that needs authentification. -- Benoit Minisini From gambas at ...1... Tue Oct 10 18:41:54 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 10 Oct 2006 18:41:54 +0200 Subject: [Gambas-user] gamabs2 configure cannot find firebird In-Reply-To: <20061009170122.S94429@...1337...> References: <20061009170122.S94429@...1337...> Message-ID: <200610101841.54546.gambas@...1...> On Tuesday 10 October 2006 02:04, Christopher Brian Jack wrote: > Why isn't gambas2 1.9.44 recognizing my install of firebird? > System: Debian/Sarge Linux > > ================================ 8x ================================= > checking for firebird driver headers... > checking for firebird driver libraries... no > configure: WARNING: *** firebird driver is disabled > configure: creating ./config.status > config.status: creating Makefile > config.status: creating src/Makefile > config.status: creating config.h > config.status: config.h is unchanged > config.status: executing depfiles commands > nall:/home/brian/gambas2-1.9.44/gb.db.firebird# cat > gb.db.firebird/configure.ac > cat: gb.db.firebird/configure.ac: No such file or directory > nall:/home/brian/gambas2-1.9.44/gb.db.firebird# configure.ac > bash: configure.ac: command not found > nall:/home/brian/gambas2-1.9.44/gb.db.firebird# cat configure.ac > dnl ---- configure.ac for gb.db.firebird driver > > AC_INIT(configure.ac) > GB_INIT(gb.db.firebird) > AC_PROG_LIBTOOL > > dnl -- Only the presence of libfbclient.so.2 is tested. Apparently, no > link is needed? > > GB_COMPONENT( > firebird, > FIREBIRD, > [firebird driver], > [src], > [], > [GB_FIND(libfbclient.$SHLIBEXT.2, /usr/local /opt /usr, lib > firebird2*/lib firebird*/lib lib/firebird2* lib/firebird*)], > []) > Try to replace 'GB_FIND(libfbclient.$SHLIBEXT.2 ...)' by 'GB_FIND(libfbclient. $SHLIBEXT ...)'. Then do: $ cd gb.db.firebird $ ./reconf $ ./configure Tell me the result! Regards, -- Benoit Minisini From brian at ...1334... Tue Oct 10 19:24:08 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 10 Oct 2006 10:24:08 -0700 (PDT) Subject: [Gambas-user] DrawingArea problems Message-ID: <20061010102357.M98745@...1337...> Is there a glitch with drawing to DrawingAreas? My former code to use a backbuffer: ========== 8x ================================== private backBuffer as Picture public sub Form_Open() '... backBuffer=new Picture(640,480,FALSE) '... End public sub Render() Draw.Begin(GfxArea) 'GfxArea is a DrawingArea Draw.Picture(backBuffer,0,0,0,0,640,480) 'buckBuffer is a Picture Draw.End() 'Blank back buffer Draw.Begin(backBuffer) FillRect(0,0,640,480,&H000000&) Draw.End() End ========== 8x ================================== Is not drawing to the DrawingArea any more. Is there a semantic that changed that makes this so it has to be done differently or is something in 1.9.44 broken thus causing this...? Also my other form elements seem to want to go into the background with the DrawingArea in front but not accepting event focus. I tried adding a GfxArea.SetFocus() to the Form_Open code but to no avail (still starts up in front without event focus until I explicitly click on it with the mouse). I also haven't been able to properly get the other form elements to show in front (of other windows/forms) but behind the DrawingArea control of the form. ---PS--- Yes I fixed almost all the compile problems but I gave up on getting Firebird support to work. Ultimately once I debug the AI technology in my game I'll be able to use sqlite or (g)dbm (non-server DB drivers) to hold the AI knowledge base. Right now I need to be able to snoop on it while the game is live which is what makes a live SQL server a good idea for the time being. ------- .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Tue Oct 10 19:20:14 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 10 Oct 2006 10:20:14 -0700 (PDT) Subject: [Gambas-user] DrawingArea problems Message-ID: <20061010100510.K98410@...1337...> Is there a glitch with drawing to DrawingAreas? My former code to use a backbuffer: ========== 8x ================================== private backBuffer as Picture public sub Form_Open() '... backBuffer=new Picture(640,480,FALSE) '... End public sub Render() Draw.Begin(GfxArea) 'GfxArea is a DrawingArea Draw.Picture(backBuffer,0,0,0,0,640,480) 'buckBuffer is a Picture Draw.End() 'Blank back buffer Draw.Begin(backBuffer) FillRect(0,0,640,480,&H000000&) Draw.End() End ========== 8x ================================== Is not drawing to the DrawingArea any more. Is there a semantic that changed that makes this so it has to be done differently or is something in 1.9.44 broken thus causing this...? Also my other form elements seem to want to go into the background with the DrawingArea in front but not accepting event focus. I tried adding a GfxArea.SetFocus() to the Form_Open code but to no avail (still starts up in front without event focus until I explicitly click on it with the mouse). I also haven't been able to properly get the other form elements to show in front (of other windows/forms) but behind the DrawingArea control of the form. ---PS--- Yes I fixed almost all the compile problems but I gave up on getting Firebird support to work. Ultimately once I debug the AI technology in my game I'll be able to use sqlite or (g)dbm (non-server DB drivers) to hold the AI knowledge base. Right now I need to be able to snoop on it while the game is live which is what makes a live SQL server a good idea for the time being. ------- .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Tue Oct 10 19:30:04 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 10 Oct 2006 10:30:04 -0700 (PDT) Subject: [Gambas-user] duplicates... Message-ID: <20061010102936.V98825@...1337...> mailer was acting up... I think my last message ended up going out twice. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From comisat at ...1569... Tue Oct 10 19:31:51 2006 From: comisat at ...1569... (comisat at ...1569...) Date: Tue, 10 Oct 2006 19:31:51 +0200 (CEST) Subject: [Gambas-user] DrawingArea problems In-Reply-To: <20061010102357.M98745@...1337...> References: <20061010102357.M98745@...1337...> Message-ID: <2959.87.0.95.212.1160501511.squirrel@...1570...> > Is not drawing to the DrawingArea any more. is it cached ? > Also my other form elements seem to want to go into the background with > the DrawingArea in front but not accepting event focus. I tried adding a > GfxArea.SetFocus() to the Form_Open code but to no avail (still starts up > in front without event focus until I explicitly click on it with the > mouse). I also haven't been able to properly get the other form elements > to show in front (of other windows/forms) but behind the DrawingArea > control of the form. try to look at object.raise _________________________________________________ * GPG/PGP public key-id: 0xB703A9E2 * http://comisat-games.sourceforge.net * rfc.altervista.org aspetta il tuo contributo * USE=-brain emerge win * "Sulla confezione c'era scritto: necessita' di win9x, winXP o superiore.. ...cosi' ho installato linux" _________________________________________________ From gambas at ...1... Tue Oct 10 19:41:52 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 10 Oct 2006 19:41:52 +0200 Subject: [Gambas-user] DrawingArea problems In-Reply-To: <20061010100510.K98410@...1337...> References: <20061010100510.K98410@...1337...> Message-ID: <200610101941.52433.gambas@...1...> On Tuesday 10 October 2006 19:20, Christopher Brian Jack wrote: > Is there a glitch with drawing to DrawingAreas? > > My former code to use a backbuffer: > > ========== 8x ================================== > > private backBuffer as Picture > > public sub Form_Open() > '... > backBuffer=new Picture(640,480,FALSE) > '... > End > > public sub Render() > Draw.Begin(GfxArea) 'GfxArea is a DrawingArea > Draw.Picture(backBuffer,0,0,0,0,640,480) 'buckBuffer is a Picture > Draw.End() > 'Blank back buffer > Draw.Begin(backBuffer) > FillRect(0,0,640,480,&H000000&) > Draw.End() > End > > ========== 8x ================================== > > Is not drawing to the DrawingArea any more. Is there a semantic that > changed that makes this so it has to be done differently or is something > in 1.9.44 broken thus causing this...? > This won't work if you don't set the Drawing.Cached property. Anyway, what you want to do is what is already done by the Drawing.Cached property. Unless you need the back buffer for doing something other than drawing on it... > Also my other form elements seem to want to go into the background with > the DrawingArea in front but not accepting event focus. I tried adding a > GfxArea.SetFocus() to the Form_Open code but to no avail (still starts up > in front without event focus until I explicitly click on it with the > mouse). Use the hierarchy window to know the control focus order. > I also haven't been able to properly get the other form elements > to show in front (of other windows/forms) but behind the DrawingArea > control of the form. ???? I don't understand what you are talking about. > > ---PS--- > Yes I fixed almost all the compile problems but I gave up on getting > Firebird support to work. Did you try what I asked you to try ? > Ultimately once I debug the AI technology in my > game I'll be able to use sqlite or (g)dbm (non-server DB drivers) to hold > the AI knowledge base. Right now I need to be able to snoop on it while > the game is live which is what makes a live SQL server a good idea for the > time being. Regards, -- Benoit Minisini From brian at ...1334... Tue Oct 10 19:39:36 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 10 Oct 2006 10:39:36 -0700 (PDT) Subject: [Gambas-user] DrawingArea problems In-Reply-To: <2959.87.0.95.212.1160501511.squirrel@...1570...> References: <20061010102357.M98745@...1337...> <2959.87.0.95.212.1160501511.squirrel@...1570...> Message-ID: <20061010103242.Q98854@...1337...> On Tue, 10 Oct 2006 comisat at ...1569... wrote: > > Is not drawing to the DrawingArea any more. > > is it cached ? ^^; ??????? What do you mean by 'cached'? Is that a new property since 1.9.23? > > Also my other form elements seem to want to go into the background with > > the DrawingArea in front but not accepting event focus. I tried adding a > > GfxArea.SetFocus() to the Form_Open code but to no avail (still starts up > > in front without event focus until I explicitly click on it with the > > mouse). I also haven't been able to properly get the other form elements > > to show in front (of other windows/forms) but behind the DrawingArea > > control of the form. > > try to look at object.raise GfxArea.Raise() isn't giving it event focus. I still have to click it with the mouse before it will accept keyboard events. Using both GfxArea.Raise() AND GfxArea.SetFocus() still isn't giving it the input focus (still need to click the mouse). Is there a low level way to inject a harware mouse press into the main event loop until this issue is resolved? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Tue Oct 10 19:56:38 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 10 Oct 2006 10:56:38 -0700 (PDT) Subject: [Gambas-user] DrawingArea problems In-Reply-To: <200610101941.52433.gambas@...1...> References: <20061010100510.K98410@...1337...> <200610101941.52433.gambas@...1...> Message-ID: <20061010104421.E98977@...1337...> On Tue, 10 Oct 2006, Benoit Minisini wrote: > Anyway, what you want to do is what is already done by the Drawing.Cached > property. Unless you need the back buffer for doing something other than > drawing on it... This appears to be a new property. What do I need to set to get the old 1.9.23 behavior? I'd prefer to keep the private backbuffer that way if I need to use something like dirty rectangle to get more speed I can do it on the backbuffer without mucking with system-owned drawables (on windows the locking issues of doing lots of bitmap work on the active surface is nightmarish). > > Also my other form elements seem to want to go into the background with > > the DrawingArea in front but not accepting event focus. I tried adding a > > GfxArea.SetFocus() to the Form_Open code but to no avail (still starts up > > in front without event focus until I explicitly click on it with the > > mouse). > > Use the hierarchy window to know the control focus order. I need to change it programmatically (and I need the attempt to do so to work). > > I also haven't been able to properly get the other form elements > > to show in front (of other windows/forms) but behind the DrawingArea > > control of the form. > > ???? I don't understand what you are talking about. I have to alt-tab to get the rest of the form to be visible other than just the DrawingArea control. > > > > ---PS--- > > Yes I fixed almost all the compile problems but I gave up on getting > > Firebird support to work. > > Did you try what I asked you to try ? Whatever firebird I'm using it doesn't seem to put any files names anything like what gambas is looking for. Debian Testing/Main Firebird2-* 1.5.3.4870-10 Maybe it doesn't like this version of firebird. configure files really look like voodoo to me and I've failed many times to understand how they work. It's the only one that didn't decide it could find it's libraries so I skipped it. If I get some assistance I expend the effort to get the sole component that didn't build otherwise I'm not spending another exhausting all-niter makeworld'ing my entire system to get a single compoent I'm not using to build. Be great to have a complete build but to be honest I didn't even know what firebird was until the build started complaining about it. With every other db driver all I had to do was load them in thru synaptic and configure found them. This one seems to be a black sheep. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From eilert-sprachen at ...221... Wed Oct 11 08:15:55 2006 From: eilert-sprachen at ...221... (Eilert) Date: Wed, 11 Oct 2006 08:15:55 +0200 Subject: [Gambas-user] DrawingArea problems In-Reply-To: <20061010104421.E98977@...1337...> References: <20061010100510.K98410@...1337...> <200610101941.52433.gambas@...1...> <20061010104421.E98977@...1337...> Message-ID: <452C8C1B.90904@...221...> Christopher Brian Jack schrieb: > On Tue, 10 Oct 2006, Benoit Minisini wrote: [...] >>> I also haven't been able to properly get the other form elements >>> to show in front (of other windows/forms) but behind the DrawingArea >>> control of the form. >> ???? I don't understand what you are talking about. > > I have to alt-tab to get the rest of the form to be visible other than > just the DrawingArea control. > Would it be possible to just use the visible property to let the elements appear/disappear programmatically? Regards Rolf From timothy.marshal-nichols at ...247... Wed Oct 11 09:21:09 2006 From: timothy.marshal-nichols at ...247... (Timothy Marshal-Nichols) Date: Wed, 11 Oct 2006 08:21:09 +0100 Subject: [Gambas-user] DrawingArea problems In-Reply-To: <200610101941.52433.gambas@...1...> Message-ID: <000001c6ed05$d464c0f0$6401a8c0@...1587...> > -----Original Message----- > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > bounces at lists.sourceforge.net] On Behalf Of Benoit Minisini > Sent: 10 October 2006 18:42 > To: mailing list for gambas users > Subject: Re: [Gambas-user] DrawingArea problems > > On Tuesday 10 October 2006 19:20, Christopher Brian Jack wrote: > > Is there a glitch with drawing to DrawingAreas? > > > > My former code to use a backbuffer: > > > > ========== 8x ================================== > > > > private backBuffer as Picture > > > > public sub Form_Open() > > '... > > backBuffer=new Picture(640,480,FALSE) > > '... > > End > > > > public sub Render() > > Draw.Begin(GfxArea) 'GfxArea is a DrawingArea > > Draw.Picture(backBuffer,0,0,0,0,640,480) 'buckBuffer is a Picture > > Draw.End() > > 'Blank back buffer > > Draw.Begin(backBuffer) > > FillRect(0,0,640,480,&H000000&) > > Draw.End() > > End > > > > ========== 8x ================================== > > > > Is not drawing to the DrawingArea any more. Is there a semantic that > > changed that makes this so it has to be done differently or is something > > in 1.9.44 broken thus causing this...? > > > > This won't work if you don't set the Drawing.Cached property. > > Anyway, what you want to do is what is already done by the Drawing.Cached > property. Unless you need the back buffer for doing something other than > drawing on it... > I have found that there are two reasons for using a buffer like this: 1. If you have lots of small objects to draw it can look better as you do not see all the background objects draw over the foreground objects. You reduce the screen flicker as objects are drawn. 2. It can be faster, again if you have a lot of objects to draw. Drawing to memory is faster than drawing to the screen. So if background objects get covered by foreground objects. You can speed things up if you draw a more complex picture or image to the screen. Both these points depend on what you are drawing. They are not true in all cases. So you need to experiment. The other point I would make is that I would make the backBuffer an Image. An Image is stored in memory while a Picture is stored on the X server. Thanks 8-) Timothy Marshal-Nichols From gambas at ...1... Wed Oct 11 10:31:33 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 11 Oct 2006 10:31:33 +0200 Subject: [Gambas-user] DrawingArea problems In-Reply-To: <000001c6ed05$d464c0f0$6401a8c0@...1587...> References: <000001c6ed05$d464c0f0$6401a8c0@...1587...> Message-ID: <200610111031.34020.gambas@...1...> On Wednesday 11 October 2006 09:21, Timothy Marshal-Nichols wrote: > > -----Original Message----- > > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > > bounces at lists.sourceforge.net] On Behalf Of Benoit Minisini > > Sent: 10 October 2006 18:42 > > To: mailing list for gambas users > > Subject: Re: [Gambas-user] DrawingArea problems > > > > On Tuesday 10 October 2006 19:20, Christopher Brian Jack wrote: > > > Is there a glitch with drawing to DrawingAreas? > > > > > > My former code to use a backbuffer: > > > > > > ========== 8x ================================== > > > > > > private backBuffer as Picture > > > > > > public sub Form_Open() > > > '... > > > backBuffer=new Picture(640,480,FALSE) > > > '... > > > End > > > > > > public sub Render() > > > Draw.Begin(GfxArea) 'GfxArea is a DrawingArea > > > Draw.Picture(backBuffer,0,0,0,0,640,480) 'buckBuffer is a Picture > > > Draw.End() > > > 'Blank back buffer > > > Draw.Begin(backBuffer) > > > FillRect(0,0,640,480,&H000000&) > > > Draw.End() > > > End > > > > > > ========== 8x ================================== > > > > > > Is not drawing to the DrawingArea any more. Is there a semantic > > that > > > > changed that makes this so it has to be done differently or is > > something > > > > in 1.9.44 broken thus causing this...? > > > > This won't work if you don't set the Drawing.Cached property. > > > > Anyway, what you want to do is what is already done by the > > Drawing.Cached > > > property. Unless you need the back buffer for doing something other > > than > > > drawing on it... > > I have found that there are two reasons for using a buffer like this: > > 1. If you have lots of small objects to draw it can look better as you > do not see all the background objects draw over the foreground objects. > You reduce the screen flicker as objects are drawn. This is exactly what DrawingArea.Cached = True does. > > 2. It can be faster, again if you have a lot of objects to draw. Drawing > to memory is faster than drawing to the screen. So if background objects > get covered by foreground objects. You can speed things up if you draw a > more complex picture or image to the screen. > > Both these points depend on what you are drawing. They are not true in > all cases. So you need to experiment. > > The other point I would make is that I would make the backBuffer an > Image. An Image is stored in memory while a Picture is stored on the X > server. > My God, no! Drawing to memory is always slower than drawing to the screen. Because of what you said: an Image is stored in the client memory, and a Picture is stored on the server. You cannot draw an Image on the screen directly, it must be sent to the server first. And this is slow. There is X extension named XSHM that allows the client to share memory with the X server so that you have a direct access to what is drawn. But apparently it is buggy and so useless. Regards, -- Benoit Minisini From josemar_mariano at ...494... Wed Oct 11 13:46:06 2006 From: josemar_mariano at ...494... (Josemar) Date: Wed, 11 Oct 2006 08:46:06 -0300 Subject: [Gambas-user] example from utilization EXTERN Message-ID: <452CD97E.3050406@...494...> hello sorry my very bad english :) i use gambas 1.0.17 i just load lib extern how to make use statement EXTERN ? statement EXTERN run in gambas 1.0.17 ? tks _______________________________________________________ Voc? quer respostas para suas perguntas? Ou voc? sabe muito e quer compartilhar seu conhecimento? Experimente o Yahoo! Respostas ! http://br.answers.yahoo.com/ From linux at ...1581... Wed Oct 11 15:03:59 2006 From: linux at ...1581... (DivTech) Date: Wed, 11 Oct 2006 06:03:59 -0700 (PDT) Subject: [Gambas-user] gamabs2 configure cannot find firebird In-Reply-To: <200610101841.54546.gambas@...1...> References: <20061009170122.S94429@...1337...> <200610101841.54546.gambas@...1...> Message-ID: <6755918.post@...1379...> >Try to replace 'GB_FIND(libfbclient.$SHLIBEXT.2 ...)' by 'GB_FIND(libfbclient. >$SHLIBEXT ...)'. Then do: > >$cd gb.db.firebird >$./reconf >./configure >>Regards, >-- >Benoit Minisini With the above change now cleanly configures and compiles for me, thanks (Mandriva 2006). Regards, Bill. -- View this message in context: http://www.nabble.com/gamabs2-configure-cannot-find-firebird-tf2413628.html#a6755918 Sent from the gambas-user mailing list archive at Nabble.com. From brian at ...1334... Wed Oct 11 17:53:52 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Wed, 11 Oct 2006 08:53:52 -0700 (PDT) Subject: [Gambas-user] DrawingArea problems In-Reply-To: <000001c6ed05$d464c0f0$6401a8c0@...1587...> References: <000001c6ed05$d464c0f0$6401a8c0@...1587...> Message-ID: <20061011084727.Y1138@...1337...> On Wed, 11 Oct 2006, Timothy Marshal-Nichols wrote: > I have found that there are two reasons for using a buffer like this: > > 1. If you have lots of small objects to draw it can look better as you > do not see all the background objects draw over the foreground objects. > You reduce the screen flicker as objects are drawn. > > 2. It can be faster, again if you have a lot of objects to draw. Drawing > to memory is faster than drawing to the screen. So if background objects > get covered by foreground objects. You can speed things up if you draw a > more complex picture or image to the screen. > > Both these points depend on what you are drawing. They are not true in > all cases. So you need to experiment. You can also do wholesale effects on the buffer data more easily than to the screen and it's also the only way to use a DR (Dirty Rectangle) render algorithm without flicker. > The other point I would make is that I would make the backBuffer an > Image. An Image is stored in memory while a Picture is stored on the X > server. Hmm... There was something a Picture was able to do that Images couldn't. I haven't worked with this code in a while thus I don't remember what it was. I'll try Image and see what breaks. Then I'll know what functionality was missing when I used Image instead of Picture. Right now it's academic because I still don't have the contents being sent to the DrawingArea being displayed, regardless of how I set the cached property. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From James.Hatridge at ...17... Wed Oct 11 17:47:38 2006 From: James.Hatridge at ...17... (James Hatridge) Date: Wed, 11 Oct 2006 17:47:38 +0200 Subject: [Gambas-user] file question Message-ID: <200610111747.38389.James.Hatridge@...17...> Hi all Is there anyway I can set up a buffer or file so that when its full the oldest part is dropped and newst is kept? The idea I have is a music buffer that holds X minutes of audio when the buffer is full it will push out the old and add the new. Is this do-able? Thanks, JIM -- Jim Hatridge Linux User #88484 ------------------------------------------------------ WartHog Bulletin Info about new German Stamps http://www.fuzzybunnymilitia.org/~hatridge/bulletin/index.php Viel Feind -- Viel Ehr' Anti-US Propaganda stamp collection http://www.fuzzybunnymilitia.org/~hatridge/collection/index.php From brian at ...1334... Wed Oct 11 18:31:12 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Wed, 11 Oct 2006 09:31:12 -0700 (PDT) Subject: [Gambas-user] file question In-Reply-To: <200610111747.38389.James.Hatridge@...17...> References: <200610111747.38389.James.Hatridge@...17...> Message-ID: <20061011090621.E1138@...1337...> On Wed, 11 Oct 2006, James Hatridge wrote: > Hi all > > Is there anyway I can set up a buffer or file so that when its full the oldest > part is dropped and newst is kept? > > The idea I have is a music buffer that holds X minutes of audio when the > buffer is full it will push out the old and add the new. Is this do-able? > > Thanks, > > JIM The solution to your problem is a ring buffer. To use a ring buffer split your main buffer into sequential chunks, maintaining a head and tail position in the buffer. If the head and tail indices are zero-based (0 indicates the first chunk) then you can use x MOD NumberOfChunks to get the wraparound effect needed for the index arithmetic. The explanation below uses MOD and hence assumes zero-based indices. When the buffer is initialized head=0, tail=0, status="empty" 1. To add to the buffer first make sure the status is not "full" (throw a football if it is) then increase the head with head=(head+1) MOD BufferChunkCount if this makes head=tail then set status to "full" and throw a football. If head!=tail then you can go ahead and fill the chunk now indexed by head. 2. To pull from the buffer first check that the buffer state is not "empty" and throw a football if it is. Transfer the chunk to whatever needs it then increase the tail by one with tail=(tail+1) MOD BufferChunkCount. Appropriately setting the status to "empty" if the condition tail=head is true after increasing the tail. 3. If the accesses to the buffer may be threaded then the head and tail check-and-change need to be done within semaphores or with a locking mechanism to make them atomic/serialized (only one thing accesses the head/tail indices at a time). Head needs to bumped before writing the data and tail must only be bumped after the chunk is transferred to whatever is using the data. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Wed Oct 11 18:40:45 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Wed, 11 Oct 2006 09:40:45 -0700 (PDT) Subject: [Gambas-user] file question In-Reply-To: <20061011090621.E1138@...1337...> References: <200610111747.38389.James.Hatridge@...17...> <20061011090621.E1138@...1337...> Message-ID: <20061011093244.E1138@...1337...> On Wed, 11 Oct 2006, Christopher Brian Jack wrote: > The solution to your problem is a ring buffer. > > To use a ring buffer split your main buffer into sequential chunks, > maintaining a head and tail position in the buffer. If the head and tail > indices are zero-based (0 indicates the first chunk) then you can use x > MOD NumberOfChunks to get the wraparound effect needed for the index > arithmetic. The explanation below uses MOD and hence assumes zero-based > indices. If you want to implement the ring buffer as a file abstraction then pick an appropriate blocksize and use head*blocksize or tail*blocksize (as appropriate to the operation) as arguments to seeking in the file. You'll need to add a special lastblock value which remembers the size of the very last block of the file (which typically isn't going to be a nice multiple of the chosen blocksize). When accessing on the highest index the client using the buffer needs to be informed about the size of the chunk being read (last part of the file) is less than the buffer's blocksize. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Wed Oct 11 17:46:12 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Wed, 11 Oct 2006 08:46:12 -0700 (PDT) Subject: [Gambas-user] DrawingArea problems In-Reply-To: <452C8C1B.90904@...221...> References: <20061010100510.K98410@...1337...> <200610101941.52433.gambas@...1...> <20061010104421.E98977@...1337...> <452C8C1B.90904@...221...> Message-ID: <20061011084512.J1138@...1337...> On Wed, 11 Oct 2006, Eilert wrote: > >>> I also haven't been able to properly get the other form elements > >>> to show in front (of other windows/forms) but behind the DrawingArea > >>> control of the form. > >> ???? I don't understand what you are talking about. > > > > I have to alt-tab to get the rest of the form to be visible other than > > just the DrawingArea control. > > > > Would it be possible to just use the visible property to let the > elements appear/disappear programmatically? I use object.Show() and object.Hide() is that the same thing? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From bartonekdragracing at ...43... Thu Oct 12 17:15:01 2006 From: bartonekdragracing at ...43... (Alex Bartonek) Date: Thu, 12 Oct 2006 08:15:01 -0700 (PDT) Subject: [Gambas-user] cant connect to mysql Message-ID: <20061012151501.70009.qmail@...1595...> I'm running gambas 1.9.33 on SuSE 10.1. The 'database' example that comes w/gambas I'm running it trying to connect to a local mysql db but I get the error "Cannot find driver for database: mysql". this is a fresh install of SuSE 10.1. I removed the version of gambas that it came with and upgraded to 1.9.33. I installed the following mysql rpm: gambas2-gb-db-mysql-1.9.33-1.gbv.suse100.i586.rpm Thanks in advance. __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com From James.Hatridge at ...17... Thu Oct 12 16:00:35 2006 From: James.Hatridge at ...17... (James Hatridge) Date: Thu, 12 Oct 2006 16:00:35 +0200 Subject: [Gambas-user] file question In-Reply-To: <20061011090621.E1138@...1337...> References: <200610111747.38389.James.Hatridge@...17...> <20061011090621.E1138@...1337...> Message-ID: <200610121600.35219.James.Hatridge@...17...> Hi Christopher et al... Ok, count me a bit slow, I think I understand. But can you show me a bit of code? (code I understand better) :) Thanks, JIM On Wednesday 11 October 2006 18:31, Christopher Brian Jack wrote: > On Wed, 11 Oct 2006, James Hatridge wrote: > > Hi all > > > > Is there anyway I can set up a buffer or file so that when its full the > > oldest part is dropped and newst is kept? > > > > The idea I have is a music buffer that holds X minutes of audio when the > > buffer is full it will push out the old and add the new. Is this do-able? > > > > Thanks, > > > > JIM > > The solution to your problem is a ring buffer. > > To use a ring buffer split your main buffer into sequential chunks, > maintaining a head and tail position in the buffer. If the head and tail > indices are zero-based (0 indicates the first chunk) then you can use x > MOD NumberOfChunks to get the wraparound effect needed for the index > arithmetic. The explanation below uses MOD and hence assumes zero-based > indices. > > When the buffer is initialized head=0, tail=0, status="empty" > > 1. To add to the buffer first make sure the status is not "full" (throw a > football if it is) then increase the head with head=(head+1) MOD > BufferChunkCount if this makes head=tail then set status to "full" and > throw a football. If head!=tail then you can go ahead and fill the chunk > now indexed by head. > > 2. To pull from the buffer first check that the buffer state is not > "empty" and throw a football if it is. Transfer the chunk to whatever > needs it then increase the tail by one with tail=(tail+1) MOD > BufferChunkCount. Appropriately setting the status to "empty" if the > condition tail=head is true after increasing the tail. > > 3. If the accesses to the buffer may be threaded then the head and tail > check-and-change need to be done within semaphores or with a locking > mechanism to make them atomic/serialized (only one thing accesses the > head/tail indices at a time). Head needs to bumped before writing the > data and tail must only be bumped after the chunk is transferred to > whatever is using the data. > > .=================================================. > > | Christopher BRIAN Jack aka "Gau of the Veldt" | > > +=================================================' > > | oevna at ...1544... > > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier Download IBM WebSphere Application Server v.1.0.1 based on Apache > Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user -- Jim Hatridge Linux User #88484 ------------------------------------------------------ WartHog Bulletin Info about new German Stamps http://www.fuzzybunnymilitia.org/~hatridge/bulletin/index.php Viel Feind -- Viel Ehr' Anti-US Propaganda stamp collection http://www.fuzzybunnymilitia.org/~hatridge/collection/index.php From James.Hatridge at ...17... Thu Oct 12 17:39:01 2006 From: James.Hatridge at ...17... (James Hatridge) Date: Thu, 12 Oct 2006 17:39:01 +0200 Subject: [Gambas-user] Tab Strip question Message-ID: <200610121739.02049.James.Hatridge@...17...> Hi all I have a tab strip in the order of 1 2 3 4 5 BUT now I find that I need it in 1 2 5 3 4 order. How can I change the order? Thanks, JIM -- Jim Hatridge Linux User #88484 ------------------------------------------------------ WartHog Bulletin Info about new German Stamps http://www.fuzzybunnymilitia.org/~hatridge/bulletin/index.php Viel Feind -- Viel Ehr' Anti-US Propaganda stamp collection http://www.fuzzybunnymilitia.org/~hatridge/collection/index.php From htakada at ...626... Thu Oct 12 19:55:32 2006 From: htakada at ...626... (Hugo) Date: Thu, 12 Oct 2006 14:55:32 -0300 Subject: [Gambas-user] cannot open project after instalation of gambas2(1.9.44) In-Reply-To: <200610071031.00697.gambas@...1...> References: <200610071031.00697.gambas@...1...> Message-ID: thanks a lot !!, now it works !! Hugo On 10/7/06, Benoit Minisini wrote: > > On Saturday 07 October 2006 00:21, Hugo wrote: > > Hi everybody, > > After compilation of gambas2 1.9.44 on FedoraCore4 I get this error when > I > > try to open my project: > > Cannot open project file: > > /path/goes/here/.. > > Null Object > > Project.GetFileIcon.479 > > > > is this a bug ? or am I doing something wrong? > > > > thanks for any advise > > > > Hugo > > Project.GetFileIcon() associates an icon to a project file. > > It seems that it fails sometimes. > > Try this patch and tells me if it fails again or not. > > Regards, > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > From brian at ...1334... Fri Oct 13 02:50:40 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 12 Oct 2006 17:50:40 -0700 (PDT) Subject: [Gambas-user] file question In-Reply-To: <200610121600.35219.James.Hatridge@...17...> References: <200610111747.38389.James.Hatridge@...17...> <20061011090621.E1138@...1337...> <200610121600.35219.James.Hatridge@...17...> Message-ID: <20061012171226.V11808@...1337...> On Thu, 12 Oct 2006, James Hatridge wrote: > Hi Christopher et al... > > Ok, count me a bit slow, I think I understand. But can you show me a bit of > code? (code I understand better) :) Okay snippets are inserted look through... This is NOT a thread-safe implementation! Also I may have botched the error reporting syntax royally. I haven't used the exception handling in Gambas as of yet. > Thanks, > > JIM > On Wednesday 11 October 2006 18:31, Christopher Brian Jack wrote: > > On Wed, 11 Oct 2006, James Hatridge wrote: > > > Hi all > > > > > > Is there anyway I can set up a buffer or file so that when its full the > > > oldest part is dropped and newst is kept? > > > > > > The idea I have is a music buffer that holds X minutes of audio when the > > > buffer is full it will push out the old and add the new. Is this do-able? > > > > > > Thanks, > > > > > > JIM > > > > The solution to your problem is a ring buffer. > > To use a ring buffer split your main buffer into sequential chunks, Private chunkSize As Integer Private chunkList As Variant > > maintaining a head and tail position in the buffer. If the head and tail > > indices are zero-based (0 indicates the first chunk) then you can use x > > MOD NumberOfChunks to get the wraparound effect needed for the index > > arithmetic. The explanation below uses MOD and hence assumes zero-based > > indices. Private head As Integer Private tail As Integer Private status As String > > When the buffer is initialized head=0, tail=0, status="empty" 'put into class "init" or "constructor" sub head=0 tail=0 status="empty" 'NOTE: The init sub/ctor must also require a block size parameter and a 'block count parameter: Dim chunks(chunkCount) As Variant chunkList=chunks ' 'It may be useful to be able to query the full/empty state of the ' Public Property isFull() As Boolean Public Property isEmpty() As Boolean Public Sub isFull() If Not (head=tail) Then Return FALSE If status="full" Then Return TRUE Return FALSE End Public Sub isEmpty() If Not (head=tail) Then Return FALSE If status="empty" Then Return TRUE Return FALSE End > > 1. To add to the buffer first make sure the status is not "full" (throw a > > football if it is) then increase the head with head=(head+1) MOD > > BufferChunkCount if this makes head=tail then set status to "full" and > > throw a football. If head!=tail then you can go ahead and fill the chunk > > now indexed by head. Public Sub Push(sourceData As String) If (status="full") Then Throw("Buffer Full") head=(head+1) MOD chunkCount If (head=tail) Then status="full" Throw("Buffer Full") End chunkList(head)=Mid(sourceData,1,Min(chunkSize,Len(sourceData))) End > > 2. To pull from the buffer first check that the buffer state is not > > "empty" and throw a football if it is. Transfer the chunk to whatever > > needs it then increase the tail by one with tail=(tail+1) MOD > > BufferChunkCount. Appropriately setting the status to "empty" if the > > condition tail=head is true after increasing the tail. Public Sub Pull() As String Dim data As String If (status="empty") Then Throw("Buffer Empty") data=chunkList(tail) chunkList(tail)=NULL tail=(tail+1) Mod chunkCount If (head=tail) Then status="empty" Return data; End > > 3. If the accesses to the buffer may be threaded then the head and tail > > check-and-change need to be done within semaphores or with a locking > > mechanism to make them atomic/serialized (only one thing accesses the > > head/tail indices at a time). Head needs to bumped before writing the > > data and tail must only be bumped after the chunk is transferred to > > whatever is using the data. This is not a thread-safe example. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From James.Hatridge at ...17... Fri Oct 13 20:20:58 2006 From: James.Hatridge at ...17... (James Hatridge) Date: Fri, 13 Oct 2006 20:20:58 +0200 Subject: [Gambas-user] file question In-Reply-To: <20061012171226.V11808@...1337...> References: <200610111747.38389.James.Hatridge@...17...> <200610121600.35219.James.Hatridge@...17...> <20061012171226.V11808@...1337...> Message-ID: <200610132020.58412.James.Hatridge@...17...> HI Christopher et al.. Thanks for the code! But there is no way in "heck" that I'm going to work coding on Friday 13th! Thanks JIM On Friday 13 October 2006 02:50, Christopher Brian Jack wrote: > On Thu, 12 Oct 2006, James Hatridge wrote: > > Hi Christopher et al... > > > > Ok, count me a bit slow, I think I understand. But can you show me a bit > > of code? (code I understand better) :) > > Okay snippets are inserted look through... > This is NOT a thread-safe implementation! > > Also I may have botched the error reporting syntax royally. I haven't > used the exception handling in Gambas as of yet. > > > Thanks, > > > > JIM > > > > On Wednesday 11 October 2006 18:31, Christopher Brian Jack wrote: > > > On Wed, 11 Oct 2006, James Hatridge wrote: > > > > Hi all > > > > > > > > Is there anyway I can set up a buffer or file so that when its full > > > > the oldest part is dropped and newst is kept? > > > > > > > > The idea I have is a music buffer that holds X minutes of audio when > > > > the buffer is full it will push out the old and add the new. Is this > > > > do-able? > > > > > > > > Thanks, > > > > > > > > JIM > > > > > > The solution to your problem is a ring buffer. > > > > > > To use a ring buffer split your main buffer into sequential chunks, > > Private chunkSize As Integer > Private chunkList As Variant > > > > maintaining a head and tail position in the buffer. If the head and > > > tail indices are zero-based (0 indicates the first chunk) then you can > > > use x MOD NumberOfChunks to get the wraparound effect needed for the > > > index arithmetic. The explanation below uses MOD and hence assumes > > > zero-based indices. > > Private head As Integer > Private tail As Integer > Private status As String > > > > When the buffer is initialized head=0, tail=0, status="empty" > > 'put into class "init" or "constructor" sub > head=0 > tail=0 > status="empty" > > 'NOTE: The init sub/ctor must also require a block size parameter and a > 'block count parameter: > > Dim chunks(chunkCount) As Variant > chunkList=chunks > > ' > 'It may be useful to be able to query the full/empty state of the > ' > Public Property isFull() As Boolean > Public Property isEmpty() As Boolean > > Public Sub isFull() > If Not (head=tail) Then Return FALSE > If status="full" Then Return TRUE > Return FALSE > End > > Public Sub isEmpty() > If Not (head=tail) Then Return FALSE > If status="empty" Then Return TRUE > Return FALSE > End > > > > 1. To add to the buffer first make sure the status is not "full" > > > (throw a football if it is) then increase the head with head=(head+1) > > > MOD BufferChunkCount if this makes head=tail then set status to "full" > > > and throw a football. If head!=tail then you can go ahead and fill the > > > chunk now indexed by head. > > Public Sub Push(sourceData As String) > If (status="full") Then Throw("Buffer Full") > head=(head+1) MOD chunkCount > If (head=tail) Then > status="full" > Throw("Buffer Full") > End > chunkList(head)=Mid(sourceData,1,Min(chunkSize,Len(sourceData))) > End > > > > 2. To pull from the buffer first check that the buffer state is not > > > "empty" and throw a football if it is. Transfer the chunk to whatever > > > needs it then increase the tail by one with tail=(tail+1) MOD > > > BufferChunkCount. Appropriately setting the status to "empty" if the > > > condition tail=head is true after increasing the tail. > > Public Sub Pull() As String > Dim data As String > If (status="empty") Then Throw("Buffer Empty") > data=chunkList(tail) > chunkList(tail)=NULL > tail=(tail+1) Mod chunkCount > If (head=tail) Then status="empty" > Return data; > End > > > > 3. If the accesses to the buffer may be threaded then the head and tail > > > check-and-change need to be done within semaphores or with a locking > > > mechanism to make them atomic/serialized (only one thing accesses the > > > head/tail indices at a time). Head needs to bumped before writing the > > > data and tail must only be bumped after the chunk is transferred to > > > whatever is using the data. > > This is not a thread-safe example. > > .=================================================. > > | Christopher BRIAN Jack aka "Gau of the Veldt" | > > +=================================================' > > | oevna at ...1544... > > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier Download IBM WebSphere Application Server v.1.0.1 based on Apache > Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user -- Jim Hatridge Linux User #88484 ------------------------------------------------------ WartHog Bulletin Info about new German Stamps http://www.fuzzybunnymilitia.org/~hatridge/bulletin/index.php Viel Feind -- Viel Ehr' Anti-US Propaganda stamp collection http://www.fuzzybunnymilitia.org/~hatridge/collection/index.php From gambas at ...1... Fri Oct 13 21:11:37 2006 From: gambas at ...1... (Benoit Minisini) Date: Fri, 13 Oct 2006 21:11:37 +0200 Subject: [Gambas-user] file question In-Reply-To: <200610132020.58412.James.Hatridge@...17...> References: <200610111747.38389.James.Hatridge@...17...> <20061012171226.V11808@...1337...> <200610132020.58412.James.Hatridge@...17...> Message-ID: <200610132111.37347.gambas@...1...> On Friday 13 October 2006 20:20, James Hatridge wrote: > HI Christopher et al.. > > Thanks for the code! But there is no way in "heck" that I'm going to work > coding on Friday 13th! > > Thanks > > JIM > Aargh! I didn't notice! -- Benoit Minisini From Karl.Reinl at ...9... Fri Oct 13 23:57:01 2006 From: Karl.Reinl at ...9... (Charlie Reinl) Date: Fri, 13 Oct 2006 23:57:01 +0200 Subject: [Gambas-user] file question In-Reply-To: <200610132111.37347.gambas@...1...> References: <200610111747.38389.James.Hatridge@...17...> <20061012171226.V11808@...1337...> <200610132020.58412.James.Hatridge@...17...> <200610132111.37347.gambas@...1...> Message-ID: <1160776622.5306.31.camel@...40...> Am Freitag, den 13.10.2006, 21:11 +0200 schrieb Benoit Minisini: > On Friday 13 October 2006 20:20, James Hatridge wrote: > > HI Christopher et al.. > > > > Thanks for the code! But there is no way in "heck" that I'm going to work > > coding on Friday 13th! > > > > Thanks > > > > JIM > > > > Aargh! I didn't notice! > Salut, 13 ? ... is that a number or an Error-Code ? Amicalment Charlie From brian at ...1334... Sat Oct 14 20:47:43 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 14 Oct 2006 11:47:43 -0700 (PDT) Subject: [Gambas-user] file question Message-ID: <20061014114655.D22521@...1337...> ...reposted for those who are superstitious... On Thu, 12 Oct 2006, James Hatridge wrote: > Hi Christopher et al... > > Ok, count me a bit slow, I think I understand. But can you show me a bit of > code? (code I understand better) :) Okay snippets are inserted look through... This is NOT a thread-safe implementation! Also I may have botched the error reporting syntax royally. I haven't used the exception handling in Gambas as of yet. > Thanks, > > JIM > On Wednesday 11 October 2006 18:31, Christopher Brian Jack wrote: > > On Wed, 11 Oct 2006, James Hatridge wrote: > > > Hi all > > > > > > Is there anyway I can set up a buffer or file so that when its full the > > > oldest part is dropped and newst is kept? > > > > > > The idea I have is a music buffer that holds X minutes of audio when the > > > buffer is full it will push out the old and add the new. Is this do-able? > > > > > > Thanks, > > > > > > JIM > > > > The solution to your problem is a ring buffer. > > To use a ring buffer split your main buffer into sequential chunks, Private chunkSize As Integer Private chunkList As Variant > > maintaining a head and tail position in the buffer. If the head and tail > > indices are zero-based (0 indicates the first chunk) then you can use x > > MOD NumberOfChunks to get the wraparound effect needed for the index > > arithmetic. The explanation below uses MOD and hence assumes zero-based > > indices. Private head As Integer Private tail As Integer Private status As String > > When the buffer is initialized head=0, tail=0, status="empty" 'put into class "init" or "constructor" sub head=0 tail=0 status="empty" 'NOTE: The init sub/ctor must also require a block size parameter and a 'block count parameter: Dim chunks(chunkCount) As Variant chunkList=chunks ' 'It may be useful to be able to query the full/empty state of the ' Public Property isFull() As Boolean Public Property isEmpty() As Boolean Public Sub isFull() If Not (head=tail) Then Return FALSE If status="full" Then Return TRUE Return FALSE End Public Sub isEmpty() If Not (head=tail) Then Return FALSE If status="empty" Then Return TRUE Return FALSE End > > 1. To add to the buffer first make sure the status is not "full" (throw a > > football if it is) then increase the head with head=(head+1) MOD > > BufferChunkCount if this makes head=tail then set status to "full" and > > throw a football. If head!=tail then you can go ahead and fill the chunk > > now indexed by head. Public Sub Push(sourceData As String) If (status="full") Then Throw("Buffer Full") head=(head+1) MOD chunkCount If (head=tail) Then status="full" Throw("Buffer Full") End chunkList(head)=Mid(sourceData,1,Min(chunkSize,Len(sourceData))) End > > 2. To pull from the buffer first check that the buffer state is not > > "empty" and throw a football if it is. Transfer the chunk to whatever > > needs it then increase the tail by one with tail=(tail+1) MOD > > BufferChunkCount. Appropriately setting the status to "empty" if the > > condition tail=head is true after increasing the tail. Public Sub Pull() As String Dim data As String If (status="empty") Then Throw("Buffer Empty") data=chunkList(tail) chunkList(tail)=NULL tail=(tail+1) Mod chunkCount If (head=tail) Then status="empty" Return data; End > > 3. If the accesses to the buffer may be threaded then the head and tail > > check-and-change need to be done within semaphores or with a locking > > mechanism to make them atomic/serialized (only one thing accesses the > > head/tail indices at a time). Head needs to bumped before writing the > > data and tail must only be bumped after the chunk is transferred to > > whatever is using the data. This is not a thread-safe example. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Sun Oct 15 21:14:17 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sun, 15 Oct 2006 12:14:17 -0700 (PDT) Subject: [Gambas-user] Mascot Code Message-ID: <20061015115455.W28489@...1337...> What would be involved in making the mascot code into a component so that updating the crustacean's repetoire wouldn't require recompiling the entire IDE? Then have the IDE able to select one (or more) "mascot components" similar to how a project can select its operating components (like gb.form, gb.db, gb.net, etc.). So his existing behaviors could be placed into something like gb.mascot.animations and gb.mascot.reporterrors or somesuch. I'm thinking this would require the mascot being reimplemented in a manner similar to a form so that the plugins can be coded as event observers. Of course there's the issue of propogating events past each plug-ins, in sequence, until one acts on the event. A standard infrastructure for adding items to a mascot-global context menu would be required for plugins for such plug-ins as well. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Sun Oct 15 21:47:25 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 15 Oct 2006 21:47:25 +0200 Subject: [Gambas-user] Mascot Code In-Reply-To: <20061015115455.W28489@...1337...> References: <20061015115455.W28489@...1337...> Message-ID: <200610152147.26082.gambas@...1...> On Sunday 15 October 2006 21:14, Christopher Brian Jack wrote: > What would be involved in making the mascot code into a component so that > updating the crustacean's repetoire wouldn't require recompiling the > entire IDE? What's the matter with recompiling the entire IDE? > > Then have the IDE able to select one (or more) "mascot components" similar > to how a project can select its operating components (like gb.form, gb.db, > gb.net, etc.). > > So his existing behaviors could be placed into something like > gb.mascot.animations and gb.mascot.reporterrors or somesuch. Components are used for sharing important code with different project. Why would you want to share the mascot? Or maybe you want to have a generic component for making mascots? > > I'm thinking this would require the mascot being reimplemented in a manner > similar to a form so that the plugins can be coded as event observers. > Of course there's the issue of propogating events past each plug-ins, in > sequence, until one acts on the event. > > A standard infrastructure for adding items to a mascot-global context menu > would be required for plugins for such plug-ins as well. > I don't understand. Can you explain exactly what you need? Or show some code? :-) Regards, -- Benoit Minisini From gambas at ...1... Sun Oct 15 21:52:17 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 15 Oct 2006 21:52:17 +0200 Subject: [Gambas-user] Web application development Message-ID: <200610152152.17594.gambas@...1...> I'm currently developping a component for making web applications with CGI. I need it for a project for my job. This component has almost the same interface as ASP, except that you don't have the equivalent of ASP pages (i.e. you must print your HTML code on the standard output). But you have: - The Request class for reading the request, sent by both GET and POST method. - The Response class for sending the answer. It manages headers and cookies. - The Session class for an automatic session management. The only restriction is that session variables can only be basic types, Array or Collection. - An HTML function for encoding text in HTML. The code is in the svn at the moment. If you have comments, ideas, needs on how should work such a component, tell now! Regards, -- Benoit Minisini From brian at ...1334... Sun Oct 15 23:47:50 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sun, 15 Oct 2006 14:47:50 -0700 (PDT) Subject: [Gambas-user] Mascot Code In-Reply-To: <200610152147.26082.gambas@...1...> References: <20061015115455.W28489@...1337...> <200610152147.26082.gambas@...1...> Message-ID: <20061015143357.B29132@...1337...> On Sun, 15 Oct 2006, Benoit Minisini wrote: > What's the matter with recompiling the entire IDE? It's akin to requiring recompiling of an entire kernel to upgrade or create a single module. > > Then have the IDE able to select one (or more) "mascot components" similar > > to how a project can select its operating components (like gb.form, gb.db, > > gb.net, etc.). > > So his existing behaviors could be placed into something like > > gb.mascot.animations and gb.mascot.reporterrors or somesuch. > > Components are used for sharing important code with different project. Why > would you want to share the mascot? > > Or maybe you want to have a generic component for making mascots? No more like a generic way to add functionality to the existing mascot. > > I'm thinking this would require the mascot being reimplemented in a manner > > similar to a form so that the plugins can be coded as event observers. > > Of course there's the issue of propogating events past each plug-in, in > > sequence, until one acts on the event. > > > > A standard infrastructure for adding items to a mascot-global context menu > > would be required for plugins for such plug-ins as well. > > I don't understand. Can you explain exactly what you need? Or show some > code? :-) Say I want to add some context (right-click) functionality to the mascot. Currently I'd have to intrude deep into the IDE code and recompile to make it work. Furthermore distributing such a change boils down to having to redistribute the code to the entire IDE (with modifications). Moving the mascot code into components would make making mascot enhancement plugins more easily distributable (don't require packing up the entire IDE to package the plug-in). Most plugins will probably want to make use of a context (popup) menu so the basic implementation for that should sit in the monolithic IDE code and exports an interface for plugins to define any context menu items the plugin requires. The plugin would have an event handler called when one of its context menu items was selected. The IDE would keep an internal table for which plugins use which context menu items so the appropriate items may be removed if a plugin is subsequently made inactive. Making the animation a plugin would allow other plugins to call the animation routines (namely to trigger the "yay-let's-go" or "oh, crap" animations). .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From sourceforge-raindog2 at ...94... Mon Oct 16 00:40:16 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sun, 15 Oct 2006 18:40:16 -0400 Subject: [Gambas-user] Web application development In-Reply-To: <200610152152.17594.gambas@...1...> References: <200610152152.17594.gambas@...1...> Message-ID: <200610151840.16287.sourceforge-raindog2@...94...> On Sunday 15 October 2006 15:52, Benoit Minisini wrote: > If you have comments, ideas, needs on how should work such a > component, tell now! As soon as I'm done with the project I've been working on all year, I intend to write a "gb.ajax" component that will let you take forms designed in the IDE and deploy them as web apps, generating the necessary XHTML and Javascript and faking the event loop through XMLHttpRequest and some kind of state preservation on the server side. I'm sure there will be complications as I develop it, but after spending the last year and a half developing a gigantic Ajax app using nothing but perl's CGI module, Gambas forms parsed out into HTML, and handwritten Javascript, I think I'm ready ;) I know the aim of my component will be very different than yours (I don't intend to let the developer output HTML or Javascript code manually at all), but I'm curious as to whether you think it would make more sense as its own top level component or if it should hang off of gb.asp, or whatever you'll be calling your new component. It seems to me that they're bound to have SOME functionality in common, though it's unclear how much. Rob From nando_f at ...1382... Mon Oct 16 10:20:29 2006 From: nando_f at ...1382... (nando) Date: Mon, 16 Oct 2006 04:20:29 -0400 Subject: [Gambas-user] Web application development In-Reply-To: <200610152152.17594.gambas@...1...> References: <200610152152.17594.gambas@...1...> Message-ID: <20061016081018.M83990@...1382...> Very interesting. I just completed a large app with PHP - logging in, sessions, mysql, fpdf, gdlib. I prefer Gambas. Having the ability to have GET POST vars readily available would be cool. Having sessions managed by a component would be cool too. An example for gdlib replacement would be nice. Rob's idea of HTTPrequest for ajax is nice too. All very, very cool things for Gambas. -Fernando ---------- Original Message ----------- From: Benoit Minisini To: gambas-user at lists.sourceforge.net Sent: Sun, 15 Oct 2006 21:52:17 +0200 Subject: [Gambas-user] Web application development > I'm currently developping a component for making web applications with CGI. I > need it for a project for my job. > > This component has almost the same interface as ASP, except that you don't > have the equivalent of ASP pages (i.e. you must print your HTML code on the > standard output). > > But you have: > - The Request class for reading the request, sent by both GET and POST method. > - The Response class for sending the answer. It manages headers and cookies. > - The Session class for an automatic session management. The only restriction > is that session variables can only be basic types, Array or Collection. > - An HTML function for encoding text in HTML. > > The code is in the svn at the moment. > > If you have comments, ideas, needs on how should work such a component, tell > now! > > Regards, > > -- > Benoit Minisini > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From marco.colnaghi at ...69... Mon Oct 16 10:48:26 2006 From: marco.colnaghi at ...69... (Marco Colnaghi) Date: Mon, 16 Oct 2006 10:48:26 +0200 Subject: [Gambas-user] RGB components from color In-Reply-To: References: Message-ID: <200610161048.27103.marco.colnaghi@...69...> I'm using gambas 1.0.15 (Debian Etch). I asked info about getting RGB components from a color (integer) I had and hint, but I still have problems: > > Is there a function giving back the red (or green or blue) component of a > > color? (equivalent to qRed in QT) > > Color[Value].Red > Color[Value].Green > Color[Value].Blue > this does not work in my gambas (Error: Color is not an array) Can please someone help me? A simple line of code would be very helpful. Thanks in advance, Marco. From lordheavy at ...512... Mon Oct 16 10:50:41 2006 From: lordheavy at ...512... (Laurent Carlier) Date: Mon, 16 Oct 2006 10:50:41 +0200 Subject: [Gambas-user] RGB components from color In-Reply-To: <200610161048.27103.marco.colnaghi@...69...> References: <200610161048.27103.marco.colnaghi@...69...> Message-ID: <200610161050.41787.lordheavy@...512...> Le lundi 16 octobre 2006 10:48, Marco Colnaghi a ?crit?: > I'm using gambas 1.0.15 (Debian Etch). > > I asked info about getting RGB components from a color (integer) > > I had and hint, but I still have problems: > > > Is there a function giving back the red (or green or blue) component of > > > a color? (equivalent to qRed in QT) > > > > Color[Value].Red > > Color[Value].Green > > Color[Value].Blue > > this does not work in my gambas (Error: Color is not an array) > > Can please someone help me? > A simple line of code would be very helpful. > > Thanks in advance, > Marco. > PRINT color[&hFFFFFFFF].Red -> 255 Regards, From dcamposf at ...626... Mon Oct 16 11:19:43 2006 From: dcamposf at ...626... (Daniel Campos) Date: Mon, 16 Oct 2006 11:19:43 +0200 Subject: [Gambas-user] RGB components from color In-Reply-To: <200610161050.41787.lordheavy@...512...> References: <200610161048.27103.marco.colnaghi@...69...> <200610161050.41787.lordheavy@...512...> Message-ID: <7259b5ae0610160219v5aa5978dqda31f323d1d778a6@...627...> The Color array syntax is useful only for Gambas 2. If you're using Gambas 1 you can do it manually, but the depends on the kind of color encoding you're using (RGB, BGR, RGBA...). If you're using just RGB and 8 bits per color, you can do: R=Lsr(hColor, 16) and &HFF G=Lsr(hColor, 8) AND &HFF B=hColor AND &HFF Daniel 2006/10/16, Laurent Carlier : > Le lundi 16 octobre 2006 10:48, Marco Colnaghi a ?crit: > > I'm using gambas 1.0.15 (Debian Etch). > > > > I asked info about getting RGB components from a color (integer) > > > > I had and hint, but I still have problems: > > > > Is there a function giving back the red (or green or blue) component of > > > > a color? (equivalent to qRed in QT) > > > > > > Color[Value].Red > > > Color[Value].Green > > > Color[Value].Blue > > > > this does not work in my gambas (Error: Color is not an array) > > > > Can please someone help me? > > A simple line of code would be very helpful. > > > > Thanks in advance, > > Marco. > > > > PRINT color[&hFFFFFFFF].Red > > -> 255 > > Regards, > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Mon Oct 16 21:27:16 2006 From: gambas at ...1... (Benoit Minisini) Date: Mon, 16 Oct 2006 21:27:16 +0200 Subject: [Gambas-user] Web application development In-Reply-To: <200610151840.16287.sourceforge-raindog2@...94...> References: <200610152152.17594.gambas@...1...> <200610151840.16287.sourceforge-raindog2@...94...> Message-ID: <200610162127.16683.gambas@...1...> On Monday 16 October 2006 00:40, Rob wrote: > On Sunday 15 October 2006 15:52, Benoit Minisini wrote: > > If you have comments, ideas, needs on how should work such a > > component, tell now! > > As soon as I'm done with the project I've been working on all > year, I intend to write a "gb.ajax" component that will let you > take forms designed in the IDE and deploy them as web apps, > generating the necessary XHTML and Javascript and faking the > event loop through XMLHttpRequest and some kind of state > preservation on the server side. I'm sure there will be > complications as I develop it, but after spending the last year > and a half developing a gigantic Ajax app using nothing but > perl's CGI module, Gambas forms parsed out into HTML, and > handwritten Javascript, I think I'm ready ;) > > I know the aim of my component will be very different than yours > (I don't intend to let the developer output HTML or Javascript > code manually at all), but I'm curious as to whether you think > it would make more sense as its own top level component or if it > should hang off of gb.asp, or whatever you'll be calling your > new component. It seems to me that they're bound to have SOME > functionality in common, though it's unclear how much. > > Rob > I'm not sure that it is a good idea to try to reuse directly GUI forms for making WEB forms. GUI controls are complicated, and usually do things differently from WEB controls. I suggest making WEB controls only based on what is possible with HTML and JavaScript, without trying to behave exactly like GUI controls. A WebForm would be a container for other WebContainers and WebControls. They will generate an HTML page that can be sent to the browser. WebControls could raise events to be catched in the server code, for example to get data like the TableView Data event, or events that comes from XmlHttp requests from the client (don't know at the moment). The current gb.web component simplify the writing of CGI script by providing classes for request management, response generation, session management... See the svn repository for that. I think you could based your gb.ajax component on gb.web, because having Ajax WebControls seems to be orthogonal to the management of HTTP requests and Session management. Of course CGI may not be the right technology for that. But we can imagine a FastCGI component, that has all the simplicity of CGI without the need to launch a process for each request - even if launching a process on Linux is far lighter than on other OS. :-) At the moment, session management is based on file saved by the CGI script into /tmp/gambas.$UID/session directory, and reloaded at each request. As Ajax applications seems to have to maintain a greater amount of data between request, maybe it is not the fastest technology. We could imagine a session server that store the data permanently, and give it on demand to the process that handle requests. Maybe a Ajax Gambas application could be an HTTP server on its own. It would be cool. I don't know if Apache (or other web servers) can automatically send an HTTP request to another port, where the Gambas server would listen. What do you think about all that? -- Benoit Minisini From dcamposf at ...626... Mon Oct 16 22:21:08 2006 From: dcamposf at ...626... (Daniel Campos) Date: Mon, 16 Oct 2006 22:21:08 +0200 Subject: [Gambas-user] Web application development In-Reply-To: <200610162127.16683.gambas@...1...> References: <200610152152.17594.gambas@...1...> <200610151840.16287.sourceforge-raindog2@...94...> <200610162127.16683.gambas@...1...> Message-ID: <7259b5ae0610161321n11c322bcm545b03b7f2bafbf7@...627...> Exactly Benoit: I think the future of web apps is not raising a process each time the server receives a request, but having a single process running while the connection is open, while the client is running the "application/web page", and there should be always a socket connected between the server and the client. In that sense people interested in "gb.ajax" (I hope somebody finds a better name), should check the Comet programming technology: http://en.wikipedia.org/wiki/Comet_%28programming%29 , that surely will provide big ideas for that component. A person here was able to run parts of the Squeak environment (Smalltalk) directly in a browser. Comet techniques also allows to draw directly on a client web canvas (Firefox and Safari/Webkit have one, and there's an emulation for IE), and even work sending graphical events from the client to the server and sending a server-client reply using Javascript injection. Daniel 2006/10/16, Benoit Minisini : > On Monday 16 October 2006 00:40, Rob wrote: > > On Sunday 15 October 2006 15:52, Benoit Minisini wrote: > > > If you have comments, ideas, needs on how should work such a > > > component, tell now! > > > > As soon as I'm done with the project I've been working on all > > year, I intend to write a "gb.ajax" component that will let you > > take forms designed in the IDE and deploy them as web apps, > > generating the necessary XHTML and Javascript and faking the > > event loop through XMLHttpRequest and some kind of state > > preservation on the server side. I'm sure there will be > > complications as I develop it, but after spending the last year > > and a half developing a gigantic Ajax app using nothing but > > perl's CGI module, Gambas forms parsed out into HTML, and > > handwritten Javascript, I think I'm ready ;) > > > > I know the aim of my component will be very different than yours > > (I don't intend to let the developer output HTML or Javascript > > code manually at all), but I'm curious as to whether you think > > it would make more sense as its own top level component or if it > > should hang off of gb.asp, or whatever you'll be calling your > > new component. It seems to me that they're bound to have SOME > > functionality in common, though it's unclear how much. > > > > Rob > > > > I'm not sure that it is a good idea to try to reuse directly GUI forms for > making WEB forms. GUI controls are complicated, and usually do things > differently from WEB controls. > > I suggest making WEB controls only based on what is possible with HTML and > JavaScript, without trying to behave exactly like GUI controls. > > A WebForm would be a container for other WebContainers and WebControls. They > will generate an HTML page that can be sent to the browser. WebControls could > raise events to be catched in the server code, for example to get data like > the TableView Data event, or events that comes from XmlHttp requests from the > client (don't know at the moment). > > The current gb.web component simplify the writing of CGI script by providing > classes for request management, response generation, session management... > See the svn repository for that. > > I think you could based your gb.ajax component on gb.web, because having Ajax > WebControls seems to be orthogonal to the management of HTTP requests and > Session management. > > Of course CGI may not be the right technology for that. But we can imagine a > FastCGI component, that has all the simplicity of CGI without the need to > launch a process for each request - even if launching a process on Linux is > far lighter than on other OS. :-) > > At the moment, session management is based on file saved by the CGI script > into /tmp/gambas.$UID/session directory, and reloaded at each request. > > As Ajax applications seems to have to maintain a greater amount of data > between request, maybe it is not the fastest technology. We could imagine a > session server that store the data permanently, and give it on demand to the > process that handle requests. > > Maybe a Ajax Gambas application could be an HTTP server on its own. It would > be cool. I don't know if Apache (or other web servers) can automatically send > an HTTP request to another port, where the Gambas server would listen. > > What do you think about all that? > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From sourceforge-raindog2 at ...94... Mon Oct 16 23:04:39 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Mon, 16 Oct 2006 17:04:39 -0400 Subject: [Gambas-user] Web application development In-Reply-To: <7259b5ae0610161321n11c322bcm545b03b7f2bafbf7@...627...> References: <200610152152.17594.gambas@...1...> <200610162127.16683.gambas@...1...> <7259b5ae0610161321n11c322bcm545b03b7f2bafbf7@...627...> Message-ID: <200610161704.40217.sourceforge-raindog2@...94...> On Monday 16 October 2006 16:21, Daniel Campos wrote: > In that sense people interested in "gb.ajax" (I hope somebody > finds a better name), should check the Comet programming > technology: > http://en.wikipedia.org/wiki/Comet_%28programming%29 , that > surely will provide big ideas for that component. I had actually expected to make use of the Comet technique, but I don't think it's safe to assume browsers will always behave nicely (i.e. not break the connection) and I certainly don't want to put any requirements on the server except for having Gambas installed as a CGI interpreter (i.e. no special middleware or proxy.) So state still needs to be maintained between requests, and cleaned out periodically. But at its simplest, Comet can be implemented as "open a connection, when the connection returns something, handle it, and when the connection closes, immediately reopen it." You have a message queue on the browser side that transmits requests over that one persistent connection and receives drawing and timer events from the server side. I would also want to have some kind of ping or heartbeat functionality, because if there's one thing I've learned in the last year and a half of being up to my elbows in Ajax, it's that TCP connections are not quite as reliable in the real world as they are in the spec. I agree that "gb.ajax" or "gb.web.ajax" would suck as a name, but you can't deny its buzzword compliance ;) If someone does suggest another name, I hope that it isn't just "gb.comet" or "gb.SomeOtherToolkit" or "gb.SomeNewMeaninglessName". I'd sooner call it "gb.form.web" (or "gb.web.form"), if that won't raise people's expectations too high. > A person here was able to run parts of the Squeak environment > (Smalltalk) directly in a browser. Comet techniques also > allows to draw directly on a client web canvas (Firefox and > Safari/Webkit have one, and there's an emulation for IE), and > even work sending graphical events from the client to the > server and sending a server-client reply using Javascript > injection. I certainly intend to support the Firefox canvas in some way, though I don't know whether my graphics-fu and/or the Firefox canvas itself is good enough to implement most of what Gambas' DrawingArea does. In answer to Benoit's earlier post, I see your point about having different controls for the web vs. gb.qt/gb.gtk, but the whole point of my "gb.ajax" concept is to allow novice web programmers to design their forms in the Gambas IDE and deploy them to the web just by moving the checkmark from "gb.qt" to "gb.ajax" in project properties. It will make for some pretty crappy forms being deployed, but then, look at the hideous things people have done with Scriptaculous. I don't think anyone would say they'd rather that it hadn't been written. It's a lofty goal, but why have goals that aren't? Rob From gambas at ...1... Mon Oct 16 23:24:46 2006 From: gambas at ...1... (Benoit Minisini) Date: Mon, 16 Oct 2006 23:24:46 +0200 Subject: [Gambas-user] Web application development In-Reply-To: <200610161704.40217.sourceforge-raindog2@...94...> References: <200610152152.17594.gambas@...1...> <7259b5ae0610161321n11c322bcm545b03b7f2bafbf7@...627...> <200610161704.40217.sourceforge-raindog2@...94...> Message-ID: <200610162324.46878.gambas@...1...> On Monday 16 October 2006 23:04, Rob wrote: > On Monday 16 October 2006 16:21, Daniel Campos wrote: > > In that sense people interested in "gb.ajax" (I hope somebody > > finds a better name), should check the Comet programming > > technology: > > http://en.wikipedia.org/wiki/Comet_%28programming%29 , that > > surely will provide big ideas for that component. > > I had actually expected to make use of the Comet technique, but I > don't think it's safe to assume browsers will always behave > nicely (i.e. not break the connection) and I certainly don't > want to put any requirements on the server except for having > Gambas installed as a CGI interpreter (i.e. no special > middleware or proxy.) So state still needs to be maintained > between requests, and cleaned out periodically. > > But at its simplest, Comet can be implemented as "open a > connection, when the connection returns something, handle it, > and when the connection closes, immediately reopen it." You > have a message queue on the browser side that transmits requests > over that one persistent connection and receives drawing and > timer events from the server side. I would also want to have > some kind of ping or heartbeat functionality, because if there's > one thing I've learned in the last year and a half of being up > to my elbows in Ajax, it's that TCP connections are not quite as > reliable in the real world as they are in the spec. > > I agree that "gb.ajax" or "gb.web.ajax" would suck as a name, but > you can't deny its buzzword compliance ;) If someone does > suggest another name, I hope that it isn't just "gb.comet" > or "gb.SomeOtherToolkit" or "gb.SomeNewMeaninglessName". I'd > sooner call it "gb.form.web" (or "gb.web.form"), if that won't > raise people's expectations too high. > > > A person here was able to run parts of the Squeak environment > > (Smalltalk) directly in a browser. Comet techniques also > > allows to draw directly on a client web canvas (Firefox and > > Safari/Webkit have one, and there's an emulation for IE), and > > even work sending graphical events from the client to the > > server and sending a server-client reply using Javascript > > injection. > > I certainly intend to support the Firefox canvas in some way, > though I don't know whether my graphics-fu and/or the Firefox > canvas itself is good enough to implement most of what Gambas' > DrawingArea does. > > In answer to Benoit's earlier post, I see your point about having > different controls for the web vs. gb.qt/gb.gtk, but the whole > point of my "gb.ajax" concept is to allow novice web programmers > to design their forms in the Gambas IDE and deploy them to the > web just by moving the checkmark from "gb.qt" to "gb.ajax" in > project properties. It will make for some pretty crappy forms > being deployed, but then, look at the hideous things people have > done with Scriptaculous. I don't think anyone would say they'd > rather that it hadn't been written. > > It's a lofty goal, but why have goals that aren't? > > Rob > Just tell us where you can go in emulating gb.qt and gb.gth controls in gb.web.form. I have started a documentation page for Daniel to explain the internal behaviour of gb.qt controls: http://gambasdoc.org/help/api/guicomp. (Have you read it Daniel?) I think you may find information there for your needs. Maybe we can imagine two components: gb.web.form and gb.web.form.ajax. The first component will simply includes Web controls that do not need Ajax (i.e. some HTML forms and Javascript only). Regards, -- Benoit Minisini From dcamposf at ...626... Tue Oct 17 00:18:01 2006 From: dcamposf at ...626... (Daniel Campos) Date: Tue, 17 Oct 2006 00:18:01 +0200 Subject: [Gambas-user] Web application development In-Reply-To: <200610162324.46878.gambas@...1...> References: <200610152152.17594.gambas@...1...> <7259b5ae0610161321n11c322bcm545b03b7f2bafbf7@...627...> <200610161704.40217.sourceforge-raindog2@...94...> <200610162324.46878.gambas@...1...> Message-ID: <7259b5ae0610161518h55b3c59fg5e77f4f6db963f8c@...627...> > > I have started a documentation page for Daniel to explain the internal > behaviour of gb.qt controls: http://gambasdoc.org/help/api/guicomp. (Have you > read it Daniel?) > I just returned from my travels, I'm the open source Phileas Fogg :-)) I'll try during this week. Rob, may be you got better or more concrete ideas, but I really think the current gb.qt and gb.gtk components are designed just for a "continuous-connection" local environment. If you plan to use just traditional web server connections and JavaScript you will loose the interactivity that you have in a traditional local interface. May be the methods and properties could be cloned, but the event part could not be used if you have not a socket always opened, and even having it, some events like "MouseMove" could be quite expensive if they're sent continuously to the server. There should be a way to decide which events are managed in the client and which ones are managed in the server, but this is not implemented in gb.qt nor gb.gtk. Apart from this there are other problems: how do you plan to fill a large list or a big table? the internet bandwith is short and unstable many times, and those widgets could spend a lot of time while beeing filled or drawn. JavaScript + Firefox or IE performance is quite bad compared with traditional interfaces. The programmer should have any guide telling him to not use it as in a local traditional way. May be the design should be adapted to a network environment, instead of writting a clone. The RAD could provide a special form design for those widgets, I think that is the less expensive part of the project. And the widgets could be designed to provide the feedback needed: automatic progress bars while the data is beeing received in a table or list, information about the synchronization status between data shared in server and client, etc The component should provide also a way to store information to be shared between server and client, so both parts can read and modify it in a transparent way for the programmer, so programming could become as easy as in a local app, without caring about server and client concepts when possible. In the Futura project we're using "network shared memory" (CRUDE) in XML, but may be here something lighter could be used for simple data. May be SVG could be also a good idea to draw the widgets, there are plugins for IE and Firefox supports it natively, as well as webkit, and it provides powerful capabilities compared with the poor HTML controls (listbox, inputbox, buttons and few more). For example, you can not put an image inside a HTML button, and this is just the minor problem. XBL is another interesting idea to create complex widgets, but it is valid only for Firefox and Webkit at this moment. And talking about images an other resources, the design of gb.qt and gb.gtk supposes that images, pdf files and other data is stored locally inside the executable. However, using browsers you have to deal with the URL of the resources, an incompatible way to work. Well, you can put an image into the server executable and send it to the client, but then you can have a big executable that you have to load and unload per each connection. Daniel From cjro99 at ...67... Tue Oct 17 01:09:00 2006 From: cjro99 at ...67... (javier romero) Date: Mon, 16 Oct 2006 23:09:00 +0000 Subject: [Gambas-user] install in mandrivia Message-ID: Hi i changed for RedHat 9 to mandriva 2006,when i try to install gambas 10.0.17 , and use ./configure says Mysql support not enabled, why? what i need to do for install gambas in mandrivia?. before I try to install with Kudlar.org but they have the 10.0.9 not the last and when try to install said me the libmysaclient.so.12 not exist. Thanks Javier Romero _________________________________________________________________ Busca desde cualquier p?gina Web con una protecci?n excepcional. Consigue la Barra de herramientas de Windows Live hoy mismo GRATUITAMENTE. http://toolbar.live.com From sourceforge-raindog2 at ...94... Tue Oct 17 01:22:22 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Mon, 16 Oct 2006 19:22:22 -0400 Subject: [Gambas-user] Web application development In-Reply-To: <7259b5ae0610161518h55b3c59fg5e77f4f6db963f8c@...627...> References: <200610152152.17594.gambas@...1...> <200610162324.46878.gambas@...1...> <7259b5ae0610161518h55b3c59fg5e77f4f6db963f8c@...627...> Message-ID: <200610161922.22827.sourceforge-raindog2@...94...> On Monday 16 October 2006 18:18, Daniel Campos wrote: > If you plan to use just traditional web server connections and > JavaScript you will loose the interactivity that you have in a > traditional local interface. May be the methods and properties > could be cloned, but the event part could not be used if you > have not a socket always opened, and even having it, some > events like "MouseMove" could be quite expensive if they're > sent continuously to the server. There should be a way to > decide which events are managed in the client and which ones > are managed in the server, but this is not implemented in > gb.qt nor gb.gtk. There will be things that gb.whatever has that gb.qt and gb.gtk don't have, and vice versa. MouseMove in particular is something that cannot be implemented at all if there's a network round-trip between the event firing and the program responding. But I think there will be other gb.form implementations someday that have the same issues.... can anyone imagine gb.form.curses? ;) > Apart from this there are other problems: how do you plan to > fill a large list or a big table? the internet bandwith is This was perhaps the worst problem I had to deal with in my current Ajax-based project. My solution was to replace list boxes with auto-suggest text boxes whose onkeyup events triggered a search that would fill the list box. If I were to implement that as a more literal replacement for a Gambas list box, I would probably populate the list box with Listbox.Count blank items, and only populate the items when the user scrolled the list to view them. If that wouldn't work, I might end up having to do some kind of canvas-based thing. There are lots of other glaring issues too. The PictureBox control in Gambas has a lot more features than the img tag in (X)HTML. We'll have a lot less control over the app window than we do in Qt or Gtk. If the app has more than one window, each one may open its own connection to the back end app, even if we're simulating a dialog like a color picker or InputBox. Some classes, like Desktop and Embedder, will be meaningless in a web environment, while others like Font and Window will be vastly reduced in functionality. Most layout controls (VSplit, HBox, etc.) will be so code-intensive as to negate their value. And I don't even want to think about things like UserControl yet. Apart from that, though, Gambas developers looking to migrate their apps to the web will need to adapt their programming styles to the limitations of sending everything over a network. One of my goals will be to make it easier for them to do so than it presently is. The app I've been reimplementing on the web was an Access 2.0 application originally, and I don't want anyone else to ever have to jump through the hoops I did. > May be the design should be adapted to a network environment, > instead of writting a clone. The RAD could provide a special > form design for those widgets, I think that is the less > expensive part of the project. And the widgets could be Hopefully someone who understands the IDE better than I do will someday attempt something like that. To me (even though I have hacked it and added to it in the past) the IDE has a lot of magic in it. > designed to provide the feedback needed: automatic progress > bars while the data is beeing received in a table or list, > information about the synchronization status between data > shared in server and client, etc I have to admit I never even considered the progress bar approach before. It makes a lot of sense. > The component should provide also a way to store information > to be shared between server and client, so both parts can read > and modify it in a transparent way for the programmer, so > programming could become as easy as in a local app, without > caring about server and client concepts when possible. In the > Futura project we're using "network shared memory" (CRUDE) in > XML, but may be here something lighter could be used for > simple data. Yeah, I think I'll have to use XHTML for the form design that gets sent to the browser, but otherwise I'd like to avoid sending XML over the wires. It's just too big. Again, though, I don't mean for the developer to have direct access to the Javascript generated by the component, though maybe I'll end up having to include a way to inject custom code. > May be SVG could be also a good idea to draw the widgets, > there are plugins for IE and Firefox supports it natively, as The SVG plugin for IE will be discontinued as of the end of next year and MS hasn't implemented SVG themselves, so I see SVG as a dead end unless IE's market share goes below 50%. If we were going to go the vector graphics route, I think it might actually make more sense to use swftools. > button, and this is just the minor problem. XBL is another > interesting idea to create complex widgets, but it is valid > only for Firefox and Webkit at this moment. It could be that we could have a dual target, XBL and XAML (for IE7) but I personally can't see myself writing anything in XAML unless Microsoft were giving me money. > And talking about images an other resources, the design of > gb.qt and gb.gtk supposes that images, pdf files and other > data is stored locally inside the executable. However, using > browsers you have to deal with the URL of the resources, an > incompatible way to work. Well, you can put an image into the > server executable and send it to the client, but then you can > have a big executable that you have to load and unload per > each connection. Yes, that's a limitation too. But again, I think that falls into the category of "things the developer must learn", and we could give him tips along the way. (As far as PDF's go, I can't see myself embedding one in a Gambas app, even on the desktop. Generate them in Gambas, sure, but not store a static one in my executable.) Rob From brian at ...1334... Tue Oct 17 05:22:15 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 16 Oct 2006 20:22:15 -0700 (PDT) Subject: [Gambas-user] Toolbar buttons Message-ID: <20061016200922.G36432@...1337...> I'm trying to make a toolbar for use on an existing form for my project. I have a few problems. Toolbar buttons aren't creatable in the form designer with the toolbox panel as the parent. So I've had to use in Form_Open something like: DIM toolButtons AS Variant[] DIM tbItem AS ToolButton ... ... PUBLIC SUB Form_Open() ... ... ' and using code like newButton=NEW ToolButton(theToolBarObject) 'set properties like picture and tag tbItem.W = 30 tbItem.H = 30 '24x24 icon image tbItem.Picture = Picture.Load("SaveIcon.png") tbItem.Tag = "save" tbItem.ToolTip = "Commit Record" toolButtons.Add(tbItem) ... ... End ... ... What I don't know is how to intercept the events these buttons will produce from the code. The form designer allows controls to be placed in groups but there does not seem to be any grouping properties available at runtime that I know of (or if there are the documentation is not easily found with normal browsing). So how do I set up (at runtime) to get events from the buttons on the toolbar and, if required, how do I assign them a group (and use Select...Case...End on the tags) for use in a single event handler? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Tue Oct 17 05:30:08 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 16 Oct 2006 20:30:08 -0700 (PDT) Subject: [Gambas-user] Expand-All/Collapse-All on TreeView's Message-ID: <20061016202844.Q36502@...1337...> Is there a way to programmatically expand (or alternatively, collapse) all the branches in the TreeView object? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Tue Oct 17 08:06:27 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 17 Oct 2006 08:06:27 +0200 Subject: [Gambas-user] Web application development In-Reply-To: <7259b5ae0610161518h55b3c59fg5e77f4f6db963f8c@...627...> References: <200610152152.17594.gambas@...1...> <200610162324.46878.gambas@...1...> <7259b5ae0610161518h55b3c59fg5e77f4f6db963f8c@...627...> Message-ID: <200610170806.27895.gambas@...1...> On Tuesday 17 October 2006 00:18, Daniel Campos wrote: > > I have started a documentation page for Daniel to explain the internal > > behaviour of gb.qt controls: http://gambasdoc.org/help/api/guicomp. (Have > > you read it Daniel?) > > I just returned from my travels, I'm the open source Phileas Fogg :-)) > I'll try during this week. > Hopefully, your travel didn't take 80 days. :-) > Rob, may be you got better or more concrete ideas, but I really think > the current gb.qt and gb.gtk components are designed just for a > "continuous-connection" local environment. If you plan to use just > traditional web server connections and JavaScript you will loose the > interactivity that you have in a traditional local interface. May be > the methods and properties could be cloned, but the event part could > not be used if you have not a socket always opened, and even having > it, some events like "MouseMove" could be quite expensive if they're > sent continuously to the server. There should be a way to decide which > events are managed in the client and which ones are managed in the > server, but this is not implemented in gb.qt nor gb.gtk. > > Apart from this there are other problems: how do you plan to fill a > large list or a big table? the internet bandwith is short and unstable > many times, and those widgets could spend a lot of time while beeing > filled or drawn. JavaScript + Firefox or IE performance is quite bad > compared with traditional interfaces. The programmer should have any > guide telling him to not use it as in a local traditional way. > > May be the design should be adapted to a network environment, instead > of writting a clone. The RAD could provide a special form design for > those widgets, I think that is the less expensive part of the project. > And the widgets could be designed to provide the feedback needed: > automatic progress bars while the data is beeing received in a table > or list, information about the synchronization status between data > shared in server and client, etc > > The component should provide also a way to store information to be > shared between server and client, so both parts can read and modify it > in a transparent way for the programmer, so programming could become > as easy as in a local app, without caring about server and client > concepts when possible. In the Futura project we're using "network > shared memory" (CRUDE) in XML, but may be here something lighter could > be used for simple data. > > May be SVG could be also a good idea to draw the widgets, there are > plugins for IE and Firefox supports it natively, as well as webkit, > and it provides powerful capabilities compared with the poor HTML > controls (listbox, inputbox, buttons and few more). For example, you > can not put an image inside a HTML button, and this is just the minor > problem. XBL is another interesting idea to create complex widgets, > but it is valid only for Firefox and Webkit at this moment. > > And talking about images an other resources, the design of gb.qt and > gb.gtk supposes that images, pdf files and other data is stored > locally inside the executable. However, using browsers you have to > deal with the URL of the resources, an incompatible way to work. Well, > you can put an image into the server executable and send it to the > client, but then you can have a big executable that you have to load > and unload per each connection. > The last point is not a real problem in Gambas, as: - The executable archive is mapped to the memory. - The class are loaded from the mapped memory only at first use. So you can put a big file in your Gambas executable, it won't take more time to load. (To be honest, the time to load is proportional to the number of files stored in the archive because of a relocation process, but it does not take time). Because of that, I can make a CGI script that handles all different pages of website without losing performances. So you could have image URL that are are interpreted by your project CGI script without problems. Regards, -- Benoit Minisini From gambas at ...1... Tue Oct 17 08:10:58 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 17 Oct 2006 08:10:58 +0200 Subject: [Gambas-user] Web application development In-Reply-To: <200610161922.22827.sourceforge-raindog2@...94...> References: <200610152152.17594.gambas@...1...> <7259b5ae0610161518h55b3c59fg5e77f4f6db963f8c@...627...> <200610161922.22827.sourceforge-raindog2@...94...> Message-ID: <200610170810.58967.gambas@...1...> On Tuesday 17 October 2006 01:22, Rob wrote: > On Monday 16 October 2006 18:18, Daniel Campos wrote: > > If you plan to use just traditional web server connections and > > JavaScript you will loose the interactivity that you have in a > > traditional local interface. May be the methods and properties > > could be cloned, but the event part could not be used if you > > have not a socket always opened, and even having it, some > > events like "MouseMove" could be quite expensive if they're > > sent continuously to the server. There should be a way to > > decide which events are managed in the client and which ones > > are managed in the server, but this is not implemented in > > gb.qt nor gb.gtk. > > There will be things that gb.whatever has that gb.qt and gb.gtk > don't have, and vice versa. MouseMove in particular is > something that cannot be implemented at all if there's a network > round-trip between the event firing and the program responding. > But I think there will be other gb.form implementations someday > that have the same issues.... can anyone imagine > gb.form.curses? ;) > > > Apart from this there are other problems: how do you plan to > > fill a large list or a big table? the internet bandwith is > > This was perhaps the worst problem I had to deal with in my > current Ajax-based project. My solution was to replace list > boxes with auto-suggest text boxes whose onkeyup events > triggered a search that would fill the list box. If I were to > implement that as a more literal replacement for a Gambas list > box, I would probably populate the list box with Listbox.Count > blank items, and only populate the items when the user scrolled > the list to view them. If that wouldn't work, I might end up > having to do some kind of canvas-based thing. > > There are lots of other glaring issues too. The PictureBox > control in Gambas has a lot more features than the img tag in > (X)HTML. We'll have a lot less control over the app window than > we do in Qt or Gtk. If the app has more than one window, each > one may open its own connection to the back end app, even if > we're simulating a dialog like a color picker or InputBox. Some > classes, like Desktop and Embedder, will be meaningless in a web > environment, while others like Font and Window will be vastly > reduced in functionality. Most layout controls (VSplit, HBox, > etc.) will be so code-intensive as to negate their value. And I > don't even want to think about things like UserControl yet. > > Apart from that, though, Gambas developers looking to migrate > their apps to the web will need to adapt their programming > styles to the limitations of sending everything over a network. > One of my goals will be to make it easier for them to do so than > it presently is. The app I've been reimplementing on the web > was an Access 2.0 application originally, and I don't want > anyone else to ever have to jump through the hoops I did. > > > May be the design should be adapted to a network environment, > > instead of writting a clone. The RAD could provide a special > > form design for those widgets, I think that is the less > > expensive part of the project. And the widgets could be > > Hopefully someone who understands the IDE better than I do will > someday attempt something like that. To me (even though I have > hacked it and added to it in the past) the IDE has a lot of > magic in it. > This is planned. At the moment a component can declare that it handles a new kind of form. And the compiler can even compile them. It is just that: - The IDE must handle different kind of forms in the project tree. - It must understand some global form kind properties (for example, a WebForm should use a white background...) - The control toolbox must adapt to the edited form kind. There are controls specific to a specific form kind, and controls that can be displayed in any form kind (Timer, Socket...) > > designed to provide the feedback needed: automatic progress > > bars while the data is beeing received in a table or list, > > information about the synchronization status between data > > shared in server and client, etc > > I have to admit I never even considered the progress bar approach > before. It makes a lot of sense. > > > The component should provide also a way to store information > > to be shared between server and client, so both parts can read > > and modify it in a transparent way for the programmer, so > > programming could become as easy as in a local app, without > > caring about server and client concepts when possible. In the > > Futura project we're using "network shared memory" (CRUDE) in > > XML, but may be here something lighter could be used for > > simple data. > > Yeah, I think I'll have to use XHTML for the form design that > gets sent to the browser, but otherwise I'd like to avoid > sending XML over the wires. It's just too big. Again, though, > I don't mean for the developer to have direct access to the > Javascript generated by the component, though maybe I'll end up > having to include a way to inject custom code. > > > May be SVG could be also a good idea to draw the widgets, > > there are plugins for IE and Firefox supports it natively, as > > The SVG plugin for IE will be discontinued as of the end of next > year and MS hasn't implemented SVG themselves, so I see SVG as a > dead end unless IE's market share goes below 50%. If we were > going to go the vector graphics route, I think it might actually > make more sense to use swftools. > > > button, and this is just the minor problem. XBL is another > > interesting idea to create complex widgets, but it is valid > > only for Firefox and Webkit at this moment. > > It could be that we could have a dual target, XBL and XAML (for > IE7) but I personally can't see myself writing anything in XAML > unless Microsoft were giving me money. > > > And talking about images an other resources, the design of > > gb.qt and gb.gtk supposes that images, pdf files and other > > data is stored locally inside the executable. However, using > > browsers you have to deal with the URL of the resources, an > > incompatible way to work. Well, you can put an image into the > > server executable and send it to the client, but then you can > > have a big executable that you have to load and unload per > > each connection. > > Yes, that's a limitation too. No, see my previous answer to Daniel. > But again, I think that falls into > the category of "things the developer must learn", and we could > give him tips along the way. (As far as PDF's go, I can't see > myself embedding one in a Gambas app, even on the desktop. > Generate them in Gambas, sure, but not store a static one in my > executable.) > > Rob > Regards, -- Benoit Minisini From brian at ...1334... Tue Oct 17 08:10:19 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 16 Oct 2006 23:10:19 -0700 (PDT) Subject: [Gambas-user] TreeView internal cursor Message-ID: <20061016230442.P36953@...1337...> In my workings with this control I discovered it would be really useful to be able to store/retrieve internal cursor states such as in recursive code to visit every item in the tree either in breadth-first or depth-first recursive traversal routines. The virtual TreeViewItem won't work for this so perhaps a way to store/retrieve the cursor would be helpful. In the abscence of something like that how about an iterator operation that guarantees just to hit every object in the TreeView when niether hierarchy nor order is important. The hierarchical operations are, without being able to save/recover the internal cursor methods are awkward to work with. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From dcamposf at ...626... Tue Oct 17 09:36:52 2006 From: dcamposf at ...626... (Daniel Campos) Date: Tue, 17 Oct 2006 09:36:52 +0200 Subject: [Gambas-user] install in mandrivia In-Reply-To: References: Message-ID: <7259b5ae0610170036w7201c972tdad2bfac512fcb7c@...627...> I think current distributions use libmysqlclient.so.14, that anyway should work. Probably you didn't install the rpm devel package: libmysqlclient-devel.rpm or something like that in your distro. it is needed to compile from sources. Daniel 2006/10/17, javier romero : > Hi i changed for RedHat 9 to mandriva 2006,when i try to install gambas 10.0.17 , and use ./configure says Mysql support not enabled, why? what i need to do for install gambas in mandrivia?. before I try to install with Kudlar.org but they have the 10.0.9 not the last and when try to install said me the libmysaclient.so.12 not exist. > > Thanks > Javier Romero > > > _________________________________________________________________ > Busca desde cualquier p?gina Web con una protecci?n excepcional. Consigue la Barra de herramientas de Windows Live hoy mismo GRATUITAMENTE. > http://toolbar.live.com > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From brian at ...1334... Tue Oct 17 11:21:29 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 17 Oct 2006 02:21:29 -0700 (PDT) Subject: [Gambas-user] TreeView+TreeViewItem problems continued Message-ID: <20061017021328.Q37950@...1337...> is: DIM hLVItem AS .ListViewItem broken in 1.9.44? I'd like to be able to pass the handle around for things like recursive function definitions (both the depth-first and breadth-first traversals may be done recursively) but trying it the above way (as shown in the documentation) doesn't work. I mentioned in a previous post I'm having trouble with trying to descend through the TreeView items with either breadth-first or depth-first visitation. Even if I could pass these values I think there may still be issues with losing the cursor position higher up in a recursive call chain. Does no one use this control? It would appear to me that to save the contents of a TreeView one needs to be able to visit the elements in-order to save them and keep the relations. Also this object has no simple iterator (one that can be used without knowledge of the elements--namely that they have parents and children as is the case in a TreeView). A simple iterator can be used when it is not required that the traversal follow any order, only that each element be iterated (visited) once. I know as I already tried FOR EACH with no luck. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From timothy.marshal-nichols at ...247... Tue Oct 17 14:55:04 2006 From: timothy.marshal-nichols at ...247... (Timothy Marshal-Nichols) Date: Tue, 17 Oct 2006 13:55:04 +0100 Subject: [Gambas-user] TreeView internal cursor In-Reply-To: <20061016230442.P36953@...1337...> Message-ID: <000001c6f1eb$78daeda0$6401a8c0@...1587...> > -----Original Message----- > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > bounces at lists.sourceforge.net] On Behalf Of Christopher Brian Jack > Sent: 17 October 2006 07:10 > To: Gambas-Users List > Subject: [Gambas-user] TreeView internal cursor > > > In my workings with this control I discovered it would be really useful to > be able to store/retrieve internal cursor states such as in recursive code > to visit every item in the tree either in breadth-first or depth-first > recursive traversal routines. The virtual TreeViewItem won't work for > this so perhaps a way to store/retrieve the cursor would be helpful. > > In the abscence of something like that how about an iterator operation > that guarantees just to hit every object in the TreeView when > niether hierarchy nor order is important. The hierarchical operations > are, without being able to save/recover the internal cursor methods are > awkward to work with. > It already does - at least for the gb.qt TreeView. Though it might not be very well documented. Use MoveBelow() as in this example: ' Go to the first item IF TreeView1.MoveFirst() THEN REPEAT ' Do what you need with the tree view item ' Next item in the TreeView UNTIL TreeView1.MoveBelow() END IF This will visit every item in the TreeView. (Not sure if it works with Gambas 1.0.xx) Thanks 8-) Timothy Marshal-Nichols From cjro99 at ...67... Tue Oct 17 14:57:00 2006 From: cjro99 at ...67... (javier romero) Date: Tue, 17 Oct 2006 12:57:00 +0000 Subject: [Gambas-user] install in mandrivia Message-ID: Yes, I Install the libmysqlclient-devel.rpm, but nothing happens, the problem persists Thanks Javier ---------------------------------------- > Date: Tue, 17 Oct 2006 09:36:52 +0200 > From: dcamposf at ...626... > To: gambas-user at lists.sourceforge.net > Subject: Re: [Gambas-user] install in mandrivia > > I think current distributions use libmysqlclient.so.14, that anyway > should work. Probably you didn't install the rpm devel package: > libmysqlclient-devel.rpm or something like that in your distro. it is > needed to compile from sources. > > Daniel > > 2006/10/17, javier romero : > > Hi i changed for RedHat 9 to mandriva 2006,when i try to install gambas 10.0.17 , and use ./configure says Mysql support not enabled, why? what i need to do for install gambas in mandrivia?. before I try to install with Kudlar.org but they have the 10.0.9 not the last and when try to install said me the libmysaclient.so.12 not exist. > > > > Thanks > > Javier Romero > > > > > > _________________________________________________________________ > > Busca desde cualquier p?gina Web con una protecci?n excepcional. Consigue la Barra de herramientas de Windows Live hoy mismo GRATUITAMENTE. > > http://toolbar.live.com > > ------------------------------------------------------------------------- > > Using Tomcat but need to do more? Need to support web services, security? > > Get stuff done quickly with pre-integrated technology to make your job easier > > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user _________________________________________________________________ Llama a tus amigos de PC a PC: ?Es GRATIS! http://get.live.com/messenger/overview From timothy.marshal-nichols at ...247... Tue Oct 17 16:59:21 2006 From: timothy.marshal-nichols at ...247... (Timothy Marshal-Nichols) Date: Tue, 17 Oct 2006 15:59:21 +0100 Subject: [Gambas-user] TreeView internal cursor In-Reply-To: <000001c6f1eb$78daeda0$6401a8c0@...1587...> Message-ID: <000001c6f1fc$d5051310$6401a8c0@...1587...> > > > It already does - at least for the gb.qt TreeView. Though it might not > be very well documented. Use MoveBelow() as in this example: > > ' Go to the first item > IF TreeView1.MoveFirst() THEN > REPEAT > ' Do what you need with the tree view item > > ' Next item in the TreeView > UNTIL TreeView1.MoveBelow() > END IF > > This will visit every item in the TreeView. (Not sure if it works with > Gambas 1.0.xx) > Ugh! Let me correct that example: ' Go to the first item IF NOT TreeView1.MoveFirst() THEN REPEAT ' Do what you need with the tree view item PRINT TreeView1.Item.Text ' Next item in the TreeView UNTIL TreeView1.MoveBelow() END IF Thanks 8-) Timothy Marshal-Nichols From brian at ...1334... Tue Oct 17 17:13:36 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 17 Oct 2006 08:13:36 -0700 (PDT) Subject: [Gambas-user] Problem: how to get toolbutton events from dynamic toolbuttons Message-ID: <20061017080807.Q39880@...1337...> My Form defines an HBar object (on the form via the designer) However the ToolButton items have to be placed in at runtime since currently the designer does not allow any object to have a parent other than the form itself. Actually right now my form is actually using an HBox container. And the buttons are created with the HBox as the parent (to get get Horizontal alignment) at runtime in my Form_Open code using NEW. How do I handle events from such ToolButtons being created at runtime from the Form code? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From rospolosco at ...152... Tue Oct 17 17:28:11 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Tue, 17 Oct 2006 17:28:11 +0200 Subject: [Gambas-user] Problem: how to get toolbutton events from dynamic toolbuttons In-Reply-To: <20061017080807.Q39880@...1337...> References: <20061017080807.Q39880@...1337...> Message-ID: <200610171728.12217.rospolosco@...152...> Alle 17:13, marted? 17 ottobre 2006, Christopher Brian Jack ha scritto: > Actually right now my form is actually using an HBox container. ?And the > buttons are created with the HBox as the parent (to get get Horizontal > alignment) at runtime in my Form_Open code using NEW. > > How do I handle events from such ToolButtons being created at runtime from > the Form code? Probably you did: MyButton1 = NEW Button AS "mybuttons" MyButton2 = NEW Button AS "mybuttons" then to get their events just PUBLIC SUB mybuttons_click() Bye, Stefano From berto.melgar at ...626... Tue Oct 17 18:40:42 2006 From: berto.melgar at ...626... (Berto) Date: Tue, 17 Oct 2006 17:40:42 +0100 Subject: [Gambas-user] install in mandrivia In-Reply-To: References: Message-ID: <38e9ff990610170940l7a342c00vc2076f0102ee6d9f@...627...> this is what i have in my mandriva 2006 maybe can help you root barebone:/home/berto# rpm -qa | grep -i mysql MySQL-common-4.1.12-4.10.20060mdk MySQL-client-4.1.12-4.10.20060mdk perl-DBD-mysql-3.0002-1mdk libmysql14-devel-4.1.12-4.10.20060mdk gambas-gb-db-mysql-1.0.10-1mdk libmysql14-4.1.12-4.10.20060mdk 2006/10/17, javier romero : > Yes, I Install the libmysqlclient-devel.rpm, but nothing happens, the problem persists > > Thanks > Javier > > > > > ---------------------------------------- > > Date: Tue, 17 Oct 2006 09:36:52 +0200 > > From: dcamposf at ...626... > > To: gambas-user at lists.sourceforge.net > > Subject: Re: [Gambas-user] install in mandrivia > > > > I think current distributions use libmysqlclient.so.14, that anyway > > should work. Probably you didn't install the rpm devel package: > > libmysqlclient-devel.rpm or something like that in your distro. it is > > needed to compile from sources. > > > > Daniel > > > > 2006/10/17, javier romero : > > > Hi i changed for RedHat 9 to mandriva 2006,when i try to install gambas 10.0.17 , and use ./configure says Mysql support not enabled, why? what i need to do for install gambas in mandrivia?. before I try to install with Kudlar.org but they have the 10.0.9 not the last and when try to install said me the libmysaclient.so.12 not exist. > > > > > > Thanks > > > Javier Romero > > > > > > > > > _________________________________________________________________ > > > Busca desde cualquier p?gina Web con una protecci?n excepcional. Consigue la Barra de herramientas de Windows Live hoy mismo GRATUITAMENTE. > > > http://toolbar.live.com > > > ------------------------------------------------------------------------- > > > Using Tomcat but need to do more? Need to support web services, security? > > > Get stuff done quickly with pre-integrated technology to make your job easier > > > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > > _______________________________________________ > > > Gambas-user mailing list > > > Gambas-user at lists.sourceforge.net > > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > ------------------------------------------------------------------------- > > Using Tomcat but need to do more? Need to support web services, security? > > Get stuff done quickly with pre-integrated technology to make your job easier > > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > _________________________________________________________________ > Llama a tus amigos de PC a PC: ?Es GRATIS! > http://get.live.com/messenger/overview > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- "Reality is that which, when you stop believing in it, doesn't go away." - Philip K. Dick "El sexo sucio? s?, claro; pero solo cuando se hace bien. - Woody Allen "No merece la pena morir de todo esto, la mitad es convenci?n, la otra mitad mentira." Dylan Thomas From gambas at ...1... Tue Oct 17 18:59:21 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 17 Oct 2006 18:59:21 +0200 Subject: [Gambas-user] TreeView+TreeViewItem problems continued In-Reply-To: <20061017021328.Q37950@...1337...> References: <20061017021328.Q37950@...1337...> Message-ID: <200610171859.21760.gambas@...1...> On Tuesday 17 October 2006 11:21, Christopher Brian Jack wrote: > is: > > DIM hLVItem AS .ListViewItem > > broken in 1.9.44? > > I'd like to be able to pass the handle around for things like recursive > function definitions (both the depth-first and breadth-first traversals > may be done recursively) but trying it the above way (as shown in the > documentation) doesn't work. > > I mentioned in a previous post I'm having trouble with trying to descend > through the TreeView items with either breadth-first or depth-first > visitation. Even if I could pass these values I think there may still be > issues with losing the cursor position higher up in a recursive call > chain. > > Does no one use this control? > > It would appear to me that to save the contents of a TreeView one needs to > be able to visit the elements in-order to save them and keep the > relations. > > Also this object has no simple iterator (one that can be used without > knowledge of the elements--namely that they have parents and children as > is the case in a TreeView). A simple iterator can be used when it is not > required that the traversal follow any order, only that each element be > iterated (visited) once. I know as I already tried FOR EACH with no luck. > You can save and recover the Item property (the internal cursor) by doing: DIM sSave AS String sSave = MyTreeView.Item.Key ... MyTreeView.MoveTo(sSave) I think too that a FOR EACH on ListView, TreeView, etc. would be useful, but I never had the time to do it. It is not as simple as it appears, because iterators should care with deleted items. Regards, -- Benoit Minisini From gambas at ...1... Tue Oct 17 19:02:08 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 17 Oct 2006 19:02:08 +0200 Subject: [Gambas-user] Problem: how to get toolbutton events from dynamic toolbuttons In-Reply-To: <20061017080807.Q39880@...1337...> References: <20061017080807.Q39880@...1337...> Message-ID: <200610171902.08733.gambas@...1...> On Tuesday 17 October 2006 17:13, Christopher Brian Jack wrote: > My Form defines an HBar object (on the form via the designer) > > However the ToolButton items have to be placed in at runtime since > currently the designer does not allow any object to have a parent other > than the form itself. What are you talking about ? Nobody before you got this bug... You can put what you want in a HBox (I suppose you are wanted to say HBox instead of HBar, which does not exist). Look at the IDE source code, you will see many toolbars full of ToolButtons. Regards, -- Benoit Minisini From brian at ...1334... Tue Oct 17 19:46:00 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 17 Oct 2006 10:46:00 -0700 (PDT) Subject: [Gambas-user] Problem: how to get toolbutton events from dynamic toolbuttons In-Reply-To: <200610171728.12217.rospolosco@...152...> References: <20061017080807.Q39880@...1337...> <200610171728.12217.rospolosco@...152...> Message-ID: <20061017104418.S40441@...1337...> On Tue, 17 Oct 2006, Stefano Palmeri wrote: Thanks. For showing me what I was missing, AND how to use what the Form designer implements as groups (which is by making hte control names in the AS part the same). > Alle 17:13, marted? 17 ottobre 2006, Christopher Brian Jack ha scritto: > > Actually right now my form is actually using an HBox container. ?And the > > buttons are created with the HBox as the parent (to get get Horizontal > > alignment) at runtime in my Form_Open code using NEW. > > > > How do I handle events from such ToolButtons being created at runtime from > > the Form code? > > Probably you did: > > MyButton1 = NEW Button AS "mybuttons" > MyButton2 = NEW Button AS "mybuttons" > > then to get their events just > > PUBLIC SUB mybuttons_click() > > Bye, > > Stefano .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Tue Oct 17 20:23:53 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 17 Oct 2006 11:23:53 -0700 (PDT) Subject: [Gambas-user] How to handle TreeViewItems and CLASS association In-Reply-To: <200610171859.21760.gambas@...1...> References: <20061017021328.Q37950@...1337...> <200610171859.21760.gambas@...1...> Message-ID: <20061017104723.C40441@...1337...> > > Also this object has no simple iterator (one that can be used without > > knowledge of the elements--namely that they have parents and children as > > is the case in a TreeView). A simple iterator can be used when it is not > > required that the traversal follow any order, only that each element be > > iterated (visited) once. I know as I already tried FOR EACH with no luck. > I think too that a FOR EACH on ListView, TreeView, etc. would be useful, but I > never had the time to do it. It is not as simple as it appears, because > iterators should care with deleted items. Simple, in this case, really is only referring to the characteristic of the iterator only providing the guanratee of accessing all available items in the collection, NOT the implementation complexity of implementing such an iterator. For instance a simple iterator on a hash table may not even iterate back the items in order of insertion (depends on the hash function) but it does guarantee iterating all available elements. I'd suggest having the iterators use virtual classes that implement read-only elements (similar to the index [] operator) but the issue of not being able to DIM a virtual class or even sticking it to a variable storing a Variant (for the iterator cursor variable) is a potential issue. > You can save and recover the Item property (the internal cursor) by doing: > > DIM sSave AS String > > sSave = MyTreeView.Item.Key > ... > MyTreeView.MoveTo(sSave) Thanks for the solution. It never even occurred to me that I could use the element keys that way. Now one more question - can the items in a TreeView be associated with an instance of a storage class? How about one that can "compound"? Say the TreeView looks like this: root |-n1 |`_n1c1 `-n2 and classes: classRoot classN1 classN2 classC1 root should inherit classRoot n1 should inherit a compound: classRoot+classN1 n1c1 should inherit a compound: classRoot+classN1+classC1 n2 should inherit a compound: classRoot+classN2 (where I have +'s the classes compound up to the root and when compounded the precedence moves towards the leaf thus allowing overrides of properties and such). Now the hitch is that this tree is going to manipulated at runtime so basically I need a runtime way of handling what is done by "INHERITS" in class files at compile time. Should I just let the contents of such classes be kept as database tables? The only catch here is that a deeply nested class may need to involve numerous database accesses and that deleteing items and making sure all associated tables have the entry for that key (the element in the TreeView being deleted) removed (and the bookkeeping of adding that key to the relevant tables when inserted) oh and then there's inheritence and overloading of properties... OUCH! I think I really need a middle-ware road here that doesn't have me reimplementing the entire class system from scratch! That would just be ouch, ouch, ouch, ouch, OWWWWWWWWWWWWCH! .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Tue Oct 17 20:26:26 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 17 Oct 2006 11:26:26 -0700 (PDT) Subject: [Gambas-user] Problem: how to get toolbutton events from dynamic toolbuttons In-Reply-To: <200610171902.08733.gambas@...1...> References: <20061017080807.Q39880@...1337...> <200610171902.08733.gambas@...1...> Message-ID: <20061017112425.C40441@...1337...> On Tue, 17 Oct 2006, Benoit Minisini wrote: > What are you talking about ? Nobody before you got this bug... You can put > what you want in a HBox (I suppose you are wanted to say HBox instead of > HBar, which does not exist). Look at the IDE source code, you will see many > toolbars full of ToolButtons. How do you create a form based on anything other than the form class in the From designer? Or in the Form designer create a ToolButton with a parent anything other than the Form itself? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Wed Oct 18 00:36:46 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 17 Oct 2006 15:36:46 -0700 (PDT) Subject: [Gambas-user] The Mascot Message-ID: <20061017153537.A41599@...1337...> No ideas about implementing a modular interface to expand the capabilities of the Gambas Mascot? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Wed Oct 18 00:38:22 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Tue, 17 Oct 2006 15:38:22 -0700 (PDT) Subject: [Gambas-user] The Mascot In-Reply-To: <20061017153537.A41599@...1337...> References: <20061017153537.A41599@...1337...> Message-ID: <20061017153756.H41610@...1337...> When I built the 1.9.44 branch was the IDE source in there somewhere? On Tue, 17 Oct 2006, Christopher Brian Jack wrote: > Date: Tue, 17 Oct 2006 15:36:46 -0700 (PDT) > From: Christopher Brian Jack > Reply-To: mailing list for gambas users > > To: Gambas-Users List > Subject: Re: [Gambas-user] The Mascot > > > No ideas about implementing a modular interface to expand the capabilities > of the Gambas Mascot? > > .=================================================. > | Christopher BRIAN Jack aka "Gau of the Veldt" | > +=================================================' > | oevna at ...1544... > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gael.le-hech at ...357... Wed Oct 18 11:01:22 2006 From: gael.le-hech at ...357... (=?ISO-8859-1?Q?Ga=EBl_Le_Hec=27H?=) Date: Wed, 18 Oct 2006 11:01:22 +0200 Subject: [Gambas-user] ComboBox limitation ? Message-ID: <4535ED62.8010707@...357...> is there a limit for the items in a combobox ? see project. on my machine at runtime I only see item 64 to 99 unless of 00 to 99 :( Have you got this pb ? -------------- next part -------------- A non-text attachment was scrubbed... Name: test-combobox-0.0.1.tar.gz Type: application/gzip Size: 5237 bytes Desc: not available URL: From cjro99 at ...67... Wed Oct 18 15:07:02 2006 From: cjro99 at ...67... (javier romero) Date: Wed, 18 Oct 2006 13:07:02 +0000 Subject: [Gambas-user] install in mandrivia Message-ID: Thanks, finally i resolv the dependnecies and now is working. Javier ---------------------------------------- > Date: Tue, 17 Oct 2006 17:40:42 +0100 > From: berto.melgar at ...626... > To: gambas-user at lists.sourceforge.net > Subject: Re: [Gambas-user] install in mandrivia > > this is what i have in my mandriva 2006 maybe can help you > > root barebone:/home/berto# rpm -qa | grep -i mysql > MySQL-common-4.1.12-4.10.20060mdk > MySQL-client-4.1.12-4.10.20060mdk > perl-DBD-mysql-3.0002-1mdk > libmysql14-devel-4.1.12-4.10.20060mdk > gambas-gb-db-mysql-1.0.10-1mdk > libmysql14-4.1.12-4.10.20060mdk > > > 2006/10/17, javier romero : > > Yes, I Install the libmysqlclient-devel.rpm, but nothing happens, the problem persists > > > > Thanks > > Javier > > > > > > > > > > ---------------------------------------- > > > Date: Tue, 17 Oct 2006 09:36:52 +0200 > > > From: dcamposf at ...626... > > > To: gambas-user at lists.sourceforge.net > > > Subject: Re: [Gambas-user] install in mandrivia > > > > > > I think current distributions use libmysqlclient.so.14, that anyway > > > should work. Probably you didn't install the rpm devel package: > > > libmysqlclient-devel.rpm or something like that in your distro. it is > > > needed to compile from sources. > > > > > > Daniel > > > > > > 2006/10/17, javier romero : > > > > Hi i changed for RedHat 9 to mandriva 2006,when i try to install gambas 10.0.17 , and use ./configure says Mysql support not enabled, why? what i need to do for install gambas in mandrivia?. before I try to install with Kudlar.org but they have the 10.0.9 not the last and when try to install said me the libmysaclient.so.12 not exist. > > > > > > > > Thanks > > > > Javier Romero > > > > > > > > > > > > _________________________________________________________________ > > > > Busca desde cualquier p?gina Web con una protecci?n excepcional. Consigue la Barra de herramientas de Windows Live hoy mismo GRATUITAMENTE. > > > > http://toolbar.live.com > > > > ------------------------------------------------------------------------- > > > > Using Tomcat but need to do more? Need to support web services, security? > > > > Get stuff done quickly with pre-integrated technology to make your job easier > > > > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > > > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > > > _______________________________________________ > > > > Gambas-user mailing list > > > > Gambas-user at lists.sourceforge.net > > > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > > > > ------------------------------------------------------------------------- > > > Using Tomcat but need to do more? Need to support web services, security? > > > Get stuff done quickly with pre-integrated technology to make your job easier > > > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > > _______________________________________________ > > > Gambas-user mailing list > > > Gambas-user at lists.sourceforge.net > > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > _________________________________________________________________ > > Llama a tus amigos de PC a PC: ?Es GRATIS! > > http://get.live.com/messenger/overview > > ------------------------------------------------------------------------- > > Using Tomcat but need to do more? Need to support web services, security? > > Get stuff done quickly with pre-integrated technology to make your job easier > > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > -- > "Reality is that which, when you stop believing in it, doesn't go > away." - Philip K. Dick > "El sexo sucio? s?, claro; pero solo cuando se hace bien. - Woody Allen > "No merece la pena morir de todo esto, la mitad es convenci?n, la otra > mitad mentira." Dylan Thomas > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user _________________________________________________________________ Consigue el nuevo Windows Live Messenger http://get.live.com/messenger/overview From gambas at ...1... Wed Oct 18 15:16:14 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 18 Oct 2006 15:16:14 +0200 Subject: [Gambas-user] ComboBox limitation ? In-Reply-To: <4535ED62.8010707@...357...> References: <4535ED62.8010707@...357...> Message-ID: <200610181516.15013.gambas@...1...> On Wednesday 18 October 2006 11:01, Ga?l Le Hec'H wrote: > is there a limit for the items in a combobox ? > see project. on my machine at runtime I only see item 64 to 99 unless of > 00 to 99 :( > Have you got this pb ? This is actually a limitation in the interpreter that cannot call a function with more than 64 arguments. Then it seems that there is a bug in the compiler: instead of raising an error (too many arguments), it wraps the number of arguments, it takes the 100 MOD 64 = 36 last arguments, and so your combo-box gets only the 64 to 99 entries. A workaround for that is filling the combo-box by code: you create a text file with one entry by line, and you load it into the combo-box this way: MyComboBox.List = Split(File.Load("MyFile.txt"), "\n") Sorry for the inconvenience! Regards, -- Benoit Minisini From buxaman at ...626... Wed Oct 18 15:41:51 2006 From: buxaman at ...626... (Fabricio Silva) Date: Wed, 18 Oct 2006 11:41:51 -0200 Subject: [Gambas-user] Unknow symbol field in class 'DataControl' Message-ID: Hello, I'm using gambas 1.9.34 and SuSE 10.0. I'm using data source e data browser controls to access a database. Everything ok. The tables configured are shown correctly but when I click in the new "Unknow symbol field in class 'DataControl'" error appears. The strage is that It worked once without making any changes. Even with the example the error appears. Fabricio Silva From gambas at ...1... Wed Oct 18 15:54:37 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 18 Oct 2006 15:54:37 +0200 Subject: [Gambas-user] Unknow symbol field in class 'DataControl' In-Reply-To: References: Message-ID: <200610181554.38021.gambas@...1...> On Wednesday 18 October 2006 15:41, Fabricio Silva wrote: > Hello, > > I'm using gambas 1.9.34 and SuSE 10.0. I'm using data source e data browser > controls to access a database. Everything ok. The tables configured are > shown correctly but when I click in the new "Unknow symbol field in class > 'DataControl'" error appears. The strage is that It worked once without > making any changes. Even with the example the error appears. > > > Fabricio Silva It have been fixed in 1.9.38. Can you try the last version? -- Benoit Minisini From gambas at ...1... Wed Oct 18 16:39:54 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 18 Oct 2006 16:39:54 +0200 Subject: [Gambas-user] ComboBox limitation ? In-Reply-To: <4535ED62.8010707@...357...> References: <4535ED62.8010707@...357...> Message-ID: <200610181639.54432.gambas@...1...> On Wednesday 18 October 2006 11:01, Ga?l Le Hec'H wrote: > is there a limit for the items in a combobox ? > see project. on my machine at runtime I only see item 64 to 99 unless of > 00 to 99 :( > Have you got this pb ? I found a workaround, so that you can put as many items as you want. You will get it in the SVN repository, or in the next release. Regards, -- Benoit Minisini From Karl.Reinl at ...9... Wed Oct 18 20:48:05 2006 From: Karl.Reinl at ...9... (Charlie Reinl) Date: Wed, 18 Oct 2006 20:48:05 +0200 Subject: [Gambas-user] The Mascot In-Reply-To: <20061017153756.H41610@...1337...> References: <20061017153537.A41599@...1337...> <20061017153756.H41610@...1337...> Message-ID: <1161197286.5310.3.camel@...40...> Am Dienstag, den 17.10.2006, 15:38 -0700 schrieb Christopher Brian Jack: Salut, you will find it in /gambas2-1.9.44/app/src/gambas2 Amicalment Charlie > When I built the 1.9.44 branch was the IDE source in there somewhere? > > On Tue, 17 Oct 2006, Christopher Brian Jack wrote: > > > Date: Tue, 17 Oct 2006 15:36:46 -0700 (PDT) > > From: Christopher Brian Jack > > Reply-To: mailing list for gambas users > > > > To: Gambas-Users List > > Subject: Re: [Gambas-user] The Mascot > > > > > > No ideas about implementing a modular interface to expand the capabilities > > of the Gambas Mascot? > > > > .=================================================. > > | Christopher BRIAN Jack aka "Gau of the Veldt" | > > +=================================================' > > | oevna at ...1544... > > `=================================================- > > Hi Spambots, my email address is sputnik at ...1334... > > Hi Humans, my email address uses rot13 cipher > > > > > > ------------------------------------------------------------------------- > > Using Tomcat but need to do more? Need to support web services, security? > > Get stuff done quickly with pre-integrated technology to make your job easier > > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > .=================================================. > | Christopher BRIAN Jack aka "Gau of the Veldt" | > +=================================================' > | oevna at ...1544... > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From brian at ...1334... Thu Oct 19 02:08:06 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Wed, 18 Oct 2006 17:08:06 -0700 (PDT) Subject: [Gambas-user] Fixed a minor mascot issue Message-ID: <20061018170132.M48156@...1337...> This slightly modified _init in the IDE code shirnks the form (with a slight constant of kludgery) to the size of the largest animation image. On my Debian system the space is noticeable as the form won't allow itself to be dragged past the screen edge. Without the resize the mascot is a good inch or so from the right edge of the screen at maximum right-drag and ends up way over left of the scrollbar in the code window. Shrinking the from to the image size allows dragging much closer to the lower right screen corner and getting him out of the code window. STATIC PUBLIC SUB _init() DIM iInd AS Integer DIM maxW AS Integer DIM maxH AS Integer $cAnim["Blink"] = "1,0,1,0" $cAnim["Blink2"] = "3,4,3,0" $cAnim["Depressive"] = "2,6,7,-8,6,2,0,-8" $cAnim["Happy"] = "5,0,5,0" 'Shrinks the form to match 'the largest animation image maxW = 0 maxH = 0 FOR iInd = 0 TO 7 $hPict[iInd] = Picture["img/anim/gambas" & CStr(iInd + 1) & ".png"] maxH = Max(maxH, $hPict[iInd].Height) maxW = Max(maxW, $hPict[iInd].Width) NEXT 'The +11,+3 is a kludge to even the padding 'of the Form versus the background image, 'tested by dragging to the four corners of 'the screen and adjusting the numbers to 'even the spacing to the edges on all 'screen corners. ME.Resize(maxW + 11, maxH + 3) END .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From rolf.frogs at ...221... Thu Oct 19 18:43:24 2006 From: rolf.frogs at ...221... (rolf) Date: Thu, 19 Oct 2006 18:43:24 +0200 Subject: [Gambas-user] Size of a picture Message-ID: <200610191843.24484.rolf.frogs@...221...> Hi everybody, I would like to store a picture in a postgresql database. So every non char (i.e. A-Z, a-z, 0-9...) have to be quoted as octal numbers with two leading backslashes. Because the Replace function only works with strings I have to loop through the picture data and do the substitution by myself. To do so, I need the number of bytes the picture has. How can I get this value? Many thanks in advance Rolf From gambas at ...1... Thu Oct 19 19:30:14 2006 From: gambas at ...1... (Benoit Minisini) Date: Thu, 19 Oct 2006 19:30:14 +0200 Subject: [Gambas-user] Fixed a minor mascot issue In-Reply-To: <20061018170132.M48156@...1337...> References: <20061018170132.M48156@...1337...> Message-ID: <200610191930.14899.gambas@...1...> On Thursday 19 October 2006 02:08, Christopher Brian Jack wrote: > This slightly modified _init in the IDE code shirnks the form (with a > slight constant of kludgery) to the size of the largest animation image. > On my Debian system the space is noticeable as the form won't allow itself > to be dragged past the screen edge. Without the resize the mascot is a > good inch or so from the right edge of the screen at maximum right-drag > and ends up way over left of the scrollbar in the code window. Shrinking > the from to the image size allows dragging much closer to the lower right > screen corner and getting him out of the code window. > > STATIC PUBLIC SUB _init() > > DIM iInd AS Integer > DIM maxW AS Integer > DIM maxH AS Integer > > $cAnim["Blink"] = "1,0,1,0" > $cAnim["Blink2"] = "3,4,3,0" > $cAnim["Depressive"] = "2,6,7,-8,6,2,0,-8" > $cAnim["Happy"] = "5,0,5,0" > > 'Shrinks the form to match > 'the largest animation image > maxW = 0 > maxH = 0 > FOR iInd = 0 TO 7 > $hPict[iInd] = Picture["img/anim/gambas" & CStr(iInd + 1) & ".png"] > maxH = Max(maxH, $hPict[iInd].Height) > maxW = Max(maxW, $hPict[iInd].Width) > NEXT > 'The +11,+3 is a kludge to even the padding > 'of the Form versus the background image, > 'tested by dragging to the four corners of > 'the screen and adjusting the numbers to > 'even the spacing to the edges on all > 'screen corners. > ME.Resize(maxW + 11, maxH + 3) > > END > > Thanks. But I don't understand the need of adding 11 and 3. Hardcoded values like this are rarely a good idea... -- Benoit Minisini From brian at ...1334... Thu Oct 19 19:48:08 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 19 Oct 2006 10:48:08 -0700 (PDT) Subject: [Gambas-user] Size of a picture In-Reply-To: <200610191843.24484.rolf.frogs@...221...> References: <200610191843.24484.rolf.frogs@...221...> Message-ID: <20061019104704.U52775@...1337...> On Thu, 19 Oct 2006, rolf wrote: > Hi everybody, > > I would like to store a picture in a postgresql database. So every non char > (i.e. A-Z, a-z, 0-9...) have to be quoted as octal numbers with two leading > backslashes. Because the Replace function only works with strings I have to > loop through the picture data and do the substitution by myself. > > To do so, I need the number of bytes the picture has. How can I get this > value? If you are getting the picture from a file you can get the length from the file on disk. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Thu Oct 19 19:55:14 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 19 Oct 2006 10:55:14 -0700 (PDT) Subject: [Gambas-user] Fixed a minor mascot issue In-Reply-To: <200610191930.14899.gambas@...1...> References: <20061018170132.M48156@...1337...> <200610191930.14899.gambas@...1...> Message-ID: <20061019104903.W52775@...1337...> As the code states they are there to even the padding as the images have some apparent spacing at the left and top sides so the pads are there to balance it by putting some approximately equivalent padding at the right and bottom sides by slightly enlarging the form. Hardcoding isn't good but one line of source beats manually adding the space to all the images in the GIMP. On Thu, 19 Oct 2006, Benoit Minisini wrote: > Date: Thu, 19 Oct 2006 19:30:14 +0200 > From: Benoit Minisini > Reply-To: mailing list for gambas users > > To: mailing list for gambas users > Subject: Re: [Gambas-user] Fixed a minor mascot issue > > On Thursday 19 October 2006 02:08, Christopher Brian Jack wrote: > > This slightly modified _init in the IDE code shirnks the form (with a > > slight constant of kludgery) to the size of the largest animation image. > > On my Debian system the space is noticeable as the form won't allow itself > > to be dragged past the screen edge. Without the resize the mascot is a > > good inch or so from the right edge of the screen at maximum right-drag > > and ends up way over left of the scrollbar in the code window. Shrinking > > the from to the image size allows dragging much closer to the lower right > > screen corner and getting him out of the code window. > > > > STATIC PUBLIC SUB _init() > > > > DIM iInd AS Integer > > DIM maxW AS Integer > > DIM maxH AS Integer > > > > $cAnim["Blink"] = "1,0,1,0" > > $cAnim["Blink2"] = "3,4,3,0" > > $cAnim["Depressive"] = "2,6,7,-8,6,2,0,-8" > > $cAnim["Happy"] = "5,0,5,0" > > > > 'Shrinks the form to match > > 'the largest animation image > > maxW = 0 > > maxH = 0 > > FOR iInd = 0 TO 7 > > $hPict[iInd] = Picture["img/anim/gambas" & CStr(iInd + 1) & ".png"] > > maxH = Max(maxH, $hPict[iInd].Height) > > maxW = Max(maxW, $hPict[iInd].Width) > > NEXT > > 'The +11,+3 is a kludge to even the padding > > 'of the Form versus the background image, > > 'tested by dragging to the four corners of > > 'the screen and adjusting the numbers to > > 'even the spacing to the edges on all > > 'screen corners. > > ME.Resize(maxW + 11, maxH + 3) > > > > END > > > > > > Thanks. But I don't understand the need of adding 11 and 3. Hardcoded values > like this are rarely a good idea... > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Thu Oct 19 20:34:46 2006 From: gambas at ...1... (Benoit Minisini) Date: Thu, 19 Oct 2006 20:34:46 +0200 Subject: [Gambas-user] Fixed a minor mascot issue In-Reply-To: <20061019104903.W52775@...1337...> References: <20061018170132.M48156@...1337...> <200610191930.14899.gambas@...1...> <20061019104903.W52775@...1337...> Message-ID: <200610192034.46890.gambas@...1...> On Thursday 19 October 2006 19:55, Christopher Brian Jack wrote: > As the code states they are there to even the padding as the images have > some apparent spacing at the left and top sides so the pads are there to > balance it by putting some approximately equivalent padding at the right > and bottom sides by slightly enlarging the form. > > Hardcoding isn't good but one line of source beats manually adding the > space to all the images in the GIMP. > OK. Actually as the window has no border on KDE, and as I can move it freely, I didn't notice the problem. Regards, -- Benoit Minisini From joe1962 at ...626... Thu Oct 19 20:40:30 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Thu, 19 Oct 2006 14:40:30 -0400 Subject: [Gambas-user] Fixed a minor mascot issue In-Reply-To: <200610192034.46890.gambas@...1...> References: <20061018170132.M48156@...1337...> <200610191930.14899.gambas@...1...> <20061019104903.W52775@...1337...> <200610192034.46890.gambas@...1...> Message-ID: <6c208f950610191140j46fea515hf0e42a6bccfb0a58@...627...> On 10/19/06, Benoit Minisini wrote: > On Thursday 19 October 2006 19:55, Christopher Brian Jack wrote: > > As the code states they are there to even the padding as the images have > > some apparent spacing at the left and top sides so the pads are there to > > balance it by putting some approximately equivalent padding at the right > > and bottom sides by slightly enlarging the form. > > > > Hardcoding isn't good but one line of source beats manually adding the > > space to all the images in the GIMP. > > > > OK. Actually as the window has no border on KDE, and as I can move it freely, > I didn't notice the problem. > What WM does the problem show up on? It moves freely in XFCE as well. Regards, Joe1962 From brian at ...1334... Thu Oct 19 23:37:12 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 19 Oct 2006 14:37:12 -0700 (PDT) Subject: [Gambas-user] Fixed a minor mascot issue In-Reply-To: <200610192034.46890.gambas@...1...> References: <20061018170132.M48156@...1337...> <200610191930.14899.gambas@...1...> <20061019104903.W52775@...1337...> <200610192034.46890.gambas@...1...> Message-ID: <20061019143401.H53875@...1337...> On Thu, 19 Oct 2006, Benoit Minisini wrote: > > As the code states they are there to even the padding as the images have > > some apparent spacing at the left and top sides so the pads are there to > > balance it by putting some approximately equivalent padding at the right > > and bottom sides by slightly enlarging the form. > > > > Hardcoding isn't good but one line of source beats manually adding the > > space to all the images in the GIMP. > > > > OK. Actually as the window has no border on KDE, and as I can move it freely, > I didn't notice the problem. I run gambas 1.9.44 on a Suse 10.0 sytem and a Debian system (Testing branch). In Suse the form can be dragged past the screen borders but not on the Debian system (refused to move the mascot form beyond screen boundaries). Both systems run KDE (3.4.2 on the SuSE 10.0 system and KDE 3.5 on the Debian system). .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From joe1962 at ...626... Thu Oct 19 23:41:59 2006 From: joe1962 at ...626... (Jose J. Rodriguez) Date: Thu, 19 Oct 2006 17:41:59 -0400 Subject: [Gambas-user] Fixed a minor mascot issue In-Reply-To: <20061019143401.H53875@...1337...> References: <20061018170132.M48156@...1337...> <200610191930.14899.gambas@...1...> <20061019104903.W52775@...1337...> <200610192034.46890.gambas@...1...> <20061019143401.H53875@...1337...> Message-ID: <6c208f950610191441g5b90badbl183de58d2ae60534@...627...> On 10/19/06, Christopher Brian Jack wrote: > On Thu, 19 Oct 2006, Benoit Minisini wrote: > > > > As the code states they are there to even the padding as the images have > > > some apparent spacing at the left and top sides so the pads are there to > > > balance it by putting some approximately equivalent padding at the right > > > and bottom sides by slightly enlarging the form. > > > > > > Hardcoding isn't good but one line of source beats manually adding the > > > space to all the images in the GIMP. > > > > > > > OK. Actually as the window has no border on KDE, and as I can move it freely, > > I didn't notice the problem. > > I run gambas 1.9.44 on a Suse 10.0 sytem and a Debian system (Testing > branch). In Suse the form can be dragged past the screen borders but not > on the Debian system (refused to move the mascot form beyond screen > boundaries). Both systems run KDE (3.4.2 on the SuSE 10.0 system > and KDE 3.5 on the Debian system). > I haven't tried KDE 3.5.x yet, but IIRC from 3.4.2, this was something that could be configured. I'm not at all sure anymore, since I've been on XFCE 4.4 for a while, so feel free to correct me if I'm wrong. Regards, Joe1962 From brian at ...1334... Thu Oct 19 23:45:16 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 19 Oct 2006 14:45:16 -0700 (PDT) Subject: [Gambas-user] Fixed a minor mascot issue In-Reply-To: <6c208f950610191140j46fea515hf0e42a6bccfb0a58@...627...> References: <20061018170132.M48156@...1337...> <200610191930.14899.gambas@...1...> <20061019104903.W52775@...1337...> <200610192034.46890.gambas@...1...> <6c208f950610191140j46fea515hf0e42a6bccfb0a58@...627...> Message-ID: <20061019143730.U53875@...1337...> On Thu, 19 Oct 2006, Jose J. Rodriguez wrote: > What WM does the problem show up on? It moves freely in XFCE as well. > > Regards, > Joe1962 Far as I can tell running the Testing branch of Debian which uses KDE 3.5 is the only one I know of so far. Another system I use gambas on runs SuSE 10.0 and I can move the mascot (window) off screen. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From rolf.frogs at ...221... Fri Oct 20 19:22:47 2006 From: rolf.frogs at ...221... (rolf) Date: Fri, 20 Oct 2006 19:22:47 +0200 Subject: [Gambas-user] Converting a Blob into a picture Message-ID: <200610201922.47209.rolf.frogs@...221...> Hi Gambas Hackers, I would like to ask everybody, how can a blob result from a database query, which is a string, converted into a picture (i.e. how can I add the converted values to the data area of a picture class)? Is there a function for octal number to integer conversion (the help on "conversion functions" in 1.9.44 does not exists or can't be found)? Many thanks for your help Rolf From gambas at ...1... Fri Oct 20 19:36:57 2006 From: gambas at ...1... (Benoit Minisini) Date: Fri, 20 Oct 2006 19:36:57 +0200 Subject: [Gambas-user] Converting a Blob into a picture In-Reply-To: <200610201922.47209.rolf.frogs@...221...> References: <200610201922.47209.rolf.frogs@...221...> Message-ID: <200610201936.58083.gambas@...1...> On Friday 20 October 2006 19:22, rolf wrote: > Hi Gambas Hackers, > > I would like to ask everybody, how can a blob result from a database query, > which is a string, converted into a picture (i.e. how can I add the > converted values to the data area of a picture class)? You must not store in your blob the picture data, but the picture file. To recover the picture (an Image object actually) from the blob, you must save it to the disk in a temporary file and loads it with Image.Load(). > > Is there a function for octal number to integer conversion (the help > on "conversion functions" in 1.9.44 does not exists or can't be found)? Oops! This is because of a bug in the gambas version installed on the wiki server. When Rob will install a more recent version, it will disappear. > > Many thanks for your help > > Rolf > Regards, -- Benoit Minisini From rohnny at ...1248... Fri Oct 20 20:40:01 2006 From: rohnny at ...1248... (R. Stormo) Date: Fri, 20 Oct 2006 11:40:01 -0700 (PDT) Subject: [Gambas-user] cannot open project after instalation of gambas2(1.9.44) In-Reply-To: <200610071031.00697.gambas@...1...> References: <200610071031.00697.gambas@...1...> Message-ID: <6922757.post@...1379...> gambas-3 wrote: > > On Saturday 07 October 2006 00:21, Hugo wrote: >> Hi everybody, >> After compilation of gambas2 1.9.44 on FedoraCore4 I get this error when >> I >> try to open my project: >> Cannot open project file: >> /path/goes/here/.. >> Null Object >> Project.GetFileIcon.479 >> >> is this a bug ? or am I doing something wrong? >> >> thanks for any advise >> >> Hugo > > Project.GetFileIcon() associates an icon to a project file. > > It seems that it fails sometimes. > > Try this patch and tells me if it fails again or not. > > Regards, > > -- > Benoit Minisini > > ' Gambas module file > > PUBLIC ProjectTree AS ColumnView > PUBLIC ProjectMessage AS Label > PUBLIC Workspace AS Workspace > > PUBLIC ActiveForm AS Object > hForm.Height - 8)))) > > END > > > PUBLIC FUNCTION GetIcon(sPath AS String, OPTIONAL iSize AS Integer) AS > Picture > Got the same problem in Ubuntu Dapper. On what file shall the change take place? Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/cannot-open-project-after-instalation-of-gambas2%281.9.44%29-tf2398375.html#a6922757 Sent from the gambas-user mailing list archive at Nabble.com. From rohnny at ...1248... Sat Oct 21 17:51:45 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 08:51:45 -0700 (PDT) Subject: [Gambas-user] compile from svn Message-ID: <6933717.post@...1379...> How do I compile the code downloaded from svn? Tried with reconf and reconf-all but there are alot of errors and it will not configure after. So There must be something I do wrong! Regards Rohnny My Gambas Community http://gambasforum.tk/ -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6933717 Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Sat Oct 21 17:55:30 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 21 Oct 2006 17:55:30 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <6933717.post@...1379...> References: <6933717.post@...1379...> Message-ID: <200610211755.30138.gambas@...1...> On Saturday 21 October 2006 17:51, R. Stormo wrote: > How do I compile the code downloaded from svn? > > Tried with reconf and reconf-all but there are alot of errors and it will > not configure after. So There must be something I do wrong! > > > Regards Rohnny > My Gambas Community http://gambasforum.tk/ Did you install automake and autoconf ? -- Benoit Minisini From rohnny at ...1248... Sat Oct 21 17:59:53 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 08:59:53 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <200610211755.30138.gambas@...1...> References: <6933717.post@...1379...> <200610211755.30138.gambas@...1...> Message-ID: <6933806.post@...1379...> gambas-3 wrote: > > On Saturday 21 October 2006 17:51, R. Stormo wrote: >> How do I compile the code downloaded from svn? >> >> Tried with reconf and reconf-all but there are alot of errors and it will >> not configure after. So There must be something I do wrong! >> >> >> Regards Rohnny >> My Gambas Community http://gambasforum.tk/ > > Did you install automake and autoconf ? > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > Yes I have both of them in my system (Ubuntu Dapper) ~$ locate autoconf|grep bin /usr/bin/autoconf ~$ locate automake|grep bin /usr/bin/automake-1.4 /usr/bin/automake /usr/bin/automake-1.9 Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6933806 Sent from the gambas-user mailing list archive at Nabble.com. From d.paleino at ...626... Sat Oct 21 18:01:37 2006 From: d.paleino at ...626... (David Paleino) Date: Sat, 21 Oct 2006 18:01:37 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <6933717.post@...1379...> References: <6933717.post@...1379...> Message-ID: <453A4461.7000104@...626...> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 R. Stormo wrote: > How do I compile the code downloaded from svn? > > Tried with reconf and reconf-all but there are alot of errors and it will > not configure after. So There must be something I do wrong! Could you paste the errors they give? > Regards Rohnny Cheers, David - -- Linux Registered User #334216 Get FireFox! >> http://www.spreadfirefox.com/?q=affiliates&id=48183&t=1 Staff >> http://www.debianizzati.org << -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.9.20 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFFOkRh5qqQFxOSsXQRAmNfAJ4sheKurWliqs4SQOdIenig4M54PACfftyf p6MxDvLWY6lhAzjq9xeuRXg= =bg5Q -----END PGP SIGNATURE----- From rohnny at ...1248... Sat Oct 21 18:12:03 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 09:12:03 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <453A4461.7000104@...626...> References: <6933717.post@...1379...> <453A4461.7000104@...626...> Message-ID: <6933912.post@...1379...> David Paleino wrote: > > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > R. Stormo wrote: >> How do I compile the code downloaded from svn? >> >> Tried with reconf and reconf-all but there are alot of errors and it will >> not configure after. So There must be something I do wrong! > > Could you paste the errors they give? > >> Regards Rohnny > > Cheers, > David > > - -- > Linux Registered User #334216 > Get FireFox! >> http://www.spreadfirefox.com/?q=affiliates&id=48183&t=1 > Staff >> http://www.debianizzati.org << > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.9.20 (GNU/Linux) > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org > > iD8DBQFFOkRh5qqQFxOSsXQRAmNfAJ4sheKurWliqs4SQOdIenig4M54PACfftyf > p6MxDvLWY6lhAzjq9xeuRXg= > =bg5Q > -----END PGP SIGNATURE----- > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > Here is part of the log. I stopped it before it was ready. Guess this is enough to find what the problem is --snip ./reconf-all main aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library configure.ac:6: error: possibly undefined macro: AC_PROG_LIBTOOL If this token and others are legitimate, please use m4_pattern_allow. See the Autoconf documentation. autoheader: error: AC_CONFIG_HEADERS not found in configure.ac automake: configure.ac: `PACKAGE' not defined in `configure.ac' automake: configure.ac: `VERSION' not defined in `configure.ac' automake: configure.ac: installing `./mkinstalldirs' Makefile.am:3: AC_PROG_MAKE_SET must be used in `configure.ac' automake: configure.ac: AC_ARG_PROGRAM must be used in `configure.ac' gbx/Makefile.am:4: invalid variable `gblib_LTLIBRARIES' gbx/Makefile.am:70: invalid unused variable name: `gb_la_SOURCES' gbx/Makefile.am:9: invalid unused variable name: `gb_la_LIBADD' gbx/Makefile.am:10: invalid unused variable name: `gb_la_LDFLAGS' lib/Makefile.am:1: AC_PROG_MAKE_SET must be used in `configure.ac' lib/Makefile.am:4: invalid variable `gblib_DATA' lib/Makefile.am:3: invalid variable `dist_gblib_DATA' lib/debug/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' lib/debug/Makefile.am:2: invalid variable `gblib_DATA' lib/debug/Makefile.am:1: invalid variable `dist_gblib_DATA' lib/debug/Makefile.am:11: invalid unused variable name: `gb_debug_la_SOURCES' lib/debug/Makefile.am:9: invalid unused variable name: `gb_debug_la_LDFLAGS' lib/debug/Makefile.am:8: invalid unused variable name: `gb_debug_la_LIBADD' lib/eval/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' lib/eval/Makefile.am:2: invalid variable `gblib_DATA' lib/eval/Makefile.am:1: invalid variable `dist_gblib_DATA' lib/eval/Makefile.am:9: invalid unused variable name: `gb_eval_la_LDFLAGS' lib/eval/Makefile.am:8: invalid unused variable name: `gb_eval_la_LIBADD' lib/eval/Makefile.am:11: invalid unused variable name: `gb_eval_la_SOURCES' lib/db/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' lib/db/Makefile.am:2: invalid variable `gblib_DATA' lib/db/Makefile.am:1: invalid variable `dist_gblib_DATA' lib/db/Makefile.am:11: invalid unused variable name: `gb_db_la_SOURCES' lib/db/Makefile.am:8: invalid unused variable name: `gb_db_la_LIBADD' lib/db/Makefile.am:9: invalid unused variable name: `gb_db_la_LDFLAGS' lib/vb/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' lib/vb/Makefile.am:2: invalid variable `gblib_DATA' lib/vb/Makefile.am:1: invalid variable `dist_gblib_DATA' lib/vb/Makefile.am:11: invalid unused variable name: `gb_vb_la_SOURCES' lib/vb/Makefile.am:9: invalid unused variable name: `gb_vb_la_LDFLAGS' lib/vb/Makefile.am:8: invalid unused variable name: `gb_vb_la_LIBADD' lib/compress/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' lib/compress/Makefile.am:2: invalid variable `gblib_DATA' lib/compress/Makefile.am:1: invalid variable `dist_gblib_DATA' lib/compress/Makefile.am:11: invalid unused variable name: `gb_compress_la_SOURC ES' lib/compress/Makefile.am:8: invalid unused variable name: `gb_compress_la_LIBADD ' lib/compress/Makefile.am:9: invalid unused variable name: `gb_compress_la_LDFLAG S' automake: configure.ac: AC_PROG_INSTALL must be used in `configure.ac' automake: configure.ac: installing `[.]/install-sh'; error while making link: No such file or directory automake: configure.ac: installing `[.]/mkinstalldirs'; error while making link: No such file or directory automake: configure.ac: installing `[.]/missing'; error while making link: No such file or directory configure.ac: 79: required file `[.]/ltmain.sh' not found configure.ac: 79: installing `[.]/config.guess'; error while making link: No such file or directory configure.ac: 79: installing `[.]/config.sub'; error while making link: No such file or directory automake: configure.ac: installing `[.]/config.guess'; error while making link: No such file or directory automake: configure.ac: installing `[.]/config.sub'; error while making link: No such file or directory configure.ac: 54: required file `./config-h.in]' not found app aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library autoheader: error: AC_CONFIG_HEADERS not found in configure.ac automake: configure.ac: `PACKAGE' not defined in `configure.ac' automake: configure.ac: `VERSION' not defined in `configure.ac' automake: configure.ac: installing `./mkinstalldirs' automake: configure.ac: AC_PROG_INSTALL must be used in `configure.ac' comp aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6933912 Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Sat Oct 21 18:18:58 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 21 Oct 2006 18:18:58 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <6933912.post@...1379...> References: <6933717.post@...1379...> <453A4461.7000104@...626...> <6933912.post@...1379...> Message-ID: <200610211818.58823.gambas@...1...> On Saturday 21 October 2006 18:12, R. Stormo wrote: > David Paleino wrote: > > -----BEGIN PGP SIGNED MESSAGE----- > > Hash: SHA1 > > > > R. Stormo wrote: > >> How do I compile the code downloaded from svn? > >> > >> Tried with reconf and reconf-all but there are alot of errors and it > >> will not configure after. So There must be something I do wrong! > > > > Could you paste the errors they give? > > > >> Regards Rohnny > > > > Cheers, > > David > > > > - -- > > Linux Registered User #334216 > > Get FireFox! >> http://www.spreadfirefox.com/?q=affiliates&id=48183&t=1 > > Staff >> http://www.debianizzati.org << > > -----BEGIN PGP SIGNATURE----- > > Version: GnuPG v1.9.20 (GNU/Linux) > > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org > > > > iD8DBQFFOkRh5qqQFxOSsXQRAmNfAJ4sheKurWliqs4SQOdIenig4M54PACfftyf > > p6MxDvLWY6lhAzjq9xeuRXg= > > =bg5Q > > -----END PGP SIGNATURE----- > > > > ------------------------------------------------------------------------- > > Using Tomcat but need to do more? Need to support web services, security? > > Get stuff done quickly with pre-integrated technology to make your job > > easier > > Download IBM WebSphere Application Server v.1.0.1 based on Apache > > Geronimo > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > Here is part of the log. I stopped it before it was ready. Guess this is > enough to find what the problem is > > --snip > > ./reconf-all > main > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > configure.ac:6: error: possibly undefined macro: AC_PROG_LIBTOOL > If this token and others are legitimate, please use m4_pattern_allow. > See the Autoconf documentation. > autoheader: error: AC_CONFIG_HEADERS not found in configure.ac > automake: configure.ac: `PACKAGE' not defined in `configure.ac' > automake: configure.ac: `VERSION' not defined in `configure.ac' > automake: configure.ac: installing `./mkinstalldirs' > Makefile.am:3: AC_PROG_MAKE_SET must be used in `configure.ac' > automake: configure.ac: AC_ARG_PROGRAM must be used in `configure.ac' > gbx/Makefile.am:4: invalid variable `gblib_LTLIBRARIES' > gbx/Makefile.am:70: invalid unused variable name: `gb_la_SOURCES' > gbx/Makefile.am:9: invalid unused variable name: `gb_la_LIBADD' > gbx/Makefile.am:10: invalid unused variable name: `gb_la_LDFLAGS' > lib/Makefile.am:1: AC_PROG_MAKE_SET must be used in `configure.ac' > lib/Makefile.am:4: invalid variable `gblib_DATA' > lib/Makefile.am:3: invalid variable `dist_gblib_DATA' > lib/debug/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' > lib/debug/Makefile.am:2: invalid variable `gblib_DATA' > lib/debug/Makefile.am:1: invalid variable `dist_gblib_DATA' > lib/debug/Makefile.am:11: invalid unused variable name: > `gb_debug_la_SOURCES' > lib/debug/Makefile.am:9: invalid unused variable name: > `gb_debug_la_LDFLAGS' lib/debug/Makefile.am:8: invalid unused variable > name: `gb_debug_la_LIBADD' lib/eval/Makefile.am:6: invalid variable > `gblib_LTLIBRARIES' > lib/eval/Makefile.am:2: invalid variable `gblib_DATA' > lib/eval/Makefile.am:1: invalid variable `dist_gblib_DATA' > lib/eval/Makefile.am:9: invalid unused variable name: `gb_eval_la_LDFLAGS' > lib/eval/Makefile.am:8: invalid unused variable name: `gb_eval_la_LIBADD' > lib/eval/Makefile.am:11: invalid unused variable name: `gb_eval_la_SOURCES' > lib/db/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' > lib/db/Makefile.am:2: invalid variable `gblib_DATA' > lib/db/Makefile.am:1: invalid variable `dist_gblib_DATA' > lib/db/Makefile.am:11: invalid unused variable name: `gb_db_la_SOURCES' > lib/db/Makefile.am:8: invalid unused variable name: `gb_db_la_LIBADD' > lib/db/Makefile.am:9: invalid unused variable name: `gb_db_la_LDFLAGS' > lib/vb/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' > lib/vb/Makefile.am:2: invalid variable `gblib_DATA' > lib/vb/Makefile.am:1: invalid variable `dist_gblib_DATA' > lib/vb/Makefile.am:11: invalid unused variable name: `gb_vb_la_SOURCES' > lib/vb/Makefile.am:9: invalid unused variable name: `gb_vb_la_LDFLAGS' > lib/vb/Makefile.am:8: invalid unused variable name: `gb_vb_la_LIBADD' > lib/compress/Makefile.am:6: invalid variable `gblib_LTLIBRARIES' > lib/compress/Makefile.am:2: invalid variable `gblib_DATA' > lib/compress/Makefile.am:1: invalid variable `dist_gblib_DATA' > lib/compress/Makefile.am:11: invalid unused variable name: > `gb_compress_la_SOURC ES' > lib/compress/Makefile.am:8: invalid unused variable name: > `gb_compress_la_LIBADD ' > lib/compress/Makefile.am:9: invalid unused variable name: > `gb_compress_la_LDFLAG S' > automake: configure.ac: AC_PROG_INSTALL must be used in `configure.ac' > automake: configure.ac: installing `[.]/install-sh'; error while making > link: No such file or directory > > automake: configure.ac: installing `[.]/mkinstalldirs'; error while making > link: No such file or directory > > automake: configure.ac: installing `[.]/missing'; error while making link: > No such file or directory > > configure.ac: 79: required file `[.]/ltmain.sh' not found > configure.ac: 79: installing `[.]/config.guess'; error while making link: > No such file or directory > > configure.ac: 79: installing `[.]/config.sub'; error while making link: No > such file or directory > > automake: configure.ac: installing `[.]/config.guess'; error while making > link: No such file or directory > > automake: configure.ac: installing `[.]/config.sub'; error while making > link: No such file or directory > > configure.ac: 54: required file `./config-h.in]' not found > app > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > autoheader: error: AC_CONFIG_HEADERS not found in configure.ac > automake: configure.ac: `PACKAGE' not defined in `configure.ac' > automake: configure.ac: `VERSION' not defined in `configure.ac' > automake: configure.ac: installing `./mkinstalldirs' > automake: configure.ac: AC_PROG_INSTALL must be used in `configure.ac' > comp > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > > > > Regards Rohnny > My Gambas Community http://gambasforum.tk Did you install libtool too ? -- Benoit Minisini From rohnny at ...1248... Sat Oct 21 18:25:07 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 09:25:07 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <200610211818.58823.gambas@...1...> References: <6933717.post@...1379...> <453A4461.7000104@...626...> <6933912.post@...1379...> <200610211818.58823.gambas@...1...> Message-ID: <6934020.post@...1379...> gambas-3 wrote: > > On Saturday 21 October 2006 18:12, R. Stormo wrote: >> David Paleino wrote: >> > -----BEGIN PGP SIGNED MESSAGE----- >> > Hash: SHA1 >> > >> > R. Stormo wrote: >> >> How do I compile the code downloaded from svn? >> >> >> >> Tried with reconf and reconf-all but there are alot of errors and it >> >> will not configure after. So There must be something I do wrong! >> > >> > Could you paste the errors they give? >> > >> >> Regards Rohnny >> > >> > Cheers, >> > David >> > >> > - -- >> > Linux Registered User #334216 >> > Get FireFox! >> http://www.spreadfirefox.com/?q=affiliates&id=48183&t=1 >> > Staff >> http://www.debianizzati.org << >> > -----BEGIN PGP SIGNATURE----- >> > Version: GnuPG v1.9.20 (GNU/Linux) >> > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org >> > >> > iD8DBQFFOkRh5qqQFxOSsXQRAmNfAJ4sheKurWliqs4SQOdIenig4M54PACfftyf >> > p6MxDvLWY6lhAzjq9xeuRXg= >> > =bg5Q >> > -----END PGP SIGNATURE----- >> > >> > >> ------------------------------------------------------------------------- >> > Using Tomcat but need to do more? Need to support web services, >> security? >> > Get stuff done quickly with pre-integrated technology to make your job >> > easier >> > Download IBM WebSphere Application Server v.1.0.1 based on Apache >> > Geronimo >> > >> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >> > _______________________________________________ >> > Gambas-user mailing list >> > Gambas-user at lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> Here is part of the log. I stopped it before it was ready. Guess this is >> enough to find what the problem is >> >> --snip >> >> ./reconf-all >> main >> aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library >> configure.ac:6: error: possibly undefined macro: AC_PROG_LIBTOOL >> If this token and others are legitimate, please use >> m4_pattern_allow. >> See the Autoconf documentation. >> autoheader: error: AC_CONFIG_HEADERS not found in configure.ac >> automake: configure.ac: `PACKAGE' not defined in `configure.ac' >> automake: configure.ac: `VERSION' not defined in `configure.ac' >> automake: configure.ac: installing `./mkinstalldirs' >> Makefile.am:3: AC_PROG_MAKE_SET must be used in `configure.ac' >> automake: configure.ac: AC_ARG_PROGRAM must be used in `configure.ac' >> gbx/Makefile.am:4: invalid variable `gblib_LTLIBRARIES' >> gbx/Makefile.am:70: invalid unused variable name: `gb_la_SOURCES' >> gbx/Makefile.am:9: invalid unused variable name: `gb_la_LIBADD' >> gbx/Makefile.am:10: invalid unused variable name: `gb_la_LDFLAGS' > > >> aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library >> aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library >> >> >> >> Regards Rohnny >> My Gambas Community http://gambasforum.tk > > Did you install libtool too ? > > -- > Benoit Minisini > > > > Yes this is also installed. --snip locate libtool|grep bin /usr/bin/libtool /usr/bin/libtoolize --snap Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6934020 Sent from the gambas-user mailing list archive at Nabble.com. From ronstk at ...239... Sat Oct 21 19:33:57 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sat, 21 Oct 2006 19:33:57 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <6933717.post@...1379...> References: <6933717.post@...1379...> Message-ID: <200610211933.58054.ronstk@...239...> On Saturday 21 October 2006 17:51, R. Stormo wrote: > > How do I compile the code downloaded from svn? > > Tried with reconf and reconf-all but there are alot of errors and it will > not configure after. So There must be something I do wrong! > > > Regards Rohnny > My Gambas Community http://gambasforum.tk/ ron at ...1311...:~/src/svn/trunk/main> link ../config.sub config.sub.ron ron at ...1311...:~/src/svn/trunk/main> l config.su* -rw-r--r-- ?1 ron users ? ?18 2006-09-27 17:26 config.sub -rwxr-xr-x ?2 ron users 31552 2006-09-27 17:26 config.sub.ron* ron at ...1311...:~/src/svn/trunk/main> ? ? check the size of /trunk/main/config.sub check the program 'link' see my mail at 2006-09-27 17:59 ron at ...1311...:~/src/svn/trunk/main> link --help Usage: link FILE1 FILE2 ? or: ?link OPTION Call the link function to create a link named FILE2 to an existing FILE1. ? ? ? --help ? ? display this help and exit ? ? ? --version ?output version information and exit Report bugs to . On SuSE it wants 'both' parameters ? YES IT DOES NEED THEM BOTH!! When I look in trunk/main/config.sub I see: ? link ../config.sub This is _one_ (1) parameter and the symlink is not made. Resulting in missing declarations during configure and compile. Ron From gambas.fr at ...626... Sat Oct 21 19:41:17 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 21 Oct 2006 19:41:17 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <200610211933.58054.ronstk@...239...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> Message-ID: <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> and this is the final soluce : uninstall automake1.4 and 1.9 and then install the automake1.7 in fact the problem come from gambas that have script file only compatible with this automake version. I've the same problem on Ubuntu dapper/edgy and on many distrib too Regards, Fabien Bodard From drmad at ...1302... Sat Oct 21 19:43:46 2006 From: drmad at ...1302... (Oliver Etchebarne Bejarano) Date: Sat, 21 Oct 2006 12:43:46 -0500 Subject: [Gambas-user] ERROR: #27: Cannot load component 'gb.db': cannot find library file Message-ID: <453A5C52.2090000@...1302...> Hi, I don't remember in which version it begun to appear that error (I was upgrading, thinking the problem was in something in the old version), but that appears when I try to run the IDE. I have a LFS, and I compile gambas with ./configure --prefix=/opt/gambas2/ --with-moc=/opt/qt-x11-free-3.3.6/bin/ --with-qt-libraries=/opt/qt-x11-free-3.3.6/lib/ --with-qt-headers=/opt/qt-x11-free-3.3.6/include/ --with-sdl-libraries=/opt/SDL/lib/ --with-sdl-includes=/opt/SDL/include/ ...as you can see, everything is inside /opt . The gb.db.so.* exists in [drmad at ...1596... bin]$ l /opt/gambas2/lib/gb.db.so* -rwxr-xr-x 1 root root 200809 2006-10-21 12:16 /opt/gambas2/lib/gb.db.so* -rwxr-xr-x 1 root root 200809 2006-10-21 12:16 /opt/gambas2/lib/gb.db.so.0* -rwxr-xr-x 1 root root 200809 2006-10-21 12:16 /opt/gambas2/lib/gb.db.so.0.0.0* and they have a soft symlink in /usr/local/ (e.g /usr/local/lib/gb.db.so*) Is there anything I am doing wrong?? Saludos, -- Oliver Etchebarne Bejarano drmad/paperclip www.paperclip.com.pe From d.paleino at ...626... Sat Oct 21 19:45:02 2006 From: d.paleino at ...626... (David Paleino) Date: Sat, 21 Oct 2006 19:45:02 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> Message-ID: <453A5C9E.2090907@...626...> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Fabien Bodard wrote: > and this is the final soluce : > > uninstall automake1.4 and 1.9 > > and then install the automake1.7 > > in fact the problem come from gambas that have script file only compatible > with this automake version. > > I've the same problem on Ubuntu dapper/edgy and on many distrib too # man update-alternatives You don't need to uninstall anything on any Debian-based system. I don't really know if update-alternatives is Debian-specific though. Alternatively, you can manually change the symbolic link: neo at ...1597...:~$ ls -l `which automake` lrwxrwxrwx 1 root root 26 2 feb 2006 /usr/bin/automake -> /etc/alternatives/automake neo at ...1597...:~$ ls -l /etc/alternatives/automake lrwxrwxrwx 1 root root 21 1 ott 23:39 /etc/alternatives/automake -> /usr/bin/automake-1.9 neo at ...1597...:~$ (again, don't know if on other systems /etc/alternatives is there, I think that /usr/bin/automake directly links to /usr/bin/automake-*.*.) > Regards, > Fabien Bodard Cheers, David - -- Linux Registered User #334216 Get FireFox! >> http://www.spreadfirefox.com/?q=affiliates&id=48183&t=1 Staff >> http://www.debianizzati.org << -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.9.20 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFFOlye5qqQFxOSsXQRAurqAKDE2ZzKz22wA6dZa61qjpxNJ1GFpQCcDBe8 j5V0YhnVNS1RiqBg3Rnwg3k= =t5AS -----END PGP SIGNATURE----- From gambas.fr at ...626... Sat Oct 21 19:49:38 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 21 Oct 2006 19:49:38 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <453A5C9E.2090907@...626...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> <453A5C9E.2090907@...626...> Message-ID: <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> i was say uninstall as it is more easy with a graphical package manager... From rohnny at ...1248... Sat Oct 21 21:11:17 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 12:11:17 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> <453A5C9E.2090907@...626...> <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> Message-ID: <6935447.post@...1379...> I know shall have done everything and still alot of errors. rohnny at ...1008...:~/gambas/1.9.44/main$ link ../config.sub config.sub.ron rohnny at ...1008...:~/gambas/1.9.44/main$ ls -l config.su* lrwxrwxrwx 1 rohnny rohnny 13 2006-10-21 18:07 config.sub -> ../config.sub -rwxr-xr-x 2 rohnny rohnny 31552 2006-10-21 18:07 config.sub.ron rohnny at ...1008...:~/gambas/1.9.44/main$ ls -l `which automake` lrwxrwxrwx 1 root root 26 2005-12-12 20:58 /usr/bin/automake -> /etc/alternatives/automake rohnny at ...1008...:~/gambas/1.9.44/main$ ls -l /etc/alternatives/automake lrwxrwxrwx 1 root root 21 2006-10-21 21:05 /etc/alternatives/automake -> /usr/bin/automake-1.7 rohnny at ...1008...:~/gambas/1.9.44/main$ tried again reconf with this output rohnny at ...1008...:~/gambas/1.9.44$ ./reconf-all main aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library configure.ac:6: error: possibly undefined macro: AC_PROG_LIBTOOL If this token and others are legitimate, please use m4_pattern_allow. See the Autoconf documentation. autoheader: error: AC_CONFIG_HEADERS not found in configure.ac configure.ac: no proper invocation of AM_INIT_AUTOMAKE was found. configure.ac: You should verify that configure.ac invokes AM_INIT_AUTOMAKE, configure.ac: that aclocal.m4 is present in the top-level directory, configure.ac: and that aclocal.m4 was recently regenerated (using aclocal). /usr/share/automake-1.7/am/depend2.am: am__fastdepCC does not appear in AM_CONDITIONAL /usr/share/automake-1.7/am/depend2.am: AMDEP does not appear in AM_CONDITIONAL gbc/Makefile.am: C source seen but `CC' is undefined gbc/Makefile.am: gbc/Makefile.am: The usual way to define `CC' is to add `AC_PROG_CC' gbc/Makefile.am: to `configure.ac' and run `autoconf' again. gbx/Makefile.am:4: `gblib_LTLIBRARIES' is used but `gblibdir' is undefined /usr/share/automake-1.7/am/depend2.am: am__fastdepCC does not appear in AM_CONDITIONAL /usr/share/automake-1.7/am/depend2.am: AMDEP does not appear in AM_CONDITIONAL gbx/Makefile.am: C source seen but `CC' is undefined gbx/Makefile.am: gbx/Makefile.am: The usual way to define `CC' is to add `AC_PROG_CC' gbx/Makefile.am: to `configure.ac' and run `autoconf' again. gbx/Makefile.am:9: unused variable: `gb_la_LIBADD' gbx/Makefile.am:10: unused variable: `gb_la_LDFLAGS' gbx/Makefile.am:86: unused variable: `gb_la_SOURCES' lib/Makefile.am:4: `gblib_DATA' is used but `gblibdir' is undefined lib/Makefile.am:3: `dist_gblib_DATA' is used but `gblibdir' is undefined lib/compress/Makefile.am:6: `gblib_LTLIBRARIES' is used but `gblibdir' is undefined component.am:2: `gblib_DATA' is used but `gblibdir' is undefined component.am:1: `dist_gblib_DATA' is used but `gblibdir' is undefined lib/compress/Makefile.am:11: unused variable: `gb_compress_la_SOURCES' lib/compress/Makefile.am:8: unused variable: `gb_compress_la_LIBADD' lib/compress/Makefile.am:9: unused variable: `gb_compress_la_LDFLAGS' lib/db/Makefile.am:6: `gblib_LTLIBRARIES' is used but `gblibdir' is undefined lib/db/Makefile.am:22: unused variable: `gb_db_la_SOURCES' lib/db/Makefile.am:8: unused variable: `gb_db_la_LIBADD' lib/db/Makefile.am:9: unused variable: `gb_db_la_LDFLAGS' lib/debug/Makefile.am:6: `gblib_LTLIBRARIES' is used but `gblibdir' is undefinedlib/debug/Makefile.am:9: unused variable: `gb_debug_la_LDFLAGS' lib/debug/Makefile.am:16: unused variable: `gb_debug_la_SOURCES' lib/debug/Makefile.am:8: unused variable: `gb_debug_la_LIBADD' lib/eval/Makefile.am:6: `gblib_LTLIBRARIES' is used but `gblibdir' is undefined lib/eval/Makefile.am:8: unused variable: `gb_eval_la_LIBADD' lib/eval/Makefile.am:27: unused variable: `gb_eval_la_SOURCES' lib/eval/Makefile.am:9: unused variable: `gb_eval_la_LDFLAGS' lib/vb/Makefile.am:6: `gblib_LTLIBRARIES' is used but `gblibdir' is undefined lib/vb/Makefile.am:8: unused variable: `gb_vb_la_LIBADD' lib/vb/Makefile.am:11: unused variable: `gb_vb_la_SOURCES' lib/vb/Makefile.am:9: unused variable: `gb_vb_la_LDFLAGS Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6935447 Sent from the gambas-user mailing list archive at Nabble.com. From Karl.Reinl at ...9... Sat Oct 21 22:46:42 2006 From: Karl.Reinl at ...9... (Charlie Reinl) Date: Sat, 21 Oct 2006 22:46:42 +0200 Subject: [Gambas-user] to : compile from svn Message-ID: <200610212246.42883.Karl.Reinl@...9...> Salut, sorry send this from my box where I can't get mails, but write. Send you my scripts which works for me, on my gentoo BOX. svn-CheckOut and svn-Update are placed at /opt/gambas2 svnMake inside /opt/gambas2/gambas2-svn may be that helps Amicalment Charlie -------------- next part -------------- A non-text attachment was scrubbed... Name: svn-CheckOut Type: application/x-shellscript Size: 248 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: svnMake Type: application/x-shellscript Size: 752 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: svn-Update Type: application/x-shellscript Size: 118 bytes Desc: not available URL: From gambas.fr at ...626... Sat Oct 21 23:19:11 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 21 Oct 2006 23:19:11 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <6935447.post@...1379...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> <453A5C9E.2090907@...626...> <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> <6935447.post@...1379...> Message-ID: <6324a42a0610211419o26bd5eabj18bce04a5895639a@...627...> C source seen but `CC' is undefined is gcc and g++ installed ? From ronstk at ...239... Sat Oct 21 23:33:36 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sat, 21 Oct 2006 23:33:36 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <6935447.post@...1379...> References: <6933717.post@...1379...> <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> <6935447.post@...1379...> Message-ID: <200610212333.36485.ronstk@...239...> On Saturday 21 October 2006 21:11, R. Stormo wrote: > I know shall have done everything and still alot of errors. > > rohnny at ...1008...:~/gambas/1.9.44/main$ link ../config.sub config.sub.ron > rohnny at ...1008...:~/gambas/1.9.44/main$ ls -l config.su* > lrwxrwxrwx 1 rohnny rohnny ? ?13 2006-10-21 18:07 config.sub -> ../config.sub > -rwxr-xr-x 2 rohnny rohnny 31552 2006-10-21 18:07 config.sub.ron > This shows to me your 'link' executable does not work as gambas likes. The config.sub is with the svn system a textfile. In the standard tarbal it is a shortcut. And that is the problem. I did replace the line in a few of those pseudo link files with: (rm ./config.sub; link ../config.sub config.sub) (rm FILE1; link FILE1 FILE2) (command1; command2) The working is that the whole line is passed to bash as one string by the '(' and ')' You are able to safe remove the source of the line in FILE1 remove the file 'config.sub' as done for command1 make the link for FILE1 as FILE2 as done with command2 I suggest to rename the current '/usr/bin/link' to '/usr/bin/link.bin' make a bash script with name 'link' and make it executable and owner root. -- code for file -- #!/bin/bash rm $0; link.bin $1 $0 --end code -- if you get a error try next -- code for file -- #!/bin/bash ( rm $0; link.bin $1 $0) <--- take care the parenthesis --end code -- An other way is to traverse the whole svn tree and test for file less then 80 char or so. test for lines starting with 'link' and if then edit/replace the line. Or Benoit edit his code in those files using the reliable syntax as 'link FILE1 FILE2' as the wiki and man pages tell. I reported this in the past but got no comment from Benoit on/about it. I give up and started to do some other work. Ron From rohnny at ...1248... Sat Oct 21 23:36:15 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 14:36:15 -0700 (PDT) Subject: [Gambas-user] to : compile from svn In-Reply-To: <200610212246.42883.Karl.Reinl@...9...> References: <200610212246.42883.Karl.Reinl@...9...> Message-ID: <6936602.post@...1379...> Charlie Reinl wrote: > > Salut, > > sorry send this from my box where I can't get mails, but write. > > Send you my scripts which works for me, on my gentoo BOX. > > svn-CheckOut and svn-Update are placed at /opt/gambas2 > svnMake inside /opt/gambas2/gambas2-svn > > may be that helps > > Amicalment > Charlie > > > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > Thank you for it but it did not work either. The problem I have is that reconf-all is giving me alot of errors. --snip aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library configure.ac:10: error: possibly undefined macro: AC_PROG_LIBTOOL If this token and others are legitimate, please use m4_pattern_allow. See the Autoconf documentation. autoheader: error: AC_CONFIG_HEADERS not found in configure.ac configure.ac: no proper invocation of AM_INIT_AUTOMAKE was found. configure.ac: You should verify that configure.ac invokes AM_INIT_AUTOMAKE, configure.ac: that aclocal.m4 is present in the top-level directory, configure.ac: and that aclocal.m4 was recently regenerated (using aclocal). configure.ac: installing `./mkinstalldirs' src/Makefile.am:3: `gblib_LTLIBRARIES' is used but `gblibdir' is undefined src/Makefile.am:6: unused variable: `gb_db_sqlite2_la_LDFLAGS' src/Makefile.am:10: unused variable: `gb_db_sqlite2_la_SOURCES' src/Makefile.am:5: unused variable: `gb_db_sqlite2_la_LIBADD' gb.db.sqlite3 acloc --snap If I try to configure after reconf is ready I get this error ./configure configure: creating cache config.cache ./configure: line 1259: syntax error near unexpected token `bzlib2,' ./configure: line 1259: `GB_CONFIG_SUBDIRS(bzlib2, gb.compress.bzlib2)' Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/to-%3A-compile-from-svn-tf2487658.html#a6936602 Sent from the gambas-user mailing list archive at Nabble.com. From rohnny at ...1248... Sat Oct 21 23:40:19 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 14:40:19 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <6324a42a0610211419o26bd5eabj18bce04a5895639a@...627...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> <453A5C9E.2090907@...626...> <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> <6935447.post@...1379...> <6324a42a0610211419o26bd5eabj18bce04a5895639a@...627...> Message-ID: <6936627.post@...1379...> Fabien Bodard-4 wrote: > > C source seen but `CC' is undefined > is gcc and g++ installed ? > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > Yes I have those installed, gambas2 from download are compiled as it should so no problem there. Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6936627 Sent from the gambas-user mailing list archive at Nabble.com. From rohnny at ...1248... Sat Oct 21 23:53:00 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 14:53:00 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <200610212333.36485.ronstk@...239...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> <453A5C9E.2090907@...626...> <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> <6935447.post@...1379...> <200610212333.36485.ronstk@...239...> Message-ID: <6936721.post@...1379...> Ron Onstenk wrote: > > On Saturday 21 October 2006 21:11, R. Stormo wrote: >> I know shall have done everything and still alot of errors. >> >> rohnny at ...1008...:~/gambas/1.9.44/main$ link ../config.sub config.sub.ron >> rohnny at ...1008...:~/gambas/1.9.44/main$ ls -l config.su* >> lrwxrwxrwx 1 rohnny rohnny 13 2006-10-21 18:07 config.sub -> >> ../config.sub >> -rwxr-xr-x 2 rohnny rohnny 31552 2006-10-21 18:07 config.sub.ron >> > > > This shows to me your 'link' executable does not work as gambas likes. > The config.sub is with the svn system a textfile. > In the standard tarbal it is a shortcut. > And that is the problem. > > > > I did replace the line in a few of those pseudo link files with: > > (rm ./config.sub; link ../config.sub config.sub) > > (rm FILE1; link FILE1 FILE2) > > (command1; command2) > The working is that the whole line is passed to bash as one string by the > '(' and ')' > You are able to safe remove the source of the line in FILE1 > > remove the file 'config.sub' as done for command1 > make the link for FILE1 as FILE2 as done with command2 > > I suggest to rename the current '/usr/bin/link' to '/usr/bin/link.bin' > make a bash script with name 'link' and make it executable and owner root. > > > -- code for file -- > #!/bin/bash > rm $0; > link.bin $1 $0 > > --end code -- > > if you get a error try next > > -- code for file -- > #!/bin/bash > ( rm $0; link.bin $1 $0) <--- take care the parenthesis > > --end code -- > > An other way is to traverse the whole svn tree and test for file less then > 80 char or so. > test for lines starting with 'link' and if then edit/replace the line. > > Or Benoit edit his code in those files using the reliable syntax > as 'link FILE1 FILE2' as the wiki and man pages tell. > > > I reported this in the past but got no comment from Benoit on/about it. > I give up and started to do some other work. > > > > > Ron > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > I tried to rename the /usr/bin/link to link.bin then I made a new file called link But when I try to write link I get this rohnny at ...1008...:/usr/bin$ link hello hello1 rm: remove write-protected regular file `/usr/bin/link'? So there must be an error someplace, because it try to remove it self. so I changed $0 to $1 and $1 to $2 and tried again. Both of your files gave me an error rohnny at ...1008...:~$ link sok.txt test rm: cannot remove `sok.txt': No such file or directory link.bin: cannot create link `sok.txt' to `test': No such file or directory rohnny at ...1008...:~$ link test sok.txt rm: cannot remove `test': No such file or directory link.bin: cannot create link `test' to `sok.txt': No such file or directory Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6936721 Sent from the gambas-user mailing list archive at Nabble.com. From ronstk at ...239... Sat Oct 21 23:53:52 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sat, 21 Oct 2006 23:53:52 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <200610212333.36485.ronstk@...239...> References: <6933717.post@...1379...> <6935447.post@...1379...> <200610212333.36485.ronstk@...239...> Message-ID: <200610212353.52594.ronstk@...239...> files involved with the problem are: acinclude.m4 component.am configure.ac config.guess config.sub ltmain.sh depcomp reconf install-sh missing From ronstk at ...239... Sun Oct 22 00:00:49 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sun, 22 Oct 2006 00:00:49 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <6936602.post@...1379...> References: <200610212246.42883.Karl.Reinl@...9...> <6936602.post@...1379...> Message-ID: <200610220000.49398.ronstk@...239...> On Saturday 21 October 2006 23:36, R. Stormo wrote: > If I try to configure after reconf is ready I get this error > ./configure > > configure: creating cache config.cache > ./configure: line 1259: syntax error near unexpected token `bzlib2,' > ./configure: line 1259: `GB_CONFIG_SUBDIRS(bzlib2, gb.compress.bzlib2)' > It is required to use ./configure -C at least as I found with SuSE. I do use ./configure -C --prefix=/opt/gb ATM. Ron P.S. check those files are symlinks in the svn tree and not plain text files. i.e. config.sub and ltmain.sh in the tree (main, gb.*.*) should be symlinks except in the root of the tree (trunk directory) From gambas at ...1... Sun Oct 22 00:39:03 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 00:39:03 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <6936602.post@...1379...> References: <200610212246.42883.Karl.Reinl@...9...> <6936602.post@...1379...> Message-ID: <200610220039.03485.gambas@...1...> On Saturday 21 October 2006 23:36, R. Stormo wrote: > Charlie Reinl wrote: > > Salut, > > > > sorry send this from my box where I can't get mails, but write. > > > > Send you my scripts which works for me, on my gentoo BOX. > > > > svn-CheckOut and svn-Update are placed at /opt/gambas2 > > svnMake inside /opt/gambas2/gambas2-svn > > > > may be that helps > > > > Amicalment > > Charlie > > > > > > > > > > ------------------------------------------------------------------------- > > Using Tomcat but need to do more? Need to support web services, security? > > Get stuff done quickly with pre-integrated technology to make your job > > easier > > Download IBM WebSphere Application Server v.1.0.1 based on Apache > > Geronimo > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > Thank you for it but it did not work either. > > The problem I have is that reconf-all is giving me alot of errors. > > --snip > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CFLAGS' not found in library > aclocal: configure.ac: 0: macro `AM_CXXFLAGS' not found in library > configure.ac:10: error: possibly undefined macro: AC_PROG_LIBTOOL > If this token and others are legitimate, please use m4_pattern_allow. > See the Autoconf documentation. > autoheader: error: AC_CONFIG_HEADERS not found in configure.ac > configure.ac: no proper invocation of AM_INIT_AUTOMAKE was found. > configure.ac: You should verify that configure.ac invokes AM_INIT_AUTOMAKE, > configure.ac: that aclocal.m4 is present in the top-level directory, > configure.ac: and that aclocal.m4 was recently regenerated (using aclocal). > configure.ac: installing `./mkinstalldirs' > src/Makefile.am:3: `gblib_LTLIBRARIES' is used but `gblibdir' is undefined > src/Makefile.am:6: unused variable: `gb_db_sqlite2_la_LDFLAGS' > src/Makefile.am:10: unused variable: `gb_db_sqlite2_la_SOURCES' > src/Makefile.am:5: unused variable: `gb_db_sqlite2_la_LIBADD' > gb.db.sqlite3 > acloc > --snap > > > If I try to configure after reconf is ready I get this error > ./configure > > configure: creating cache config.cache > ./configure: line 1259: syntax error near unexpected token `bzlib2,' > ./configure: line 1259: `GB_CONFIG_SUBDIRS(bzlib2, gb.compress.bzlib2)' > > > > Regards Rohnny > > My Gambas Community http://gambasforum.tk I try to understand where the problem comes from, but I don't see at the moment. I generate the tar.gz source package by doing the same thing as Rohnny. I do a checkout, I compile everything, and I use 'make dist' (with a tweak so that symlinks are preserved). Here is the versions installed on my Mandriva 2007: * aclocal 1.9.6 * autoconf 2.59 * autoheader 2.59 * automake 1.9.6 aclocal generates the aclocal.m4 file that contains all m4 macros needed for making the configure script from configure.ac. To do that, it analyzes the configure.ac file to put only the needed macros, and not all ones. With a few google search, it seems that you must install automale 1.9.x. As you have automake 1.4 and automake 1.9 installed on your system, I suggest that you check that you use the 1.9 version when running ./reconf. Just type automake --version to see that. I think you use the 1.4 by default, and so you get these errors. Regards, -- Benoit Minisini From gambas at ...1... Sun Oct 22 00:41:20 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 00:41:20 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <200610212333.36485.ronstk@...239...> References: <6933717.post@...1379...> <6935447.post@...1379...> <200610212333.36485.ronstk@...239...> Message-ID: <200610220041.21082.gambas@...1...> On Saturday 21 October 2006 23:33, Ron Onstenk wrote: > On Saturday 21 October 2006 21:11, R. Stormo wrote: > > I know shall have done everything and still alot of errors. > > > > rohnny at ...1008...:~/gambas/1.9.44/main$ link ../config.sub config.sub.ron > > rohnny at ...1008...:~/gambas/1.9.44/main$ ls -l config.su* > > lrwxrwxrwx 1 rohnny rohnny ? ?13 2006-10-21 18:07 config.sub -> > > ../config.sub -rwxr-xr-x 2 rohnny rohnny 31552 2006-10-21 18:07 > > config.sub.ron > > This shows to me your 'link' executable does not work as gambas likes. > The config.sub is with the svn system a textfile. > In the standard tarbal it is a shortcut. > And that is the problem. > > > > I did replace the line in a few of those pseudo link files with: > > (rm ./config.sub; link ../config.sub config.sub) > > (rm FILE1; link FILE1 FILE2) > > (command1; command2) > The working is that the whole line is passed to bash as one string by the > '(' and ')' You are able to safe remove the source of the line in FILE1 > > remove the file 'config.sub' as done for command1 > make the link for FILE1 as FILE2 as done with command2 > > I suggest to rename the current '/usr/bin/link' to '/usr/bin/link.bin' > make a bash script with name 'link' and make it executable and owner root. > > > -- code for file -- > #!/bin/bash > rm $0; > link.bin $1 $0 > > --end code -- > > if you get a error try next > > -- code for file -- > #!/bin/bash > ( rm $0; link.bin $1 $0) <--- take care the parenthesis > > --end code -- > > An other way is to traverse the whole svn tree and test for file less then > 80 char or so. test for lines starting with 'link' and if then edit/replace > the line. > > Or Benoit edit his code in those files using the reliable syntax > as 'link FILE1 FILE2' as the wiki and man pages tell. > > > I reported this in the past but got no comment from Benoit on/about it. > I give up and started to do some other work. > > > > > Ron > I must not touch these files, they are generated by autoconf,automake & friends. I think the error comes from not using the "correct" version of these tools. Regards, -- Benoit Minisini From rohnny at ...1248... Sun Oct 22 01:13:24 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 16:13:24 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <200610212353.52594.ronstk@...239...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> <453A5C9E.2090907@...626...> <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> <6935447.post@...1379...> <200610212333.36485.ronstk@...239...> <200610212353.52594.ronstk@...239...> Message-ID: <6937356.post@...1379...> Ron Onstenk wrote: > > > files involved with the problem are: > > acinclude.m4 > component.am > configure.ac > config.guess > config.sub > > ltmain.sh > > depcomp > reconf > install-sh > missing > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > I did remove automake and installed it again, this way I was missing aclocal I put the alternative to automake1.9 sudo update-alternatives --config automake and made a link aclocal to aclocal1.9 then I got these errors (did not find aclocal-1.7) --snip gb.sdl /usr/share/aclocal/tulip.m4:2: warning: underquoted definition of AC_PATH_TULIP run info '(automake)Extending aclocal' or see http://sources.redhat.com/automake/automake.html#Extending-aclocal /usr/share/aclocal/tcl.m4:20: warning: underquoted definition of SC_PATH_TCLCONFIG /usr/share/aclocal/tcl.m4:124: warning: underquoted definition of SC_PATH_TKCONFIG /usr/share/aclocal/tcl.m4:228: warning: underquoted definition of SC_LOAD_TCLCONFIG /usr/share/aclocal/tcl.m4:295: warning: underquoted definition of SC_LOAD_TKCONFIG /usr/share/aclocal/tcl.m4:332: warning: underquoted definition of SC_PROG_TCLSH /usr/share/aclocal/tcl.m4:378: warning: underquoted definition of SC_BUILD_TCLSH /usr/share/aclocal/tcl.m4:406: warning: underquoted definition of SC_ENABLE_SHARED /usr/share/aclocal/tcl.m4:446: warning: underquoted definition of SC_ENABLE_FRAMEWORK /usr/share/aclocal/tcl.m4:501: warning: underquoted definition of SC_ENABLE_THREADS /usr/share/aclocal/tcl.m4:600: warning: underquoted definition of SC_ENABLE_SYMBOLS /usr/share/aclocal/tcl.m4:657: warning: underquoted definition of SC_ENABLE_LANGINFO /usr/share/aclocal/tcl.m4:708: warning: underquoted definition of SC_CONFIG_MANPAGES /usr/share/aclocal/tcl.m4:840: warning: underquoted definition of SC_CONFIG_CFLAGS /usr/share/aclocal/tcl.m4:2035: warning: underquoted definition of SC_SERIAL_PORT /usr/share/aclocal/tcl.m4:2164: warning: underquoted definition of SC_MISSING_POSIX_HEADERS /usr/share/aclocal/tcl.m4:2244: warning: underquoted definition of SC_PATH_X /usr/share/aclocal/tcl.m4:2330: warning: underquoted definition of SC_BLOCKING_STYLE /usr/share/aclocal/tcl.m4:2395: warning: underquoted definition of SC_TIME_HANDLER /usr/share/aclocal/tcl.m4:2472: warning: underquoted definition of SC_BUGGY_STRTOD /usr/share/aclocal/tcl.m4:2534: warning: underquoted definition of SC_TCL_LINK_LIBS /usr/share/aclocal/tcl.m4:2611: warning: underquoted definition of SC_TCL_EARLY_FLAG /usr/share/aclocal/tcl.m4:2623: warning: underquoted definition of SC_TCL_EARLY_FLAGS /usr/share/aclocal/tcl.m4:2657: warning: underquoted definition of SC_TCL_64BIT_FLAGS /usr/share/aclocal/smpeg.m4:13: warning: underquoted definition of AM_PATH_SMPEG /usr/share/aclocal/oaf.m4:4: warning: underquoted definition of AM_PATH_OAF /usr/share/aclocal/lirc.m4:15: warning: underquoted definition of AC_PATH_LIRC /usr/share/aclocal/libglade.m4:7: warning: underquoted definition of AM_PATH_LIBGLADE /usr/share/aclocal/libart.m4:11: warning: underquoted definition of AM_PATH_LIBART /usr/share/aclocal/gtkgl.m4:4: warning: underquoted definition of AM_PATH_GTKGL /usr/share/aclocal/gtkextra.m4:8: warning: underquoted definition of AM_PATH_GTK_EXTRA /usr/share/aclocal/gtkextra--.m4:11: warning: underquoted definition of AM_PATH_GTKEXTRAMM /usr/share/aclocal/gtk--.m4:10: warning: underquoted definition of AM_PATH_GTKMM /usr/share/aclocal/glib.m4:8: warning: underquoted definition of AM_PATH_GLIB /usr/share/aclocal/gconf-1.m4:4: warning: underquoted definition of AM_PATH_GCONF /usr/share/aclocal/gconf-1.m4:71: warning: underquoted definition of AM_GCONF_SOURCE configure.ac:10: warning: AC_ARG_PROGRAM was called before AC_CANONICAL_TARGET autoconf/general.m4:1657: AC_CANONICAL_TARGET is expanded from... configure.ac:10: AC_CANONICAL_TARGET is required by... /usr/share/aclocal/sdl.m4:180: AM_PATH_SDL is expanded from... configure.ac:10: the top level configure.ac:10: warning: AC_ARG_PROGRAM was called before AC_CANONICAL_TARGET autoconf/general.m4:1657: AC_CANONICAL_TARGET is expanded from... configure.ac:10: AC_CANONICAL_TARGET is required by... aclocal.m4:193: AM_PATH_SDL is expanded from... configure.ac:10: the top level configure.ac:10: warning: AC_ARG_PROGRAM was called before AC_CANONICAL_TARGET autoconf/general.m4:1657: AC_CANONICAL_TARGET is expanded from... configure.ac:10: AC_CANONICAL_TARGET is required by... aclocal.m4:193: AM_PATH_SDL is expanded from... configure.ac:10: the top level configure.ac:10: warning: AC_ARG_PROGRAM was called before AC_CANONICAL_TARGET autoconf/general.m4:1657: AC_CANONICAL_TARGET is expanded from... configure.ac:10: AC_CANONICAL_TARGET is required by... aclocal.m4:193: AM_PATH_SDL is expanded from... configure.ac:10: the top level gb.sdl.sound --snap Configure went well :D , waiting for make to finish. Get back tomorrow with information if it went well. Thank you all. Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6937356 Sent from the gambas-user mailing list archive at Nabble.com. From sourceforge-raindog2 at ...94... Sun Oct 22 06:34:11 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sun, 22 Oct 2006 00:34:11 -0400 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 Message-ID: <200610220034.11714.sourceforge-raindog2@...94...> Since necessity is the mother of invention, I had to spend some time today updating ImportVBProject to work with recent Gambas versions (I tested it with 1.9.42.) It won't work with 1.0 releases because it needs the gb.pcre component. ImportVBProject is a pretty simple Gambas program that takes a VB .frm or .vbp file, and imports the form designs into a Gambas project of your choosing (or creates a new one.) If you import a form into a Gambas project that's already open, make sure you do Project/Refresh from the Gambas menu afterward. It DOES NOT convert any code, just form designs. The only new feature in this release is compatibility with the changes to the Gambas language in the last year and a half. This program was obsolete for a long time since I had merged it into the Gambas IDE. That function seems to be gone in the new version of the IDE so here's ImportVBProject again. Rob -------------- next part -------------- A non-text attachment was scrubbed... Name: ImportVBProject-0.0.8.tar.gz Type: application/x-tgz Size: 26649 bytes Desc: not available URL: From rohnny at ...1248... Sun Oct 22 07:28:50 2006 From: rohnny at ...1248... (R. Stormo) Date: Sat, 21 Oct 2006 22:28:50 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <6937356.post@...1379...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> <453A5C9E.2090907@...626...> <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> <6935447.post@...1379...> <200610212333.36485.ronstk@...239...> <200610212353.52594.ronstk@...239...> <6937356.post@...1379...> Message-ID: <6939111.post@...1379...> R. Stormo wrote: > > > > Ron Onstenk wrote: >> >> >> files involved with the problem are: >> >> acinclude.m4 >> component.am >> configure.ac >> config.guess >> config.sub >> >> ltmain.sh >> >> depcomp >> reconf >> install-sh >> missing >> >> >> ------------------------------------------------------------------------- >> Using Tomcat but need to do more? Need to support web services, security? >> Get stuff done quickly with pre-integrated technology to make your job >> easier >> Download IBM WebSphere Application Server v.1.0.1 based on Apache >> Geronimo >> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> > > I did remove automake and installed it again, this way I was missing > aclocal > I put the alternative to automake1.9 > sudo update-alternatives --config automake > > and made a link aclocal to aclocal1.9 then I got these errors (did not > find aclocal-1.7) > > --snip > gb.sdl > /usr/share/aclocal/tulip.m4:2: warning: underquoted definition of > AC_PATH_TULIP > run info '(automake)Extending aclocal' > or see > http://sources.redhat.com/automake/automake.html#Extending-aclocal > /usr/share/aclocal/tcl.m4:20: warning: underquoted definition of > SC_PATH_TCLCONFIG > /usr/share/aclocal/tcl.m4:124: warning: underquoted definition of > SC_PATH_TKCONFIG > /usr/share/aclocal/tcl.m4:228: warning: underquoted definition of > SC_LOAD_TCLCONFIG > /usr/share/aclocal/tcl.m4:295: warning: underquoted definition of > SC_LOAD_TKCONFIG > /usr/share/aclocal/tcl.m4:332: warning: underquoted definition of > SC_PROG_TCLSH > autoconf/general.m4:1657: AC_CANONICAL_TARGET is expanded from... > configure.ac:10: AC_CANONICAL_TARGET is required by... > aclocal.m4:193: AM_PATH_SDL is expanded from... > configure.ac:10: the top level > gb.sdl.sound > > --snap > > > > Configure went well :D , waiting for make to finish. Get back tomorrow > with information if it went well. > > Thank you all. > > > Regards Rohnny > My Gambas Community http://gambasforum.tk > > > make and install worked fine also, thanks. But when I open gambas from terminal I get this --snip Stock._get.220: Cannot find: directory when I open a small test project I get 4 more of these When I switch project I get this Stock._get.220: Cannot find: new-dir Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: home Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: home Stock._get.220: Cannot find: desktop Stock._get.220: Cannot find: system Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Stock._get.220: Cannot find: directory Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6939111 Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Sun Oct 22 09:33:33 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 09:33:33 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <6939111.post@...1379...> References: <6933717.post@...1379...> <6937356.post@...1379...> <6939111.post@...1379...> Message-ID: <200610220933.33494.gambas@...1...> On Sunday 22 October 2006 07:28, R. Stormo wrote: > > make and install worked fine also, thanks. > > But when I open gambas from terminal I get this > --snip > > Stock._get.220: Cannot find: directory > > when I open a small test project I get 4 more of these > > When I switch project I get this > > Stock._get.220: Cannot find: new-dir > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: home > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: home > Stock._get.220: Cannot find: desktop > Stock._get.220: Cannot find: system > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > Stock._get.220: Cannot find: directory > > > > Regards Rohnny > My Gambas Community http://gambasforum.tk At the moment, the Stock class depends on QT or GTK+ icons. I think some of them are not installed on your computer. Please find the directory where your icons are installed and tell me. It is usually /usr/share/icons/crystalsvg and /usr/share/icons/hicolor. The Stock class use the 'kde-config' program to detect the path where KDE icons are installed. But it seems there is no way for detecting gnome icon paths. In the future, I will store icons to use them when nor gnome or kde is installed. Regards, -- Benoit Minisini From gambas at ...1... Sun Oct 22 09:36:53 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 09:36:53 +0200 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610220034.11714.sourceforge-raindog2@...94...> References: <200610220034.11714.sourceforge-raindog2@...94...> Message-ID: <200610220936.54057.gambas@...1...> On Sunday 22 October 2006 06:34, Rob wrote: > Since necessity is the mother of invention, I had to spend some > time today updating ImportVBProject to work with recent Gambas > versions (I tested it with 1.9.42.) It won't work with 1.0 > releases because it needs the gb.pcre component. > > ImportVBProject is a pretty simple Gambas program that takes a > VB .frm or .vbp file, and imports the form designs into a Gambas > project of your choosing (or creates a new one.) If you import > a form into a Gambas project that's already open, make sure you > do Project/Refresh from the Gambas menu afterward. It DOES NOT > convert any code, just form designs. The only new feature in > this release is compatibility with the changes to the Gambas > language in the last year and a half. > > This program was obsolete for a long time since I had merged it > into the Gambas IDE. That function seems to be gone in the new > version of the IDE so here's ImportVBProject again. > > Rob I will put it in the svn. Do you want a write access so that you can develop in it ? -- Benoit Minisini From rohnny at ...1248... Sun Oct 22 09:59:04 2006 From: rohnny at ...1248... (R. Stormo) Date: Sun, 22 Oct 2006 00:59:04 -0700 (PDT) Subject: [Gambas-user] compile from svn In-Reply-To: <200610220933.33494.gambas@...1...> References: <6933717.post@...1379...> <200610211933.58054.ronstk@...239...> <6324a42a0610211041q2b0e79b1qa047247785b3277d@...627...> <453A5C9E.2090907@...626...> <6324a42a0610211049r2bb480adv187de53c06b0ac8b@...627...> <6935447.post@...1379...> <200610212333.36485.ronstk@...239...> <200610212353.52594.ronstk@...239...> <6937356.post@...1379...> <6939111.post@...1379...> <200610220933.33494.gambas@...1...> Message-ID: <6939751.post@...1379...> gambas-3 wrote: > > On Sunday 22 October 2006 07:28, R. Stormo wrote: >> >> make and install worked fine also, thanks. >> >> But when I open gambas from terminal I get this >> --snip >> >> Stock._get.220: Cannot find: directory >> >> when I open a small test project I get 4 more of these >> >> When I switch project I get this >> >> Stock._get.220: Cannot find: new-dir >> Stock._get.220: Cannot find: directory >> Stock._get.220: Cannot find: directory >> Stock._get.220: Cannot find: directory >> Stock._get.220: Cannot find: directory >> Stock._get.220: Cannot find: directory >> >> >> >> Regards Rohnny >> My Gambas Community http://gambasforum.tk > > At the moment, the Stock class depends on QT or GTK+ icons. I think some > of > them are not installed on your computer. > > Please find the directory where your icons are installed and tell me. It > is > usually /usr/share/icons/crystalsvg and /usr/share/icons/hicolor. > > The Stock class use the 'kde-config' program to detect the path where KDE > icons are installed. But it seems there is no way for detecting gnome icon > paths. > > In the future, I will store icons to use them when nor gnome or kde is > installed. > > Regards, > > -- > Benoit Minisini > > > > Yes they are at that location rohnny at ...1008...:/usr/share/icons/crystalsvg$ ls 128x128 22x22 48x48 icon-theme.cache scalable 16x16 32x32 64x64 index.theme rohnny at ...1008...:/usr/share/icons/crystalsvg$ cd .. rohnny at ...1008...:/usr/share/icons$ cd hicolor rohnny at ...1008...:/usr/share/icons/hicolor$ ls 128x128 192x192 24x24 36x36 64x64 96x96 index.theme 16x16 22x22 32x32 48x48 72x72 icon-theme.cache scalable I have a program called kde-config but when I run it nothing happens. It do not run in process either Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/compile-from-svn-tf2486708.html#a6939751 Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Sun Oct 22 10:15:45 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 10:15:45 +0200 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610220034.11714.sourceforge-raindog2@...94...> References: <200610220034.11714.sourceforge-raindog2@...94...> Message-ID: <200610221015.45538.gambas@...1...> On Sunday 22 October 2006 06:34, Rob wrote: > Since necessity is the mother of invention, I had to spend some > time today updating ImportVBProject to work with recent Gambas > versions (I tested it with 1.9.42.) It won't work with 1.0 > releases because it needs the gb.pcre component. > > ImportVBProject is a pretty simple Gambas program that takes a > VB .frm or .vbp file, and imports the form designs into a Gambas > project of your choosing (or creates a new one.) If you import > a form into a Gambas project that's already open, make sure you > do Project/Refresh from the Gambas menu afterward. It DOES NOT > convert any code, just form designs. The only new feature in > this release is compatibility with the changes to the Gambas > language in the last year and a half. > > This program was obsolete for a long time since I had merged it > into the Gambas IDE. That function seems to be gone in the new > version of the IDE so here's ImportVBProject again. > > Rob Is it possible to make it a command-line only tool ? This way I can easily integrate it in the IDE in the "new file" dialog. Regards, -- Benoit Minisini From gambas at ...1... Sun Oct 22 10:17:07 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 10:17:07 +0200 Subject: [Gambas-user] ERROR: #27: Cannot load component 'gb.db': cannot find library file In-Reply-To: <453A5C52.2090000@...1302...> References: <453A5C52.2090000@...1302...> Message-ID: <200610221017.07915.gambas@...1...> On Saturday 21 October 2006 19:43, Oliver Etchebarne Bejarano wrote: > Hi, > > I don't remember in which version it begun to appear that error (I was > upgrading, thinking the problem was in something in the old version), > but that appears when I try to run the IDE. > > I have a LFS, and I compile gambas with > > ./configure --prefix=/opt/gambas2/ > --with-moc=/opt/qt-x11-free-3.3.6/bin/ > --with-qt-libraries=/opt/qt-x11-free-3.3.6/lib/ > --with-qt-headers=/opt/qt-x11-free-3.3.6/include/ > --with-sdl-libraries=/opt/SDL/lib/ --with-sdl-includes=/opt/SDL/include/ > > ...as you can see, everything is inside /opt . The gb.db.so.* exists in > > [drmad at ...1596... bin]$ l /opt/gambas2/lib/gb.db.so* > -rwxr-xr-x 1 root root 200809 2006-10-21 12:16 /opt/gambas2/lib/gb.db.so* > -rwxr-xr-x 1 root root 200809 2006-10-21 12:16 > /opt/gambas2/lib/gb.db.so.0* -rwxr-xr-x 1 root root 200809 2006-10-21 > 12:16 > /opt/gambas2/lib/gb.db.so.0.0.0* > > and they have a soft symlink in /usr/local/ (e.g /usr/local/lib/gb.db.so*) > > Is there anything I am doing wrong?? > > Saludos, Can you do a 'strace gbx2 -p' in your directory project and look which file it looks for when trying to load gb.db.so? -- Benoit Minisini From ronstk at ...239... Sun Oct 22 15:26:26 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sun, 22 Oct 2006 15:26:26 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <200610220039.03485.gambas@...1...> References: <200610212246.42883.Karl.Reinl@...9...> <6936602.post@...1379...> <200610220039.03485.gambas@...1...> Message-ID: <200610221526.26895.ronstk@...239...> On Sunday 22 October 2006 00:39, Benoit Minisini wrote: > I do a checkout, I compile everything, and I use 'make dist' (with a tweak so > that symlinks are preserved). > It are for me just those tweaked symlinks that breaks me up ATM. Can you provide me with that tweak code so I can make a "correct" un-tweak? Ron From gambas at ...1... Sun Oct 22 15:36:23 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 15:36:23 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <200610221526.26895.ronstk@...239...> References: <200610212246.42883.Karl.Reinl@...9...> <200610220039.03485.gambas@...1...> <200610221526.26895.ronstk@...239...> Message-ID: <200610221536.23880.gambas@...1...> On Sunday 22 October 2006 15:26, Ron Onstenk wrote: > On Sunday 22 October 2006 00:39, Benoit Minisini wrote: > > I do a checkout, I compile everything, and I use 'make dist' (with a > > tweak so that symlinks are preserved). > > It are for me just those tweaked symlinks that breaks me up ATM. > Can you provide me with that tweak code so I can make a "correct" un-tweak? > > > Ron > These symbolic links only points from a file inside the source archive to another file of the source archive, so replacing them by the file they points at will change nothing. I don't understand what your problem is... Regards, -- Benoit Minisini From ronstk at ...239... Sun Oct 22 15:54:55 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sun, 22 Oct 2006 15:54:55 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <200610220041.21082.gambas@...1...> References: <6933717.post@...1379...> <200610212333.36485.ronstk@...239...> <200610220041.21082.gambas@...1...> Message-ID: <200610221554.55932.ronstk@...239...> On Sunday 22 October 2006 00:41, Benoit Minisini wrote: > I must not touch these files, they are generated by autoconf,automake & friends. OK I do understand > I think the error comes from not using the "correct" version of these tools. > > Regards, > > -- > Benoit Minisini > What is the "correct" one? You use 1.9.6? aclocal.m4 tell: # generated automatically by aclocal 1.9.5 -*- Autoconf -*- acinclude.m4 tell: AM_INIT_AUTOMAKE($1, 1.9.45) config.sub tell: timestamp='2005-05-12' my box in /usr/share/aclocal aclocal --version aclocal (GNU automake) 1.9.5 automake --version automake (GNU automake) 1.9.5 /usr/share/automake-1.9/ config.sub tell: timestamp='2005-02-10' Fabian tell at 2006-10-21 19:41 > and this is the final soluce : > uninstall automake1.4 and 1.9 > and then install the automake1.7 <------------------------ downgrade ??? > > in fact the problem come from gambas that have script file only compatible > with this automake version. uuuuhhhh and Benoit is using 1.9.5/6 in gambas 1.9.43/44 ? > > I've the same problem on Ubuntu dapper/edgy and on many distrib too > Regards, > Fabien Bodard It looks the version hell with Linux is starting :) :) :) My major problem is there are files in the svn tree that contains a line to the 'link' executable and that belongs to the 'coreutils.rpm' and NOT the automake and friends :) I do not see up/downgrade of the auto* package make/will any change to it. The behaviour of 'link' is not as expected by the auto* developers? Ron From gambas at ...1... Sun Oct 22 16:12:34 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 16:12:34 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <200610221554.55932.ronstk@...239...> References: <6933717.post@...1379...> <200610220041.21082.gambas@...1...> <200610221554.55932.ronstk@...239...> Message-ID: <200610221612.34893.gambas@...1...> On Sunday 22 October 2006 15:54, Ron Onstenk wrote: > On Sunday 22 October 2006 00:41, Benoit Minisini wrote: > > I must not touch these files, they are generated by autoconf,automake & > > friends. > > OK I do understand > > > I think the error comes from not using the "correct" version of these > > tools. > > > > Regards, > > > > -- > > Benoit Minisini > > What is the "correct" one? > > You use 1.9.6? > aclocal.m4 tell: # generated automatically by aclocal 1.9.5 -*- Autoconf > -*- acinclude.m4 tell: AM_INIT_AUTOMAKE($1, 1.9.45) > config.sub tell: timestamp='2005-05-12' > > > my box in /usr/share/aclocal > aclocal --version > aclocal (GNU automake) 1.9.5 > automake --version > automake (GNU automake) 1.9.5 > > /usr/share/automake-1.9/ > config.sub tell: timestamp='2005-02-10' > > > Fabian tell at 2006-10-21 19:41 > > > and this is the final soluce : > > uninstall automake1.4 and 1.9 > > and then install the automake1.7 <------------------------ downgrade ??? > > > > in fact the problem come from gambas that have script file only > > compatible with this automake version. > > uuuuhhhh and Benoit is using 1.9.5/6 in gambas 1.9.43/44 ? > > > I've the same problem on Ubuntu dapper/edgy and on many distrib too > > > > Regards, > > Fabien Bodard > > It looks the version hell with Linux is starting :) :) :) > > My major problem is there are files in the svn tree that contains a line > to the 'link' executable and that belongs to the 'coreutils.rpm' and NOT > the automake and friends :) > I do not see up/downgrade of the auto* package make/will any change to it. > > The behaviour of 'link' is not as expected by the auto* developers? > > > Ron > There is apparently no file that uses the link executable in the trunk. Where do you see it? How do you make your checkout? -- Benoit Minisini From ronstk at ...239... Sun Oct 22 16:19:20 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sun, 22 Oct 2006 16:19:20 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <200610221536.23880.gambas@...1...> References: <200610212246.42883.Karl.Reinl@...9...> <200610221526.26895.ronstk@...239...> <200610221536.23880.gambas@...1...> Message-ID: <200610221619.20814.ronstk@...239...> On Sunday 22 October 2006 15:36, Benoit Minisini wrote: > On Sunday 22 October 2006 15:26, Ron Onstenk wrote: > > On Sunday 22 October 2006 00:39, Benoit Minisini wrote: > > > I do a checkout, I compile everything, and I use 'make dist' (with a > > > tweak so that symlinks are preserved). > > > > It are for me just those tweaked symlinks that breaks me up ATM. > > Can you provide me with that tweak code so I can make a "correct" un-tweak? > > > > > > Ron > > > > These symbolic links only points from a file inside the source archive to > another file of the source archive, so replacing them by the file they points > at will change nothing. I don't understand what your problem is... > > Regards, > In the svn tree (after check-out) /svn/trunk/main is a "file config.sub" and NOT a "symlink to ../config.sub". The content is: "link ../config.sub" The purpose I understand is that as source given to the shell by the configure script it SHOULD remove the 'config.sub' text file and make a symlink named 'config.sub' to '../config.sub' './configure' should, I assume, convert the textfiles to symlinks during his proccess but it does not. from help and man page etc: # link --version link (GNU coreutils) 5.2.1 Written by Michael Stone. Usage: link FILE1 FILE2 ? or: ?link OPTION Call the link function to create a link named FILE2 to an existing FILE1. My SuSE version of link EXPECTS: 'link FILE1 FILE2' Only FILE1 is given, where the symlink should point to. FILE2 is missing and the program 'link' does not make the symlink. And './configure' give up. :) Replace of the content in config.sub with (rm ./config.sub; link ../config.sub config.sub) does work (rm ./config.sub; link ../config.sub config.sub) see as (rm ./FILE2; link FILE1 FILE2) where FILE2 is the text file to replace as symlink and given as command source to the shell by configure. Ron From gambas at ...1... Sun Oct 22 16:47:04 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 16:47:04 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <200610221619.20814.ronstk@...239...> References: <200610212246.42883.Karl.Reinl@...9...> <200610221536.23880.gambas@...1...> <200610221619.20814.ronstk@...239...> Message-ID: <200610221647.04869.gambas@...1...> On Sunday 22 October 2006 16:19, Ron Onstenk wrote: > On Sunday 22 October 2006 15:36, Benoit Minisini wrote: > > On Sunday 22 October 2006 15:26, Ron Onstenk wrote: > > > On Sunday 22 October 2006 00:39, Benoit Minisini wrote: > > > > I do a checkout, I compile everything, and I use 'make dist' (with a > > > > tweak so that symlinks are preserved). > > > > > > It are for me just those tweaked symlinks that breaks me up ATM. > > > Can you provide me with that tweak code so I can make a "correct" > > > un-tweak? > > > > > > > > > Ron > > > > These symbolic links only points from a file inside the source archive to > > another file of the source archive, so replacing them by the file they > > points at will change nothing. I don't understand what your problem is... > > > > Regards, > > In the svn tree (after check-out) > /svn/trunk/main is a "file config.sub" and NOT a "symlink to > ../config.sub". > > The content is: "link ../config.sub" This file has no contents, it is a symbolic link. What you see is just a text displayed by the svn web viewer. If you get a text file with this contents when doing a checkout, instead of a true symbolic link, then you have a problem with your subversion client! Regards, -- Benoit Minisini From ronstk at ...239... Sun Oct 22 17:07:57 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sun, 22 Oct 2006 17:07:57 +0200 Subject: [Gambas-user] compile from svn In-Reply-To: <200610221612.34893.gambas@...1...> References: <6933717.post@...1379...> <200610221554.55932.ronstk@...239...> <200610221612.34893.gambas@...1...> Message-ID: <200610221707.58489.ronstk@...239...> On Sunday 22 October 2006 16:12, Benoit Minisini wrote: > There is apparently no file that uses the link executable in the trunk. > > Where do you see it? ===================================================================== in svn/trunk/configure around line 1313 in svn/trunk/main/configure around line 1313 ac_config_guess="$SHELL $ac_aux_dir/config.guess" ac_config_sub="$SHELL $ac_aux_dir/config.sub" ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure. ====================================================================== in svn/trunk/configure around line 2476 in svn/trunk/main/configure around line 2476 # Make sure we can run config.sub. $ac_config_sub sun4 >/dev/null 2>&1 || { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5 echo "$as_me: error: cannot run $ac_config_sub" >&2;} { (exit 1); exit 1; }; } ======================================================================= configure: configuring in main configure: running /bin/sh './configure' --prefix=/opt/gb ?'-C' '--prefix=/opt/gb' --cache-file=../config.cache --srcdir=. configure: loading cache ../config.cache checking for a BSD-compatible install... (cached) /usr/bin/install -c checking whether build environment is sane... yes link: too few arguments Try `link --help' for more information. configure: WARNING: `missing' script is too old or missing checking for gawk... (cached) gawk checking whether make sets $(MAKE)... (cached) yes configure: error: cannot run /bin/sh ./config.sub configure: error: /bin/sh './configure' failed for main ====================================================================== And the next line is the prove the file is passed as argument to the shell?? configure: error: cannot run /bin/sh ./config.sub > > How do you make your checkout? my script named 'getgbsvn' #!/bin/bash echo "Getting the gambas source :)" cd /home/ron/src/svn svn checkout https://svn.sourceforge.net/svnroot/gambas/2.0/trunk cd trunk ./reconf-all > > -- > Benoit Minisini > # svn --version svn, version 1.0.8 (r11084) compiled Dec 21 2004, 01:27:25 SuSE package 9.2 From ronstk at ...239... Sun Oct 22 17:45:35 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sun, 22 Oct 2006 17:45:35 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <200610221647.04869.gambas@...1...> References: <200610212246.42883.Karl.Reinl@...9...> <200610221619.20814.ronstk@...239...> <200610221647.04869.gambas@...1...> Message-ID: <200610221745.35417.ronstk@...239...> On Sunday 22 October 2006 16:47, Benoit Minisini wrote: > This file has no contents, it is a symbolic link. What you see is just a text > displayed by the svn web viewer. > I do not use the svn web viewer. cat/less config.sub shows text. > If you get a text file with this contents when doing a checkout, instead of a > true symbolic link, then you have a problem with your subversion client! Arg, That make more sense then up/down auto* stuff. (wich one is yours?) Current: svn, version 1.0.8 (r11084) compiled Dec 21 2004, 01:27:25 > > Regards, > > -- > Benoit Minisini > Ron From gambas at ...1... Sun Oct 22 18:00:33 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 18:00:33 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <200610221745.35417.ronstk@...239...> References: <200610212246.42883.Karl.Reinl@...9...> <200610221647.04869.gambas@...1...> <200610221745.35417.ronstk@...239...> Message-ID: <200610221800.33945.gambas@...1...> On Sunday 22 October 2006 17:45, Ron Onstenk wrote: > On Sunday 22 October 2006 16:47, Benoit Minisini wrote: > > This file has no contents, it is a symbolic link. What you see is just a > > text displayed by the svn web viewer. > > I do not use the svn web viewer. > cat/less config.sub shows text. > > > If you get a text file with this contents when doing a checkout, instead > > of a true symbolic link, then you have a problem with your subversion > > client! > > Arg, That make more sense then up/down auto* stuff. > (wich one is yours?) > Current: > svn, version 1.0.8 (r11084) compiled Dec 21 2004, 01:27:25 > svn, version 1.3.2 (r19776) According to http://subversion.tigris.org/svn_1.1_releasenotes.html, subversion 1.0 does not support symlinks, so everything is explained now! Regards, -- Benoit Minisini From sourceforge-raindog2 at ...94... Sun Oct 22 20:45:58 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sun, 22 Oct 2006 14:45:58 -0400 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610220936.54057.gambas@...1...> References: <200610220034.11714.sourceforge-raindog2@...94...> <200610220936.54057.gambas@...1...> Message-ID: <200610221445.58280.sourceforge-raindog2@...94...> On Sunday 22 October 2006 03:36, Benoit Minisini wrote: > I will put it in the svn. Do you want a write access so that > you can develop in it ? Yes, please! Rob From sourceforge-raindog2 at ...94... Sun Oct 22 20:47:18 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sun, 22 Oct 2006 14:47:18 -0400 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610221015.45538.gambas@...1...> References: <200610220034.11714.sourceforge-raindog2@...94...> <200610221015.45538.gambas@...1...> Message-ID: <200610221447.18464.sourceforge-raindog2@...94...> On Sunday 22 October 2006 04:15, Benoit Minisini wrote: > Is it possible to make it a command-line only tool ? This way > I can easily integrate it in the IDE in the "new file" dialog. Sure, I'll just remove the dialog and the gb.qt component reference and replace it with a startup class. I'll post the result as soon as it's done. Rob From gambas at ...1... Sun Oct 22 20:51:37 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 20:51:37 +0200 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610221445.58280.sourceforge-raindog2@...94...> References: <200610220034.11714.sourceforge-raindog2@...94...> <200610220936.54057.gambas@...1...> <200610221445.58280.sourceforge-raindog2@...94...> Message-ID: <200610222051.37289.gambas@...1...> On Sunday 22 October 2006 20:45, Rob wrote: > On Sunday 22 October 2006 03:36, Benoit Minisini wrote: > > I will put it in the svn. Do you want a write access so that > > you can develop in it ? > > Yes, please! > > Rob > You need to have a sourceforge account. When you have it, tell me what it is, and I will grant you a write access. Regards, -- Benoit Minisini From sourceforge-raindog2 at ...94... Sun Oct 22 20:59:11 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sun, 22 Oct 2006 14:59:11 -0400 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610222051.37289.gambas@...1...> References: <200610220034.11714.sourceforge-raindog2@...94...> <200610221445.58280.sourceforge-raindog2@...94...> <200610222051.37289.gambas@...1...> Message-ID: <200610221459.11225.sourceforge-raindog2@...94...> On Sunday 22 October 2006 14:51, Benoit Minisini wrote: > You need to have a sourceforge account. When you have it, tell > me what it is, and I will grant you a write access. I've been posting from my sourceforge account for the last 3 years ;) It's "raindog2". Rob From gambas at ...1... Sun Oct 22 21:23:45 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 22 Oct 2006 21:23:45 +0200 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610221459.11225.sourceforge-raindog2@...94...> References: <200610220034.11714.sourceforge-raindog2@...94...> <200610222051.37289.gambas@...1...> <200610221459.11225.sourceforge-raindog2@...94...> Message-ID: <200610222123.45681.gambas@...1...> On Sunday 22 October 2006 20:59, Rob wrote: > On Sunday 22 October 2006 14:51, Benoit Minisini wrote: > > You need to have a sourceforge account. When you have it, tell > > me what it is, and I will grant you a write access. > > I've been posting from my sourceforge account for the last 3 > years ;) It's "raindog2". > > Rob > Done. Put your project in /2.0/trunk/app/src/, with gambas2, gambas-database-manager, and doc.cgi. Regards, -- Benoit Minisini From ronstk at ...239... Mon Oct 23 01:35:55 2006 From: ronstk at ...239... (Ron Onstenk) Date: Mon, 23 Oct 2006 01:35:55 +0200 Subject: [Gambas-user] to : compile from svn In-Reply-To: <200610221800.33945.gambas@...1...> References: <200610212246.42883.Karl.Reinl@...9...> <200610221745.35417.ronstk@...239...> <200610221800.33945.gambas@...1...> Message-ID: <200610230135.55599.ronstk@...239...> On Sunday 22 October 2006 18:00, Benoit Minisini wrote: > On Sunday 22 October 2006 17:45, Ron Onstenk wrote: > > On Sunday 22 October 2006 16:47, Benoit Minisini wrote: > > > This file has no contents, it is a symbolic link. What you see is just a > > > text displayed by the svn web viewer. > > > > I do not use the svn web viewer. > > cat/less config.sub shows text. > > > > > If you get a text file with this contents when doing a checkout, instead > > > of a true symbolic link, then you have a problem with your subversion > > > client! > > > > Arg, That make more sense then up/down auto* stuff. > > (wich one is yours?) > > Current: > > svn, version 1.0.8 (r11084) compiled Dec 21 2004, 01:27:25 > > > > svn, version 1.3.2 (r19776) > > According to http://subversion.tigris.org/svn_1.1_releasenotes.html, > subversion 1.0 does not support symlinks, so everything is explained now! > > Regards, > Yes, it is. I'm cry-ing very loud now. This 1.0.8 is the last version precompiled for SuSE 9.2 :( Seen 1.4 at http://subversion.tigris.org/ and will give it a shot. Thanks for info Ron From olinux at ...289... Mon Oct 23 09:05:50 2006 From: olinux at ...289... (olinux) Date: Mon, 23 Oct 2006 09:05:50 +0200 Subject: [Gambas-user] come-back again In-Reply-To: <200610230135.55599.ronstk@...239...> References: <200610212246.42883.Karl.Reinl@...9...> <200610221745.35417.ronstk@...239...> <200610221800.33945.gambas@...1...> <200610230135.55599.ronstk@...239...> Message-ID: <453C69CE.10400@...289...> a long time ago, i was gambas user the life make me a Xp user for some time and now, I come back to linux and gambas Good suprise withe 1.9.44, a real evolution of this product. i test it and here is my first buf finded. In ide at design time, background and foreground of many controls are innaccessibles text value can't be entered manualy (text field is not accessible) color chooser give an error message syst?maticaly: [11] unknown symbol 'Container' in class 'listcontainer' FcolorChooser.AddColor.45' ??? Regards Olivier Coquet http://www.insectopedia.net/ -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.9/490 - Release Date: 20/10/2006 From buxaman at ...626... Mon Oct 23 15:39:18 2006 From: buxaman at ...626... (Fabricio Silva) Date: Mon, 23 Oct 2006 11:39:18 -0200 Subject: [Gambas-user] Can't exec an sql string Message-ID: Hello guys, I have this sql: "select price from product order by cast (price as char)" When I execute this sql inside phpMyAdmin it comes with the right result. But when executing the sql inside Gambas 1.9.34 it comes with the error: "Query failde: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near('price, ....." I'm using price as varchar because in Brazil we use 147,00 instead of 147.00and I haven't figure out yet a way of showing the result with "," whether than dot when I use decimal or float types. Regards Fabricio Silva From rohnny at ...1248... Mon Oct 23 16:53:52 2006 From: rohnny at ...1248... (R. Stormo) Date: Mon, 23 Oct 2006 07:53:52 -0700 (PDT) Subject: [Gambas-user] Can't exec an sql string In-Reply-To: References: Message-ID: <6954599.post@...1379...> Fabricio Silva-2 wrote: > > Hello guys, > > I have this sql: "select price from product order by cast (price as > char)" > When I execute this sql inside phpMyAdmin it comes with the right result. > But when executing the sql inside Gambas 1.9.34 it comes with the error: > "Query failde: You have an error in your SQL syntax; check the manual that > corresponds to your MySQL server version for the right syntax to use > near('price, ....." > I'm using price as varchar because in Brazil we use 147,00 instead of > 147.00and I haven't figure out yet a way of showing the result with > "," whether > than dot when I use decimal or float types. > > Regards > Fabricio Silva > > > What about dont put the price at char it should come out as you want? You could do a , nasty one, dim myprice as string myprice = rs!price if myprice<>"" and NOT isNull(myprice) then myprice = replace(myprice,".","-") myprice = replace(myprice,",",".") myprice = replace(myprice,"-",",") else myprice = "0.00" end if Regards Rohnny My Gambas Community http://gamasforum.tk -- View this message in context: http://www.nabble.com/Can%27t-exec-an-sql-string-tf2494260.html#a6954599 Sent from the gambas-user mailing list archive at Nabble.com. From James.Hatridge at ...17... Mon Oct 23 16:00:29 2006 From: James.Hatridge at ...17... (James Hatridge) Date: Mon, 23 Oct 2006 16:00:29 +0200 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610222123.45681.gambas@...1...> References: <200610220034.11714.sourceforge-raindog2@...94...> <200610221459.11225.sourceforge-raindog2@...94...> <200610222123.45681.gambas@...1...> Message-ID: <200610231600.29466.James.Hatridge@...17...> Hi all! On Sunday 22 October 2006 21:23, Benoit Minisini wrote: > On Sunday 22 October 2006 20:59, Rob wrote: > > On Sunday 22 October 2006 14:51, Benoit Minisini wrote: > > > You need to have a sourceforge account. When you have it, tell > > > me what it is, and I will grant you a write access. > > > > I've been posting from my sourceforge account for the last 3 > > years ;) It's "raindog2". > > > > Rob > > Done. Put your project in /2.0/trunk/app/src/, with gambas2, > gambas-database-manager, and doc.cgi. > > Regards, First of all thanks to Rob for this. Is it possible for a "Export to VB"? It would help me no end. Thanks, JIM -- Jim Hatridge Here I stand. I can do no other. Linux User #88484 ------------------------------------------------------ WartHog Bulletin Info about new German Stamps http://www.fuzzybunnymilitia.org/~hatridge/bulletin/index.php Viel Feind -- Viel Ehr' Anti-US Propaganda stamp collection http://www.fuzzybunnymilitia.org/~hatridge/collection/index.php From sourceforge-raindog2 at ...94... Mon Oct 23 19:10:21 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Mon, 23 Oct 2006 13:10:21 -0400 Subject: [Gambas-user] ANN: ImportVBProject 0.0.8 In-Reply-To: <200610231600.29466.James.Hatridge@...17...> References: <200610220034.11714.sourceforge-raindog2@...94...> <200610222123.45681.gambas@...1...> <200610231600.29466.James.Hatridge@...17...> Message-ID: <200610231310.22078.sourceforge-raindog2@...94...> On Monday 23 October 2006 10:00, James Hatridge wrote: > First of all thanks to Rob for this. Is it possible for a > "Export to VB"? It would help me no end. Well, I wrote ImportVBProject because I needed to convert a lot of VB forms to Gambas for a client, and I've never needed to go the other way, but if you look at the source it shouldn't be too tough to do that. I won't have time to do it myself, though. I also wrote an Access module that would export Access forms to Gambas form files (can't do it easily from Gambas itself because Access forms are stored in an undocumented binary format) but my hard disk on the server started going bad yesterday and trashed my VMware session and all my snapshots, so I'm starting over from scratch :P Rob From gambas.fr at ...626... Mon Oct 23 20:37:42 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Mon, 23 Oct 2006 20:37:42 +0200 Subject: [Gambas-user] come-back again In-Reply-To: <453C69CE.10400@...289...> References: <200610212246.42883.Karl.Reinl@...9...> <200610221745.35417.ronstk@...239...> <200610221800.33945.gambas@...1...> <200610230135.55599.ronstk@...239...> <453C69CE.10400@...289...> Message-ID: <6324a42a0610231137x28cb47b6s337d2be3d4ca6787@...627...> Hi, Olivier what have you doing ? i'm really surprised ! Can you tell us your distrib name and version, and send us an exemple archive ? Fabien i hope you have not an old version installed before install this one and in case of yes you have destroy all gambas related files in usr/lib/gambas 2006/10/23, olinux : > > a long time ago, i was gambas user > the life make me a Xp user for some time > and now, I come back to linux and gambas > > Good suprise withe 1.9.44, a real evolution of this product. > > i test it and here is my first buf finded. > > In ide at design time, background and foreground of many controls are > innaccessibles > > text value can't be entered manualy (text field is not accessible) > color chooser give an error message syst?maticaly: > > [11] unknown symbol 'Container' in class 'listcontainer' > FcolorChooser.AddColor.45' > > > > ??? > > Regards > Olivier Coquet > http://www.insectopedia.net/ > > > -- > No virus found in this outgoing message. > Checked by AVG Free Edition. > Version: 7.1.408 / Virus Database: 268.13.9/490 - Release Date: 20/10/2006 > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas.fr at ...626... Mon Oct 23 20:39:46 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Mon, 23 Oct 2006 20:39:46 +0200 Subject: [Gambas-user] Can't exec an sql string In-Reply-To: References: Message-ID: <6324a42a0610231139t9355eecuc78c46335835c678@...627...> 2006/10/23, Fabricio Silva : > > Hello guys, > > I have this sql: "select price from product order by cast (price as > char)" > When I execute this sql inside phpMyAdmin it comes with the right result. > But when executing the sql inside Gambas 1.9.34 it comes with the error: > "Query failde: You have an error in your SQL syntax; check the manual that > corresponds to your MySQL server version for the right syntax to use > near('price, ....." > I'm using price as varchar because in Brazil we use 147,00 instead of > 147.00and I haven't figure out yet a way of showing the result with > "," whether > than dot when I use decimal or float types. and the 'format' command ? format(value,pattern) Regards > Fabricio Silva > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Mon Oct 23 20:48:25 2006 From: gambas at ...1... (Benoit Minisini) Date: Mon, 23 Oct 2006 20:48:25 +0200 Subject: [Gambas-user] Can't exec an sql string In-Reply-To: References: Message-ID: <200610232048.26056.gambas@...1...> On Monday 23 October 2006 15:39, Fabricio Silva wrote: > Hello guys, > > I have this sql: "select price from product order by cast (price as char)" > When I execute this sql inside phpMyAdmin it comes with the right result. Are you sure that is SQL standard, and not a phpMyAdmin feature? > But when executing the sql inside Gambas 1.9.34 it comes with the error: > "Query failde: You have an error in your SQL syntax; check the manual that > corresponds to your MySQL server version for the right syntax to use > near('price, ....." > I'm using price as varchar because in Brazil we use 147,00 instead of > 147.00and I haven't figure out yet a way of showing the result with > "," whether > than dot when I use decimal or float types. If price is numeric, then you must use the Str() or Format() function to format the value according to your locale. Regards, -- Benoit Minisini From gambas at ...1... Mon Oct 23 20:53:14 2006 From: gambas at ...1... (Benoit Minisini) Date: Mon, 23 Oct 2006 20:53:14 +0200 Subject: [Gambas-user] come-back again In-Reply-To: <453C69CE.10400@...289...> References: <200610212246.42883.Karl.Reinl@...9...> <200610230135.55599.ronstk@...239...> <453C69CE.10400@...289...> Message-ID: <200610232053.14148.gambas@...1...> On Monday 23 October 2006 09:05, olinux wrote: > a long time ago, i was gambas user > the life make me a Xp user for some time > and now, I come back to linux and gambas > > Good suprise withe 1.9.44, a real evolution of this product. > > i test it and here is my first buf finded. > > In ide at design time, background and foreground of many controls are > innaccessibles > > text value can't be entered manualy (text field is not accessible) > color chooser give an error message syst?maticaly: > > [11] unknown symbol 'Container' in class 'listcontainer' > FcolorChooser.AddColor.45' > > > > ??? > > Regards > Olivier Coquet > http://www.insectopedia.net/ I fixed this bug in the svn. You can do it yourself by removing the ".Container" stuff from the line 45 of FColorChooser clss in the IDE source code. Regards, -- Benoit Minisini From gambas.fr at ...626... Mon Oct 23 20:37:42 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Mon, 23 Oct 2006 20:37:42 +0200 Subject: [Gambas-user] come-back again In-Reply-To: <453C69CE.10400@...289...> References: <200610212246.42883.Karl.Reinl@...9...> <200610221745.35417.ronstk@...239...> <200610221800.33945.gambas@...1...> <200610230135.55599.ronstk@...239...> <453C69CE.10400@...289...> Message-ID: <6324a42a0610231137x28cb47b6s337d2be3d4ca6787@...627...> Hi, Olivier what have you doing ? i'm really surprised ! Can you tell us your distrib name and version, and send us an exemple archive ? Fabien i hope you have not an old version installed before install this one and in case of yes you have destroy all gambas related files in usr/lib/gambas 2006/10/23, olinux : > > a long time ago, i was gambas user > the life make me a Xp user for some time > and now, I come back to linux and gambas > > Good suprise withe 1.9.44, a real evolution of this product. > > i test it and here is my first buf finded. > > In ide at design time, background and foreground of many controls are > innaccessibles > > text value can't be entered manualy (text field is not accessible) > color chooser give an error message syst?maticaly: > > [11] unknown symbol 'Container' in class 'listcontainer' > FcolorChooser.AddColor.45' > > > > ??? > > Regards > Olivier Coquet > http://www.insectopedia.net/ > > > -- > No virus found in this outgoing message. > Checked by AVG Free Edition. > Version: 7.1.408 / Virus Database: 268.13.9/490 - Release Date: 20/10/2006 > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From sourceforge-raindog2 at ...94... Mon Oct 23 23:21:42 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Mon, 23 Oct 2006 17:21:42 -0400 Subject: [Gambas-user] Inconsistent handling of control names Message-ID: <200610231721.42742.sourceforge-raindog2@...94...> Apart from the handling of underscores in control names (the compiler allows it, so does VB, but if you try to edit a control in a form imported from VB with an underscore, it'll force you to change the name) I discovered a new problem with the IDE as of 1.9.42. I converted some Access forms to VB forms a while back, and then converted those VB forms to Gambas. I just brought one of those forms up in the IDE and tried to edit it. I noticed a few things: 1. The IDE accepts, and will display, controls with a type of "Textbox" (as opposed to TextBox.) 2. While you can move, resize and do other things to such controls, the name of the control will always be displayed in them, even if you change the Text property. 3. At run time, the control will display the Text property you have set, not the control name. So I'm guessing somewhere in the IDE you're doing a case-insensitive check of the control type, and in other places you're doing a case-sensitive check. I'd actually rather have it error out if it finds a type it doesn't recognize. And I'd like to be able to have underscores in my control names, since the compiler allows them anyway, they're valid in all the other Gambas identifiers, and they're so common in VB apps ;) Rob From gambas.fr at ...626... Mon Oct 23 20:39:46 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Mon, 23 Oct 2006 20:39:46 +0200 Subject: [Gambas-user] Can't exec an sql string In-Reply-To: References: Message-ID: <6324a42a0610231139t9355eecuc78c46335835c678@...627...> 2006/10/23, Fabricio Silva : > > Hello guys, > > I have this sql: "select price from product order by cast (price as > char)" > When I execute this sql inside phpMyAdmin it comes with the right result. > But when executing the sql inside Gambas 1.9.34 it comes with the error: > "Query failde: You have an error in your SQL syntax; check the manual that > corresponds to your MySQL server version for the right syntax to use > near('price, ....." > I'm using price as varchar because in Brazil we use 147,00 instead of > 147.00and I haven't figure out yet a way of showing the result with > "," whether > than dot when I use decimal or float types. and the 'format' command ? format(value,pattern) Regards > Fabricio Silva > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From ronstk at ...239... Tue Oct 24 04:04:22 2006 From: ronstk at ...239... (Ron Onstenk) Date: Tue, 24 Oct 2006 04:04:22 +0200 Subject: [Gambas-user] Inconsistent handling of control names In-Reply-To: <200610231721.42742.sourceforge-raindog2@...94...> References: <200610231721.42742.sourceforge-raindog2@...94...> Message-ID: <200610240404.22686.ronstk@...239...> On Monday 23 October 2006 23:21, Rob wrote: > And I'd like to be able to have underscores in my control names, > since the compiler allows them anyway, they're valid in all the > other Gambas identifiers, and they're so common in VB apps ;) > > Rob > One vote from me to for the same reason :) Ron --- (B.M. will hate me now ;) ) From brian at ...1334... Tue Oct 24 05:13:46 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Mon, 23 Oct 2006 20:13:46 -0700 (PDT) Subject: [Gambas-user] Inconsistent handling of control names In-Reply-To: <200610240404.22686.ronstk@...239...> References: <200610231721.42742.sourceforge-raindog2@...94...> <200610240404.22686.ronstk@...239...> Message-ID: <20061023201208.C79448@...1337...> On Tue, 24 Oct 2006, Ron Onstenk wrote: > On Monday 23 October 2006 23:21, Rob wrote: > > And I'd like to be able to have underscores in my control names, > > since the compiler allows them anyway, they're valid in all the > > other Gambas identifiers, and they're so common in VB apps ;) > > > > Rob > > > > One vote from me to for the same reason :) Put my vote in for that too, with the additional reason that they are frequently used for identifiers in other languages (like C/C++/Python/Ruby) as well. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From olinux at ...289... Tue Oct 24 07:39:12 2006 From: olinux at ...289... (olinux) Date: Tue, 24 Oct 2006 07:39:12 +0200 Subject: [Gambas-user] come-back again In-Reply-To: <200610232053.14148.gambas@...1...> References: <200610212246.42883.Karl.Reinl@...9...> <200610230135.55599.ronstk@...239...> <453C69CE.10400@...289...> <200610232053.14148.gambas@...1...> Message-ID: <453DA700.80509@...289...> thank benoit, But, there is just a little problem :=) with the modification of line 45, i can choose a color but not type a value manualy in the color field !!!!! another little bug in the colorchooser is than the hex value is enabled only after choosing an existing preconfigured color. Before, you can move the mouse on the color circle but value don't change. regards regards. Benoit Minisini a ?crit : > On Monday 23 October 2006 09:05, olinux wrote: > >> a long time ago, i was gambas user >> the life make me a Xp user for some time >> and now, I come back to linux and gambas >> >> Good suprise withe 1.9.44, a real evolution of this product. >> >> i test it and here is my first buf finded. >> >> In ide at design time, background and foreground of many controls are >> innaccessibles >> >> text value can't be entered manualy (text field is not accessible) >> color chooser give an error message syst?maticaly: >> >> [11] unknown symbol 'Container' in class 'listcontainer' >> FcolorChooser.AddColor.45' >> >> >> >> ??? >> >> Regards >> Olivier Coquet >> http://www.insectopedia.net/ >> > > I fixed this bug in the svn. You can do it yourself by removing > the ".Container" stuff from the line 45 of FColorChooser clss in the IDE > source code. > > Regards, > > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/493 - Release Date: 23/10/2006 From olinux at ...289... Tue Oct 24 07:42:34 2006 From: olinux at ...289... (olinux) Date: Tue, 24 Oct 2006 07:42:34 +0200 Subject: [Gambas-user] 1.9.44 treeview sort Message-ID: <453DA7CA.2090207@...289...> aparently, there is a light problem with sort in the treeview, the sort is aparently made only on : 1234567890abcdefghijklmnopqrstuvwxyz maj and min are not considered in the sort and other char like .,;:! etc. are not so considered regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/493 - Release Date: 23/10/2006 From olinux at ...289... Tue Oct 24 08:07:10 2006 From: olinux at ...289... (olinux) Date: Tue, 24 Oct 2006 08:07:10 +0200 Subject: [Gambas-user] 1.9.44 suggestion Message-ID: <453DAD8E.8050800@...289...> a suggestion for the dir function: make possible a filter on hidden files because dir return syst?matiquely hidden files. a suggestion for a new exist function: there is no function to now if a file already exist on the disk. regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/493 - Release Date: 23/10/2006 From timothy.marshal-nichols at ...247... Tue Oct 24 12:17:19 2006 From: timothy.marshal-nichols at ...247... (Timothy Marshal-Nichols) Date: Tue, 24 Oct 2006 11:17:19 +0100 Subject: [Gambas-user] 1.9.44 suggestion In-Reply-To: <453DAD8E.8050800@...289...> Message-ID: <000001c6f755$97e95550$6401a8c0@...1587...> > -----Original Message----- > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > bounces at lists.sourceforge.net] On Behalf Of olinux > Sent: 24 October 2006 07:07 > To: mailing list for gambas users > Subject: [Gambas-user] 1.9.44 suggestion > > a suggestion for the dir function: > > make possible a filter on hidden files because dir return syst?matiquely > hidden files. Use a pattern: Dir(User.Home, "[^.]*") > > a suggestion for a new exist function: This function does exist. But the help on the function does not appear to exist :-) > > there is no function to now if a file already exist on the disk. > > regards > Olivier Coquet > > Thanks 8-) Timothy Marshal-Nichols From olinux at ...289... Tue Oct 24 16:09:38 2006 From: olinux at ...289... (olinux) Date: Tue, 24 Oct 2006 16:09:38 +0200 Subject: [Gambas-user] grid allign Message-ID: <453E1EA2.8040705@...289...> am i completely stupid or in version 1.9.44 there is no way to disable grid allignment in form editor? regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/493 - Release Date: 23/10/2006 From gambas at ...1... Tue Oct 24 22:13:34 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 24 Oct 2006 22:13:34 +0200 Subject: [Gambas-user] 1.9.44 suggestion In-Reply-To: <000001c6f755$97e95550$6401a8c0@...1587...> References: <000001c6f755$97e95550$6401a8c0@...1587...> Message-ID: <200610242213.34563.gambas@...1...> On Tuesday 24 October 2006 12:17, Timothy Marshal-Nichols wrote: > > -----Original Message----- > > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > > bounces at lists.sourceforge.net] On Behalf Of olinux > > Sent: 24 October 2006 07:07 > > To: mailing list for gambas users > > Subject: [Gambas-user] 1.9.44 suggestion > > > > a suggestion for the dir function: > > > > make possible a filter on hidden files because dir return > > syst?matiquely > > > hidden files. > > Use a pattern: > > Dir(User.Home, "[^.]*") > > > a suggestion for a new exist function: > > This function does exist. But the help on the function does not appear > to exist :-) > Are you sure? :-) -- Benoit Minisini From olinux at ...289... Wed Oct 25 08:51:10 2006 From: olinux at ...289... (olinux) Date: Wed, 25 Oct 2006 08:51:10 +0200 Subject: [Gambas-user] bug 1.9.44 Dialog.Filter Message-ID: <453F095E.1080903@...289...> A little bug Dilaog.Filter give strange things with Dialog.SaveFile when setting regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/496 - Release Date: 24/10/2006 From gambas at ...1... Wed Oct 25 10:17:03 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 25 Oct 2006 10:17:03 +0200 Subject: [Gambas-user] grid allign In-Reply-To: <453E1EA2.8040705@...289...> References: <453E1EA2.8040705@...289...> Message-ID: <200610251017.03796.gambas@...1...> On Tuesday 24 October 2006 16:09, olinux wrote: > am i completely stupid or in version 1.9.44 there is no way to disable > grid allignment in form editor? > > > regards > Olivier Coquet There is toggle button for that in the form editor toolbar. Regards, -- Benoit Minisini From gambas at ...1... Wed Oct 25 10:17:21 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 25 Oct 2006 10:17:21 +0200 Subject: [Gambas-user] bug 1.9.44 Dialog.Filter In-Reply-To: <453F095E.1080903@...289...> References: <453F095E.1080903@...289...> Message-ID: <200610251017.21365.gambas@...1...> On Wednesday 25 October 2006 08:51, olinux wrote: > A little bug > > Dilaog.Filter give strange things with Dialog.SaveFile when setting > > > > regards > Olivier Coquet What are you talking about ? I can't read minds yet. :-) -- Benoit Minisini From timothy.marshal-nichols at ...247... Wed Oct 25 10:26:25 2006 From: timothy.marshal-nichols at ...247... (Timothy Marshal-Nichols) Date: Wed, 25 Oct 2006 09:26:25 +0100 Subject: [Gambas-user] 1.9.44 suggestion In-Reply-To: <200610242213.34563.gambas@...1...> Message-ID: <000001c6f80f$4784ef10$6401a8c0@...1587...> > -----Original Message----- > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > bounces at lists.sourceforge.net] On Behalf Of Benoit Minisini > Sent: 24 October 2006 21:14 > To: mailing list for gambas users > Subject: Re: [Gambas-user] 1.9.44 suggestion > > On Tuesday 24 October 2006 12:17, Timothy Marshal-Nichols wrote: > > > -----Original Message----- > > > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > > > bounces at lists.sourceforge.net] On Behalf Of olinux > > > Sent: 24 October 2006 07:07 > > > To: mailing list for gambas users > > > Subject: [Gambas-user] 1.9.44 suggestion > > > > > > a suggestion for the dir function: > > > > > > make possible a filter on hidden files because dir return > > > > syst?matiquely > > > > > hidden files. > > > > Use a pattern: > > > > Dir(User.Home, "[^.]*") > > > > > a suggestion for a new exist function: > > > > This function does exist. But the help on the function does not appear > > to exist :-) > > > > Are you sure? :-) > > -- > Benoit Minisini > > No! It is listed in the online help wiki. But I can not find it in the offline help on my workstation. The language index list jumps from EXEC to Exp. The online help has Exist between these two entries. Also on the "File & Directory Functions" page it shows up as /lang/exists in the online help. But it is not listed in the offline help. Thanks 8-) Timothy Marshal-Nichols From gambas at ...1... Wed Oct 25 10:32:40 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 25 Oct 2006 10:32:40 +0200 Subject: [Gambas-user] 1.9.44 suggestion In-Reply-To: <000001c6f80f$4784ef10$6401a8c0@...1587...> References: <000001c6f80f$4784ef10$6401a8c0@...1587...> Message-ID: <200610251032.40508.gambas@...1...> On Wednesday 25 October 2006 10:26, Timothy Marshal-Nichols wrote: > > -----Original Message----- > > From: gambas-user-bounces at lists.sourceforge.net [mailto:gambas-user- > > bounces at lists.sourceforge.net] On Behalf Of Benoit Minisini > > Sent: 24 October 2006 21:14 > > To: mailing list for gambas users > > Subject: Re: [Gambas-user] 1.9.44 suggestion > > > > On Tuesday 24 October 2006 12:17, Timothy Marshal-Nichols wrote: > > > > -----Original Message----- > > > > From: gambas-user-bounces at lists.sourceforge.net > > [mailto:gambas-user- > > > > > bounces at lists.sourceforge.net] On Behalf Of olinux > > > > Sent: 24 October 2006 07:07 > > > > To: mailing list for gambas users > > > > Subject: [Gambas-user] 1.9.44 suggestion > > > > > > > > a suggestion for the dir function: > > > > > > > > make possible a filter on hidden files because dir return > > > > > > syst?matiquely > > > > > > > hidden files. > > > > > > Use a pattern: > > > > > > Dir(User.Home, "[^.]*") > > > > > > > a suggestion for a new exist function: > > > > > > This function does exist. But the help on the function does not > > appear > > > > to exist :-) > > > > Are you sure? :-) > > > > -- > > Benoit Minisini > > No! It was a joke. I just added it when I read your mail. :-) -- Benoit Minisini From olinux at ...289... Wed Oct 25 10:36:35 2006 From: olinux at ...289... (olinux) Date: Wed, 25 Oct 2006 10:36:35 +0200 Subject: [Gambas-user] grid allign In-Reply-To: <200610251017.03796.gambas@...1...> References: <453E1EA2.8040705@...289...> <200610251017.03796.gambas@...1...> Message-ID: <453F2213.8030104@...289...> Benoit Minisini a ?crit : > On Tuesday 24 October 2006 16:09, olinux wrote: > >> am i completely stupid or in version 1.9.44 there is no way to disable >> grid allignment in form editor? >> >> >> regards >> Olivier Coquet >> > > There is toggle button for that in the form editor toolbar. > > Regards, > > Sorry Benoit but, the toggle button enable or dissable the grid display, but it does not dissable the allignment to grid !!!!!! regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/496 - Release Date: 24/10/2006 From olinux at ...289... Wed Oct 25 10:42:30 2006 From: olinux at ...289... (olinux) Date: Wed, 25 Oct 2006 10:42:30 +0200 Subject: [Gambas-user] bug 1.9.44 Dialog.Filter In-Reply-To: <200610251017.21365.gambas@...1...> References: <453F095E.1080903@...289...> <200610251017.21365.gambas@...1...> Message-ID: <453F2376.8090007@...289...> Benoit Minisini a ?crit : > On Wednesday 25 October 2006 08:51, olinux wrote: > >> A little bug >> >> Dilaog.Filter give strange things with Dialog.SaveFile when setting >> >> >> >> regards >> Olivier Coquet >> > > What are you talking about ? I can't read minds yet. :-) > > setting dialog.filter like this Dialog.filter = ["monfiltre (*.flt)"] and yhe window show this in selector after dialog.save all files (*) setting this: Dialog.Filter = ["monfiltre (*.flt)","mon autre filtre (*.mft)"] and the window show this in selector after dialog.save monfiltre (*.flt)(mon autre filtre (*.mft)) all files (*) setting this: Dialog.Filter = ["monfiltre (*.flt)",""] and the window show this in selector after dialog.save monfiltre (*.flt)() all files (*) regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/496 - Release Date: 24/10/2006 From gambas at ...1... Wed Oct 25 10:44:53 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 25 Oct 2006 10:44:53 +0200 Subject: [Gambas-user] grid allign In-Reply-To: <453F2213.8030104@...289...> References: <453E1EA2.8040705@...289...> <200610251017.03796.gambas@...1...> <453F2213.8030104@...289...> Message-ID: <200610251044.53192.gambas@...1...> On Wednesday 25 October 2006 10:36, olinux wrote: > Benoit Minisini a ?crit : > > On Tuesday 24 October 2006 16:09, olinux wrote: > >> am i completely stupid or in version 1.9.44 there is no way to disable > >> grid allignment in form editor? > >> > >> > >> regards > >> Olivier Coquet > > > > There is toggle button for that in the form editor toolbar. > > > > Regards, > > Sorry Benoit but, the toggle button enable or dissable the grid display, > but it does not dissable the allignment to grid !!!!!! > > > regards > > Olivier Coquet Oops sorry! You must enter your coordinates manually, or press the SHIFT key while moving or resizing the control. Regards, -- Benoit Minisini From gambas at ...1... Wed Oct 25 10:45:58 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 25 Oct 2006 10:45:58 +0200 Subject: [Gambas-user] bug 1.9.44 Dialog.Filter In-Reply-To: <453F2376.8090007@...289...> References: <453F095E.1080903@...289...> <200610251017.21365.gambas@...1...> <453F2376.8090007@...289...> Message-ID: <200610251045.58956.gambas@...1...> On Wednesday 25 October 2006 10:42, olinux wrote: > Benoit Minisini a ?crit : > > On Wednesday 25 October 2006 08:51, olinux wrote: > >> A little bug > >> > >> Dilaog.Filter give strange things with Dialog.SaveFile when setting > >> > >> > >> > >> regards > >> Olivier Coquet > > > > What are you talking about ? I can't read minds yet. :-) > > setting dialog.filter like this > > Dialog.filter = ["monfiltre (*.flt)"] > > and yhe window show this in selector after dialog.save > > all files (*) > > setting this: > > Dialog.Filter = ["monfiltre (*.flt)","mon autre filtre (*.mft)"] > > and the window show this in selector after dialog.save > > monfiltre (*.flt)(mon autre filtre (*.mft)) > all files (*) > > setting this: > > Dialog.Filter = ["monfiltre (*.flt)",""] > > and the window show this in selector after dialog.save > > monfiltre (*.flt)() > all files (*) > > regards > Olivier Coquet Do you use gb.qt component, gb.qt & gb.form or gb.qt & gb.qt.kde ? -- Benoit Minisini From olinux at ...289... Wed Oct 25 10:49:13 2006 From: olinux at ...289... (olinux) Date: Wed, 25 Oct 2006 10:49:13 +0200 Subject: [Gambas-user] grid allign In-Reply-To: <200610251044.53192.gambas@...1...> References: <453E1EA2.8040705@...289...> <200610251017.03796.gambas@...1...> <453F2213.8030104@...289...> <200610251044.53192.gambas@...1...> Message-ID: <453F2509.8070300@...289...> Benoit Minisini a ?crit : > On Wednesday 25 October 2006 10:36, olinux wrote: > >> Benoit Minisini a ?crit : >> >>> On Tuesday 24 October 2006 16:09, olinux wrote: >>> >>>> am i completely stupid or in version 1.9.44 there is no way to disable >>>> grid allignment in form editor? >>>> >>>> >>>> regards >>>> Olivier Coquet >>>> >>> There is toggle button for that in the form editor toolbar. >>> >>> Regards, >>> >> Sorry Benoit but, the toggle button enable or dissable the grid display, >> but it does not dissable the allignment to grid !!!!!! >> >> >> regards >> >> Olivier Coquet >> > > Oops sorry! You must enter your coordinates manually, or press the SHIFT key > while moving or resizing the control. > > Regards, > > thanks !!!! -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/496 - Release Date: 24/10/2006 From olinux at ...289... Wed Oct 25 10:50:53 2006 From: olinux at ...289... (olinux) Date: Wed, 25 Oct 2006 10:50:53 +0200 Subject: [Gambas-user] bug 1.9.44 Dialog.Filter In-Reply-To: <200610251045.58956.gambas@...1...> References: <453F095E.1080903@...289...> <200610251017.21365.gambas@...1...> <453F2376.8090007@...289...> <200610251045.58956.gambas@...1...> Message-ID: <453F256D.4020606@...289...> Benoit Minisini a ?crit : > On Wednesday 25 October 2006 10:42, olinux wrote: > >> Benoit Minisini a ?crit : >> >>> On Wednesday 25 October 2006 08:51, olinux wrote: >>> >>>> A little bug >>>> >>>> Dilaog.Filter give strange things with Dialog.SaveFile when setting >>>> >>>> >>>> >>>> regards >>>> Olivier Coquet >>>> >>> What are you talking about ? I can't read minds yet. :-) >>> >> setting dialog.filter like this >> >> Dialog.filter = ["monfiltre (*.flt)"] >> >> and yhe window show this in selector after dialog.save >> >> all files (*) >> >> setting this: >> >> Dialog.Filter = ["monfiltre (*.flt)","mon autre filtre (*.mft)"] >> >> and the window show this in selector after dialog.save >> >> monfiltre (*.flt)(mon autre filtre (*.mft)) >> all files (*) >> >> setting this: >> >> Dialog.Filter = ["monfiltre (*.flt)",""] >> >> and the window show this in selector after dialog.save >> >> monfiltre (*.flt)() >> all files (*) >> >> regards >> Olivier Coquet >> > > Do you use gb.qt component, gb.qt & gb.form or gb.qt & gb.qt.kde ? > > gb.qt only regards -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/496 - Release Date: 24/10/2006 From gambas at ...1... Wed Oct 25 10:58:51 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 25 Oct 2006 10:58:51 +0200 Subject: [Gambas-user] bug 1.9.44 Dialog.Filter In-Reply-To: <453F256D.4020606@...289...> References: <453F095E.1080903@...289...> <200610251045.58956.gambas@...1...> <453F256D.4020606@...289...> Message-ID: <200610251058.52046.gambas@...1...> On Wednesday 25 October 2006 10:50, olinux wrote: > Benoit Minisini a ?crit : > > On Wednesday 25 October 2006 10:42, olinux wrote: > >> Benoit Minisini a ?crit : > >>> On Wednesday 25 October 2006 08:51, olinux wrote: > >>>> A little bug > >>>> > >>>> Dilaog.Filter give strange things with Dialog.SaveFile when setting > >>>> > >>>> > >>>> > >>>> regards > >>>> Olivier Coquet > >>> > >>> What are you talking about ? I can't read minds yet. :-) > >> > >> setting dialog.filter like this > >> > >> Dialog.filter = ["monfiltre (*.flt)"] > >> > >> and yhe window show this in selector after dialog.save > >> > >> all files (*) > >> > >> setting this: > >> > >> Dialog.Filter = ["monfiltre (*.flt)","mon autre filtre (*.mft)"] > >> > >> and the window show this in selector after dialog.save > >> > >> monfiltre (*.flt)(mon autre filtre (*.mft)) > >> all files (*) > >> > >> setting this: > >> > >> Dialog.Filter = ["monfiltre (*.flt)",""] > >> > >> and the window show this in selector after dialog.save > >> > >> monfiltre (*.flt)() > >> all files (*) > >> > >> regards > >> Olivier Coquet > > > > Do you use gb.qt component, gb.qt & gb.form or gb.qt & gb.qt.kde ? > > gb.qt only > > regards The syntax has changed. See http://gambasdoc.org/help/comp/gb.qt/dialog/filter Regards, -- Benoit Minisini From olinux at ...289... Wed Oct 25 11:28:53 2006 From: olinux at ...289... (olinux) Date: Wed, 25 Oct 2006 11:28:53 +0200 Subject: [Gambas-user] bug 1.9.44 Dialog.Filter In-Reply-To: <200610251058.52046.gambas@...1...> References: <453F095E.1080903@...289...> <200610251045.58956.gambas@...1...> <453F256D.4020606@...289...> <200610251058.52046.gambas@...1...> Message-ID: <453F2E55.9020002@...289...> Benoit Minisini a ?crit : > On Wednesday 25 October 2006 10:50, olinux wrote: > >> Benoit Minisini a ?crit : >> >>> On Wednesday 25 October 2006 10:42, olinux wrote: >>> >>>> Benoit Minisini a ?crit : >>>> >>>>> On Wednesday 25 October 2006 08:51, olinux wrote: >>>>> >>>>>> A little bug >>>>>> >>>>>> Dilaog.Filter give strange things with Dialog.SaveFile when setting >>>>>> >>>>>> >>>>>> >>>>>> regards >>>>>> Olivier Coquet >>>>>> >>>>> What are you talking about ? I can't read minds yet. :-) >>>>> >>>> setting dialog.filter like this >>>> >>>> Dialog.filter = ["monfiltre (*.flt)"] >>>> >>>> and yhe window show this in selector after dialog.save >>>> >>>> all files (*) >>>> >>>> setting this: >>>> >>>> Dialog.Filter = ["monfiltre (*.flt)","mon autre filtre (*.mft)"] >>>> >>>> and the window show this in selector after dialog.save >>>> >>>> monfiltre (*.flt)(mon autre filtre (*.mft)) >>>> all files (*) >>>> >>>> setting this: >>>> >>>> Dialog.Filter = ["monfiltre (*.flt)",""] >>>> >>>> and the window show this in selector after dialog.save >>>> >>>> monfiltre (*.flt)() >>>> all files (*) >>>> >>>> regards >>>> Olivier Coquet >>>> >>> Do you use gb.qt component, gb.qt & gb.form or gb.qt & gb.qt.kde ? >>> >> gb.qt only >> >> regards >> > > The syntax has changed. See http://gambasdoc.org/help/comp/gb.qt/dialog/filter > > Regards, > > thank ! -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/496 - Release Date: 24/10/2006 From gambas at ...1... Wed Oct 25 17:58:37 2006 From: gambas at ...1... (Benoit Minisini) Date: Wed, 25 Oct 2006 17:58:37 +0200 Subject: [Gambas-user] Inconsistent handling of control names In-Reply-To: <200610231721.42742.sourceforge-raindog2@...94...> References: <200610231721.42742.sourceforge-raindog2@...94...> Message-ID: <200610251758.37880.gambas@...1...> On Monday 23 October 2006 23:21, Rob wrote: > Apart from the handling of underscores in control names (the > compiler allows it, so does VB, but if you try to edit a control > in a form imported from VB with an underscore, it'll force you > to change the name) I discovered a new problem with the IDE as > of 1.9.42. > > I converted some Access forms to VB forms a while back, and then > converted those VB forms to Gambas. I just brought one of those > forms up in the IDE and tried to edit it. I noticed a few > things: > > 1. The IDE accepts, and will display, controls with a type > of "Textbox" (as opposed to TextBox.) > > 2. While you can move, resize and do other things to such > controls, the name of the control will always be displayed in > them, even if you change the Text property. > > 3. At run time, the control will display the Text property you > have set, not the control name. > > So I'm guessing somewhere in the IDE you're doing a > case-insensitive check of the control type, and in other places > you're doing a case-sensitive check. I'd actually rather have > it error out if it finds a type it doesn't recognize. I found only one case sensitive test on control type, so I replaced it by an non-sensitive test. > > And I'd like to be able to have underscores in my control names, > since the compiler allows them anyway, they're valid in all the > other Gambas identifiers, and they're so common in VB apps ;) I activate it in the svn, but maybe it will break some things in autocompletion. You will tell me! :-) Regards; -- Benoit Minisini From James.Hatridge at ...17... Wed Oct 25 17:52:16 2006 From: James.Hatridge at ...17... (James Hatridge) Date: Wed, 25 Oct 2006 17:52:16 +0200 Subject: [Gambas-user] First program -- Kmeasures Message-ID: <200610251752.17051.James.Hatridge@...17...> Hi all To learn gambas I did this program. My wife is always asking how many miles to the km or F? to C?, so I wrote this. Let me know what you all think. JIM -- Jim Hatridge Here I stand. I can do no other. Linux User #88484 ------------------------------------------------------ WartHog Bulletin Info about new German Stamps http://www.fuzzybunnymilitia.org/~hatridge/bulletin/index.php Viel Feind -- Viel Ehr' Anti-US Propaganda stamp collection http://www.fuzzybunnymilitia.org/~hatridge/collection/index.php -------------- next part -------------- A non-text attachment was scrubbed... Name: Kmeasures-0.0.7.tar.tar.gz Type: application/x-tgz Size: 21797 bytes Desc: not available URL: From pierre.guilhem at ...1282... Thu Oct 26 12:21:17 2006 From: pierre.guilhem at ...1282... (Pierre GUILHEM) Date: Thu, 26 Oct 2006 12:21:17 +0200 Subject: [Gambas-user] network info Message-ID: <200610261221.17691.pierre.guilhem@...1282...> hello, is it possible with gamba to program a summary sniffer able of to break up a package TCP/IP or udp/ip in order to post the contents of each one fields heading made up of the three protocols, is ARP+IP+TCP or ARP+IP+UDP? So yes which functions have I to use? always so yes with which version of gamba 1 or 2? thank you. Pierre GUILHEM. From buxaman at ...626... Thu Oct 26 15:14:36 2006 From: buxaman at ...626... (Fabricio Silva) Date: Thu, 26 Oct 2006 11:14:36 -0200 Subject: [Gambas-user] Can't exec an sql string In-Reply-To: <200610232048.26056.gambas@...1...> References: <200610232048.26056.gambas@...1...> Message-ID: I was trying this when saving data: txtprice.Text = Replace$(txtprice.Text, ",", ".") then executing the sql to save. ok. So when the user types 1,25 it's saves 1.25 into a float type field. Perfect. But my problem is when showing the saved data. I tryed a tableview. =============================================== PUBLIC SUB show_data() DIM sql AS String WITH tbvcadprodutos .rows.count = 0 .columns.count = 4 .columns[0].text = "C?digo" .columns[0].Width = 50 .columns[1].text = "Descri??o" .columns[1].Width = 250 .Columns[2].Text = "Quantidade" .columns[2].Width = 80 .columns[3].text = "Pre?o" .columns[3].Width = 70 END WITH sql = "SELECT codigo, descricao, quantidade, preco FROM `produto` ORDER BY `codigo` ASC" global.preencher(tbvcadprodutos, sql) ===================================================== Procedure preencher ===================================================== PUBLIC SUB preencher(tbv AS tableview, qry AS String) DIM i AS Integer i = 0 rs1 = db.exec(qry) DO WHILE i <= rs1.Fields.Count tbv.rows.count = 0 IF rs1.count <> 0 THEN tbv.columns.count = rs1.fields.count tbv.rows.count = rs1.count END IF i = i + 1 rs1.MoveNext LOOP END ======================================================== and to show the data ======================================================== PUBLIC SUB tbvcadprodutos_Data(Row AS Integer, Column AS Integer) arrtable[0] = "codigo" arrtable[1] = "descricao" arrtable[2] = "quantidade" arrtable[3] = "preco" global.rs1.MoveTo(Row) tbvcadprodutos.data.Text = Str(global.rs1[arrtable[Column]]) END ================================================== And the 'preco' values are shown wrongly. 34,00 typed by the user is displayed 34. and 89,56 is displayed 89.56. So I tried another way of showing the data: tbvcadprodutos.data.Text = Format(global.rs1[arrtable[Column]], "#.00") "Type mismatch: Wanted Float got String instead" error appears. =================================================== I'm stuck in this. I tryed datasource and databrowser pair too... but I can't manipulated this can I? Plz help me out in this. I'm desesperated. :) Best Reards Fabricio From olinux at ...289... Thu Oct 26 15:48:19 2006 From: olinux at ...289... (olinux) Date: Thu, 26 Oct 2006 15:48:19 +0200 Subject: [Gambas-user] enumerate treeview items Message-ID: <4540BCA3.3070006@...289...> Is somebody to know how to enumerate items in a treeview like for each loop ???? regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.11/497 - Release Date: 25/10/2006 From j0e at ...103... Fri Oct 27 02:46:20 2006 From: j0e at ...103... (jum) Date: Thu, 26 Oct 2006 20:46:20 -0400 Subject: [Gambas-user] Window problem? In-Reply-To: References: Message-ID: <200610262046.21086.j0e@...103...> Hi all, hi Benoit! For a long time, I am not touch my computer because of my mom got sick (Stroke) and I should take care of her until now. When I have some time to download new release of Gambas(1.9.44) I am amazed with the new Interface. But my problem is when I run my project it always error.After I trace down, the problem can be raise with this following code: SUB Main() windo AS Object windo = NEW Window windo.move(0,0,800,600) windo.Show END The program stopped at Windo.move and Raise an error (Got Signal 11?). Is there any change for this command or this is a gambas bug? The Last version I use 1.9.32 (Quantum leap, eh). Currently I will try to use 1.9.41 (Least version I can download),may be I can report it if I have some time. Regards, L.Jumadi From gambas at ...1... Thu Oct 26 18:48:41 2006 From: gambas at ...1... (Benoit Minisini) Date: Thu, 26 Oct 2006 18:48:41 +0200 Subject: [Gambas-user] Window problem? In-Reply-To: <200610262046.21086.j0e@...103...> References: <200610262046.21086.j0e@...103...> Message-ID: <200610261848.41306.gambas@...1...> On Friday 27 October 2006 02:46, jum wrote: > Hi all, hi Benoit! > > For a long time, I am not touch my computer because of my mom got sick > (Stroke) and I should take care of her until now. > When I have some time to download new release of Gambas(1.9.44) I am amazed > with the new Interface. But my problem is when I run my project it always > error.After I trace down, the problem can be raise with this following > code: > > SUB Main() > windo AS Object > windo = NEW Window > windo.move(0,0,800,600) > windo.Show > END > > The program stopped at Windo.move and Raise an error (Got Signal 11?). > Is there any change for this command or this is a gambas bug? > The Last version I use 1.9.32 (Quantum leap, eh). Currently I will try to > use 1.9.41 (Least version I can download),may be I can report it if I have > some time. > > Regards, > > L.Jumadi > Please upgrade to the newer release possible, and tell me if you have the problem yet. Regards, -- Benoit Minisini From gambas at ...1... Thu Oct 26 18:49:07 2006 From: gambas at ...1... (Benoit Minisini) Date: Thu, 26 Oct 2006 18:49:07 +0200 Subject: [Gambas-user] enumerate treeview items In-Reply-To: <4540BCA3.3070006@...289...> References: <4540BCA3.3070006@...289...> Message-ID: <200610261849.07771.gambas@...1...> On Thursday 26 October 2006 15:48, olinux wrote: > Is somebody to know how to enumerate items in a treeview like for each > loop ???? > > > regards > Olivier Coquet It is not possible at the moment. You must use the Move*() methods. Regards, -- Benoit Minisini From gambas at ...1... Thu Oct 26 18:50:07 2006 From: gambas at ...1... (Benoit Minisini) Date: Thu, 26 Oct 2006 18:50:07 +0200 Subject: [Gambas-user] network info In-Reply-To: <200610261221.17691.pierre.guilhem@...1282...> References: <200610261221.17691.pierre.guilhem@...1282...> Message-ID: <200610261850.07532.gambas@...1...> On Thursday 26 October 2006 12:21, Pierre GUILHEM wrote: > hello, is it possible with gamba to program a summary sniffer able of to > break up a package TCP/IP or udp/ip in order to post the contents of each > one fields heading made up of the three protocols, is ARP+IP+TCP or > ARP+IP+UDP? > > So yes which functions have I to use? > always so yes with which version of gamba 1 or 2? > > thank you. > > Pierre GUILHEM. > Good question. I don't think so, because I think sniffing packet requires special sockets. Maybe it is possible to enhance the gb.net command so that it provides the needed options... -- Benoit Minisini From gambas at ...1... Thu Oct 26 18:56:32 2006 From: gambas at ...1... (Benoit Minisini) Date: Thu, 26 Oct 2006 18:56:32 +0200 Subject: [Gambas-user] Can't exec an sql string In-Reply-To: References: <200610232048.26056.gambas@...1...> Message-ID: <200610261856.32897.gambas@...1...> On Thursday 26 October 2006 15:14, Fabricio Silva wrote: > I was trying this when saving data: > > txtprice.Text = Replace$(txtprice.Text, ",", ".") > then executing the sql to save. ok. > So when the user types 1,25 it's saves 1.25 into a float type field. > Perfect. > > But my problem is when showing the saved data. I tryed a tableview. > =============================================== > PUBLIC SUB show_data() > DIM sql AS String > WITH tbvcadprodutos > .rows.count = 0 > .columns.count = 4 > .columns[0].text = "C?digo" > .columns[0].Width = 50 > .columns[1].text = "Descri??o" > .columns[1].Width = 250 > .Columns[2].Text = "Quantidade" > .columns[2].Width = 80 > .columns[3].text = "Pre?o" > .columns[3].Width = 70 > > END WITH > sql = "SELECT codigo, descricao, quantidade, preco FROM `produto` ORDER > BY `codigo` ASC" > global.preencher(tbvcadprodutos, sql) > > ===================================================== > Procedure preencher > ===================================================== > PUBLIC SUB preencher(tbv AS tableview, qry AS String) > DIM i AS Integer > i = 0 > rs1 = db.exec(qry) > DO WHILE i <= rs1.Fields.Count > tbv.rows.count = 0 > IF rs1.count <> 0 THEN > tbv.columns.count = rs1.fields.count > tbv.rows.count = rs1.count > END IF > i = i + 1 > rs1.MoveNext > LOOP > END > ======================================================== > and to show the data > ======================================================== > PUBLIC SUB tbvcadprodutos_Data(Row AS Integer, Column AS Integer) > > arrtable[0] = "codigo" > arrtable[1] = "descricao" > arrtable[2] = "quantidade" > arrtable[3] = "preco" > global.rs1.MoveTo(Row) > > tbvcadprodutos.data.Text = Str(global.rs1[arrtable[Column]]) > > END > ================================================== > > And the 'preco' values are shown wrongly. > 34,00 typed by the user is displayed 34. > and 89,56 is displayed 89.56. > > So I tried another way of showing the data: > > tbvcadprodutos.data.Text = Format(global.rs1[arrtable[Column]], "#.00") > > "Type mismatch: Wanted Float got String instead" error appears. > =================================================== > > I'm stuck in this. I tryed datasource and databrowser pair too... but I > can't manipulated this can I? > > Plz help me out in this. I'm desesperated. :) > > Best Reards > > Fabricio You are putting numeric values inside a database string field. So Gambas automatically converts the numeric value into a string by using the CStr() function. CStr() uses US localization. Then, when you fill your TableView, you get a string from the database: the result of CStr() applied to the number you wanted to store. And of course, if you use Format(), the function complains because it gets a string instead of a floating point value. There are two solutions: 1) Using a database numeric field, and Str() or Format() to convert the value in TableView_Data. 2) Keeping with your string field, but then you must use Str() or Format() to store the data (so that you use your localization, not the US one). Then you display the data in TableView_Data as it is stored. Regards, -- Benoit Minisini From sourceforge-raindog2 at ...94... Thu Oct 26 19:06:56 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Thu, 26 Oct 2006 13:06:56 -0400 Subject: [Gambas-user] network info In-Reply-To: <200610261850.07532.gambas@...1...> References: <200610261221.17691.pierre.guilhem@...1282...> <200610261850.07532.gambas@...1...> Message-ID: <200610261306.56821.sourceforge-raindog2@...94...> On Thursday 26 October 2006 12:50, Benoit Minisini wrote: > Good question. I don't think so, because I think sniffing > packet requires special sockets. Maybe it is possible to > enhance the gb.net command so that it provides the needed > options... I personally would shell out to a program already designed to do this sort of thing, like ethereal or plain old tcpdump or something like that, and use Gambas to parse and report on the output.... This is Unix, not Windows.... there are more ways to reuse code than just API calls or components. I think you'll find that even graphical sniffer programs written in C or C++ run these tools over a pipe rather than reinventing the wheel. Ditto with CD/DVD burning... I'm sure I'm not the only one who's written specialized burning front ends in Gambas, but no one has asked if it's possible to write a cdrecord replacement in Gambas itself. Rob From brian at ...1334... Thu Oct 26 21:09:59 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 26 Oct 2006 12:09:59 -0700 (PDT) Subject: [Gambas-user] Object names Message-ID: <20061026120606.Y95103@...1337...> Say I have a Form with a control, say a textbox that happens to be called TextBox1 Now say I have a function of the form: PUBLIC SUB SomeSub(client as Control) ... END Is there any way to find out the client's name (eg: TextBox1)? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Thu Oct 26 21:14:32 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 26 Oct 2006 12:14:32 -0700 (PDT) Subject: [Gambas-user] enumerate treeview items In-Reply-To: <4540BCA3.3070006@...289...> References: <4540BCA3.3070006@...289...> Message-ID: <20061026121031.J95289@...1337...> On Thu, 26 Oct 2006, olinux wrote: > Is somebody to know how to enumerate items in a treeview like for each > loop ???? > > > regards > Olivier Coquet I just got the brainstorm to make a class to do this. Basically you'd create the iterator class with NEW, specifying the client TreeView, observer object and callback prefix. Then you'd call tvIterObject.ForEach() and the callback on the observer object will be notified of Begin, Visit (for each treeview item visited) and Done There's some complexities in making it of general use but I'm working on it. When it works and I get the bugs out I'll post the code. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From Karl.Reinl at ...9... Fri Oct 27 00:15:42 2006 From: Karl.Reinl at ...9... (Charlie Reinl) Date: Fri, 27 Oct 2006 00:15:42 +0200 Subject: [Gambas-user] Object names In-Reply-To: <20061026120606.Y95103@...1337...> References: <20061026120606.Y95103@...1337...> Message-ID: <1161900943.5501.7.camel@...40...> Am Donnerstag, den 26.10.2006, 12:09 -0700 schrieb Christopher Brian Jack: > Say I have a Form with a control, say a textbox that happens to be called > TextBox1 > > Now say I have a function of the form: > > PUBLIC SUB SomeSub(client as Control) > > ... > > END > > Is there any way to find out the client's name (eg: TextBox1)? > Salut, dit you think about something like that ? this is MEditorColors.module ' Gambas module file CONST myGotFocusColor AS Integer = &HAAFF7F& CONST myLostFocusColor AS Integer = &HF9F9BD& PUBLIC SUB SetEditColor(oObj AS Object, objLast AS Control) DIM myControl AS String DIM hClass AS Control DIM hCont AS Container myControl = Object.Class(objLast) FOR EACH hClass IN oObj.Children ' is it like my LAST ? IF Object.Class(hClass) = myControl THEN ' only for debugging 'PRINT Object.Class(hClass) & " LAST.TAG = " & objLast.Tag & " hClass.Tag = " & hClass.Tag IF objLast.Tag = hClass.Tag THEN hClass.Background = myGotFocusColor ELSE hClass.Background = myLostFocusColor ENDIF ELSE ' TRY if it is a Container TRY hCont = hClass IF NOT ERROR THEN ' I call my self to find out if there are Cildren like my LAST SetEditColor(hClass, objLast) ENDIF ENDIF NEXT END this is called by : Public SUB Col_GotFocus() MEditorColors.SetEditColor(ME, LAST) END May be that gives you an Idea. (It came from gambas1) Amicalment Charlie From brian at ...1334... Fri Oct 27 01:27:43 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 26 Oct 2006 16:27:43 -0700 (PDT) Subject: [Gambas-user] Object names In-Reply-To: <1161900943.5501.7.camel@...40...> References: <20061026120606.Y95103@...1337...> <1161900943.5501.7.camel@...40...> Message-ID: <20061026155946.S96062@...1337...> What I'm looking for is, given any particular Control (passed as client to the SUB in my example), I'd like to get the name that it was given in the designer (as per my example of passing the textbox on the form to SomeSub and inside SomeSub being able to find out that the control now referenced by the client parameter to SomeSub is called "TextBox1"). I know I can find out what kind of object it is with the Object static class (in this example: "TextBox") but I'm unsure about how to find the object's name ("TextBox1" or "RazzleDazzle" if it was so named in the Form Designer). Unless I'm misunderstanding it, the code below appears to be solving a different problem. The code looks more like a way to recursively access the contents of a form. So try this again: Make a form with Button. I'll go into the designer and change it from "PushButton1" or whatever default I get and change it to "RazzleDazzle" and just to further unambiguate I'll make the Text property "Something Else Altogether" and the Tag "TheseArentTheDroidsYourLookingFor" Now the sub(s): PUBLIC SUB GetControlName(client as Control) as String DIM sName as String sName=?????????? what do I need here ?????????? return sName END SUB Somewhere else in the code: PUBLIC SUB RazzleDazzle_Click() DIM who AS VARIANT=LAST PRINT Object.Class(who) PRINT GetControlName(who) END Clicking the textbox should put in the console the output: TextBox RazzleDazzle The Form should be displaying "Something Else Altogether" in the TextBox when run. On Fri, 27 Oct 2006, Charlie Reinl wrote: > > Am Donnerstag, den 26.10.2006, 12:09 -0700 schrieb Christopher Brian > Jack: > > Say I have a Form with a control, say a textbox that happens to be called > > TextBox1 > > > > Now say I have a function of the form: > > > > PUBLIC SUB SomeSub(client as Control) > > > > ... > > > > END > > > > Is there any way to find out the client's name (eg: TextBox1)? > > > Salut, > > dit you think about something like that ? > > this is MEditorColors.module > > ' Gambas module file > CONST myGotFocusColor AS Integer = &HAAFF7F& > CONST myLostFocusColor AS Integer = &HF9F9BD& > PUBLIC SUB SetEditColor(oObj AS Object, objLast AS Control) > DIM myControl AS String > DIM hClass AS Control > DIM hCont AS Container > myControl = Object.Class(objLast) > FOR EACH hClass IN oObj.Children > ' is it like my LAST ? > IF Object.Class(hClass) = myControl THEN > ' only for debugging > 'PRINT Object.Class(hClass) & " LAST.TAG = " & objLast.Tag > & " hClass.Tag = " & hClass.Tag > IF objLast.Tag = hClass.Tag THEN > hClass.Background = myGotFocusColor > ELSE > hClass.Background = myLostFocusColor > ENDIF > ELSE > ' TRY if it is a Container > TRY hCont = hClass > IF NOT ERROR THEN > ' I call my self to find out if there are Cildren like my > LAST > SetEditColor(hClass, objLast) > ENDIF > ENDIF > NEXT > END > > > this is called by : > > Public SUB Col_GotFocus() > MEditorColors.SetEditColor(ME, LAST) > END > > May be that gives you an Idea. (It came from gambas1) .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Fri Oct 27 01:31:45 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Thu, 26 Oct 2006 16:31:45 -0700 (PDT) Subject: [Gambas-user] Object names In-Reply-To: <20061026155946.S96062@...1337...> References: <20061026120606.Y95103@...1337...> <1161900943.5501.7.camel@...40...> <20061026155946.S96062@...1337...> Message-ID: <20061026162939.O96231@...1337...> On Thu, 26 Oct 2006, Christopher Brian Jack wrote: > Clicking the textbox should put in the console the output: > TextBox ^^^^^^^^^^---> PushButton > RazzleDazzle > The Form should be displaying "Something Else Altogether" in the > TextBox --^^^^^^^----> PushButton > when run. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From sourceforge-raindog2 at ...94... Fri Oct 27 09:49:59 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Fri, 27 Oct 2006 03:49:59 -0400 Subject: [Gambas-user] new name for proposed "gb.ajax" Message-ID: <200610270349.59565.sourceforge-raindog2@...94...> I think it's going to end up being "gb.dojo". Dojo is still new (version 0.4 just came out), and the documentation is about at the point where Gambas was at its own 0.4 release (not much of it), but its API almost seems like a minimal Gtk sort of thing: http://dojotoolkit.org/api/?#dojo.widget And they're addressing some of the concerns people had with adapting Gambas apps to the web, like having to send huge lists of data down to the browser for data-bound combo boxes: http://manual.dojotoolkit.org/WikiHome/DojoDotBook/Book44/Book79 You can do all the buzzword-compliant stuff like JSON and XMLHttp and XMLRPC, or you can even use Iframes to send data back and forth for old, busted browsers. (Been there, done that.... you don't want to do that unless you really have to.) I get the sense that it's not what you would call lightweight, but I've never seen any Javascript framework that was this complete or desktop-like before. I look forward to trying it out as soon as I free up some time. Of course, you could use dojo by itself in your Gambas CGI applications already, if you wanted to ;) Rob From rospolosco at ...152... Fri Oct 27 16:30:02 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Fri, 27 Oct 2006 16:30:02 +0200 Subject: [Gambas-user] about Application.Args Message-ID: <200610271630.03015.rospolosco@...152...> Hi, Benoit. In the online help I read: Application.Args Returns an array containing the arguments passed to the program by the shell. I expect this works like bash script, but Application.Args returns even the name of the application, which in my opinion is not a passed argument. Application.Args.Count returns number of arguments + 1, because of the application name. Is it a feature or bug? I think is more logical that arguments don't count the name of the application. Anyway, the help should be modified: Application.Args Returns an array containing the application name and the arguments passed to the program by the shell. Best regards, Stefano Palmeri From sourceforge-raindog2 at ...94... Fri Oct 27 18:29:57 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Fri, 27 Oct 2006 12:29:57 -0400 Subject: [Gambas-user] about Application.Args In-Reply-To: <200610271630.03015.rospolosco@...152...> References: <200610271630.03015.rospolosco@...152...> Message-ID: <200610271229.57236.sourceforge-raindog2@...94...> On Friday 27 October 2006 10:30, Stefano Palmeri wrote: > Application.Args.Count returns number of arguments + 1, > because of the application name. Is it a feature or bug? I > think is more logical that arguments don't count the name of > the application. Having the arguments include the application name is "the C way" of doing things. Java and Perl omit the application name. I personally expected it to behave as it does, but I can understand why it would be confusing. The reason C does it that way is because you can have a single executable with multiple symbolic links to it, and have it do different things depending on what name the user ran it under. For example, gzip and gunzip are the same program, but behave differently depending on which one you run. So there needs to be a way to get the actual name of the program, and the name under which the user ran it. There's no reason to prevent Gambas programs from using this kind of functionality. I have also seen programs behave differently if you called them with an absolute path versus just the name of the program by itself.... gbx used to be one of those programs, in fact. Again, that's user-supplied data and, in my opinion and 38 years of C tradition, belongs in the arguments. Of course, BASIC isn't C, but I think Gambas is something beyond BASIC. > Anyway, the help should be modified: > Application.Args > Returns an array containing the application name and the > arguments passed to the program by the shell. I'd add a note mentioning that the first argument is always the name of the program. In fact, I just did. Rob From rospolosco at ...152... Fri Oct 27 18:59:26 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Fri, 27 Oct 2006 18:59:26 +0200 Subject: [Gambas-user] about Application.Args In-Reply-To: <200610271229.57236.sourceforge-raindog2@...94...> References: <200610271630.03015.rospolosco@...152...> <200610271229.57236.sourceforge-raindog2@...94...> Message-ID: <200610271859.26113.rospolosco@...152...> Alle 18:29, venerd? 27 ottobre 2006, Rob ha scritto: > On Friday 27 October 2006 10:30, Stefano Palmeri wrote: > > Application.Args.Count returns number of arguments + 1, > > because of the application name. Is it a feature or bug? I > > think is more logical that arguments don't count the name of > > the application. > > Having the arguments include the application name is "the C way" > of doing things. Java and Perl omit the application name. I > personally expected it to behave as it does, but I can > understand why it would be confusing. > > The reason C does it that way is because you can have a single > executable with multiple symbolic links to it, and have it do > different things depending on what name the user ran it under. > For example, gzip and gunzip are the same program, but behave > differently depending on which one you run. So there needs to > be a way to get the actual name of the program, and the name > under which the user ran it. There's no reason to prevent Gambas > programs from using this kind of functionality. > > I have also seen programs behave differently if you called them > with an absolute path versus just the name of the program by > itself.... gbx used to be one of those programs, in fact. > Again, that's user-supplied data and, in my opinion and 38 years > of C tradition, belongs in the arguments. Of course, BASIC > isn't C, but I think Gambas is something beyond BASIC. > > > Anyway, the help should be modified: > > Application.Args > > Returns an array containing the application name and the > > arguments passed to the program by the shell. > > I'd add a note mentioning that the first argument is always the > name of the program. In fact, I just did. > > Rob Thanks for very clear, quick reply. The note in the help is what no C developers (like me) need. Thanks. Regards, Stefano Palmeri > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From olinux at ...289... Fri Oct 27 20:11:45 2006 From: olinux at ...289... (olinux) Date: Fri, 27 Oct 2006 20:11:45 +0200 Subject: [Gambas-user] wait and stack overflow Message-ID: <45424BE1.2080608@...289...> Is somebody can explain me why: while toto<>0 wait whend generate a stack overflow ???? about 1150 it?ration with the default stack & about 25000 it?ration with a 256k stack and if it's a fatality, how can i setup a stack > 256k for application? regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.14/501 - Release Date: 26/10/2006 From rospolosco at ...152... Fri Oct 27 20:56:15 2006 From: rospolosco at ...152... (Stefano Palmeri) Date: Fri, 27 Oct 2006 20:56:15 +0200 Subject: [Gambas-user] First program -- Kmeasures In-Reply-To: <200610251752.17051.James.Hatridge@...17...> References: <200610251752.17051.James.Hatridge@...17...> Message-ID: <200610272056.15532.rospolosco@...152...> Alle 17:52, mercoled? 25 ottobre 2006, James Hatridge ha scritto: > Hi all > > To learn gambas I did this program. My wife is always asking how many miles to > the km or F? to C?, so I wrote this. Let me know what you all think. > > JIM > -- Nice app. Little bug: you wrote "Italien" instead of "Italian". Stefano > Jim Hatridge > Here I stand. I can do no other. > Linux User #88484 > ------------------------------------------------------ > WartHog Bulletin > Info about new German Stamps > http://www.fuzzybunnymilitia.org/~hatridge/bulletin/index.php > > Viel Feind -- Viel Ehr' > Anti-US Propaganda stamp collection > http://www.fuzzybunnymilitia.org/~hatridge/collection/index.php > From sourceforge-raindog2 at ...94... Fri Oct 27 21:18:37 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Fri, 27 Oct 2006 15:18:37 -0400 Subject: [Gambas-user] wait and stack overflow In-Reply-To: <45424BE1.2080608@...289...> References: <45424BE1.2080608@...289...> Message-ID: <200610271518.38361.sourceforge-raindog2@...94...> On Friday 27 October 2006 14:11, olinux wrote: > Is somebody can explain me why: > while toto<>0 > wait > whend > generate a stack overflow ???? Because it's an infinite loop and every time the "wait" executes, the interpreter adds a context to the stack. So if it's in some event handler that gets called during the wait, e.g. in a timer, you end up with 25,000 copies of that event handler on the stack. Can't really be any more specific without seeing the project. Rob From gambas at ...1... Fri Oct 27 21:24:54 2006 From: gambas at ...1... (Benoit Minisini) Date: Fri, 27 Oct 2006 21:24:54 +0200 Subject: [Gambas-user] wait and stack overflow In-Reply-To: <200610271518.38361.sourceforge-raindog2@...94...> References: <45424BE1.2080608@...289...> <200610271518.38361.sourceforge-raindog2@...94...> Message-ID: <200610272124.55185.gambas@...1...> On Friday 27 October 2006 21:18, Rob wrote: > On Friday 27 October 2006 14:11, olinux wrote: > > Is somebody can explain me why: > > while toto<>0 > > wait > > whend > > generate a stack overflow ???? > > Because it's an infinite loop and every time the "wait" executes, > the interpreter adds a context to the stack. So if it's in some > event handler that gets called during the wait, e.g. in a timer, > you end up with 25,000 copies of that event handler on the > stack. > > Can't really be any more specific without seeing the project. > > Rob > This loop works without any problem, unless there *is* an infinite recursion. That means that WAIT calls an event handler that calls your loop again. Just trace your program to detect it. If this is not the case, then it is a bug in the interpreter. Just tell your version of gambas you use then. Regards, -- Benoit Minisini From Karl.Reinl at ...9... Sat Oct 28 00:32:09 2006 From: Karl.Reinl at ...9... (Charlie Reinl) Date: Sat, 28 Oct 2006 00:32:09 +0200 Subject: [Gambas-user] porting gambasEditor from gambas1 to gambas2-1.9.x (> 21) Message-ID: <1161988330.17820.16.camel@...40...> Salut, porteted a project writen on gambas1 to gambas2-1.9.44. One Form had an Editor (called at gambas1 GambasEditor) All seams OK, but the form called, finished by an #11. When I came to the idea, that it could be the Editor, at the toolbox the editor was named 'GambasEditor',but reading the ChangeLog, a 'GambasEditor' dosn't exist anymore since about gambas2-1.9.31. While compiling the project ... no ERROR. Only deleting the Editor on the form, and replace it with the still called 'GambasEditor' from the toolbox,solved the problem. In both . No more #11 and the Editor in the toolbox was nemed 'Editor' Seams that the new 'Editor' , first tells gambas2 'everything's OK', even if it is the old 'GambasEditor'. Was a hard piece of work. Amicalment Charlie From brian at ...1334... Sat Oct 28 00:50:55 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Fri, 27 Oct 2006 15:50:55 -0700 (PDT) Subject: [Gambas-user] Gambas 1.9.44+ IDE and CVS Message-ID: <20061027153432.A2026@...1337...> Has anyone considered a component or otherwise to make projects CVS-aware, CVS-friendly and perhaps even do the appropriate operations (such as commits when modifying project files (or creating new files like forms, classes, modules, images, etc, or doing an update operation when the project is loaded and optionally at any time from the ide from a toolbar button and/or menu option). Basically the IDE would like for the CVS/CVSROOT dirs when opening a project and (a) hide these directories in the project fileview on the left pane and (b) enable options for cvs management and automatically handling some of the repository-helpful-but-often-overlooked functions like lock/edit/unlock (helps avoid conflicts) (c) provide a RCSEditorView which would be a special application of GambasEditor with awareness of the RCS tags when a conflict does arise. For jointly developed Gambas applications this would be a definite plus. I suppose subversion support should be added as well but I have no idea about how svn works, only cvs. I also don't know anything about how to properly make components to extend the IDE (nor if such a mechanism even exists). .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Sat Oct 28 00:53:44 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Fri, 27 Oct 2006 15:53:44 -0700 (PDT) Subject: [Gambas-user] Gambas 1.9.44+ IDE and CVS In-Reply-To: <20061027153432.A2026@...1337...> References: <20061027153432.A2026@...1337...> Message-ID: <20061027155213.I2099@...1337...> On Fri, 27 Oct 2006, Christopher Brian Jack wrote: Currently the IDE does some CVS directory bashing under .gambas when compiling projects to run the code. At the minimum it would be nice to have the IDE detect these diredctories and not to delete them. > Date: Fri, 27 Oct 2006 15:50:55 -0700 (PDT) > From: Christopher Brian Jack > To: Gambas-Users List > Subject: Gambas 1.9.44+ IDE and CVS > > > Has anyone considered a component or otherwise to make projects CVS-aware, > CVS-friendly and perhaps even do the appropriate operations (such as > commits when modifying project files (or creating new files like forms, > classes, modules, images, etc, or doing an update operation when the > project is loaded and optionally at any time from the ide from a toolbar > button and/or menu option). > > Basically the IDE would like for the CVS/CVSROOT dirs when opening a > project and (a) hide these directories in the project fileview on the left > pane and (b) enable options for cvs management and automatically handling > some of the repository-helpful-but-often-overlooked functions like > lock/edit/unlock (helps avoid conflicts) (c) provide a RCSEditorView which > would be a special application of GambasEditor with awareness of the RCS > tags when a conflict does arise. > > For jointly developed Gambas applications this would be a definite plus. > I suppose subversion support should be added as well but I have no idea > about how svn works, only cvs. > > I also don't know anything about how to properly make components to extend > the IDE (nor if such a mechanism even exists). > > .=================================================. > | Christopher BRIAN Jack aka "Gau of the Veldt" | > +=================================================' > | oevna at ...1544... > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From olinux at ...289... Sat Oct 28 09:55:08 2006 From: olinux at ...289... (olinux) Date: Sat, 28 Oct 2006 09:55:08 +0200 Subject: [Gambas-user] wait and stack overflow In-Reply-To: <200610272124.55185.gambas@...1...> References: <45424BE1.2080608@...289...> <200610271518.38361.sourceforge-raindog2@...94...> <200610272124.55185.gambas@...1...> Message-ID: <45430CDC.8070906@...289...> here is the precise exemple: for i= 0 to fildir.count-1 prc=exec ["gtar", "-xvf","fichier source","-C", repdest,fichierextract[i]] for read as "rest" while prc.state = 1 wait wend next version gambas 1.9.44 regards Olivier Coquet Benoit Minisini a ?crit : > On Friday 27 October 2006 21:18, Rob wrote: > >> On Friday 27 October 2006 14:11, olinux wrote: >> >>> Is somebody can explain me why: >>> while toto<>0 >>> wait >>> whend >>> generate a stack overflow ???? >>> >> Because it's an infinite loop and every time the "wait" executes, >> the interpreter adds a context to the stack. So if it's in some >> event handler that gets called during the wait, e.g. in a timer, >> you end up with 25,000 copies of that event handler on the >> stack. >> >> Can't really be any more specific without seeing the project. >> >> Rob >> >> > > This loop works without any problem, unless there *is* an infinite recursion. > That means that WAIT calls an event handler that calls your loop again. Just > trace your program to detect it. > > If this is not the case, then it is a bug in the interpreter. Just tell your > version of gambas you use then. > > Regards, > > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From gambas at ...1... Sat Oct 28 10:46:45 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 10:46:45 +0200 Subject: [Gambas-user] Gambas 1.9.44+ IDE and CVS In-Reply-To: <20061027155213.I2099@...1337...> References: <20061027153432.A2026@...1337...> <20061027155213.I2099@...1337...> Message-ID: <200610281046.46159.gambas@...1...> On Saturday 28 October 2006 00:53, Christopher Brian Jack wrote: > On Fri, 27 Oct 2006, Christopher Brian Jack wrote: > > Currently the IDE does some CVS directory bashing under .gambas when > compiling projects to run the code. At the minimum it would be nice to > have the IDE detect these diredctories and not to delete them. > > > Date: Fri, 27 Oct 2006 15:50:55 -0700 (PDT) > > From: Christopher Brian Jack > > To: Gambas-Users List > > Subject: Gambas 1.9.44+ IDE and CVS > > > > > > Has anyone considered a component or otherwise to make projects > > CVS-aware, CVS-friendly and perhaps even do the appropriate operations > > (such as commits when modifying project files (or creating new files like > > forms, classes, modules, images, etc, or doing an update operation when > > the project is loaded and optionally at any time from the ide from a > > toolbar button and/or menu option). > > > > Basically the IDE would like for the CVS/CVSROOT dirs when opening a > > project and (a) hide these directories in the project fileview on the > > left pane and (b) enable options for cvs management and automatically > > handling some of the repository-helpful-but-often-overlooked functions > > like lock/edit/unlock (helps avoid conflicts) (c) provide a RCSEditorView > > which would be a special application of GambasEditor with awareness of > > the RCS tags when a conflict does arise. > > > > For jointly developed Gambas applications this would be a definite plus. > > I suppose subversion support should be added as well but I have no idea > > about how svn works, only cvs. > > > > I also don't know anything about how to properly make components to > > extend the IDE (nor if such a mechanism even exists). > > I'd like to do exactly the same thing for svn, as now I know svn but not CVS. I think we could do that together. But I don't want to go too far, as I'd like to freeze the 2.0 version as soon as possible. So I suggest continue doing the "update/commit/conflict solving" by hand at the moment. Here is the tasks we could do: 1) Automatically detect that a project is managed by CVS or SVN. Not difficult, as we just have to check there is a CVS or .svn directory in the project directory. 2) Not destroying these directories in any situation. 3) We must define each CVS or SVN command that must be run when: * A new file is added to the project. * A new directory is added to the project. * A file is removed. * A directory is removed. * A file is renamed. * A directory is renamed. 4) Which files must be controlled, and which not. I think the rule can be that once a project is cleaned up, all resting files should be controlled. So I could make a "import to CVS/SVN" command that clean up the project and run the import command. So please tell me, and send me all information on the developer mailing-list! Regards, -- Benoit Minisini From gambas at ...1... Sat Oct 28 10:51:18 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 10:51:18 +0200 Subject: [Gambas-user] Gambas 1.9.44+ IDE and CVS In-Reply-To: <20061027155213.I2099@...1337...> References: <20061027153432.A2026@...1337...> <20061027155213.I2099@...1337...> Message-ID: <200610281051.18384.gambas@...1...> On Saturday 28 October 2006 00:53, Christopher Brian Jack wrote: > On Fri, 27 Oct 2006, Christopher Brian Jack wrote: > > Currently the IDE does some CVS directory bashing under .gambas when > compiling projects to run the code. At the minimum it would be nice to > have the IDE detect these diredctories and not to delete them. > You are right, but actually files under .gambas should not go in the CVS repository, as they are generated. Regards, -- Benoit Minisini From olinux at ...289... Sat Oct 28 11:06:41 2006 From: olinux at ...289... (olinux) Date: Sat, 28 Oct 2006 11:06:41 +0200 Subject: [Gambas-user] wait and stack overflow In-Reply-To: <45430CDC.8070906@...289...> References: <45424BE1.2080608@...289...> <200610271518.38361.sourceforge-raindog2@...94...> <200610272124.55185.gambas@...1...> <45430CDC.8070906@...289...> Message-ID: <45431DA1.7050603@...289...> I have a possible start of answer... here is the complete code: public sub launchrst(......) for i= 0 to fildir.count-1 prc=exec ["gtar", "-xvf","fichier source","-C", repdest,fichierextract[i]] for read as "rest" while prc.state = 1 wait wend next endsub public sub rest_Read() dim sline as string line input #last, sline ..... .... print sline <================here is the start of answer end if i put a print in the read subroutine, all work fine if i don't put a print here, stack overflow is generated about 1200 read events this work with print to the console or print to a file opened. an idee ?????? regards Olivier Coquet olinux a ?crit : > here is the precise exemple: > > for i= 0 to fildir.count-1 > prc=exec ["gtar", "-xvf","fichier source","-C", repdest,fichierextract[i]] for read as "rest" > > while prc.state = 1 > wait > wend > next > > > > version gambas 1.9.44 > > > regards > Olivier Coquet > > > > Benoit Minisini a ?crit : > >> On Friday 27 October 2006 21:18, Rob wrote: >> >> >>> On Friday 27 October 2006 14:11, olinux wrote: >>> >>> >>>> Is somebody can explain me why: >>>> while toto<>0 >>>> wait >>>> whend >>>> generate a stack overflow ???? >>>> >>>> >>> Because it's an infinite loop and every time the "wait" executes, >>> the interpreter adds a context to the stack. So if it's in some >>> event handler that gets called during the wait, e.g. in a timer, >>> you end up with 25,000 copies of that event handler on the >>> stack. >>> >>> Can't really be any more specific without seeing the project. >>> >>> Rob >>> >>> >>> >> This loop works without any problem, unless there *is* an infinite recursion. >> That means that WAIT calls an event handler that calls your loop again. Just >> trace your program to detect it. >> >> If this is not the case, then it is a bug in the interpreter. Just tell your >> version of gambas you use then. >> >> Regards, >> >> >> > > > > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From gambas at ...1... Sat Oct 28 11:18:26 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 11:18:26 +0200 Subject: [Gambas-user] wait and stack overflow In-Reply-To: <45431DA1.7050603@...289...> References: <45424BE1.2080608@...289...> <45430CDC.8070906@...289...> <45431DA1.7050603@...289...> Message-ID: <200610281118.26528.gambas@...1...> On Saturday 28 October 2006 11:06, olinux wrote: > I have a possible start of answer... > here is the complete code: > > public sub launchrst(......) > for i= 0 to fildir.count-1 > prc=exec ["gtar", "-xvf","fichier source","-C", repdest,fichierextract[i]] > for read as "rest" > > while prc.state = 1 > wait > wend > next > endsub > > public sub rest_Read() > dim sline as string > > line input #last, sline > ..... > .... > > print sline <================here is the start of answer > > end > > > if i put a print in the read subroutine, all work fine > if i don't put a print here, stack overflow is generated about 1200 read > events > > this work with print to the console or print to a file opened. > > an idee ?????? > > regards > Olivier Coquet > Send your full source code please. Regards, -- Benoit Minisini From olinux at ...289... Sat Oct 28 11:31:08 2006 From: olinux at ...289... (olinux) Date: Sat, 28 Oct 2006 11:31:08 +0200 Subject: [Gambas-user] wait and stack overflow In-Reply-To: <200610281118.26528.gambas@...1...> References: <45424BE1.2080608@...289...> <45430CDC.8070906@...289...> <45431DA1.7050603@...289...> <200610281118.26528.gambas@...1...> Message-ID: <4543235C.2060803@...289...> here it is: module routines: ' Gambas module file PUBLIC actflnb AS Integer PUBLIC maxflnb AS Integer PUBLIC prc AS Process PUBLIC hfile AS File 'routine de restauration PUBLIC SUB GB_restaure(fildir AS String[], filsrc AS String, repdest AS String, maxfic AS Integer) DIM i AS Short actflnb = 0 maxflnb = maxfic GBackup.msgsysrst.Text = "Restauration en cours..." 'pour chaque s?lection ? restaurer FOR i = 0 TO fildir.Count - 1 prc = EXEC ["gtar", "-xvf", Left(filsrc, -4), "-C", repdest, Right(fildir[i], -1)] FOR READ AS "Rst" WHILE prc.state = 1 WAIT WEND NEXT END 'routine de lecture de commande restaure PUBLIC SUB Rst_Read() DIM sLine AS String LINE INPUT #LAST, sLine 'si pas un r?pertoire 'IF NOT IsDir(sLine) THEN 'INC actflnb 'GBackup.pgbr.Value = (1 / maxflnb) * actflnb PRINT sline END 'routine de backup simple PUBLIC SUB GB_norm_bkp(fildir AS String[], filedest AS String, maxfile AS Integer) DIM i AS Short actflnb = 0 maxflnb = maxfile 'cr?ation du fichier vide (g?n?re une erreur mais on ne la voit pas) EXEC ["gtar", "-cf", filedest, "null"] FOR READ hfile = OPEN filedest & ".bkf" FOR OUTPUT CREATE PRINT #hfile, maxfile 'pour chaque r?pertoire FOR i = 0 TO fildir.Count - 1 prc = EXEC ["gtar", "-rvf", filedest, fildir[i]] FOR READ AS "Bkp" 'ne sort de cette routine que quand la commande est arr?t?e WHILE prc.State = 1 WAIT WEND CLOSE #hfile NEXT END 'routine de lecture des ?v?nements de commande externe PUBLIC SUB Bkp_Read() DIM sLine AS String LINE INPUT #LAST, sLine 'si pas un r?pertoire 'IF NOT IsDir(sLine) THEN INC actflnb GBackup.pgb.Value = (1 / maxflnb) * actflnb GBackup.ficnbr.text = actflnb & " / " & maxflnb & " fichiers" PRINT #hfile, sLine 'ENDIF END 'routine de comptage des r?pertoires et fichiers PUBLIC SUB GB_dir(fildir AS String[]) AS Integer[] 'lecture d'une suite de r?pertoire avec les r?sultats DIM File AS String DIM I AS Integer DIM infos AS NEW Integer[] 'taille/nbre globals a sauvegarder infos.Add(0) infos.Add(0) FOR i = 0 TO fildir.Count - 1 FOR EACH File IN RDir(fildir[i]) 'si pas un r?pertoire 'IF NOT IsDir(File) THEN INC infos[0] 'ENDIF NEXT NEXT GBackup.ficnbr.text = "0 / " & CStr(infos[0]) & " fichiers" RETURN infos END and here is my main form: ' Gambas class file ' D??clarations des variables communes ? toute la classe PUBLIC varsrclst AS NEW String[] PUBLIC varrstlst AS NEW String[] PUBLIC strrstlst AS String PUBLIC idxsrclst AS Integer PUBLIC picselectnodir AS NEW Picture PUBLIC picselectyesdir AS NEW Picture PUBLIC maxfic AS Integer STATIC PUBLIC FUNCTION Run() AS Boolean DIM hForm AS Form hForm = NEW GBackup RETURN hForm.ShowModal() END PUBLIC SUB Form_Open() 'Initialisations diverses 'chemin de la racine du disque varsrclst.add("/") idxsrclst = 0 'images pour les r??pertoires ? lister picselectnodir = picture["selectnodir.png"] picselectyesdir = picture["selectyesdir.png"] 'Lance la premi??re lecture du r??pertoire SrcLst_Refresh(varsrclst[idxsrclst]) END PUBLIC SUB Quitter_Click() slpachquit.Show slpachquit.Center WAIT 0.1 ficlstsrc.clear slpachquit.Close(TRUE) ME.Close(TRUE) END PUBLIC SUB SrcLst_Refresh(rep AS String) DIM sFile AS String 'Routine de rafraichissement et de lecture des r??pertoires dans la treeview 'effacement de la liste srclst.Clear 'Racine du r??pertoire ? visualiser srclst.Add(rep, rep) 'Lecture du r??pertoire FOR EACH sFile IN Dir(rep) 'Si l'objet lu n'est pas invisible IF NOT Stat(rep & sFile).Hidden THEN ' si l'objet lu est un r??pertoire, met le devant avec un espace IF IsDir(rep & sFile) THEN srclst.Add(sFile, sFile, picselectnodir, rep) ELSE 'sinon met le derri??re sans espace 'srclst.Add(sFile, sFile, picfic, rep) ENDIF ENDIF NEXT 'afficher a plat tous le r??pertoire srclst.Current.Expanded = TRUE END PUBLIC SUB SrcLst_Click() 'bascule s??lection yes/no 'pas de bascule si racine IF srclst.Current.key <> varsrclst[idxsrclst] THEN IF srclst.Current.Picture = picselectnodir THEN Srclst.Current.Picture = picselectyesdir ELSE IF srclst.Current.Picture = picselectyesdir THEN Srclst.Current.Picture = picselectnodir ENDIF ENDIF END PUBLIC SUB SelectAll_Click() 's??lectionner tous srclst.MoveFirst WHILE NOT srclst.MoveBelow() srclst.item.Picture = picselectyesdir WEND END PUBLIC SUB DeSelectAll_Click() 'd??s??lectionner tous srclst.MoveFirst WHILE NOT srclst.MoveBelow() srclst.item.Picture = picselectnodir WEND END PUBLIC SUB SrcLst_DblClick() 'seulement si repertoire 'annule l'action click SrcLst_Click() 'changement de repertoire IF srclst.Current.key = varsrclst[idxsrclst] THEN 'sur racine 'mais pas si d??j? racine IF idxsrclst <> 0 THEN 'remonte d'un niveau dans l'arbo DEC idxsrclst varsrclst.Remove(idxsrclst + 1, 1) SrcLst_Refresh(varsrclst[idxsrclst]) ENDIF ELSE 'sur repertoire simple INC idxsrclst varsrclst.Add(varsrclst[idxsrclst - 1] & srclst.Current.key & "/") SrcLst_Refresh(varsrclst[idxsrclst]) ENDIF srclst.Current.Expanded = TRUE END PUBLIC SUB BtSelFic_Click() 'selection du fichier de destination dialog.path = "/" IF NOT dialog.SaveFile() THEN ficdest.text = dialog.path ENDIF END PUBLIC SUB BkpNow_Click() 'variable de liste des r??pertoires DIM lstrep AS NEW String[] 'variable d'information sur le backup 'idx=1 => nbre de fichier 'idx=2 => taille globale en octets DIM inforep AS NEW Integer[] DIM i AS Integer DIM hFile AS File 'cr??ation de la liste des r??pertoires s??lectionn??s srclst.MoveFirst 'infos utilisateur MsgSys.Text = "Liste fichiers..." WHILE NOT srclst.MoveBelow() IF srclst.item.Picture = picselectyesdir THEN lstrep.Add(varsrclst[idxsrclst] & srclst.Item.Text) ENDIF WEND 'cacul du nombre de fichiers (r??sultat dans inforep 0 et 1 inforep = routines.GB_dir(lstrep) maxfic = inforep[0] 'valeur progressbar = (1/maxfic)*valeuractuelle 'v??rification de l'existance d'un fichier backup destination IF ficdest.text <> "" THEN 'Lancement du backup en fonction du mode choisi IF Sglsel.Value = TRUE THEN 'mode backup simple 'le fichier existe-t-il d??j? ? TRY hfile = OPEN ficdest.text FOR READ IF NOT ERROR THEN i = message.Warning("Attention, le fichier de destination existe d??j? .\n Si vous continuez il va ??tre ??cras??.\n Souhaitez vous continuer?", "Oui", "Non") CLOSE #hfile IF i <> 2 THEN 'l'utilisateur confirme 'on lance la sauvegarde malgr??s tout MsgSys.Text = "Backup en cours..." routines.GB_norm_bkp(lstrep, ficdest.text, maxfic) ELSE 'l'utilisateur annule ficdest.text = "" ENDIF ELSE 'le fichier n'existe pas on peut lancer la sauvegarde MsgSys.Text = "Backup en cours..." routines.GB_norm_bkp(lstrep, ficdest.text, maxfic) ENDIF ELSE IF Incsel.Value = TRUE THEN 'mode backup incr??mentiel ELSE IF Cpysel.Value = TRUE THEN 'mode copie simple ENDIF ENDIF MsgSys.Text = "En attente..." END PUBLIC SUB selficsrc_Click() 'selection du fichier source dialog.path = "/" dialog.filter = ["*.bkf", "fichiers catalogues"] IF NOT dialog.OpenFile() THEN ficsrc.text = dialog.path refreshrest(dialog.path) ENDIF END PUBLIC SUB refreshrest(fpath AS String) DIM hrfile AS File DIM resline AS String DIM mxf AS Integer DIM actf AS Integer DIM acts AS String DIM linesplit AS NEW String[] DIM tmppath1 AS String DIM tmppath2 AS String DIM i AS Integer msgsysrst.text = "Catalogue en cours..." WAIT actf = 0 'efface la liste ficlstsrc.Clear 'ouvre le fichier catalogue en lecture hrfile = OPEN fpath FOR INPUT 'li la valeur maximale du nbr de fichiers LINE INPUT #hrfile, acts mxf = Val(acts) 'lire chaque ligne WHILE NOT Eof(hrfile) LINE INPUT #hrfile, resline 'mise a jour de la pb pgbr.Value = (1 / mxf) * actf INC actf 'separation des r??pertoires et fichiers dans la ligne linesplit = Split(resline, "/") 'mise en place dans le treeview avec arbo tmppath1 = "" tmppath2 = "" 'pour chaque ??l??ment du chemin FOR i = 1 TO (linesplit.count - 2) tmppath2 = tmppath1 tmppath1 = tmppath1 & "/" & linesplit[i] IF ficlstsrc.Exist(tmppath1) = FALSE THEN 'si la clef n'existe pas, la cr??er ficlstsrc.Add(tmppath1, linesplit[i], picselectnodir, tmppath2) ENDIF NEXT IF linesplit[linesplit.count - 1] <> "" THEN 'si c'est un fichier le cr??er ficlstsrc.Add(tmppath1 & "/" & linesplit[linesplit.count - 1], linesplit[linesplit.count - 1],, tmppath1) ENDIF WEND pgbr.value = 1 ficlstsrc.MoveFirst ficlstsrc.Current.Expanded = TRUE CLOSE #hrfile msgsysrst.text = "En attente..." pgbr.Value = 0 END PUBLIC SUB ficlstsrc_Click() 'bascule s??lection yes/no IF ficlstsrc.Current.Picture = picselectnodir THEN ficlstsrc.Current.Picture = picselectyesdir ELSE IF ficlstsrc.Current.Picture = picselectyesdir THEN ficlstsrc.Current.Picture = picselectnodir ENDIF END PUBLIC SUB selrepdstrst_Click() 'selection du repertoire de restauration destination dialog.path = "/" IF NOT dialog.SelectDirectory() THEN repdestdst.text = dialog.path ENDIF END PUBLIC SUB RestBtn_Click() DIM maxfil AS Integer 'processus de restauration suivant s??lection 'et comptage des fichiers a s??lectionner ficlstsrc.MoveFirst DO IF ficlstsrc.Item.Children <> 0 THEN maxfil += ficlstsrc.Item.Children ficlstsrc.Item.Expanded = TRUE 'cr??ation de la liste des s??lections IF ficlstsrc.Item.Picture = picselectyesdir THEN varrstlst.add(ficlstsrc.Item.Key & "/") ENDIF IF ficlstsrc.Item.Picture = picselectyesdir OR ficlstsrc.Item.Picture = picselectnodir THEN DEC maxfil ENDIF LOOP UNTIL ficlstsrc.MoveBelow() routines.GB_restaure(varrstlst, ficsrc.text, repdestdst.Text, maxfil) GBackup.msgsysrst.Text = "En attente..." END goof luck.....I programm like a pig....lol regards Olivier Coquet Benoit Minisini a ?crit : > On Saturday 28 October 2006 11:06, olinux wrote: > >> I have a possible start of answer... >> here is the complete code: >> >> public sub launchrst(......) >> for i= 0 to fildir.count-1 >> prc=exec ["gtar", "-xvf","fichier source","-C", repdest,fichierextract[i]] >> for read as "rest" >> >> while prc.state = 1 >> wait >> wend >> next >> endsub >> >> public sub rest_Read() >> dim sline as string >> >> line input #last, sline >> ..... >> .... >> >> print sline <================here is the start of answer >> >> end >> >> >> if i put a print in the read subroutine, all work fine >> if i don't put a print here, stack overflow is generated about 1200 read >> events >> >> this work with print to the console or print to a file opened. >> >> an idee ?????? >> >> regards >> Olivier Coquet >> >> > > Send your full source code please. > > Regards, > > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From gambas at ...1... Sat Oct 28 11:42:14 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 11:42:14 +0200 Subject: [Gambas-user] wait and stack overflow In-Reply-To: <4543235C.2060803@...289...> References: <45424BE1.2080608@...289...> <200610281118.26528.gambas@...1...> <4543235C.2060803@...289...> Message-ID: <200610281142.14225.gambas@...1...> On Saturday 28 October 2006 11:31, olinux wrote: > here it is: > > module routines: Please use the "make archive" menu entry in the Project menu so that I get the full project directory, and not just the source code. Regards, -- Benoit Minisini From olinux at ...289... Sat Oct 28 11:53:22 2006 From: olinux at ...289... (olinux) Date: Sat, 28 Oct 2006 11:53:22 +0200 Subject: [Gambas-user] wait and stack overflow In-Reply-To: <200610281142.14225.gambas@...1...> References: <45424BE1.2080608@...289...> <200610281118.26528.gambas@...1...> <4543235C.2060803@...289...> <200610281142.14225.gambas@...1...> Message-ID: <45432892.3010707@...289...> oups sorry here it is in attach regards Benoit Minisini a ?crit : > On Saturday 28 October 2006 11:31, olinux wrote: > >> here it is: >> >> module routines: >> > > Please use the "make archive" menu entry in the Project menu so that I get the > full project directory, and not just the source code. > > Regards, > > -------------- next part -------------- A non-text attachment was scrubbed... Name: GBackup-0.1.24.tar.gz Type: application/gzip Size: 12300 bytes Desc: not available URL: -------------- next part -------------- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From brian at ...1334... Sat Oct 28 14:10:09 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 05:10:09 -0700 (PDT) Subject: [Gambas-user] Gambas 1.9.44+ IDE and CVS In-Reply-To: <200610281051.18384.gambas@...1...> References: <20061027153432.A2026@...1337...> <20061027155213.I2099@...1337...> <200610281051.18384.gambas@...1...> Message-ID: <20061028050316.O4246@...1337...> On Sat, 28 Oct 2006, Benoit Minisini wrote: > On Saturday 28 October 2006 00:53, Christopher Brian Jack wrote: > > On Fri, 27 Oct 2006, Christopher Brian Jack wrote: > > > > Currently the IDE does some CVS directory bashing under .gambas when > > compiling projects to run the code. At the minimum it would be nice to > > have the IDE detect these diredctories and not to delete them. > You are right, but actually files under .gambas should not go in the CVS > repository, as they are generated. Indeed. The contents of .gambas are most likely a .cvsignore candidate but the directory stub must to be created or the project will not load in the IDE. I also discovered it is good to keep .directory and contents though in the event that the project's directory icon is altered. The IDE won't edit it but you can use a program like the GIMP to change the directory icon in .directory .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Sat Oct 28 14:38:34 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 05:38:34 -0700 (PDT) Subject: [Gambas-user] enumerate treeview items In-Reply-To: <4540BCA3.3070006@...289...> References: <4540BCA3.3070006@...289...> Message-ID: <20061028051132.K5878@...1337...> On Thu, 26 Oct 2006, olinux wrote: > Date: Thu, 26 Oct 2006 15:48:19 +0200 > From: olinux > Reply-To: mailing list for gambas users > > To: mailing list for gambas users > Subject: [Gambas-user] enumerate treeview items > > Is somebody to know how to enumerate items in a treeview like for each > loop ???? Okay I have created a class that will implement iteration on a TreeView object. The class file itself is simple enough to use. The class works by specifying a TreeView host, an observer (ME works good in most cases) and method basename (called on the observer as _next). This class could be generalized to iterate over other things like ListView and TableView but that is left as an exercise for anyone else. NB: I was not able to find a way to get the name of the host object only its type (TreeView in this case). So you cannot currently use single XXX_next method to observe iteration for more than one host (since there's no way to know which host object you are receiving notificaiton for). If the attachment comes through OK it includes a test form that uses the iterator and dumps the resulting output. The brief snippets below indicates the gist of using the class: 'We have a form containing a TreeView called tvTheTreeView PRIVATE tviTheTreeView AS CIterateTreeView PUBLIC SUB form_Open() tviTheTreeView=NEW CIterateTreeView(tvTheTreeView, ME, "tviMyIterator") ... END PUBLIC SUB form_Close() 'keep this in or you get problems with circular referencing tviTheTreeView=NULL END PUBLIC SUB tviMyIterator_next(hostob AS TreeView, key AS String, state AS Integer) SELECT state CASE CIterateTreeView.IterBegin 'called before iteration starts CASE CIterateTreeView.IterDone 'called after iteration is complete CASE CIterateTreeView.IterVisit 'called once for each .TreeViewItem visited 'you have to use the key arg since .TreeViewItem 'do not work for method parameter passing END SELECT END .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher -------------- next part -------------- A non-text attachment was scrubbed... Name: IterateTreeView.tar.bz2 Type: application/octet-stream Size: 38297 bytes Desc: IterateTreeView.tar.bz2 URL: From brian at ...1334... Sat Oct 28 14:42:55 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 05:42:55 -0700 (PDT) Subject: [Gambas-user] enumerate treeview items In-Reply-To: <20061028051132.K5878@...1337...> References: <4540BCA3.3070006@...289...> <20061028051132.K5878@...1337...> Message-ID: <20061028053946.R5878@...1337...> On Sat, 28 Oct 2006, Christopher Brian Jack wrote: In the snippet I forgot probably the most important part... Namely calling tviTheTreeView.ForEach() whereever you want to iterate the host TreeView in your code. > 'We have a form containing a TreeView called tvTheTreeView > PRIVATE tviTheTreeView AS CIterateTreeView > > PUBLIC SUB form_Open() > tviTheTreeView=NEW CIterateTreeView(tvTheTreeView, ME, "tviMyIterator") > ... > END > > PUBLIC SUB form_Close() > 'keep this in or you get problems with circular referencing > tviTheTreeView=NULL > END > > PUBLIC SUB tviMyIterator_next(hostob AS TreeView, key AS String, > state AS Integer) > SELECT state > CASE CIterateTreeView.IterBegin > 'called before iteration starts > CASE CIterateTreeView.IterDone > 'called after iteration is complete > CASE CIterateTreeView.IterVisit > 'called once for each .TreeViewItem visited > 'you have to use the key arg since .TreeViewItem > 'do not work for method parameter passing > END SELECT > END .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Sat Oct 28 18:09:37 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 18:09:37 +0200 Subject: [Gambas-user] Release of gambas 1.9.45 Message-ID: <200610281809.37534.gambas@...1...> Hi, Here is a new release of the development version: * You get gb.web, a new component for making Web application based on CGI scripts: It has a ASP-like interface; it allows you to manage the request, the response, and has session management; And last but not least, it is documented in the wiki! * The IDE open project dialog has been redesigned. * Gambas has been translated to Farsi by Nima Mohammadi. * And there are tons of bug fixes... See the ChangeLog at http://gambas.sf.net/changelog2.html. The gb.web component was developed because I use gambas at my job for developing a http web application that generates KML files of networks for Google Earth, and that allows the user to edit and search forms associated with the objects on the network. Maybe some people will find CGI outdated, but associated with a light HTTP server like thttpd, it rocks! :-) If you need more information about gb.web, you know where to ask. The next step will be a redesign of the internal debugger so that Charlie can allows its IDE visible part to show objects, arrays and collections contents. Regards, -- Benoit Minisini From olinux at ...289... Sat Oct 28 18:16:46 2006 From: olinux at ...289... (olinux) Date: Sat, 28 Oct 2006 18:16:46 +0200 Subject: [Gambas-user] Release of gambas 1.9.45 In-Reply-To: <200610281809.37534.gambas@...1...> References: <200610281809.37534.gambas@...1...> Message-ID: <4543826E.2090402@...289...> Good job, i go to test it for my stack overflow problemm a simple print in each event called during wait and the problem is solved for me. regards olivier Benoit Minisini a ?crit : > Hi, > > Here is a new release of the development version: > > * You get gb.web, a new component for making Web application based on CGI > scripts: It has a ASP-like interface; it allows you to manage the request, > the response, and has session management; And last but not least, it is > documented in the wiki! > > * The IDE open project dialog has been redesigned. > > * Gambas has been translated to Farsi by Nima Mohammadi. > > * And there are tons of bug fixes... > > See the ChangeLog at http://gambas.sf.net/changelog2.html. > > The gb.web component was developed because I use gambas at my job for > developing a http web application that generates KML files of networks for > Google Earth, and that allows the user to edit and search forms associated > with the objects on the network. > > Maybe some people will find CGI outdated, but associated with a light HTTP > server like thttpd, it rocks! :-) > > If you need more information about gb.web, you know where to ask. > > The next step will be a redesign of the internal debugger so that Charlie can > allows its IDE visible part to show objects, arrays and collections contents. > > Regards, > > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From gambas.fr at ...626... Sat Oct 28 18:30:18 2006 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 28 Oct 2006 18:30:18 +0200 Subject: [Gambas-user] Release of gambas 1.9.45 In-Reply-To: <4543826E.2090402@...289...> References: <200610281809.37534.gambas@...1...> <4543826E.2090402@...289...> Message-ID: <6324a42a0610280930p78f6b81q872ea7f8552f64c3@...627...> does the changelog file is automatiquely generated from the svn logs ? in this case why the sdl change not appear ? Fabien From gambas at ...1... Sat Oct 28 18:35:21 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 18:35:21 +0200 Subject: [Gambas-user] Release of gambas 1.9.45 In-Reply-To: <6324a42a0610280930p78f6b81q872ea7f8552f64c3@...627...> References: <200610281809.37534.gambas@...1...> <4543826E.2090402@...289...> <6324a42a0610280930p78f6b81q872ea7f8552f64c3@...627...> Message-ID: <200610281835.21440.gambas@...1...> On Saturday 28 October 2006 18:30, Fabien Bodard wrote: > does the changelog file is automatiquely generated from the svn logs ? > > in this case why the sdl change not appear ? > > > Fabien No, I do it by hand. And SDL changes are there, aren't they? -- Benoit Minisini From gambas at ...1... Sat Oct 28 18:38:54 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 18:38:54 +0200 Subject: [Gambas-user] Changes in LINK Message-ID: <200610281838.55036.gambas@...1...> I have chosen the following syntax for LINK: LINK Destination TO Source But now I think it is a bad idea, as: - It is the contrary of the 'ln -s' shell command. - It is the contrary of COPY syntax. I think I will invert the arguments, which will lead to source incompatibility between versions <= 1.9.45 and versions >= 1.9.46. What do you think about that? -- Benoit Minisini From ulisse.rubizzo at ...626... Sat Oct 28 20:10:30 2006 From: ulisse.rubizzo at ...626... (ulisse rubizzo) Date: Sat, 28 Oct 2006 20:10:30 +0200 Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281838.55036.gambas@...1...> References: <200610281838.55036.gambas@...1...> Message-ID: <7e1501bb0610281110j115cb356tc9fe434f3683d7d7@...627...> Hi I'm ulisse and I'm new to gambas I'm just wondering around and I like it and I'd like in a future give some contrib.. About the link... I think it's a good idea ;) bye ulix On 10/28/06, Benoit Minisini wrote: > I have chosen the following syntax for LINK: > > LINK Destination TO Source > > But now I think it is a bad idea, as: > - It is the contrary of the 'ln -s' shell command. > - It is the contrary of COPY syntax. > > I think I will invert the arguments, which will lead to source incompatibility > between versions <= 1.9.45 and versions >= 1.9.46. > > What do you think about that? > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From sourceforge-raindog2 at ...94... Sat Oct 28 20:58:55 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sat, 28 Oct 2006 14:58:55 -0400 Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281838.55036.gambas@...1...> References: <200610281838.55036.gambas@...1...> Message-ID: <200610281458.55625.sourceforge-raindog2@...94...> On Saturday 28 October 2006 12:38, Benoit Minisini wrote: > I think I will invert the arguments, which will lead to source > incompatibility between versions <= 1.9.45 and versions >= > 1.9.46. > What do you think about that? I think this is a good idea. It's a shame you couldn't change the TO keyword to something else so that rather than accidentally creating backward links, old code just wouldn't compile. Rob From Karl.Reinl at ...9... Sat Oct 28 21:06:16 2006 From: Karl.Reinl at ...9... (Charlie Reinl) Date: Sat, 28 Oct 2006 21:06:16 +0200 Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281838.55036.gambas@...1...> References: <200610281838.55036.gambas@...1...> Message-ID: <1162062378.5300.1.camel@...40...> Am Samstag, den 28.10.2006, 18:38 +0200 schrieb Benoit Minisini: > I have chosen the following syntax for LINK: > > LINK Destination TO Source > > But now I think it is a bad idea, as: > - It is the contrary of the 'ln -s' shell command. > - It is the contrary of COPY syntax. > > I think I will invert the arguments, which will lead to source incompatibility > between versions <= 1.9.45 and versions >= 1.9.46. > > What do you think about that? Salut, better now, then after the gambas2 final. Amicalment Charlie From brian at ...1334... Sat Oct 28 21:20:59 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 12:20:59 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281458.55625.sourceforge-raindog2@...94...> References: <200610281838.55036.gambas@...1...> <200610281458.55625.sourceforge-raindog2@...94...> Message-ID: <20061028121334.Y7552@...1337...> On Sat, 28 Oct 2006, Rob wrote: Agreed. Incompatibility that causes sometimes unnoticeable but possibly catastrophic changes in logic due to changed semantics without any warnings is VERY BAD. It would be way better to make a syntactical change so older code doesn't get mistakenly run with logic bugs possibly resulting in potentially dangerous and catastrphic file trashing (just think of the mayhem while running an admin tool with root privs in system areas and links in older code going backwards!!!!). If upgrading the interpretor only breaks the code semantically (without errors or warnings at compile time or run time) there could be lots of trouble. > Date: Sat, 28 Oct 2006 14:58:55 -0400 > From: Rob > Reply-To: mailing list for gambas users > > To: gambas-user at lists.sourceforge.net > Subject: Re: [Gambas-user] Changes in LINK > > On Saturday 28 October 2006 12:38, Benoit Minisini wrote: > > I think I will invert the arguments, which will lead to source > > incompatibility between versions <= 1.9.45 and versions >= > > 1.9.46. > > What do you think about that? > > I think this is a good idea. It's a shame you couldn't change > the TO keyword to something else so that rather than > accidentally creating backward links, old code just wouldn't > compile. More than a shame. An accident waiting to happen. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Sat Oct 28 21:34:54 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 21:34:54 +0200 Subject: [Gambas-user] Changes in LINK In-Reply-To: <20061028121334.Y7552@...1337...> References: <200610281838.55036.gambas@...1...> <200610281458.55625.sourceforge-raindog2@...94...> <20061028121334.Y7552@...1337...> Message-ID: <200610282134.55113.gambas@...1...> On Saturday 28 October 2006 21:20, Christopher Brian Jack wrote: > On Sat, 28 Oct 2006, Rob wrote: > > Agreed. Incompatibility that causes sometimes unnoticeable but possibly > catastrophic changes in logic due to changed semantics without any > warnings is VERY BAD. > > It would be way better to make a syntactical change so older code doesn't > get mistakenly run with logic bugs possibly resulting in potentially > dangerous and catastrphic file trashing (just think of the mayhem while > running an admin tool with root privs in system areas and links in older > code going backwards!!!!). If upgrading the interpretor only breaks the > code semantically (without errors or warnings at compile time or run time) > there could be lots of trouble. > I agree, but I don't want to add another keyword nor make a syntactical change just for that. Inverting the argument of LINK is not dramatic, as if you make a mistake, instead of creating a link, it will only raise an error, as the link source taken as destination already exists. When I will do it, I will put a big warning to warn people to check their code. After all, this is a development version. Of course I would never do that with a stable one. Regards, -- Benoit Minisini From brian at ...1334... Sat Oct 28 21:41:26 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 12:41:26 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281458.55625.sourceforge-raindog2@...94...> References: <200610281838.55036.gambas@...1...> <200610281458.55625.sourceforge-raindog2@...94...> Message-ID: <20061028122308.I7552@...1337...> On Sat, 28 Oct 2006, Rob wrote: Could the AS keyword be used in the inverted form? eg: LINK AS Or does the AS keyword have some internal management that requires it to be paired with datatypes or class names (hence it could only be used as a keyword in things like declarations where a datatype or class name is involved). Another alternative could be to take out LINK completely and make Link a File method (I can just hear the boos and hisses now)? eg: DIM HFile AS File OPEN "" FOR READ AS #hFile hFile.Link("") hFile.Close() Possibly also has the benefit of localizing checks for existance but maybe not since a race condition could render the handle invalid by the time the interpretor got from OPEN to File.Link That brings up another idea: OPEN [LOCKED] "" FOR {READ|WRITE|BOTH} AS #handle Where the OPEN fails if it can't get a file lock immediately after opening when LOCKED is specified. The idea being to allow serialized/atomic file access sections (of course CLOSE would then have to be aware of locking and drop the lock after committing buffers but prior to making the close system call). > Date: Sat, 28 Oct 2006 14:58:55 -0400 > From: Rob > Reply-To: mailing list for gambas users > > To: gambas-user at lists.sourceforge.net > Subject: Re: [Gambas-user] Changes in LINK > > On Saturday 28 October 2006 12:38, Benoit Minisini wrote: > > I think I will invert the arguments, which will lead to source > > incompatibility between versions <= 1.9.45 and versions >= > > 1.9.46. > > What do you think about that? > > I think this is a good idea. It's a shame you couldn't change > the TO keyword to something else so that rather than > accidentally creating backward links, old code just wouldn't > compile. > > Rob > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Sat Oct 28 21:48:04 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 12:48:04 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <20061028122308.I7552@...1337...> References: <200610281838.55036.gambas@...1...> <200610281458.55625.sourceforge-raindog2@...94...> <20061028122308.I7552@...1337...> Message-ID: <20061028124351.H7552@...1337...> On Sat, 28 Oct 2006, Christopher Brian Jack wrote: This email took a while to write benoit so I didn't get your last reply about not wanting to change the syntax until after I composed and sent it off... BTW: I wonder if olinux has had a chance to play around with the tree walker I posted for him? I didn't see any other solutions posted or any other indication that he solved his need for TreeView iteration (if he did I start to wonder if I'm getting all the list emails...). > Date: Sat, 28 Oct 2006 12:41:26 -0700 (PDT) > From: Christopher Brian Jack > Reply-To: mailing list for gambas users > > To: mailing list for gambas users > Subject: Re: [Gambas-user] Changes in LINK > > On Sat, 28 Oct 2006, Rob wrote: > > Could the AS keyword be used in the inverted form? > > eg: > LINK AS > > Or does the AS keyword have some internal management that requires it to > be paired with datatypes or class names (hence it could only be used as a > keyword in things like declarations where a datatype or class name is > involved). > > Another alternative could be to take out LINK completely and make Link a > File method (I can just hear the boos and hisses now)? > > eg: > DIM HFile AS File > OPEN "" FOR READ AS #hFile > hFile.Link("") > hFile.Close() > > Possibly also has the benefit of localizing checks for existance but maybe > not since a race condition could render the handle invalid by the time the > interpretor got from OPEN to File.Link > > That brings up another idea: > > OPEN [LOCKED] "" FOR {READ|WRITE|BOTH} AS #handle > > Where the OPEN fails if it can't get a file lock immediately after opening > when LOCKED is specified. The idea being to allow serialized/atomic file > access sections (of course CLOSE would then have to be aware of locking > and drop the lock after committing buffers but prior to making the close > system call). > > > Date: Sat, 28 Oct 2006 14:58:55 -0400 > > From: Rob > > Reply-To: mailing list for gambas users > > > > To: gambas-user at lists.sourceforge.net > > Subject: Re: [Gambas-user] Changes in LINK > > > > On Saturday 28 October 2006 12:38, Benoit Minisini wrote: > > > I think I will invert the arguments, which will lead to source > > > incompatibility between versions <= 1.9.45 and versions >= > > > 1.9.46. > > > What do you think about that? > > > > I think this is a good idea. It's a shame you couldn't change > > the TO keyword to something else so that rather than > > accidentally creating backward links, old code just wouldn't > > compile. > > > > Rob > > > > ------------------------------------------------------------------------- > > Using Tomcat but need to do more? Need to support web services, security? > > Get stuff done quickly with pre-integrated technology to make your job easier > > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > .=================================================. > | Christopher BRIAN Jack aka "Gau of the Veldt" | > +=================================================' > | oevna at ...1544... > `=================================================- > Hi Spambots, my email address is sputnik at ...1334... > Hi Humans, my email address uses rot13 cipher > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From sourceforge-raindog2 at ...94... Sat Oct 28 21:59:24 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sat, 28 Oct 2006 15:59:24 -0400 Subject: [Gambas-user] Changes in LINK In-Reply-To: <20061028122308.I7552@...1337...> References: <200610281838.55036.gambas@...1...> <200610281458.55625.sourceforge-raindog2@...94...> <20061028122308.I7552@...1337...> Message-ID: <200610281559.25403.sourceforge-raindog2@...94...> On Saturday 28 October 2006 15:41, Christopher Brian Jack wrote: > Another alternative could be to take out LINK completely and > make Link a File method (I can just hear the boos and hisses > now)? I really think if it were a File method, it should be static. I've actually always wondered why LINK, RENAME/MOVE, etc. were built-in keywords and not part of the File class anyway.... I assume it was to make VB people more comfortable, but all these keywords are different than the VB ones. > Where the OPEN fails if it can't get a file lock immediately > after opening when LOCKED is specified. The idea being to > allow serialized/atomic file access sections (of course CLOSE > would then have to be aware of locking and drop the lock after > committing buffers but prior to making the close system call). It will eventually be important to have file locking in Gambas. Right now I think the only way to do it is with API calls, if it's possible at all.... Rob From sourceforge-raindog2 at ...94... Sat Oct 28 22:03:14 2006 From: sourceforge-raindog2 at ...94... (Rob) Date: Sat, 28 Oct 2006 16:03:14 -0400 Subject: [Gambas-user] Changes in LINK In-Reply-To: <20061028124351.H7552@...1337...> References: <200610281838.55036.gambas@...1...> <20061028122308.I7552@...1337...> <20061028124351.H7552@...1337...> Message-ID: <200610281603.14982.sourceforge-raindog2@...94...> On Saturday 28 October 2006 15:48, Christopher Brian Jack wrote: > BTW: I wonder if olinux has had a chance to play around with > the tree walker I posted for him? I didn't see any other > solutions posted I didn't understand his original post and didn't have time to ask for clarification when I saw it, so I just forgot about the whole thread once I saw you had jumped in. He hasn't replied to that thread, but he has posted to two others so I assume he just got caught up in his other problem (with the stack overflow.) Rob From gambas at ...1... Sat Oct 28 22:10:50 2006 From: gambas at ...1... (Benoit Minisini) Date: Sat, 28 Oct 2006 22:10:50 +0200 Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281559.25403.sourceforge-raindog2@...94...> References: <200610281838.55036.gambas@...1...> <20061028122308.I7552@...1337...> <200610281559.25403.sourceforge-raindog2@...94...> Message-ID: <200610282210.50386.gambas@...1...> On Saturday 28 October 2006 21:59, Rob wrote: > On Saturday 28 October 2006 15:41, Christopher Brian Jack wrote: > > Another alternative could be to take out LINK completely and > > make Link a File method (I can just hear the boos and hisses > > now)? > > I really think if it were a File method, it should be static. > > I've actually always wondered why LINK, RENAME/MOVE, etc. were > built-in keywords and not part of the File class anyway.... I > assume it was to make VB people more comfortable, but all these > keywords are different than the VB ones. > Hey, it is the BASIC way. :-) > > Where the OPEN fails if it can't get a file lock immediately > > after opening when LOCKED is specified. The idea being to > > allow serialized/atomic file access sections (of course CLOSE > > would then have to be aware of locking and drop the lock after > > committing buffers but prior to making the close system call). > > It will eventually be important to have file locking in Gambas. > Right now I think the only way to do it is with API calls, if > it's possible at all.... > > Rob > You have the LOCK and UNLOCK keyword for locking/unlocking a file opened for writing. Maybe I should rewrite them so that they work on a path and not on a file. This will be easier to use: you choose a path file that will work as a lock, and you use LOCK and UNLOCK on it. -- Benoit Minisini From ronstk at ...239... Sat Oct 28 23:41:02 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sat, 28 Oct 2006 23:41:02 +0200 Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281838.55036.gambas@...1...> References: <200610281838.55036.gambas@...1...> Message-ID: <200610282341.03947.ronstk@...239...> On Saturday 28 October 2006 18:38, Benoit Minisini wrote: > I have chosen the following syntax for LINK: > > LINK Destination TO Source > > But now I think it is a bad idea, as: > - It is the contrary of the 'ln -s' shell command. > - It is the contrary of COPY syntax. > > I think I will invert the arguments, which will lead to source incompatibility > between versions <= 1.9.45 and versions >= 1.9.46. > > What do you think about that? > LINK Source AS Destination ??? Ron From brian at ...1334... Sun Oct 29 00:43:39 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 15:43:39 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281559.25403.sourceforge-raindog2@...94...> References: <200610281838.55036.gambas@...1...> <200610281458.55625.sourceforge-raindog2@...94...> <20061028122308.I7552@...1337...> <200610281559.25403.sourceforge-raindog2@...94...> Message-ID: <20061028153852.J8257@...1337...> On Sat, 28 Oct 2006, Rob wrote: > > Where the OPEN fails if it can't get a file lock immediately > > after opening when LOCKED is specified. The idea being to > > allow serialized/atomic file access sections (of course CLOSE > > would then have to be aware of locking and drop the lock after > > committing buffers but prior to making the close system call). > > It will eventually be important to have file locking in Gambas. > Right now I think the only way to do it is with API calls, if > it's possible at all.... API calls are really not friendly to the Gambas environment and can have portability issues. But, yeah, file locking is important for many application aspects (such as a server running via inetd using a gambas app and accessing common files). Looks like compression, base64 (because most DBs aren't 8-bit clean) and DB access is the way to go until file locking becomes available. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Sun Oct 29 00:46:24 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 15:46:24 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281603.14982.sourceforge-raindog2@...94...> References: <200610281838.55036.gambas@...1...> <20061028122308.I7552@...1337...> <20061028124351.H7552@...1337...> <200610281603.14982.sourceforge-raindog2@...94...> Message-ID: <20061028154417.N8257@...1337...> On Sat, 28 Oct 2006, Rob wrote: As I understood it, he wanted a way to be able to do for a TreeView what FOR EACH does for supported objects. It's not currently possible natively in Gambas so I made a class to do it using a recursive walk. > Date: Sat, 28 Oct 2006 16:03:14 -0400 > From: Rob > Reply-To: mailing list for gambas users > > To: gambas-user at lists.sourceforge.net > Subject: Re: [Gambas-user] Changes in LINK > > On Saturday 28 October 2006 15:48, Christopher Brian Jack wrote: > > BTW: I wonder if olinux has had a chance to play around with > > the tree walker I posted for him? I didn't see any other > > solutions posted > > I didn't understand his original post and didn't have time to ask > for clarification when I saw it, so I just forgot about the > whole thread once I saw you had jumped in. He hasn't replied to > that thread, but he has posted to two others so I assume he just > got caught up in his other problem (with the stack overflow.) > > Rob > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Sun Oct 29 00:54:00 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 15:54:00 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610282210.50386.gambas@...1...> References: <200610281838.55036.gambas@...1...> <20061028122308.I7552@...1337...> <200610281559.25403.sourceforge-raindog2@...94...> <200610282210.50386.gambas@...1...> Message-ID: <20061028154739.K8257@...1337...> On Sat, 28 Oct 2006, Benoit Minisini wrote: > You have the LOCK and UNLOCK keyword for locking/unlocking a file opened for > writing. > > Maybe I should rewrite them so that they work on a path and not on a file. > This will be easier to use: you choose a path file that will work as a lock, > and you use LOCK and UNLOCK on it. There are times where locking is desirable for readers as well as writers such as when access to one part of a file is an index to where other data should be written. If a race condition develops between two concurrent accessors on the file and one changes the index between the time the first app does it's read then reopens for write+lock there will definately be file inconsistencies and a whole new insect kingdom of bugs--that the programmer didn't even know existed--creeping in. Hopefully locks can be requested when the file is open FOR BOTH? .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Sun Oct 29 00:58:39 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sat, 28 Oct 2006 15:58:39 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610282341.03947.ronstk@...239...> References: <200610281838.55036.gambas@...1...> <200610282341.03947.ronstk@...239...> Message-ID: <20061028155434.A8314@...1337...> On Sat, 28 Oct 2006, Ron Onstenk wrote: > > What do you think about that? > > > > > LINK Source AS Destination ??? I was thinking the same thing... Either that or as a non-static File method so you know who the source is (the File on which the method is invoked). IMO I think using a File method (that is not static) more clearly indicates which animal is the source file for the link. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From olinux at ...289... Sun Oct 29 07:48:57 2006 From: olinux at ...289... (olinux) Date: Sun, 29 Oct 2006 07:48:57 +0100 Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610281603.14982.sourceforge-raindog2@...94...> References: <200610281838.55036.gambas@...1...> <20061028122308.I7552@...1337...> <20061028124351.H7552@...1337...> <200610281603.14982.sourceforge-raindog2@...94...> Message-ID: <45444ED9.4040401@...289...> i have used another methode to list all members of a treeview. a moveabove cpompleted with an expand property give me a good result except than all member of treeview are expanded after that. thanks for your solution regards Olivier Coquet Rob a ?crit : > On Saturday 28 October 2006 15:48, Christopher Brian Jack wrote: > >> BTW: I wonder if olinux has had a chance to play around with >> the tree walker I posted for him? I didn't see any other >> solutions posted >> > > I didn't understand his original post and didn't have time to ask > for clarification when I saw it, so I just forgot about the > whole thread once I saw you had jumped in. He hasn't replied to > that thread, but he has posted to two others so I assume he just > got caught up in his other problem (with the stack overflow.) > > Rob > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From olinux at ...289... Sun Oct 29 07:51:43 2006 From: olinux at ...289... (olinux) Date: Sun, 29 Oct 2006 07:51:43 +0100 Subject: [Gambas-user] 1.9.45 compile but not start ! Message-ID: <45444F7F.5060209@...289...> 1.9.45 compile ok install ok application can't load design.class at startup. FC5 1.9.44 run normaly regards Olivier Coquet -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From brian at ...1334... Sun Oct 29 08:15:25 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sun, 29 Oct 2006 00:15:25 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <45444ED9.4040401@...289...> References: <200610281838.55036.gambas@...1...> <20061028122308.I7552@...1337...> <20061028124351.H7552@...1337...> <200610281603.14982.sourceforge-raindog2@...94...> <45444ED9.4040401@...289...> Message-ID: <20061029001416.I10198@...1337...> On Sun, 29 Oct 2006, olinux wrote: > i have used another methode to list all members of a treeview. > > a moveabove cpompleted with an expand property give me a good result > except than all member of treeview are expanded after that. > > thanks for your solution It's there if you want a way to access the treeview nodes without expanding everything first. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Sun Oct 29 09:39:52 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 09:39:52 +0100 Subject: [Gambas-user] 1.9.45 compile but not start ! In-Reply-To: <45444F7F.5060209@...289...> References: <45444F7F.5060209@...289...> Message-ID: <200610290939.52984.gambas@...1...> On Sunday 29 October 2006 07:51, olinux wrote: > 1.9.45 > > compile ok > install ok > > application can't load design.class at startup. > > FC5 > 1.9.44 run normaly > > regards > > Olivier Coquet Please download the package again, and recompile. You got the first download, where some files were missing. Regards, -- Benoit Minisini From olinux at ...289... Sun Oct 29 08:44:55 2006 From: olinux at ...289... (olinux) Date: Sun, 29 Oct 2006 08:44:55 +0100 Subject: [Gambas-user] 1.9.45 compile but not start ! In-Reply-To: <200610290939.52984.gambas@...1...> References: <45444F7F.5060209@...289...> <200610290939.52984.gambas@...1...> Message-ID: <45445BF7.7030106@...289...> ok i go thankes olivier Benoit Minisini a ?crit : > On Sunday 29 October 2006 07:51, olinux wrote: > >> 1.9.45 >> >> compile ok >> install ok >> >> application can't load design.class at startup. >> >> FC5 >> 1.9.44 run normaly >> >> regards >> >> Olivier Coquet >> > > Please download the package again, and recompile. You got the first download, > where some files were missing. > > Regards, > > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From gambas at ...1... Sun Oct 29 09:50:30 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 09:50:30 +0100 Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610282341.03947.ronstk@...239...> References: <200610281838.55036.gambas@...1...> <200610282341.03947.ronstk@...239...> Message-ID: <200610290950.30669.gambas@...1...> On Saturday 28 October 2006 23:41, Ron Onstenk wrote: > On Saturday 28 October 2006 18:38, Benoit Minisini wrote: > > I have chosen the following syntax for LINK: > > > > LINK Destination TO Source > > > > But now I think it is a bad idea, as: > > - It is the contrary of the 'ln -s' shell command. > > - It is the contrary of COPY syntax. > > > > I think I will invert the arguments, which will lead to source > > incompatibility between versions <= 1.9.45 and versions >= 1.9.46. > > > > What do you think about that? > > LINK Source AS Destination ??? > > > Ron > Actually this is the syntax I should have used for the current semantic. -- Benoit Minisini From gambas at ...1... Sun Oct 29 10:01:20 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 10:01:20 +0100 Subject: [Gambas-user] Changes in LINK In-Reply-To: <20061028154739.K8257@...1337...> References: <200610281838.55036.gambas@...1...> <200610282210.50386.gambas@...1...> <20061028154739.K8257@...1337...> Message-ID: <200610291001.20214.gambas@...1...> On Sunday 29 October 2006 00:54, Christopher Brian Jack wrote: > On Sat, 28 Oct 2006, Benoit Minisini wrote: > > You have the LOCK and UNLOCK keyword for locking/unlocking a file opened > > for writing. > > > > Maybe I should rewrite them so that they work on a path and not on a > > file. This will be easier to use: you choose a path file that will work > > as a lock, and you use LOCK and UNLOCK on it. > > There are times where locking is desirable for readers as well as writers > such as when access to one part of a file is an index to where other data > should be written. If a race condition develops between two concurrent > accessors on the file and one changes the index between the time the first > app does it's read then reopens for write+lock there will definately be > file inconsistencies and a whole new insect kingdom of bugs--that the > programmer didn't even know existed--creeping in. > > Hopefully locks can be requested when the file is open FOR BOTH? > Actually the goal of LOCK and UNLOCK is not locking files (funny, isn't it?). It's a way for implementing a system-wide critical code section by using a file as a lock. LOCK/UNLOCK will ensure that there is only one process that run a piece of code at a time. Real file locking is a problem, as it depends on the underlying O.S., the kind of locks supported by the filesystem where the file to lock is located, if the file system is on a network, which system call you use, if the file is buffered... Look at 'man fcntl', 'man flock' and 'man lockf'. It is a real mess! Regards, -- Benoit Minisini From olinux at ...289... Sun Oct 29 09:08:20 2006 From: olinux at ...289... (olinux) Date: Sun, 29 Oct 2006 09:08:20 +0100 Subject: [Gambas-user] 1.9.45 compile but not start ! In-Reply-To: <200610290939.52984.gambas@...1...> References: <45444F7F.5060209@...289...> <200610290939.52984.gambas@...1...> Message-ID: <45446174.2020807@...289...> ok this work now! thank's regards Olivier Coquet Benoit Minisini a ?crit : > On Sunday 29 October 2006 07:51, olinux wrote: > >> 1.9.45 >> >> compile ok >> install ok >> >> application can't load design.class at startup. >> >> FC5 >> 1.9.44 run normaly >> >> regards >> >> Olivier Coquet >> > > Please download the package again, and recompile. You got the first download, > where some files were missing. > > Regards, > > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 27/10/2006 From brian at ...1334... Sun Oct 29 09:14:21 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sun, 29 Oct 2006 01:14:21 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610291001.20214.gambas@...1...> References: <200610281838.55036.gambas@...1...> <200610282210.50386.gambas@...1...> <20061028154739.K8257@...1337...> <200610291001.20214.gambas@...1...> Message-ID: <20061029011050.J10392@...1337...> On Sun, 29 Oct 2006, Benoit Minisini wrote: So is the moral of the story to use compression, base64 (since most DB drivers aren't 8-bit clean) and a database driver, such as MySQL or PostgreSQL, instead of files? May require some lightning-fast MMX-optimized base64 encode/decode algs. Base64 also solves 1001 of the security issues introduced in the DB if attempting to use non-standard methods to store octet (8-bit clean) data in DB fields. I know the DB drivers support locking in the appropriate capacity. > Date: Sun, 29 Oct 2006 10:01:20 +0100 > From: Benoit Minisini > Reply-To: mailing list for gambas users > > To: mailing list for gambas users > Subject: Re: [Gambas-user] Changes in LINK > > On Sunday 29 October 2006 00:54, Christopher Brian Jack wrote: > > On Sat, 28 Oct 2006, Benoit Minisini wrote: > > > You have the LOCK and UNLOCK keyword for locking/unlocking a file opened > > > for writing. > > > > > > Maybe I should rewrite them so that they work on a path and not on a > > > file. This will be easier to use: you choose a path file that will work > > > as a lock, and you use LOCK and UNLOCK on it. > > > > There are times where locking is desirable for readers as well as writers > > such as when access to one part of a file is an index to where other data > > should be written. If a race condition develops between two concurrent > > accessors on the file and one changes the index between the time the first > > app does it's read then reopens for write+lock there will definately be > > file inconsistencies and a whole new insect kingdom of bugs--that the > > programmer didn't even know existed--creeping in. > > > > Hopefully locks can be requested when the file is open FOR BOTH? > > > > Actually the goal of LOCK and UNLOCK is not locking files (funny, isn't it?). > It's a way for implementing a system-wide critical code section by using a > file as a lock. LOCK/UNLOCK will ensure that there is only one process that > run a piece of code at a time. > > Real file locking is a problem, as it depends on the underlying O.S., the kind > of locks supported by the filesystem where the file to lock is located, if > the file system is on a network, which system call you use, if the file is > buffered... > > Look at 'man fcntl', 'man flock' and 'man lockf'. It is a real mess! > > Regards, > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From brian at ...1334... Sun Oct 29 09:20:27 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sun, 29 Oct 2006 01:20:27 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <20061029011050.J10392@...1337...> References: <200610281838.55036.gambas@...1...> <200610282210.50386.gambas@...1...> <20061028154739.K8257@...1337...> <200610291001.20214.gambas@...1...> <20061029011050.J10392@...1337...> Message-ID: <20061029011654.J10520@...1337...> On Sun, 29 Oct 2006, Christopher Brian Jack wrote: > May require some lightning-fast MMX-optimized base64 encode/decode algs. > Base64 also solves 1001 of the security issues introduced in the DB if > attempting to use non-standard methods to store octet (8-bit clean) data > in DB fields. The PHP folks got bit pretty badly by the ad-infinitum-cat-and-mouse quoting problems when trying to store 8-bit data into a DB. Nice thing about base64 data is it NEVER needs escaping to avoid SQL special characters since they don't exist in base64's encoding set. [A-Za-z0-9] which is 62 characters and only a couple or so more needed and it is EASY to find a few extras that aren't SQL characters with special meaning. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From gambas at ...1... Sun Oct 29 10:21:22 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 10:21:22 +0100 Subject: [Gambas-user] Changes in LINK In-Reply-To: <20061029011050.J10392@...1337...> References: <200610281838.55036.gambas@...1...> <200610291001.20214.gambas@...1...> <20061029011050.J10392@...1337...> Message-ID: <200610291021.22772.gambas@...1...> On Sunday 29 October 2006 09:14, Christopher Brian Jack wrote: > On Sun, 29 Oct 2006, Benoit Minisini wrote: > > So is the moral of the story to use compression, base64 (since most DB > drivers aren't 8-bit clean) and a database driver, such as MySQL or > PostgreSQL, instead of files? > > May require some lightning-fast MMX-optimized base64 encode/decode algs. > Base64 also solves 1001 of the security issues introduced in the DB if > attempting to use non-standard methods to store octet (8-bit clean) data > in DB fields. > > I know the DB drivers support locking in the appropriate capacity. > What are you talking about? Of course you must use a database when you want several processes to read/write the same data, with transaction facilities. And I don't understand why you are talking about base64 too. -- Benoit Minisini From brian at ...1334... Sun Oct 29 09:25:34 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sun, 29 Oct 2006 01:25:34 -0700 (PDT) Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610291021.22772.gambas@...1...> References: <200610281838.55036.gambas@...1...> <200610291001.20214.gambas@...1...> <20061029011050.J10392@...1337...> <200610291021.22772.gambas@...1...> Message-ID: <20061029012323.Y10535@...1337...> On Sun, 29 Oct 2006, Benoit Minisini wrote: > And I don't understand why you are talking about base64 too. If you are going to use a DB in place of files the problem becomes finding a clean way to store the data without all the escaping issues involved with 8-bit data (such as in images, audio, etc). Base64 is one such encoding designed to prevent those problems. .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From leonardo at ...1237... Sun Oct 29 10:24:02 2006 From: leonardo at ...1237... (Leonardo Miliani) Date: Sun, 29 Oct 2006 10:24:02 +0100 Subject: [Gambas-user] How to compile SVG & Firebird component? Message-ID: <45447332.6030505@...1237...> 1) My distro (Suse 10.1) is based on KDE and Gnome isn't upgraded via the officiale Suse channels (the last version is 2.12). SVG uses some packages that are present only in 2.16... How can I compile it without changing my WM? 2) I still continue to not be able to compile the Firebird component. I don't know why... On my system I've installed the Firebird server FirebirdCS-1.5.3 but I've never been able to compile this component.... -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software From gambas at ...1... Sun Oct 29 10:36:14 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 10:36:14 +0100 Subject: [Gambas-user] How to compile SVG & Firebird component? In-Reply-To: <45447332.6030505@...1237...> References: <45447332.6030505@...1237...> Message-ID: <200610291036.14467.gambas@...1...> On Sunday 29 October 2006 10:24, Leonardo Miliani wrote: > 1) > My distro (Suse 10.1) is based on KDE and Gnome isn't upgraded via the > officiale Suse channels (the last version is 2.12). SVG uses some > packages that are present only in 2.16... > How can I compile it without changing my WM? I think you can't. Daniel may give you more details about that. > > 2) > I still continue to not be able to compile the Firebird component. > I don't know why... On my system I've installed the Firebird server > FirebirdCS-1.5.3 but I've never been able to compile this component.... You need to install libfbclient.so. Regards, -- Benoit Minisini From rolf.frogs at ...221... Sun Oct 29 10:43:39 2006 From: rolf.frogs at ...221... (rolf) Date: Sun, 29 Oct 2006 10:43:39 +0100 Subject: [Gambas-user] Gambas Version Message-ID: <200610291043.39261.rolf.frogs@...221...> Hi Benoit, hi gambas fighters, I would like to ask, if there is a posibility to get the gambas version number for referencing. I would like to show the version in an about dialog. Could it be something like "gb.version"? Thanks in advance Rolf From a.grandi at ...626... Sun Oct 29 10:47:39 2006 From: a.grandi at ...626... (Andrea Grandi) Date: Sun, 29 Oct 2006 10:47:39 +0100 Subject: [Gambas-user] What do I need to run an application written with Gambas? Message-ID: <9cf0f07b0610290147x10aa0931g51aeaba9e4bb7812@...627...> Hi, the quick answer to my question would be "Install the latest version of gambas, off course!". But... is there a way to strip only the runtim from Gambas and distribute it with my application? For example... I have the latest development version of gambas (1.9.45) and I create an application. Now I want to distribute my application to another user. Does the user need to install Gambas 1.9.45 or does he need only a runtime? How can I create a runtime package? Thanks for your reply. -- Andrea Grandi email: a.grandi at ...626... website: http://www.ptlug.org FON: FONero #69387 From a.grandi at ...626... Sun Oct 29 10:55:55 2006 From: a.grandi at ...626... (Andrea Grandi) Date: Sun, 29 Oct 2006 10:55:55 +0100 Subject: [Gambas-user] Error with 'make install' in Gambas 1.9.45 Message-ID: <9cf0f07b0610290155p57e88ddfg3a185d3beabf49f7@...627...> Hi, I was trying to install the latest version of Gambas (1.9.45). No problemi with ./configure or with make, but running 'make install' I get this: andy80 at ...1008...:~/download/gambas2-1.9.45$ make install Making install in main make[1]: Entering directory `/home/andy80/download/gambas2-1.9.45/main' Making install in libltdl make[2]: Entering directory `/home/andy80/download/gambas2-1.9.45/main/libltdl' make[3]: Entering directory `/home/andy80/download/gambas2-1.9.45/main/libltdl' test -z "/usr/local/lib" || mkdir -p -- "/usr/local/lib" test -z "/usr/local/include" || mkdir -p -- "/usr/local/include" make[3]: Leaving directory `/home/andy80/download/gambas2-1.9.45/main/libltdl' make[2]: Leaving directory `/home/andy80/download/gambas2-1.9.45/main/libltdl' Making install in gbx make[2]: Entering directory `/home/andy80/download/gambas2-1.9.45/main/gbx' make[3]: Entering directory `/home/andy80/download/gambas2-1.9.45/main/gbx' test -z "/usr/local/bin" || mkdir -p -- "/usr/local/bin" /bin/sh ../libtool --mode=install /usr/bin/install -c 'gbx2' '/usr/local/bin/gbx2' /usr/bin/install -c gbx2 /usr/local/bin/gbx2 /usr/bin/install: cannot remove `/usr/local/bin/gbx2': Permission denied make[3]: *** [install-binPROGRAMS] Error 1 make[3]: Leaving directory `/home/andy80/download/gambas2-1.9.45/main/gbx' make[2]: *** [install-am] Error 2 make[2]: Leaving directory `/home/andy80/download/gambas2-1.9.45/main/gbx' make[1]: *** [install-recursive] Error 1 make[1]: Leaving directory `/home/andy80/download/gambas2-1.9.45/main' make: *** [install-recursive] Error 1 Best regards, -- Andrea Grandi email: a.grandi at ...626... website: http://www.ptlug.org FON: FONero #69387 From rolf.frogs at ...221... Sun Oct 29 10:57:06 2006 From: rolf.frogs at ...221... (rolf) Date: Sun, 29 Oct 2006 10:57:06 +0100 Subject: [Gambas-user] Changes in LINK In-Reply-To: <20061029012323.Y10535@...1337...> References: <200610281838.55036.gambas@...1...> <200610291021.22772.gambas@...1...> <20061029012323.Y10535@...1337...> Message-ID: <200610291057.06234.rolf.frogs@...221...> Hi Christopher, > > And I don't understand why you are talking about base64 too. > > If you are going to use a DB in place of files the problem becomes finding > a clean way to store the data without all the escaping issues involved > with 8-bit data (such as in images, audio, etc). Base64 is one such > encoding designed to prevent those problems. The code for quoting (for example a picture) for postqresql is like - so it is not so complex to do it or to put it into a function (perhaps Benoit can doit into the database component): DIM buffer AS Byte DIM bildText AS String ' String with converted picture. The string can be ' written in a bytea-field of a postgresql database OPEN NameOfPic FOR INPUT AS #hFile WHILE NOT Eof(hFile) READ #hfile, buffer, Lof(hFile) IF buffer < 32 OR buffer > 126 THEN bildText = bildText & "\\\\" & Coct(buffer) ELSE ' check if value < 32 or > 127 or 92 (\) or 44 (') SELECT buffer CASE 92 ' (\) bildText = bildText & "\\\\134" CASE 39 ' (') bildText = bildText & "\\'" DEFAULT bildText = bildText & Chr$(buffer) END SELECT END IF WEND CLOSE hFile bye Rolf From ronstk at ...239... Sun Oct 29 11:01:59 2006 From: ronstk at ...239... (Ron Onstenk) Date: Sun, 29 Oct 2006 12:01:59 +0200 Subject: [Gambas-user] Error with 'make install' in Gambas 1.9.45 In-Reply-To: <9cf0f07b0610290155p57e88ddfg3a185d3beabf49f7@...627...> References: <9cf0f07b0610290155p57e88ddfg3a185d3beabf49f7@...627...> Message-ID: <200610291102.00231.ronstk@...239...> On Sunday 29 October 2006 10:55, Andrea Grandi wrote: > Hi, > > I was trying to install the latest version of Gambas (1.9.45). No > problemi with ./configure or with make, but running 'make install' I > get this: > > andy80 at ...1008...:~/download/gambas2-1.9.45$ make install > Making install in main > You should do the install as root when you do not use --prefix to your owned directory. > usr/bin/install -c gbx2 /usr/local/bin/gbx2 > /usr/bin/install: cannot remove `/usr/local/bin/gbx2': Permission denied This directory is owned by root. use 'su', 'kdesu' or gnome equivalent or login as root for the final install. Ron From gambas at ...1... Sun Oct 29 11:05:22 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 11:05:22 +0100 Subject: [Gambas-user] Changes in LINK In-Reply-To: <200610291057.06234.rolf.frogs@...221...> References: <200610281838.55036.gambas@...1...> <20061029012323.Y10535@...1337...> <200610291057.06234.rolf.frogs@...221...> Message-ID: <200610291105.22192.gambas@...1...> On Sunday 29 October 2006 10:57, rolf wrote: > Hi Christopher, > > > > And I don't understand why you are talking about base64 too. > > > > If you are going to use a DB in place of files the problem becomes > > finding a clean way to store the data without all the escaping issues > > involved with 8-bit data (such as in images, audio, etc). Base64 is one > > such encoding designed to prevent those problems. > > The code for quoting (for example a picture) for postqresql is like - so it > is not so complex to do it or to put it into a function (perhaps Benoit can > doit into the database component): > > DIM buffer AS Byte > DIM bildText AS String ' String with converted picture. The string can > be ' written in a bytea-field of a postgresql > database > > OPEN NameOfPic FOR INPUT AS #hFile > > WHILE NOT Eof(hFile) > READ #hfile, buffer, Lof(hFile) > IF buffer < 32 OR buffer > 126 THEN > bildText = bildText & "\\\\" & Coct(buffer) > ELSE > ' check if value < 32 or > 127 or 92 (\) or 44 (') > SELECT buffer > CASE 92 ' (\) > bildText = bildText & "\\\\134" > CASE 39 ' (') > bildText = bildText & "\\'" > DEFAULT > bildText = bildText & Chr$(buffer) > END SELECT > END IF > WEND > CLOSE hFile > > bye > Rolf > It is automatically done if you use BLOBs. Regards, -- Benoit Minisini From gambas at ...1... Sun Oct 29 11:06:39 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 11:06:39 +0100 Subject: [Gambas-user] Gambas Version In-Reply-To: <200610291043.39261.rolf.frogs@...221...> References: <200610291043.39261.rolf.frogs@...221...> Message-ID: <200610291106.39388.gambas@...1...> On Sunday 29 October 2006 10:43, rolf wrote: > Hi Benoit, hi gambas fighters, > > I would like to ask, if there is a posibility to get the gambas version > number for referencing. I would like to show the version in an about > dialog. > > Could it be something like "gb.version"? > > Thanks in advance > Rolf > Something like that? SHELL "gbx2 -V" TO sVersion -- Benoit Minisini From rohnny at ...1248... Sun Oct 29 12:16:51 2006 From: rohnny at ...1248... (R. Stormo) Date: Sun, 29 Oct 2006 03:16:51 -0800 (PST) Subject: [Gambas-user] What do I need to run an application written with Gambas? In-Reply-To: <9cf0f07b0610290147x10aa0931g51aeaba9e4bb7812@...627...> References: <9cf0f07b0610290147x10aa0931g51aeaba9e4bb7812@...627...> Message-ID: <7059881.post@...1379...> Andrea Grandi wrote: > > Hi, > > the quick answer to my question would be "Install the latest version > of gambas, off course!". > But... is there a way to strip only the runtim from Gambas and > distribute it with my application? For example... I have the latest > development version of gambas (1.9.45) and I create an application. > Now I want to distribute my application to another user. Does the user > need to install Gambas 1.9.45 or does he need only a runtime? How can > I create a runtime package? > > Thanks for your reply. > > -- > Andrea Grandi > email: a.grandi at ...626... > website: http://www.ptlug.org > FON: FONero #69387 > Hi. I have tried to make a program to include what you need for your project. Have a look at http://gambasforum.tk under code/application snippets. It's called Runtime Installer. It do work under Ubuntu Dapper. Regards Rohnny My Gambas Community http://gambasforum.tk -- View this message in context: http://www.nabble.com/What-do-I-need-to-run-an-application-written-with-Gambas--tf2533761.html#a7059881 Sent from the gambas-user mailing list archive at Nabble.com. From forty_ at ...18... Sun Oct 29 12:23:05 2006 From: forty_ at ...18... (forty_ at ...18...) Date: Sun, 29 Oct 2006 12:23:05 +0100 Subject: [Gambas-user] Error with 'make install' in Gambas 1.9.45 In-Reply-To: <9cf0f07b0610290155p57e88ddfg3a185d3beabf49f7@...627...> (Andrea Grandi's message of "Sun\, 29 Oct 2006 10\:55\:55 +0100") References: <9cf0f07b0610290155p57e88ddfg3a185d3beabf49f7@...627...> Message-ID: <87ac3fnz6u.fsf@...17...> "Andrea Grandi" writes: Hi, > /usr/bin/install: cannot remove `/usr/local/bin/gbx2': Permission denied > make[3]: *** [install-binPROGRAMS] Error 1 > make[3]: Leaving directory `/home/andy80/download/gambas2-1.9.45/main/gbx' > make[2]: *** [install-am] Error 2 > make[2]: Leaving directory `/home/andy80/download/gambas2-1.9.45/main/gbx' > make[1]: *** [install-recursive] Error 1 > make[1]: Leaving directory `/home/andy80/download/gambas2-1.9.45/main' > make: *** [install-recursive] Error 1 su -c "make install" From gambas at ...1... Sun Oct 29 15:30:03 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 15:30:03 +0100 Subject: [Gambas-user] LINK is done Message-ID: <200610291530.04225.gambas@...1...> That's it! I have swapped the two arguments of LINK in the subversion repository. Everybody using LINK with a gambas version >= 1.9.46 must do the same, otherwise the command will fail. Regards, -- Benoit Minisini From brian at ...1334... Sun Oct 29 16:47:17 2006 From: brian at ...1334... (Christopher Brian Jack) Date: Sun, 29 Oct 2006 07:47:17 -0800 (PST) Subject: [Gambas-user] LINK is done In-Reply-To: <200610291530.04225.gambas@...1...> References: <200610291530.04225.gambas@...1...> Message-ID: <20061029074622.H12792@...1337...> On Sun, 29 Oct 2006, Benoit Minisini wrote: Yikes! (I think the king has spoken and made the final ultimatum.) > Date: Sun, 29 Oct 2006 15:30:03 +0100 > From: Benoit Minisini > Reply-To: mailing list for gambas users > > To: gambas-user at lists.sourceforge.net > Subject: [Gambas-user] LINK is done > > That's it! > > I have swapped the two arguments of LINK in the subversion repository. > > Everybody using LINK with a gambas version >= 1.9.46 must do the same, > otherwise the command will fail. > > Regards, > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > .=================================================. | Christopher BRIAN Jack aka "Gau of the Veldt" | +=================================================' | oevna at ...1544... `=================================================- Hi Spambots, my email address is sputnik at ...1334... Hi Humans, my email address uses rot13 cipher From jredrejo at ...626... Sun Oct 29 17:15:28 2006 From: jredrejo at ...626... (=?ISO-8859-1?Q?Jos=E9_Luis_Redrejo?=) Date: Sun, 29 Oct 2006 17:15:28 +0100 Subject: [Gambas-user] Debian packages for gambas 1.9.45 Message-ID: <8eb28a500610290815l29519075x74293d743f3570cc@...627...> As usual the Debian packages for version 1.9.45 are tested and ready. To get them in a Debian based distribution, the procedure is described at http://gambas.sourceforge.net/download.html in the Debian Section. These packages have been compiled to be used in Debian sid. If a Debian Sarge (as LinEx) is used, you have to replace the "sid" word by "sarge". Maybe Ubuntu users are lucky, and this time their distro "tricks" will let them use the packages. Otherwise, they can compile it in the debian way using the debianized sources availables at http://apt.linex.org/linex/gambas/1.9.45/sid/ (if they don't like to compile they also can switch to use a real Debian based distribution instead of that fork) Cheers. From gambas at ...1... Sun Oct 29 17:29:55 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 17:29:55 +0100 Subject: [Gambas-user] Debian packages for gambas 1.9.45 In-Reply-To: <8eb28a500610290815l29519075x74293d743f3570cc@...627...> References: <8eb28a500610290815l29519075x74293d743f3570cc@...627...> Message-ID: <200610291729.55594.gambas@...1...> On Sunday 29 October 2006 17:15, Jos? Luis Redrejo wrote: > As usual the Debian packages for version 1.9.45 are tested and ready. > To get them in a Debian based distribution, the procedure is described > at http://gambas.sourceforge.net/download.html in the Debian Section. > > These packages have been compiled to be used in Debian sid. If a > Debian Sarge (as LinEx) is used, you have to replace the "sid" word by > "sarge". > > Maybe Ubuntu users are lucky, and this time their distro "tricks" will > let them use the packages. Otherwise, they can compile it in the > debian way using the debianized sources availables at > http://apt.linex.org/linex/gambas/1.9.45/sid/ (if they don't like to > compile they also can switch to use a real Debian based distribution > instead of that fork) > > Cheers. > Can you explain why do you patch the original sources? 1) You removed the compilation of examples at installation. Not dramatic, but why? 2) You replaced 'gbr' by 'gbx' in the interpreter and compiler source code! This is problematic: it breaks the interpreter behaviour, and it prevents Gambas program made outside of Debian from working on Debian. Not a good idea IMHO... Regards, -- Benoit Minisini From rolf.frogs at ...221... Sun Oct 29 12:28:24 2006 From: rolf.frogs at ...221... (rolf) Date: Sun, 29 Oct 2006 12:28:24 +0100 Subject: [Gambas-user] Gambas Version In-Reply-To: <200610291106.39388.gambas@...1...> References: <200610291043.39261.rolf.frogs@...221...> <200610291106.39388.gambas@...1...> Message-ID: <200610291228.24158.rolf.frogs@...221...> Hi Benoit > > I would like to ask, if there is a posibility to get the gambas version > > number for referencing. I would like to show the version in an about > > dialog. > > > > Could it be something like "gb.version"? > > Something like that? > > SHELL "gbx2 -V" TO sVersion This is the version of the gambas runtime and is a dynamic value which changes (perhaps) after each update. But I would like to write a message like: "This program was developed with GAMBAS Version xxx" So the version number might be bind to the IDE (resp. the main gambas components) and not to the interpreter, because a program might run with a newer interpreter as well. Thanks Rolf From gambas at ...1... Sun Oct 29 18:13:09 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 18:13:09 +0100 Subject: [Gambas-user] Gambas Version In-Reply-To: <200610291228.24158.rolf.frogs@...221...> References: <200610291043.39261.rolf.frogs@...221...> <200610291106.39388.gambas@...1...> <200610291228.24158.rolf.frogs@...221...> Message-ID: <200610291813.09477.gambas@...1...> On Sunday 29 October 2006 12:28, rolf wrote: > Hi Benoit > > > > I would like to ask, if there is a posibility to get the gambas version > > > number for referencing. I would like to show the version in an about > > > dialog. > > > > > > Could it be something like "gb.version"? > > > > Something like that? > > > > SHELL "gbx2 -V" TO sVersion > > This is the version of the gambas runtime and is a dynamic value which > changes (perhaps) after each update. But I would like to write a message > like: > > "This program was developed with GAMBAS Version xxx" > > So the version number might be bind to the IDE (resp. the main gambas > components) and not to the interpreter, because a program might run with a > newer interpreter as well. > > Thanks > Rolf > Then use 'System.Version'. Regards, -- Benoit Minisini From rolf.frogs at ...221... Sun Oct 29 19:12:21 2006 From: rolf.frogs at ...221... (rolf) Date: Sun, 29 Oct 2006 19:12:21 +0100 Subject: [Gambas-user] Gambas Version In-Reply-To: <200610291813.09477.gambas@...1...> References: <200610291043.39261.rolf.frogs@...221...> <200610291228.24158.rolf.frogs@...221...> <200610291813.09477.gambas@...1...> Message-ID: <200610291912.21199.rolf.frogs@...221...> Hi Benoit > > > > I would like to ask, if there is a posibility to get the gambas > > > > version number for referencing. I would like to show the version in > > > > an about dialog. > > > > > > > > Could it be something like "gb.version"? > > > > > > Something like that? > > > > > > SHELL "gbx2 -V" TO sVersion > > > > This is the version of the gambas runtime and is a dynamic value which > > changes (perhaps) after each update. But I would like to write a message > > like: > > > > "This program was developed with GAMBAS Version xxx" > > > > So the version number might be bind to the IDE (resp. the main gambas > > components) and not to the interpreter, because a program might run with > > a newer interpreter as well. > Then use 'System.Version'. It works fine, but only gives the major version number. But this does not reflect the work in progress of the development version, where a lot of features come with each new subversion. Rolf From jredrejo at ...626... Sun Oct 29 22:50:56 2006 From: jredrejo at ...626... (=?ISO-8859-1?Q?Jos=E9_Luis_Redrejo?=) Date: Sun, 29 Oct 2006 22:50:56 +0100 Subject: [Gambas-user] Debian packages for gambas 1.9.45 Message-ID: <8eb28a500610291350w1620976bt273110f44c7894f2@...627...> 2006/10/29, Benoit Minisini : > > > > On Sunday 29 October 2006 17:15, Jos? Luis Redrejo wrote: > > As usual the Debian packages for version 1.9.45 are tested and ready. > > To get them in a Debian based distribution, the procedure is described > > at http://gambas.sourceforge.net/download.html in the Debian Section. > > > > These packages have been compiled to be used in Debian sid. If a > > Debian Sarge (as LinEx) is used, you have to replace the "sid" word by > > "sarge". > > > > Maybe Ubuntu users are lucky, and this time their distro "tricks" will > > let them use the packages. Otherwise, they can compile it in the > > debian way using the debianized sources availables at > > http://apt.linex.org/linex/gambas/1.9.45/sid/ (if they don't like to > > compile they also can switch to use a real Debian based distribution > > instead of that fork) > > > > Cheers. > > > > Can you explain why do you patch the original sources? > > 1) You removed the compilation of examples at installation. Not dramatic, > but > why? Because Debian follows FHS for the file system ( http://www.pathname.com/fhs/pub/fhs-2.3.html), and no executable files should be placed at /usr/share/..... So I left there the examples with their code to be checked, used, studied, etc by gambas users, but not compiling them to fullfil the 2) You replaced 'gbr' by 'gbx' in the interpreter and compiler source code! > This is problematic: it breaks the interpreter behaviour, and it prevents > Gambas program made outside of Debian from working on Debian. > > Not a good idea IMHO... Maybe you're right, but I had to think of keeping compatibility between previous gambas compilations made in Debian, and programs compiled outside of Debian to work on Debian. I think the last case is really strange, as when applications are moved from a distribution to another they are usually recompiled. But, when the runtime interpreter changed its name there were already a bunch of applications running in Debian that would fail. In fact, I'm not sure what the best solution would be for this name changing. Anyway the problem (if there were any) is easily fixed with a symbolic link between gbx2/gbr2. Obviously, consider this an open issue, and if you can convince me that changing to gbr2 is the best option, I'll do it. Cheers. Jos? L. From gambas at ...1... Sun Oct 29 23:09:10 2006 From: gambas at ...1... (Benoit Minisini) Date: Sun, 29 Oct 2006 23:09:10 +0100 Subject: [Gambas-user] Debian packages for gambas 1.9.45 In-Reply-To: <8eb28a500610291350w1620976bt273110f44c7894f2@...627...> References: <8eb28a500610291350w1620976bt273110f44c7894f2@...627...> Message-ID: <200610292309.10329.gambas@...1...> On Sunday 29 October 2006 22:50, Jos? Luis Redrejo wrote: > 2006/10/29, Benoit Minisini : > > On Sunday 29 October 2006 17:15, Jos? Luis Redrejo wrote: > > > As usual the Debian packages for version 1.9.45 are tested and ready. > > > To get them in a Debian based distribution, the procedure is described > > > at http://gambas.sourceforge.net/download.html in the Debian Section. > > > > > > These packages have been compiled to be used in Debian sid. If a > > > Debian Sarge (as LinEx) is used, you have to replace the "sid" word by > > > "sarge". > > > > > > Maybe Ubuntu users are lucky, and this time their distro "tricks" will > > > let them use the packages. Otherwise, they can compile it in the > > > debian way using the debianized sources availables at > > > http://apt.linex.org/linex/gambas/1.9.45/sid/ (if they don't like to > > > compile they also can switch to use a real Debian based distribution > > > instead of that fork) > > > > > > Cheers. > > > > Can you explain why do you patch the original sources? > > > > 1) You removed the compilation of examples at installation. Not dramatic, > > but > > why? > > Because Debian follows FHS for the file system ( > http://www.pathname.com/fhs/pub/fhs-2.3.html), and no executable files > should be placed at /usr/share/..... So I left there the examples with > their code to be checked, used, studied, etc by gambas users, but not > compiling them to fullfil the > > 2) You replaced 'gbr' by 'gbx' in the interpreter and compiler source code! > > > This is problematic: it breaks the interpreter behaviour, and it prevents > > Gambas program made outside of Debian from working on Debian. > > > > Not a good idea IMHO... > > Maybe you're right, but I had to think of keeping compatibility between > previous gambas compilations made in Debian, and programs compiled outside > of Debian to work on Debian. I think the last case is really strange, as > when applications are moved from a distribution to another they are usually > recompiled. But, when the runtime interpreter changed its name there were > already a bunch of applications running in Debian that would fail. In fact, > I'm not sure what the best solution would be for this name changing. Anyway > the problem (if there were any) is easily fixed with a symbolic link > between gbx2/gbr2. > Obviously, consider this an open issue, and if you can convince me that > changing to gbr2 is the best option, I'll do it. > > Cheers. > Jos? L. gbr2 is already a symbolic link to gbx2. This is the way for avoiding having a symbolic link in /usr/bin to run gambas archives, do you remember? I replaced '#!/usr/bin/gbx2 -x' by '#!/usr/bin/env gbr2'. As '#!' syntax can only deal with one argument, I made a symbolic link 'gbr2' that points at 'gbx2'. This way, gbx2 knows that it should run as if '-x' was passed as argument. And the aim of gambas executables is being system-agnostic, so you don't have to recompile them when changing the O.S. I'm not sure that this will be true when gambas will be ported on 64 bits. I hope I convinced you, because I am almost sure that what you did prevents programs from being debugged in the IDE, because gbx2 cannot know anymore if it must run a project directory or a compiled archive. Regards, -- Benoit Minisini From jredrejo at ...626... Mon Oct 30 11:19:15 2006 From: jredrejo at ...626... (=?ISO-8859-1?Q?Jos=E9_Luis_Redrejo?=) Date: Mon, 30 Oct 2006 11:19:15 +0100 Subject: [Gambas-user] Debian packages for gambas 1.9.45 In-Reply-To: <8eb28a500610291350w1620976bt273110f44c7894f2@...627...> References: <8eb28a500610291350w1620976bt273110f44c7894f2@...627...> Message-ID: <8eb28a500610300219p22b1624dje51029965e80a64e@...627...> 2006/10/29, Jos? Luis Redrejo : > > > 2006/10/29, Benoit Minisini : > > > > > > > > On Sunday 29 October 2006 17:15, Jos? Luis Redrejo wrote: > > > As usual the Debian packages for version 1.9.45 are tested and ready. > > > To get them in a Debian based distribution, the procedure is described > > > at http://gambas.sourceforge.net/download.html in the Debian Section. > > > > > > These packages have been compiled to be used in Debian sid. If a > > > Debian Sarge (as LinEx) is used, you have to replace the "sid" word by > > > "sarge". > > > > > > Maybe Ubuntu users are lucky, and this time their distro "tricks" will > > > let them use the packages. Otherwise, they can compile it in the > > > debian way using the debianized sources availables at > > > http://apt.linex.org/linex/gambas/1.9.45/sid/ (if they don't like to > > > compile they also can switch to use a real Debian based distribution > > > instead of that fork) > > > > > > Cheers. > > > > > > > Can you explain why do you patch the original sources? > > > > 1) You removed the compilation of examples at installation. Not dramatic, > > but > > why? > > > > Because Debian follows FHS for the file system ( > http://www.pathname.com/fhs/pub/fhs-2.3.html), and no executable files > should be placed at /usr/share/..... So I left there the examples with > their code to be checked, used, studied, etc by gambas users, but not > compiling them to fullfil the > > 2) You replaced 'gbr' by 'gbx' in the interpreter and compiler source code! > > This is problematic: it breaks the interpreter behaviour, and it prevents > > Gambas program made outside of Debian from working on Debian. > > > > Not a good idea IMHO... > > > > Maybe you're right, but I had to think of keeping compatibility between > previous gambas compilations made in Debian, and programs compiled outside > of Debian to work on Debian. I think the last case is really strange, as > when applications are moved from a distribution to another they are usually > recompiled. But, when the runtime interpreter changed its name there were > already a bunch of applications running in Debian that would fail. In fact, > I'm not sure what the best solution would be for this name changing. Anyway > the problem (if there were any) is easily fixed with a symbolic link between > gbx2/gbr2. > Obviously, consider this an open issue, and if you can convince me that > changing to gbr2 is the best option, I'll do it. > > Cheers. > Jos? L. > > > > > > *Re: Debian packages for gambas 1.9.45 > * > From: Benoit Minisini - 2006-10-29 14:09 > > On Sunday 29 October 2006 22:50, Jos? Luis Redrejo wrote: > > 2006/10/29, Benoit Minisini : > > > On Sunday 29 October 2006 17:15, Jos? Luis Redrejo wrote: > > > > As usual the Debian packages for version 1.9.45 are tested and ready. > > > > To get them in a Debian based distribution, the procedure is described > > > > at http://gambas.sourceforge.net/download.html in the Debian Section. > > > > > > > > These packages have been compiled to be used in Debian sid. If a > > > > Debian Sarge (as LinEx) is used, you have to replace the "sid" word by > > > > "sarge". > > > > > > > > Maybe Ubuntu users are lucky, and this time their distro "tricks" will > > > > let them use the packages. Otherwise, they can compile it in the > > > > debian way using the debianized sources availables at > > > > http://apt.linex.org/linex/gambas/1.9.45/sid/ (if they don't like to > > > > compile they also can switch to use a real Debian based distribution > > > > instead of that fork) > > > > > > > > Cheers. > > > > > > Can you explain why do you patch the original sources? > > > > > > 1) You removed the compilation of examples at installation. Not dramatic, > > > but > > > why? > > > > Because Debian follows FHS for the file system ( > > http://www.pathname.com/fhs/pub/fhs-2.3.html), and no executable files > > should be placed at /usr/share/..... So I left there the examples with > > their code to be checked, used, studied, etc by gambas users, but not > > compiling them to fullfil the > > > > 2) You replaced 'gbr' by 'gbx' in the interpreter and compiler source code! > > > > > This is problematic: it breaks the interpreter behaviour, and it prevents > > > Gambas program made outside of Debian from working on Debian. > > > > > > Not a good idea IMHO... > > > > Maybe you're right, but I had to think of keeping compatibility between > > previous gambas compilations made in Debian, and programs compiled outside > > of Debian to work on Debian. I think the last case is really strange, as > > when applications are moved from a distribution to another they are usually > > recompiled. But, when the runtime interpreter changed its name there were > > already a bunch of applications running in Debian that would fail. In fact, > > I'm not sure what the best solution would be for this name changing. Anyway > > the problem (if there were any) is easily fixed with a symbolic link > > between gbx2/gbr2. > > Obviously, consider this an open issue, and if you can convince me that > > changing to gbr2 is the best option, I'll do it. > > > > Cheers. > > Jos? L. > > gbr2 is already a symbolic link to gbx2. This is the way for avoiding having a > symbolic link in /usr/bin to run gambas archives, do you remember? > > I replaced '#!/usr/bin/gbx2 -x' by '#!/usr/bin/env gbr2'. > > As '#!' syntax can only deal with one argument, I made a symbolic link 'gbr2' > that points at 'gbx2'. This way, gbx2 knows that it should run as if '-x' was > passed as argument. > > And the aim of gambas executables is being system-agnostic, so you don't have > to recompile them when changing the O.S. I'm not sure that this will be true > when gambas will be ported on 64 bits. > > I hope I convinced you, because I am almost sure that what you did prevents > programs from being debugged in the IDE, because gbx2 cannot know anymore if > it must run a project directory or a compiled archive. > > > Obviously, you convinced me. If debugging won't work, there is no option. I've already changed it and updated the packages. Cheers. From j0e at ...103... Tue Oct 31 02:55:53 2006 From: j0e at ...103... (jum) Date: Mon, 30 Oct 2006 20:55:53 -0500 Subject: [Gambas-user] Window Problem (Solved) and new minor problem In-Reply-To: References: Message-ID: <200610302055.54384.j0e@...103...> From iguest at ...1599... Mon Oct 30 16:23:04 2006 From: iguest at ...1599... (Iestyn Guest) Date: Mon, 30 Oct 2006 10:23:04 -0500 Subject: [Gambas-user] ODBC/Easysoft Oracle in Gambas 1.0.17? Message-ID: <1162221784.17421.11.camel@...1600...> Hello, I'm using Gambas 1.0.17 - Is there a way to connect to an Oracle database by way of Unix ODBC/Easysoft or directly via native Oracle 10g driver? I only see postgresql, mysql and sqlite in the Gambas Database Manager. Any help would be appreciated. Kind regards, Iestyn Guest. From henrique.ulbrich at ...626... Mon Oct 30 17:57:47 2006 From: henrique.ulbrich at ...626... (Henrique Cesar Ulbrich) Date: Mon, 30 Oct 2006 14:57:47 -0200 Subject: [Gambas-user] Debian packages for gambas 1.9.45 In-Reply-To: <8eb28a500610290815l29519075x74293d743f3570cc@...627...> References: <8eb28a500610290815l29519075x74293d743f3570cc@...627...> Message-ID: <200610301457.51836.henrique.ulbrich@...626...> Historiadores acreditam que, em Domingo 29 Outubro 2006 14:15, Jos? Luis Redrejo disse: > Maybe Ubuntu users are lucky, and this time their distro "tricks" will > let them use the packages. Unfortunately, no :( -- Henrique Cesar Ulbrich henrique.ulbrich at ...626... 22 - Algumas pessoas usam uniforme do Superman. J? o Superman usa uniforme de Chuck Norris. Este email est? assinado digitalmente (PGP). -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 191 bytes Desc: not available URL: From jredrejo at ...626... Mon Oct 30 18:33:35 2006 From: jredrejo at ...626... (=?ISO-8859-1?Q?Jos=E9_Luis_Redrejo?=) Date: Mon, 30 Oct 2006 18:33:35 +0100 Subject: [Gambas-user] Debian packages for gambas 1.9.45 In-Reply-To: <200610301457.51836.henrique.ulbrich@...626...> References: <8eb28a500610290815l29519075x74293d743f3570cc@...627...> <200610301457.51836.henrique.ulbrich@...626...> Message-ID: <8eb28a500610300933icff4ae0ic8cd89de095fe196@...627...> Have you tried both options: sid and sarge packages? Maybe sid won't work but sarge will... 2006/10/30, Henrique Cesar Ulbrich : > > Historiadores acreditam que, > em Domingo 29 Outubro 2006 14:15, Jos? Luis Redrejo disse: > > Maybe Ubuntu users are lucky, and this time their distro "tricks" will > > let them use the packages. > > Unfortunately, no :( > -- > Henrique Cesar Ulbrich > henrique.ulbrich at ...626... > > > 22 - Algumas pessoas usam uniforme do Superman. > J? o Superman usa uniforme de Chuck Norris. > > Este email est? assinado digitalmente (PGP). > > > From fidojones at ...805... Tue Oct 31 02:31:19 2006 From: fidojones at ...805... (Lorenzo Tejera) Date: Tue, 31 Oct 2006 01:31:19 +0000 Subject: [Gambas-user] Bug or feature with IIF Message-ID: <19cca6e50610301731k1990eb57n3b2eea2e9119f5f@...627...> I'm trying to use old visual basic code, and this not work IIf(bUltimo, "", ",") bUltimo is boolean, gambas give an error with the first parameter ("" the empty string), say "wanted null and give a String instead" If I put IIf(bUltimo, " ", ",") And " " space string works fine, but I can't return a "" empty string..... In visual basic it works; it's a bug or a feature benoit? regards Lorenzo From christian at ...980... Tue Oct 31 19:41:06 2006 From: christian at ...980... (Christian E. =?iso-8859-1?q?L=F3pez?= Finnberg) Date: Tue, 31 Oct 2006 18:41:06 +0000 Subject: [Gambas-user] Special Compilation for archlinux. Message-ID: <200610311841.07405.christian@...980...> Hi, I'm trying to make the archlinux package. To do the package I have to compile and install on a temporary directory using the option DESTDIR of make. Unfortunatelly it does not work. I think the compilation process uses files created during the same compilation so it does not find the needed files and i get errors like this: Compiling gb.settings... /home/christian/t/gambas/src/gambas2-1.9.45/comp/src/gb.settings/Settings.class:12: Unknown identifier: Collection Installing gb.settings... Compiling gb.info... /home/christian/t/gambas/src/gambas2-1.9.45/comp/src/gb.info/ComponentInfo.class:5: Unknown identifier: String[] Installing gb.info... And so on... I don't know too much about the compilation process so i have been unable to find a solution. Any ideas will be wellcome. -- Thanks in advance, Christian E. L?pez Finnberg From gambas at ...1... Tue Oct 31 20:24:30 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 31 Oct 2006 20:24:30 +0100 Subject: [Gambas-user] Bug or feature with IIF In-Reply-To: <19cca6e50610301731k1990eb57n3b2eea2e9119f5f@...627...> References: <19cca6e50610301731k1990eb57n3b2eea2e9119f5f@...627...> Message-ID: <200610312024.30923.gambas@...1...> On Tuesday 31 October 2006 02:31, Lorenzo Tejera wrote: > I'm trying to use old visual basic code, and this not work > > IIf(bUltimo, "", ",") > > bUltimo is boolean, gambas give an error with the first parameter ("" the > empty string), say "wanted null and give a String instead" > > If I put > > IIf(bUltimo, " ", ",") > > And " " space string works fine, but I can't return a "" empty string..... > > In visual basic it works; it's a bug or a feature benoit? > > regards > Lorenzo It is a bug. Which version of Gambas do you use? -- Benoit Minisini From gambas at ...1... Tue Oct 31 20:25:55 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 31 Oct 2006 20:25:55 +0100 Subject: [Gambas-user] Special Compilation for archlinux. In-Reply-To: <200610311841.07405.christian@...980...> References: <200610311841.07405.christian@...980...> Message-ID: <200610312025.55603.gambas@...1...> On Tuesday 31 October 2006 19:41, Christian E. L?pez Finnberg wrote: > Hi, I'm trying to make the archlinux package. To do the package I have to > compile and install on a temporary directory using the option DESTDIR of > make. Unfortunatelly it does not work. I think the compilation process uses > files created during the same compilation so it does not find the needed > files and i get errors like this: > > Compiling gb.settings... > /home/christian/t/gambas/src/gambas2-1.9.45/comp/src/gb.settings/Settings.c >lass:12: Unknown identifier: Collection Installing gb.settings... > Compiling gb.info... > /home/christian/t/gambas/src/gambas2-1.9.45/comp/src/gb.info/ComponentInfo. >class:5: Unknown identifier: String[] Installing gb.info... > And so on... > > > I don't know too much about the compilation process so i have been unable > to find a solution. Any ideas will be wellcome. Do not use DESTDIR. You must use "prefix": $ make $ make install prefix=/where/you/install/gambas Regards, -- Benoit Minisini From fidojones at ...805... Tue Oct 31 20:40:39 2006 From: fidojones at ...805... (Lorenzo Tejera) Date: Tue, 31 Oct 2006 19:40:39 +0000 Subject: [Gambas-user] Bug or feature with IIF In-Reply-To: <200610312024.30923.gambas@...1...> References: <19cca6e50610301731k1990eb57n3b2eea2e9119f5f@...627...> <200610312024.30923.gambas@...1...> Message-ID: <19cca6e50610311140x1e3e25a8w67139cef4f95b95d@...627...> The last one 1.9.45 2006/10/31, Benoit Minisini : > > On Tuesday 31 October 2006 02:31, Lorenzo Tejera wrote: > > I'm trying to use old visual basic code, and this not work > > > > IIf(bUltimo, "", ",") > > > > bUltimo is boolean, gambas give an error with the first parameter ("" > the > > empty string), say "wanted null and give a String instead" > > > > If I put > > > > IIf(bUltimo, " ", ",") > > > > And " " space string works fine, but I can't return a "" empty > string..... > > > > In visual basic it works; it's a bug or a feature benoit? > > > > regards > > Lorenzo > > It is a bug. Which version of Gambas do you use? > > -- > Benoit Minisini > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From nix.or.die at ...1601... Tue Oct 31 20:48:24 2006 From: nix.or.die at ...1601... (Gabriel C) Date: Tue, 31 Oct 2006 20:48:24 +0100 Subject: [Gambas-user] Special Compilation for archlinux. In-Reply-To: <200610311841.07405.christian@...980...> References: <200610311841.07405.christian@...980...> Message-ID: <4547A888.60304@...1601...> Christian E. L?pez Finnberg wrote: > Hi, I'm trying to make the archlinux package. To do the package I have to compile and install on a temporary directory using the option DESTDIR of make. > Unfortunatelly it does not work. I think the compilation process uses files created during the same compilation so it does not find the needed files and i get errors like this: > > Compiling gb.settings... > /home/christian/t/gambas/src/gambas2-1.9.45/comp/src/gb.settings/Settings.class:12: Unknown identifier: Collection > Installing gb.settings... > Compiling gb.info... > /home/christian/t/gambas/src/gambas2-1.9.45/comp/src/gb.info/ComponentInfo.class:5: Unknown identifier: String[] > Installing gb.info... > And so on... > Yes , I got the same problems on Frugalware. I've solved this ( well may be a hack but there is no other way without to modify the build files and works fine for me) TMP doing: make bindir=$Fdestdir/usr/bin ( $Fdestdir should be $startdir/pkg/usr in ArchLinux ) then make prefix="$Fdestdir/usr" install ( FrugalBuild is here if you want to look at it but is not ArchLinux like , anyway the FB is not done yet ftp://frugalware.org/pub/other/people/crazy/source-testing/gambas2/FrugalBuild ) This problem got introduced in some 0.3X ( can't remeber now ) > > I don't know too much about the compilation process so i have been unable to find a solution. > Any ideas will be wellcome. > > Gabriel From nix.or.die at ...1601... Tue Oct 31 21:06:40 2006 From: nix.or.die at ...1601... (Gabriel C) Date: Tue, 31 Oct 2006 21:06:40 +0100 Subject: [Gambas-user] Special Compilation for archlinux. In-Reply-To: <200610312025.55603.gambas@...1...> References: <200610311841.07405.christian@...980...> <200610312025.55603.gambas@...1...> Message-ID: <4547ACD0.4030705@...1601...> Benoit Minisini wrote: > On Tuesday 31 October 2006 19:41, Christian E. L?pez Finnberg wrote: > >> Hi, I'm trying to make the archlinux package. To do the package I have to >> compile and install on a temporary directory using the option DESTDIR of >> make. Unfortunatelly it does not work. I think the compilation process uses >> files created during the same compilation so it does not find the needed >> files and i get errors like this: >> >> Compiling gb.settings... >> /home/christian/t/gambas/src/gambas2-1.9.45/comp/src/gb.settings/Settings.c >> lass:12: Unknown identifier: Collection Installing gb.settings... >> Compiling gb.info... >> /home/christian/t/gambas/src/gambas2-1.9.45/comp/src/gb.info/ComponentInfo. >> class:5: Unknown identifier: String[] Installing gb.info... >> And so on... >> >> >> I don't know too much about the compilation process so i have been unable >> to find a solution. Any ideas will be wellcome. >> > > Do not use DESTDIR. You must use "prefix": > > $ make > Does only work you already have gambas installed and won't work at all for chroot build. You have in main/share/gb_file_temp.h: snip if (!path) path = GAMBAS_LINK_PATH; } else { path = GAMBAS_PATH "/gbx" GAMBAS_VERSION_STRING; } snip GAMBAS_LINK_PATH is defined in main/share/gb_component.h as : #define GAMBAS_LINK_PATH "/usr/bin/gbx" GAMBAS_VERSION_STRING and GAMBAS_PATH is defined by -DGAMBAS_PATH= which point to $(bindir) so both are set to $(bindir) for an /usr install. Without to have gambas2 installed ( means in a chroot I have add gamabas as makedepend for gambas which is a bit crazy ) I need such a ' make bindir=/point_to_my_install_patch_from_chroot/usr/bin' to get it compiled. I've send you a email about this issue some time ago but never got any answer and I really forgot about :) > $ make install prefix=/where/you/install/gambas > > Regards, > > Gabriel From gambas at ...1... Tue Oct 31 21:07:59 2006 From: gambas at ...1... (Benoit Minisini) Date: Tue, 31 Oct 2006 21:07:59 +0100 Subject: [Gambas-user] Bug or feature with IIF In-Reply-To: <19cca6e50610311140x1e3e25a8w67139cef4f95b95d@...627...> References: <19cca6e50610301731k1990eb57n3b2eea2e9119f5f@...627...> <200610312024.30923.gambas@...1...> <19cca6e50610311140x1e3e25a8w67139cef4f95b95d@...627...> Message-ID: <200610312107.59363.gambas@...1...> On Tuesday 31 October 2006 20:40, Lorenzo Tejera wrote: > The last one 1.9.45 > It is fixed in the svn. -- Benoit Minisini