From gambas at ...1... Mon Dec 1 00:15:19 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 1 Dec 2008 00:15:19 +0100 Subject: [Gambas-user] Updating the Xandros repos In-Reply-To: References: <200811302227.23994.gambas@...1...> Message-ID: <200812010015.19233.gambas@...1...> On dimanche 30 novembre 2008, Charles Capaday wrote: > Hi, > > First let me congratulate you on developing an outstanding product > and being outstanding in supporting it... Would it be possible to update > the Xandros repos to the latest version of gambas, I use it for now to > write simple teaching programs for my eight year old boy. I use the EEE > PC 900 for that, an ideal platform to develop gambas applications I > think. > > Cheers, > > > Dr. Charles Capaday > Professor & Director > Brain and Movement Lab. > Dept. of Anatomy & Physiology > Faculty of Medicine, Laval University > http://www.brainandmovementlab.org/ > > Mailing address: > CRULRG F-6500 > Hopital Robert-Giffard > 2601 de la Canardiere, Beauport, QC > G1J 2G3 Canada > > Tel: +418-663-5747 (Sec.) > +418-663-5000 ext. 6736 (Off.) > +418-663-5000 ext. 6877 (Lab.) > Fax: +418-663-8756 > > You must Xandros for that, I provide Gambas only as source tarballs. Regards, -- Benoit Minisini From gambas at ...1... Mon Dec 1 00:16:34 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 1 Dec 2008 00:16:34 +0100 Subject: [Gambas-user] xslt-tranformation in Gambas 2.9 In-Reply-To: References: Message-ID: <200812010016.34423.gambas@...1...> On dimanche 30 novembre 2008, Jaap Cramer wrote: > Hello > > I use the xml and XSLT.Transform routines. And they seem not te wokr > anymore, from Gambas version 2.9. I saw on the changelog some changes, but > I wonder how to use it correct. > > I want to apply al XSLT tranformation an a XSL sheet. > Code that used to work: > > DIM x_Xslt, x_Q AS NEW XmlDocument > DIM s as String > > s = file.Load("xml/tanach/LastVerse.xml") > > x_Xslt.FromString(s) > x_Q = Xslt.Transform(x, x_xslt) > s = x_Q.ToString("utf-8") > > ____________ > > Any help or documentation? > > tnx in advance. > Jaap > Can you provide a complete project and explain what does not work exactly? -- Benoit Minisini From jaap_cramer at ...67... Mon Dec 1 00:38:57 2008 From: jaap_cramer at ...67... (Jaap Cramer) Date: Mon, 1 Dec 2008 00:38:57 +0100 Subject: [Gambas-user] xslt-tranformation in Gambas 2.9 In-Reply-To: <200812010016.34423.gambas@...1...> References: <200812010016.34423.gambas@...1...> Message-ID: Hi Benoit. because it is part of a huge program, with a lot of data, I wrote this little app. It's lika a function to determine the amount of verses in a chapter of a biblebook (in this case Jonah). The data is from www.tanach.us, freely available. In previous versions of Gambas this sort of routine worked fine. This is the errordiscription: symbol lookup error: /usr/lib/gambas2/gb.xml.xslt.so: undefined symbol: XML_InitDocument I cannot execute the xslt stylesheet transformation. I hope I answered your question? tnx Jaap > From: gambas at ...1... > To: gambas-user at lists.sourceforge.net > Date: Mon, 1 Dec 2008 00:16:34 +0100 > Subject: Re: [Gambas-user] xslt-tranformation in Gambas 2.9 > > On dimanche 30 novembre 2008, Jaap Cramer wrote: > > Hello > > > > I use the xml and XSLT.Transform routines. And they seem not te wokr > > anymore, from Gambas version 2.9. I saw on the changelog some changes, but > > I wonder how to use it correct. > > > > I want to apply al XSLT tranformation an a XSL sheet. > > Code that used to work: > > > > DIM x_Xslt, x_Q AS NEW XmlDocument > > DIM s as String > > > > s = file.Load("xml/tanach/LastVerse.xml") > > > > x_Xslt.FromString(s) > > x_Q = Xslt.Transform(x, x_xslt) > > s = x_Q.ToString("utf-8") > > > > ____________ > > > > Any help or documentation? > > > > tnx in advance. > > Jaap > > > > Can you provide a complete project and explain what does not work exactly? > > -- > Benoit Minisini > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user _________________________________________________________________ Jouw nieuws en entertainment, vind je op MSN.nl! http://nl.msn.com/ -------------- next part -------------- A non-text attachment was scrubbed... Name: xmlbug-0.0.1.tar.gz Type: application/x-gzip Size: 16871 bytes Desc: not available URL: From gambas at ...1... Mon Dec 1 01:07:37 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 1 Dec 2008 01:07:37 +0100 Subject: [Gambas-user] xslt-tranformation in Gambas 2.9 In-Reply-To: References: <200812010016.34423.gambas@...1...> Message-ID: <200812010107.37743.gambas@...1...> On lundi 1 d?cembre 2008, Jaap Cramer wrote: > Hi Benoit. > > because it is part of a huge program, with a lot of data, I wrote this > little app. It's lika a function to determine the amount of verses in a > chapter of a biblebook (in this case Jonah). The data is from > www.tanach.us, freely available. > > In previous versions of Gambas this sort of routine worked fine. This is > the errordiscription: symbol lookup error: /usr/lib/gambas2/gb.xml.xslt.so: > undefined symbol: XML_InitDocument > > I cannot execute the xslt stylesheet transformation. I hope I answered your > question? > > tnx > Jaap > Yes. I made a fix in revision #1718, and I will make a gambas 2.10 soon. Regards, -- Benoit Minisini From rterry at ...1946... Mon Dec 1 03:57:29 2008 From: rterry at ...1946... (richard terry) Date: Mon, 1 Dec 2008 13:57:29 +1100 Subject: [Gambas-user] Ideas needed ?how to track down corruption of png file Message-ID: <200812011357.29563.rterry@...1946...> I've mentioned recently that my re-loading of images from postgres back into my program is failing - the images seem to save correctly but on retrieving them they fail to display in khtml or konqueror if I load the tempfile from the desktop They will load into gimp, albeit with an error message as shown in the accompanying pictures. I wondered if anyone had any clue how to proceed to help me track this down, or suggestions as to another forum one could find out. Regards richard -------------- next part -------------- A non-text attachment was scrubbed... Name: png_error.png Type: image/png Size: 74468 bytes Desc: not available URL: From almodook at ...2007... Mon Dec 1 10:06:38 2008 From: almodook at ...2007... (moon_walker) Date: Mon, 1 Dec 2008 01:06:38 -0800 (PST) Subject: [Gambas-user] Form does not get focus In-Reply-To: <200811302200.28548.gambas@...1...> References: <20742005.post@...1379...> <200811302200.28548.gambas@...1...> Message-ID: <20768344.post@...1379...> Thanks Benoit! br Attila Bugzilla from gambas at ...1... wrote: > > On samedi 29 novembre 2008, moon_walker wrote: >> Hi Gurus, >> >> i have a problem again:-): >> >> PUBLIC SUB TableView3_Menu() >> DIM lform AS Form >> >> lform = NEW dataentry(did.Value, "fertilizer", tableview3.X, >> tableview3.Y) >> lform.showmodal >> >> END >> >> The resulting form do not get the focus upon the opening IF >> dataentry.skiptaskbar = TRUE. :-) >> Is this correct? >> Could you please somebody explain this. >> >> Thanks >> Attila > > This is a bug that was fixed recently, so you will have the fix with the > next > version. > > Regards, > > -- > Benoit Minisini > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge > Build the coolest Linux based applications with Moblin SDK & win great > prizes > Grand prize is a trip for two to an Open Source event anywhere in the > world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > -- View this message in context: http://www.nabble.com/Form-does-not-get-focus-tp20742005p20768344.html Sent from the gambas-user mailing list archive at Nabble.com. From demosthenesk at ...626... Mon Dec 1 10:10:06 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Mon, 1 Dec 2008 11:10:06 +0200 Subject: [Gambas-user] To fast do..loops for process management! In-Reply-To: <200811302227.23994.gambas@...1...> References: <200811302227.23994.gambas@...1...> Message-ID: On Sun, Nov 30, 2008 at 11:27 PM, Benoit Minisini wrote: > On jeudi 27 novembre 2008, Demosthenes Koptsis wrote: >> Hi dear list, >> >> I write a front-end for mpg123 mp3 console player in gambas2 but i >> came face to face with a bug and i need your help! >> i dont know if the bug is due to gambas or my writing code or mpg123 >> player's. >> >> The story is like this.... >> >> '### I have two public vars >> >> PUBLIC hProcess AS Process 'varProcess is a Process variable for SHELL >> command PUBLIC iNrPlayingSong AS Integer 'public var to hold the nr of >> playing song >> >> '### i execute a command to play mp3 songs >> >> ..... >> 'format sting command >> sCommand = "mpg123 -vC@ " & sPlaylistFile 'play in verbose mode >> (v), interactive (C), and load a playlist (@) >> 'execute command >> hProcess = SHELL sCommand FOR INPUT OUTPUT >> ..... >> >> >> '### previous track sub >> PUBLIC SUB btnPreviousTrack_Click() >> >> IF NOT IsNull(hProcess) THEN >> IF hProcess.State = 1 THEN PRINT #hProcess, "d" 'mpg123 recieve >> a keyboard "d" to go previous track >> ENDIF >> >> END >> >> >> '### next track sub >> PUBLIC SUB btnNextTrack_Click() >> >> IF NOT IsNull(hProcess) THEN >> IF hProcess.State = 1 THEN PRINT #hProcess, "f" 'mpg123 recieve >> a keyboard "f" to go next track >> ENDIF >> >> END >> >> '### NOTE, the previous SUBs are the same. They differ only to letters >> "f" and "d" >> >> >> '#### A wait sub for the system, see next! >> PUBLIC SUB WaitSystem() >> >> 'wait the system >> FMain.Mouse = 3 >> WAIT 0.05 >> FMain.Mouse = 0 >> >> END >> >> >> >> '########### So far with no bug, the code is working >> >> >> >> '### i write a sub if user click in playlist a list item = a mp3 track >> >> PUBLIC SUB lvwPlayList_DblClick() >> >> DIM iCounter AS Integer = iNrPlayingSong 'var get current playing >> song and also act as counter. iNrPlayingSong get its value from SUB >> Process_Read() >> >> IF NOT IsNull(lvwPlayList.Key) THEN >> >> '### This do..loop part working fine >> 'if user click an item with key greater than number of playing song >> IF (lvwPlayList.key + 1) > iCounter THEN 'go next track >> DO >> IF iCounter = (lvwPlayList.key + 1) THEN BREAK >> 'PRINT "Go next track" >> btnNextTrack_Click() >> INC iCounter >> LOOP >> ENDIF >> >> 'if user click an item with key smaller than number of playing song >> IF (lvwPlayList.key + 1) < iCounter THEN 'go previous track >> DO >> IF iCounter = (lvwPlayList.key + 1) THEN BREAK >> 'PRINT "Go previous track" >> btnPreviousTrack_Click() >> >> ' ### Now the strange bug >> '!FIXEME! >> ########################################################################### >>######### WaitSystem() '***!!!!!***---> ### [ -- i need to force a wait >> system sub to working correctly --- ] >> 'Probably there is a bug. >> 'the hProcess does not recieve the btnPreviousTrack_Click() command >> as recieves btnNextTrack_Click() >> >> 'The same code in btnNextTrack_Click() works fine. >> 'Sorry for the annoying bug. >> '!FIXEME! >> ########################################################################### >>######### >> >> DEC iCounter >> >> LOOP >> ENDIF >> >> ENDIF >> >> END >> >> '#################### >> >> To test this bug make a long playlist with up to 200 mp3s. >> >> if you check the two subs btnNextTrack_Click() and >> btnPreviousTrack_Click() are the same. >> If you check the two DO..LOOPs parts are the same, they only change in >> btnNextTrack_Click() and btnPreviousTrack_Click(). >> In first case the btnNextTrack_Click() works. >> In second case i need to force a wait to application to work the >> btnPreviousTrack_Click(). >> >> I test to PRINT the vars which they be read from Sub Read_Process and >> they are ok. Vars iNrPlayingSong, iCounter are OK. >> My conclusion is that hProcess cannot recieve so quickly the previous >> command from gambas2. >> So the questions now! >> Is this a bug of mpg123 player or a bug of gambas in process management? >> >> >> I attach my project if you want to look its strange bug. >> >> -- >> >> ???? ???? ?? ?????!!! >> >> Regards, >> >> Demosthenes Koptsis > > I don't really see any bug, but I can be wrong as your code is not very clear. > > What I can tell you is that there is no guarantee that you will get the answer > of a command sent to mpg123 immediately, so the song number stored in your > public variable is not necessarily accurate. I checked the var which holds the number of playing song by PRINT it and is correct. > > Next, the event loop is only run if no code is run, or if you call the WAIT > instruction. That means, i cant get results from a running process with Process_Read when i run code in a do...loop? If this is true i cant run simultaneously processes and loop code! >And the Process_Read function is called only by the event loop! > > Regards, > > -- > Benoit Minisini > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From gambas at ...1... Mon Dec 1 14:23:41 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 1 Dec 2008 14:23:41 +0100 Subject: [Gambas-user] To fast do..loops for process management! In-Reply-To: References: <200811302227.23994.gambas@...1...> Message-ID: <200812011423.42097.gambas@...1...> On lundi 1 d?cembre 2008, Demosthenes Koptsis wrote: > On Sun, Nov 30, 2008 at 11:27 PM, Benoit Minisini > > wrote: > > On jeudi 27 novembre 2008, Demosthenes Koptsis wrote: > >> Hi dear list, > >> > >> I write a front-end for mpg123 mp3 console player in gambas2 but i > >> came face to face with a bug and i need your help! > >> i dont know if the bug is due to gambas or my writing code or mpg123 > >> player's. > >> > >> The story is like this.... > >> > >> '### I have two public vars > >> > >> PUBLIC hProcess AS Process 'varProcess is a Process variable for SHELL > >> command PUBLIC iNrPlayingSong AS Integer 'public var to hold the nr of > >> playing song > >> > >> '### i execute a command to play mp3 songs > >> > >> ..... > >> 'format sting command > >> sCommand = "mpg123 -vC@ " & sPlaylistFile 'play in verbose mode > >> (v), interactive (C), and load a playlist (@) > >> 'execute command > >> hProcess = SHELL sCommand FOR INPUT OUTPUT > >> ..... > >> > >> > >> '### previous track sub > >> PUBLIC SUB btnPreviousTrack_Click() > >> > >> IF NOT IsNull(hProcess) THEN > >> IF hProcess.State = 1 THEN PRINT #hProcess, "d" 'mpg123 recieve > >> a keyboard "d" to go previous track > >> ENDIF > >> > >> END > >> > >> > >> '### next track sub > >> PUBLIC SUB btnNextTrack_Click() > >> > >> IF NOT IsNull(hProcess) THEN > >> IF hProcess.State = 1 THEN PRINT #hProcess, "f" 'mpg123 recieve > >> a keyboard "f" to go next track > >> ENDIF > >> > >> END > >> > >> '### NOTE, the previous SUBs are the same. They differ only to letters > >> "f" and "d" > >> > >> > >> '#### A wait sub for the system, see next! > >> PUBLIC SUB WaitSystem() > >> > >> 'wait the system > >> FMain.Mouse = 3 > >> WAIT 0.05 > >> FMain.Mouse = 0 > >> > >> END > >> > >> > >> > >> '########### So far with no bug, the code is working > >> > >> > >> > >> '### i write a sub if user click in playlist a list item = a mp3 track > >> > >> PUBLIC SUB lvwPlayList_DblClick() > >> > >> DIM iCounter AS Integer = iNrPlayingSong 'var get current playing > >> song and also act as counter. iNrPlayingSong get its value from SUB > >> Process_Read() > >> > >> IF NOT IsNull(lvwPlayList.Key) THEN > >> > >> '### This do..loop part working fine > >> 'if user click an item with key greater than number of playing > >> song IF (lvwPlayList.key + 1) > iCounter THEN 'go next track > >> DO > >> IF iCounter = (lvwPlayList.key + 1) THEN BREAK > >> 'PRINT "Go next track" > >> btnNextTrack_Click() > >> INC iCounter > >> LOOP > >> ENDIF > >> > >> 'if user click an item with key smaller than number of playing > >> song IF (lvwPlayList.key + 1) < iCounter THEN 'go previous track DO > >> IF iCounter = (lvwPlayList.key + 1) THEN BREAK > >> 'PRINT "Go previous track" > >> btnPreviousTrack_Click() > >> > >> ' ### Now the strange bug > >> '!FIXEME! > >> ######################################################################## > >>### ######### WaitSystem() '***!!!!!***---> ### [ -- i need to force a > >> wait system sub to working correctly --- ] > >> 'Probably there is a bug. > >> 'the hProcess does not recieve the btnPreviousTrack_Click() > >> command as recieves btnNextTrack_Click() > >> > >> 'The same code in btnNextTrack_Click() works fine. > >> 'Sorry for the annoying bug. > >> '!FIXEME! > >> ######################################################################## > >>### ######### > >> > >> DEC iCounter > >> > >> LOOP > >> ENDIF > >> > >> ENDIF > >> > >> END > >> > >> '#################### > >> > >> To test this bug make a long playlist with up to 200 mp3s. > >> > >> if you check the two subs btnNextTrack_Click() and > >> btnPreviousTrack_Click() are the same. > >> If you check the two DO..LOOPs parts are the same, they only change in > >> btnNextTrack_Click() and btnPreviousTrack_Click(). > >> In first case the btnNextTrack_Click() works. > >> In second case i need to force a wait to application to work the > >> btnPreviousTrack_Click(). > >> > >> I test to PRINT the vars which they be read from Sub Read_Process and > >> they are ok. Vars iNrPlayingSong, iCounter are OK. > >> My conclusion is that hProcess cannot recieve so quickly the previous > >> command from gambas2. > >> So the questions now! > >> Is this a bug of mpg123 player or a bug of gambas in process management? > >> > >> > >> I attach my project if you want to look its strange bug. > >> > >> -- > >> > >> ???? ???? ?? ?????!!! > >> > >> Regards, > >> > >> Demosthenes Koptsis > > > > I don't really see any bug, but I can be wrong as your code is not very > > clear. > > > > What I can tell you is that there is no guarantee that you will get the > > answer of a command sent to mpg123 immediately, so the song number stored > > in your public variable is not necessarily accurate. > > I checked the var which holds the number of playing song by PRINT it > and is correct. > > > Next, the event loop is only run if no code is run, or if you call the > > WAIT instruction. > > That means, i cant get results from a running process with > Process_Read when i run code in a do...loop? > > If this is true i cant run simultaneously processes and loop code! > The processes will run independantly of your code, but you can't run Process_Read and your own code at the same moment. You must return to the event loop, or use the WAIT instruction to let Process_Read be called. -- Benoit Minisini From gambas at ...1... Mon Dec 1 14:25:10 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 1 Dec 2008 14:25:10 +0100 Subject: [Gambas-user] Ideas needed ?how to track down corruption of png file In-Reply-To: <200812011357.29563.rterry@...1946...> References: <200812011357.29563.rterry@...1946...> Message-ID: <200812011425.10311.gambas@...1...> On lundi 1 d?cembre 2008, richard terry wrote: > I've mentioned recently that my re-loading of images from postgres back > into my program is failing - the images seem to save correctly but on > retrieving them they fail to display in khtml or konqueror if I load the > tempfile from the desktop > > They will load into gimp, albeit with an error message as shown in the > accompanying pictures. > > I wondered if anyone had any clue how to proceed to help me track this > down, or suggestions as to another forum one could find out. > > Regards > > richard Can you make a copy of the the PictureDatabase example, change its source code to use your postgresql database, and try to load then save the same image, and see if it corrupted? -- Benoit Minisini From gambas at ...1... Mon Dec 1 14:35:00 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 1 Dec 2008 14:35:00 +0100 Subject: [Gambas-user] Using a socket to download an image. Please Help ^_^ In-Reply-To: References: Message-ID: <200812011435.00501.gambas@...1...> On dimanche 30 novembre 2008, Robert Moss wrote: > The ImgData stops writing when it comes to a byte with value &H00 (I > believe) although I'm pretty sure it doesn't matter how I write the stream, > once it's read as a String, it becomes terminated by any NULL char. So my > question is this: How do I read the data from the Socket in binary, write > it to a stream file in binary, but STILL I MUST be able to split the data > based on the 2 CRLF's > Strange, it should work. I mean: zero bytes in a string does not matter, as soon as the string is not passed through some methods of components written in C/C++, because there strings sometimes needs to be zero terminated. You can read/write arrays from streams if you need: they all have a Read method and a Write method for that. Anyway can you send me your full source code? -- Benoit Minisini From rterry at ...1946... Mon Dec 1 21:39:30 2008 From: rterry at ...1946... (richard terry) Date: Tue, 2 Dec 2008 07:39:30 +1100 Subject: [Gambas-user] Ideas needed ?how to track down corruption of png file In-Reply-To: <200812011425.10311.gambas@...1...> References: <200812011357.29563.rterry@...1946...> <200812011425.10311.gambas@...1...> Message-ID: <200812020739.31127.rterry@...1946...> On Tue, 2 Dec 2008 12:25:10 am you wrote: > On lundi 1 d?cembre 2008, richard terry wrote: > > I've mentioned recently that my re-loading of images from postgres back > > into my program is failing - the images seem to save correctly but on > > retrieving them they fail to display in khtml or konqueror if I load the > > tempfile from the desktop > > > > They will load into gimp, albeit with an error message as shown in the > > accompanying pictures. > > > > I wondered if anyone had any clue how to proceed to help me track this > > down, or suggestions as to another forum one could find out. > > > > Regards > > > > richard > > Can you make a copy of the the PictureDatabase example, change its source > code to use your postgresql database, and try to load then save the same > image, and see if it corrupted? Ok, I will try, I did copy this module in the first place so used the same code exactly, however I will maybe try and create a mini database with one table and send you the code. However, of interest I looked at png files created in any paint program, or using gambas, they all have this structure: ?PNG  IHDR IEND?B`? Now, the string that gets sent to postgres, looks like this: \\211PNG\\015\\012\\032\\012\\000\\000\\000\\015IHDR\\000\\000\\000\ \214#\\323\\000\\000\\000\\000IEND\\256B`\\202 However, when pulled back from postgres and re-constituted (using the same code as in the picture database, this bit is missing off the end: IEND?B`?. Gimp will ignore that, and load the picture with an error, but most other paint programs throw up a libpng error a and baulk. I will try as I say to make a small program so someone else can look at it. Regards and thanks. Richard From ste.sullivan at ...626... Mon Dec 1 21:47:11 2008 From: ste.sullivan at ...626... (Stephen Sullivan) Date: Mon, 1 Dec 2008 20:47:11 +0000 Subject: [Gambas-user] On Gentoo 64-bit... Message-ID: Just to report: Gambas works fine on gentoo 64-bit, but the e-build is horribly broken (i could not get the portage version to build at all). I built it from the latest stable source package (./configure && make && make install) which worked without any hassle. Having said this I have had Gambas quit unexpectedly, but I was not trapping the errors and haven't been able to replicate it. Hope this is of help! Keep up the excellent work! Stephen From fredrik_hansson at ...1788... Tue Dec 2 08:14:08 2008 From: fredrik_hansson at ...1788... (Fredrik Hansson) Date: Tue, 02 Dec 2008 08:14:08 +0100 Subject: [Gambas-user] Gambas pgm won't start at all Message-ID: <1228202048.7764.5.camel@...1789...> At my office we have an application written by me in Gambas. One user can't execute it, no matter where she logs on. Everybode else can run the application on every computer. We all have our own Desktop and the .gambas file is there. Seems that this poor user has an error making it impossible for the system to connect .gambas files to /usr/bin/gbx. Does anyone know where that connection is located - I suppose it's written in some config file somewhere. And yes, we have tried forcing by specifying gbx in "Properties"-->"Open with" for the -gambas-file on the Desktop. /Fredrik Hansson From pokerbirch at ...1601... Tue Dec 2 13:43:56 2008 From: pokerbirch at ...1601... (birchy) Date: Tue, 2 Dec 2008 04:43:56 -0800 (PST) Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <20759131.post@...1379...> References: <20435022.post@...1379...> <200811111555.45564.gambas@...1...> <200811111601.49341.gambas@...1...> <20759131.post@...1379...> Message-ID: <20791388.post@...1379...> bump....because i'm really trying to avoid learning java instead... -- View this message in context: http://www.nabble.com/Web-application---CURL-and-Cookies--tp20435022p20791388.html Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Tue Dec 2 14:50:47 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 2 Dec 2008 14:50:47 +0100 Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <20791388.post@...1379...> References: <20435022.post@...1379...> <20759131.post@...1379...> <20791388.post@...1379...> Message-ID: <200812021450.47939.gambas@...1...> On mardi 2 d?cembre 2008, birchy wrote: > bump....because i'm really trying to avoid learning java instead... DIM hXmlDoc AS NEW XmlDocument DIM sHTML AS String sHTML = GetHTMLFromSomewhere() hXmlDoc.HTMLFromString(sHTML) ... -- Benoit Minisini From gambas at ...1... Tue Dec 2 14:51:56 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 2 Dec 2008 14:51:56 +0100 Subject: [Gambas-user] Gambas pgm won't start at all In-Reply-To: <1228202048.7764.5.camel@...1789...> References: <1228202048.7764.5.camel@...1789...> Message-ID: <200812021451.56995.gambas@...1...> On mardi 2 d?cembre 2008, Fredrik Hansson wrote: > At my office we have an application written by me in Gambas. > One user can't execute it, no matter where she logs on. > Everybode else can run the application on every computer. > We all have our own Desktop and the .gambas file is there. > Seems that this poor user has an error making it impossible for the > system to connect .gambas files to /usr/bin/gbx. Does anyone know where > that connection is located - I suppose it's written in some config file > somewhere. > > And yes, we have tried forcing by specifying gbx in "Properties"-->"Open > with" for the -gambas-file on the Desktop. > > /Fredrik Hansson > Can you provide more details? Which version of Gambas exactly do you run? Which distribution do you use? How was Gambas installed? -- Benoit Minisini From gambas at ...1... Tue Dec 2 15:06:46 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 2 Dec 2008 15:06:46 +0100 Subject: [Gambas-user] using icons from system theme without specifiying full path In-Reply-To: <4247f5440811300933h764f9271uf56edb71a093ec87@...627...> References: <4247f5440811300323q372d25fdpd9adfaf8ff0b67af@...627...> <20759098.post@...1379...> <4247f5440811300933h764f9271uf56edb71a093ec87@...627...> Message-ID: <200812021506.46244.gambas@...1...> On dimanche 30 novembre 2008, Joshua Higgins wrote: > well.... I'm making an application launcher. It reads all the .desktop > files from under /usr/share/applications and after loads of splitting adds > them to a ListView. > > .desktop file layed out as follows: > > [Desktop Entry] > Type=Application > Name=Inkscape > Comment=Vector Graphics Editor > Exec=inkscape > Icon=inkscape.png > Categories=GNOME;Utility; > > The problem I'm having is that the icons are described as they are in the > theme, i.e. just the file name, not by the path, and I'm struggling to find > a reliable way to resolve this back to the path to the icon, which I can > then load into Gambas. > Gambas internally uses its own algorithm to get desktop icons from theme, because it needs to get the current icon theme first, which depends on the current desktop being used. Then it use a desktop-dependent method to get the path of the icon theme. But the real algorithm you must follow is described by a freedesktop standard at: http://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html Regards, -- Benoit Minisini From pokerbirch at ...1601... Tue Dec 2 15:10:15 2008 From: pokerbirch at ...1601... (birchy) Date: Tue, 2 Dec 2008 06:10:15 -0800 (PST) Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <200812021450.47939.gambas@...1...> References: <20435022.post@...1379...> <200811111555.45564.gambas@...1...> <200811111601.49341.gambas@...1...> <20759131.post@...1379...> <20791388.post@...1379...> <200812021450.47939.gambas@...1...> Message-ID: <20792906.post@...1379...> Benoit Minisini wrote: > > hXmlDoc.HTMLFromString(sHTML) Thank you for your reply. I setup a quick test app and using the http://www.google.co.uk google homepage HTML gives me lots of errors when i call: hXmlDoc.HTMLFromString(sHTML) The errors are: HTML parser error : Tag nobr invalid age().src='/images/nav_logo3.png'" topmargin=3 marginheight=3>
Web "http://images.google.co.uk/imghp?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' r.qs(this) class=gb1 Images "http://maps.google.co.uk/maps?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' ar.qs(this) class=gb1 Maps "http://news.google.co.uk/nwshp?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' bar.qs(this) class=gb1 News "http://www.google.co.uk/prdhp?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' .qs(this) class=gb1 Shopping "http://mail.google.com/mail/?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' ll ▼
"http://video.google.co.uk/?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' qs(this) class=gb2 Video "http://groups.google.co.uk/grphp?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' qs(this) class=gb2 Groups "http://books.google.co.uk/bkshp?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' s(this) class=gb2 Books "http://scholar.google.co.uk/schhp?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' is) class=gb2 Scholar "http://finance.google.co.uk/finance?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' s(this) class=gb2 Finance "http://blogsearch.google.co.uk/?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' class=gb2
"http://uk.youtube.com/?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' ) class=gb2 YouTube http://www.google.com/calendar/render?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' wc Calendar "http://picasaweb.google.co.uk/home?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' ck=gbar.qs(this) class=gb2 Photos "http://docs.google.com/?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' class=gb2 Documents http://www.google.co.uk/reader/view/?hl=en&tab ^ HTML parser error : htmlParseEntityRef: expecting ';' /?hl=en&tab=wy Reader http://sites.google.com/?hl=en&tab ^ HTML parser error : Tag nobr invalid
/url?sa=p&pref ^ HTML parser error : htmlParseEntityRef: expecting ';' /url?sa=p&pref=ig&pval ^ HTML parser error : htmlParseEntityRef: expecting ';' t-size:84%;padding:0 0 4px /url?sa=p&pref=ig&pval=3&q ^ HTML parser error : htmlParseEntityRef: expecting ';' l?sa=p&pref=ig&pval=3&q=http://www.google.co.uk/ig%3Fhl%3Den%26source%3Diglk&usg ^ HTML parser error : htmlParseEntityRef: expecting ';' href= -- View this message in context: http://www.nabble.com/Web-application---CURL-and-Cookies--tp20435022p20792906.html Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Tue Dec 2 15:21:52 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 2 Dec 2008 15:21:52 +0100 Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <20792906.post@...1379...> References: <20435022.post@...1379...> <200812021450.47939.gambas@...1...> <20792906.post@...1379...> Message-ID: <200812021521.52101.gambas@...1...> On mardi 2 d?cembre 2008, birchy wrote: > Benoit Minisini wrote: > > hXmlDoc.HTMLFromString(sHTML) > > Thank you for your reply. I setup a quick test app and using the > http://www.google.co.uk google homepage HTML gives me lots of errors when > i call: > > hXmlDoc.HTMLFromString(sHTML) > > The errors are: > HTML parser error : Tag nobr invalid > age().src='/images/nav_logo3.png'" topmargin=3 marginheight=3>
id=gbar> > ^ > HTML parser error : htmlParseEntityRef: expecting ';' > r>Web "http://images.google.co.uk/imghp?hl=en&tab > > ... And so? You found less errors than the W3C HTML validator than returns sixty errors for the same page. :-) Maybe you should try some better HTML pages... -- Benoit Minisini From pokerbirch at ...1601... Tue Dec 2 15:33:42 2008 From: pokerbirch at ...1601... (birchy) Date: Tue, 2 Dec 2008 06:33:42 -0800 (PST) Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <200812021521.52101.gambas@...1...> References: <20435022.post@...1379...> <200811111555.45564.gambas@...1...> <200811111601.49341.gambas@...1...> <20759131.post@...1379...> <20791388.post@...1379...> <200812021450.47939.gambas@...1...> <20792906.post@...1379...> <200812021521.52101.gambas@...1...> Message-ID: <20793347.post@...1379...> Benoit Minisini wrote: > Maybe you should try some better HTML pages... Or maybe i should step backwards and manually parse my targets with InStr() and Mid(). OR, learn Java and use something like TagSoup which can (allegedly) handle "wild" html... -- View this message in context: http://www.nabble.com/Web-application---CURL-and-Cookies--tp20435022p20793347.html Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Tue Dec 2 15:42:03 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 2 Dec 2008 15:42:03 +0100 Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <20793347.post@...1379...> References: <20435022.post@...1379...> <200812021521.52101.gambas@...1...> <20793347.post@...1379...> Message-ID: <200812021542.04023.gambas@...1...> On mardi 2 d?cembre 2008, birchy wrote: > Benoit Minisini wrote: > > Maybe you should try some better HTML pages... > > Or maybe i should step backwards and manually parse my targets with InStr() > and Mid(). OR, learn Java and use something like TagSoup which can > (allegedly) handle "wild" html... If I understand, you want to parse HTML as a browser can do. This is one of the most complex things to do. There is almost no correct HTML page on the web (it is difficult to do so), and two browsers will render them differently. Maybe if you explain precisely what you need I could give you some advice? -- Benoit Minisini From joshiggins at ...1601... Tue Dec 2 20:29:00 2008 From: joshiggins at ...1601... (Joshua Higgins) Date: Tue, 2 Dec 2008 19:29:00 +0000 Subject: [Gambas-user] using icons from system theme without specifiying full path In-Reply-To: <200812021506.46244.gambas@...1...> References: <4247f5440811300323q372d25fdpd9adfaf8ff0b67af@...627...> <20759098.post@...1379...> <4247f5440811300933h764f9271uf56edb71a093ec87@...627...> <200812021506.46244.gambas@...1...> Message-ID: <4247f5440812021129s1f6c20e2rcee12b38328b12e@...627...> Okay, I've got a bash script which you hand a .desktop file and it searches and returns the path of the icon (i'll post if anyone else is interested). but... not all the icons are the same size. Is there a way (without manually resizing them) to have a consistent icon size in a ListView? 2008/12/2 Benoit Minisini > On dimanche 30 novembre 2008, Joshua Higgins wrote: > > well.... I'm making an application launcher. It reads all the .desktop > > files from under /usr/share/applications and after loads of splitting > adds > > them to a ListView. > > > > .desktop file layed out as follows: > > > > [Desktop Entry] > > Type=Application > > Name=Inkscape > > Comment=Vector Graphics Editor > > Exec=inkscape > > Icon=inkscape.png > > Categories=GNOME;Utility; > > > > The problem I'm having is that the icons are described as they are in the > > theme, i.e. just the file name, not by the path, and I'm struggling to > find > > a reliable way to resolve this back to the path to the icon, which I can > > then load into Gambas. > > > > Gambas internally uses its own algorithm to get desktop icons from theme, > because it needs to get the current icon theme first, which depends on the > current desktop being used. Then it use a desktop-dependent method to get > the > path of the icon theme. > > But the real algorithm you must follow is described by a freedesktop > standard > at: > > > http://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html > > Regards, > > -- > Benoit Minisini > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge > Build the coolest Linux based applications with Moblin SDK & win great > prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- joshua higgins >>>>>>------ From joshiggins at ...1601... Tue Dec 2 21:00:36 2008 From: joshiggins at ...1601... (joshiggins) Date: Tue, 2 Dec 2008 12:00:36 -0800 (PST) Subject: [Gambas-user] using icons from system theme without specifiying full path In-Reply-To: <4247f5440812021129s1f6c20e2rcee12b38328b12e@...627...> References: <4247f5440811300323q372d25fdpd9adfaf8ff0b67af@...627...> <20759098.post@...1379...> <4247f5440811300933h764f9271uf56edb71a093ec87@...627...> <200812021506.46244.gambas@...1...> <4247f5440812021129s1f6c20e2rcee12b38328b12e@...627...> Message-ID: <20799703.post@...1379...> Found the answer: Image.Load("pathtoimage").Stretch(24, 24, TRUE).Picture joshiggins wrote: > > Okay, I've got a bash script which you hand a .desktop file and it > searches > and returns the path of the icon (i'll post if anyone else is interested). > > but... not all the icons are the same size. Is there a way (without > manually > resizing them) to have a consistent icon size in a ListView? > > 2008/12/2 Benoit Minisini > >> On dimanche 30 novembre 2008, Joshua Higgins wrote: >> > well.... I'm making an application launcher. It reads all the .desktop >> > files from under /usr/share/applications and after loads of splitting >> adds >> > them to a ListView. >> > >> > .desktop file layed out as follows: >> > >> > [Desktop Entry] >> > Type=Application >> > Name=Inkscape >> > Comment=Vector Graphics Editor >> > Exec=inkscape >> > Icon=inkscape.png >> > Categories=GNOME;Utility; >> > >> > The problem I'm having is that the icons are described as they are in >> the >> > theme, i.e. just the file name, not by the path, and I'm struggling to >> find >> > a reliable way to resolve this back to the path to the icon, which I >> can >> > then load into Gambas. >> > >> >> Gambas internally uses its own algorithm to get desktop icons from theme, >> because it needs to get the current icon theme first, which depends on >> the >> current desktop being used. Then it use a desktop-dependent method to get >> the >> path of the icon theme. >> >> But the real algorithm you must follow is described by a freedesktop >> standard >> at: >> >> >> http://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html >> >> Regards, >> >> -- >> Benoit Minisini >> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's >> challenge >> Build the coolest Linux based applications with Moblin SDK & win great >> prizes >> Grand prize is a trip for two to an Open Source event anywhere in the >> world >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > > -- > joshua higgins >>>>>>>------ > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge > Build the coolest Linux based applications with Moblin SDK & win great > prizes > Grand prize is a trip for two to an Open Source event anywhere in the > world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > -- View this message in context: http://www.nabble.com/using-icons-from-system-theme-without-specifiying-full-path-tp20756670p20799703.html Sent from the gambas-user mailing list archive at Nabble.com. From demosthenesk at ...626... Wed Dec 3 09:40:07 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Wed, 3 Dec 2008 10:40:07 +0200 Subject: [Gambas-user] openSuse11 and libSDL.la Message-ID: I try to install gambas2-2.9.0 in openSuse11.0 and i get an error in make procedure There is a problem with location of libSDL.la file grep: /usr/local/lib/libSDL.la: No such file or directory /usr/bin/sed: can't read /usr/local/lib/libSDL.la: No such file or directory libtool: link: `/usr/local/lib/libSDL.la' is not a valid libtool archive make[4]: *** [gb.sdl.sound.la] Error 1 make[4]: Leaving directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound/src' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound' make[2]: *** [all] Error 2 make[2]: Leaving directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0' make: *** [all] Error 2 Making install in main make[1]: Entering directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main' Making install in libltdl make[2]: Entering directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl' make[3]: Entering directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl' test -z "/usr/local/lib" || /bin/mkdir -p "/usr/local/lib" test -z "/usr/local/include" || /bin/mkdir -p "/usr/local/include" make[3]: Leaving directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl' make[2]: Leaving directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl' Making install in gbx make[2]: Entering directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' make[3]: Entering directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' test -z "/usr/local/bin" || /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/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' make[2]: *** [install-am] Error 2 make[2]: Leaving directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' make[1]: *** [install-recursive] Error 1 make[1]: Leaving directory `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main' make: *** [install-recursive] Error 1 1) The file libSDL.la is in /usr/lib and not in /usr/local/lib. 2) i run the command ( ./configure; make; make install ) > output.txt 2>&1 as user 3) configure disables these components ************************************************************ THESE COMPONENTS ARE DISABLED: - gb.corba - gb.db.firebird - gb.qte ************************************************************ 4) i attach the output.txt. i dont know what other info to provide, tell me what you need to mention. -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis -------------- next part -------------- A non-text attachment was scrubbed... Name: output.zip Type: application/zip Size: 17455 bytes Desc: not available URL: From gambas at ...1... Wed Dec 3 10:32:55 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 3 Dec 2008 10:32:55 +0100 Subject: [Gambas-user] openSuse11 and libSDL.la In-Reply-To: References: Message-ID: <200812031032.56009.gambas@...1...> On mercredi 3 d?cembre 2008, Demosthenes Koptsis wrote: > I try to install gambas2-2.9.0 in openSuse11.0 and i get an error in > make procedure > > There is a problem with location of libSDL.la file > > grep: /usr/local/lib/libSDL.la: No such file or directory > /usr/bin/sed: can't read /usr/local/lib/libSDL.la: No such file or > directory libtool: link: `/usr/local/lib/libSDL.la' is not a valid libtool > archive make[4]: *** [gb.sdl.sound.la] Error 1 > make[4]: Leaving directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >/src' make[3]: *** [all-recursive] Error 1 > make[3]: Leaving directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >' make[2]: *** [all] Error 2 > make[2]: Leaving directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >' make[1]: *** [all-recursive] Error 1 > make[1]: Leaving directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0' > make: *** [all] Error 2 > Making install in main > make[1]: Entering directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main' > Making install in libltdl > make[2]: Entering directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >' make[3]: Entering directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >' test -z "/usr/local/lib" || /bin/mkdir -p "/usr/local/lib" > test -z "/usr/local/include" || /bin/mkdir -p "/usr/local/include" > make[3]: Leaving directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >' make[2]: Leaving directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >' Making install in gbx > make[2]: Entering directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' > make[3]: Entering directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' > test -z "/usr/local/bin" || /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/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' > make[2]: *** [install-am] Error 2 > make[2]: Leaving directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' > make[1]: *** [install-recursive] Error 1 > make[1]: Leaving directory > `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main' > make: *** [install-recursive] Error 1 > > > > 1) The file libSDL.la is in /usr/lib and not in /usr/local/lib. > > 2) i run the command ( ./configure; make; make install ) > output.txt > 2>&1 as user > 3) configure disables these components > ************************************************************ > > THESE COMPONENTS ARE DISABLED: > > - gb.corba > - gb.db.firebird > - gb.qte > > ************************************************************ > > > 4) i attach the output.txt. > > i dont know what other info to provide, tell me what you need to mention. Maybe there is a problem in the SDL_mixer.la file. Can you find this file and send me its contents? -- Benoit Minisini From demosthenesk at ...626... Wed Dec 3 11:59:24 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Wed, 3 Dec 2008 12:59:24 +0200 Subject: [Gambas-user] openSuse11 and libSDL.la In-Reply-To: <200812031032.56009.gambas@...1...> References: <200812031032.56009.gambas@...1...> Message-ID: There is no SDL_mixer.la but /usr/lib/libSDL_mixer.la Ok these are the contents of it:: # libSDL_mixer.la - a libtool library file # Generated by ltmain.sh - GNU libtool 1.5.22 (1.1220.2.365 2005/12/18 22:14:06) # # Please DO NOT delete this file! # It is necessary for linking the library. # The name that we can dlopen(3). dlname='libSDL_mixer-1.2.so.0' # Names of this library. library_names='libSDL_mixer-1.2.so.0.2.6 libSDL_mixer-1.2.so.0 libSDL_mixer.so' # The name of the static archive. old_library='libSDL_mixer.a' # Libraries that this one depends upon. dependency_libs=' -L/usr/local/lib /usr/local/lib/libSDL.la -lm -ldl -lpthread' # Version information for libSDL_mixer. current=2 age=2 revision=6 # Is this an already installed library? installed=yes # Should we warn about portability when linking against -modules? shouldnotlink=no # Files to dlopen/dlpreopen dlopen='' dlpreopen='' # Directory that this library needs to be installed in: libdir='/usr/lib' i chenged the path from /usr/local/lib to /usr/lib and now the problem is solved. i can run "make" and "make install" with no error! On 12/3/08, Benoit Minisini wrote: > On mercredi 3 d?cembre 2008, Demosthenes Koptsis wrote: >> I try to install gambas2-2.9.0 in openSuse11.0 and i get an error in >> make procedure >> >> There is a problem with location of libSDL.la file >> >> grep: /usr/local/lib/libSDL.la: No such file or directory >> /usr/bin/sed: can't read /usr/local/lib/libSDL.la: No such file or >> directory libtool: link: `/usr/local/lib/libSDL.la' is not a valid libtool >> archive make[4]: *** [gb.sdl.sound.la] Error 1 >> make[4]: Leaving directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >>/src' make[3]: *** [all-recursive] Error 1 >> make[3]: Leaving directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >>' make[2]: *** [all] Error 2 >> make[2]: Leaving directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >>' make[1]: *** [all-recursive] Error 1 >> make[1]: Leaving directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0' >> make: *** [all] Error 2 >> Making install in main >> make[1]: Entering directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main' >> Making install in libltdl >> make[2]: Entering directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >>' make[3]: Entering directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >>' test -z "/usr/local/lib" || /bin/mkdir -p "/usr/local/lib" >> test -z "/usr/local/include" || /bin/mkdir -p "/usr/local/include" >> make[3]: Leaving directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >>' make[2]: Leaving directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >>' Making install in gbx >> make[2]: Entering directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' >> make[3]: Entering directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' >> test -z "/usr/local/bin" || /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/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' >> make[2]: *** [install-am] Error 2 >> make[2]: Leaving directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' >> make[1]: *** [install-recursive] Error 1 >> make[1]: Leaving directory >> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main' >> make: *** [install-recursive] Error 1 >> >> >> >> 1) The file libSDL.la is in /usr/lib and not in /usr/local/lib. >> >> 2) i run the command ( ./configure; make; make install ) > output.txt >> 2>&1 as user >> 3) configure disables these components >> ************************************************************ >> >> THESE COMPONENTS ARE DISABLED: >> >> - gb.corba >> - gb.db.firebird >> - gb.qte >> >> ************************************************************ >> >> >> 4) i attach the output.txt. >> >> i dont know what other info to provide, tell me what you need to mention. > > Maybe there is a problem in the SDL_mixer.la file. Can you find this file > and > send me its contents? > > -- > Benoit Minisini > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great > prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From demosthenesk at ...626... Wed Dec 3 12:00:16 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Wed, 3 Dec 2008 13:00:16 +0200 Subject: [Gambas-user] openSuse11 and libSDL.la In-Reply-To: References: <200812031032.56009.gambas@...1...> Message-ID: Thanks Benoit! On 12/3/08, Demosthenes Koptsis wrote: > There is no SDL_mixer.la but /usr/lib/libSDL_mixer.la > > Ok these are the contents of it:: > > # libSDL_mixer.la - a libtool library file > # Generated by ltmain.sh - GNU libtool 1.5.22 (1.1220.2.365 2005/12/18 > 22:14:06) > # > # Please DO NOT delete this file! > # It is necessary for linking the library. > > # The name that we can dlopen(3). > dlname='libSDL_mixer-1.2.so.0' > > # Names of this library. > library_names='libSDL_mixer-1.2.so.0.2.6 libSDL_mixer-1.2.so.0 > libSDL_mixer.so' > > # The name of the static archive. > old_library='libSDL_mixer.a' > > # Libraries that this one depends upon. > dependency_libs=' -L/usr/local/lib /usr/local/lib/libSDL.la -lm -ldl > -lpthread' > > # Version information for libSDL_mixer. > current=2 > age=2 > revision=6 > > # Is this an already installed library? > installed=yes > > # Should we warn about portability when linking against -modules? > shouldnotlink=no > > # Files to dlopen/dlpreopen > dlopen='' > dlpreopen='' > > # Directory that this library needs to be installed in: > libdir='/usr/lib' > > i chenged the path from /usr/local/lib to /usr/lib > > and now the problem is solved. > i can run "make" and "make install" with no error! > > > On 12/3/08, Benoit Minisini wrote: >> On mercredi 3 d?cembre 2008, Demosthenes Koptsis wrote: >>> I try to install gambas2-2.9.0 in openSuse11.0 and i get an error in >>> make procedure >>> >>> There is a problem with location of libSDL.la file >>> >>> grep: /usr/local/lib/libSDL.la: No such file or directory >>> /usr/bin/sed: can't read /usr/local/lib/libSDL.la: No such file or >>> directory libtool: link: `/usr/local/lib/libSDL.la' is not a valid >>> libtool >>> archive make[4]: *** [gb.sdl.sound.la] Error 1 >>> make[4]: Leaving directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >>>/src' make[3]: *** [all-recursive] Error 1 >>> make[3]: Leaving directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >>>' make[2]: *** [all] Error 2 >>> make[2]: Leaving directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/gb.sdl.sound >>>' make[1]: *** [all-recursive] Error 1 >>> make[1]: Leaving directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0' >>> make: *** [all] Error 2 >>> Making install in main >>> make[1]: Entering directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main' >>> Making install in libltdl >>> make[2]: Entering directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >>>' make[3]: Entering directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >>>' test -z "/usr/local/lib" || /bin/mkdir -p "/usr/local/lib" >>> test -z "/usr/local/include" || /bin/mkdir -p "/usr/local/include" >>> make[3]: Leaving directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >>>' make[2]: Leaving directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/libltdl >>>' Making install in gbx >>> make[2]: Entering directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' >>> make[3]: Entering directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' >>> test -z "/usr/local/bin" || /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/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' >>> make[2]: *** [install-am] Error 2 >>> make[2]: Leaving directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main/gbx' >>> make[1]: *** [install-recursive] Error 1 >>> make[1]: Leaving directory >>> `/home/user/Pliroforiki/DEVELOPMENT/Basic/gambas/gambas2-2.9.0/main' >>> make: *** [install-recursive] Error 1 >>> >>> >>> >>> 1) The file libSDL.la is in /usr/lib and not in /usr/local/lib. >>> >>> 2) i run the command ( ./configure; make; make install ) > output.txt >>> 2>&1 as user >>> 3) configure disables these components >>> ************************************************************ >>> >>> THESE COMPONENTS ARE DISABLED: >>> >>> - gb.corba >>> - gb.db.firebird >>> - gb.qte >>> >>> ************************************************************ >>> >>> >>> 4) i attach the output.txt. >>> >>> i dont know what other info to provide, tell me what you need to mention. >> >> Maybe there is a problem in the SDL_mixer.la file. Can you find this file >> and >> send me its contents? >> >> -- >> Benoit Minisini >> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's >> challenge >> Build the coolest Linux based applications with Moblin SDK & win great >> prizes >> Grand prize is a trip for two to an Open Source event anywhere in the >> world >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > -- > > ???? ???? ?? ?????!!! > > Regards, > > Demosthenes Koptsis > -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From gambas at ...1... Wed Dec 3 12:06:21 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 3 Dec 2008 12:06:21 +0100 Subject: [Gambas-user] openSuse11 and libSDL.la In-Reply-To: References: <200812031032.56009.gambas@...1...> Message-ID: <200812031206.21454.gambas@...1...> On mercredi 3 d?cembre 2008, Demosthenes Koptsis wrote: > There is no SDL_mixer.la but /usr/lib/libSDL_mixer.la > > Ok these are the contents of it:: > > # libSDL_mixer.la - a libtool library file > # Generated by ltmain.sh - GNU libtool 1.5.22 (1.1220.2.365 2005/12/18 > 22:14:06) # > # Please DO NOT delete this file! > # It is necessary for linking the library. > > # The name that we can dlopen(3). > dlname='libSDL_mixer-1.2.so.0' > > # Names of this library. > library_names='libSDL_mixer-1.2.so.0.2.6 libSDL_mixer-1.2.so.0 > libSDL_mixer.so' > > # The name of the static archive. > old_library='libSDL_mixer.a' > > # Libraries that this one depends upon. > dependency_libs=' -L/usr/local/lib /usr/local/lib/libSDL.la -lm -ldl > -lpthread' > > # Version information for libSDL_mixer. > current=2 > age=2 > revision=6 > > # Is this an already installed library? > installed=yes > > # Should we warn about portability when linking against -modules? > shouldnotlink=no > > # Files to dlopen/dlpreopen > dlopen='' > dlpreopen='' > > # Directory that this library needs to be installed in: > libdir='/usr/lib' > > i chenged the path from /usr/local/lib to /usr/lib > > and now the problem is solved. > i can run "make" and "make install" with no error! > So apparently this is a bug in SuSE. Maybe you should send them a bug report? -- Benoit Minisini From demosthenesk at ...626... Wed Dec 3 12:40:07 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Wed, 3 Dec 2008 13:40:07 +0200 Subject: [Gambas-user] openSuse11 and libSDL.la In-Reply-To: <200812031206.21454.gambas@...1...> References: <200812031032.56009.gambas@...1...> <200812031206.21454.gambas@...1...> Message-ID: yes it seems so! i will send an email or a post in openSuse forum. On 12/3/08, Benoit Minisini wrote: > On mercredi 3 d?cembre 2008, Demosthenes Koptsis wrote: >> There is no SDL_mixer.la but /usr/lib/libSDL_mixer.la >> >> Ok these are the contents of it:: >> >> # libSDL_mixer.la - a libtool library file >> # Generated by ltmain.sh - GNU libtool 1.5.22 (1.1220.2.365 2005/12/18 >> 22:14:06) # >> # Please DO NOT delete this file! >> # It is necessary for linking the library. >> >> # The name that we can dlopen(3). >> dlname='libSDL_mixer-1.2.so.0' >> >> # Names of this library. >> library_names='libSDL_mixer-1.2.so.0.2.6 libSDL_mixer-1.2.so.0 >> libSDL_mixer.so' >> >> # The name of the static archive. >> old_library='libSDL_mixer.a' >> >> # Libraries that this one depends upon. >> dependency_libs=' -L/usr/local/lib /usr/local/lib/libSDL.la -lm -ldl >> -lpthread' >> >> # Version information for libSDL_mixer. >> current=2 >> age=2 >> revision=6 >> >> # Is this an already installed library? >> installed=yes >> >> # Should we warn about portability when linking against -modules? >> shouldnotlink=no >> >> # Files to dlopen/dlpreopen >> dlopen='' >> dlpreopen='' >> >> # Directory that this library needs to be installed in: >> libdir='/usr/lib' >> >> i chenged the path from /usr/local/lib to /usr/lib >> >> and now the problem is solved. >> i can run "make" and "make install" with no error! >> > > So apparently this is a bug in SuSE. Maybe you should send them a bug > report? > > -- > Benoit Minisini > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great > prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From david_villalobos_c at ...43... Wed Dec 3 15:34:42 2008 From: david_villalobos_c at ...43... (David Villalobos Cambronero) Date: Wed, 3 Dec 2008 06:34:42 -0800 (PST) Subject: [Gambas-user] Action managment Message-ID: <561822.40087.qm@...1658...> Hi all, I have a problem using Actions. That is what I got: I have a form let's call it FMain, in this form I have a work space that I use to emmbed some others form, Let's suppose I emmbed a form in this work space, let's call it Form2, in this form, I insert a class, this class has some controls with actions, so at the end we have, two forms and one class: FMain::Form2::class, all of them has the Action_Activate procedure, but the Actions of the class are intersepted by the parent, in this case: Form2. How can I make my class to intersept his own Actions? Regards -- David From arosa at ...2015... Wed Dec 3 18:46:13 2008 From: arosa at ...2015... (Toni) Date: Wed, 03 Dec 2008 17:46:13 +0000 Subject: [Gambas-user] TrayIcon control Message-ID: <4936C5E5.3050304@...2015...> Hi, I'm using the "trayicon" control and I have found a couple of problems with it. If I use "ShowModal" or "ShowDialog" to show a Form within one of its "events" it happens that: 1. It does'nt prevent the control from getting new events, and 2. if the application is Closed with that Form still opened, it crashes with signal #11. The other problem is that, although I set its visible property to FALSE in the IDE, it keeps changing back to visible = True alone... Regards, Toni p.s. I use Gambas 2.9 (svn version) From Charles.Capaday at ...2023... Wed Dec 3 19:05:22 2008 From: Charles.Capaday at ...2023... (Charles Capaday) Date: Wed, 3 Dec 2008 13:05:22 -0500 Subject: [Gambas-user] Coordinate system in Gambas Graphics Message-ID: I'm interested in developing a graph object in Gambas to plot points, curves etc. Are there language statements for coordinate transformations such as to make, for example, the pixel locations of a rectangle into x,y coordinate values? Cheers, Dr. Charles Capaday Professor & Director Brain and Movement Lab. Dept. of Anatomy & Physiology Faculty of Medicine, Laval University http://www.brainandmovementlab.org/ Mailing address: CRULRG F-6500 Hopital Robert-Giffard 2601 de la Canardiere, Beauport, QC G1J 2G3 Canada Tel: +418-663-5747 (Sec.) +418-663-5000 ext. 6736 (Off.) +418-663-5000 ext. 6877 (Lab.) Fax: +418-663-8756 From nkoch22 at ...626... Wed Dec 3 19:35:51 2008 From: nkoch22 at ...626... (Nicolas Koch) Date: Wed, 3 Dec 2008 21:35:51 +0300 Subject: [Gambas-user] TrayIcon control In-Reply-To: <4936C5E5.3050304@...2015...> References: <4936C5E5.3050304@...2015...> Message-ID: <73abb3e80812031035g568c54e5qb317cae674fa17c5@...627...> Toni, Are you using gb.gtk, gb.gui or gb.qt? I have replicated the same error only with gb.qt or using gb.gui while in KDE. Regards, Nick On Wed, Dec 3, 2008 at 8:46 PM, Toni wrote: > Hi, > > I'm using the "trayicon" control and I have found a couple of problems > with it. > > If I use "ShowModal" or "ShowDialog" to show a Form within one of its > "events" it happens that: 1. It does'nt prevent the control from getting > new events, and 2. if the application is Closed with that Form still > opened, it crashes with signal #11. > > The other problem is that, although I set its visible property to FALSE > in the IDE, it keeps changing back to visible = True alone... > > Regards, > > Toni > > p.s. I use Gambas 2.9 (svn version) > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Wed Dec 3 19:46:42 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 3 Dec 2008 19:46:42 +0100 Subject: [Gambas-user] TrayIcon control In-Reply-To: <4936C5E5.3050304@...2015...> References: <4936C5E5.3050304@...2015...> Message-ID: <200812031946.42706.gambas@...1...> On mercredi 3 d?cembre 2008, Toni wrote: > Hi, > > I'm using the "trayicon" control and I have found a couple of problems > with it. > > If I use "ShowModal" or "ShowDialog" to show a Form within one of its > "events" it happens that: 1. It does'nt prevent the control from getting > new events, What sort of events? > and 2. if the application is Closed with that Form still > opened, it crashes with signal #11. > > The other problem is that, although I set its visible property to FALSE > in the IDE, it keeps changing back to visible = True alone... > > Regards, > > Toni > > p.s. I use Gambas 2.9 (svn version) > Can you provide some source code that shows the problem, if possible? -- Benoit Minisini From ron at ...1740... Wed Dec 3 20:10:27 2008 From: ron at ...1740... (Ron) Date: Wed, 03 Dec 2008 20:10:27 +0100 Subject: [Gambas-user] TrayIcon control In-Reply-To: <200812031946.42706.gambas@...1...> References: <4936C5E5.3050304@...2015...> <200812031946.42706.gambas@...1...> Message-ID: <4936D9A3.9040808@...1740...> Benoit Minisini schreef: > On mercredi 3 d?cembre 2008, Toni wrote: > >> Hi, >> >> I'm using the "trayicon" control and I have found a couple of problems >> with it. >> >> If I use "ShowModal" or "ShowDialog" to show a Form within one of its >> "events" it happens that: 1. It does'nt prevent the control from getting >> new events, >> > > What sort of events? > > >> and 2. if the application is Closed with that Form still >> opened, it crashes with signal #11. >> >> The other problem is that, although I set its visible property to FALSE >> in the IDE, it keeps changing back to visible = True alone... >> >> Regards, >> >> Toni >> >> p.s. I use Gambas 2.9 (svn version) >> >> > > Can you provide some source code that shows the problem, if possible? > > I guess this the same signal 11 I got when I try to integrate trayicon in my project. (gb.qt) Tried to isolate it in a small project, but it kept working then .. bummer... Regards, Ron_2nd From rterry at ...1946... Wed Dec 3 21:34:41 2008 From: rterry at ...1946... (richard terry) Date: Thu, 4 Dec 2008 07:34:41 +1100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: References: Message-ID: <200812040734.41502.rterry@...1946...> On Thu, 4 Dec 2008 05:05:22 am Charles Capaday wrote: Fabians chart component may or may not help. I'll mail you some piccies of what it can do off list. Regards Richard > I'm interested in developing a graph object in Gambas to plot points, > curves etc. Are there language statements for coordinate transformations > such as to make, for example, the pixel locations of a rectangle into > x,y coordinate values? > > > Cheers, > > > Dr. Charles Capaday > Professor & Director > Brain and Movement Lab. > Dept. of Anatomy & Physiology > Faculty of Medicine, Laval University > http://www.brainandmovementlab.org/ > > Mailing address: > CRULRG F-6500 > Hopital Robert-Giffard > 2601 de la Canardiere, Beauport, QC > G1J 2G3 Canada > > Tel: +418-663-5747 (Sec.) > +418-663-5000 ext. 6736 (Off.) > +418-663-5000 ext. 6877 (Lab.) > Fax: +418-663-8756 > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge Build the coolest Linux based applications with Moblin SDK & win > great prizes Grand prize is a trip for two to an Open Source event anywhere > in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From arosa at ...2015... Wed Dec 3 21:55:48 2008 From: arosa at ...2015... (Toni) Date: Wed, 03 Dec 2008 20:55:48 +0000 Subject: [Gambas-user] TrayIcon control In-Reply-To: <200812031946.42706.gambas@...1...> References: <4936C5E5.3050304@...2015...> <200812031946.42706.gambas@...1...> Message-ID: <4936F254.4010300@...2015...> Hi, I have created a new project "gb.gui" with two forms, "Fmain" (startup class) and "Form1". "Fmain" has a Button "ButtonExit" and one IconTray "TrayIcon1". What I am trying to accomplish is that the application can be only "exited" clicking on the button. When the form "Fmain" is Closed, it "places" it self into an Icontray. When "doubleclicking" on the "Icontray" it will show "Fmain" again. "Icontray1" has a "contextual menu" to show another form (Form1). Now, the steps to reproduce problems I mentioned in my prevoius mail: 1. Launch application, close Fmain. It "places" itself in the IconTray. 2. Then select Icontray1 menu "Opt1" (it will "showmodal()" Form1) 3. Then "DoubleClick" on Icontray1 again, it will show "Fmain". *First problem: Although the "showmodal()" has been called, Icontray1 has still processed events and show "FMain" 4. "Click" on FMain ButtonExit *Second problem, clicking on "ButtonExit" will crash with signal #11. The Code in "Fmain" is the following: PUBLIC Mnu AS menu PUBLIC Opt1 AS Menu PUBLIC Opt2 AS Menu PUBLIC SUB _new() Mnu = NEW Menu(ME) Mnu.Name = "Mnu" Opt1 = NEW Menu(Mnu) AS "MenuTray" Opt1.Name = "Opt1" Opt1.Caption = "Opt1" Opt1.Visible = TRUE Opt2 = NEW Menu(Mnu) AS "MenuTray" Opt2.Name = "Opt2" Opt2.Caption = "Opt2" Opt2.Visible = TRUE ME.Persistent = TRUE TrayIcon1.Visible = FALSE END PUBLIC SUB Form_Close() ME.Visible = FALSE ME.SkipTaskbar = TRUE TrayIcon1.Visible = TRUE END PUBLIC SUB MenuTray_Click() DIM Frm AS NEW Form1 IF LAST.name = "Opt1" THEN Frm.Showmodal() ELSE ButtonExit_Click() ENDIF END PUBLIC SUB TrayIcon1_Menu() Mnu.popup END PUBLIC SUB TrayIcon1_DblClick() ME.Visible = TRUE ME.SkipTaskbar = FALSE TrayIcon1.Visible = FALSE END PUBLIC SUB ButtonExit_Click() ME.Persistent = FALSE ME.Close END Thanks! P.S. I have, yet, another problem related to Icontrays. I would like to use it as the "control" sended to "Ballon", so the "ballon" displays information pointing at it... but it doesn't compile arguing that it (ballon) expected a Control not an Icontray :( From eilert-sprachen at ...221... Thu Dec 4 09:19:01 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Thu, 04 Dec 2008 09:19:01 +0100 Subject: [Gambas-user] Small window without gadgets Message-ID: <49379275.8@...221...> Hi everyone out there... The question is simple: Is it possible to make a small window without any gadgets appear and disappear after some seconds showing a small hint such as "you got new messages..."? What I want is something like these hints Thunderbird or the Suse update client produce at the lower right edge of the screen, for my own messenger app here in our firm. Thanks for all ideas. Regards, Rolf From arosa at ...2015... Thu Dec 4 10:27:19 2008 From: arosa at ...2015... (Toni) Date: Thu, 04 Dec 2008 09:27:19 +0000 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <49379275.8@...221...> References: <49379275.8@...221...> Message-ID: <4937A277.1000004@...2015...> Hi Rolf, I'm new to Gambas so maybe other will tell otherwise..., but I think "Ballon" is what you are looking for. The only problem is that I haven't been able to get it working pointing to a TrayIcon (that low right edge of the screen you mention). Hope it helps and, in anycase, if there is a better solution I'll be gald to hear from it too. Regards, Toni En/na Rolf-Werner Eilert ha escrit: > Hi everyone out there... > > The question is simple: Is it possible to make a small window without > any gadgets appear and disappear after some seconds showing a small hint > such as "you got new messages..."? > > What I want is something like these hints Thunderbird or the Suse update > client produce at the lower right edge of the screen, for my own > messenger app here in our firm. > > Thanks for all ideas. > > Regards, > > Rolf > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From demosthenesk at ...626... Thu Dec 4 12:14:24 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Thu, 4 Dec 2008 13:14:24 +0200 Subject: [Gambas-user] TrayIcon control In-Reply-To: <4936F254.4010300@...2015...> References: <4936C5E5.3050304@...2015...> <200812031946.42706.gambas@...1...> <4936F254.4010300@...2015...> Message-ID: i propose to hide or show the FMain form instead close it. so this code may help you PUBLIC SUB TrayIcon1_DblClick() 'when double click tray icon show or hide FMain IF FMain.Visible = TRUE THEN FMain.Visible = FALSE ELSE FMain.Visible = TRUE END IF END PUBLIC SUB btnHide_Click() ME.Hide() END PUBLIC SUB btnExit_Click() ME.Close() END On Wed, Dec 3, 2008 at 10:55 PM, Toni wrote: > Hi, > I have created a new project "gb.gui" with two forms, "Fmain" (startup > class) and "Form1". > > "Fmain" has a Button "ButtonExit" and one IconTray "TrayIcon1". > What I am trying to accomplish is that the application can be only > "exited" clicking on the button. When the form "Fmain" is Closed, it > "places" it self into an Icontray. > When "doubleclicking" on the "Icontray" it will show "Fmain" again. > "Icontray1" has a "contextual menu" to show another form (Form1). > > Now, the steps to reproduce problems I mentioned in my prevoius mail: > 1. Launch application, close Fmain. It "places" itself in the IconTray. > 2. Then select Icontray1 menu "Opt1" (it will "showmodal()" Form1) > 3. Then "DoubleClick" on Icontray1 again, it will show "Fmain". > *First problem: Although the "showmodal()" has been called, Icontray1 > has still processed events and show "FMain" > 4. "Click" on FMain ButtonExit > *Second problem, clicking on "ButtonExit" will crash with signal #11. > > > > The Code in "Fmain" is the following: > > PUBLIC Mnu AS menu > PUBLIC Opt1 AS Menu > PUBLIC Opt2 AS Menu > > PUBLIC SUB _new() > Mnu = NEW Menu(ME) > Mnu.Name = "Mnu" > Opt1 = NEW Menu(Mnu) AS "MenuTray" > Opt1.Name = "Opt1" > Opt1.Caption = "Opt1" > Opt1.Visible = TRUE > Opt2 = NEW Menu(Mnu) AS "MenuTray" > Opt2.Name = "Opt2" > Opt2.Caption = "Opt2" > Opt2.Visible = TRUE > ME.Persistent = TRUE > TrayIcon1.Visible = FALSE > END > > PUBLIC SUB Form_Close() > ME.Visible = FALSE > ME.SkipTaskbar = TRUE > TrayIcon1.Visible = TRUE > END > > PUBLIC SUB MenuTray_Click() > DIM Frm AS NEW Form1 > IF LAST.name = "Opt1" THEN > Frm.Showmodal() > ELSE > ButtonExit_Click() > ENDIF > END > > PUBLIC SUB TrayIcon1_Menu() > Mnu.popup > END > > > PUBLIC SUB TrayIcon1_DblClick() > ME.Visible = TRUE > ME.SkipTaskbar = FALSE > TrayIcon1.Visible = FALSE > END > > PUBLIC SUB ButtonExit_Click() > ME.Persistent = FALSE > ME.Close > END > > > > > > Thanks! > > P.S. I have, yet, another problem related to Icontrays. I would like to > use it as the "control" sended to "Ballon", so the "ballon" displays > information pointing at it... but it doesn't compile arguing that it > (ballon) expected a Control not an Icontray :( > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From arosa at ...2015... Thu Dec 4 13:24:22 2008 From: arosa at ...2015... (Toni) Date: Thu, 04 Dec 2008 12:24:22 +0000 Subject: [Gambas-user] TrayIcon control In-Reply-To: References: <4936C5E5.3050304@...2015...> <200812031946.42706.gambas@...1...> <4936F254.4010300@...2015...> Message-ID: <4937CBF6.30906@...2015...> Hi Demosthenes, I have changed my code in FMain Close event to ".Hide()" and to ".Show()" in TrayIcon1 DblClick event (instead of setting FMain visible property to FALSE/TRUE), with no difference. It still has the same two problems... Regards, Toni En/na Demosthenes Koptsis ha escrit: > i propose to hide or show the FMain form instead close it. > > so this code may help you > > PUBLIC SUB TrayIcon1_DblClick() > > 'when double click tray icon show or hide FMain > IF FMain.Visible = TRUE THEN > FMain.Visible = FALSE > ELSE > FMain.Visible = TRUE > END IF > > END > > PUBLIC SUB btnHide_Click() > > ME.Hide() > > END > > PUBLIC SUB btnExit_Click() > > ME.Close() > > END > > > On Wed, Dec 3, 2008 at 10:55 PM, Toni wrote: > >> Hi, >> I have created a new project "gb.gui" with two forms, "Fmain" (startup >> class) and "Form1". >> >> "Fmain" has a Button "ButtonExit" and one IconTray "TrayIcon1". >> What I am trying to accomplish is that the application can be only >> "exited" clicking on the button. When the form "Fmain" is Closed, it >> "places" it self into an Icontray. >> When "doubleclicking" on the "Icontray" it will show "Fmain" again. >> "Icontray1" has a "contextual menu" to show another form (Form1). >> >> Now, the steps to reproduce problems I mentioned in my prevoius mail: >> 1. Launch application, close Fmain. It "places" itself in the IconTray. >> 2. Then select Icontray1 menu "Opt1" (it will "showmodal()" Form1) >> 3. Then "DoubleClick" on Icontray1 again, it will show "Fmain". >> *First problem: Although the "showmodal()" has been called, Icontray1 >> has still processed events and show "FMain" >> 4. "Click" on FMain ButtonExit >> *Second problem, clicking on "ButtonExit" will crash with signal #11. >> >> >> >> The Code in "Fmain" is the following: >> >> PUBLIC Mnu AS menu >> PUBLIC Opt1 AS Menu >> PUBLIC Opt2 AS Menu >> >> PUBLIC SUB _new() >> Mnu = NEW Menu(ME) >> Mnu.Name = "Mnu" >> Opt1 = NEW Menu(Mnu) AS "MenuTray" >> Opt1.Name = "Opt1" >> Opt1.Caption = "Opt1" >> Opt1.Visible = TRUE >> Opt2 = NEW Menu(Mnu) AS "MenuTray" >> Opt2.Name = "Opt2" >> Opt2.Caption = "Opt2" >> Opt2.Visible = TRUE >> ME.Persistent = TRUE >> TrayIcon1.Visible = FALSE >> END >> >> PUBLIC SUB Form_Close() >> ME.Visible = FALSE >> ME.SkipTaskbar = TRUE >> TrayIcon1.Visible = TRUE >> END >> >> PUBLIC SUB MenuTray_Click() >> DIM Frm AS NEW Form1 >> IF LAST.name = "Opt1" THEN >> Frm.Showmodal() >> ELSE >> ButtonExit_Click() >> ENDIF >> END >> >> PUBLIC SUB TrayIcon1_Menu() >> Mnu.popup >> END >> >> >> PUBLIC SUB TrayIcon1_DblClick() >> ME.Visible = TRUE >> ME.SkipTaskbar = FALSE >> TrayIcon1.Visible = FALSE >> END >> >> PUBLIC SUB ButtonExit_Click() >> ME.Persistent = FALSE >> ME.Close >> END >> >> >> >> >> >> Thanks! >> >> P.S. I have, yet, another problem related to Icontrays. I would like to >> use it as the "control" sended to "Ballon", so the "ballon" displays >> information pointing at it... but it doesn't compile arguing that it >> (ballon) expected a Control not an Icontray :( >> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge >> Build the coolest Linux based applications with Moblin SDK & win great prizes >> Grand prize is a trip for two to an Open Source event anywhere in the world >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> > > > > From eilert-sprachen at ...221... Thu Dec 4 17:29:29 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Thu, 04 Dec 2008 17:29:29 +0100 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <4937A277.1000004@...2015...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> Message-ID: <49380569.6070509@...221...> Hi Toni, Toni schrieb: > Hi Rolf, > I'm new to Gambas so maybe other will tell otherwise..., but I think never mind :-) I've been into Gambas for quite some time now, but I'm still far away from being an expert... > "Ballon" is what you are looking for. Didn't find that - is it one of the examples? In the examples, I did find the thing with the transparent clock and the other clock example. But those seem to have to do with transparency rather than with just a window without gadgets. Though I tried to do the same and failed - I don't know why my windows always have gadgets, even when I say "Border - None", and I cannot make out any other difference between my own programs and the examples (except the drawing routines). The examples run flawlessly here, my own programs always show standard windows. So, where's the trick? Regards, Rolf > The only problem is that I haven't been able to get it working pointing > to a TrayIcon (that low right edge of the screen you mention). Hope it > helps and, in anycase, if there is a better solution I'll be gald to > hear from it too. > > Regards, > Toni > > En/na Rolf-Werner Eilert ha escrit: >> Hi everyone out there... >> >> The question is simple: Is it possible to make a small window without >> any gadgets appear and disappear after some seconds showing a small hint >> such as "you got new messages..."? >> >> What I want is something like these hints Thunderbird or the Suse update >> client produce at the lower right edge of the screen, for my own >> messenger app here in our firm. >> >> Thanks for all ideas. >> >> Regards, >> >> Rolf >> From nkoch22 at ...626... Thu Dec 4 20:06:46 2008 From: nkoch22 at ...626... (Nicolas Koch) Date: Thu, 4 Dec 2008 22:06:46 +0300 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <49379275.8@...221...> References: <49379275.8@...221...> Message-ID: <73abb3e80812041106r3e0c4c79t84b9d3ca400b01cd@...627...> Rolf, > The question is simple: Is it possible to make a small window without > any gadgets appear and disappear after some seconds showing a small hint > such as "you got new messages..."? Yes. Ok on your project you have your main form say FMain, create another form call it FNewMsg. On FMain add a button or whatever way you want to call the FNewMsg form. ' Gambas class file PUBLIC SUB Form_Open() END PUBLIC SUB Button1_Click() FNewMsg.Show END Now on FNewMsg we just have the Message you wanted "you got new messages..." either as textlabel, msg or picture whatever and add a timer like the below FNewMsg ' Gambas class file PRIVATE CloseTimer AS NEW Timer AS "CloseTimer" PUBLIC SUB Form_Open() ME.Center CloseTimer.Delay = 4 * 1000 CloseTimer.Enabled = TRUE END PUBLIC SUB CloseTimer_Timer() ME.Close() END Regards, Nick From gambas.fr at ...626... Thu Dec 4 21:10:07 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Thu, 4 Dec 2008 21:10:07 +0100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <200812040734.41502.rterry@...1946...> References: <200812040734.41502.rterry@...1946...> Message-ID: <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> i'm currently working on it, and made richard's wich true 2008/12/3 richard terry : > On Thu, 4 Dec 2008 05:05:22 am Charles Capaday wrote: > Fabians chart component may or may not help. > > I'll mail you some piccies of what it can do off list. > > Regards > > Richard > >> I'm interested in developing a graph object in Gambas to plot points, >> curves etc. Are there language statements for coordinate transformations >> such as to make, for example, the pixel locations of a rectangle into >> x,y coordinate values? >> >> >> Cheers, >> >> >> Dr. Charles Capaday >> Professor & Director >> Brain and Movement Lab. >> Dept. of Anatomy & Physiology >> Faculty of Medicine, Laval University >> http://www.brainandmovementlab.org/ >> >> Mailing address: >> CRULRG F-6500 >> Hopital Robert-Giffard >> 2601 de la Canardiere, Beauport, QC >> G1J 2G3 Canada >> >> Tel: +418-663-5747 (Sec.) >> +418-663-5000 ext. 6736 (Off.) >> +418-663-5000 ext. 6877 (Lab.) >> Fax: +418-663-8756 >> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's >> challenge Build the coolest Linux based applications with Moblin SDK & win >> great prizes Grand prize is a trip for two to an Open Source event anywhere >> in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From Charles.Capaday at ...2023... Thu Dec 4 21:22:54 2008 From: Charles.Capaday at ...2023... (Charles Capaday) Date: Thu, 4 Dec 2008 15:22:54 -0500 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> Message-ID: Thanks, this would be a nice feature indeed, however I was not looking for a component as such. Simply I asked whether the language has commands for mapping pixel values to x-y coordinate values, these where part of DOS Basic Compiler 7 for example and in VB as well I am pretty sure... Cheers, Dr. Charles Capaday Professor & Director Brain and Movement Lab. Dept. of Anatomy & Physiology Faculty of Medicine, Laval University http://www.brainandmovementlab.org/ Mailing address: CRULRG F-6500 Hopital Robert-Giffard 2601 de la Canardiere, Beauport, QC G1J 2G3 Canada Tel: +418-663-5747 (Sec.) +418-663-5000 ext. 6736 (Off.) +418-663-5000 ext. 6877 (Lab.) Fax: +418-663-8756 > -----Original Message----- > From: Fabien Bodard [mailto:gambas.fr at ...626...] > Sent: 4 d?cembre 2008 15:10 > To: richard terry; mailing list for gambas users > Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics > > i'm currently working on it, and made richard's wich true > > > 2008/12/3 richard terry : > > On Thu, 4 Dec 2008 05:05:22 am Charles Capaday wrote: > > Fabians chart component may or may not help. > > > > I'll mail you some piccies of what it can do off list. > > > > Regards > > > > Richard > > > >> I'm interested in developing a graph object in Gambas to > plot points, > >> curves etc. Are there language statements for coordinate > >> transformations such as to make, for example, the pixel > locations of > >> a rectangle into x,y coordinate values? > >> > >> > >> Cheers, > >> > >> > >> Dr. Charles Capaday > >> Professor & Director > >> Brain and Movement Lab. > >> Dept. of Anatomy & Physiology > >> Faculty of Medicine, Laval University > >> http://www.brainandmovementlab.org/ > >> > >> Mailing address: > >> CRULRG F-6500 > >> Hopital Robert-Giffard > >> 2601 de la Canardiere, Beauport, QC > >> G1J 2G3 Canada > >> > >> Tel: +418-663-5747 (Sec.) > >> +418-663-5000 ext. 6736 (Off.) > >> +418-663-5000 ext. 6877 (Lab.) > >> Fax: +418-663-8756 > >> > >> > --------------------------------------------------------------------- > >> ---- This SF.Net email is sponsored by the Moblin Your Move > >> Developer's challenge Build the coolest Linux based > applications with > >> Moblin SDK & win great prizes Grand prize is a trip for two to an > >> Open Source event anywhere in the world > >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > > > ---------------------------------------------------------------------- > > --- This SF.Net email is sponsored by the Moblin Your Move > Developer's > > challenge Build the coolest Linux based applications with > Moblin SDK & > > win great prizes Grand prize is a trip for two to an Open > Source event > > anywhere in the world > > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > -------------------------------------------------------------- > ---------------- > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las > Vegas, Nevada. > The future of the web can't happen without you. Join us at > MIX09 to help pave the way to the Next Web now. Learn more > and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 > .visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From arosa at ...2015... Fri Dec 5 04:24:11 2008 From: arosa at ...2015... (Toni) Date: Fri, 05 Dec 2008 03:24:11 +0000 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <49380569.6070509@...221...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> <49380569.6070509@...221...> Message-ID: <49389EDB.7010805@...2015...> Hi Rolf again, By ballon I meant "gb.form.ballon", a Message like class. I couldn't get it pointing to a Tray Icon, but otherwise I find it pretty nice and unobtrusive :) Regards, Toni En/na Rolf-Werner Eilert ha escrit: > Hi Toni, > > Toni schrieb: > >> Hi Rolf, >> I'm new to Gambas so maybe other will tell otherwise..., but I think >> > > never mind :-) I've been into Gambas for quite some time now, but I'm > still far away from being an expert... > > >> "Ballon" is what you are looking for. >> > > Didn't find that - is it one of the examples? > > In the examples, I did find the thing with the transparent clock and the > other clock example. But those seem to have to do with transparency > rather than with just a window without gadgets. > > Though I tried to do the same and failed - I don't know why my windows > always have gadgets, even when I say "Border - None", and I cannot make > out any other difference between my own programs and the examples > (except the drawing routines). The examples run flawlessly here, my own > programs always show standard windows. > > So, where's the trick? > > > Regards, > > Rolf > > >> The only problem is that I haven't been able to get it working pointing >> to a TrayIcon (that low right edge of the screen you mention). Hope it >> helps and, in anycase, if there is a better solution I'll be gald to >> hear from it too. >> >> Regards, >> Toni >> >> En/na Rolf-Werner Eilert ha escrit: >> >>> Hi everyone out there... >>> >>> The question is simple: Is it possible to make a small window without >>> any gadgets appear and disappear after some seconds showing a small hint >>> such as "you got new messages..."? >>> >>> What I want is something like these hints Thunderbird or the Suse update >>> client produce at the lower right edge of the screen, for my own >>> messenger app here in our firm. >>> >>> Thanks for all ideas. >>> >>> Regards, >>> >>> Rolf >>> >>> > > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From eilert-sprachen at ...221... Fri Dec 5 08:25:55 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Fri, 05 Dec 2008 08:25:55 +0100 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <73abb3e80812041106r3e0c4c79t84b9d3ca400b01cd@...627...> References: <49379275.8@...221...> <73abb3e80812041106r3e0c4c79t84b9d3ca400b01cd@...627...> Message-ID: <4938D783.2060204@...221...> Nicolas Koch schrieb: > Rolf, > >> The question is simple: Is it possible to make a small window without >> any gadgets appear and disappear after some seconds showing a small hint >> such as "you got new messages..."? > > Yes. > > Ok on your project you have your main form say FMain, create another > form call it FNewMsg. > > On FMain add a button or whatever way you want to call the FNewMsg form. > > ' Gambas class file > > PUBLIC SUB Form_Open() > > END > > PUBLIC SUB Button1_Click() > FNewMsg.Show > END > > Now on FNewMsg we just have the Message you wanted "you got new > messages..." either as textlabel, msg or picture whatever and add a > timer like the below > > FNewMsg > ' Gambas class file > > PRIVATE CloseTimer AS NEW Timer AS "CloseTimer" > > PUBLIC SUB Form_Open() > ME.Center > CloseTimer.Delay = 4 * 1000 > CloseTimer.Enabled = TRUE > > END > > PUBLIC SUB CloseTimer_Timer() > ME.Close() > END > > Thanks for that proposal. Of course, everything runs as expected, the only thing is that the message window always has gadgets here, and I cannot explain why. In the properties, I set this window to "Border - None" and the gadgets disappear in design mode. But when the window is called like in the example, it does have gadgets... Rolf From demosthenesk at ...626... Fri Dec 5 13:22:25 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Fri, 5 Dec 2008 14:22:25 +0200 Subject: [Gambas-user] TrayIcon control In-Reply-To: References: <4936C5E5.3050304@...2015...> <200812031946.42706.gambas@...1...> <4936F254.4010300@...2015...> <4937CBF6.30906@...2015...> Message-ID: a note the line ME.Persistent = FALSE is useless if you call QUIT ! On 12/5/08, Demosthenes Koptsis wrote: > ok back to your code, > > replace this code > > PUBLIC SUB ButtonExit_Click() > ME.Persistent = FALSE > ME.Close > END > > > with this one > > PUBLIC SUB ButtonExit_Click() > ME.Persistent = FALSE > QUIT > END > > try to quit instead of close form. > > is that you want? > > On 12/4/08, Toni wrote: >> Hi Demosthenes, >> I have changed my code in FMain Close event to ".Hide()" and to >> ".Show()" in TrayIcon1 DblClick event (instead of setting FMain visible >> property to FALSE/TRUE), with no difference. It still has the same two >> problems... >> >> Regards, >> Toni >> >> >> En/na Demosthenes Koptsis ha escrit: >>> i propose to hide or show the FMain form instead close it. >>> >>> so this code may help you >>> >>> PUBLIC SUB TrayIcon1_DblClick() >>> >>> 'when double click tray icon show or hide FMain >>> IF FMain.Visible = TRUE THEN >>> FMain.Visible = FALSE >>> ELSE >>> FMain.Visible = TRUE >>> END IF >>> >>> END >>> >>> PUBLIC SUB btnHide_Click() >>> >>> ME.Hide() >>> >>> END >>> >>> PUBLIC SUB btnExit_Click() >>> >>> ME.Close() >>> >>> END >>> >>> >>> On Wed, Dec 3, 2008 at 10:55 PM, Toni wrote: >>> >>>> Hi, >>>> I have created a new project "gb.gui" with two forms, "Fmain" (startup >>>> class) and "Form1". >>>> >>>> "Fmain" has a Button "ButtonExit" and one IconTray "TrayIcon1". >>>> What I am trying to accomplish is that the application can be only >>>> "exited" clicking on the button. When the form "Fmain" is Closed, it >>>> "places" it self into an Icontray. >>>> When "doubleclicking" on the "Icontray" it will show "Fmain" again. >>>> "Icontray1" has a "contextual menu" to show another form (Form1). >>>> >>>> Now, the steps to reproduce problems I mentioned in my prevoius mail: >>>> 1. Launch application, close Fmain. It "places" itself in the IconTray. >>>> 2. Then select Icontray1 menu "Opt1" (it will "showmodal()" Form1) >>>> 3. Then "DoubleClick" on Icontray1 again, it will show "Fmain". >>>> *First problem: Although the "showmodal()" has been called, Icontray1 >>>> has still processed events and show "FMain" >>>> 4. "Click" on FMain ButtonExit >>>> *Second problem, clicking on "ButtonExit" will crash with signal #11. >>>> >>>> >>>> >>>> The Code in "Fmain" is the following: >>>> >>>> PUBLIC Mnu AS menu >>>> PUBLIC Opt1 AS Menu >>>> PUBLIC Opt2 AS Menu >>>> >>>> PUBLIC SUB _new() >>>> Mnu = NEW Menu(ME) >>>> Mnu.Name = "Mnu" >>>> Opt1 = NEW Menu(Mnu) AS "MenuTray" >>>> Opt1.Name = "Opt1" >>>> Opt1.Caption = "Opt1" >>>> Opt1.Visible = TRUE >>>> Opt2 = NEW Menu(Mnu) AS "MenuTray" >>>> Opt2.Name = "Opt2" >>>> Opt2.Caption = "Opt2" >>>> Opt2.Visible = TRUE >>>> ME.Persistent = TRUE >>>> TrayIcon1.Visible = FALSE >>>> END >>>> >>>> PUBLIC SUB Form_Close() >>>> ME.Visible = FALSE >>>> ME.SkipTaskbar = TRUE >>>> TrayIcon1.Visible = TRUE >>>> END >>>> >>>> PUBLIC SUB MenuTray_Click() >>>> DIM Frm AS NEW Form1 >>>> IF LAST.name = "Opt1" THEN >>>> Frm.Showmodal() >>>> ELSE >>>> ButtonExit_Click() >>>> ENDIF >>>> END >>>> >>>> PUBLIC SUB TrayIcon1_Menu() >>>> Mnu.popup >>>> END >>>> >>>> >>>> PUBLIC SUB TrayIcon1_DblClick() >>>> ME.Visible = TRUE >>>> ME.SkipTaskbar = FALSE >>>> TrayIcon1.Visible = FALSE >>>> END >>>> >>>> PUBLIC SUB ButtonExit_Click() >>>> ME.Persistent = FALSE >>>> ME.Close >>>> END >>>> >>>> >>>> >>>> >>>> >>>> Thanks! >>>> >>>> P.S. I have, yet, another problem related to Icontrays. I would like to >>>> use it as the "control" sended to "Ballon", so the "ballon" displays >>>> information pointing at it... but it doesn't compile arguing that it >>>> (ballon) expected a Control not an Icontray :( >>>> >>>> ------------------------------------------------------------------------- >>>> This SF.Net email is sponsored by the Moblin Your Move Developer's >>>> challenge >>>> Build the coolest Linux based applications with Moblin SDK & win great >>>> prizes >>>> Grand prize is a trip for two to an Open Source event anywhere in the >>>> world >>>> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>>> >>> >>> >>> >>> >> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's >> challenge >> Build the coolest Linux based applications with Moblin SDK & win great >> prizes >> Grand prize is a trip for two to an Open Source event anywhere in the >> world >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > -- > > ???? ???? ?? ?????!!! > > Regards, > > Demosthenes Koptsis > -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From demosthenesk at ...626... Fri Dec 5 13:19:58 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Fri, 5 Dec 2008 14:19:58 +0200 Subject: [Gambas-user] TrayIcon control In-Reply-To: <4937CBF6.30906@...2015...> References: <4936C5E5.3050304@...2015...> <200812031946.42706.gambas@...1...> <4936F254.4010300@...2015...> <4937CBF6.30906@...2015...> Message-ID: ok back to your code, replace this code PUBLIC SUB ButtonExit_Click() ME.Persistent = FALSE ME.Close END with this one PUBLIC SUB ButtonExit_Click() ME.Persistent = FALSE QUIT END try to quit instead of close form. is that you want? On 12/4/08, Toni wrote: > Hi Demosthenes, > I have changed my code in FMain Close event to ".Hide()" and to > ".Show()" in TrayIcon1 DblClick event (instead of setting FMain visible > property to FALSE/TRUE), with no difference. It still has the same two > problems... > > Regards, > Toni > > > En/na Demosthenes Koptsis ha escrit: >> i propose to hide or show the FMain form instead close it. >> >> so this code may help you >> >> PUBLIC SUB TrayIcon1_DblClick() >> >> 'when double click tray icon show or hide FMain >> IF FMain.Visible = TRUE THEN >> FMain.Visible = FALSE >> ELSE >> FMain.Visible = TRUE >> END IF >> >> END >> >> PUBLIC SUB btnHide_Click() >> >> ME.Hide() >> >> END >> >> PUBLIC SUB btnExit_Click() >> >> ME.Close() >> >> END >> >> >> On Wed, Dec 3, 2008 at 10:55 PM, Toni wrote: >> >>> Hi, >>> I have created a new project "gb.gui" with two forms, "Fmain" (startup >>> class) and "Form1". >>> >>> "Fmain" has a Button "ButtonExit" and one IconTray "TrayIcon1". >>> What I am trying to accomplish is that the application can be only >>> "exited" clicking on the button. When the form "Fmain" is Closed, it >>> "places" it self into an Icontray. >>> When "doubleclicking" on the "Icontray" it will show "Fmain" again. >>> "Icontray1" has a "contextual menu" to show another form (Form1). >>> >>> Now, the steps to reproduce problems I mentioned in my prevoius mail: >>> 1. Launch application, close Fmain. It "places" itself in the IconTray. >>> 2. Then select Icontray1 menu "Opt1" (it will "showmodal()" Form1) >>> 3. Then "DoubleClick" on Icontray1 again, it will show "Fmain". >>> *First problem: Although the "showmodal()" has been called, Icontray1 >>> has still processed events and show "FMain" >>> 4. "Click" on FMain ButtonExit >>> *Second problem, clicking on "ButtonExit" will crash with signal #11. >>> >>> >>> >>> The Code in "Fmain" is the following: >>> >>> PUBLIC Mnu AS menu >>> PUBLIC Opt1 AS Menu >>> PUBLIC Opt2 AS Menu >>> >>> PUBLIC SUB _new() >>> Mnu = NEW Menu(ME) >>> Mnu.Name = "Mnu" >>> Opt1 = NEW Menu(Mnu) AS "MenuTray" >>> Opt1.Name = "Opt1" >>> Opt1.Caption = "Opt1" >>> Opt1.Visible = TRUE >>> Opt2 = NEW Menu(Mnu) AS "MenuTray" >>> Opt2.Name = "Opt2" >>> Opt2.Caption = "Opt2" >>> Opt2.Visible = TRUE >>> ME.Persistent = TRUE >>> TrayIcon1.Visible = FALSE >>> END >>> >>> PUBLIC SUB Form_Close() >>> ME.Visible = FALSE >>> ME.SkipTaskbar = TRUE >>> TrayIcon1.Visible = TRUE >>> END >>> >>> PUBLIC SUB MenuTray_Click() >>> DIM Frm AS NEW Form1 >>> IF LAST.name = "Opt1" THEN >>> Frm.Showmodal() >>> ELSE >>> ButtonExit_Click() >>> ENDIF >>> END >>> >>> PUBLIC SUB TrayIcon1_Menu() >>> Mnu.popup >>> END >>> >>> >>> PUBLIC SUB TrayIcon1_DblClick() >>> ME.Visible = TRUE >>> ME.SkipTaskbar = FALSE >>> TrayIcon1.Visible = FALSE >>> END >>> >>> PUBLIC SUB ButtonExit_Click() >>> ME.Persistent = FALSE >>> ME.Close >>> END >>> >>> >>> >>> >>> >>> Thanks! >>> >>> P.S. I have, yet, another problem related to Icontrays. I would like to >>> use it as the "control" sended to "Ballon", so the "ballon" displays >>> information pointing at it... but it doesn't compile arguing that it >>> (ballon) expected a Control not an Icontray :( >>> >>> ------------------------------------------------------------------------- >>> This SF.Net email is sponsored by the Moblin Your Move Developer's >>> challenge >>> Build the coolest Linux based applications with Moblin SDK & win great >>> prizes >>> Grand prize is a trip for two to an Open Source event anywhere in the >>> world >>> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>> >> >> >> >> > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great > prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From eilert-sprachen at ...221... Fri Dec 5 13:10:09 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Fri, 05 Dec 2008 13:10:09 +0100 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <49389EDB.7010805@...2015...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> <49380569.6070509@...221...> <49389EDB.7010805@...2015...> Message-ID: <49391A21.4020108@...221...> Hi Toni, I found the description, but it won't be found by Gambas here. Do I have to do more than activating gb.form in the components list to get it? Thanks for your help. Rolf Toni schrieb: > Hi Rolf again, > By ballon I meant "gb.form.ballon", a Message like class. > I couldn't get it pointing to a Tray Icon, but otherwise I find it > pretty nice and unobtrusive :) > Regards, > Toni > > > > En/na Rolf-Werner Eilert ha escrit: >> Hi Toni, >> >> Toni schrieb: >> >>> Hi Rolf, >>> I'm new to Gambas so maybe other will tell otherwise..., but I think >>> >> never mind :-) I've been into Gambas for quite some time now, but I'm >> still far away from being an expert... >> >> >>> "Ballon" is what you are looking for. >>> >> Didn't find that - is it one of the examples? >> >> In the examples, I did find the thing with the transparent clock and the >> other clock example. But those seem to have to do with transparency >> rather than with just a window without gadgets. >> >> Though I tried to do the same and failed - I don't know why my windows >> always have gadgets, even when I say "Border - None", and I cannot make >> out any other difference between my own programs and the examples >> (except the drawing routines). The examples run flawlessly here, my own >> programs always show standard windows. >> >> So, where's the trick? >> >> >> Regards, >> >> Rolf >> >> >>> The only problem is that I haven't been able to get it working pointing >>> to a TrayIcon (that low right edge of the screen you mention). Hope it >>> helps and, in anycase, if there is a better solution I'll be gald to >>> hear from it too. >>> >>> Regards, >>> Toni >>> >>> En/na Rolf-Werner Eilert ha escrit: >>> >>>> Hi everyone out there... >>>> >>>> The question is simple: Is it possible to make a small window without >>>> any gadgets appear and disappear after some seconds showing a small hint >>>> such as "you got new messages..."? >>>> >>>> What I want is something like these hints Thunderbird or the Suse update >>>> client produce at the lower right edge of the screen, for my own >>>> messenger app here in our firm. >>>> >>>> Thanks for all ideas. >>>> >>>> Regards, >>>> >>>> Rolf >>>> >>>> >> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge >> Build the coolest Linux based applications with Moblin SDK & win great prizes >> Grand prize is a trip for two to an Open Source event anywhere in the world >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From eilert-sprachen at ...221... Fri Dec 5 12:55:38 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Fri, 05 Dec 2008 12:55:38 +0100 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <49389EDB.7010805@...2015...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> <49380569.6070509@...221...> <49389EDB.7010805@...2015...> Message-ID: <493916BA.4020308@...221...> Aaargh - I found it, maybe I was somewhat blind... Looks interesting, I'll try around with it. Rolf Toni schrieb: > Hi Rolf again, > By ballon I meant "gb.form.ballon", a Message like class. > I couldn't get it pointing to a Tray Icon, but otherwise I find it > pretty nice and unobtrusive :) > Regards, > Toni > > > > En/na Rolf-Werner Eilert ha escrit: >> Hi Toni, >> >> Toni schrieb: >> >>> Hi Rolf, >>> I'm new to Gambas so maybe other will tell otherwise..., but I think >>> >> never mind :-) I've been into Gambas for quite some time now, but I'm >> still far away from being an expert... >> >> >>> "Ballon" is what you are looking for. >>> >> Didn't find that - is it one of the examples? >> >> In the examples, I did find the thing with the transparent clock and the >> other clock example. But those seem to have to do with transparency >> rather than with just a window without gadgets. >> >> Though I tried to do the same and failed - I don't know why my windows >> always have gadgets, even when I say "Border - None", and I cannot make >> out any other difference between my own programs and the examples >> (except the drawing routines). The examples run flawlessly here, my own >> programs always show standard windows. >> >> So, where's the trick? >> >> >> Regards, >> >> Rolf >> >> >>> The only problem is that I haven't been able to get it working pointing >>> to a TrayIcon (that low right edge of the screen you mention). Hope it >>> helps and, in anycase, if there is a better solution I'll be gald to >>> hear from it too. >>> >>> Regards, >>> Toni >>> >>> En/na Rolf-Werner Eilert ha escrit: >>> >>>> Hi everyone out there... >>>> >>>> The question is simple: Is it possible to make a small window without >>>> any gadgets appear and disappear after some seconds showing a small hint >>>> such as "you got new messages..."? >>>> >>>> What I want is something like these hints Thunderbird or the Suse update >>>> client produce at the lower right edge of the screen, for my own >>>> messenger app here in our firm. >>>> >>>> Thanks for all ideas. >>>> >>>> Regards, >>>> >>>> Rolf >>>> >>>> >> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge >> Build the coolest Linux based applications with Moblin SDK & win great prizes >> Grand prize is a trip for two to an Open Source event anywhere in the world >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Fri Dec 5 13:38:28 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 5 Dec 2008 13:38:28 +0100 Subject: [Gambas-user] Action managment In-Reply-To: <561822.40087.qm@...1658...> References: <561822.40087.qm@...1658...> Message-ID: <200812051338.28476.gambas@...1...> On mercredi 3 d?cembre 2008, David Villalobos Cambronero wrote: > Hi all, I have a problem using Actions. That is what I got: > > I have a form let's call it FMain, in this form I have a work space that I > use to emmbed some others form, Let's suppose I emmbed a form in this work > space, let's call it Form2, in this form, I insert a class, this class has > some controls with actions, so at the end we have, two forms and one class: > FMain::Form2::class, all of them has the Action_Activate procedure, but the > Actions of the class are intersepted by the parent, in this case: Form2. > > How can I make my class to intersept his own Actions? > > Regards > > > -- > David > At the moment only classes that inherit Window can have an Action_Activate procedure. Can you explain exactly what your goal is? -- Benoit Minisini From leo_senpao at ...1541... Fri Dec 5 13:44:39 2008 From: leo_senpao at ...1541... (Leo Sendra) Date: Fri, 5 Dec 2008 20:44:39 +0800 (SGT) Subject: [Gambas-user] How to run gambas execute file Message-ID: <703401.97375.qm@...2025...> Hi all, I have a computer and I want this computer just run a gambas execute file. No need a Gambas IDE development tool. So, what should I install to this computer?? Must I install the development tool?? Thanks.. Nikmati chatting lebih sering di blog dan situs web. Gunakan Wizard Pembuat Pingbox Online. http://id.messenger.yahoo.com/pingbox/ From gambas at ...1... Fri Dec 5 12:45:41 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 5 Dec 2008 12:45:41 +0100 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <4938D783.2060204@...221...> References: <49379275.8@...221...> <73abb3e80812041106r3e0c4c79t84b9d3ca400b01cd@...627...> <4938D783.2060204@...221...> Message-ID: <200812051245.41508.gambas@...1...> On vendredi 5 d?cembre 2008, Rolf-Werner Eilert wrote: > Nicolas Koch schrieb: > > Rolf, > > > >> The question is simple: Is it possible to make a small window without > >> any gadgets appear and disappear after some seconds showing a small hint > >> such as "you got new messages..."? > > > > Yes. > > > > Ok on your project you have your main form say FMain, create another > > form call it FNewMsg. > > > > On FMain add a button or whatever way you want to call the FNewMsg form. > > > > ' Gambas class file > > > > PUBLIC SUB Form_Open() > > > > END > > > > PUBLIC SUB Button1_Click() > > FNewMsg.Show > > END > > > > Now on FNewMsg we just have the Message you wanted "you got new > > messages..." either as textlabel, msg or picture whatever and add a > > timer like the below > > > > FNewMsg > > ' Gambas class file > > > > PRIVATE CloseTimer AS NEW Timer AS "CloseTimer" > > > > PUBLIC SUB Form_Open() > > ME.Center > > CloseTimer.Delay = 4 * 1000 > > CloseTimer.Enabled = TRUE > > > > END > > > > PUBLIC SUB CloseTimer_Timer() > > ME.Close() > > END > > Thanks for that proposal. Of course, everything runs as expected, the > only thing is that the message window always has gadgets here, and I > cannot explain why. In the properties, I set this window to "Border - > None" and the gadgets disappear in design mode. But when the window is > called like in the example, it does have gadgets... > > > Rolf > It shouldn't, but it depends on the window manager you use. Which one do you use? Which version of Gambas do you use too? -- Benoit Minisini From gambas.fr at ...626... Fri Dec 5 15:21:51 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Fri, 5 Dec 2008 15:21:51 +0100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> Message-ID: <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> http://gambasdoc.org/help/comp/gb.qt/draw Draw.begin(drawingarea1) draw.point(x,y) draw.end is it that ??? 2008/12/4 Charles Capaday : > Thanks, this would be a nice feature indeed, however I was not looking for a component as such. Simply I asked whether the language has commands for mapping pixel values to x-y coordinate values, these where part of DOS Basic Compiler 7 for example and in VB as well I am pretty sure... > > Cheers, > > > Dr. Charles Capaday > Professor & Director > Brain and Movement Lab. > Dept. of Anatomy & Physiology > Faculty of Medicine, Laval University > http://www.brainandmovementlab.org/ > > Mailing address: > CRULRG F-6500 > Hopital Robert-Giffard > 2601 de la Canardiere, Beauport, QC > G1J 2G3 Canada > > Tel: +418-663-5747 (Sec.) > +418-663-5000 ext. 6736 (Off.) > +418-663-5000 ext. 6877 (Lab.) > Fax: +418-663-8756 > > >> -----Original Message----- >> From: Fabien Bodard [mailto:gambas.fr at ...626...] >> Sent: 4 d?cembre 2008 15:10 >> To: richard terry; mailing list for gambas users >> Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics >> >> i'm currently working on it, and made richard's wich true >> >> >> 2008/12/3 richard terry : >> > On Thu, 4 Dec 2008 05:05:22 am Charles Capaday wrote: >> > Fabians chart component may or may not help. >> > >> > I'll mail you some piccies of what it can do off list. >> > >> > Regards >> > >> > Richard >> > >> >> I'm interested in developing a graph object in Gambas to >> plot points, >> >> curves etc. Are there language statements for coordinate >> >> transformations such as to make, for example, the pixel >> locations of >> >> a rectangle into x,y coordinate values? >> >> >> >> >> >> Cheers, >> >> >> >> >> >> Dr. Charles Capaday >> >> Professor & Director >> >> Brain and Movement Lab. >> >> Dept. of Anatomy & Physiology >> >> Faculty of Medicine, Laval University >> >> http://www.brainandmovementlab.org/ >> >> >> >> Mailing address: >> >> CRULRG F-6500 >> >> Hopital Robert-Giffard >> >> 2601 de la Canardiere, Beauport, QC >> >> G1J 2G3 Canada >> >> >> >> Tel: +418-663-5747 (Sec.) >> >> +418-663-5000 ext. 6736 (Off.) >> >> +418-663-5000 ext. 6877 (Lab.) >> >> Fax: +418-663-8756 >> >> >> >> >> --------------------------------------------------------------------- >> >> ---- This SF.Net email is sponsored by the Moblin Your Move >> >> Developer's challenge Build the coolest Linux based >> applications with >> >> Moblin SDK & win great prizes Grand prize is a trip for two to an >> >> Open Source event anywhere in the world >> >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> >> _______________________________________________ >> >> Gambas-user mailing list >> >> Gambas-user at lists.sourceforge.net >> >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > >> > >> > >> > >> ---------------------------------------------------------------------- >> > --- This SF.Net email is sponsored by the Moblin Your Move >> Developer's >> > challenge Build the coolest Linux based applications with >> Moblin SDK & >> > win great prizes Grand prize is a trip for two to an Open >> Source event >> > anywhere in the world >> > http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> > _______________________________________________ >> > Gambas-user mailing list >> > Gambas-user at lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/gambas-user >> > >> >> -------------------------------------------------------------- >> ---------------- >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las >> Vegas, Nevada. >> The future of the web can't happen without you. Join us at >> MIX09 to help pave the way to the Next Web now. Learn more >> and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 >> .visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas.fr at ...626... Fri Dec 5 15:26:28 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Fri, 5 Dec 2008 15:26:28 +0100 Subject: [Gambas-user] How to run gambas execute file In-Reply-To: <703401.97375.qm@...2025...> References: <703401.97375.qm@...2025...> Message-ID: <6324a42a0812050626y665c52b8od426f5620579c0f7@...627...> no... just the runtime and libs normally the ide is in separated package. 2008/12/5 Leo Sendra : > Hi all, I have a computer and I want this computer just run a gambas execute file. No need a Gambas IDE development tool. > So, what should I install to this computer?? > Must I install the development tool?? > > Thanks.. > > > > Nikmati chatting lebih sering di blog dan situs web. Gunakan Wizard Pembuat Pingbox Online. http://id.messenger.yahoo.com/pingbox/ > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Fri Dec 5 15:38:14 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 5 Dec 2008 15:38:14 +0100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: References: Message-ID: <200812051538.14241.gambas@...1...> On mercredi 3 d?cembre 2008, Charles Capaday wrote: > I'm interested in developing a graph object in Gambas to plot points, > curves etc. Are there language statements for coordinate transformations > such as to make, for example, the pixel locations of a rectangle into > x,y coordinate values? > > > Cheers, > > > Dr. Charles Capaday > Professor & Director > Brain and Movement Lab. > Dept. of Anatomy & Physiology > Faculty of Medicine, Laval University > http://www.brainandmovementlab.org/ > > Mailing address: > CRULRG F-6500 > Hopital Robert-Giffard > 2601 de la Canardiere, Beauport, QC > G1J 2G3 Canada > > Tel: +418-663-5747 (Sec.) > +418-663-5000 ext. 6736 (Off.) > +418-663-5000 ext. 6877 (Lab.) > Fax: +418-663-8756 > No, because it is not very complex to do. Moreover, you have to use different algorithms according to what you are drawing. If you want to draw a curve, a simple matrix multiplication and a translation applied to point coordinates are enough. But if you want to implement a print preview (fox example), you will have to map positions and dimensions differently, to minimize drawing errors. Regards, -- Benoit Minisini From Charles.Capaday at ...2023... Fri Dec 5 16:00:03 2008 From: Charles.Capaday at ...2023... (Charles Capaday) Date: Fri, 5 Dec 2008 10:00:03 -0500 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> References: <200812040734.41502.rterry@...1946...><6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> Message-ID: Thanks draw.point(x,y) is in pixels, not coordinate values of ones coordinate system, anyway Benoit answered the question there are no commands for coordinate translation and one has to do it oneself, which is not hard, je vous remercie! Cheers, Dr. Charles Capaday Professor & Director Brain and Movement Lab. Dept. of Anatomy & Physiology Faculty of Medicine, Laval University http://www.brainandmovementlab.org/ Mailing address: CRULRG F-6500 Hopital Robert-Giffard 2601 de la Canardiere, Beauport, QC G1J 2G3 Canada Tel: +418-663-5747 (Sec.) +418-663-5000 ext. 6736 (Off.) +418-663-5000 ext. 6877 (Lab.) Fax: +418-663-8756 > -----Original Message----- > From: Fabien Bodard [mailto:gambas.fr at ...626...] > Sent: 5 d?cembre 2008 09:22 > To: mailing list for gambas users > Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics > > http://gambasdoc.org/help/comp/gb.qt/draw > > > Draw.begin(drawingarea1) > > draw.point(x,y) > > > draw.end > > > > is it that ??? > > > > > > > 2008/12/4 Charles Capaday : > > Thanks, this would be a nice feature indeed, however I was > not looking for a component as such. Simply I asked whether > the language has commands for mapping pixel values to x-y > coordinate values, these where part of DOS Basic Compiler 7 > for example and in VB as well I am pretty sure... > > > > > > > Cheers, > > > > > > Dr. Charles Capaday > > Professor & Director > > Brain and Movement Lab. > > Dept. of Anatomy & Physiology > > Faculty of Medicine, Laval University > > http://www.brainandmovementlab.org/ > > > > Mailing address: > > CRULRG F-6500 > > Hopital Robert-Giffard > > 2601 de la Canardiere, Beauport, QC > > G1J 2G3 Canada > > > > Tel: +418-663-5747 (Sec.) > > +418-663-5000 ext. 6736 (Off.) > > +418-663-5000 ext. 6877 (Lab.) > > Fax: +418-663-8756 > > > > > >> -----Original Message----- > >> From: Fabien Bodard [mailto:gambas.fr at ...626...] > >> Sent: 4 d?cembre 2008 15:10 > >> To: richard terry; mailing list for gambas users > >> Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics > >> > >> i'm currently working on it, and made richard's wich true > >> > >> > >> 2008/12/3 richard terry : > >> > On Thu, 4 Dec 2008 05:05:22 am Charles Capaday wrote: > >> > Fabians chart component may or may not help. > >> > > >> > I'll mail you some piccies of what it can do off list. > >> > > >> > Regards > >> > > >> > Richard > >> > > >> >> I'm interested in developing a graph object in Gambas to > >> plot points, > >> >> curves etc. Are there language statements for coordinate > >> >> transformations such as to make, for example, the pixel > >> locations of > >> >> a rectangle into x,y coordinate values? > >> >> > >> >> > >> >> Cheers, > >> >> > >> >> > >> >> Dr. Charles Capaday > >> >> Professor & Director > >> >> Brain and Movement Lab. > >> >> Dept. of Anatomy & Physiology > >> >> Faculty of Medicine, Laval University > >> >> http://www.brainandmovementlab.org/ > >> >> > >> >> Mailing address: > >> >> CRULRG F-6500 > >> >> Hopital Robert-Giffard > >> >> 2601 de la Canardiere, Beauport, QC G1J 2G3 Canada > >> >> > >> >> Tel: +418-663-5747 (Sec.) > >> >> +418-663-5000 ext. 6736 (Off.) > >> >> +418-663-5000 ext. 6877 (Lab.) > >> >> Fax: +418-663-8756 > >> >> > >> >> > >> > --------------------------------------------------------------------- > >> >> ---- This SF.Net email is sponsored by the Moblin Your Move > >> >> Developer's challenge Build the coolest Linux based > >> applications with > >> >> Moblin SDK & win great prizes Grand prize is a trip for > two to an > >> >> Open Source event anywhere in the world > >> >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ > >> >> _______________________________________________ > >> >> Gambas-user mailing list > >> >> Gambas-user at lists.sourceforge.net > >> >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > >> > > >> > > >> > > >> > --------------------------------------------------------------------- > >> - > >> > --- This SF.Net email is sponsored by the Moblin Your Move > >> Developer's > >> > challenge Build the coolest Linux based applications with > >> Moblin SDK & > >> > win great prizes Grand prize is a trip for two to an Open > >> Source event > >> > anywhere in the world > >> > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > >> > _______________________________________________ > >> > Gambas-user mailing list > >> > Gambas-user at lists.sourceforge.net > >> > https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > >> > >> -------------------------------------------------------------- > >> ---------------- > >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in > Las Vegas, > >> Nevada. > >> The future of the web can't happen without you. Join us at > >> MIX09 to help pave the way to the Next Web now. Learn more and > >> register at > >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 > >> .visitmix.com/ > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > > > > ---------------------------------------------------------------------- > > -------- SF.Net email is Sponsored by MIX09, March 18-20, > 2009 in Las > > Vegas, Nevada. > > The future of the web can't happen without you. Join us at > MIX09 to > > help pave the way to the Next Web now. Learn more and register at > > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmi > > x.com/ _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > -------------------------------------------------------------- > ---------------- > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las > Vegas, Nevada. > The future of the web can't happen without you. Join us at > MIX09 to help pave the way to the Next Web now. Learn more > and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 > .visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From emil at ...1913... Fri Dec 5 16:25:43 2008 From: emil at ...1913... (Tchekov.Net) Date: Fri, 5 Dec 2008 16:25:43 +0100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: Message-ID: I think there are too many possibilities available, so it must be leaved to the programmer to choose which one to use and how to implement - Carthesian, Polar, 3D and also some more exotical... So it is impossible to implement all of them in a programming language. Pixels as expression of physical output device (monitor or printer - with may be additional info about the DPI resolution) are enough to produce reasonable scaled output - image or graph or function plot or whatsoever... wish you many success in your work Emil -----Urspr?ngliche Nachricht----- Von: Charles Capaday [mailto:Charles.Capaday at ...2023...] Gesendet: Freitag, 5. Dezember 2008 16:00 An: mailing list for gambas users Betreff: Re: [Gambas-user] Coordinate system in Gambas Graphics Thanks draw.point(x,y) is in pixels, not coordinate values of ones coordinate system, anyway Benoit answered the question there are no commands for coordinate translation and one has to do it oneself, which is not hard, je vous remercie! Chee rs, Dr. Charles Capaday Professor & Director Brain and Movement Lab. Dept. of Anatomy & Physiology Faculty of Medicine, Laval University http://www.brainandmovementlab.org/ Mailing address: CRULRG F-6500 Hopital Robert-Giffard 2601 de la Canardiere, Beauport, QC G1J 2G3 Canada Tel: +418-663-5747 (Sec.) +418-663-5000 ext. 6736 (Off.) +418-663-5000 ext. 6877 (Lab.) Fax: +418-663-8756 > -----Original Message----- > From: Fabien Bodard [mailto:gambas.fr at ...626...] > Sent: 5 d?cembre 2008 09:22 > To: mailing list for gambas users > Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics > > http://gambasdoc.org/help/comp/gb.qt/draw > > > Draw.begin(drawingarea1) > > draw.point(x,y) > > > draw.end > > > > is it that ??? > > > > > > > 2008/12/4 Charles Capaday : > > Thanks, this would be a nice feature indeed, however I was > not looking for a component as such. Simply I asked whether > the language has commands for mapping pixel values to x-y > coordinate values, these where part of DOS Basic Compiler 7 > for example and in VB as well I am pretty sure... > > > > > > > Cheers, > > > > > > Dr. Charles Capaday > > Professor & Director > > Brain and Movement Lab. > > Dept. of Anatomy & Physiology > > Faculty of Medicine, Laval University > > http://www.brainandmovementlab.org/ > > > > Mailing address: > > CRULRG F-6500 > > Hopital Robert-Giffard > > 2601 de la Canardiere, Beauport, QC > > G1J 2G3 Canada > > > > Tel: +418-663-5747 (Sec.) > > +418-663-5000 ext. 6736 (Off.) > > +418-663-5000 ext. 6877 (Lab.) > > Fax: +418-663-8756 > > > > > >> -----Original Message----- > >> From: Fabien Bodard [mailto:gambas.fr at ...626...] > >> Sent: 4 d?cembre 2008 15:10 > >> To: richard terry; mailing list for gambas users > >> Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics > >> > >> i'm currently working on it, and made richard's wich true > >> > >> > >> 2008/12/3 richard terry : > >> > On Thu, 4 Dec 2008 05:05:22 am Charles Capaday wrote: > >> > Fabians chart component may or may not help. > >> > > >> > I'll mail you some piccies of what it can do off list. > >> > > >> > Regards > >> > > >> > Richard > >> > > >> >> I'm interested in developing a graph object in Gambas to > >> plot points, > >> >> curves etc. Are there language statements for coordinate > >> >> transformations such as to make, for example, the pixel > >> locations of > >> >> a rectangle into x,y coordinate values? > >> >> > >> >> > >> >> Cheers, > >> >> > >> >> > >> >> Dr. Charles Capaday > >> >> Professor & Director > >> >> Brain and Movement Lab. > >> >> Dept. of Anatomy & Physiology > >> >> Faculty of Medicine, Laval University > >> >> http://www.brainandmovementlab.org/ > >> >> > >> >> Mailing address: > >> >> CRULRG F-6500 > >> >> Hopital Robert-Giffard > >> >> 2601 de la Canardiere, Beauport, QC G1J 2G3 Canada > >> >> > >> >> Tel: +418-663-5747 (Sec.) > >> >> +418-663-5000 ext. 6736 (Off.) > >> >> +418-663-5000 ext. 6877 (Lab.) > >> >> Fax: +418-663-8756 > >> >> > >> >> > >> > --------------------------------------------------------------------- > >> >> ---- This SF.Net email is sponsored by the Moblin Your Move > >> >> Developer's challenge Build the coolest Linux based > >> applications with > >> >> Moblin SDK & win great prizes Grand prize is a trip for > two to an > >> >> Open Source event anywhere in the world > >> >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ > >> >> _______________________________________________ > >> >> Gambas-user mailing list > >> >> Gambas-user at lists.sourceforge.net > >> >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > >> > > >> > > >> > > >> > --------------------------------------------------------------------- > >> - > >> > --- This SF.Net email is sponsored by the Moblin Your Move > >> Developer's > >> > challenge Build the coolest Linux based applications with > >> Moblin SDK & > >> > win great prizes Grand prize is a trip for two to an Open > >> Source event > >> > anywhere in the world > >> > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > >> > _______________________________________________ > >> > Gambas-user mailing list > >> > Gambas-user at lists.sourceforge.net > >> > https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > >> > >> -------------------------------------------------------------- > >> ---------------- > >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in > Las Vegas, > >> Nevada. > >> The future of the web can't happen without you. Join us at > >> MIX09 to help pave the way to the Next Web now. Learn more and > >> register at > >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 > >> .visitmix.com/ > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > > > > ---------------------------------------------------------------------- > > -------- SF.Net email is Sponsored by MIX09, March 18-20, > 2009 in Las > > Vegas, Nevada. > > The future of the web can't happen without you. Join us at > MIX09 to > > help pave the way to the Next Web now. Learn more and register at > > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmi > > x.com/ _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > -------------------------------------------------------------- > ---------------- > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las > Vegas, Nevada. > The future of the web can't happen without you. Join us at > MIX09 to help pave the way to the Next Web now. Learn more > and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 > .visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > ---------------------------------------------------------------------------- -- SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. The future of the web can't happen without you. Join us at MIX09 to help pave the way to the Next Web now. Learn more and register at http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ _______________________________________________ Gambas-user mailing list Gambas-user at lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user From m0e.lnx at ...626... Fri Dec 5 17:18:06 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Fri, 5 Dec 2008 10:18:06 -0600 Subject: [Gambas-user] Gambas2-2.9 Possible bug when running in russian locale Message-ID: <1f1e8c1b0812050818k1e863fafjd811f4a19728fa52@...627...> Here is the problem. I have an application which offers different languages to select from (English, Spanish, and Russian ATM) The problem is that when I select russian, I get this error that says This application has raised an unexpected error and must abort [31] Unsupported string conversion. Stock.AddPath.60 This only happens when it is ran with the ru_RU locale. To see the error yourself, checkout a copy of the program svn co http://vinstall-ng.googlecode.com/svn/branches/iVL vinstall-ng Set the locale to ru_RU and execute the binary cd vinstall-ng LANG=ru_RU ./installer.gambas Please HELP From doriano.blengino at ...1909... Fri Dec 5 17:24:21 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Fri, 05 Dec 2008 17:24:21 +0100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: References: <200812040734.41502.rterry@...1946...><6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> Message-ID: <493955B5.5090203@...1909...> Charles Capaday ha scritto: > Thanks draw.point(x,y) is in pixels, not coordinate values of ones coordinate system, anyway Benoit answered the question there are no commands for coordinate translation and one has to do it oneself, which is not hard, je vous remercie! > Hmm, simple linear transformation is possible by using draw.translate() and draw.scale(); draw.reset() will reset the transformation matrix. Draw.push() and draw.pop() exist to save and restore the matrix. I think this is enough to map simple world 2D coordinates; it is effective and scales everything but text. For more complicated things, they should be implemented in software. Regards, Doriano Blengino From Charles.Capaday at ...2023... Fri Dec 5 17:36:12 2008 From: Charles.Capaday at ...2023... (Charles Capaday) Date: Fri, 5 Dec 2008 11:36:12 -0500 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <493955B5.5090203@...1909...> References: <200812040734.41502.rterry@...1946...><6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> Message-ID: Grazie, this is the best answer I got, most others seemed to say there was no such thing, which frankly surprised me. Cheers, Dr. Charles Capaday Professor & Director Brain and Movement Lab. Dept. of Anatomy & Physiology Faculty of Medicine, Laval University http://www.brainandmovementlab.org/ Mailing address: CRULRG F-6500 Hopital Robert-Giffard 2601 de la Canardiere, Beauport, QC G1J 2G3 Canada Tel: +418-663-5747 (Sec.) +418-663-5000 ext. 6736 (Off.) +418-663-5000 ext. 6877 (Lab.) Fax: +418-663-8756 > -----Original Message----- > From: Doriano Blengino [mailto:doriano.blengino at ...1909...] > Sent: 5 d?cembre 2008 11:24 > To: mailing list for gambas users > Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics > > Charles Capaday ha scritto: > > Thanks draw.point(x,y) is in pixels, not coordinate values > of ones coordinate system, anyway Benoit answered the > question there are no commands for coordinate translation and > one has to do it oneself, which is not hard, je vous remercie! > > > Hmm, > > simple linear transformation is possible by using > draw.translate() and draw.scale(); draw.reset() will reset > the transformation matrix. > Draw.push() and draw.pop() exist to save and restore the matrix. > > I think this is enough to map simple world 2D coordinates; it > is effective and scales everything but text. > > For more complicated things, they should be implemented in software. > > Regards, > Doriano Blengino > > > -------------------------------------------------------------- > ---------------- > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las > Vegas, Nevada. > The future of the web can't happen without you. Join us at > MIX09 to help pave the way to the Next Web now. Learn more > and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 > .visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Fri Dec 5 18:13:33 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 5 Dec 2008 18:13:33 +0100 Subject: [Gambas-user] Gambas2-2.9 Possible bug when running in russian locale In-Reply-To: <1f1e8c1b0812050818k1e863fafjd811f4a19728fa52@...627...> References: <1f1e8c1b0812050818k1e863fafjd811f4a19728fa52@...627...> Message-ID: <200812051813.33564.gambas@...1...> On vendredi 5 d?cembre 2008, M0E Lnx wrote: > Here is the problem. > I have an application which offers different languages to select from > (English, Spanish, and Russian ATM) > > The problem is that when I select russian, I get this error that says > > This application has raised an unexpected error and must abort > [31] Unsupported string conversion. > Stock.AddPath.60 > > This only happens when it is ran with the ru_RU locale. > > To see the error yourself, checkout a copy of the program > svn co http://vinstall-ng.googlecode.com/svn/branches/iVL vinstall-ng > > Set the locale to ru_RU and execute the binary > cd vinstall-ng > LANG=ru_RU ./installer.gambas > > Please HELP > This error depends on the configuration of your system. The Stock.AddPath() function is called to create a list of directories where icons must be searched. By reading the source code again, I noticed that when icon directories are taken from configuration file, or configuration programs like "kde-config", they are supposed to be in UTF-8, which may not be true. Can you tell which desktop you use, which icon theme you use, and where the icons are stored on your system? -- Benoit Minisini From m0e.lnx at ...626... Fri Dec 5 20:20:29 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Fri, 5 Dec 2008 13:20:29 -0600 Subject: [Gambas-user] Gambas2-2.9 Possible bug when running in russian locale In-Reply-To: <200812051813.33564.gambas@...1...> References: <1f1e8c1b0812050818k1e863fafjd811f4a19728fa52@...627...> <200812051813.33564.gambas@...1...> Message-ID: <1f1e8c1b0812051120p494a6744r1f6354a65acf47b7@...627...> I'm not using a Desktop at all... running JWM with a gb.gtk used in the project.. I did test with ru_RU.utf8 and it works fine that way... but ru_RU does produce the error. On Fri, Dec 5, 2008 at 11:13 AM, Benoit Minisini wrote: > On vendredi 5 d?cembre 2008, M0E Lnx wrote: >> Here is the problem. >> I have an application which offers different languages to select from >> (English, Spanish, and Russian ATM) >> >> The problem is that when I select russian, I get this error that says >> >> This application has raised an unexpected error and must abort >> [31] Unsupported string conversion. >> Stock.AddPath.60 >> >> This only happens when it is ran with the ru_RU locale. >> >> To see the error yourself, checkout a copy of the program >> svn co http://vinstall-ng.googlecode.com/svn/branches/iVL vinstall-ng >> >> Set the locale to ru_RU and execute the binary >> cd vinstall-ng >> LANG=ru_RU ./installer.gambas >> >> Please HELP >> > > This error depends on the configuration of your system. > > The Stock.AddPath() function is called to create a list of directories where > icons must be searched. > > By reading the source code again, I noticed that when icon directories are > taken from configuration file, or configuration programs like "kde-config", > they are supposed to be in UTF-8, which may not be true. > > Can you tell which desktop you use, which icon theme you use, and where the > icons are stored on your system? > > -- > Benoit Minisini > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From m0e.lnx at ...626... Fri Dec 5 20:35:17 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Fri, 5 Dec 2008 13:35:17 -0600 Subject: [Gambas-user] Feature request Message-ID: <1f1e8c1b0812051135m246212d8sd78f3f7186eb3cca@...627...> I've noticed the radio button has no .Adjust method. This would be nice, because in my case, I have a radio button with text, that when translated to other languages can be quite long. It'd be nice to have it work like the textlabels work with an .adjust method. Cheers! From gambas at ...1... Fri Dec 5 21:54:34 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 5 Dec 2008 21:54:34 +0100 Subject: [Gambas-user] TrayIcon control In-Reply-To: <4936C5E5.3050304@...2015...> References: <4936C5E5.3050304@...2015...> Message-ID: <200812052154.34296.gambas@...1...> On mercredi 3 d?cembre 2008, Toni wrote: > Hi, > > I'm using the "trayicon" control and I have found a couple of problems > with it. > > If I use "ShowModal" or "ShowDialog" to show a Form within one of its > "events" it happens that: 1. It does'nt prevent the control from getting > new events, and 2. if the application is Closed with that Form still > opened, it crashes with signal #11. > > The other problem is that, although I set its visible property to FALSE > in the IDE, it keeps changing back to visible = True alone... > > Regards, > > Toni > > p.s. I use Gambas 2.9 (svn version) > These are GTK+ bugs. I fixed them in revision #1722. Regards, -- Benoit Minisini From gambas.fr at ...626... Sat Dec 6 10:55:26 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 6 Dec 2008 10:55:26 +0100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> Message-ID: <6324a42a0812060155u204563e2m78185113d723f8d3@...627...> i apologize, it seem i was really tired the night I've read your mail ... 2008/12/5 Charles Capaday : > Grazie, this is the best answer I got, most others seemed to say there was no such thing, which frankly surprised me. > > Cheers, > > > Dr. Charles Capaday > Professor & Director > Brain and Movement Lab. > Dept. of Anatomy & Physiology > Faculty of Medicine, Laval University > http://www.brainandmovementlab.org/ > > Mailing address: > CRULRG F-6500 > Hopital Robert-Giffard > 2601 de la Canardiere, Beauport, QC > G1J 2G3 Canada > > Tel: +418-663-5747 (Sec.) > +418-663-5000 ext. 6736 (Off.) > +418-663-5000 ext. 6877 (Lab.) > Fax: +418-663-8756 > > >> -----Original Message----- >> From: Doriano Blengino [mailto:doriano.blengino at ...1909...] >> Sent: 5 d?cembre 2008 11:24 >> To: mailing list for gambas users >> Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics >> >> Charles Capaday ha scritto: >> > Thanks draw.point(x,y) is in pixels, not coordinate values >> of ones coordinate system, anyway Benoit answered the >> question there are no commands for coordinate translation and >> one has to do it oneself, which is not hard, je vous remercie! >> > >> Hmm, >> >> simple linear transformation is possible by using >> draw.translate() and draw.scale(); draw.reset() will reset >> the transformation matrix. >> Draw.push() and draw.pop() exist to save and restore the matrix. >> >> I think this is enough to map simple world 2D coordinates; it >> is effective and scales everything but text. >> >> For more complicated things, they should be implemented in software. >> >> Regards, >> Doriano Blengino >> >> >> -------------------------------------------------------------- >> ---------------- >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las >> Vegas, Nevada. >> The future of the web can't happen without you. Join us at >> MIX09 to help pave the way to the Next Web now. Learn more >> and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 >> .visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From david_villalobos_c at ...43... Sat Dec 6 14:39:30 2008 From: david_villalobos_c at ...43... (David Villalobos Cambronero) Date: Sat, 6 Dec 2008 05:39:30 -0800 (PST) Subject: [Gambas-user] Action managment References: <561822.40087.qm@...1658...> <200812051338.28476.gambas@...1...> Message-ID: <551483.52123.qm@...1657...> Well, I have been working in this project: http://code.google.com/p/mysql-gui/ what I need I my class to raise the Action_Activate event, I inherit Window to my class and it works fine. Regards -- David ----- Original Message ---- From: Benoit Minisini To: mailing list for gambas users Sent: Friday, December 5, 2008 6:38:28 AM Subject: Re: [Gambas-user] Action managment On mercredi 3 d?cembre 2008, David Villalobos Cambronero wrote: > Hi all, I have a problem using Actions. That is what I got: > > I have a form let's call it FMain, in this form I have a work space that I > use to emmbed some others form, Let's suppose I emmbed a form in this work > space, let's call it Form2, in this form, I insert a class, this class has > some controls with actions, so at the end we have, two forms and one class: > FMain::Form2::class, all of them has the Action_Activate procedure, but the > Actions of the class are intersepted by the parent, in this case: Form2. > > How can I make my class to intersept his own Actions? > > Regards > > > -- > David > At the moment only classes that inherit Window can have an Action_Activate procedure. Can you explain exactly what your goal is? -- Benoit Minisini ------------------------------------------------------------------------------ SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. The future of the web can't happen without you. Join us at MIX09 to help pave the way to the Next Web now. Learn more and register at http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ _______________________________________________ Gambas-user mailing list Gambas-user at lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user From Charles.Capaday at ...2023... Sat Dec 6 19:37:08 2008 From: Charles.Capaday at ...2023... (Charles Capaday) Date: Sat, 6 Dec 2008 13:37:08 -0500 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <6324a42a0812060155u204563e2m78185113d723f8d3@...627...> References: <200812040734.41502.rterry@...1946...><6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...><6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...><493955B5.5090203@...1909...> <6324a42a0812060155u204563e2m78185113d723f8d3@...627...> Message-ID: Not a problem, it is quite sportly of you to acknowledge the error... Cheers, Dr. Charles Capaday Professor & Director Brain and Movement Lab. Dept. of Anatomy & Physiology Faculty of Medicine, Laval University http://www.brainandmovementlab.org/ Mailing address: CRULRG F-6500 Hopital Robert-Giffard 2601 de la Canardiere, Beauport, QC G1J 2G3 Canada Tel: +418-663-5747 (Sec.) +418-663-5000 ext. 6736 (Off.) +418-663-5000 ext. 6877 (Lab.) Fax: +418-663-8756 > -----Original Message----- > From: Fabien Bodard [mailto:gambas.fr at ...626...] > Sent: 6 d?cembre 2008 04:55 > To: mailing list for gambas users > Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics > > i apologize, it seem i was really tired the night I've read > your mail ... > > > > > 2008/12/5 Charles Capaday : > > Grazie, this is the best answer I got, most others seemed > to say there was no such thing, which frankly surprised me. > > > > > > > Cheers, > > > > > > Dr. Charles Capaday > > Professor & Director > > Brain and Movement Lab. > > Dept. of Anatomy & Physiology > > Faculty of Medicine, Laval University > > http://www.brainandmovementlab.org/ > > > > Mailing address: > > CRULRG F-6500 > > Hopital Robert-Giffard > > 2601 de la Canardiere, Beauport, QC > > G1J 2G3 Canada > > > > Tel: +418-663-5747 (Sec.) > > +418-663-5000 ext. 6736 (Off.) > > +418-663-5000 ext. 6877 (Lab.) > > Fax: +418-663-8756 > > > > > >> -----Original Message----- > >> From: Doriano Blengino [mailto:doriano.blengino at ...1909...] > >> Sent: 5 d?cembre 2008 11:24 > >> To: mailing list for gambas users > >> Subject: Re: [Gambas-user] Coordinate system in Gambas Graphics > >> > >> Charles Capaday ha scritto: > >> > Thanks draw.point(x,y) is in pixels, not coordinate values > >> of ones coordinate system, anyway Benoit answered the > question there > >> are no commands for coordinate translation and one has to do it > >> oneself, which is not hard, je vous remercie! > >> > > >> Hmm, > >> > >> simple linear transformation is possible by using > >> draw.translate() and draw.scale(); draw.reset() will reset the > >> transformation matrix. > >> Draw.push() and draw.pop() exist to save and restore the matrix. > >> > >> I think this is enough to map simple world 2D coordinates; it is > >> effective and scales everything but text. > >> > >> For more complicated things, they should be implemented in > software. > >> > >> Regards, > >> Doriano Blengino > >> > >> > >> -------------------------------------------------------------- > >> ---------------- > >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in > Las Vegas, > >> Nevada. > >> The future of the web can't happen without you. Join us at > >> MIX09 to help pave the way to the Next Web now. Learn more and > >> register at > >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 > >> .visitmix.com/ > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > > > > ---------------------------------------------------------------------- > > -------- SF.Net email is Sponsored by MIX09, March 18-20, > 2009 in Las > > Vegas, Nevada. > > The future of the web can't happen without you. Join us at > MIX09 to > > help pave the way to the Next Web now. Learn more and register at > > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmi > > x.com/ _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > -------------------------------------------------------------- > ---------------- > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las > Vegas, Nevada. > The future of the web can't happen without you. Join us at > MIX09 to help pave the way to the Next Web now. Learn more > and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009 > .visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From leonardo at ...1237... Sun Dec 7 00:22:38 2008 From: leonardo at ...1237... (Leonardo Miliani) Date: Sun, 07 Dec 2008 00:22:38 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 Message-ID: <493B093E.8050509@...1237...> I found a bug into Gambas 2.9 running on Gnome 2.24: the masks of the windows are not applied, resulting in forms that visualize the window borders. Try the Clock example and you'll understand what I mean. The problem doesn't appear on KDE 4.x and Gnome <=2.22. -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software Co-fondatore di Gambas-it.org Il sito di riferimento della comunit? italiana degli utenti di Gambas www.gambas-it.org From almodook at ...2007... Sun Dec 7 01:24:00 2008 From: almodook at ...2007... (moon_walker) Date: Sat, 6 Dec 2008 16:24:00 -0800 (PST) Subject: [Gambas-user] configure...: components were disabled... Message-ID: <20876394.post@...1379...> Hi Gurus, i am just runned the ./configure for rev. 1722. I realised that many components were disabled: gb.qt gb.gtk gb.desktop gb.db.odbc ... could you tell me maybe the reason? thanks Attila -- View this message in context: http://www.nabble.com/configure...%3A-components-were-disabled...-tp20876394p20876394.html Sent from the gambas-user mailing list archive at Nabble.com. From rterry at ...1946... Sun Dec 7 02:39:27 2008 From: rterry at ...1946... (richard terry) Date: Sun, 7 Dec 2008 12:39:27 +1100 Subject: [Gambas-user] File read question LineInput Question Message-ID: <200812071239.28150.rterry@...1946...> I have files, could be thousands of lines, but the start/end lines are like this: FHS|^~\&|APOLLO|NATA^2178^N|||200811101339+1100||dhm0003.ORU||3 FTS|1|3  I wondered what the rectangle represents I guess must be some sort of byte count??, and how to get rid of it as I process the file. My code to read the file which works fine is: hfile = Open sFilename For Input While Not Eof(hfile) Line Input #hfile, OneLine Thanks in anticipation. richard From rterry at ...1946... Sun Dec 7 05:19:21 2008 From: rterry at ...1946... (richard terry) Date: Sun, 7 Dec 2008 15:19:21 +1100 Subject: [Gambas-user] Reproducable Bug in IDE search routine Message-ID: <200812071519.21586.rterry@...1946...> Build 1721. Quite specific, but reproducable. When find previous is unable to find another occurence of the search string, and the search in subroutine button is depressed, it stays in an endless loop with the busy cursor on the screen. The gambas process must be killed to extricate. To replicate: 1) Create an empty unique subroutine e.g: Public sub Find_this() End 2) Click the search in subroutine only button 3) Double click on the Find_this, so it is highlighted. 4) Hit Ctrl_F for find, "Find this" will then appear in the text to search for at the bottom of the IDE 5) Click on the find_previous up arrow button > Lock up. I've tried this a number of times and same result. Regards Richard From charles at ...1784... Sun Dec 7 10:20:16 2008 From: charles at ...1784... (charlesg) Date: Sun, 7 Dec 2008 01:20:16 -0800 (PST) Subject: [Gambas-user] Trumpets please! Message-ID: <20879250.post@...1379...> Hi, Gambas 2.9.0 is on the coverdisk of my favourite Linux mag (Linux Format LXF114 Jan 09) again. Some very nice comments in the magazine as well. Such as "...has blossomed into one of the finest development environments in the free software world - the Gambas team certainly has a lot to be proud of." Also "Gambas is, by a huge margin, the easiest way to dip your toe into open source coding, and we simply can't recommend it enough." All thoroughly deserved of course. -- View this message in context: http://www.nabble.com/Trumpets-please%21-tp20879250p20879250.html Sent from the gambas-user mailing list archive at Nabble.com. From charles at ...1784... Sun Dec 7 13:00:54 2008 From: charles at ...1784... (charlesg) Date: Sun, 7 Dec 2008 04:00:54 -0800 (PST) Subject: [Gambas-user] How to run gambas execute file In-Reply-To: <703401.97375.qm@...2025...> References: <703401.97375.qm@...2025...> Message-ID: <20880313.post@...1379...> Hi, Gambas Runtime Here are my experiences with copying a Gambas program developed on one computer to a second computer. The first computer is running Ubuntu 8.04 and Gambas 2.8. The second computer is running Ubuntu 8.10 without installed Gambas. Making an installation program from the development version of Gambas requires two programs on the development machine which were not available in 8.04. The first task is to install these programs. Applications, Accessories, Terminal from the prompt: "sudo apt-get install debhelper" and enter. Give your password and respond as required. Follow this with "sudo apt-get install fakeroot". Start the development version of Gambas and load the application. Click on the button 'Make Installation Package' (next to the meshed gears). Click next from page 1. Package Information and from 2. Changelog. If the debhelper installed correctly then the Debian and Ubuntu entries should be selectable. There will be a warning that rpmbuild and tar-1.13 are not installed which is ok for this tutorial. Click on the Ubuntu entry and then on next. Choose a package group (I chose 'Office') and click next. Choose a menu entry (I chose 'apps' and 'database') and select 'office' under category (again?). choose a destination directory for the installation package (I created a sub-directory under Home - doesn't matter what it is called). Finally click ok on create package. if all goes well you will get a message that the installation has been successful. Close the installation process and exit from Gambas itself. Copy the directory across to the new computer. In my case the directory contained five files including the all important .deb file. Places, Home Folder. Go to the directory and double-click the .deb file. Close the package installer once it has completed. You might get a warning message (as I did) that a later version exists in the repository. This just means that your masterpiece has the same name as an existing piece of software. Ignore the warning for the moment but consider changing the name of your program or your will continually be badgered to upgrade to the latest (but incorrect) version. You should now find your program in the menu you specified (in my case under applications, office) When I first tried to run the program, it warned that it could not find the sqlite driver so I went system, administration, synaptic. gambas in the quicksearch window to display all the gambas related packages. Find the entry gambas2-gb-db-sqlite and click the box next to it. Click 'mark for installation' and then 'apply' and 'apply' again. Close Synaptic package manager. Obviously this would be not be needed if you are using MySQL or PostgreSQL. When I ran my program again, it complained that it could not find the required database. Not surprising really because it isn't there. More importantly, the error message tells you that Gambas runtime expects to find the sqlite file in /usr/bin. Initially it refused to allow me to copy the file into /usr/bin because I did not have permission. Applicatiion, Accessories, Terminal and then opened Nautilus (the file browser) with 'sudo nautilus' and give the su password. I can then copy the sqlite database into /usr/bin. Exit from nautilus (file browser) and close the terminal window. My program now works. I must say it does not look as pretty on the runtime computer as it did on the development machine. I don't know if that is something to do with Gambas or the video card in the runtime computer. I also made the fatal mistake at one stage of installing the runtime version of the software on the development machine. This rendered the development version of Gambas inoperative. I had to go into synaptic and un-install gambas-runtime to fix this. -- View this message in context: http://www.nabble.com/How-to-run-gambas-execute-file-tp20853085p20880313.html Sent from the gambas-user mailing list archive at Nabble.com. From ronstk at ...239... Sun Dec 7 12:33:32 2008 From: ronstk at ...239... (Ron_1st) Date: Sun, 7 Dec 2008 12:33:32 +0100 Subject: [Gambas-user] File read question LineInput Question In-Reply-To: <200812071239.28150.rterry@...1946...> References: <200812071239.28150.rterry@...1946...> Message-ID: <200812071233.32820.ronstk@...239...> On Sunday 07 December 2008, richard terry wrote: > I have files, could be thousands of lines, but the start/end lines are like > this: > > FHS|^~\&|APOLLO|NATA^2178^N|||200811101339+1100||dhm0003.ORU||3 > > > FTS|1|3 > > > I wondered what the rectangle represents I guess must be some sort of byte > count??, and how to get rid of it as I process the file. > > My code to read the file which works fine is: > > hfile = Open sFilename For Input > > While Not Eof(hfile) > Line Input #hfile, OneLine > > > Thanks in anticipation. > > richard > many programs write to there files some magis header for identification. In *.gif files you can see GIF98, *.jpeg uses JIFF as readable text. They can also use a byte(s) like FBF9 im some *.mpg files. Here the block is a character not available as visual glyph for screen in your current font. I asume the file(s) is/are longer as 256 bytes so the need 2 bytes for length. Using 'khexedit' (KDE) you can see if all those files start with the same byte. The last square in your example can be part of a CR/LF or a close marker. Without some of those files and/or know what program made them it is not easy to see the logic and do a absolute statement but I think my gues is right. Best regards Ron_1st From wdahn at ...1000... Sun Dec 7 13:27:57 2008 From: wdahn at ...1000... (Werner) Date: Sun, 07 Dec 2008 20:27:57 +0800 Subject: [Gambas-user] Trumpets please! In-Reply-To: <20879250.post@...1379...> References: <20879250.post@...1379...> Message-ID: <493BC14D.7010208@...1000...> charlesg wrote: > Hi, > > Gambas 2.9.0 is on the coverdisk of my favourite Linux mag (Linux Format > LXF114 Jan 09) again. Some very nice comments in the magazine as well. Such > as "...has blossomed into one of the finest development environments in the > free software world - the Gambas team certainly has a lot to be proud of." > > Also "Gambas is, by a huge margin, the easiest way to dip your toe into open > source coding, and we simply can't recommend it enough." > > All thoroughly deserved of course. > In the same vein: Gambas has been the IT tool of choice for the annual Hebe Haven Yacht Club 24 Hour Dinghy Charity Race. It is used for lap counting, race publishing and results calculations ever since version 1.0.9. This years' takings were 115,000US$, over the last few years totaling around 500,000US$. The proceeds go to local charities such as the Children's Cancer Foundation. http://www.hhyc.org.hk/Photo%20Gallery/Yachting/Sponsorship%20Proposal%20-%2024hr_21%20Apr%202008.pdf Thank you, Benoit for an outstanding job. Regards, Werner From leo_senpao at ...1541... Sun Dec 7 14:39:19 2008 From: leo_senpao at ...1541... (Leo Sendra) Date: Sun, 7 Dec 2008 21:39:19 +0800 (SGT) Subject: [Gambas-user] Ask about com access Message-ID: <322963.37774.qm@...2026...> Hi all, I want to ask.. How to access a com port in gambas? I want my program to access a cash drawer using gambas. Thanks... Menambah banyak teman sangatlah mudah dan cepat. Undang teman dari Hotmail, Gmail ke Yahoo! Messenger sekarang! http://id.messenger.yahoo.com/invite/ From sbungay at ...981... Sun Dec 7 15:48:40 2008 From: sbungay at ...981... (Stephen Bungay) Date: Sun, 07 Dec 2008 09:48:40 -0500 Subject: [Gambas-user] Ask about com access In-Reply-To: <322963.37774.qm@...2026...> References: <322963.37774.qm@...2026...> Message-ID: <493BE248.4010808@...981...> I wrote a complete POS in GAMBAS but the cash drawer was connected to the parallell device.. however, I did dump text to an LED pole display, to show the customer how much they owed and the change due etc. Should be fairly similar, knowing the control codes to send to the cash drawer might be the difficult part (might not be well documented). PUBLIC SUB OutputToPoleDisplay(pOutputString AS String) DIM ShellString AS String ClearPoleDisplay ShellString = "echo -ne \"" & pOutputString & "\" > /dev/ttyS0" SHELL ShellString WAIT END PUBLIC SUB ClearPoleDisplay() SHELL "echo -ne \"\n\n\n\" > /dev/ttyS0" WAIT END Regards Steve :) Leo Sendra wrote: > Hi all, I want to ask.. How to access a com port in gambas? I want my program to access a cash drawer using gambas. > > Thanks... > > > > Menambah banyak teman sangatlah mudah dan cepat. Undang teman dari Hotmail, Gmail ke Yahoo! Messenger sekarang! http://id.messenger.yahoo.com/invite/ > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From leonardo at ...1237... Sun Dec 7 16:28:39 2008 From: leonardo at ...1237... (Leonardo Miliani) Date: Sun, 07 Dec 2008 16:28:39 +0100 Subject: [Gambas-user] Another graphical bug in Gambas 2.9 Message-ID: <493BEBA7.4010504@...1237...> Maybe I found another graphical bug in Gambas 2.9. I use Ubuntu 8.10 with Gnome 2.24 and if I use a Qt project I get the window decorations even if I chose not to see them (window border set to 'none'). -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software Co-fondatore di Gambas-it.org Il sito di riferimento della comunit? italiana degli utenti di Gambas www.gambas-it.org From gambas at ...1... Sun Dec 7 20:03:26 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 7 Dec 2008 20:03:26 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <493B093E.8050509@...1237...> References: <493B093E.8050509@...1237...> Message-ID: <200812072003.26596.gambas@...1...> On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: > I found a bug into Gambas 2.9 running on Gnome 2.24: the masks of the > windows are not applied, resulting in forms that visualize the window > borders. > > Try the Clock example and you'll understand what I mean. > > The problem doesn't appear on KDE 4.x and Gnome <=2.22. I don't have this problem when running the Clock example with gb.gtk, on Mandriva 2009 with KDE 3.5.10. I think the problem comes from the Gnome 2.24 window manager. -- Benoit Minisini From nkoch22 at ...626... Sun Dec 7 20:27:53 2008 From: nkoch22 at ...626... (nkoch22 at ...626...) Date: Sun, 07 Dec 2008 19:27:53 +0000 Subject: [Gambas-user] GAMBAS Suggestions Message-ID: <000e0cd296181a7269045d79e8e0@...2027...> Gambas Community, I find it curious that such a great piece of software doesn't have a better updated website and a bug/tracking system. All I see are a few forums.. some outdated and just the sourceforge list with only a few items on it in the tracker section. To help speed development I strongly suggest a bug / tracking system. Additionally gambasrad.org needs some serious updating. I'd be willing to offer help if that's what is needed. One of GAMBAS strong points was the good user list with lots of help and a pretty informative basic wiki of operations. I think we as a community need to expand this knowledge. Best Regards, Nick Koch From gambas at ...1... Sun Dec 7 21:34:01 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 7 Dec 2008 21:34:01 +0100 Subject: [Gambas-user] Another graphical bug in Gambas 2.9 In-Reply-To: <493BEBA7.4010504@...1237...> References: <493BEBA7.4010504@...1237...> Message-ID: <200812072134.01933.gambas@...1...> On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: > Maybe I found another graphical bug in Gambas 2.9. > > I use Ubuntu 8.10 with Gnome 2.24 and if I use a Qt project I get the > window decorations even if I chose not to see them (window border set to > 'none'). This could confirm that there is something wrong in the Gnome 2.24 window manager on Ubuntu 8.10... -- Benoit Minisini From rterry at ...1946... Sun Dec 7 21:38:59 2008 From: rterry at ...1946... (richard terry) Date: Mon, 8 Dec 2008 07:38:59 +1100 Subject: [Gambas-user] GAMBAS Suggestions In-Reply-To: <000e0cd296181a7269045d79e8e0@...2027...> References: <000e0cd296181a7269045d79e8e0@...2027...> Message-ID: <200812080738.59954.rterry@...1946...> On Mon, 8 Dec 2008 06:27:53 am nkoch22 at ...626... wrote: > Gambas Community, > > I find it curious that such a great piece of software doesn't have a better > updated website and a bug/tracking system. I think the problem is it's such great software and so rewarding to use that we all just beaver away programming!!!! Having said that I agree. I think a great place to start would be better examples for beginners, with a demo like the wxPython demo which shows at a very basic level how to use all the controls. I've been collecting bits of code in the hope that this would one day come to pass. We could all contribute a small part if someone could oversee it. Unfortunately like most people of the planet I suspect that many of us work inoordinate hours (I'm in general practice in Australia - get to work 7:30am, leave to go home at 6pm, on call 24/24 7/7, and that sort of stuff combined with the that that many of us are enthusiastic amateurs rather than trained seasoned programmers makes it difficult. Regards Richard > > All I see are a few forums.. some outdated and just the sourceforge list > with only a few items on it in the tracker section. > > To help speed development I strongly suggest a bug / tracking system. > Additionally gambasrad.org needs some serious updating. I'd be willing to > offer help if that's what is needed. One of GAMBAS strong points was the > good user list with lots of help and a pretty informative basic wiki of > operations. I think we as a community need to expand this knowledge. > > Best Regards, > > Nick Koch > --------------------------------------------------------------------------- >--- SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, > Nevada. The future of the web can't happen without you. Join us at MIX09 > to help pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com >/ _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From rterry at ...1946... Sun Dec 7 21:42:57 2008 From: rterry at ...1946... (richard terry) Date: Mon, 8 Dec 2008 07:42:57 +1100 Subject: [Gambas-user] Toolpanel foreground font - can't change colour Message-ID: <200812080742.57254.rterry@...1946...> There seems no way to change the font colour of this control, the foreground property changes the body of the control itself, not the text on the little bars. Regards richard From leonardo at ...1237... Sun Dec 7 23:20:57 2008 From: leonardo at ...1237... (Leonardo Miliani) Date: Sun, 07 Dec 2008 23:20:57 +0100 Subject: [Gambas-user] Another graphical bug in Gambas 2.9 In-Reply-To: <200812072134.01933.gambas@...1...> References: <493BEBA7.4010504@...1237...> <200812072134.01933.gambas@...1...> Message-ID: <493C4C49.9020108@...1237...> Benoit Minisini ha scritto: > On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: >> Maybe I found another graphical bug in Gambas 2.9. >> >> I use Ubuntu 8.10 with Gnome 2.24 and if I use a Qt project I get the >> window decorations even if I chose not to see them (window border set to >> 'none'). > > This could confirm that there is something wrong in the Gnome 2.24 window > manager on Ubuntu 8.10... > I had the same idea... but Gnome 2.24 is very popular now, not only for Ubuntu 8.10 but for many other distros, so this problem should be investigated, isn't it? -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software Co-fondatore di Gambas-it.org Il sito di riferimento della comunit? italiana degli utenti di Gambas www.gambas-it.org From sourceforge-raindog2 at ...94... Sun Dec 7 23:19:13 2008 From: sourceforge-raindog2 at ...94... (Rob) Date: Sun, 7 Dec 2008 17:19:13 -0500 Subject: [Gambas-user] GAMBAS Suggestions In-Reply-To: <000e0cd296181a7269045d79e8e0@...2027...> References: <000e0cd296181a7269045d79e8e0@...2027...> Message-ID: <200812071719.13871.sourceforge-raindog2@...94...> On Sunday 07 December 2008 14:27, nkoch22 at ...626... wrote: > I find it curious that such a great piece of software doesn't have a > better updated website and a bug/tracking system. Gambas is a project with a benevolent dictator, namely Benoit, who does most of the work and prefers mailing lists for bug reporting. You can sign up for notification of the subversion commits to see which bugs get fixed, as well. I just looked at the project website (gambas.sf.net) and it correctly indicates that the current stable version is 2.9.0. It provides a download link to that and instructions for checking out the development snapshots. What do you see there that could be better updated? There are forums out there, but what the community lacks is people who actually care about web forums. I try to stay on top of linuxbasic.net which gets 5 or 10 posts per week, but when you get right down to it, mailing lists come to me whereas I have to go to a web forum. Gambasforum.tk gets a few posts a week as well. Some other guy was trying a couple months ago to start a catch-all BASIC forum site, sort of a linuxbasic.net knockoff only with lots of added Windows users, but none of us had time to visit yet another forum. The Gambasrad.org forums, once you set aside the mirrored content of this mailing list, are pretty quiet so I haven't been there in some time. I just went there now and see that it calls itself the "Gambas home page", but that doesn't seem to be the case. If you came across that and were led to believe it was the project website, I can understand why you'd complain about its outdatedness since the most recent announcement was 13 months ago today. > I think we as a community need to expand this knowledge. The Gambas wiki started when I took the original Openoffice document Benoit created to document Gambas 0.30 (or thereabouts) and converted it into a format a wiki could handle so that people could add documentation and a static version could be created for inclusion in the IDE. I did this without asking for permission and without being told to. Only when it turned out to be usable (and Benoit had made many suggestions and improvements) did it become "the Gambas wiki", eventually being replaced entirely with Benoit's custom wiki code that we run today. In other words, the only way things ever get done in free software is through someone who takes the initiative. Please don't feel you need to ask before doing something for the community, though it's also important not to get too discouraged if what you think the community needs turns out to be not as useful as you thought. Starting (and keeping well-organized and on-topic) an examples repository would be a great idea if you have that kind of time. And time is really the limiting factor. When I set up the original wiki in early 2003, I had some clients who needed a lot of Gambas work in preparation for a push to Linux desktop deployment, so it was easy to dedicate some of my time to the wiki, and to maintaining Gambas packages for Mandrake, and to writing gb.pcre and working on other components my clients needed. Now the push for Linux desktops has turned into a push for thin clients and web-based applications, at least where I am, so Gambas is back to being just a personal interest of mine that takes up some of my left over free time. If your situation affords you more time, I hope you'll step up. Rob From nkoch22 at ...626... Sun Dec 7 23:42:00 2008 From: nkoch22 at ...626... (Nicolas Koch) Date: Mon, 8 Dec 2008 01:42:00 +0300 Subject: [Gambas-user] GAMBAS Suggestions In-Reply-To: <200812071719.13871.sourceforge-raindog2@...94...> References: <000e0cd296181a7269045d79e8e0@...2027...> <200812071719.13871.sourceforge-raindog2@...94...> Message-ID: <73abb3e80812071442j72ef92fcq425b9755b54bc489@...627...> >In other words, the only way things ever get done in free software is >through someone who takes the initiative. Please don't feel you need to >ask before doing something for the community. I am quite aware of this and am in some other communities as a prominent figure precisely because of initiative. The only reason why I ask, is because I don't want to overstep someones toes if they are already working on something and two I don't want to create a new site just to accomplish what I feel this community needs. And as you pointed out, Benoit likes to get bugs from the list. If that is so then I can't blame him. Another reason why it's safer to ask first. I definitely wouldn't suggest adding a forum as I find a list way more useful. I know gambas.sf.net is current, but doesn't really offer anything other than this is the software, download and svn. I just wanted to update what was already out there since there are many sites already and make it a better starting point. I suggested gambasrad.org since it is the most outdated and has a good base. Plone is also a good CMS that is just as simple as wiki if not easier to add stuff to it. Anyways, I have time to dedicate to making it a better project and will be looking for examples eventually and code snippets. Regards, Nick From gambas at ...1... Mon Dec 8 01:07:38 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 8 Dec 2008 01:07:38 +0100 Subject: [Gambas-user] Toolpanel foreground font - can't change colour In-Reply-To: <200812080742.57254.rterry@...1946...> References: <200812080742.57254.rterry@...1946...> Message-ID: <200812080107.38153.gambas@...1...> On dimanche 7 d?cembre 2008, richard terry wrote: > There seems no way to change the font colour of this control, the > foreground property changes the body of the control itself, not the text on > the little bars. > > Regards > > richard > It depends on the GUI component: - With gb.gtk, this is aapparently a bug. - With gb.qt, some themes (for example QtCurve) erase color changes on buttons. -- Benoit Minisini From gambas at ...1... Mon Dec 8 01:21:46 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 8 Dec 2008 01:21:46 +0100 Subject: [Gambas-user] GAMBAS Suggestions In-Reply-To: <73abb3e80812071442j72ef92fcq425b9755b54bc489@...627...> References: <000e0cd296181a7269045d79e8e0@...2027...> <200812071719.13871.sourceforge-raindog2@...94...> <73abb3e80812071442j72ef92fcq425b9755b54bc489@...627...> Message-ID: <200812080121.46802.gambas@...1...> On dimanche 7 d?cembre 2008, Nicolas Koch wrote: > >In other words, the only way things ever get done in free software is > >through someone who takes the initiative. Please don't feel you need to > >ask before doing something for the community. > > I am quite aware of this and am in some other communities as a > prominent figure precisely because of initiative. The only reason why > I ask, is because I don't want to overstep someones toes if they are > already working on something and two I don't want to create a new site > just to accomplish what I feel this community needs. And as you > pointed out, Benoit likes to get bugs from the list. If that is so > then I can't blame him. Another reason why it's safer to ask first. > > I definitely wouldn't suggest adding a forum as I find a list way more > useful. I know gambas.sf.net is current, but doesn't really offer > anything other than this is the software, download and svn. > > I just wanted to update what was already out there since there are > many sites already and make it a better starting point. I suggested > gambasrad.org since it is the most outdated and has a good base. > Plone is also a good CMS that is just as simple as wiki if not easier > to add stuff to it. > > Anyways, I have time to dedicate to making it a better project and > will be looking for examples eventually and code snippets. > > Regards, > > Nick > The Plone CMS was a bit too complex for my taste. I admit a bug tracker is needed, but I'd like something like bugzilla, in a simpler way if possible. :-) At the moment, I just read the mailing-list and check the mails related to bugs that need to be fixed. -- Benoit Minisini From jj at ...1636... Mon Dec 8 01:21:49 2008 From: jj at ...1636... (jose julio vidal) Date: Mon, 08 Dec 2008 01:21:49 +0100 Subject: [Gambas-user] Ask about com access In-Reply-To: <493BE248.4010808@...981...> References: <322963.37774.qm@...2026...> <493BE248.4010808@...981...> Message-ID: <1228695709.6706.10.camel@...2028...> Hi all! I also wrote a program pos in gambas :) I open the cash drawer as follows: C (constants): Gambas module file --------------------------------- PUBLIC codeopencash AS String = "" .... codeopencash=Chr$(27) & Chr$(112) & Chr$(0) & Chr$(27) & Chr$(112) & Chr $(1) ..... F (functions): Gambas Module File --------------------------------- PUBLIC SUB abrir_caja() DIM hFile AS File hFile = OPEN "/dev/lp0" FOR WRITE IF ERROR THEN message.Error("No se puede acceder a la Caja") ELSE WRITE #hFile, Eval(c.codeopencash) END IF END .... Regards! El dom, 07-12-2008 a las 09:48 -0500, Stephen Bungay escribi?: > I wrote a complete POS in GAMBAS but the cash drawer was connected to > the parallell device.. however, I did dump text to an LED pole display, > to show the customer how much they owed and the change due etc. Should > be fairly similar, knowing the control codes to send to the cash drawer > might be the difficult part (might not be well documented). > > PUBLIC SUB OutputToPoleDisplay(pOutputString AS String) > DIM ShellString AS String > ClearPoleDisplay > ShellString = "echo -ne \"" & pOutputString & "\" > /dev/ttyS0" > SHELL ShellString WAIT > END > > PUBLIC SUB ClearPoleDisplay() > SHELL "echo -ne \"\n\n\n\" > /dev/ttyS0" WAIT > END > > Regards > Steve :) > > Leo Sendra wrote: > > Hi all, I want to ask.. How to access a com port in gambas? I want my program to access a cash drawer using gambas. > > > > Thanks... > > > > > > > > Menambah banyak teman sangatlah mudah dan cepat. Undang teman dari Hotmail, Gmail ke Yahoo! Messenger sekarang! http://id.messenger.yahoo.com/invite/ > > ------------------------------------------------------------------------------ > > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > > The future of the web can't happen without you. Join us at MIX09 to help > > pave the way to the Next Web now. Learn more and register at > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From nkoch22 at ...626... Mon Dec 8 10:25:49 2008 From: nkoch22 at ...626... (Nicolas Koch) Date: Mon, 8 Dec 2008 12:25:49 +0300 Subject: [Gambas-user] GAMBAS Suggestions In-Reply-To: <200812080121.46802.gambas@...1...> References: <000e0cd296181a7269045d79e8e0@...2027...> <200812071719.13871.sourceforge-raindog2@...94...> <73abb3e80812071442j72ef92fcq425b9755b54bc489@...627...> <200812080121.46802.gambas@...1...> Message-ID: <73abb3e80812080125p2c3cf3bu530f610677d844b0@...627...> > The Plone CMS was a bit too complex for my taste. I admit a bug tracker is > needed, but I'd like something like bugzilla, in a simpler way if > possible. :-) In that case I'd recommend Trac http://trac.edgewall.org It is a very good tracker like bugzilla, but incorporates a wiki and has several additional features. And not to totally through plone out the window, there are some mods for it to do the same kind of thing such as bug tracking and development. Regards, Nick From gambas at ...1938... Mon Dec 8 11:57:31 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Mon, 8 Dec 2008 11:57:31 +0100 Subject: [Gambas-user] configure...: components were disabled... Message-ID: <200812081157.31133.gambas@...1938...> Hi Attila! Have a look in the output of configure. There you can see, the complains about missing libraries and so on. Remember to install the development-version (dev-xxx) of these missing libraries too. Example: gb.db.odbc needs unixodbc, so you have to install this package AND unixodbc-dev. Hope it helps! Greetz Stevie Am Sonntag, 7. Dezember 2008 01:24:00 schrieb moon_walker: > Hi Gurus, > > i am just runned the ./configure for rev. 1722. > I realised that many components were disabled: > gb.qt > gb.gtk > gb.desktop > gb.db.odbc > ... > > could you tell me maybe the reason? > > thanks > Attila From almodook at ...2007... Mon Dec 8 12:04:43 2008 From: almodook at ...2007... (moon_walker) Date: Mon, 8 Dec 2008 03:04:43 -0800 (PST) Subject: [Gambas-user] configure...: components were disabled... In-Reply-To: <200812081157.31133.gambas@...1938...> References: <20876394.post@...1379...> <200812081157.31133.gambas@...1938...> Message-ID: <20893323.post@...1379...> Hi Stevie, thank you for the kind answer. I saw many xy.h was missed. But the list was so long on the screen... :-) Where is the whole log saved? br Attila gambas-3 wrote: > > Hi Attila! > > Have a look in the output of configure. There you can see, the complains > about > missing libraries and so on. Remember to install the development-version > (dev-xxx) of these missing libraries too. > Example: > gb.db.odbc needs unixodbc, so you have to install this package AND > unixodbc-dev. > > Hope it helps! > > Greetz > Stevie > > Am Sonntag, 7. Dezember 2008 01:24:00 schrieb moon_walker: >> Hi Gurus, >> >> i am just runned the ./configure for rev. 1722. >> I realised that many components were disabled: >> gb.qt >> gb.gtk >> gb.desktop >> gb.db.odbc >> ... >> >> could you tell me maybe the reason? >> >> thanks >> Attila > > > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, > Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > -- View this message in context: http://www.nabble.com/configure...%3A-components-were-disabled...-tp20876394p20893323.html Sent from the gambas-user mailing list archive at Nabble.com. From leo_senpao at ...1541... Mon Dec 8 14:29:42 2008 From: leo_senpao at ...1541... (Leo Sendra) Date: Mon, 8 Dec 2008 21:29:42 +0800 (SGT) Subject: [Gambas-user] Ask about com access Message-ID: <142088.83522.qm@...2025...> Hi Jose.. If you don't mind, would you like to send me a code in Gambas?? I really need a code to open cash drawer... I really appreciate for your help... Thanks... >Hi all! I also wrote a program pos in gambas :) >I open the cash drawer as follows: >C (constants): Gambas module file >--------------------------------- >PUBLIC codeopencash AS String = "" >.... >codeopencash=Chr$(27) & Chr$(112) & Chr$(0) & Chr$(27) & Chr$(112) & Chr >$(1) >..... >F (functions): Gambas Module File >--------------------------------- >PUBLIC SUB abrir_caja() >DIM hFile AS File >hFile = OPEN "/dev/lp0" FOR WRITE >IF ERROR THEN > message.Error("No se puede acceder a la Caja") >ELSE > WRITE #hFile, Eval(c.codeopencash) >END IF >END >Regards! Menambah banyak teman sangatlah mudah dan cepat. Undang teman dari Hotmail, Gmail ke Yahoo! Messenger sekarang! http://id.messenger.yahoo.com/invite/ From gambas at ...1938... Mon Dec 8 15:38:59 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Mon, 8 Dec 2008 15:38:59 +0100 Subject: [Gambas-user] How to return results and status from a function to the calling procedure?? Message-ID: <200812081538.59698.gambas@...1938...> Hi List, stupid question. What I wanted to do is - call a function and check if all went OK (True/False) - If True get the result and go on. - If False do some error managemen In principle it is an easy task, but: - Using global vars is (citation): "Poor programming practise" ;-) (no offense) - Using ByRef is slower then copy the content So, what's the best, cleanest or preferred way to do it in Gambas? Greetz Stevie From gambas at ...1... Mon Dec 8 15:42:26 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 8 Dec 2008 15:42:26 +0100 Subject: [Gambas-user] How to return results and status from a function to the calling procedure?? In-Reply-To: <200812081538.59698.gambas@...1938...> References: <200812081538.59698.gambas@...1938...> Message-ID: <200812081542.26965.gambas@...1...> On lundi 8 d?cembre 2008, gambas at ...1938... wrote: > Hi List, > > stupid question. > What I wanted to do is > - call a function and check if all went OK (True/False) > - If True get the result and go on. > - If False do some error managemen > > In principle it is an easy task, but: > - Using global vars is (citation): "Poor programming practise" ;-) (no > offense) > - Using ByRef is slower then copy the content > > So, what's the best, cleanest or preferred way to do it in Gambas? > > Greetz > Stevie > If "all was not ok" means that there was an error, then you should use Error.Raise() and error management. If "all was not ok" is actually normal, then your function should return a boolean that will tell you the result. If your function also return a value, then you can use one of the value to indicate a problem. For example, a function that returns a Date can return NULL for errors. If you can't use one of the value to indicate an error, then you must do something else! -- Benoit Minisini From jussi.lahtinen at ...626... Mon Dec 8 16:15:56 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Mon, 8 Dec 2008 17:15:56 +0200 Subject: [Gambas-user] Height and width units? Message-ID: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> Hi list! What is the unit of height and width? At least in PictureBox and DrawingArea, unit is not pixel, instead something little larger... Other thing, there seems to be limit in form size. I can't make form bigger than 1024 units, regarding both width and height. Something to do with my resolution 1280x1024? Bug? Gambas2.9 at ...2029... 8.10 64bit Jussi From gambas at ...1938... Mon Dec 8 16:23:17 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Mon, 8 Dec 2008 16:23:17 +0100 Subject: [Gambas-user] How to return results and status from a function to the calling procedure?? In-Reply-To: <200812081542.26965.gambas@...1...> References: <200812081538.59698.gambas@...1938...> <200812081542.26965.gambas@...1...> Message-ID: <200812081623.17637.gambas@...1938...> Hi Benoit! Message understood. :-) Many thanks! Greetz Stevie Am Montag, 8. Dezember 2008 15:42:26 schrieb Benoit Minisini: > On lundi 8 d?cembre 2008, gambas at ...1938... wrote: > > Hi List, > > > > stupid question. > > What I wanted to do is > > - call a function and check if all went OK (True/False) > > - If True get the result and go on. > > - If False do some error managemen > > > > In principle it is an easy task, but: > > - Using global vars is (citation): "Poor programming practise" ;-) (no > > offense) > > - Using ByRef is slower then copy the content > > > > So, what's the best, cleanest or preferred way to do it in Gambas? > > > > Greetz > > Stevie > > If "all was not ok" means that there was an error, then you should use > Error.Raise() and error management. > > If "all was not ok" is actually normal, then your function should return a > boolean that will tell you the result. > > If your function also return a value, then you can use one of the value to > indicate a problem. For example, a function that returns a Date can return > NULL for errors. > > If you can't use one of the value to indicate an error, then you must do > something else! From doriano.blengino at ...1909... Mon Dec 8 16:39:41 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Mon, 08 Dec 2008 16:39:41 +0100 Subject: [Gambas-user] How to return results and status from a function to the calling procedure?? In-Reply-To: <200812081542.26965.gambas@...1...> References: <200812081538.59698.gambas@...1938...> <200812081542.26965.gambas@...1...> Message-ID: <493D3FBD.5000103@...1909...> Benoit Minisini ha scritto: > On lundi 8 d?cembre 2008, gambas at ...1938... wrote: > >> Hi List, >> >> stupid question. >> What I wanted to do is >> - call a function and check if all went OK (True/False) >> - If True get the result and go on. >> - If False do some error managemen >> >> In principle it is an easy task, but: >> - Using global vars is (citation): "Poor programming practise" ;-) (no >> offense) >> - Using ByRef is slower then copy the content >> >> So, what's the best, cleanest or preferred way to do it in Gambas? >> >> Greetz >> Stevie >> >> > > If "all was not ok" means that there was an error, then you should use > Error.Raise() and error management. > > If "all was not ok" is actually normal, then your function should return a > boolean that will tell you the result. > > If your function also return a value, then you can use one of the value to > indicate a problem. For example, a function that returns a Date can return > NULL for errors. > > If you can't use one of the value to indicate an error, then you must do > something else! > "Poor programming practices" exist only when the programmer has no good reasons to do so... GOTOs, for example, are normally considered bad, but sometimes an awful goto is clearer, easier and faster than anything else. So, in your case, a function returning a boolean or an integer error code, and having a reference parameter (byval) for the actual result if any, could be the best. If you are really worried about speed, then a global variable (if faster), should not be regreted. I am not so deep inside Gambas, but normally raise and catch (try/except) are really slow (I think, more than a byval parameter). If it is relatively rare that a true error happens in your code, then a raise/catch should be the right way to go. At any extent, no methods are perfect. One can be slower but clearer, the other more robust, the other fast but obscure... but normally I would neglect speed and go for the clearest one. Cheers, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From eilert-sprachen at ...221... Mon Dec 8 16:46:00 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Mon, 08 Dec 2008 16:46:00 +0100 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <49389EDB.7010805@...2015...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> <49380569.6070509@...221...> <49389EDB.7010805@...2015...> Message-ID: <493D4138.7000600@...221...> Hi Toni again :-) Of course, I knew I'm not that stupid, I got it running, and it's great. Do you know if it's possible to control if it points upwards or downwards? What I found out is, when the control it points to is below .Height/2 of its parent, it will point upwards, otherwise downwards. And I cannot control left or right pointing, too. Everything else: great thing. In contrary to Benoit, I think it won't replace Message class, however, because it doesn't have buttons the user can click on, there is no interaction, so it's limited to displaying something. About the Tray Icon, I tried with a small window and a balloon pointing to its lower right edge. When you drag the window around the screen, the balloon won't disappear as long as you are dragging but it will change its pointing edge and form. So I dragged the window into the lower right edge of the screen, under Kicker and the Tray. The balloon will stop at the border of Kicker, it won't continue pointing on the window's edge, neither above nor under the tray. So I guess that Kicker and the tray have another level on the screen, above the windows. Maybe one could change this by some option in the window manager's control, something like "always there" or "always on top" such as in Windows. But your idea should work with either option, of course. Sorry I can't help any more, but thank you for pointing me to the balloon thing :-) Rolf Toni schrieb: > Hi Rolf again, > By ballon I meant "gb.form.ballon", a Message like class. > I couldn't get it pointing to a Tray Icon, but otherwise I find it > pretty nice and unobtrusive :) > Regards, > Toni > > > > En/na Rolf-Werner Eilert ha escrit: >> Hi Toni, >> >> Toni schrieb: >> >>> Hi Rolf, >>> I'm new to Gambas so maybe other will tell otherwise..., but I think >>> >> never mind :-) I've been into Gambas for quite some time now, but I'm >> still far away from being an expert... >> >> >>> "Ballon" is what you are looking for. >>> >> Didn't find that - is it one of the examples? >> >> In the examples, I did find the thing with the transparent clock and the >> other clock example. But those seem to have to do with transparency >> rather than with just a window without gadgets. >> >> Though I tried to do the same and failed - I don't know why my windows >> always have gadgets, even when I say "Border - None", and I cannot make >> out any other difference between my own programs and the examples >> (except the drawing routines). The examples run flawlessly here, my own >> programs always show standard windows. >> >> So, where's the trick? >> >> >> Regards, >> >> Rolf >> >> >>> The only problem is that I haven't been able to get it working pointing >>> to a TrayIcon (that low right edge of the screen you mention). Hope it >>> helps and, in anycase, if there is a better solution I'll be gald to >>> hear from it too. >>> >>> Regards, >>> Toni >>> >>> En/na Rolf-Werner Eilert ha escrit: >>> >>>> Hi everyone out there... >>>> >>>> The question is simple: Is it possible to make a small window without >>>> any gadgets appear and disappear after some seconds showing a small hint >>>> such as "you got new messages..."? >>>> >>>> What I want is something like these hints Thunderbird or the Suse update >>>> client produce at the lower right edge of the screen, for my own >>>> messenger app here in our firm. >>>> >>>> Thanks for all ideas. >>>> >>>> Regards, >>>> >>>> Rolf >>>> >>>> >> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge >> Build the coolest Linux based applications with Moblin SDK & win great prizes >> Grand prize is a trip for two to an Open Source event anywhere in the world >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Mon Dec 8 17:02:08 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 8 Dec 2008 17:02:08 +0100 Subject: [Gambas-user] How to return results and status from a function to the calling procedure?? In-Reply-To: <493D3FBD.5000103@...1909...> References: <200812081538.59698.gambas@...1938...> <200812081542.26965.gambas@...1...> <493D3FBD.5000103@...1909...> Message-ID: <200812081702.08136.gambas@...1...> On lundi 8 d?cembre 2008, Doriano Blengino wrote: > I am not so deep inside Gambas, but normally raise and catch > (try/except) are really slow (I think, more than a byval parameter). If > it is relatively rare that a true error happens in your code, then a > raise/catch should be the right way to go. > Of course, some benchmarking is needed... ByVal parameter are slower, because it adds a runtime test to check that the ByVal is allowed. Exceptions are slower. But I don't know if they are really slow: raising an exception means using the longjmp() C function, creating the error object, freeing the stack until a CATCH or FINALLY is found in a function, or displaying an error if none is found. What you have to do by hand when you don't use exceptions. But Creating the error object can be slow if you want the stack backtrace - This is the reason why there is an option for that in the Gambas 3 IDE. Maybe sometimes exceptions could be faster by ByVal. Regards, -- Benoit Minisini From gambas at ...1... Mon Dec 8 17:09:32 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 8 Dec 2008 17:09:32 +0100 Subject: [Gambas-user] Height and width units? In-Reply-To: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> Message-ID: <200812081709.33039.gambas@...1...> On lundi 8 d?cembre 2008, Jussi Lahtinen wrote: > Hi list! > > What is the unit of height and width? At least in PictureBox and > DrawingArea, unit is not pixel, instead something little larger... Hu ? Everything is in pixels in Gambas. Control dimensions in the IDE are just multiple of Desktop.Scale. > > Other thing, there seems to be limit in form size. > I can't make form bigger than 1024 units, regarding both width and height. > Something to do with my resolution 1280x1024? Bug? Oops. This is just a stupid limit hardcoded in the IDE. You can override it by code if you want. Regards, -- Benoit Minisini From gambas at ...1... Mon Dec 8 17:15:15 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 8 Dec 2008 17:15:15 +0100 Subject: [Gambas-user] Height and width units? In-Reply-To: <200812081709.33039.gambas@...1...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812081709.33039.gambas@...1...> Message-ID: <200812081715.15509.gambas@...1...> On lundi 8 d?cembre 2008, Benoit Minisini wrote: > On lundi 8 d?cembre 2008, Jussi Lahtinen wrote: > > Hi list! > > > > What is the unit of height and width? At least in PictureBox and > > DrawingArea, unit is not pixel, instead something little larger... > > Hu ? Everything is in pixels in Gambas. Control dimensions in the IDE are > just multiple of Desktop.Scale. > > > Other thing, there seems to be limit in form size. > > I can't make form bigger than 1024 units, regarding both width and > > height. Something to do with my resolution 1280x1024? Bug? > > Oops. This is just a stupid limit hardcoded in the IDE. You can override it > by code if you want. > > Regards, I raised the limit to 4096x4096 pixels in revision #1728. Regards, -- Benoit Minisini From joshiggins at ...1601... Mon Dec 8 18:01:33 2008 From: joshiggins at ...1601... (Joshua Higgins) Date: Mon, 8 Dec 2008 17:01:33 +0000 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <493D4138.7000600@...221...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> <49380569.6070509@...221...> <49389EDB.7010805@...2015...> <493D4138.7000600@...221...> Message-ID: <4247f5440812080901s2371737oa4726981fdb4fd8b@...627...> I know its not the gambas way, but if you have a notification-daemon and dbus running, install the package libnotify-bin. Then you can use the command notify-send to create popups on the screen near the system tray. They look like this: (ubuntu) http://tjeb.nl/Projects/Mailbox_Alert/mailboxalert_example.png (normal) http://wagiaalla.com/blog/wp-content/uploads/2008/03/notify-send.png hth 2008/12/8 Rolf-Werner Eilert > Hi Toni again :-) > > Of course, I knew I'm not that stupid, I got it running, and it's great. > > Do you know if it's possible to control if it points upwards or > downwards? What I found out is, when the control it points to is below > .Height/2 of its parent, it will point upwards, otherwise downwards. And > I cannot control left or right pointing, too. Everything else: great thing. > > In contrary to Benoit, I think it won't replace Message class, however, > because it doesn't have buttons the user can click on, there is no > interaction, so it's limited to displaying something. > > About the Tray Icon, I tried with a small window and a balloon pointing > to its lower right edge. When you drag the window around the screen, the > balloon won't disappear as long as you are dragging but it will change > its pointing edge and form. So I dragged the window into the lower right > edge of the screen, under Kicker and the Tray. The balloon will stop at > the border of Kicker, it won't continue pointing on the window's edge, > neither above nor under the tray. > > So I guess that Kicker and the tray have another level on the screen, > above the windows. Maybe one could change this by some option in the > window manager's control, something like "always there" or "always on > top" such as in Windows. But your idea should work with either option, > of course. > > Sorry I can't help any more, but thank you for pointing me to the > balloon thing :-) > > Rolf > > > > Toni schrieb: > > Hi Rolf again, > > By ballon I meant "gb.form.ballon", a Message like class. > > I couldn't get it pointing to a Tray Icon, but otherwise I find it > > pretty nice and unobtrusive :) > > Regards, > > Toni > > > > > > > > En/na Rolf-Werner Eilert ha escrit: > >> Hi Toni, > >> > >> Toni schrieb: > >> > >>> Hi Rolf, > >>> I'm new to Gambas so maybe other will tell otherwise..., but I think > >>> > >> never mind :-) I've been into Gambas for quite some time now, but I'm > >> still far away from being an expert... > >> > >> > >>> "Ballon" is what you are looking for. > >>> > >> Didn't find that - is it one of the examples? > >> > >> In the examples, I did find the thing with the transparent clock and the > >> other clock example. But those seem to have to do with transparency > >> rather than with just a window without gadgets. > >> > >> Though I tried to do the same and failed - I don't know why my windows > >> always have gadgets, even when I say "Border - None", and I cannot make > >> out any other difference between my own programs and the examples > >> (except the drawing routines). The examples run flawlessly here, my own > >> programs always show standard windows. > >> > >> So, where's the trick? > >> > >> > >> Regards, > >> > >> Rolf > >> > >> > >>> The only problem is that I haven't been able to get it working pointing > >>> to a TrayIcon (that low right edge of the screen you mention). Hope > it > >>> helps and, in anycase, if there is a better solution I'll be gald to > >>> hear from it too. > >>> > >>> Regards, > >>> Toni > >>> > >>> En/na Rolf-Werner Eilert ha escrit: > >>> > >>>> Hi everyone out there... > >>>> > >>>> The question is simple: Is it possible to make a small window without > >>>> any gadgets appear and disappear after some seconds showing a small > hint > >>>> such as "you got new messages..."? > >>>> > >>>> What I want is something like these hints Thunderbird or the Suse > update > >>>> client produce at the lower right edge of the screen, for my own > >>>> messenger app here in our firm. > >>>> > >>>> Thanks for all ideas. > >>>> > >>>> Regards, > >>>> > >>>> Rolf > >>>> > >>>> > >> > >> > ------------------------------------------------------------------------- > >> This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge > >> Build the coolest Linux based applications with Moblin SDK & win great > prizes > >> Grand prize is a trip for two to an Open Source event anywhere in the > world > >> http://moblin-contest.org/redirect.php?banner_id=100&url=/ > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > > > > ------------------------------------------------------------------------------ > > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, > Nevada. > > The future of the web can't happen without you. Join us at MIX09 to help > > pave the way to the Next Web now. Learn more and register at > > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- joshua higgins >>>>>>------ From eilert-sprachen at ...221... Mon Dec 8 18:20:40 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Mon, 08 Dec 2008 18:20:40 +0100 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <4247f5440812080901s2371737oa4726981fdb4fd8b@...627...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> <49380569.6070509@...221...> <49389EDB.7010805@...2015...> <493D4138.7000600@...221...> <4247f5440812080901s2371737oa4726981fdb4fd8b@...627...> Message-ID: <493D5768.7060202@...221...> Yes, Joshua, this would be exactly the way it was supposed to look like. Maybe I'll sort this out tomorrow, thanks for the tip! Rolf Joshua Higgins schrieb: > I know its not the gambas way, but if you have a notification-daemon and > dbus running, install the package libnotify-bin. Then you can use the > command notify-send to create popups on the screen near the system tray. > > They look like this: > > (ubuntu) http://tjeb.nl/Projects/Mailbox_Alert/mailboxalert_example.png > (normal) > http://wagiaalla.com/blog/wp-content/uploads/2008/03/notify-send.png > > hth > > 2008/12/8 Rolf-Werner Eilert > >> Hi Toni again :-) >> >> Of course, I knew I'm not that stupid, I got it running, and it's great. >> >> Do you know if it's possible to control if it points upwards or >> downwards? What I found out is, when the control it points to is below >> .Height/2 of its parent, it will point upwards, otherwise downwards. And >> I cannot control left or right pointing, too. Everything else: great thing. >> >> In contrary to Benoit, I think it won't replace Message class, however, >> because it doesn't have buttons the user can click on, there is no >> interaction, so it's limited to displaying something. >> >> About the Tray Icon, I tried with a small window and a balloon pointing >> to its lower right edge. When you drag the window around the screen, the >> balloon won't disappear as long as you are dragging but it will change >> its pointing edge and form. So I dragged the window into the lower right >> edge of the screen, under Kicker and the Tray. The balloon will stop at >> the border of Kicker, it won't continue pointing on the window's edge, >> neither above nor under the tray. >> >> So I guess that Kicker and the tray have another level on the screen, >> above the windows. Maybe one could change this by some option in the >> window manager's control, something like "always there" or "always on >> top" such as in Windows. But your idea should work with either option, >> of course. >> >> Sorry I can't help any more, but thank you for pointing me to the >> balloon thing :-) >> >> Rolf >> >> >> >> Toni schrieb: >>> Hi Rolf again, >>> By ballon I meant "gb.form.ballon", a Message like class. >>> I couldn't get it pointing to a Tray Icon, but otherwise I find it >>> pretty nice and unobtrusive :) >>> Regards, >>> Toni >>> >>> >>> >>> En/na Rolf-Werner Eilert ha escrit: >>>> Hi Toni, >>>> >>>> Toni schrieb: >>>> >>>>> Hi Rolf, >>>>> I'm new to Gambas so maybe other will tell otherwise..., but I think >>>>> >>>> never mind :-) I've been into Gambas for quite some time now, but I'm >>>> still far away from being an expert... >>>> >>>> >>>>> "Ballon" is what you are looking for. >>>>> >>>> Didn't find that - is it one of the examples? >>>> >>>> In the examples, I did find the thing with the transparent clock and the >>>> other clock example. But those seem to have to do with transparency >>>> rather than with just a window without gadgets. >>>> >>>> Though I tried to do the same and failed - I don't know why my windows >>>> always have gadgets, even when I say "Border - None", and I cannot make >>>> out any other difference between my own programs and the examples >>>> (except the drawing routines). The examples run flawlessly here, my own >>>> programs always show standard windows. >>>> >>>> So, where's the trick? >>>> >>>> >>>> Regards, >>>> >>>> Rolf >>>> >>>> >>>>> The only problem is that I haven't been able to get it working pointing >>>>> to a TrayIcon (that low right edge of the screen you mention). Hope >> it >>>>> helps and, in anycase, if there is a better solution I'll be gald to >>>>> hear from it too. >>>>> >>>>> Regards, >>>>> Toni >>>>> >>>>> En/na Rolf-Werner Eilert ha escrit: >>>>> >>>>>> Hi everyone out there... >>>>>> >>>>>> The question is simple: Is it possible to make a small window without >>>>>> any gadgets appear and disappear after some seconds showing a small >> hint >>>>>> such as "you got new messages..."? >>>>>> >>>>>> What I want is something like these hints Thunderbird or the Suse >> update >>>>>> client produce at the lower right edge of the screen, for my own >>>>>> messenger app here in our firm. >>>>>> >>>>>> Thanks for all ideas. >>>>>> >>>>>> Regards, >>>>>> >>>>>> Rolf >>>>>> >>>>>> >>>> >> ------------------------------------------------------------------------- >>>> This SF.Net email is sponsored by the Moblin Your Move Developer's >> challenge >>>> Build the coolest Linux based applications with Moblin SDK & win great >> prizes >>>> Grand prize is a trip for two to an Open Source event anywhere in the >> world >>>> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> >> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, >> Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > From malvarez at ...2030... Mon Dec 8 18:27:40 2008 From: malvarez at ...2030... (Mauricio Alvarez Sanabria) Date: Mon, 8 Dec 2008 11:27:40 -0600 Subject: [Gambas-user] please un suscribe me Message-ID: <008701c9595a$463c5ea0$d2b51be0$@ac.cr> please un suscribe me From jj at ...1636... Mon Dec 8 19:37:31 2008 From: jj at ...1636... (jose julio vidal) Date: Mon, 08 Dec 2008 19:37:31 +0100 Subject: [Gambas-user] Ask about com access In-Reply-To: <142088.83522.qm@...2025...> References: <142088.83522.qm@...2025...> Message-ID: <1228761451.4587.5.camel@...2028...> Hi! it's very easy, but, You should make sure that your device is the /dev/lp0, otherwise change the device in the code. ' Gambas class file PUBLIC SUB Button1_Click() DIM hFile AS File DIM codeopencash AS String codeopencash = "Chr$(27) & Chr$(112) & Chr$(0) & Chr$(27) & Chr$(112) & Chr$(1)" hFile = OPEN "/dev/lp0" FOR WRITE IF ERROR THEN message.Error("No se puede acceder a la Caja") ELSE WRITE #hFile, Eval(codeopencash) END IF END regards El lun, 08-12-2008 a las 21:29 +0800, Leo Sendra escribi?: > Hi Jose.. If you don't mind, would you like to send me a code in Gambas?? > I really need a code to open cash drawer... > > I really appreciate for your help... > > Thanks... > > >Hi all! I also wrote a program pos in gambas :) > >I open the cash drawer as follows: > > > >C (constants): Gambas module file > >--------------------------------- > >PUBLIC codeopencash AS String = "" > >.... > >codeopencash=Chr$(27) & Chr$(112) & Chr$(0) & Chr$(27) & Chr$(112) & Chr > >$(1) > >..... > > > > >F (functions): Gambas Module File > >--------------------------------- > > >PUBLIC SUB abrir_caja() > > >DIM hFile AS File > > >hFile = OPEN "/dev/lp0" FOR WRITE > >IF ERROR THEN > > message.Error("No se puede acceder a la Caja") > >ELSE > > WRITE #hFile, Eval(c.codeopencash) > >END IF > > >END > > > >Regards! > > > Menambah banyak teman sangatlah mudah dan cepat. Undang teman dari Hotmail, Gmail ke Yahoo! Messenger sekarang! http://id.messenger.yahoo.com/invite/ > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user -------------- next part -------------- A non-text attachment was scrubbed... Name: opencash.zip Type: application/zip Size: 9343 bytes Desc: not available URL: From jussi.lahtinen at ...626... Mon Dec 8 20:22:38 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Mon, 8 Dec 2008 21:22:38 +0200 Subject: [Gambas-user] Height and width units? In-Reply-To: <200812081715.15509.gambas@...1...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812081709.33039.gambas@...1...> <200812081715.15509.gambas@...1...> Message-ID: <384d3900812081122p2b40dd01p26b8fd0e06afbefc@...627...> >> > What is the unit of height and width? At least in PictureBox and >> > DrawingArea, unit is not pixel, instead something little larger... >> >> Hu ? Everything is in pixels in Gambas. Control dimensions in the IDE are >> just multiple of Desktop.Scale. Hmmm... I'm not sure if I understand correctly. But, make PictureBox / DrawingArea, set Height and Width to 100. Then put picture (size 100x100 pixel) / draw square (100x100) to PictureBox / DrawingArea. Result is bigger PictureBox / DrawingArea than than picture / square inside it. Other words, Height & Width 100 box, can hold lager picture than 100x100 pixels. I just noticed that this is true only in running state!! In stop state IDE shows forms OK... Jussi From arosa at ...2015... Mon Dec 8 20:49:28 2008 From: arosa at ...2015... (Toni) Date: Mon, 08 Dec 2008 19:49:28 +0000 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <493D5768.7060202@...221...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> <49380569.6070509@...221...> <49389EDB.7010805@...2015...> <493D4138.7000600@...221...> <4247f5440812080901s2371737oa4726981fdb4fd8b@...627...> <493D5768.7060202@...221...> Message-ID: <493D7A48.1090506@...2015...> Hi, Thanks for the information Rolf. Regarding whether it's possible to control "balloon" pointing upwoards or downwards, sorry but I don't know either... Besides, I will give a try to Joshua's approach, too! Regards, Toni En/na Rolf-Werner Eilert ha escrit: > Yes, Joshua, this would be exactly the way it was supposed to look like. > > Maybe I'll sort this out tomorrow, thanks for the tip! > > Rolf > > > Joshua Higgins schrieb: > >> I know its not the gambas way, but if you have a notification-daemon and >> dbus running, install the package libnotify-bin. Then you can use the >> command notify-send to create popups on the screen near the system tray. >> >> They look like this: >> >> (ubuntu) http://tjeb.nl/Projects/Mailbox_Alert/mailboxalert_example.png >> (normal) >> http://wagiaalla.com/blog/wp-content/uploads/2008/03/notify-send.png >> >> hth >> >> 2008/12/8 Rolf-Werner Eilert >> >> >>> Hi Toni again :-) >>> >>> Of course, I knew I'm not that stupid, I got it running, and it's great. >>> >>> Do you know if it's possible to control if it points upwards or >>> downwards? What I found out is, when the control it points to is below >>> .Height/2 of its parent, it will point upwards, otherwise downwards. And >>> I cannot control left or right pointing, too. Everything else: great thing. >>> >>> In contrary to Benoit, I think it won't replace Message class, however, >>> because it doesn't have buttons the user can click on, there is no >>> interaction, so it's limited to displaying something. >>> >>> About the Tray Icon, I tried with a small window and a balloon pointing >>> to its lower right edge. When you drag the window around the screen, the >>> balloon won't disappear as long as you are dragging but it will change >>> its pointing edge and form. So I dragged the window into the lower right >>> edge of the screen, under Kicker and the Tray. The balloon will stop at >>> the border of Kicker, it won't continue pointing on the window's edge, >>> neither above nor under the tray. >>> >>> So I guess that Kicker and the tray have another level on the screen, >>> above the windows. Maybe one could change this by some option in the >>> window manager's control, something like "always there" or "always on >>> top" such as in Windows. But your idea should work with either option, >>> of course. >>> >>> Sorry I can't help any more, but thank you for pointing me to the >>> balloon thing :-) >>> >>> Rolf >>> >>> >>> >>> Toni schrieb: >>> >>>> Hi Rolf again, >>>> By ballon I meant "gb.form.ballon", a Message like class. >>>> I couldn't get it pointing to a Tray Icon, but otherwise I find it >>>> pretty nice and unobtrusive :) >>>> Regards, >>>> Toni >>>> >>>> >>>> >>>> En/na Rolf-Werner Eilert ha escrit: >>>> >>>>> Hi Toni, >>>>> >>>>> Toni schrieb: >>>>> >>>>> >>>>>> Hi Rolf, >>>>>> I'm new to Gambas so maybe other will tell otherwise..., but I think >>>>>> >>>>>> >>>>> never mind :-) I've been into Gambas for quite some time now, but I'm >>>>> still far away from being an expert... >>>>> >>>>> >>>>> >>>>>> "Ballon" is what you are looking for. >>>>>> >>>>>> >>>>> Didn't find that - is it one of the examples? >>>>> >>>>> In the examples, I did find the thing with the transparent clock and the >>>>> other clock example. But those seem to have to do with transparency >>>>> rather than with just a window without gadgets. >>>>> >>>>> Though I tried to do the same and failed - I don't know why my windows >>>>> always have gadgets, even when I say "Border - None", and I cannot make >>>>> out any other difference between my own programs and the examples >>>>> (except the drawing routines). The examples run flawlessly here, my own >>>>> programs always show standard windows. >>>>> >>>>> So, where's the trick? >>>>> >>>>> >>>>> Regards, >>>>> >>>>> Rolf >>>>> >>>>> >>>>> >>>>>> The only problem is that I haven't been able to get it working pointing >>>>>> to a TrayIcon (that low right edge of the screen you mention). Hope >>>>>> >>> it >>> >>>>>> helps and, in anycase, if there is a better solution I'll be gald to >>>>>> hear from it too. >>>>>> >>>>>> Regards, >>>>>> Toni >>>>>> >>>>>> En/na Rolf-Werner Eilert ha escrit: >>>>>> >>>>>> >>>>>>> Hi everyone out there... >>>>>>> >>>>>>> The question is simple: Is it possible to make a small window without >>>>>>> any gadgets appear and disappear after some seconds showing a small >>>>>>> >>> hint >>> >>>>>>> such as "you got new messages..."? >>>>>>> >>>>>>> What I want is something like these hints Thunderbird or the Suse >>>>>>> >>> update >>> >>>>>>> client produce at the lower right edge of the screen, for my own >>>>>>> messenger app here in our firm. >>>>>>> >>>>>>> Thanks for all ideas. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Rolf >>>>>>> >>>>>>> >>>>>>> >>> ------------------------------------------------------------------------- >>> >>>>> This SF.Net email is sponsored by the Moblin Your Move Developer's >>>>> >>> challenge >>> >>>>> Build the coolest Linux based applications with Moblin SDK & win great >>>>> >>> prizes >>> >>>>> Grand prize is a trip for two to an Open Source event anywhere in the >>>>> >>> world >>> >>>>> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >>>>> _______________________________________________ >>>>> Gambas-user mailing list >>>>> Gambas-user at lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>> >>>>> >>> ------------------------------------------------------------------------------ >>> >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, >>>> >>> Nevada. >>> >>>> The future of the web can't happen without you. Join us at MIX09 to help >>>> pave the way to the Next Web now. Learn more and register at >>>> >>>> >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>>> >>> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>> >> >> > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Mon Dec 8 21:02:01 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 8 Dec 2008 21:02:01 +0100 Subject: [Gambas-user] Height and width units? In-Reply-To: <384d3900812081122p2b40dd01p26b8fd0e06afbefc@...627...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812081715.15509.gambas@...1...> <384d3900812081122p2b40dd01p26b8fd0e06afbefc@...627...> Message-ID: <200812082102.01232.gambas@...1...> On lundi 8 d?cembre 2008, Jussi Lahtinen wrote: > >> > What is the unit of height and width? At least in PictureBox and > >> > DrawingArea, unit is not pixel, instead something little larger... > >> > >> Hu ? Everything is in pixels in Gambas. Control dimensions in the IDE > >> are just multiple of Desktop.Scale. > > Hmmm... I'm not sure if I understand correctly. > But, make PictureBox / DrawingArea, set Height and Width to 100. > Then put picture (size 100x100 pixel) / draw square (100x100) to > PictureBox / DrawingArea. > Result is bigger PictureBox / DrawingArea than than picture / square > inside it. Other words, Height & Width 100 box, can hold lager picture than > 100x100 pixels. > > I just noticed that this is true only in running state!! > In stop state IDE shows forms OK... > > > Jussi > Which GUI component do you use? -- Benoit Minisini From leo_senpao at ...1541... Mon Dec 8 21:23:58 2008 From: leo_senpao at ...1541... (Leo Sendra) Date: Tue, 9 Dec 2008 04:23:58 +0800 (SGT) Subject: [Gambas-user] Ask about com access References: Message-ID: <320850.81128.qm@...1991...> Hi Jose.. thanks for the sharing... but, I have a question... What is the meaning of code below? codeopencash = "Chr$(27) & Chr$(112) & Chr$(0) & Chr$(27) & Chr$(112) & Chr$(1)" I will try this code ASAP.... Apakah demonstrasi & turun ke jalan itu hal yang wajar? Temukan jawabannya di Yahoo! Answers! http://id.answers.yahoo.com From gambas at ...1... Tue Dec 9 01:21:53 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 01:21:53 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <200812072003.26596.gambas@...1...> References: <493B093E.8050509@...1237...> <200812072003.26596.gambas@...1...> Message-ID: <200812090121.53451.gambas@...1...> On dimanche 7 d?cembre 2008, Benoit Minisini wrote: > On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: > > I found a bug into Gambas 2.9 running on Gnome 2.24: the masks of the > > windows are not applied, resulting in forms that visualize the window > > borders. > > > > Try the Clock example and you'll understand what I mean. > > > > The problem doesn't appear on KDE 4.x and Gnome <=2.22. > > I don't have this problem when running the Clock example with gb.gtk, on > Mandriva 2009 with KDE 3.5.10. > > I think the problem comes from the Gnome 2.24 window manager. I tried the Clock example with Gnome 2.24 on Mandriva 2009, and there is no problem at all. Regards, -- Benoit Minisini From gambas at ...1... Tue Dec 9 01:23:22 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 01:23:22 +0100 Subject: [Gambas-user] Another graphical bug in Gambas 2.9 In-Reply-To: <493C4C49.9020108@...1237...> References: <493BEBA7.4010504@...1237...> <200812072134.01933.gambas@...1...> <493C4C49.9020108@...1237...> Message-ID: <200812090123.22712.gambas@...1...> On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: > Benoit Minisini ha scritto: > > On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: > >> Maybe I found another graphical bug in Gambas 2.9. > >> > >> I use Ubuntu 8.10 with Gnome 2.24 and if I use a Qt project I get the > >> window decorations even if I chose not to see them (window border set to > >> 'none'). > > > > This could confirm that there is something wrong in the Gnome 2.24 window > > manager on Ubuntu 8.10... > > I had the same idea... but Gnome 2.24 is very popular now, not only for > Ubuntu 8.10 but for many other distros, so this problem should be > investigated, isn't it? I tried a Qt project with a window having its Border property set to none on Mandriva 2009 with Gnome 2.24, and everything is correct. So maybe there is (yet) a problem on Ubuntu 8.10? Are you sure that the compilation of Gambas was correct? Regards, -- Benoit Minisini From gambas at ...1... Tue Dec 9 01:24:12 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 01:24:12 +0100 Subject: [Gambas-user] configure...: components were disabled... In-Reply-To: <20876394.post@...1379...> References: <20876394.post@...1379...> Message-ID: <200812090124.12908.gambas@...1...> On dimanche 7 d?cembre 2008, moon_walker wrote: > Hi Gurus, > > i am just runned the ./configure for rev. 1722. > I realised that many components were disabled: > gb.qt > gb.gtk > gb.desktop > gb.db.odbc > ... > > could you tell me maybe the reason? > > thanks > Attila You didn't install the needed development packages? -- Benoit Minisini From gael.lehech at ...626... Tue Dec 9 01:39:29 2008 From: gael.lehech at ...626... (=?ISO-8859-1?Q?Ga=EBl_Le_Hec'H?=) Date: Tue, 9 Dec 2008 01:39:29 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <200812090121.53451.gambas@...1...> References: <493B093E.8050509@...1237...> <200812072003.26596.gambas@...1...> <200812090121.53451.gambas@...1...> Message-ID: I confirm the problem on fedora 10 with gnome 2.24.2 and gambas2 2.9.0 with the clock example Ga?l Le Hec'H 2008/12/9 Benoit Minisini > On dimanche 7 d?cembre 2008, Benoit Minisini wrote: > > On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: > > > I found a bug into Gambas 2.9 running on Gnome 2.24: the masks of the > > > windows are not applied, resulting in forms that visualize the window > > > borders. > > > > > > Try the Clock example and you'll understand what I mean. > > > > > > The problem doesn't appear on KDE 4.x and Gnome <=2.22. > > > > I don't have this problem when running the Clock example with gb.gtk, on > > Mandriva 2009 with KDE 3.5.10. > > > > I think the problem comes from the Gnome 2.24 window manager. > > I tried the Clock example with Gnome 2.24 on Mandriva 2009, and there is no > problem at all. > > Regards, > > -- > Benoit Minisini > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Tue Dec 9 01:42:29 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 01:42:29 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: References: <493B093E.8050509@...1237...> <200812090121.53451.gambas@...1...> Message-ID: <200812090142.29337.gambas@...1...> On mardi 9 d?cembre 2008, Ga?l Le Hec'H wrote: > I confirm the problem on fedora 10 with gnome 2.24.2 and gambas2 2.9.0 with > the clock example > > Ga?l Le Hec'H > Just an idea: do you use Compiz? -- Benoit Minisini From emil at ...1913... Tue Dec 9 08:43:55 2008 From: emil at ...1913... (Tchekov.Net) Date: Tue, 9 Dec 2008 08:43:55 +0100 Subject: [Gambas-user] Problems with libtool In-Reply-To: <200810091257.53543.gambas@...1...> Message-ID: Dear all, need help on compiling Gambas. Have tried to install Gambas 2.9 on Xubuntu in Virtual Machine. Evrth. went good, but I have overseen the version warning for the libtool (I was really dumb ...), so the compiling was not successfull (libtool 2.2.24 was installed on my Xubuntu). So using Synaptic I have "completely" removed the libtool 2.2.24; Then downloaded the required version 1.5.12 (configure, make, make install went successfull). BUT the Gambas compilation is still not successfull - after reconf and configure, make still breaks with libtool version warning (2.2.24). I think there is some kind of string, which is not set to the proper value, since I have now the proper version on libtool, but may be not properly "registered". Any suggestion? Or should I reinstall Xubuntu :-( Thank you very much in advance kind regards Emil From leonardo at ...1237... Tue Dec 9 10:31:40 2008 From: leonardo at ...1237... (Leonardo Miliani) Date: Tue, 09 Dec 2008 10:31:40 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <200812090142.29337.gambas@...1...> References: <493B093E.8050509@...1237...> <200812090121.53451.gambas@...1...> <200812090142.29337.gambas@...1...> Message-ID: <493E3AFC.10602@...1237...> Benoit Minisini ha scritto: > On mardi 9 d?cembre 2008, Ga?l Le Hec'H wrote: >> I confirm the problem on fedora 10 with gnome 2.24.2 and gambas2 2.9.0 with >> the clock example >> >> Ga?l Le Hec'H >> > > Just an idea: do you use Compiz? > No, I don't. I attach a screenshot to let you see the problem. -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software Co-fondatore di Gambas-it.org Il sito di riferimento della comunit? italiana degli utenti di Gambas www.gambas-it.org -------------- next part -------------- A non-text attachment was scrubbed... Name: clock.jpg Type: image/jpeg Size: 17876 bytes Desc: not available URL: From jaap_cramer at ...67... Tue Dec 9 10:39:43 2008 From: jaap_cramer at ...67... (Jaap Cramer) Date: Tue, 9 Dec 2008 10:39:43 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <493E3AFC.10602@...1237...> References: <493B093E.8050509@...1237...> <200812090121.53451.gambas@...1...> <200812090142.29337.gambas@...1...> <493E3AFC.10602@...1237...> Message-ID: I've maybe a similar problem, with my balloons. They have a border (like the image of the clock) I do use gnome 2.24.2 with compiz Jaap > Date: Tue, 9 Dec 2008 10:31:40 +0100 > From: leonardo at ...1237... > To: gambas-user at lists.sourceforge.net > Subject: Re: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 > > Benoit Minisini ha scritto: > > On mardi 9 d?cembre 2008, Ga?l Le Hec'H wrote: > >> I confirm the problem on fedora 10 with gnome 2.24.2 and gambas2 2.9.0 with > >> the clock example > >> > >> Ga?l Le Hec'H > >> > > > > Just an idea: do you use Compiz? > > > > No, I don't. > I attach a screenshot to let you see the problem. > > -- > Ciao. > Leo. > > Web: www.leonardomiliani.com > E-mail: leonardo at ...1237... > Scegli software opensource - Choose opensource software > > Co-fondatore di Gambas-it.org > Il sito di riferimento della comunit? italiana degli utenti di Gambas > www.gambas-it.org _________________________________________________________________ Jouw nieuws en entertainment, vind je op MSN.nl! http://nl.msn.com/ From leonardo at ...1237... Tue Dec 9 10:40:33 2008 From: leonardo at ...1237... (Leonardo Miliani) Date: Tue, 09 Dec 2008 10:40:33 +0100 Subject: [Gambas-user] Another graphical bug in Gambas 2.9 In-Reply-To: <200812090123.22712.gambas@...1...> References: <493BEBA7.4010504@...1237...> <200812072134.01933.gambas@...1...> <493C4C49.9020108@...1237...> <200812090123.22712.gambas@...1...> Message-ID: <493E3D11.1040400@...1237...> Benoit Minisini ha scritto: > On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: >> Benoit Minisini ha scritto: >>> On dimanche 7 d?cembre 2008, Leonardo Miliani wrote: >>>> Maybe I found another graphical bug in Gambas 2.9. >>>> >>>> I use Ubuntu 8.10 with Gnome 2.24 and if I use a Qt project I get the >>>> window decorations even if I chose not to see them (window border set to >>>> 'none'). >>> This could confirm that there is something wrong in the Gnome 2.24 window >>> manager on Ubuntu 8.10... >> I had the same idea... but Gnome 2.24 is very popular now, not only for >> Ubuntu 8.10 but for many other distros, so this problem should be >> investigated, isn't it? > > I tried a Qt project with a window having its Border property set to none on > Mandriva 2009 with Gnome 2.24, and everything is correct. > > So maybe there is (yet) a problem on Ubuntu 8.10? Are you sure that the > compilation of Gambas was correct? > > Regards, > Gambas was compiled correctly. I tried several projects. All projects of mine using gb.qt component don't work correctly on Ubuntu 8.10/Gnome 2.24 presenting the window borders even I set the border property to none. -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software Co-fondatore di Gambas-it.org Il sito di riferimento della comunit? italiana degli utenti di Gambas www.gambas-it.org From gambas at ...1... Tue Dec 9 12:21:22 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 12:21:22 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: References: <493B093E.8050509@...1237...> <493E3AFC.10602@...1237...> Message-ID: <200812091221.22487.gambas@...1...> On mardi 9 d?cembre 2008, Jaap Cramer wrote: > I've maybe a similar problem, with my balloons. They have a border (like > the image of the clock) I do use gnome 2.24.2 with compiz > > Jaap > I just noticed that on Mandriva the Gnome version is 2.24.0. Maybe there is a bug^W new feature in the 2.24.2 version? -- Benoit Minisini From gambas at ...1... Tue Dec 9 12:54:24 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 12:54:24 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <493E3AFC.10602@...1237...> References: <493B093E.8050509@...1237...> <200812090142.29337.gambas@...1...> <493E3AFC.10602@...1237...> Message-ID: <200812091254.24313.gambas@...1...> On mardi 9 d?cembre 2008, Leonardo Miliani wrote: > Benoit Minisini ha scritto: > > On mardi 9 d?cembre 2008, Ga?l Le Hec'H wrote: > >> I confirm the problem on fedora 10 with gnome 2.24.2 and gambas2 2.9.0 > >> with the clock example > >> > >> Ga?l Le Hec'H > > > > Just an idea: do you use Compiz? > > No, I don't. > I attach a screenshot to let you see the problem. The mask is actually applied. Just that the window manager shows the windows borders, whereas it was requested not to do that. -- Benoit Minisini From gambas at ...1... Tue Dec 9 12:52:57 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 12:52:57 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <200812091221.22487.gambas@...1...> References: <493B093E.8050509@...1237...> <200812091221.22487.gambas@...1...> Message-ID: <200812091252.58028.gambas@...1...> On mardi 9 d?cembre 2008, Benoit Minisini wrote: > On mardi 9 d?cembre 2008, Jaap Cramer wrote: > > I've maybe a similar problem, with my balloons. They have a border (like > > the image of the clock) I do use gnome 2.24.2 with compiz > > > > Jaap > > I just noticed that on Mandriva the Gnome version is 2.24.0. Maybe there is > a bug^W new feature in the 2.24.2 version? Apparently there is no change in metacity between 2.24.0 and 2.24.2... -- Benoit Minisini From jussi.lahtinen at ...626... Tue Dec 9 13:34:16 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Tue, 9 Dec 2008 14:34:16 +0200 Subject: [Gambas-user] Height and width units? In-Reply-To: <200812082102.01232.gambas@...1...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812081715.15509.gambas@...1...> <384d3900812081122p2b40dd01p26b8fd0e06afbefc@...627...> <200812082102.01232.gambas@...1...> Message-ID: <384d3900812090434s70a55152h40208f035a7c33b3@...627...> > Which GUI component do you use? GTK, I tried to switch it to QT, and problem gone! Is switching GUI component legit thing to do, or can I mess up my code with it? This time everything ok, but with real project... maybe I'm just having M$ nightmare induced paranoia... Anyhow the problem is GTK component, and I noticed an other problem too. GTK is about 40 times slower when talking about Draw.Picture() !! Jussi From gambas at ...1... Tue Dec 9 13:46:44 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 13:46:44 +0100 Subject: [Gambas-user] Height and width units? In-Reply-To: <384d3900812090434s70a55152h40208f035a7c33b3@...627...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812082102.01232.gambas@...1...> <384d3900812090434s70a55152h40208f035a7c33b3@...627...> Message-ID: <200812091346.44102.gambas@...1...> On mardi 9 d?cembre 2008, Jussi Lahtinen wrote: > > Which GUI component do you use? > > GTK, I tried to switch it to QT, and problem gone! > Is switching GUI component legit thing to do, or can I mess up my code > with it? This time everything ok, but with real project... maybe I'm just > having M$ nightmare > induced paranoia... This is just a bug in gb.gtk. > > Anyhow the problem is GTK component, and I noticed an other problem too. > GTK is about 40 times slower when talking about Draw.Picture() !! Mmm. GTK+ is slower than QT, but not 40 times. Can you show your code? -- Benoit Minisini From jussi.lahtinen at ...626... Tue Dec 9 14:33:37 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Tue, 9 Dec 2008 15:33:37 +0200 Subject: [Gambas-user] Height and width units? In-Reply-To: <200812091346.44102.gambas@...1...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812082102.01232.gambas@...1...> <384d3900812090434s70a55152h40208f035a7c33b3@...627...> <200812091346.44102.gambas@...1...> Message-ID: <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> >> Anyhow the problem is GTK component, and I noticed an other problem too. >> GTK is about 40 times slower when talking about Draw.Picture() !! > > Mmm. GTK+ is slower than QT, but not 40 times. Can you show your code? No problem, it's just stupid performance test / tile engine prototype. See attached file (NayttoProto2-0.0.1.tar.gz). -------------- next part -------------- A non-text attachment was scrubbed... Name: NayttoProto2-0.0.1.tar.gz Type: application/x-gzip Size: 8834 bytes Desc: not available URL: From jussi.lahtinen at ...626... Tue Dec 9 14:45:01 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Tue, 9 Dec 2008 15:45:01 +0200 Subject: [Gambas-user] Height and width units? In-Reply-To: <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812082102.01232.gambas@...1...> <384d3900812090434s70a55152h40208f035a7c33b3@...627...> <200812091346.44102.gambas@...1...> <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> Message-ID: <384d3900812090545t75e1e4aidc1c1f5a80fac78b@...627...> One more thing about that code.... Press Exit button (gives just the Quit command), and IDE gives messages: WARNING: circular references detected FMain (1) Mutex destroy failure: Device or resource busy WARNING: 15 allocation(s) non freed. Am I doing something wrong with that? Do I need to free objects somehow before Quit? Or..? Jussi On Tue, Dec 9, 2008 at 3:33 PM, Jussi Lahtinen wrote: >>> Anyhow the problem is GTK component, and I noticed an other problem too. >>> GTK is about 40 times slower when talking about Draw.Picture() !! >> >> Mmm. GTK+ is slower than QT, but not 40 times. Can you show your code? > > No problem, it's just stupid performance test / tile engine prototype. > See attached file (NayttoProto2-0.0.1.tar.gz). > From gambas at ...1... Tue Dec 9 14:49:01 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 9 Dec 2008 14:49:01 +0100 Subject: [Gambas-user] Height and width units? In-Reply-To: <384d3900812090545t75e1e4aidc1c1f5a80fac78b@...627...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> <384d3900812090545t75e1e4aidc1c1f5a80fac78b@...627...> Message-ID: <200812091449.01745.gambas@...1...> On mardi 9 d?cembre 2008, Jussi Lahtinen wrote: > One more thing about that code.... > Press Exit button (gives just the Quit command), and IDE gives messages: > > WARNING: circular references detected > FMain (1) > Mutex destroy failure: Device or resource busy > WARNING: 15 allocation(s) non freed. > > Am I doing something wrong with that? Do I need to free objects > somehow before Quit? > Or..? > > > Jussi > QUIT actually aborts the program. If you want to cleanly quit your program, just close your windows. Regards, -- Benoit Minisini From jussi.lahtinen at ...626... Tue Dec 9 15:21:46 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Tue, 9 Dec 2008 16:21:46 +0200 Subject: [Gambas-user] Height and width units? In-Reply-To: <200812091449.01745.gambas@...1...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> <384d3900812090545t75e1e4aidc1c1f5a80fac78b@...627...> <200812091449.01745.gambas@...1...> Message-ID: <384d3900812090621t3196c2b1hf6b22a5e3a4c6f48@...627...> > QUIT actually aborts the program. If you want to cleanly quit your program, > just close your windows. Ok that makes sense, thanks! So there is not any command to close all windows? Or some generic way to do it, something like FOR EACH Form.... ...Me.Close...? My main project will have about 21 - 30 forms total. And of course, not all of them are open at same time. Jussi From jj at ...1636... Tue Dec 9 16:02:26 2008 From: jj at ...1636... (jose julio vidal) Date: Tue, 09 Dec 2008 16:02:26 +0100 Subject: [Gambas-user] Ask about com access In-Reply-To: <320850.81128.qm@...1991...> References: <320850.81128.qm@...1991...> Message-ID: <1228834946.4668.1.camel@...2028...> More info (control codes to open your cash drawer) http://pages.prodigy.net/daleharris/popopen.htm http://pages.prodigy.net/daleharris/popopen2.htm El mar, 09-12-2008 a las 04:23 +0800, Leo Sendra escribi?: > Hi Jose.. thanks for the sharing... but, I have a question... What is the meaning of code below? > > codeopencash = "Chr$(27) & Chr$(112) & Chr$(0) & Chr$(27) & Chr$(112) & Chr$(1)" > > I will try this code ASAP.... > > > > Apakah demonstrasi & turun ke jalan itu hal yang wajar? Temukan jawabannya di Yahoo! Answers! http://id.answers.yahoo.com > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From ron at ...1740... Tue Dec 9 16:16:36 2008 From: ron at ...1740... (Ron) Date: Tue, 09 Dec 2008 16:16:36 +0100 Subject: [Gambas-user] Table "too many arguments" Message-ID: <493E8BD4.1070508@...1740...> Hi, I need to define this crc hash table in my gambas project. But I get "too many arguments", what alternatives do I have? Thanks. Regards, Ron_2nd PUBLIC table AS Integer[] = [&H0000, &H1021, &H2042, &H3063, &H4084, &H50A5, &H60C6, &H70E7, &H8108, &H9129, &HA14A, &HB16B, &HC18C, &HD1AD, &HE1CE, &HF1EF, &H1231, &H0210, &H3273, &H2252, &H52B5, &H4294, &H72F7, &H62D6, &H9339, &H8318, &HB37B, &HA35A, &HD3BD, &HC39C, &HF3FF, &HE3DE, &H2462, &H3443, &H0420, &H1401, &H64E6, &H74C7, &H44A4, &H5485, &HA56A, &HB54B, &H8528, &H9509, &HE5EE, &HF5CF, &HC5AC, &HD58D, &H3653, &H2672, &H1611, &H0630, &H76D7, &H66F6, &H5695, &H46B4, &HB75B, &HA77A, &H9719, &H8738, &HF7DF, &HE7FE, &HD79D, &HC7BC, &H48C4, &H58E5, &H6886, &H78A7, &H0840, &H1861, &H2802, &H3823, &HC9CC, &HD9ED, &HE98E, &HF9AF, &H8948, &H9969, &HA90A, &HB92B, &H5AF5, &H4AD4, &H7AB7, &H6A96, &H1A71, &H0A50, &H3A33, &H2A12, &HDBFD, &HCBDC, &HFBBF, &HEB9E, &H9B79, &H8B58, &HBB3B, &HAB1A, &H6CA6, &H7C87, &H4CE4, &H5CC5, &H2C22, &H3C03, &H0C60, &H1C41, &HEDAE, &HFD8F, &HCDEC, &HDDCD, &HAD2A, &HBD0B, &H8D68, &H9D49, &H7E97, &H6EB6, &H5ED5, &H4EF4, &H3E13, &H2E32, &H1E51, &H0E70, &HFF9F, &HEFBE, &HDFDD, &HCFFC, &HBF1B, &HAF3A, &H9F59, &H8F78, &H9188, &H81A9, &HB1CA, &HA1EB, &HD10C, &HC12D, &HF14E, &HE16F, &H1080, &H00A1, &H30C2, &H20E3, &H5004, &H4025, &H7046, &H6067, &H83B9, &H9398, &HA3FB, &HB3DA, &HC33D, &HD31C, &HE37F, &HF35E, &H02B1, &H1290, &H22F3, &H32D2, &H4235, &H5214, &H6277, &H7256, &HB5EA, &HA5CB, &H95A8, &H8589, &HF56E, &HE54F, &HD52C, &HC50D, &H34E2, &H24C3, &H14A0, &H0481, &H7466, &H6447, &H5424, &H4405, &HA7DB, &HB7FA, &H8799, &H97B8, &HE75F, &HF77E, &HC71D, &HD73C, &H26D3, &H36F2, &H0691, &H16B0, &H6657, &H7676, &H4615, &H5634, &HD94C, &HC96D, &HF90E, &HE92F, &H99C8, &H89E9, &HB98A, &HA9AB, &H5844, &H4865, &H7806, &H6827, &H18C0, &H08E1, &H3882, &H28A3, &HCB7D, &HDB5C, &HEB3F, &HFB1E, &H8BF9, &H9BD8, &HABBB, &HBB9A, &H4A75, &H5A54, &H6A37, &H7A16, &H0AF1, &H1AD0, &H2AB3, &H3A92, &HFD2E, &HED0F, &HDD6C, &HCD4D, &HBDAA, &HAD8B, &H9DE8, &H8DC9, &H7C26, &H6C07, &H5C64, &H4C45, &H3CA2, &H2C83, &H1CE0, &H0CC1, &HEF1F, &HFF3E, &HCF5D, &HDF7C, &HAF9B, &HBFBA, &H8FD9, &H9FF8, &H6E17, &H7E36, &H4E55, &H5E74, &H2E93, &H3EB2, &H0ED1, &H1EF0] From gambas at ...1... Wed Dec 10 02:08:58 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 02:08:58 +0100 Subject: [Gambas-user] Table "too many arguments" In-Reply-To: <493E8BD4.1070508@...1740...> References: <493E8BD4.1070508@...1740...> Message-ID: <200812100208.58106.gambas@...1...> On mardi 9 d?cembre 2008, Ron wrote: > Hi, > > I need to define this crc hash table in my gambas project. > > But I get "too many arguments", what alternatives do I have? > > Thanks. > > Regards, > Ron_2nd > > PUBLIC table AS Integer[] = [&H0000, &H1021, &H2042, &H3063, &H4084, > &H50A5, &H60C6, &H70E7, > &H8108, &H9129, &HA14A, &HB16B, &HC18C, &HD1AD, &HE1CE, &HF1EF, > &H1231, &H0210, &H3273, &H2252, &H52B5, &H4294, &H72F7, &H62D6, > &H9339, &H8318, &HB37B, &HA35A, &HD3BD, &HC39C, &HF3FF, &HE3DE, > &H2462, &H3443, &H0420, &H1401, &H64E6, &H74C7, &H44A4, &H5485, > &HA56A, &HB54B, &H8528, &H9509, &HE5EE, &HF5CF, &HC5AC, &HD58D, > &H3653, &H2672, &H1611, &H0630, &H76D7, &H66F6, &H5695, &H46B4, > &HB75B, &HA77A, &H9719, &H8738, &HF7DF, &HE7FE, &HD79D, &HC7BC, > &H48C4, &H58E5, &H6886, &H78A7, &H0840, &H1861, &H2802, &H3823, > &HC9CC, &HD9ED, &HE98E, &HF9AF, &H8948, &H9969, &HA90A, &HB92B, > &H5AF5, &H4AD4, &H7AB7, &H6A96, &H1A71, &H0A50, &H3A33, &H2A12, > &HDBFD, &HCBDC, &HFBBF, &HEB9E, &H9B79, &H8B58, &HBB3B, &HAB1A, > &H6CA6, &H7C87, &H4CE4, &H5CC5, &H2C22, &H3C03, &H0C60, &H1C41, > &HEDAE, &HFD8F, &HCDEC, &HDDCD, &HAD2A, &HBD0B, &H8D68, &H9D49, > &H7E97, &H6EB6, &H5ED5, &H4EF4, &H3E13, &H2E32, &H1E51, &H0E70, > &HFF9F, &HEFBE, &HDFDD, &HCFFC, &HBF1B, &HAF3A, &H9F59, &H8F78, > &H9188, &H81A9, &HB1CA, &HA1EB, &HD10C, &HC12D, &HF14E, &HE16F, > &H1080, &H00A1, &H30C2, &H20E3, &H5004, &H4025, &H7046, &H6067, > &H83B9, &H9398, &HA3FB, &HB3DA, &HC33D, &HD31C, &HE37F, &HF35E, > &H02B1, &H1290, &H22F3, &H32D2, &H4235, &H5214, &H6277, &H7256, > &HB5EA, &HA5CB, &H95A8, &H8589, &HF56E, &HE54F, &HD52C, &HC50D, > &H34E2, &H24C3, &H14A0, &H0481, &H7466, &H6447, &H5424, &H4405, > &HA7DB, &HB7FA, &H8799, &H97B8, &HE75F, &HF77E, &HC71D, &HD73C, > &H26D3, &H36F2, &H0691, &H16B0, &H6657, &H7676, &H4615, &H5634, > &HD94C, &HC96D, &HF90E, &HE92F, &H99C8, &H89E9, &HB98A, &HA9AB, > &H5844, &H4865, &H7806, &H6827, &H18C0, &H08E1, &H3882, &H28A3, > &HCB7D, &HDB5C, &HEB3F, &HFB1E, &H8BF9, &H9BD8, &HABBB, &HBB9A, > &H4A75, &H5A54, &H6A37, &H7A16, &H0AF1, &H1AD0, &H2AB3, &H3A92, > &HFD2E, &HED0F, &HDD6C, &HCD4D, &HBDAA, &HAD8B, &H9DE8, &H8DC9, > &H7C26, &H6C07, &H5C64, &H4C45, &H3CA2, &H2C83, &H1CE0, &H0CC1, > &HEF1F, &HFF3E, &HCF5D, &HDF7C, &HAF9B, &HBFBA, &H8FD9, &H9FF8, > &H6E17, &H7E36, &H4E55, &H5E74, &H2E93, &H3EB2, &H0ED1, &H1EF0] > Functions are limited to 63 arguments in Gambas. To workaround that, you can split the assignation this way: DIM table AS Integer[] = [ 0, 1, 2, 3, ..., 62 ] table.Insert([63, 64, 65, ..., 125]) table.Insert([126, ..., 188]) ... Note: You should add a '&' after number to be sure they are unsigned. Regards, -- Benoit Minisini From gambas at ...1... Wed Dec 10 02:18:55 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 02:18:55 +0100 Subject: [Gambas-user] Height and width units? In-Reply-To: <200812091346.44102.gambas@...1...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <384d3900812090434s70a55152h40208f035a7c33b3@...627...> <200812091346.44102.gambas@...1...> Message-ID: <200812100218.55245.gambas@...1...> On mardi 9 d?cembre 2008, Benoit Minisini wrote: > On mardi 9 d?cembre 2008, Jussi Lahtinen wrote: > > > Which GUI component do you use? > > > > GTK, I tried to switch it to QT, and problem gone! > > Is switching GUI component legit thing to do, or can I mess up my code > > with it? This time everything ok, but with real project... maybe I'm just > > having M$ nightmare > > induced paranoia... > > This is just a bug in gb.gtk. > This is not a bug in gb.gtk. As I said before, control and window dimensions are multiple of Desktop.Scale. Desktop.Scale is half the height of the default font in pixels. Alas, the same font with the same size with the same resolution does not always have the same height with Qt and GTK+! Even if they are the same on the screen. Yeepee! The IDE uses gb.qt, so, sometimes, when you run a project that uses gb.gtk or gb.gui on Gnome, your windows and controls does not have the same absolute size. Because Desktop.Scale is different. I think I will find a workaround with the mess of QT/GTK+ font management, but only in Gambas 3 I think... Or you can unset the (Scaled) property of the form: when this property is FALSE, the size and positions of the form and its controls are absolute. Regards, -- Benoit Minisini From gambas at ...1... Wed Dec 10 03:21:22 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 03:21:22 +0100 Subject: [Gambas-user] Height and width units? In-Reply-To: <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812091346.44102.gambas@...1...> <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> Message-ID: <200812100321.22425.gambas@...1...> On mardi 9 d?cembre 2008, Jussi Lahtinen wrote: > >> Anyhow the problem is GTK component, and I noticed an other problem > >> too. GTK is about 40 times slower when talking about Draw.Picture() !! > > > > Mmm. GTK+ is slower than QT, but not 40 times. Can you show your code? > > No problem, it's just stupid performance test / tile engine prototype. > See attached file (NayttoProto2-0.0.1.tar.gz). That was some sort of weird behaviour of gb.gtk, that does not internally manage pictures like in gb.qt. Now, with gb.gtk, using Picture.Load() ensures that the image is located in the server, so that using it for drawing is fast. Only Image.Load() keeps the image in the process memory. Regards, -- Benoit Minisini From gambas at ...1... Wed Dec 10 03:22:11 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 03:22:11 +0100 Subject: [Gambas-user] Height and width units? In-Reply-To: <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> References: <384d3900812080715r7f1efd71m58d4708ae1c56f36@...627...> <200812091346.44102.gambas@...1...> <384d3900812090533w3147a0baq53edbf81f0d853c0@...627...> Message-ID: <200812100322.11807.gambas@...1...> On mardi 9 d?cembre 2008, Jussi Lahtinen wrote: > >> Anyhow the problem is GTK component, and I noticed an other problem > >> too. GTK is about 40 times slower when talking about Draw.Picture() !! > > > > Mmm. GTK+ is slower than QT, but not 40 times. Can you show your code? > > No problem, it's just stupid performance test / tile engine prototype. > See attached file (NayttoProto2-0.0.1.tar.gz). The bug was fixed in revision #1732. -- Benoit Minisini From simonart.dominique at ...11... Wed Dec 10 05:25:29 2008 From: simonart.dominique at ...11... (Simonart Dominique) Date: Wed, 10 Dec 2008 05:25:29 +0100 Subject: [Gambas-user] Infinite loop with the image editor Message-ID: <493F44B9.9050909@...11...> Hi, May be it's me, but ... in the gambas 2.9 IDE (opensuse 11.0 KDE 3, Qt project), create a new image1.png file. after drawing something on the area, select the transparent color and the fill tool then click on a colored pixel and you enter in infinite loop. By the way, I search a solution to restore a small area in a big picture with transparency. How this is possible? regards, Dominique SIMONART From eilert-sprachen at ...221... Wed Dec 10 10:52:24 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Wed, 10 Dec 2008 10:52:24 +0100 Subject: [Gambas-user] Timer in Script Message-ID: <493F9158.7080402@...221...> Hello experts! Can I use a Timer control in a scripted Gambas program, and if yes, how? And if not, is it possible in a non-graphical Gambas program? Thanks for any hints. Rolf From rospolosco at ...152... Wed Dec 10 12:05:12 2008 From: rospolosco at ...152... (Stefano Palmeri) Date: Wed, 10 Dec 2008 12:05:12 +0100 Subject: [Gambas-user] Timer in Script In-Reply-To: <493F9158.7080402@...221...> References: <493F9158.7080402@...221...> Message-ID: <200812101205.13274.rospolosco@...152...> Il mercoled? 10 dicembre 2008 10:52:24 Rolf-Werner Eilert ha scritto: > Hello experts! > > Can I use a Timer control in a scripted Gambas program, and if yes, how? > And if not, is it possible in a non-graphical Gambas program? > > Thanks for any hints. > > Rolf > Don't know about scripted Gambas program, but for a shell program you cloud do: ----------------------------------------------------------------------------- ' Gambas module file PUBLIC hConsoleTimer AS Timer PUBLIC SUB Main() hConsoleTimer = NEW Timer AS "MyTimer" hConsoleTimer.Delay = 1000 hConsoleTimer.Enabled = TRUE END PUBLIC SUB MyTimer_Timer() PRINT "Hello Gambas" END --------------------------------------------------------------- Bye, Stefano > --------------------------------------------------------------------------- >--- SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, > Nevada. The future of the web can't happen without you. Join us at MIX09 > to help pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com >/ _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From gambas at ...1... Wed Dec 10 13:16:53 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 13:16:53 +0100 Subject: [Gambas-user] Infinite loop with the image editor In-Reply-To: <493F44B9.9050909@...11...> References: <493F44B9.9050909@...11...> Message-ID: <200812101316.53463.gambas@...1...> On mercredi 10 d?cembre 2008, Simonart Dominique wrote: > Hi, > May be it's me, but ... > in the gambas 2.9 IDE (opensuse 11.0 KDE 3, Qt project), > create a new image1.png file. after drawing something on the > area, select the transparent color and the fill tool then > click on a colored pixel and you enter in infinite loop. Fixed in revision #1733! > > By the way, I search a solution to restore a small area in a > big picture with transparency. How this is possible? What do you mean exactly? -- Benoit Minisini From gambas at ...1938... Wed Dec 10 14:09:29 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Wed, 10 Dec 2008 14:09:29 +0100 Subject: [Gambas-user] Ctrl+Alt+X doesn't create executable Message-ID: <200812101409.29738.gambas@...1938...> Hi Benoit, In Gambas 3.0, snapshot from today, hitting the shortcut mentioned above doesn't do anything. Klicking on Project=>>Version=>>Executable does the job Greetz Stevie From gambas at ...1... Wed Dec 10 14:15:35 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 14:15:35 +0100 Subject: [Gambas-user] Ctrl+Alt+X doesn't create executable In-Reply-To: <200812101409.29738.gambas@...1938...> References: <200812101409.29738.gambas@...1938...> Message-ID: <200812101415.35244.gambas@...1...> On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > Hi Benoit, > > In Gambas 3.0, snapshot from today, hitting the shortcut mentioned above > doesn't do anything. > Klicking on Project=>>Version=>>Executable does the job > > Greetz > Stevie > It works there: check that this shortcut is not used by your desktop. -- Benoit Minisini From gambas at ...1938... Wed Dec 10 14:38:52 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Wed, 10 Dec 2008 14:38:52 +0100 Subject: [Gambas-user] Ctrl+Alt+X doesn't create executable In-Reply-To: <200812101415.35244.gambas@...1...> References: <200812101409.29738.gambas@...1938...> <200812101415.35244.gambas@...1...> Message-ID: <200812101438.52490.gambas@...1938...> Am Mittwoch, 10. Dezember 2008 14:15:35 schrieb Benoit Minisini: > On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > > Hi Benoit, > > > > In Gambas 3.0, snapshot from today, hitting the shortcut mentioned above > > doesn't do anything. > > Klicking on Project=>>Version=>>Executable does the job > > > > Greetz > > Stevie > > It works there: check that this shortcut is not used by your desktop. Uhm...with this shortcut most (all?) people using KDE come in conflict with the function: Clipboard on/off ...at least for Kubuntu. Greetz Stevie From simonart.dominique at ...11... Wed Dec 10 14:41:12 2008 From: simonart.dominique at ...11... (Simonart Dominique) Date: Wed, 10 Dec 2008 14:41:12 +0100 Subject: [Gambas-user] Infinite loop with the image editor In-Reply-To: <200812101316.53463.gambas@...1...> References: <493F44B9.9050909@...11...> <200812101316.53463.gambas@...1...> Message-ID: <493FC6F8.7010203@...11...> Benoit Minisini a ?crit : > On mercredi 10 d?cembre 2008, Simonart Dominique wrote: >> Hi, >> May be it's me, but ... >> in the gambas 2.9 IDE (opensuse 11.0 KDE 3, Qt project), >> create a new image1.png file. after drawing something on the >> area, select the transparent color and the fill tool then >> click on a colored pixel and you enter in infinite loop. > > Fixed in revision #1733! Thanks! > >> By the way, I search a solution to restore a small area in a >> big picture with transparency. How this is possible? > > What do you mean exactly? > I create a big picture with transparency (.png) by adding small squares in some places. Sometimes, I put a small square at a wrong place so I want to remove this square and restore the transparent square wich was there before the mistake. I could not figure how to do that. I think about something like myPicture.clear(x,y,w,h) or myPicture.remove(x,y,w,h) regards Dominique Simonart From gambas at ...1... Wed Dec 10 14:46:30 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 14:46:30 +0100 Subject: [Gambas-user] Ctrl+Alt+X doesn't create executable In-Reply-To: <200812101438.52490.gambas@...1938...> References: <200812101409.29738.gambas@...1938...> <200812101415.35244.gambas@...1...> <200812101438.52490.gambas@...1938...> Message-ID: <200812101446.30917.gambas@...1...> On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > Am Mittwoch, 10. Dezember 2008 14:15:35 schrieb Benoit Minisini: > > On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > > > Hi Benoit, > > > > > > In Gambas 3.0, snapshot from today, hitting the shortcut mentioned > > > above doesn't do anything. > > > Klicking on Project=>>Version=>>Executable does the job > > > > > > Greetz > > > Stevie > > > > It works there: check that this shortcut is not used by your desktop. > > Uhm...with this shortcut most (all?) people using KDE come in conflict with > the function: Clipboard on/off ...at least for Kubuntu. > > Greetz > Stevie > What's that? Anyway, shortcuts should be configurable in the IDE, but I will do that for Gambas 3 only. -- Benoit Minisini From gambas at ...1938... Wed Dec 10 14:50:03 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Wed, 10 Dec 2008 14:50:03 +0100 Subject: [Gambas-user] Ctrl+Alt+X doesn't create executable In-Reply-To: <200812101446.30917.gambas@...1...> References: <200812101409.29738.gambas@...1938...> <200812101438.52490.gambas@...1938...> <200812101446.30917.gambas@...1...> Message-ID: <200812101450.03612.gambas@...1938...> Am Mittwoch, 10. Dezember 2008 14:46:30 schrieb Benoit Minisini: > On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > > Am Mittwoch, 10. Dezember 2008 14:15:35 schrieb Benoit Minisini: > > > On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > > > > Hi Benoit, > > > > > > > > In Gambas 3.0, snapshot from today, hitting the shortcut mentioned > > > > above doesn't do anything. > > > > Klicking on Project=>>Version=>>Executable does the job > > > > > > > > Greetz > > > > Stevie > > > > > > It works there: check that this shortcut is not used by your desktop. > > > > Uhm...with this shortcut most (all?) people using KDE come in conflict > > with the function: Clipboard on/off ...at least for Kubuntu. > > > > Greetz > > Stevie > > What's that? Anyway, shortcuts should be configurable in the IDE, but I > will do that for Gambas 3 only. I never talked about something else. :-))) Greetz Stevie From gambas at ...1938... Wed Dec 10 14:58:37 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Wed, 10 Dec 2008 14:58:37 +0100 Subject: [Gambas-user] How to execute a standard routine every time a function in a component is called Message-ID: <200812101458.37114.gambas@...1938...> Hi Gurus! Sorry for this noop-question: In the module area of my component I read a settings file with some connection parameters. As long as I run the component as a normal Gambas-programm this works perfectly. But when I turn it into a component and call one of it's exported functions, the function is called directly, without executing the code in the module area and my connection parameters are never read. Surely there is a another way than putting the reading of the settings file into every single function...but which way? TIA and grretz Stevie From gambas at ...1... Wed Dec 10 15:04:08 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 15:04:08 +0100 Subject: [Gambas-user] How to execute a standard routine every time a function in a component is called In-Reply-To: <200812101458.37114.gambas@...1938...> References: <200812101458.37114.gambas@...1938...> Message-ID: <200812101504.08313.gambas@...1...> On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > Hi Gurus! > > Sorry for this noop-question: > In the module area of my component I read a settings file with some > connection parameters. > As long as I run the component as a normal Gambas-programm this works > perfectly. But when I turn it into a component and call one of it's > exported functions, the function is called directly, without executing the > code in the module area and my connection parameters are never read. > Surely there is a another way than putting the reading of the settings file > into every single function...but which way? > > TIA and grretz > Stevie > A class can have an "_init" special static public method that is called the first time a class is used. You can use that. A component written in Gambas has no global initialization function. -- Benoit Minisini From gambas at ...1938... Wed Dec 10 15:31:55 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Wed, 10 Dec 2008 15:31:55 +0100 Subject: [Gambas-user] How to execute a standard routine every time a function in a component is called In-Reply-To: <200812101504.08313.gambas@...1...> References: <200812101458.37114.gambas@...1938...> <200812101504.08313.gambas@...1...> Message-ID: <200812101531.55586.gambas@...1938...> Am Mittwoch, 10. Dezember 2008 15:04:08 schrieb Benoit Minisini: > On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > > Hi Gurus! > > > > Sorry for this noop-question: > > In the module area of my component I read a settings file with some > > connection parameters. > > As long as I run the component as a normal Gambas-programm this works > > perfectly. But when I turn it into a component and call one of it's > > exported functions, the function is called directly, without executing > > the code in the module area and my connection parameters are never read. > > Surely there is a another way than putting the reading of the settings > > file into every single function...but which way? > > > > TIA and grretz > > Stevie > > A class can have an "_init" special static public method that is called the > first time a class is used. You can use that. > > A component written in Gambas has no global initialization function. Thanks for the hint, but I can't get it going. I put this into the module area: Static Public Sub _init() ' Read config file Dim hCFG As New Settings(User.Home &/ "etc/some.cfg") End When compiling I get: Unxepected Static Next question: How do I have to define hCFG? Dim, Private??? ...I think, I need a good newby-book about Gambas and OO! ...but where to get?? :-) Thanks for help! Greetz Stevie From eilert-sprachen at ...221... Wed Dec 10 15:40:54 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Wed, 10 Dec 2008 15:40:54 +0100 Subject: [Gambas-user] Hiding FMain not possible? Message-ID: <493FD4F6.3030308@...221...> Hi folks, meanwhile I've understood how to use the TrayIcon, but if my application should show only the tray icon, no application window, how can I hide the whole thing (except the tray icon, of course)? Thanks for your advice! Rolf From gambas at ...1... Wed Dec 10 15:42:10 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 15:42:10 +0100 Subject: [Gambas-user] How to execute a standard routine every time a function in a component is called In-Reply-To: <200812101531.55586.gambas@...1938...> References: <200812101458.37114.gambas@...1938...> <200812101504.08313.gambas@...1...> <200812101531.55586.gambas@...1938...> Message-ID: <200812101542.10687.gambas@...1...> On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > Am Mittwoch, 10. Dezember 2008 15:04:08 schrieb Benoit Minisini: > > On mercredi 10 d?cembre 2008, gambas at ...1938... wrote: > > > Hi Gurus! > > > > > > Sorry for this noop-question: > > > In the module area of my component I read a settings file with some > > > connection parameters. > > > As long as I run the component as a normal Gambas-programm this works > > > perfectly. But when I turn it into a component and call one of it's > > > exported functions, the function is called directly, without executing > > > the code in the module area and my connection parameters are never > > > read. Surely there is a another way than putting the reading of the > > > settings file into every single function...but which way? > > > > > > TIA and grretz > > > Stevie > > > > A class can have an "_init" special static public method that is called > > the first time a class is used. You can use that. > > > > A component written in Gambas has no global initialization function. > > Thanks for the hint, but I can't get it going. I put this into the module > area: > > Static Public Sub _init() > ' Read config file > Dim hCFG As New Settings(User.Home &/ "etc/some.cfg") > End > > When compiling I get: > Unxepected Static > A module is just a class where everything is static, so the STATIC keyword is not needed. > Next question: How do I have to define hCFG? Dim, Private??? > ...I think, I need a good newby-book about Gambas and OO! ...but where to > get?? :-) It depends where you need to use it. Regards, -- Benoit Minisini From gambas at ...1... Wed Dec 10 15:42:36 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 15:42:36 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <493FD4F6.3030308@...221...> References: <493FD4F6.3030308@...221...> Message-ID: <200812101542.36355.gambas@...1...> On mercredi 10 d?cembre 2008, Rolf-Werner Eilert wrote: > Hi folks, > > meanwhile I've understood how to use the TrayIcon, but if my application > should show only the tray icon, no application window, how can I hide > the whole thing (except the tray icon, of course)? > > Thanks for your advice! > > Rolf > FMain.Hide ? -- Benoit Minisini From eilert-sprachen at ...221... Wed Dec 10 15:45:21 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Wed, 10 Dec 2008 15:45:21 +0100 Subject: [Gambas-user] Timer in Script In-Reply-To: <200812101205.13274.rospolosco@...152...> References: <493F9158.7080402@...221...> <200812101205.13274.rospolosco@...152...> Message-ID: <493FD601.4000207@...221...> Stefano Palmeri schrieb: > Il mercoled? 10 dicembre 2008 10:52:24 Rolf-Werner Eilert ha scritto: >> Hello experts! >> >> Can I use a Timer control in a scripted Gambas program, and if yes, how? >> And if not, is it possible in a non-graphical Gambas program? >> >> Thanks for any hints. >> >> Rolf >> > > Don't know about scripted Gambas program, but for a shell > program you cloud do: > > ----------------------------------------------------------------------------- > ' Gambas module file > > PUBLIC hConsoleTimer AS Timer > > PUBLIC SUB Main() > > hConsoleTimer = NEW Timer AS "MyTimer" > hConsoleTimer.Delay = 1000 > hConsoleTimer.Enabled = TRUE > > END > > PUBLIC SUB MyTimer_Timer() > > PRINT "Hello Gambas" > > END > --------------------------------------------------------------- > > Bye, > > Stefano > > A scripted program seems to be one big SUB or FUNCTION, so I got errors until I changed everything into one big single code without calling any SUBs or FUNCTIONs. This runs good. Without a timer, of course. Thanks for your example. This might be a solution, and this gives me another idea, I'll be back later :-) Rolf From eilert-sprachen at ...221... Wed Dec 10 15:50:15 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Wed, 10 Dec 2008 15:50:15 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <200812101542.36355.gambas@...1...> References: <493FD4F6.3030308@...221...> <200812101542.36355.gambas@...1...> Message-ID: <493FD727.7010108@...221...> Benoit Minisini schrieb: > On mercredi 10 d?cembre 2008, Rolf-Werner Eilert wrote: >> Hi folks, >> >> meanwhile I've understood how to use the TrayIcon, but if my application >> should show only the tray icon, no application window, how can I hide >> the whole thing (except the tray icon, of course)? >> >> Thanks for your advice! >> >> Rolf >> > > FMain.Hide ? > This is what I tried, and I tried setting FMain.Visible = False and so on - no help, it just shows up on screen. It is shown when started in the IDE and when started as an executable as well. Seems this has to do with my KDE version, like the other thing we discussed yesterday... Rolf From arosa at ...2015... Wed Dec 10 16:10:57 2008 From: arosa at ...2015... (Toni) Date: Wed, 10 Dec 2008 15:10:57 +0000 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <493FD727.7010108@...221...> References: <493FD4F6.3030308@...221...> <200812101542.36355.gambas@...1...> <493FD727.7010108@...221...> Message-ID: <493FDC01.8090901@...2015...> Hi Rolf, I needed something similar and what I did is creating a new module and setting it as the "startup class", then in order to prevent the application ending straightly (after creating/showing the trayicon), I used Fmain "Persistent" property to force the application stay loaded... so in your case, even if there is a bug ?? in your version of KDE, it will not be showing the form and so, there will be no need to hide it. (may be it is not the best solution, but it works for me!) Here is a sample of what you could code this startup module: PUBLIC FUNCTION Main() AS Boolean DIM tryicn AS TrayIcon tryicn = NEW TrayIcon AS "tryicn" tryicn.Show() tryicn.Visible = TRUE tryicn.Picture = Picture["agendaxml.png"] FMain.Persistent = TRUE END PUBLIC SUB tryicn_dblclick() FMain.Persistent = FALSE FMain.Close END Regards, Toni En/na Rolf-Werner Eilert ha escrit: > Benoit Minisini schrieb: > >> On mercredi 10 d?cembre 2008, Rolf-Werner Eilert wrote: >> >>> Hi folks, >>> >>> meanwhile I've understood how to use the TrayIcon, but if my application >>> should show only the tray icon, no application window, how can I hide >>> the whole thing (except the tray icon, of course)? >>> >>> Thanks for your advice! >>> >>> Rolf >>> >>> >> FMain.Hide ? >> >> > > This is what I tried, and I tried setting FMain.Visible = False and so > on - no help, it just shows up on screen. > > It is shown when started in the IDE and when started as an executable as > well. > > Seems this has to do with my KDE version, like the other thing we > discussed yesterday... > > Rolf > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Wed Dec 10 16:27:07 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 16:27:07 +0100 Subject: [Gambas-user] My own sourceforge address was rejected by sourceforge mailing-list! :-) Message-ID: <200812101627.07202.gambas@...1...> Funny :-/ ---------- Transmitted message ----------------------- Sujet?: confirm 4c208dde7ac4f9f3470f886941cf5698a9455f86 Date?: mercredi 10 d?cembre 2008 De?: gambas-user-request at lists.sourceforge.net ??: gambas at ...1... Your membership in the mailing list Gambas-user has been disabled due to excessive bounces The last bounce received from you was dated 10-Dec-2008. You will not get any more messages from this list until you re-enable your membership. You will receive 3 more reminders like this before your membership in the list is deleted. To re-enable your membership, you can simply respond to this message (leaving the Subject: line intact), or visit the confirmation page at ... ------------------------------------------------------- -- Benoit Minisini From gambas at ...1938... Wed Dec 10 18:05:45 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Wed, 10 Dec 2008 18:05:45 +0100 Subject: [Gambas-user] Problem with gb.settings Message-ID: <200812101805.45943.gambas@...1938...> Hi List, This in the module area works. Private hCFG As New Settings("/Path/To/cfg") Because I'm writing a component, now I have to do this in the module area: Private hCFG As Settings And something like this in the _init-Sub hCFG = New Settings("/Path/To/cfg") 'Just for testing Print hCFG["General/Color"] No complains when compiling it..but the object stays empty. Print() doesn't put any data out. What I'm doing wrong? ...and another question: Where can I get (read) informations about such things and how to do them in Gambas? TIA Stevie From jussi.lahtinen at ...626... Wed Dec 10 18:33:20 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 10 Dec 2008 19:33:20 +0200 Subject: [Gambas-user] Problem with gb.settings In-Reply-To: <200812101805.45943.gambas@...1938...> References: <200812101805.45943.gambas@...1938...> Message-ID: <384d3900812100933n5902a01ao450c8bbbdac20115@...627...> @ http://gambasdoc.org/help/comp/gb.settings/settings There is example of usage. I think you need code something like this: hCFG[General/Color] = something to write under General/Color hCFG.Save Ok? Jussi On Wed, Dec 10, 2008 at 7:05 PM, wrote: > Hi List, > > This in the module area works. > Private hCFG As New Settings("/Path/To/cfg") > > Because I'm writing a component, now I have to do this in the module area: > Private hCFG As Settings > > And something like this in the _init-Sub > hCFG = New Settings("/Path/To/cfg") > 'Just for testing > Print hCFG["General/Color"] > > No complains when compiling it..but the object stays empty. Print() doesn't > put any data out. > > What I'm doing wrong? > > ...and another question: Where can I get (read) informations about such things > and how to do them in Gambas? > > TIA > Stevie > > > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From glassnig at ...1994... Wed Dec 10 18:20:25 2008 From: glassnig at ...1994... (Georg Lassnig) Date: Wed, 10 Dec 2008 18:20:25 +0100 Subject: [Gambas-user] Problem with gb.settings In-Reply-To: <200812101805.45943.gambas@...1938...> References: <200812101805.45943.gambas@...1938...> Message-ID: <200812101820.25326.glassnig@...1994...> Am Mittwoch 10. Dezember 2008 18:05:45 schrieb gambas at ...1938...: > Hi List, > > This in the module area works. > Private hCFG As New Settings("/Path/To/cfg") Try this: Private hCFG As New Settings("/Path/To/cfg") AS "hCFG" > > Because I'm writing a component, now I have to do this in the module area: > Private hCFG As Settings > > And something like this in the _init-Sub > hCFG = New Settings("/Path/To/cfg") > 'Just for testing > Print hCFG["General/Color"] hCFG["General/Color"] = Variable hCFG.Save > ...and another question: Where can I get (read) informations about such > things and how to do them in Gambas? Do you mean this? Variable = hCFG["General/Color"] Regards George From jussi.lahtinen at ...626... Wed Dec 10 18:34:35 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 10 Dec 2008 19:34:35 +0200 Subject: [Gambas-user] Problem with gb.settings In-Reply-To: <384d3900812100933n5902a01ao450c8bbbdac20115@...627...> References: <200812101805.45943.gambas@...1938...> <384d3900812100933n5902a01ao450c8bbbdac20115@...627...> Message-ID: <384d3900812100934i3c8628a4r44abb014a7373c6c@...627...> Sorry, hCFG["General/Color"] = something to write under General/Color hCFG.Save Of course.... On Wed, Dec 10, 2008 at 7:33 PM, Jussi Lahtinen wrote: > @ http://gambasdoc.org/help/comp/gb.settings/settings > > There is example of usage. I think you need code something like this: > > hCFG[General/Color] = something to write under General/Color > hCFG.Save > > Ok? > > > Jussi > > > > On Wed, Dec 10, 2008 at 7:05 PM, wrote: >> Hi List, >> >> This in the module area works. >> Private hCFG As New Settings("/Path/To/cfg") >> >> Because I'm writing a component, now I have to do this in the module area: >> Private hCFG As Settings >> >> And something like this in the _init-Sub >> hCFG = New Settings("/Path/To/cfg") >> 'Just for testing >> Print hCFG["General/Color"] >> >> No complains when compiling it..but the object stays empty. Print() doesn't >> put any data out. >> >> What I'm doing wrong? >> >> ...and another question: Where can I get (read) informations about such things >> and how to do them in Gambas? >> >> TIA >> Stevie >> >> >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > From jussi.lahtinen at ...626... Wed Dec 10 18:50:11 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 10 Dec 2008 19:50:11 +0200 Subject: [Gambas-user] Gambas3 compilation problem Message-ID: <384d3900812100950j12b2bd9bibb5e7c664d8d483b@...627...> Hi! I'm on Ubuntu 8.10 64 bit. I have compiled Gambas2.9 without problems, so everything should be ok with my system..? I've done this: 1. svn checkout https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk/ Checked out revision 1733. Everything ok. 2. ./reconf-all Got messages: libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, `.'. libtoolize: copying file `./ltmain.sh' libtoolize: putting auxiliary files in `.'. libtoolize: copying file `libltdl/config/compile' libtoolize: copying file `libltdl/config/config.guess' libtoolize: copying file `libltdl/config/config.sub' libtoolize: copying file `libltdl/config/depcomp' libtoolize: copying file `libltdl/config/install-sh' libtoolize: copying file `libltdl/config/missing' libtoolize: copying file `libltdl/config/ltmain.sh' libtoolize: putting macros in `libltdl/m4'. libtoolize: copying file `libltdl/m4/argz.m4' libtoolize: copying file `libltdl/m4/libtool.m4' libtoolize: copying file `libltdl/m4/ltdl.m4' libtoolize: copying file `libltdl/m4/ltoptions.m4' libtoolize: copying file `libltdl/m4/ltsugar.m4' libtoolize: copying file `libltdl/m4/ltversion.m4' libtoolize: copying file `libltdl/m4/lt~obsolete.m4' libtoolize: putting libltdl files in `libltdl'. libtoolize: copying file `libltdl/COPYING.LIB' libtoolize: copying file `libltdl/README' libtoolize: copying file `libltdl/Makefile.am' libtoolize: copying file `libltdl/configure.ac' libtoolize: copying file `libltdl/aclocal.m4' libtoolize: copying file `libltdl/Makefile.in' libtoolize: copying file `libltdl/config-h.in' libtoolize: copying file `libltdl/configure' libtoolize: copying file `libltdl/argz_.h' libtoolize: copying file `libltdl/argz.c' libtoolize: copying file `libltdl/loaders/dld_link.c' libtoolize: copying file `libltdl/loaders/dlopen.c' libtoolize: copying file `libltdl/loaders/dyld.c' libtoolize: copying file `libltdl/loaders/load_add_on.c' libtoolize: copying file `libltdl/loaders/loadlibrary.c' libtoolize: copying file `libltdl/loaders/shl_load.c' libtoolize: copying file `libltdl/lt__dirent.c' libtoolize: copying file `libltdl/lt__strl.c' libtoolize: copying file `libltdl/libltdl/lt__alloc.h' libtoolize: copying file `libltdl/libltdl/lt__dirent.h' libtoolize: copying file `libltdl/libltdl/lt__glibc.h' libtoolize: copying file `libltdl/libltdl/lt__private.h' libtoolize: copying file `libltdl/libltdl/lt__strl.h' libtoolize: copying file `libltdl/libltdl/lt_dlloader.h' libtoolize: copying file `libltdl/libltdl/lt_error.h' libtoolize: copying file `libltdl/libltdl/lt_system.h' libtoolize: copying file `libltdl/libltdl/slist.h' libtoolize: copying file `libltdl/loaders/preopen.c' libtoolize: copying file `libltdl/lt__alloc.c' libtoolize: copying file `libltdl/lt_dlloader.c' libtoolize: copying file `libltdl/lt_error.c' libtoolize: copying file `libltdl/ltdl.c' libtoolize: copying file `libltdl/ltdl.h' libtoolize: copying file `libltdl/slist.c' libtoolize: You should add the contents of the following files to `aclocal.m4': libtoolize: `libltdl/m4/libtool.m4' libtoolize: `libltdl/m4/ltoptions.m4' libtoolize: `libltdl/m4/ltversion.m4' libtoolize: `libltdl/m4/ltsugar.m4' libtoolize: `libltdl/m4/lt~obsolete.m4' libtoolize: `libltdl/m4/argz.m4' libtoolize: `libltdl/m4/ltdl.m4' libtoolize: or else add `AC_CONFIG_MACRO_DIR([libltdl/m4])' to configure.ac. libtoolize: Remember to add `LT_CONFIG_LTDL_DIR([libltdl])' to `configure.ac'. libtoolize: Consider using `AC_CONFIG_AUX_DIR([libltdl/config])' in configure.ac. libtoolize: Consider adding `-I m4' to ACLOCAL_AMFLAGS in Makefile.am. configure.ac: required file `./mkinstalldirs' not found autoreconf: automake failed with exit status: 1 Ideas? Jussi From jussi.lahtinen at ...626... Wed Dec 10 19:01:07 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 10 Dec 2008 20:01:07 +0200 Subject: [Gambas-user] Problem with gb.settings In-Reply-To: <200812101820.25326.glassnig@...1994...> References: <200812101805.45943.gambas@...1938...> <200812101820.25326.glassnig@...1994...> Message-ID: <384d3900812101001u25465bf1r951c9ab75b521ae4@...627...> I'm not sure what is the problem you mean.... PUBLIC SUB WriteSettings() hCFG["General/Color"] = 666 hCFG.Save END PUBLIC SUB ReadSettings() DIM aa AS Integer PRINT hCFG["General/Color"] 'Print content to IDE console. aa = hCFG["General/Color"] 'Put content to aa (in this case integer). PRINT aa 'Print aa to IDE console, just to see that aa got it right. END Everything seems to work..? Following example creates file content: [General] Color=666 Hope that helps... Jussi On Wed, Dec 10, 2008 at 7:20 PM, Georg Lassnig wrote: > Am Mittwoch 10. Dezember 2008 18:05:45 schrieb gambas at ...1938...: >> Hi List, >> >> This in the module area works. >> Private hCFG As New Settings("/Path/To/cfg") > Try this: > Private hCFG As New Settings("/Path/To/cfg") AS "hCFG" > > >> >> Because I'm writing a component, now I have to do this in the module area: >> Private hCFG As Settings >> >> And something like this in the _init-Sub >> hCFG = New Settings("/Path/To/cfg") >> 'Just for testing >> Print hCFG["General/Color"] > hCFG["General/Color"] = Variable > hCFG.Save > > >> ...and another question: Where can I get (read) informations about such >> things and how to do them in Gambas? > Do you mean this? > Variable = hCFG["General/Color"] > > Regards > George > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From rospolosco at ...152... Wed Dec 10 19:18:27 2008 From: rospolosco at ...152... (Stefano Palmeri) Date: Wed, 10 Dec 2008 19:18:27 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <493FD727.7010108@...221...> References: <493FD4F6.3030308@...221...> <200812101542.36355.gambas@...1...> <493FD727.7010108@...221...> Message-ID: <200812101918.27610.rospolosco@...152...> Il mercoled? 10 dicembre 2008 15:50:15 Rolf-Werner Eilert ha scritto: > Benoit Minisini schrieb: > > On mercredi 10 d?cembre 2008, Rolf-Werner Eilert wrote: > >> Hi folks, > >> > >> meanwhile I've understood how to use the TrayIcon, but if my application > >> should show only the tray icon, no application window, how can I hide > >> the whole thing (except the tray icon, of course)? > >> > >> Thanks for your advice! > >> > >> Rolf > > > > FMain.Hide ? > > This is what I tried, and I tried setting FMain.Visible = False and so > on - no help, it just shows up on screen. > > It is shown when started in the IDE and when started as an executable as > well. > > Seems this has to do with my KDE version, like the other thing we > discussed yesterday... > > Rolf > I've the same problem under KDE 3.5.9. To solve I use the same solution explained by Toni. In a startup module I just put: --------------------------------- PUBLIC SUB Main() FMain.Visible = FALSE END --------------------------------- Bye, Stefano > > --------------------------------------------------------------------------- >--- SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, > Nevada. The future of the web can't happen without you. Join us at MIX09 > to help pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com >/ _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From gambas at ...1... Wed Dec 10 19:34:44 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 10 Dec 2008 19:34:44 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <200812101918.27610.rospolosco@...152...> References: <493FD4F6.3030308@...221...> <493FD727.7010108@...221...> <200812101918.27610.rospolosco@...152...> Message-ID: <200812101934.44824.gambas@...1...> On mercredi 10 d?cembre 2008, Stefano Palmeri wrote: > Il mercoled? 10 dicembre 2008 15:50:15 Rolf-Werner Eilert ha scritto: > > Benoit Minisini schrieb: > > > On mercredi 10 d?cembre 2008, Rolf-Werner Eilert wrote: > > >> Hi folks, > > >> > > >> meanwhile I've understood how to use the TrayIcon, but if my > > >> application should show only the tray icon, no application window, how > > >> can I hide the whole thing (except the tray icon, of course)? > > >> > > >> Thanks for your advice! > > >> > > >> Rolf > > > > > > FMain.Hide ? > > > > This is what I tried, and I tried setting FMain.Visible = False and so > > on - no help, it just shows up on screen. > > > > It is shown when started in the IDE and when started as an executable as > > well. > > > > Seems this has to do with my KDE version, like the other thing we > > discussed yesterday... > > > > Rolf > > I've the same problem under KDE 3.5.9. To solve I use the same > solution explained by Toni. In a startup module I just put: > > --------------------------------- > PUBLIC SUB Main() > > FMain.Visible = FALSE > > END > --------------------------------- > > > Bye, > > Stefano > If your startup class is not a form, you don't have to do FMain.Visible = FALSE. Just create your TrayIcon there, and show FMain only if needed. Regards, -- Benoit Minisini From m0e.lnx at ...626... Wed Dec 10 21:39:45 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Wed, 10 Dec 2008 20:39:45 +0000 Subject: [Gambas-user] Emulating wizard Back/Next navigation Message-ID: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> So I set myself to create a program that acts like a wizard, but chose not to use the wizard object because well, there is just too many variables here, and there is more than one way to get to the end, Depending on user input. So what I did was create a navigation tool bar at the bottom of FMain this toolbar has a BACK, EXIT, and a NEXT button. I have a workspace object above it which will host other forms via each forms .Reparent method. Can anyone suggest a way to make reverse and forward navigation on such a setup? I have created a small project what I'm trying to do... See attachment Any help is appreciated Thanks -------------- next part -------------- A non-text attachment was scrubbed... Name: navigation-0.0.1.tar.gz Type: application/x-gzip Size: 9753 bytes Desc: not available URL: From gambas at ...1938... Wed Dec 10 22:18:16 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Wed, 10 Dec 2008 22:18:16 +0100 Subject: [Gambas-user] Problem with gb.settings In-Reply-To: <200812101820.25326.glassnig@...1994...> References: <200812101805.45943.gambas@...1938...> <200812101820.25326.glassnig@...1994...> Message-ID: <200812102218.16678.gambas@...1938...> Hi George! Thanks for your reply. Perhaps I was not really clear. - I want to write a component - This component needs to read some settings from a config file - Because of the fact, that the functions of the component are called directly, doing something like this: Private hCFG As New Settings(User.Home &/ "Path/To/Configfile") is not possible, because the declaration would be done, but not the assigning of the path to the config file So what I need is: Declare hCFG as Private and do the assignment of the path in _init-sub, so that gb.settings knows which config file it has to load. Private hCFG As New Settings("/Path/To/cfg") AS "hCFG" doesn't do the job...the object hCFG stays empty. > > ...and another question: Where can I get (read) informations about such > > things and how to do them in Gambas? > > Do you mean this? Not really. I meant this things like creating objects and assigning data to them in those various ways. Greetz Stevie From gambasforum at ...2019... Thu Dec 11 08:14:01 2008 From: gambasforum at ...2019... (Lars Hoeger) Date: Thu, 11 Dec 2008 08:14:01 +0100 Subject: [Gambas-user] Using a socket to download an image. Please Help ^_^ In-Reply-To: <200812010749.21204.rterry@...1946...> References: <200812010749.21204.rterry@...1946...> Message-ID: <4940BDB9.6040907@...2019...> richard terry schrieb: > On Mon, 1 Dec 2008 06:50:06 am Robert Moss wrote: > > Robert this may not be much help to you and I'm not sure how related to your > problem it is, but just on the off chance. I struggled with saving a picture > and retrieving from a postgres field. > > The code I included worked really well for a long time, but in the last couple > of upgrades though it saves the file ok, it retreives a corrupt image. and I > get a libpng error (sob sob) and I havn't had time or inclination to re-look > at it. > > Please if/when you figure it out can I have a few pointers. > > Regards > > Richard > > > > >> The ImgData stops writing when it comes to a byte with value &H00 (I >> believe) although I'm pretty sure it doesn't matter how I write the stream, >> once it's read as a String, it becomes terminated by any NULL char. So my >> question is this: How do I read the data from the Socket in binary, write >> it to a stream file in binary, but STILL I MUST be able to split the data >> based on the 2 CRLF's >> >> On Sun, Nov 30, 2008 at 11:48 AM, Robert Moss >> > wrote: > >>> Sorry that's not it, I mis-copied the line, in the actual code it does >>> Mid(sData, p1 + 4) >>> >>> On Sun, Nov 30, 2008 at 2:39 AM, Doriano Blengino < >>> >>> doriano.blengino at ...1909...> wrote: >>> >>>> Robert Moss ha scritto: >>>> >>>>> I am trying to get an image (or any binary data) downloaded from a >>>>> >>>> website >>>> >>>> >>>>> and into a jpg file. I expect I will need to use the Byte[] datatype, >>>>> >>>> but I >>>> >>>> >>>>> absolutely can NOT use Callbacks when the data comes in this time. >>>>> >>>>> ... >>>>> >>>>> DO UNTIL(EOF(#Sock)) >>>>> READ #Sock, sBuf, Lof(Sock) >>>>> sTotal &= sBuf >>>>> LOOP >>>>> >>>>> CLOSE #Sock >>>>> >>>>> >>>>> p1 = InStr(sTotal, "\r\n\r\n") >>>>> >>>>> ImgData = Mid(sTotal, p1) >>>>> >>>>> OPEN "localimg.jpg" FOR OUTPUT CREATE AS #myFile >>>>> WRITE #myFile, ImgData, Len(ImgData) >>>>> CLOSE #myFile >>>>> >>>> I think there is a problem with InStr(...,"\r\n\r\n"). >>>> By taking mid$(...,p1), you retain the two CRLFs, which are not good at >>>> the beginning of a jpeg file. >>>> You should get rid of the first 4 characters. May be there are still >>>> other problems, but this is one for sure. >>>> >>>> Regards, >>>> >>>> -- >>>> Doriano Blengino >>>> >>>> "Listen twice before you speak. >>>> This is why we have two ears, but only one mouth." >>>> >>>> >>>> ------------------------------------------------------------------------ >>>> - This SF.Net email is sponsored by the Moblin Your Move Developer's >>>> challenge >>>> Build the coolest Linux based applications with Moblin SDK & win great >>>> prizes >>>> Grand prize is a trip for two to an Open Source event anywhere in the >>>> world >>>> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >> ------------------------------------------------------------------------- >> This SF.Net email is sponsored by the Moblin Your Move Developer's >> challenge Build the coolest Linux based applications with Moblin SDK & win >> great prizes Grand prize is a trip for two to an Open Source event anywhere >> in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > ------------------------------------------------------------------------ > > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user Hi Richard, could you comment on your code? I understand the section "ifbuffer ..." not. Thank you very much Lars From rospolosco at ...152... Thu Dec 11 10:39:19 2008 From: rospolosco at ...152... (Stefano Palmeri) Date: Thu, 11 Dec 2008 10:39:19 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <200812101934.44824.gambas@...1...> References: <493FD4F6.3030308@...221...> <200812101918.27610.rospolosco@...152...> <200812101934.44824.gambas@...1...> Message-ID: <200812111039.19716.rospolosco@...152...> Il mercoled? 10 dicembre 2008 19:34:44 Benoit Minisini ha scritto: > On mercredi 10 d?cembre 2008, Stefano Palmeri wrote: > > Il mercoled? 10 dicembre 2008 15:50:15 Rolf-Werner Eilert ha scritto: > > > Benoit Minisini schrieb: > > > > On mercredi 10 d?cembre 2008, Rolf-Werner Eilert wrote: > > > >> Hi folks, > > > >> > > > >> meanwhile I've understood how to use the TrayIcon, but if my > > > >> application should show only the tray icon, no application window, > > > >> how can I hide the whole thing (except the tray icon, of course)? > > > >> > > > >> Thanks for your advice! > > > >> > > > >> Rolf > > > > > > > > FMain.Hide ? > > > > > > This is what I tried, and I tried setting FMain.Visible = False and so > > > on - no help, it just shows up on screen. > > > > > > It is shown when started in the IDE and when started as an executable > > > as well. > > > > > > Seems this has to do with my KDE version, like the other thing we > > > discussed yesterday... > > > > > > Rolf > > > > I've the same problem under KDE 3.5.9. To solve I use the same > > solution explained by Toni. In a startup module I just put: > > > > --------------------------------- > > PUBLIC SUB Main() > > > > FMain.Visible = FALSE > > > > END > > --------------------------------- > > > > > > Bye, > > > > Stefano > > If your startup class is not a form, you don't have to do FMain.Visible = > FALSE. Just create your TrayIcon there, and show FMain only if needed. > > Regards, Benoit, the Module startup class is a workaround. The little problem here is that if I have a startup class that is a Form with a TrayIcon, is not possible to hide it on start. I don't know if this is a bug of Gambas or KDE. I attached a little example to explain. I would like to iconify the app on startup, I mean I don't want to see the Form, just the icon in KDE kicker. If the the startup class is the FMain form, Me.Hide or ME.Visible are unuseful. The Form is shown. If in the same project you set Module1 as startup class the form finally is not shown and I see only the trayicon as I want. I hope the issue is more clear, even if my english is awful :-) Just run the project and see. The goal is not to show the FMain form on start, without using the Module1 startup class. Tell me where's the error. KDE 3.5.9 QT 3.3.8b Gambas 2.9 rev 1668 Thank you, Stefano -------------- next part -------------- A non-text attachment was scrubbed... Name: trayicon-0.0.1.tar.gz Type: application/x-tgz Size: 8179 bytes Desc: not available URL: From gambas at ...1938... Thu Dec 11 11:00:28 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Thu, 11 Dec 2008 11:00:28 +0100 Subject: [Gambas-user] My own sourceforge address was rejected by sourceforge mailing-list! :-) In-Reply-To: <200812101627.07202.gambas@...1...> References: <200812101627.07202.gambas@...1...> Message-ID: <200812111100.28747.gambas@...1938...> Am Mittwoch, 10. Dezember 2008 16:27:07 schrieb Benoit Minisini: > Funny :-/ Mine too.....yesterday evening at 10:18. From gambas at ...1... Thu Dec 11 11:24:19 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 11 Dec 2008 11:24:19 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <200812111039.19716.rospolosco@...152...> References: <493FD4F6.3030308@...221...> <200812101934.44824.gambas@...1...> <200812111039.19716.rospolosco@...152...> Message-ID: <200812111124.19528.gambas@...1...> On jeudi 11 d?cembre 2008, Stefano Palmeri wrote: > Il mercoled? 10 dicembre 2008 19:34:44 Benoit Minisini ha scritto: > > On mercredi 10 d?cembre 2008, Stefano Palmeri wrote: > > > Il mercoled? 10 dicembre 2008 15:50:15 Rolf-Werner Eilert ha scritto: > > > > Benoit Minisini schrieb: > > > > > On mercredi 10 d?cembre 2008, Rolf-Werner Eilert wrote: > > > > >> Hi folks, > > > > >> > > > > >> meanwhile I've understood how to use the TrayIcon, but if my > > > > >> application should show only the tray icon, no application window, > > > > >> how can I hide the whole thing (except the tray icon, of course)? > > > > >> > > > > >> Thanks for your advice! > > > > >> > > > > >> Rolf > > > > > > > > > > FMain.Hide ? > > > > > > > > This is what I tried, and I tried setting FMain.Visible = False and > > > > so on - no help, it just shows up on screen. > > > > > > > > It is shown when started in the IDE and when started as an executable > > > > as well. > > > > > > > > Seems this has to do with my KDE version, like the other thing we > > > > discussed yesterday... > > > > > > > > Rolf > > > > > > I've the same problem under KDE 3.5.9. To solve I use the same > > > solution explained by Toni. In a startup module I just put: > > > > > > --------------------------------- > > > PUBLIC SUB Main() > > > > > > FMain.Visible = FALSE > > > > > > END > > > --------------------------------- > > > > > > > > > Bye, > > > > > > Stefano > > > > If your startup class is not a form, you don't have to do FMain.Visible = > > FALSE. Just create your TrayIcon there, and show FMain only if needed. > > > > Regards, > > Benoit, the Module startup class is a workaround. > The little problem here is that if I have a startup class that is a Form > with a TrayIcon, is not possible to hide it on start. I don't know if this > is a bug of Gambas or KDE. I attached a little example to explain. > I would like to iconify the app on startup, I mean I don't want to see > the Form, just the icon in KDE kicker. If the the startup class is the > FMain form, Me.Hide or ME.Visible are unuseful. The Form is shown. Yes, this is the purpose of having a startup form: showing it automatically. So having a startup module is not a workaround, it is the normal way for starting the application. :-) Otherwise, to prevent a startup class from being shown, just override its Main() static method defined in the Form class. STATIC PUBLIC SUB Main() ' Loads the hidden instance of FMain without showing it. FMain.Load END I will post a fix so that when the Visible property of the form is set to FALSE, the form is not shown at startup, but loaded. So the workaround above will not be needed anymore! Regards, -- Benoit Minisini From gambas at ...1... Thu Dec 11 11:34:18 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 11 Dec 2008 11:34:18 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <200812111124.19528.gambas@...1...> References: <493FD4F6.3030308@...221...> <200812111039.19716.rospolosco@...152...> <200812111124.19528.gambas@...1...> Message-ID: <200812111134.18854.gambas@...1...> On jeudi 11 d?cembre 2008, Benoit Minisini wrote: > > I will post a fix so that when the Visible property of the form is set to > FALSE, the form is not shown at startup, but loaded. So the workaround > above will not be needed anymore! > > Regards, Fix committed in revision #1735. Regards, -- Benoit Minisini From rospolosco at ...152... Thu Dec 11 11:56:11 2008 From: rospolosco at ...152... (Stefano Palmeri) Date: Thu, 11 Dec 2008 11:56:11 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <200812111134.18854.gambas@...1...> References: <493FD4F6.3030308@...221...> <200812111124.19528.gambas@...1...> <200812111134.18854.gambas@...1...> Message-ID: <200812111156.11229.rospolosco@...152...> Il gioved? 11 dicembre 2008 11:34:18 Benoit Minisini ha scritto: > On jeudi 11 d?cembre 2008, Benoit Minisini wrote: > > I will post a fix so that when the Visible property of the form is set to > > FALSE, the form is not shown at startup, but loaded. So the workaround > > above will not be needed anymore! > > > > Regards, > > Fix committed in revision #1735. > > Regards, Ok. Thank you. Great as usual. Bye, Stefano From eilert-sprachen at ...221... Thu Dec 11 12:44:31 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Thu, 11 Dec 2008 12:44:31 +0100 Subject: [Gambas-user] Hiding FMain not possible? In-Reply-To: <200812111134.18854.gambas@...1...> References: <493FD4F6.3030308@...221...> <200812111039.19716.rospolosco@...152...> <200812111124.19528.gambas@...1...> <200812111134.18854.gambas@...1...> Message-ID: <4940FD1F.4000108@...221...> Benoit Minisini schrieb: > On jeudi 11 d?cembre 2008, Benoit Minisini wrote: >> I will post a fix so that when the Visible property of the form is set to >> FALSE, the form is not shown at startup, but loaded. So the workaround >> above will not be needed anymore! >> >> Regards, > > Fix committed in revision #1735. > > Regards, > Aaaah - runs perfectly now, thanks so much! Rolf From ron at ...1740... Thu Dec 11 12:20:13 2008 From: ron at ...1740... (Ron) Date: Thu, 11 Dec 2008 12:20:13 +0100 Subject: [Gambas-user] Hex string to float Message-ID: <4940F76D.800@...1740...> Hi, Anyone have a routine to convert a hex string to a float? Like these: B6FBEB3A = -0.000007507766895287204 3C5D2104 = 0.01349664106965065 Find lots of vb code, but those use copymem functions. Thanks in advance! Regards, Ron_2nd From gambasforum at ...2019... Thu Dec 11 13:43:10 2008 From: gambasforum at ...2019... (Lars Hoeger) Date: Thu, 11 Dec 2008 13:43:10 +0100 Subject: [Gambas-user] Small window without gadgets In-Reply-To: <493D7A48.1090506@...2015...> References: <49379275.8@...221...> <4937A277.1000004@...2015...> <49380569.6070509@...221...> <49389EDB.7010805@...2015...> <493D4138.7000600@...221...> <4247f5440812080901s2371737oa4726981fdb4fd8b@...627...> <493D5768.7060202@...221...> <493D7A48.1090506@...2015...> Message-ID: <49410ADE.4060702@...2019...> Toni schrieb: > Hi, > Thanks for the information Rolf. Regarding whether it's possible to > control "balloon" pointing upwoards or downwards, sorry but I don't > know either... Besides, I will give a try to Joshua's approach, too! > Regards, > Toni > > En/na Rolf-Werner Eilert ha escrit: > >> Yes, Joshua, this would be exactly the way it was supposed to look like. >> >> Maybe I'll sort this out tomorrow, thanks for the tip! >> >> Rolf >> >> >> Joshua Higgins schrieb: >> >> >>> I know its not the gambas way, but if you have a notification-daemon and >>> dbus running, install the package libnotify-bin. Then you can use the >>> command notify-send to create popups on the screen near the system tray. >>> >>> They look like this: >>> >>> (ubuntu) http://tjeb.nl/Projects/Mailbox_Alert/mailboxalert_example.png >>> (normal) >>> http://wagiaalla.com/blog/wp-content/uploads/2008/03/notify-send.png >>> >>> hth >>> >>> 2008/12/8 Rolf-Werner Eilert >>> >>> >>> >>>> Hi Toni again :-) >>>> >>>> Of course, I knew I'm not that stupid, I got it running, and it's great. >>>> >>>> Do you know if it's possible to control if it points upwards or >>>> downwards? What I found out is, when the control it points to is below >>>> .Height/2 of its parent, it will point upwards, otherwise downwards. And >>>> I cannot control left or right pointing, too. Everything else: great thing. >>>> >>>> In contrary to Benoit, I think it won't replace Message class, however, >>>> because it doesn't have buttons the user can click on, there is no >>>> interaction, so it's limited to displaying something. >>>> >>>> About the Tray Icon, I tried with a small window and a balloon pointing >>>> to its lower right edge. When you drag the window around the screen, the >>>> balloon won't disappear as long as you are dragging but it will change >>>> its pointing edge and form. So I dragged the window into the lower right >>>> edge of the screen, under Kicker and the Tray. The balloon will stop at >>>> the border of Kicker, it won't continue pointing on the window's edge, >>>> neither above nor under the tray. >>>> >>>> So I guess that Kicker and the tray have another level on the screen, >>>> above the windows. Maybe one could change this by some option in the >>>> window manager's control, something like "always there" or "always on >>>> top" such as in Windows. But your idea should work with either option, >>>> of course. >>>> >>>> Sorry I can't help any more, but thank you for pointing me to the >>>> balloon thing :-) >>>> >>>> Rolf >>>> >>>> >>>> >>>> Toni schrieb: >>>> >>>> >>>>> Hi Rolf again, >>>>> By ballon I meant "gb.form.ballon", a Message like class. >>>>> I couldn't get it pointing to a Tray Icon, but otherwise I find it >>>>> pretty nice and unobtrusive :) >>>>> Regards, >>>>> Toni >>>>> >>>>> >>>>> >>>>> En/na Rolf-Werner Eilert ha escrit: >>>>> >>>>> >>>>>> Hi Toni, >>>>>> >>>>>> Toni schrieb: >>>>>> >>>>>> >>>>>> >>>>>>> Hi Rolf, >>>>>>> I'm new to Gambas so maybe other will tell otherwise..., but I think >>>>>>> >>>>>>> >>>>>>> >>>>>> never mind :-) I've been into Gambas for quite some time now, but I'm >>>>>> still far away from being an expert... >>>>>> >>>>>> >>>>>> >>>>>> >>>>>>> "Ballon" is what you are looking for. >>>>>>> >>>>>>> >>>>>>> >>>>>> Didn't find that - is it one of the examples? >>>>>> >>>>>> In the examples, I did find the thing with the transparent clock and the >>>>>> other clock example. But those seem to have to do with transparency >>>>>> rather than with just a window without gadgets. >>>>>> >>>>>> Though I tried to do the same and failed - I don't know why my windows >>>>>> always have gadgets, even when I say "Border - None", and I cannot make >>>>>> out any other difference between my own programs and the examples >>>>>> (except the drawing routines). The examples run flawlessly here, my own >>>>>> programs always show standard windows. >>>>>> >>>>>> So, where's the trick? >>>>>> >>>>>> >>>>>> Regards, >>>>>> >>>>>> Rolf >>>>>> >>>>>> >>>>>> >>>>>> >>>>>>> The only problem is that I haven't been able to get it working pointing >>>>>>> to a TrayIcon (that low right edge of the screen you mention). Hope >>>>>>> >>>>>>> >>>> it >>>> >>>> >>>>>>> helps and, in anycase, if there is a better solution I'll be gald to >>>>>>> hear from it too. >>>>>>> >>>>>>> Regards, >>>>>>> Toni >>>>>>> >>>>>>> En/na Rolf-Werner Eilert ha escrit: >>>>>>> >>>>>>> >>>>>>> >>>>>>>> Hi everyone out there... >>>>>>>> >>>>>>>> The question is simple: Is it possible to make a small window without >>>>>>>> any gadgets appear and disappear after some seconds showing a small >>>>>>>> >>>>>>>> >>>> hint >>>> >>>> >>>>>>>> such as "you got new messages..."? >>>>>>>> >>>>>>>> What I want is something like these hints Thunderbird or the Suse >>>>>>>> >>>>>>>> >>>> update >>>> >>>> >>>>>>>> client produce at the lower right edge of the screen, for my own >>>>>>>> messenger app here in our firm. >>>>>>>> >>>>>>>> Thanks for all ideas. >>>>>>>> >>>>>>>> Regards, >>>>>>>> >>>>>>>> Rolf >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> >>>> ------------------------------------------------------------------------- >>>> >>>> >>>>>> This SF.Net email is sponsored by the Moblin Your Move Developer's >>>>>> >>>>>> >>>> challenge >>>> >>>> >>>>>> Build the coolest Linux based applications with Moblin SDK & win great >>>>>> >>>>>> >>>> prizes >>>> >>>> >>>>>> Grand prize is a trip for two to an Open Source event anywhere in the >>>>>> >>>>>> >>>> world >>>> >>>> >>>>>> http://moblin-contest.org/redirect.php?banner_id=100&url=/ >>>>>> _______________________________________________ >>>>>> Gambas-user mailing list >>>>>> Gambas-user at lists.sourceforge.net >>>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>>> >>>>>> >>>>>> >>>> ------------------------------------------------------------------------------ >>>> >>>> >>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, >>>>> >>>>> >>>> Nevada. >>>> >>>> >>>>> The future of the web can't happen without you. Join us at MIX09 to help >>>>> pave the way to the Next Web now. Learn more and register at >>>>> >>>>> >>>>> >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>> >>>> >>>>> _______________________________________________ >>>>> Gambas-user mailing list >>>>> Gambas-user at lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>> >>>>> >>>>> >>>> ------------------------------------------------------------------------------ >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>> The future of the web can't happen without you. Join us at MIX09 to help >>>> pave the way to the Next Web now. Learn more and register at >>>> >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>>> >>>> >>> >>> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > If I understood you correctly, you want a window without a border and it's buttons. Did you try the MASK option of the form? Here you can choose a picture which is shown instead of the normal window. If you use transparency in this picture, you can create round corners and much more funny things. Regards, Lars From nando_f at ...951... Thu Dec 11 19:20:50 2008 From: nando_f at ...951... (nando) Date: Thu, 11 Dec 2008 13:20:50 -0500 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> Message-ID: <20081211181151.M51711@...951...> Perhaps the following ideas... Every step in the wizard has an associated form for whatever it does for that step. Every form has a SUB for 'backwards' and 'forwards so that when NEXT is clicked, the forwards code runs, which is whatever is required for moving to the next form (ie: perform work, verify info, hide form, the activate 'next' form) when BACK is clicked, the backwards code runs, which is whatever to undo this step (if needed), hide form, activate 'back' form. Each form knows how to go back one step, and go forward one step. You would have to tell the Next and BAck buttons which forwards and backwards sub to run...you could place in NEXT.tag and BACK.tag the form or info required to properly run the correct code. This would be modular so each form takes care of things. Or, the list of wizard steps could be in a global string array with the name of the form and simply step through the index. -Fernando ---------- Original Message ----------- From: "M0E Lnx" To: "mailing list for gambas users" Sent: Wed, 10 Dec 2008 20:39:45 +0000 Subject: [Gambas-user] Emulating wizard Back/Next navigation > So I set myself to create a program that acts like a wizard, but chose > not to use the wizard object because well, there is just too many > variables here, and there is more than one way to get to the end, > Depending on user input. > > So what I did was create a navigation tool bar at the bottom of FMain > this toolbar has a BACK, EXIT, and a NEXT button. > > I have a workspace object above it which will host other forms via > each forms .Reparent method. > > Can anyone suggest a way to make reverse and forward navigation on such a setup? > > I have created a small project what I'm trying to do... See attachment > > Any help is appreciated > > Thanks ------- End of Original Message ------- From m0e.lnx at ...626... Thu Dec 11 20:40:42 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Thu, 11 Dec 2008 19:40:42 +0000 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <20081211181151.M51711@...951...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> Message-ID: <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> I have to say, the array idea makes more sense to me, simply because otherwise, it'll be hard to tell the next and back buttons which sub to run. I have tried an array, but object array rather than string array. The idea is that every form that gets opened leaves a footprint in this object array for instance, the form's open() event would have something like this IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) this makes reverse navigation possible by indexing the array or a similar method. However, I am not able to work out all the bugs resulting from this because it gets crazy when you try to move back, then forward... then back... ends up in a crash almost every time Can someone work out a sample I can use? On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: > Perhaps the following ideas... > Every step in the wizard has an associated form for whatever it does for that step. > Every form has a SUB for 'backwards' and 'forwards so that > when NEXT is clicked, the forwards code runs, which is whatever > is required for moving to the next form (ie: perform work, verify info, > hide form, the activate 'next' form) > when BACK is clicked, the backwards code runs, which is whatever to > undo this step (if needed), hide form, activate 'back' form. > Each form knows how to go back one step, and go forward one step. > You would have to tell the Next and BAck buttons which forwards and backwards > sub to run...you could place in NEXT.tag and BACK.tag the form or info required > to properly run the correct code. This would be modular so each form takes > care of things. > Or, the list of wizard steps could be in a global string array with the name > of the form and simply step through the index. > -Fernando > > > ---------- Original Message ----------- > From: "M0E Lnx" > To: "mailing list for gambas users" > Sent: Wed, 10 Dec 2008 20:39:45 +0000 > Subject: [Gambas-user] Emulating wizard Back/Next navigation > >> So I set myself to create a program that acts like a wizard, but chose >> not to use the wizard object because well, there is just too many >> variables here, and there is more than one way to get to the end, >> Depending on user input. >> >> So what I did was create a navigation tool bar at the bottom of FMain >> this toolbar has a BACK, EXIT, and a NEXT button. >> >> I have a workspace object above it which will host other forms via >> each forms .Reparent method. >> >> Can anyone suggest a way to make reverse and forward navigation on such a setup? >> >> I have created a small project what I'm trying to do... See attachment >> >> Any help is appreciated >> >> Thanks > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From simonart.dominique at ...11... Thu Dec 11 21:23:20 2008 From: simonart.dominique at ...11... (Simonart Dominique) Date: Thu, 11 Dec 2008 21:23:20 +0100 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> Message-ID: <494176B8.7080804@...11...> M0E Lnx a ?crit : > I have to say, the array idea makes more sense to me, simply because > otherwise, it'll be hard to tell the next and back buttons which sub > to run. > > I have tried an array, but object array rather than string array. > > The idea is that every form that gets opened leaves a footprint in > this object array > for instance, the form's open() event would have something like this > > IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) > > this makes reverse navigation possible by indexing the array or a > similar method. However, I am not able to work out all the bugs > resulting from this because it gets crazy when you try to move back, > then forward... then back... ends up in a crash almost every time > > Can someone work out a sample I can use? > > > > > > On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: >> Perhaps the following ideas... >> Every step in the wizard has an associated form for whatever it does for that step. >> Every form has a SUB for 'backwards' and 'forwards so that >> when NEXT is clicked, the forwards code runs, which is whatever >> is required for moving to the next form (ie: perform work, verify info, >> hide form, the activate 'next' form) >> when BACK is clicked, the backwards code runs, which is whatever to >> undo this step (if needed), hide form, activate 'back' form. >> Each form knows how to go back one step, and go forward one step. >> You would have to tell the Next and BAck buttons which forwards and backwards >> sub to run...you could place in NEXT.tag and BACK.tag the form or info required >> to properly run the correct code. This would be modular so each form takes >> care of things. >> Or, the list of wizard steps could be in a global string array with the name >> of the form and simply step through the index. >> -Fernando >> >> >> ---------- Original Message ----------- >> From: "M0E Lnx" >> To: "mailing list for gambas users" >> Sent: Wed, 10 Dec 2008 20:39:45 +0000 >> Subject: [Gambas-user] Emulating wizard Back/Next navigation >> >>> So I set myself to create a program that acts like a wizard, but chose >>> not to use the wizard object because well, there is just too many >>> variables here, and there is more than one way to get to the end, >>> Depending on user input. >>> >>> So what I did was create a navigation tool bar at the bottom of FMain >>> this toolbar has a BACK, EXIT, and a NEXT button. >>> >>> I have a workspace object above it which will host other forms via >>> each forms .Reparent method. >>> >>> Can anyone suggest a way to make reverse and forward navigation on such a setup? >>> >>> I have created a small project what I'm trying to do... See attachment >>> >>> Any help is appreciated >>> >>> Thanks >> ------- End of Original Message ------- >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > I think BACK has to be only an "undo" process, and NEXT is the logical next state depending on the datas already collected. If 2 forms could result from an actual status, then you have to review the logical chain. my two cents :) Dominique Simonart From m0e.lnx at ...626... Thu Dec 11 21:50:38 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Thu, 11 Dec 2008 14:50:38 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <494176B8.7080804@...11...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> Message-ID: <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> Exactly. The forward navigation depends on the user input, so it could jump from Form1 to Form3 and then to Form2 ans do on... So if we leave a footprint in the array, I think it *should* be easy to reverse the process indeed sort of like an "undo" process. But I'm not sure exactly what the best way to do the reverse is... should I index the array? or try to find the current form in the array and then just use the current forms.index in the array - 1 ? I've been fidling with this for a while... and it works perfecly in my mind... but can't really make it work on the IDE :( On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique wrote: > M0E Lnx a ?crit : >> I have to say, the array idea makes more sense to me, simply because >> otherwise, it'll be hard to tell the next and back buttons which sub >> to run. >> >> I have tried an array, but object array rather than string array. >> >> The idea is that every form that gets opened leaves a footprint in >> this object array >> for instance, the form's open() event would have something like this >> >> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) >> >> this makes reverse navigation possible by indexing the array or a >> similar method. However, I am not able to work out all the bugs >> resulting from this because it gets crazy when you try to move back, >> then forward... then back... ends up in a crash almost every time >> >> Can someone work out a sample I can use? >> >> >> >> >> >> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: >>> Perhaps the following ideas... >>> Every step in the wizard has an associated form for whatever it does for that step. >>> Every form has a SUB for 'backwards' and 'forwards so that >>> when NEXT is clicked, the forwards code runs, which is whatever >>> is required for moving to the next form (ie: perform work, verify info, >>> hide form, the activate 'next' form) >>> when BACK is clicked, the backwards code runs, which is whatever to >>> undo this step (if needed), hide form, activate 'back' form. >>> Each form knows how to go back one step, and go forward one step. >>> You would have to tell the Next and BAck buttons which forwards and backwards >>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required >>> to properly run the correct code. This would be modular so each form takes >>> care of things. >>> Or, the list of wizard steps could be in a global string array with the name >>> of the form and simply step through the index. >>> -Fernando >>> >>> >>> ---------- Original Message ----------- >>> From: "M0E Lnx" >>> To: "mailing list for gambas users" >>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 >>> Subject: [Gambas-user] Emulating wizard Back/Next navigation >>> >>>> So I set myself to create a program that acts like a wizard, but chose >>>> not to use the wizard object because well, there is just too many >>>> variables here, and there is more than one way to get to the end, >>>> Depending on user input. >>>> >>>> So what I did was create a navigation tool bar at the bottom of FMain >>>> this toolbar has a BACK, EXIT, and a NEXT button. >>>> >>>> I have a workspace object above it which will host other forms via >>>> each forms .Reparent method. >>>> >>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? >>>> >>>> I have created a small project what I'm trying to do... See attachment >>>> >>>> Any help is appreciated >>>> >>>> Thanks >>> ------- End of Original Message ------- >>> >>> >>> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> > > I think BACK has to be only an "undo" process, and NEXT is > the logical next state depending on the datas already > collected. If 2 forms could result from an actual status, > then you have to review the logical chain. > > my two cents :) > Dominique Simonart > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From nando_f at ...951... Thu Dec 11 22:04:28 2008 From: nando_f at ...951... (nando) Date: Thu, 11 Dec 2008 16:04:28 -0500 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> Message-ID: <20081211205932.M27897@...951...> To go back, you have to 'undo' all the things needed to properly go forward. So, in form5 (ie step5) you would have code to run to 'undo' what you did to get to step6...so when step6 has to go back, you'll run step5's 'undo' code. something psuedo like... IF 'BACK' was clicked THEN hide form (the current form pointed to by your pointer which is Form6) DEC your array pointer (which is now for Form5) run the sub called UNDO unhide form (the current form pointed to is now Form5) Endif ---------- Original Message ----------- From: "M0E Lnx" To: "mailing list for gambas users" Sent: Thu, 11 Dec 2008 14:50:38 -0600 Subject: Re: [Gambas-user] Emulating wizard Back/Next navigation > Exactly. > > The forward navigation depends on the user input, so it could jump > from Form1 to Form3 and then to Form2 ans do on... > > So if we leave a footprint in the array, I think it *should* be easy > to reverse the process indeed sort of like an "undo" process. > > But I'm not sure exactly what the best way to do the reverse is... > should I index the array? or try to find the current form in the array > and then just use the current forms.index in the array - 1 ? > > I've been fidling with this for a while... and it works perfecly in my > mind... but can't really make it work on the IDE :( > > On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique > wrote: > > M0E Lnx a ?crit : > >> I have to say, the array idea makes more sense to me, simply because > >> otherwise, it'll be hard to tell the next and back buttons which sub > >> to run. > >> > >> I have tried an array, but object array rather than string array. > >> > >> The idea is that every form that gets opened leaves a footprint in > >> this object array > >> for instance, the form's open() event would have something like this > >> > >> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) > >> > >> this makes reverse navigation possible by indexing the array or a > >> similar method. However, I am not able to work out all the bugs > >> resulting from this because it gets crazy when you try to move back, > >> then forward... then back... ends up in a crash almost every time > >> > >> Can someone work out a sample I can use? > >> > >> > >> > >> > >> > >> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: > >>> Perhaps the following ideas... > >>> Every step in the wizard has an associated form for whatever it does for that step. > >>> Every form has a SUB for 'backwards' and 'forwards so that > >>> when NEXT is clicked, the forwards code runs, which is whatever > >>> is required for moving to the next form (ie: perform work, verify info, > >>> hide form, the activate 'next' form) > >>> when BACK is clicked, the backwards code runs, which is whatever to > >>> undo this step (if needed), hide form, activate 'back' form. > >>> Each form knows how to go back one step, and go forward one step. > >>> You would have to tell the Next and BAck buttons which forwards and backwards > >>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required > >>> to properly run the correct code. This would be modular so each form takes > >>> care of things. > >>> Or, the list of wizard steps could be in a global string array with the name > >>> of the form and simply step through the index. > >>> -Fernando > >>> > >>> > >>> ---------- Original Message ----------- > >>> From: "M0E Lnx" > >>> To: "mailing list for gambas users" > >>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 > >>> Subject: [Gambas-user] Emulating wizard Back/Next navigation > >>> > >>>> So I set myself to create a program that acts like a wizard, but chose > >>>> not to use the wizard object because well, there is just too many > >>>> variables here, and there is more than one way to get to the end, > >>>> Depending on user input. > >>>> > >>>> So what I did was create a navigation tool bar at the bottom of FMain > >>>> this toolbar has a BACK, EXIT, and a NEXT button. > >>>> > >>>> I have a workspace object above it which will host other forms via > >>>> each forms .Reparent method. > >>>> > >>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? > >>>> > >>>> I have created a small project what I'm trying to do... See attachment > >>>> > >>>> Any help is appreciated > >>>> > >>>> Thanks > >>> ------- End of Original Message ------- > >>> > >>> > >>> ------------------------------------------------------------------------------ > >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >>> The future of the web can't happen without you. Join us at MIX09 to help > >>> pave the way to the Next Web now. Learn more and register at > >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >>> _______________________________________________ > >>> Gambas-user mailing list > >>> Gambas-user at lists.sourceforge.net > >>> https://lists.sourceforge.net/lists/listinfo/gambas-user > >>> > >> > >> ------------------------------------------------------------------------------ > >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >> The future of the web can't happen without you. Join us at MIX09 to help > >> pave the way to the Next Web now. Learn more and register at > >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > >> > > > > I think BACK has to be only an "undo" process, and NEXT is > > the logical next state depending on the datas already > > collected. If 2 forms could result from an actual status, > > then you have to review the logical chain. > > > > my two cents :) > > Dominique Simonart > > > > > > ------------------------------------------------------------------------------ > > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > > The future of the web can't happen without you. Join us at MIX09 to help > > pave the way to the Next Web now. Learn more and register at > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From m0e.lnx at ...626... Thu Dec 11 22:17:39 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Thu, 11 Dec 2008 15:17:39 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <20081211205932.M27897@...951...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <20081211205932.M27897@...951...> Message-ID: <1f1e8c1b0812111317t507d9606u3ae6f986c8921869@...627...> Can you try to work a sample?? On Thu, Dec 11, 2008 at 3:04 PM, nando wrote: > To go back, you have to 'undo' all the things needed to properly go forward. > So, in form5 (ie step5) you would have code to run to 'undo' what you did to > get to step6...so when step6 has to go back, you'll run step5's 'undo' code. > > something psuedo like... > IF 'BACK' was clicked THEN > hide form (the current form pointed to by your pointer which is Form6) > DEC your array pointer (which is now for Form5) > run the sub called UNDO > unhide form (the current form pointed to is now Form5) > Endif > > > ---------- Original Message ----------- > From: "M0E Lnx" > To: "mailing list for gambas users" > Sent: Thu, 11 Dec 2008 14:50:38 -0600 > Subject: Re: [Gambas-user] Emulating wizard Back/Next navigation > >> Exactly. >> >> The forward navigation depends on the user input, so it could jump >> from Form1 to Form3 and then to Form2 ans do on... >> >> So if we leave a footprint in the array, I think it *should* be easy >> to reverse the process indeed sort of like an "undo" process. >> >> But I'm not sure exactly what the best way to do the reverse is... >> should I index the array? or try to find the current form in the array >> and then just use the current forms.index in the array - 1 ? >> >> I've been fidling with this for a while... and it works perfecly in my >> mind... but can't really make it work on the IDE :( >> >> On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique >> wrote: >> > M0E Lnx a ?crit : >> >> I have to say, the array idea makes more sense to me, simply because >> >> otherwise, it'll be hard to tell the next and back buttons which sub >> >> to run. >> >> >> >> I have tried an array, but object array rather than string array. >> >> >> >> The idea is that every form that gets opened leaves a footprint in >> >> this object array >> >> for instance, the form's open() event would have something like this >> >> >> >> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) >> >> >> >> this makes reverse navigation possible by indexing the array or a >> >> similar method. However, I am not able to work out all the bugs >> >> resulting from this because it gets crazy when you try to move back, >> >> then forward... then back... ends up in a crash almost every time >> >> >> >> Can someone work out a sample I can use? >> >> >> >> >> >> >> >> >> >> >> >> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: >> >>> Perhaps the following ideas... >> >>> Every step in the wizard has an associated form for whatever it does for that step. >> >>> Every form has a SUB for 'backwards' and 'forwards so that >> >>> when NEXT is clicked, the forwards code runs, which is whatever >> >>> is required for moving to the next form (ie: perform work, verify info, >> >>> hide form, the activate 'next' form) >> >>> when BACK is clicked, the backwards code runs, which is whatever to >> >>> undo this step (if needed), hide form, activate 'back' form. >> >>> Each form knows how to go back one step, and go forward one step. >> >>> You would have to tell the Next and BAck buttons which forwards and backwards >> >>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required >> >>> to properly run the correct code. This would be modular so each form takes >> >>> care of things. >> >>> Or, the list of wizard steps could be in a global string array with the name >> >>> of the form and simply step through the index. >> >>> -Fernando >> >>> >> >>> >> >>> ---------- Original Message ----------- >> >>> From: "M0E Lnx" >> >>> To: "mailing list for gambas users" >> >>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 >> >>> Subject: [Gambas-user] Emulating wizard Back/Next navigation >> >>> >> >>>> So I set myself to create a program that acts like a wizard, but chose >> >>>> not to use the wizard object because well, there is just too many >> >>>> variables here, and there is more than one way to get to the end, >> >>>> Depending on user input. >> >>>> >> >>>> So what I did was create a navigation tool bar at the bottom of FMain >> >>>> this toolbar has a BACK, EXIT, and a NEXT button. >> >>>> >> >>>> I have a workspace object above it which will host other forms via >> >>>> each forms .Reparent method. >> >>>> >> >>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? >> >>>> >> >>>> I have created a small project what I'm trying to do... See attachment >> >>>> >> >>>> Any help is appreciated >> >>>> >> >>>> Thanks >> >>> ------- End of Original Message ------- >> >>> >> >>> >> >>> ------------------------------------------------------------------------------ >> >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> >>> The future of the web can't happen without you. Join us at MIX09 to help >> >>> pave the way to the Next Web now. Learn more and register at >> >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> >>> _______________________________________________ >> >>> Gambas-user mailing list >> >>> Gambas-user at lists.sourceforge.net >> >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >>> >> >> >> >> ------------------------------------------------------------------------------ >> >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> >> The future of the web can't happen without you. Join us at MIX09 to help >> >> pave the way to the Next Web now. Learn more and register at >> >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> >> _______________________________________________ >> >> Gambas-user mailing list >> >> Gambas-user at lists.sourceforge.net >> >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> >> >> >> > >> > I think BACK has to be only an "undo" process, and NEXT is >> > the logical next state depending on the datas already >> > collected. If 2 forms could result from an actual status, >> > then you have to review the logical chain. >> > >> > my two cents :) >> > Dominique Simonart >> > >> > >> > ------------------------------------------------------------------------------ >> > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> > The future of the web can't happen without you. Join us at MIX09 to help >> > pave the way to the Next Web now. Learn more and register at >> > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> > _______________________________________________ >> > Gambas-user mailing list >> > Gambas-user at lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/gambas-user >> > >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From simonart.dominique at ...11... Thu Dec 11 22:40:54 2008 From: simonart.dominique at ...11... (Simonart Dominique) Date: Thu, 11 Dec 2008 22:40:54 +0100 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> Message-ID: <494188E6.6020604@...11...> M0E Lnx a ?crit : > Exactly. > > The forward navigation depends on the user input, so it could jump > from Form1 to Form3 and then to Form2 ans do on... > > So if we leave a footprint in the array, I think it *should* be easy > to reverse the process indeed sort of like an "undo" process. > > But I'm not sure exactly what the best way to do the reverse is... > should I index the array? or try to find the current form in the array > and then just use the current forms.index in the array - 1 ? > > I've been fidling with this for a while... and it works perfecly in my > mind... but can't really make it work on the IDE :( > > On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique > wrote: >> M0E Lnx a ?crit : >>> I have to say, the array idea makes more sense to me, simply because >>> otherwise, it'll be hard to tell the next and back buttons which sub >>> to run. >>> >>> I have tried an array, but object array rather than string array. >>> >>> The idea is that every form that gets opened leaves a footprint in >>> this object array >>> for instance, the form's open() event would have something like this >>> >>> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) >>> >>> this makes reverse navigation possible by indexing the array or a >>> similar method. However, I am not able to work out all the bugs >>> resulting from this because it gets crazy when you try to move back, >>> then forward... then back... ends up in a crash almost every time >>> >>> Can someone work out a sample I can use? >>> >>> >>> >>> >>> >>> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: >>>> Perhaps the following ideas... >>>> Every step in the wizard has an associated form for whatever it does for that step. >>>> Every form has a SUB for 'backwards' and 'forwards so that >>>> when NEXT is clicked, the forwards code runs, which is whatever >>>> is required for moving to the next form (ie: perform work, verify info, >>>> hide form, the activate 'next' form) >>>> when BACK is clicked, the backwards code runs, which is whatever to >>>> undo this step (if needed), hide form, activate 'back' form. >>>> Each form knows how to go back one step, and go forward one step. >>>> You would have to tell the Next and BAck buttons which forwards and backwards >>>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required >>>> to properly run the correct code. This would be modular so each form takes >>>> care of things. >>>> Or, the list of wizard steps could be in a global string array with the name >>>> of the form and simply step through the index. >>>> -Fernando >>>> >>>> >>>> ---------- Original Message ----------- >>>> From: "M0E Lnx" >>>> To: "mailing list for gambas users" >>>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 >>>> Subject: [Gambas-user] Emulating wizard Back/Next navigation >>>> >>>>> So I set myself to create a program that acts like a wizard, but chose >>>>> not to use the wizard object because well, there is just too many >>>>> variables here, and there is more than one way to get to the end, >>>>> Depending on user input. >>>>> >>>>> So what I did was create a navigation tool bar at the bottom of FMain >>>>> this toolbar has a BACK, EXIT, and a NEXT button. >>>>> >>>>> I have a workspace object above it which will host other forms via >>>>> each forms .Reparent method. >>>>> >>>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? >>>>> >>>>> I have created a small project what I'm trying to do... See attachment >>>>> >>>>> Any help is appreciated >>>>> >>>>> Thanks >>>> ------- End of Original Message ------- >>>> >>>> >>>> ------------------------------------------------------------------------------ >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>> The future of the web can't happen without you. Join us at MIX09 to help >>>> pave the way to the Next Web now. Learn more and register at >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>> >> I think BACK has to be only an "undo" process, and NEXT is >> the logical next state depending on the datas already >> collected. If 2 forms could result from an actual status, >> then you have to review the logical chain. >> >> my two cents :) >> Dominique Simonart >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > The simpler is often the better :) May be you could write two procedures sort of PUSH and POP routines. Since the datas to keep should be limited enough, the better is to store all of them at each step with the last Object/form name. Since all data are implicitly correct (they passed correctly the preceeding step!) this is just a matter of display the form and to restore all the variables with the POPed values without control. This suppose of course the BACK could only reverse step by step. If you add something else in the BACK process, you could not be sure to return on the same initial state. Dominique Simonart From m0e.lnx at ...626... Thu Dec 11 23:33:30 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Thu, 11 Dec 2008 16:33:30 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <494188E6.6020604@...11...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <494188E6.6020604@...11...> Message-ID: <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> I just can't seem to completely wrap my mind around this one. It really doesn't matter if i return to the same state or not... as long as I return there. it gets complicated when for instance, you go in a sequence from 1, 2, 3 then you back up to 2... change something in 2 that now makes you skip 3 and jump to 4 or 5. On Thu, Dec 11, 2008 at 3:40 PM, Simonart Dominique wrote: > M0E Lnx a ?crit : >> Exactly. >> >> The forward navigation depends on the user input, so it could jump >> from Form1 to Form3 and then to Form2 ans do on... >> >> So if we leave a footprint in the array, I think it *should* be easy >> to reverse the process indeed sort of like an "undo" process. >> >> But I'm not sure exactly what the best way to do the reverse is... >> should I index the array? or try to find the current form in the array >> and then just use the current forms.index in the array - 1 ? >> >> I've been fidling with this for a while... and it works perfecly in my >> mind... but can't really make it work on the IDE :( >> >> On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique >> wrote: >>> M0E Lnx a ?crit : >>>> I have to say, the array idea makes more sense to me, simply because >>>> otherwise, it'll be hard to tell the next and back buttons which sub >>>> to run. >>>> >>>> I have tried an array, but object array rather than string array. >>>> >>>> The idea is that every form that gets opened leaves a footprint in >>>> this object array >>>> for instance, the form's open() event would have something like this >>>> >>>> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) >>>> >>>> this makes reverse navigation possible by indexing the array or a >>>> similar method. However, I am not able to work out all the bugs >>>> resulting from this because it gets crazy when you try to move back, >>>> then forward... then back... ends up in a crash almost every time >>>> >>>> Can someone work out a sample I can use? >>>> >>>> >>>> >>>> >>>> >>>> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: >>>>> Perhaps the following ideas... >>>>> Every step in the wizard has an associated form for whatever it does for that step. >>>>> Every form has a SUB for 'backwards' and 'forwards so that >>>>> when NEXT is clicked, the forwards code runs, which is whatever >>>>> is required for moving to the next form (ie: perform work, verify info, >>>>> hide form, the activate 'next' form) >>>>> when BACK is clicked, the backwards code runs, which is whatever to >>>>> undo this step (if needed), hide form, activate 'back' form. >>>>> Each form knows how to go back one step, and go forward one step. >>>>> You would have to tell the Next and BAck buttons which forwards and backwards >>>>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required >>>>> to properly run the correct code. This would be modular so each form takes >>>>> care of things. >>>>> Or, the list of wizard steps could be in a global string array with the name >>>>> of the form and simply step through the index. >>>>> -Fernando >>>>> >>>>> >>>>> ---------- Original Message ----------- >>>>> From: "M0E Lnx" >>>>> To: "mailing list for gambas users" >>>>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 >>>>> Subject: [Gambas-user] Emulating wizard Back/Next navigation >>>>> >>>>>> So I set myself to create a program that acts like a wizard, but chose >>>>>> not to use the wizard object because well, there is just too many >>>>>> variables here, and there is more than one way to get to the end, >>>>>> Depending on user input. >>>>>> >>>>>> So what I did was create a navigation tool bar at the bottom of FMain >>>>>> this toolbar has a BACK, EXIT, and a NEXT button. >>>>>> >>>>>> I have a workspace object above it which will host other forms via >>>>>> each forms .Reparent method. >>>>>> >>>>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? >>>>>> >>>>>> I have created a small project what I'm trying to do... See attachment >>>>>> >>>>>> Any help is appreciated >>>>>> >>>>>> Thanks >>>>> ------- End of Original Message ------- >>>>> >>>>> >>>>> ------------------------------------------------------------------------------ >>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>>> The future of the web can't happen without you. Join us at MIX09 to help >>>>> pave the way to the Next Web now. Learn more and register at >>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>>> _______________________________________________ >>>>> Gambas-user mailing list >>>>> Gambas-user at lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>> >>>> ------------------------------------------------------------------------------ >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>> The future of the web can't happen without you. Join us at MIX09 to help >>>> pave the way to the Next Web now. Learn more and register at >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>>> >>> I think BACK has to be only an "undo" process, and NEXT is >>> the logical next state depending on the datas already >>> collected. If 2 forms could result from an actual status, >>> then you have to review the logical chain. >>> >>> my two cents :) >>> Dominique Simonart >>> >>> >>> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> > > The simpler is often the better :) May be you could write > two procedures sort of PUSH and POP routines. Since the > datas to keep should be limited enough, the better is to > store all of them at each step with the last Object/form > name. Since all data are implicitly correct (they passed > correctly the preceeding step!) this is just a matter of > display the form and to restore all the variables with the > POPed values without control. This suppose of course the > BACK could only reverse step by step. If you add something > else in the BACK process, you could not be sure to return on > the same initial state. > > Dominique Simonart > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From simonart.dominique at ...11... Fri Dec 12 04:11:24 2008 From: simonart.dominique at ...11... (Dominique SIMONART) Date: Fri, 12 Dec 2008 04:11:24 +0100 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> Message-ID: <4941D65C.3060705@...11...> M0E Lnx a ?crit : > I just can't seem to completely wrap my mind around this one. > > It really doesn't matter if i return to the same state or not... as > long as I return there. > > it gets complicated when for instance, you go in a sequence from 1, 2, > 3 then you back up to 2... change something in 2 that now makes you > skip 3 and jump to 4 or 5. > > On Thu, Dec 11, 2008 at 3:40 PM, Simonart Dominique > wrote: > >> M0E Lnx a ?crit : >> >>> Exactly. >>> >>> The forward navigation depends on the user input, so it could jump >>> from Form1 to Form3 and then to Form2 ans do on... >>> >>> So if we leave a footprint in the array, I think it *should* be easy >>> to reverse the process indeed sort of like an "undo" process. >>> >>> But I'm not sure exactly what the best way to do the reverse is... >>> should I index the array? or try to find the current form in the array >>> and then just use the current forms.index in the array - 1 ? >>> >>> I've been fidling with this for a while... and it works perfecly in my >>> mind... but can't really make it work on the IDE :( >>> >>> On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique >>> wrote: >>> >>>> M0E Lnx a ?crit : >>>> >>>>> I have to say, the array idea makes more sense to me, simply because >>>>> otherwise, it'll be hard to tell the next and back buttons which sub >>>>> to run. >>>>> >>>>> I have tried an array, but object array rather than string array. >>>>> >>>>> The idea is that every form that gets opened leaves a footprint in >>>>> this object array >>>>> for instance, the form's open() event would have something like this >>>>> >>>>> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) >>>>> >>>>> this makes reverse navigation possible by indexing the array or a >>>>> similar method. However, I am not able to work out all the bugs >>>>> resulting from this because it gets crazy when you try to move back, >>>>> then forward... then back... ends up in a crash almost every time >>>>> >>>>> Can someone work out a sample I can use? >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: >>>>> >>>>>> Perhaps the following ideas... >>>>>> Every step in the wizard has an associated form for whatever it does for that step. >>>>>> Every form has a SUB for 'backwards' and 'forwards so that >>>>>> when NEXT is clicked, the forwards code runs, which is whatever >>>>>> is required for moving to the next form (ie: perform work, verify info, >>>>>> hide form, the activate 'next' form) >>>>>> when BACK is clicked, the backwards code runs, which is whatever to >>>>>> undo this step (if needed), hide form, activate 'back' form. >>>>>> Each form knows how to go back one step, and go forward one step. >>>>>> You would have to tell the Next and BAck buttons which forwards and backwards >>>>>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required >>>>>> to properly run the correct code. This would be modular so each form takes >>>>>> care of things. >>>>>> Or, the list of wizard steps could be in a global string array with the name >>>>>> of the form and simply step through the index. >>>>>> -Fernando >>>>>> >>>>>> >>>>>> ---------- Original Message ----------- >>>>>> From: "M0E Lnx" >>>>>> To: "mailing list for gambas users" >>>>>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 >>>>>> Subject: [Gambas-user] Emulating wizard Back/Next navigation >>>>>> >>>>>> >>>>>>> So I set myself to create a program that acts like a wizard, but chose >>>>>>> not to use the wizard object because well, there is just too many >>>>>>> variables here, and there is more than one way to get to the end, >>>>>>> Depending on user input. >>>>>>> >>>>>>> So what I did was create a navigation tool bar at the bottom of FMain >>>>>>> this toolbar has a BACK, EXIT, and a NEXT button. >>>>>>> >>>>>>> I have a workspace object above it which will host other forms via >>>>>>> each forms .Reparent method. >>>>>>> >>>>>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? >>>>>>> >>>>>>> I have created a small project what I'm trying to do... See attachment >>>>>>> >>>>>>> Any help is appreciated >>>>>>> >>>>>>> Thanks >>>>>>> >>>>>> ------- End of Original Message ------- >>>>>> >>>>>> >>>>>> ------------------------------------------------------------------------------ >>>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>>>> The future of the web can't happen without you. Join us at MIX09 to help >>>>>> pave the way to the Next Web now. Learn more and register at >>>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>>>> _______________________________________________ >>>>>> Gambas-user mailing list >>>>>> Gambas-user at lists.sourceforge.net >>>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>>> >>>>>> >>>>> ------------------------------------------------------------------------------ >>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>>> The future of the web can't happen without you. Join us at MIX09 to help >>>>> pave the way to the Next Web now. Learn more and register at >>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>>> _______________________________________________ >>>>> Gambas-user mailing list >>>>> Gambas-user at lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>> >>>>> >>>>> >>>> I think BACK has to be only an "undo" process, and NEXT is >>>> the logical next state depending on the datas already >>>> collected. If 2 forms could result from an actual status, >>>> then you have to review the logical chain. >>>> >>>> my two cents :) >>>> Dominique Simonart >>>> >>>> >>>> ------------------------------------------------------------------------------ >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>> The future of the web can't happen without you. Join us at MIX09 to help >>>> pave the way to the Next Web now. Learn more and register at >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>>> >>> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>> >>> >> The simpler is often the better :) May be you could write >> two procedures sort of PUSH and POP routines. Since the >> datas to keep should be limited enough, the better is to >> store all of them at each step with the last Object/form >> name. Since all data are implicitly correct (they passed >> correctly the preceeding step!) this is just a matter of >> display the form and to restore all the variables with the >> POPed values without control. This suppose of course the >> BACK could only reverse step by step. If you add something >> else in the BACK process, you could not be sure to return on >> the same initial state. >> >> Dominique Simonart >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > Well, here is a very dirty tentative to show what could be done. I don't really tested all the cases and it is surely not robust too! I take 5 forms, each of one with a checkbox to simulate different user input and 3 buttons, Back, Next and Cancel the chaining is not totally linear as I understand your wizard is The "stack" is a Gridview (sort of static array bidimensional) wich I display on the main form after all the steps the first column is the tag of the active form, and the others give the status of the 5 checkboxes hope this help Dominique Simonart -------------- next part -------------- A non-text attachment was scrubbed... Name: TestWizard-0.0.1.tar.gz Type: application/x-gzip Size: 8956 bytes Desc: not available URL: From l.jumadi at ...626... Fri Dec 12 08:16:22 2008 From: l.jumadi at ...626... (L Jumadi) Date: Fri, 12 Dec 2008 14:16:22 +0700 Subject: [Gambas-user] Integer Bug Message-ID: <3b3b9f170812112316i1ec86680wc28cc77aa36a5e0c@...627...> I found integer bug in gambas. Please try ?54*41000000 in gambas console. The result is negative, maybe because 41000000 is converted to integer rather than long integer. I can solve it by use manual converting to ?54*clng(41000000) but I think it should converted automatically by interpreter, isn't it? Another anomali (I am not search the detail yet) when I change gb.qt to gb.gtk: When I navigate between textbox with keyboard Tab it raise gambas error (it seems divide by zero) but rapidly another error raise (message box already open) and gambas close with signal 11. I hope this little information can help to solve the problem, or may be I will investigate more deeply (cause my program already complex now) in later time. When I switch back to gb.qt everything normal again. Regards L.Jumadi From gambas at ...1... Fri Dec 12 12:59:52 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 12 Dec 2008 12:59:52 +0100 Subject: [Gambas-user] Integer Bug In-Reply-To: <3b3b9f170812112316i1ec86680wc28cc77aa36a5e0c@...627...> References: <3b3b9f170812112316i1ec86680wc28cc77aa36a5e0c@...627...> Message-ID: <200812121259.52290.gambas@...1...> On vendredi 12 d?cembre 2008, L Jumadi wrote: > I found integer bug in gambas. Please try ?54*41000000 in gambas > console. The result is negative, maybe because 41000000 is converted > to integer rather than long integer. I can solve it by use manual > converting to ?54*clng(41000000) but I think it should converted > automatically by interpreter, isn't it? It should not, because checking an overflow is impossible in C, AFAIK. It would take far longer to check it than doing the operation. So I prefer let the programmer do the conversion explicitely. > Another anomali (I am not search the detail yet) when I change gb.qt > to gb.gtk: When I navigate between textbox with keyboard Tab it raise > gambas error (it seems divide by zero) but rapidly another error raise > (message box already open) and gambas close with signal 11. I hope > this little information can help to solve the problem, or may be I > will investigate more deeply (cause my program already complex now) in > later time. When I switch back to gb.qt everything normal again. I need a piece of your project that raises the bug, and the way to reproduce it. Otherwise I cannot do anything. You can help by running your project with valgrind and a gambas compiled from sources, and send me the valgrind output until the crash. Regards, -- Benoit Minisini From ron at ...1740... Fri Dec 12 14:11:42 2008 From: ron at ...1740... (Ron) Date: Fri, 12 Dec 2008 14:11:42 +0100 Subject: [Gambas-user] Hex string to float In-Reply-To: <4940F76D.800@...1740...> References: <4940F76D.800@...1740...> Message-ID: <4942630E.3040704@...1740...> Ron schreef: > > Hi, > > Anyone have a routine to convert a hex string to a float? > Like these: > B6FBEB3A = -0.000007507766895287204 > 3C5D2104 = 0.01349664106965065 > > Find lots of vb code, but those use copymem functions. > > Thanks in advance! > To answer my own question: I ended up with this so far: PUBLIC SUB Main() PRINT HexToFloat("3C5D2104") PRINT HexToFloat("B6FBEB3A") END PUBLIC FUNCTION HexToFloat(sHex AS String) AS Float DIM sTemp AS String DIM iSign, iExponent AS Integer DIM fTemp, fMant, fResult AS Float PRINT "Value = " & sHex ' calculate sign sTemp = Mid(sHex, 1, 2) fTemp = Val("&H" & sTemp) AND &H80 iSign = IIf(fTemp = 128, -1, 1) PRINT "Sign = " & iSign ' calculate exponent sTemp = Mid(sHex, 1, 3) fTemp = Val("&H" & sTemp) AND &H7F8 iExponent = fTemp / 2 ^ 3 - 127 PRINT "Exponent = " & iExponent ' calculate mantissa sTemp = Mid(sHex, 3, 6) fTemp = Val("&H" & sTemp) AND &H7FFFFF fMant = (fTemp / 2 ^ 23) + 1 PRINT "Mantissa = " & fMant fResult = iSign * fMant * 2 ^ iExponent RETURN fResult END Value = 3C5D2104 Sign = 1 Exponent = -7 Mantissa = 1.727570056915 Result: 0.01349664107 Value = B6FBEB3A Sign = -1 Exponent = -18 Mantissa = 1.968116044998 Result: -7.507766895287E-6 Regards, Ron_2nd From gambas at ...1... Fri Dec 12 17:30:46 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 12 Dec 2008 17:30:46 +0100 Subject: [Gambas-user] Problem with gambas wiki web site Message-ID: <200812121730.46376.gambas@...1...> Hi all, Apparently gambasdoc.org does not answer anymore, nor kudla.org, the domain where you can write to Rob Kudla, the gambasdoc.org server owner. If you read that Rob, please tell us what happens! -- Benoit Minisini From jussi.lahtinen at ...626... Fri Dec 12 17:34:29 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Fri, 12 Dec 2008 18:34:29 +0200 Subject: [Gambas-user] OO Message-ID: <384d3900812120834m43b334d5oc9cef93af42b1d31@...627...> Object Oriented approach is pretty new to me, so... PUBLIC tavk AS Object[2] tavk[0] = NEW Object[] tavk[1] = NEW Object[] This works, as I want to create two object arrays. But I need it to be dynamic array of array of objects, is it possible somehow? Other words, I need to add tavk[] objects dynamically. Example, is it possible to create objects like described below, if so how? If I have object called atom, which contains dynamic array of objects called electrons (different atoms contains different amount of electrons). Is it possible to add different atoms dynamically? And then change them later (add or remove electron [example if atom becomes ion])? Jussi From nando_f at ...951... Fri Dec 12 18:54:41 2008 From: nando_f at ...951... (nando) Date: Fri, 12 Dec 2008 12:54:41 -0500 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <4941D65C.3060705@...11...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> <4941D65C.3060705@...11...> Message-ID: <20081212174619.M65094@...951...> To remove the complicatedness of going from 2 to 4 or 5, skipping 3, you could implement it this way. Let's say you're in Form2 and when NEXT is pressed, it is determined that the next step is 5. You should have two global vars (called 'FROM' and 'DEST') set FROM 2 and set DEST to 5. Then perform the code (in Form2) to next the next form (FORM3) but it checks to see if it matches DEST. This case it doesn't. Form3 will run code for NEXT to Form4. Each form performs the same type of operation. Each form should have a local var to remember the FROM when the thread reaches there to know where to go BACK to. In this case when in Form5, it would save locally that it came from 2. If Form5 needs to go BACK, it will use it's local copy of FROM to know to set DEST, then run the back code (to Form4, then Form3, then Form2). Everything works sequencially forwards and backwards and each form has similar tests and methods to perform doing it. ---------- Original Message ----------- From: Dominique SIMONART To: mailing list for gambas users Sent: Fri, 12 Dec 2008 04:11:24 +0100 Subject: Re: [Gambas-user] Emulating wizard Back/Next navigation > M0E Lnx a ?crit : > > I just can't seem to completely wrap my mind around this one. > > > > It really doesn't matter if i return to the same state or not... as > > long as I return there. > > > > it gets complicated when for instance, you go in a sequence from 1, 2, > > 3 then you back up to 2... change something in 2 that now makes you > > skip 3 and jump to 4 or 5. > > > > On Thu, Dec 11, 2008 at 3:40 PM, Simonart Dominique > > wrote: > > > >> M0E Lnx a ?crit : > >> > >>> Exactly. > >>> > >>> The forward navigation depends on the user input, so it could jump > >>> from Form1 to Form3 and then to Form2 ans do on... > >>> > >>> So if we leave a footprint in the array, I think it *should* be easy > >>> to reverse the process indeed sort of like an "undo" process. > >>> > >>> But I'm not sure exactly what the best way to do the reverse is... > >>> should I index the array? or try to find the current form in the array > >>> and then just use the current forms.index in the array - 1 ? > >>> > >>> I've been fidling with this for a while... and it works perfecly in my > >>> mind... but can't really make it work on the IDE :( > >>> > >>> On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique > >>> wrote: > >>> > >>>> M0E Lnx a ?crit : > >>>> > >>>>> I have to say, the array idea makes more sense to me, simply because > >>>>> otherwise, it'll be hard to tell the next and back buttons which sub > >>>>> to run. > >>>>> > >>>>> I have tried an array, but object array rather than string array. > >>>>> > >>>>> The idea is that every form that gets opened leaves a footprint in > >>>>> this object array > >>>>> for instance, the form's open() event would have something like this > >>>>> > >>>>> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) > >>>>> > >>>>> this makes reverse navigation possible by indexing the array or a > >>>>> similar method. However, I am not able to work out all the bugs > >>>>> resulting from this because it gets crazy when you try to move back, > >>>>> then forward... then back... ends up in a crash almost every time > >>>>> > >>>>> Can someone work out a sample I can use? > >>>>> > >>>>> > >>>>> > >>>>> > >>>>> > >>>>> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: > >>>>> > >>>>>> Perhaps the following ideas... > >>>>>> Every step in the wizard has an associated form for whatever it does for that step. > >>>>>> Every form has a SUB for 'backwards' and 'forwards so that > >>>>>> when NEXT is clicked, the forwards code runs, which is whatever > >>>>>> is required for moving to the next form (ie: perform work, verify info, > >>>>>> hide form, the activate 'next' form) > >>>>>> when BACK is clicked, the backwards code runs, which is whatever to > >>>>>> undo this step (if needed), hide form, activate 'back' form. > >>>>>> Each form knows how to go back one step, and go forward one step. > >>>>>> You would have to tell the Next and BAck buttons which forwards and backwards > >>>>>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required > >>>>>> to properly run the correct code. This would be modular so each form takes > >>>>>> care of things. > >>>>>> Or, the list of wizard steps could be in a global string array with the name > >>>>>> of the form and simply step through the index. > >>>>>> -Fernando > >>>>>> > >>>>>> > >>>>>> ---------- Original Message ----------- > >>>>>> From: "M0E Lnx" > >>>>>> To: "mailing list for gambas users" > >>>>>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 > >>>>>> Subject: [Gambas-user] Emulating wizard Back/Next navigation > >>>>>> > >>>>>> > >>>>>>> So I set myself to create a program that acts like a wizard, but chose > >>>>>>> not to use the wizard object because well, there is just too many > >>>>>>> variables here, and there is more than one way to get to the end, > >>>>>>> Depending on user input. > >>>>>>> > >>>>>>> So what I did was create a navigation tool bar at the bottom of FMain > >>>>>>> this toolbar has a BACK, EXIT, and a NEXT button. > >>>>>>> > >>>>>>> I have a workspace object above it which will host other forms via > >>>>>>> each forms .Reparent method. > >>>>>>> > >>>>>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? > >>>>>>> > >>>>>>> I have created a small project what I'm trying to do... See attachment > >>>>>>> > >>>>>>> Any help is appreciated > >>>>>>> > >>>>>>> Thanks > >>>>>>> > >>>>>> ------- End of Original Message ------- > >>>>>> > >>>>>> > >>>>>> ------------------------------------------------------------------------------ > >>>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >>>>>> The future of the web can't happen without you. Join us at MIX09 to help > >>>>>> pave the way to the Next Web now. Learn more and register at > >>>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >>>>>> _______________________________________________ > >>>>>> Gambas-user mailing list > >>>>>> Gambas-user at lists.sourceforge.net > >>>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user > >>>>>> > >>>>>> > >>>>> ------------------------------------------------------------------------------ > >>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >>>>> The future of the web can't happen without you. Join us at MIX09 to help > >>>>> pave the way to the Next Web now. Learn more and register at > >>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >>>>> _______________________________________________ > >>>>> Gambas-user mailing list > >>>>> Gambas-user at lists.sourceforge.net > >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user > >>>>> > >>>>> > >>>>> > >>>> I think BACK has to be only an "undo" process, and NEXT is > >>>> the logical next state depending on the datas already > >>>> collected. If 2 forms could result from an actual status, > >>>> then you have to review the logical chain. > >>>> > >>>> my two cents :) > >>>> Dominique Simonart > >>>> > >>>> > >>>> ------------------------------------------------------------------------------ > >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >>>> The future of the web can't happen without you. Join us at MIX09 to help > >>>> pave the way to the Next Web now. Learn more and register at > >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >>>> _______________________________________________ > >>>> Gambas-user mailing list > >>>> Gambas-user at lists.sourceforge.net > >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user > >>>> > >>>> > >>> ------------------------------------------------------------------------------ > >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >>> The future of the web can't happen without you. Join us at MIX09 to help > >>> pave the way to the Next Web now. Learn more and register at > >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >>> _______________________________________________ > >>> Gambas-user mailing list > >>> Gambas-user at lists.sourceforge.net > >>> https://lists.sourceforge.net/lists/listinfo/gambas-user > >>> > >>> > >>> > >> The simpler is often the better :) May be you could write > >> two procedures sort of PUSH and POP routines. Since the > >> datas to keep should be limited enough, the better is to > >> store all of them at each step with the last Object/form > >> name. Since all data are implicitly correct (they passed > >> correctly the preceeding step!) this is just a matter of > >> display the form and to restore all the variables with the > >> POPed values without control. This suppose of course the > >> BACK could only reverse step by step. If you add something > >> else in the BACK process, you could not be sure to return on > >> the same initial state. > >> > >> Dominique Simonart > >> > >> > >> ------------------------------------------------------------------------------ > >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >> The future of the web can't happen without you. Join us at MIX09 to help > >> pave the way to the Next Web now. Learn more and register at > >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > >> > > > > ------------------------------------------------------------------------------ > > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > > The future of the web can't happen without you. Join us at MIX09 to help > > pave the way to the Next Web now. Learn more and register at > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > Well, here is a very dirty tentative to show what could be done. > I don't really tested all the cases and it is surely not robust too! > > I take 5 forms, each of one with a checkbox to simulate different user > input and 3 buttons, Back, Next and Cancel > the chaining is not totally linear as I understand your wizard is > The "stack" is a Gridview (sort of static array bidimensional) wich I > display on the main form after all the steps > the first column is the tag of the active form, and the others give the > status of the 5 checkboxes > > hope this help > Dominique Simonart ------- End of Original Message ------- From m0e.lnx at ...626... Fri Dec 12 19:18:28 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Fri, 12 Dec 2008 12:18:28 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <20081212174619.M65094@...951...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> <4941D65C.3060705@...11...> <20081212174619.M65094@...951...> Message-ID: <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> My idea was a little different, but I think I got it.... In my idea, I use a panel or workspace in FMain as a host for the other windows. The navigation is always handled from FMain, and not from each child window, which is what makes it complicated for me. I had created a model that used the object[] for reverse navigation and the logical forward sequence is defined by the child windows, and partly from a pre-defined default path. I'm getting satisfactory results, but I was trying to see if there was a better way to do it On Fri, Dec 12, 2008 at 11:54 AM, nando wrote: > To remove the complicatedness of going from 2 to 4 or 5, skipping 3, you > could implement it this way. > Let's say you're in Form2 and when NEXT is pressed, it is determined that > the next step is 5. You should have two global vars (called 'FROM' and 'DEST') > set FROM 2 and set DEST to 5. Then perform the code (in Form2) to next the next > form (FORM3) but it checks to see if it matches DEST. This case it doesn't. > Form3 will run code for NEXT to Form4. Each form performs the same > type of operation. Each form should have a local var to remember the FROM > when the thread reaches there to know where to go BACK to. In this case > when in Form5, it would save locally that it came from 2. If Form5 needs to > go BACK, it will use it's local copy of FROM to know to set DEST, then > run the back code (to Form4, then Form3, then Form2). > Everything works sequencially forwards and backwards and each form has similar > tests and methods to perform doing it. > > > > ---------- Original Message ----------- > From: Dominique SIMONART > To: mailing list for gambas users > Sent: Fri, 12 Dec 2008 04:11:24 +0100 > Subject: Re: [Gambas-user] Emulating wizard Back/Next navigation > >> M0E Lnx a ?crit : >> > I just can't seem to completely wrap my mind around this one. >> > >> > It really doesn't matter if i return to the same state or not... as >> > long as I return there. >> > >> > it gets complicated when for instance, you go in a sequence from 1, 2, >> > 3 then you back up to 2... change something in 2 that now makes you >> > skip 3 and jump to 4 or 5. >> > >> > On Thu, Dec 11, 2008 at 3:40 PM, Simonart Dominique >> > wrote: >> > >> >> M0E Lnx a ?crit : >> >> >> >>> Exactly. >> >>> >> >>> The forward navigation depends on the user input, so it could jump >> >>> from Form1 to Form3 and then to Form2 ans do on... >> >>> >> >>> So if we leave a footprint in the array, I think it *should* be easy >> >>> to reverse the process indeed sort of like an "undo" process. >> >>> >> >>> But I'm not sure exactly what the best way to do the reverse is... >> >>> should I index the array? or try to find the current form in the array >> >>> and then just use the current forms.index in the array - 1 ? >> >>> >> >>> I've been fidling with this for a while... and it works perfecly in my >> >>> mind... but can't really make it work on the IDE :( >> >>> >> >>> On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique >> >>> wrote: >> >>> >> >>>> M0E Lnx a ?crit : >> >>>> >> >>>>> I have to say, the array idea makes more sense to me, simply because >> >>>>> otherwise, it'll be hard to tell the next and back buttons which sub >> >>>>> to run. >> >>>>> >> >>>>> I have tried an array, but object array rather than string array. >> >>>>> >> >>>>> The idea is that every form that gets opened leaves a footprint in >> >>>>> this object array >> >>>>> for instance, the form's open() event would have something like this >> >>>>> >> >>>>> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) >> >>>>> >> >>>>> this makes reverse navigation possible by indexing the array or a >> >>>>> similar method. However, I am not able to work out all the bugs >> >>>>> resulting from this because it gets crazy when you try to move back, >> >>>>> then forward... then back... ends up in a crash almost every time >> >>>>> >> >>>>> Can someone work out a sample I can use? >> >>>>> >> >>>>> >> >>>>> >> >>>>> >> >>>>> >> >>>>> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: >> >>>>> >> >>>>>> Perhaps the following ideas... >> >>>>>> Every step in the wizard has an associated form for whatever it does for that step. >> >>>>>> Every form has a SUB for 'backwards' and 'forwards so that >> >>>>>> when NEXT is clicked, the forwards code runs, which is whatever >> >>>>>> is required for moving to the next form (ie: perform work, verify info, >> >>>>>> hide form, the activate 'next' form) >> >>>>>> when BACK is clicked, the backwards code runs, which is whatever to >> >>>>>> undo this step (if needed), hide form, activate 'back' form. >> >>>>>> Each form knows how to go back one step, and go forward one step. >> >>>>>> You would have to tell the Next and BAck buttons which forwards and backwards >> >>>>>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required >> >>>>>> to properly run the correct code. This would be modular so each form takes >> >>>>>> care of things. >> >>>>>> Or, the list of wizard steps could be in a global string array with the name >> >>>>>> of the form and simply step through the index. >> >>>>>> -Fernando >> >>>>>> >> >>>>>> >> >>>>>> ---------- Original Message ----------- >> >>>>>> From: "M0E Lnx" >> >>>>>> To: "mailing list for gambas users" >> >>>>>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 >> >>>>>> Subject: [Gambas-user] Emulating wizard Back/Next navigation >> >>>>>> >> >>>>>> >> >>>>>>> So I set myself to create a program that acts like a wizard, but chose >> >>>>>>> not to use the wizard object because well, there is just too many >> >>>>>>> variables here, and there is more than one way to get to the end, >> >>>>>>> Depending on user input. >> >>>>>>> >> >>>>>>> So what I did was create a navigation tool bar at the bottom of FMain >> >>>>>>> this toolbar has a BACK, EXIT, and a NEXT button. >> >>>>>>> >> >>>>>>> I have a workspace object above it which will host other forms via >> >>>>>>> each forms .Reparent method. >> >>>>>>> >> >>>>>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? >> >>>>>>> >> >>>>>>> I have created a small project what I'm trying to do... See attachment >> >>>>>>> >> >>>>>>> Any help is appreciated >> >>>>>>> >> >>>>>>> Thanks >> >>>>>>> >> >>>>>> ------- End of Original Message ------- >> >>>>>> >> >>>>>> >> >>>>>> ------------------------------------------------------------------------------ >> >>>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> >>>>>> The future of the web can't happen without you. Join us at MIX09 to help >> >>>>>> pave the way to the Next Web now. Learn more and register at >> >>>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> >>>>>> _______________________________________________ >> >>>>>> Gambas-user mailing list >> >>>>>> Gambas-user at lists.sourceforge.net >> >>>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >>>>>> >> >>>>>> >> >>>>> ------------------------------------------------------------------------------ >> >>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> >>>>> The future of the web can't happen without you. Join us at MIX09 to help >> >>>>> pave the way to the Next Web now. Learn more and register at >> >>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> >>>>> _______________________________________________ >> >>>>> Gambas-user mailing list >> >>>>> Gambas-user at lists.sourceforge.net >> >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >>>>> >> >>>>> >> >>>>> >> >>>> I think BACK has to be only an "undo" process, and NEXT is >> >>>> the logical next state depending on the datas already >> >>>> collected. If 2 forms could result from an actual status, >> >>>> then you have to review the logical chain. >> >>>> >> >>>> my two cents :) >> >>>> Dominique Simonart >> >>>> >> >>>> >> >>>> ------------------------------------------------------------------------------ >> >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> >>>> The future of the web can't happen without you. Join us at MIX09 to help >> >>>> pave the way to the Next Web now. Learn more and register at >> >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> >>>> _______________________________________________ >> >>>> Gambas-user mailing list >> >>>> Gambas-user at lists.sourceforge.net >> >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >>>> >> >>>> >> >>> ------------------------------------------------------------------------------ >> >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> >>> The future of the web can't happen without you. Join us at MIX09 to help >> >>> pave the way to the Next Web now. Learn more and register at >> >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> >>> _______________________________________________ >> >>> Gambas-user mailing list >> >>> Gambas-user at lists.sourceforge.net >> >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >>> >> >>> >> >>> >> >> The simpler is often the better :) May be you could write >> >> two procedures sort of PUSH and POP routines. Since the >> >> datas to keep should be limited enough, the better is to >> >> store all of them at each step with the last Object/form >> >> name. Since all data are implicitly correct (they passed >> >> correctly the preceeding step!) this is just a matter of >> >> display the form and to restore all the variables with the >> >> POPed values without control. This suppose of course the >> >> BACK could only reverse step by step. If you add something >> >> else in the BACK process, you could not be sure to return on >> >> the same initial state. >> >> >> >> Dominique Simonart >> >> >> >> >> >> ------------------------------------------------------------------------------ >> >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> >> The future of the web can't happen without you. Join us at MIX09 to help >> >> pave the way to the Next Web now. Learn more and register at >> >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> >> _______________________________________________ >> >> Gambas-user mailing list >> >> Gambas-user at lists.sourceforge.net >> >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> >> >> >> > >> > ------------------------------------------------------------------------------ >> > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> > The future of the web can't happen without you. Join us at MIX09 to help >> > pave the way to the Next Web now. Learn more and register at >> > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> > _______________________________________________ >> > Gambas-user mailing list >> > Gambas-user at lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/gambas-user >> > >> > >> > >> Well, here is a very dirty tentative to show what could be done. >> I don't really tested all the cases and it is surely not robust too! >> >> I take 5 forms, each of one with a checkbox to simulate different user >> input and 3 buttons, Back, Next and Cancel >> the chaining is not totally linear as I understand your wizard is >> The "stack" is a Gridview (sort of static array bidimensional) wich I >> display on the main form after all the steps >> the first column is the tag of the active form, and the others give the >> status of the 5 checkboxes >> >> hope this help >> Dominique Simonart > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From epileg at ...626... Fri Dec 12 19:22:50 2008 From: epileg at ...626... (=?ISO-8859-1?Q?Ep=EDleg?=) Date: Fri, 12 Dec 2008 19:22:50 +0100 Subject: [Gambas-user] Problems with libtool In-Reply-To: References: Message-ID: <4942ABFA.2090807@...626...> En/na Tchekov.Net ha escrit: > Dear all, > > need help on compiling Gambas. > > Have tried to install Gambas 2.9 on Xubuntu in Virtual Machine. > > Evrth. went good, but I have overseen the version warning for the libtool (I > was really dumb ...), so the compiling was not successfull (libtool 2.2.24 > was installed on my Xubuntu). > > So using Synaptic I have "completely" removed the libtool 2.2.24; Then > downloaded the required version 1.5.12 (configure, make, make install went > successfull). > > BUT the Gambas compilation is still not successfull - after reconf and > configure, make still breaks with libtool version warning (2.2.24). > > I think there is some kind of string, which is not set to the proper value, > since I have now the proper version on libtool, but may be not properly > "registered". > > Any suggestion? Or should I reinstall Xubuntu :-( > > Thank you very much in advance > > > kind regards > > > Emil Hello, Try to reconf-all, configure and make in a clean new tree project. Best regards, -- Ep?leg From ronstk at ...239... Fri Dec 12 19:42:09 2008 From: ronstk at ...239... (Ron_1st) Date: Fri, 12 Dec 2008 19:42:09 +0100 Subject: [Gambas-user] Hex string to float In-Reply-To: <4942630E.3040704@...1740...> References: <4940F76D.800@...1740...> <4942630E.3040704@...1740...> Message-ID: <200812121942.10361.ronstk@...239...> On Friday 12 December 2008, Ron wrote: > Ron schreef: > > > > Hi, > > > > Anyone have a routine to convert a hex string to a float? > > Like these: > > B6FBEB3A = -0.000007507766895287204 > > 3C5D2104 = 0.01349664106965065 > > > > Find lots of vb code, but those use copymem functions. > > > > Thanks in advance! > > > To answer my own question: > > I ended up with this so far: > > PUBLIC SUB Main() > > PRINT HexToFloat("3C5D2104") > PRINT HexToFloat("B6FBEB3A") > > END > > PUBLIC FUNCTION HexToFloat(sHex AS String) AS Float > > DIM sTemp AS String > DIM iSign, iExponent AS Integer > DIM fTemp, fMant, fResult AS Float > > PRINT "Value = " & sHex > ' calculate sign > sTemp = Mid(sHex, 1, 2) > fTemp = Val("&H" & sTemp) AND &H80 > iSign = IIf(fTemp = 128, -1, 1) > PRINT "Sign = " & iSign > > ' calculate exponent > sTemp = Mid(sHex, 1, 3) > fTemp = Val("&H" & sTemp) AND &H7F8 > iExponent = fTemp / 2 ^ 3 - 127 > PRINT "Exponent = " & iExponent > > ' calculate mantissa > sTemp = Mid(sHex, 3, 6) > fTemp = Val("&H" & sTemp) AND &H7FFFFF > fMant = (fTemp / 2 ^ 23) + 1 > PRINT "Mantissa = " & fMant > > fResult = iSign * fMant * 2 ^ iExponent > > RETURN fResult > > END > > Value = 3C5D2104 > Sign = 1 > Exponent = -7 > Mantissa = 1.727570056915 > > Result: 0.01349664107 > > Value = B6FBEB3A > Sign = -1 > Exponent = -18 > Mantissa = 1.968116044998 > > Result: -7.507766895287E-6 > > Regards, > Ron_2nd > > Hi Ron :) It's a very long time ago I had to manage same 'problem' First you need to know what notation is in the hex number. I only know a little of two of them and second you cant do strict hex to float. Its binary written in short by hex digits. 1) The left most bit is the sign of the number and every bit is 1/2 01001001 is positive 1*0.5 + 0*.25 + 0*.125 + 1*0.062 + 0*0.031 +0*0.016 +1*0.008 in hex 0x49 2) the leftmost is the sign, then 8 bits for the exponent and followed 23 bits for the mantisa. (it looks to me you have/use this notation) The first step is to convert the hex number to binary. Seperate the sign bit from the bits and loop the remaining bits is the base method in both notations. The bad part is the fractional part but if you have a fixed count of bits you can first multiply by a fix number. i.e. if you have 8 bits (1 sign 7 number) you multiply by 128, for 16 bits (1 sign,15 number) you multiply by 65536. After dont the calculations you know you need to divide by that number. I did it in Z80 machine language and the method was good enough, using a quarter of a sinus table (180 steps of 0.5 grad per byte) and usage of pitagoras to draw circles on the screen. Her the multiply was done by shift left, divide by shift right. The table was the sinus table value for 90 degree multiplied by 256 If floppy disks have a lifetime of centuries the I maybe can find it back on a real 5.25 floppy disk :) links: google:floating number in binary IEEE 754-2008 - Wikipedia, the free encyclopedia http://en.wikipedia.org/wiki/IEEE_754 IEEE Standard 754 Floating-Point http://steve.hollasch.net/cgindex/coding/ieeefloat.html Binary floating point and .NET http://www.yoda.arachsys.com/csharp/floatingpoint.html Read the part: What exactly does a floating point number look like in memory? IEEE Floating-Point Binary Representation http://hankfiles.pcvsconsole.com/answer.php?file=454 So the keyword is 'IEEE754' for search. google:floating number in binary z80 (nice results) Understanding Floating Point Formats http://aplawrence.com/Basics/floatingpoint.html (perl script) Best regards Ron_1st From gambas.fr at ...626... Fri Dec 12 19:55:42 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Fri, 12 Dec 2008 19:55:42 +0100 Subject: [Gambas-user] OO In-Reply-To: <384d3900812120834m43b334d5oc9cef93af42b1d31@...627...> References: <384d3900812120834m43b334d5oc9cef93af42b1d31@...627...> Message-ID: <6324a42a0812121055w4393819fjcdcdab55da85233f@...627...> dim i as integer dim tavk as new object[] dim o as object[] for i = 0 to 4 o = new object[] tavk.add(o) next 2008/12/12 Jussi Lahtinen : > Object Oriented approach is pretty new to me, so... > > PUBLIC tavk AS Object[2] > > tavk[0] = NEW Object[] > tavk[1] = NEW Object[] > > This works, as I want to create two object arrays. > But I need it to be dynamic array of array of objects, is it possible somehow? > Other words, I need to add tavk[] objects dynamically. > > Example, is it possible to create objects like described below, if so how? > If I have object called atom, which contains dynamic array of objects > called electrons > (different atoms contains different amount of electrons). > Is it possible to add different atoms dynamically? > And then change them later (add or remove electron [example if atom > becomes ion])? > > > Jussi > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From ronstk at ...239... Fri Dec 12 19:58:22 2008 From: ronstk at ...239... (Ron_1st) Date: Fri, 12 Dec 2008 19:58:22 +0100 Subject: [Gambas-user] Hex string to float In-Reply-To: <200812121942.10361.ronstk@...239...> References: <4940F76D.800@...1740...> <4942630E.3040704@...1740...> <200812121942.10361.ronstk@...239...> Message-ID: <200812121958.22406.ronstk@...239...> PS http://books.google.com/books?id=YMmepn2xCcMC&pg=PA46&lpg=PR14&dq=floating+number+in+binary++z80&output=html page is 46 DATA REPRESENTATION. I did not trust the notation of sign exponent mantisa and found another source about it. There was my orginal sequence of sign., mantisa, exponent. As far I remeber there is a sign for the mantisa and also a sign for the exponent. My source was fortran and intels PL/M at that time (1976) Best regards Ron_1st From jussi.lahtinen at ...626... Fri Dec 12 21:30:28 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Fri, 12 Dec 2008 22:30:28 +0200 Subject: [Gambas-user] OO In-Reply-To: <6324a42a0812121055w4393819fjcdcdab55da85233f@...627...> References: <384d3900812120834m43b334d5oc9cef93af42b1d31@...627...> <6324a42a0812121055w4393819fjcdcdab55da85233f@...627...> Message-ID: <384d3900812121230y22eb84f3h7439b3d4fbb55e25@...627...> Thanks! Now the solution looks obvious. Jussi On Fri, Dec 12, 2008 at 8:55 PM, Fabien Bodard wrote: > dim i as integer > dim tavk as new object[] > dim o as object[] > > for i = 0 to 4 > o = new object[] > tavk.add(o) > next > > 2008/12/12 Jussi Lahtinen : >> Object Oriented approach is pretty new to me, so... >> >> PUBLIC tavk AS Object[2] >> >> tavk[0] = NEW Object[] >> tavk[1] = NEW Object[] >> >> This works, as I want to create two object arrays. >> But I need it to be dynamic array of array of objects, is it possible somehow? >> Other words, I need to add tavk[] objects dynamically. >> >> Example, is it possible to create objects like described below, if so how? >> If I have object called atom, which contains dynamic array of objects >> called electrons >> (different atoms contains different amount of electrons). >> Is it possible to add different atoms dynamically? >> And then change them later (add or remove electron [example if atom >> becomes ion])? >> >> >> Jussi >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From nando_f at ...951... Fri Dec 12 21:40:59 2008 From: nando_f at ...951... (nando) Date: Fri, 12 Dec 2008 15:40:59 -0500 Subject: [Gambas-user] Hex string to float In-Reply-To: <200812121942.10361.ronstk@...239...> References: <4940F76D.800@...1740...> <4942630E.3040704@...1740...> <200812121942.10361.ronstk@...239...> Message-ID: <20081212203820.M23548@...951...> Two Questions: 1) Is the HEX you show below the HEX representation of 4B of a IEEE 4B Float? 2) How do you get these values? (read in from file? something else?) -Fernando ---------- Original Message ----------- From: "Ron_1st" To: gambas-user at lists.sourceforge.net Sent: Fri, 12 Dec 2008 19:42:09 +0100 Subject: Re: [Gambas-user] Hex string to float > On Friday 12 December 2008, Ron wrote: > > Ron schreef: > > > > > > Hi, > > > > > > Anyone have a routine to convert a hex string to a float? > > > Like these: > > > B6FBEB3A = -0.000007507766895287204 > > > 3C5D2104 = 0.01349664106965065 > > > > > > Find lots of vb code, but those use copymem functions. > > > > > > Thanks in advance! > > > > > To answer my own question: > > > > I ended up with this so far: > > > > PUBLIC SUB Main() > > > > PRINT HexToFloat("3C5D2104") > > PRINT HexToFloat("B6FBEB3A") > > > > END > > > > PUBLIC FUNCTION HexToFloat(sHex AS String) AS Float > > > > DIM sTemp AS String > > DIM iSign, iExponent AS Integer > > DIM fTemp, fMant, fResult AS Float > > > > PRINT "Value = " & sHex > > ' calculate sign > > sTemp = Mid(sHex, 1, 2) > > fTemp = Val("&H" & sTemp) AND &H80 > > iSign = IIf(fTemp = 128, -1, 1) > > PRINT "Sign = " & iSign > > > > ' calculate exponent > > sTemp = Mid(sHex, 1, 3) > > fTemp = Val("&H" & sTemp) AND &H7F8 > > iExponent = fTemp / 2 ^ 3 - 127 > > PRINT "Exponent = " & iExponent > > > > ' calculate mantissa > > sTemp = Mid(sHex, 3, 6) > > fTemp = Val("&H" & sTemp) AND &H7FFFFF > > fMant = (fTemp / 2 ^ 23) + 1 > > PRINT "Mantissa = " & fMant > > > > fResult = iSign * fMant * 2 ^ iExponent > > > > RETURN fResult > > > > END > > > > Value = 3C5D2104 > > Sign = 1 > > Exponent = -7 > > Mantissa = 1.727570056915 > > > > Result: 0.01349664107 > > > > Value = B6FBEB3A > > Sign = -1 > > Exponent = -18 > > Mantissa = 1.968116044998 > > > > Result: -7.507766895287E-6 > > > > Regards, > > Ron_2nd > > > > > > Hi Ron :) > It's a very long time ago I had to manage same 'problem' > > First you need to know what notation is in the hex number. > I only know a little of two of them and second you cant do > strict hex to float. Its binary written in short by hex digits. > > 1) The left most bit is the sign of the number and every bit is 1/2 > 01001001 is positive 1*0.5 + 0*.25 + 0*.125 + 1*0.062 + 0*0.031 +0*0.016 +1*0.008 > in hex 0x49 > > 2) the leftmost is the sign, then 8 bits for the exponent and followed > 23 bits for the mantisa. (it looks to me you have/use this notation) > > The first step is to convert the hex number to binary. > Seperate the sign bit from the bits and loop the remaining bits > is the base method in both notations. > The bad part is the fractional part but if you have a fixed count of bits > you can first multiply by a fix number. > i.e. if you have 8 bits (1 sign 7 number) you multiply by 128, > for 16 bits (1 sign,15 number) you multiply by 65536. > After dont the calculations you know you need to divide by that number. > > I did it in Z80 machine language and the method was good enough, using > a quarter of a sinus table (180 steps of 0.5 grad per byte) and usage > of pitagoras to draw circles on the screen. > Her the multiply was done by shift left, divide by shift right. > The table was the sinus table value for 90 degree multiplied by 256 > > If floppy disks have a lifetime of centuries the I maybe can find it back > on a real 5.25 floppy disk :) > > links: > google:floating number in binary > IEEE 754-2008 - Wikipedia, the free encyclopedia > http://en.wikipedia.org/wiki/IEEE_754 > IEEE Standard 754 Floating-Point > http://steve.hollasch.net/cgindex/coding/ieeefloat.html > Binary floating point and .NET > http://www.yoda.arachsys.com/csharp/floatingpoint.html > Read the part: > What exactly does a floating point number look like in memory? > > IEEE Floating-Point Binary Representation > http://hankfiles.pcvsconsole.com/answer.php?file=454 > > So the keyword is 'IEEE754' for search. > > google:floating number in binary z80 > (nice results) > Understanding Floating Point Formats > http://aplawrence.com/Basics/floatingpoint.html (perl script) > > Best regards > Ron_1st > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From gambas.fr at ...626... Sat Dec 13 08:20:56 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 13 Dec 2008 08:20:56 +0100 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081211181151.M51711@...951...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> <4941D65C.3060705@...11...> <20081212174619.M65094@...951...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> Message-ID: <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> forward need to be hardcoded, backward need to use an object array and the function pop/push and it will work with that. so 1->2->3 ->4 it's 2 who know if you must or not go to the 3 or 4 so the next button need to drive that statiquely. it may work in all case. when next is selected it store the current form in an array the main windows own the prev/next button you need to have a common fonction in your child windows, Named for exemple GetNext, that return the next Windows and in fact Public $arrPrev as new Object[] Public $oCurrentChild as Object Public sub Next_Click() dim o, oTmp as Object 'Get the next One sTmp =$oCurrentChild.GetNext() 'Is this form already opened ? 'if true it may have no been closed to preserve entries For each o in Panel if Object.Type(o) = sTmp then oTmp = o next 'strore the previous $arrPrev.Push(oCurrentChlid) 'Select or create the form if not isNull(oTmp) then $oCurrentChild = Object.New(sTmp, Panel) $oCurrentChild.Visible = True else $OCurrentChild = oTmp endif 'Push to the foreground $oCurrentChild.Raise() end Public sub Prev_Click() $oCurrentChild = $arrPrev.Pop $oCurrentChild.Raise() end in all your children you add : Public Fonction GetNext() as String 'simply return the name of the next form as a string (classname) return "frmNext" end so it's not tested but it will work Regards Fabien Bodard 2008/12/12 M0E Lnx : > My idea was a little different, but I think I got it.... > > In my idea, I use a panel or workspace in FMain as a host for the other windows. > > The navigation is always handled from FMain, and not from each child > window, which is what makes it complicated for me. > I had created a model that used the object[] for reverse navigation > and the logical forward sequence is defined by the child windows, and > partly from a pre-defined default path. I'm getting satisfactory > results, but I was trying to see if there was a better way to do it > > > > On Fri, Dec 12, 2008 at 11:54 AM, nando wrote: >> To remove the complicatedness of going from 2 to 4 or 5, skipping 3, you >> could implement it this way. >> Let's say you're in Form2 and when NEXT is pressed, it is determined that >> the next step is 5. You should have two global vars (called 'FROM' and 'DEST') >> set FROM 2 and set DEST to 5. Then perform the code (in Form2) to next the next >> form (FORM3) but it checks to see if it matches DEST. This case it doesn't. >> Form3 will run code for NEXT to Form4. Each form performs the same >> type of operation. Each form should have a local var to remember the FROM >> when the thread reaches there to know where to go BACK to. In this case >> when in Form5, it would save locally that it came from 2. If Form5 needs to >> go BACK, it will use it's local copy of FROM to know to set DEST, then >> run the back code (to Form4, then Form3, then Form2). >> Everything works sequencially forwards and backwards and each form has similar >> tests and methods to perform doing it. >> >> >> >> ---------- Original Message ----------- >> From: Dominique SIMONART >> To: mailing list for gambas users >> Sent: Fri, 12 Dec 2008 04:11:24 +0100 >> Subject: Re: [Gambas-user] Emulating wizard Back/Next navigation >> >>> M0E Lnx a ?crit : >>> > I just can't seem to completely wrap my mind around this one. >>> > >>> > It really doesn't matter if i return to the same state or not... as >>> > long as I return there. >>> > >>> > it gets complicated when for instance, you go in a sequence from 1, 2, >>> > 3 then you back up to 2... change something in 2 that now makes you >>> > skip 3 and jump to 4 or 5. >>> > >>> > On Thu, Dec 11, 2008 at 3:40 PM, Simonart Dominique >>> > wrote: >>> > >>> >> M0E Lnx a ?crit : >>> >> >>> >>> Exactly. >>> >>> >>> >>> The forward navigation depends on the user input, so it could jump >>> >>> from Form1 to Form3 and then to Form2 ans do on... >>> >>> >>> >>> So if we leave a footprint in the array, I think it *should* be easy >>> >>> to reverse the process indeed sort of like an "undo" process. >>> >>> >>> >>> But I'm not sure exactly what the best way to do the reverse is... >>> >>> should I index the array? or try to find the current form in the array >>> >>> and then just use the current forms.index in the array - 1 ? >>> >>> >>> >>> I've been fidling with this for a while... and it works perfecly in my >>> >>> mind... but can't really make it work on the IDE :( >>> >>> >>> >>> On Thu, Dec 11, 2008 at 2:23 PM, Simonart Dominique >>> >>> wrote: >>> >>> >>> >>>> M0E Lnx a ?crit : >>> >>>> >>> >>>>> I have to say, the array idea makes more sense to me, simply because >>> >>>>> otherwise, it'll be hard to tell the next and back buttons which sub >>> >>>>> to run. >>> >>>>> >>> >>>>> I have tried an array, but object array rather than string array. >>> >>>>> >>> >>>>> The idea is that every form that gets opened leaves a footprint in >>> >>>>> this object array >>> >>>>> for instance, the form's open() event would have something like this >>> >>>>> >>> >>>>> IF ArrNav.find(me) = -1 THEN ArrNav.Add(me) >>> >>>>> >>> >>>>> this makes reverse navigation possible by indexing the array or a >>> >>>>> similar method. However, I am not able to work out all the bugs >>> >>>>> resulting from this because it gets crazy when you try to move back, >>> >>>>> then forward... then back... ends up in a crash almost every time >>> >>>>> >>> >>>>> Can someone work out a sample I can use? >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> On Thu, Dec 11, 2008 at 6:20 PM, nando wrote: >>> >>>>> >>> >>>>>> Perhaps the following ideas... >>> >>>>>> Every step in the wizard has an associated form for whatever it does for that step. >>> >>>>>> Every form has a SUB for 'backwards' and 'forwards so that >>> >>>>>> when NEXT is clicked, the forwards code runs, which is whatever >>> >>>>>> is required for moving to the next form (ie: perform work, verify info, >>> >>>>>> hide form, the activate 'next' form) >>> >>>>>> when BACK is clicked, the backwards code runs, which is whatever to >>> >>>>>> undo this step (if needed), hide form, activate 'back' form. >>> >>>>>> Each form knows how to go back one step, and go forward one step. >>> >>>>>> You would have to tell the Next and BAck buttons which forwards and backwards >>> >>>>>> sub to run...you could place in NEXT.tag and BACK.tag the form or info required >>> >>>>>> to properly run the correct code. This would be modular so each form takes >>> >>>>>> care of things. >>> >>>>>> Or, the list of wizard steps could be in a global string array with the name >>> >>>>>> of the form and simply step through the index. >>> >>>>>> -Fernando >>> >>>>>> >>> >>>>>> >>> >>>>>> ---------- Original Message ----------- >>> >>>>>> From: "M0E Lnx" >>> >>>>>> To: "mailing list for gambas users" >>> >>>>>> Sent: Wed, 10 Dec 2008 20:39:45 +0000 >>> >>>>>> Subject: [Gambas-user] Emulating wizard Back/Next navigation >>> >>>>>> >>> >>>>>> >>> >>>>>>> So I set myself to create a program that acts like a wizard, but chose >>> >>>>>>> not to use the wizard object because well, there is just too many >>> >>>>>>> variables here, and there is more than one way to get to the end, >>> >>>>>>> Depending on user input. >>> >>>>>>> >>> >>>>>>> So what I did was create a navigation tool bar at the bottom of FMain >>> >>>>>>> this toolbar has a BACK, EXIT, and a NEXT button. >>> >>>>>>> >>> >>>>>>> I have a workspace object above it which will host other forms via >>> >>>>>>> each forms .Reparent method. >>> >>>>>>> >>> >>>>>>> Can anyone suggest a way to make reverse and forward navigation on such a setup? >>> >>>>>>> >>> >>>>>>> I have created a small project what I'm trying to do... See attachment >>> >>>>>>> >>> >>>>>>> Any help is appreciated >>> >>>>>>> >>> >>>>>>> Thanks >>> >>>>>>> >>> >>>>>> ------- End of Original Message ------- >>> >>>>>> >>> >>>>>> >>> >>>>>> ------------------------------------------------------------------------------ >>> >>>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> >>>>>> The future of the web can't happen without you. Join us at MIX09 to help >>> >>>>>> pave the way to the Next Web now. Learn more and register at >>> >>>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> >>>>>> _______________________________________________ >>> >>>>>> Gambas-user mailing list >>> >>>>>> Gambas-user at lists.sourceforge.net >>> >>>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>>>>> >>> >>>>>> >>> >>>>> ------------------------------------------------------------------------------ >>> >>>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> >>>>> The future of the web can't happen without you. Join us at MIX09 to help >>> >>>>> pave the way to the Next Web now. Learn more and register at >>> >>>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> >>>>> _______________________________________________ >>> >>>>> Gambas-user mailing list >>> >>>>> Gambas-user at lists.sourceforge.net >>> >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>> I think BACK has to be only an "undo" process, and NEXT is >>> >>>> the logical next state depending on the datas already >>> >>>> collected. If 2 forms could result from an actual status, >>> >>>> then you have to review the logical chain. >>> >>>> >>> >>>> my two cents :) >>> >>>> Dominique Simonart >>> >>>> >>> >>>> >>> >>>> ------------------------------------------------------------------------------ >>> >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> >>>> The future of the web can't happen without you. Join us at MIX09 to help >>> >>>> pave the way to the Next Web now. Learn more and register at >>> >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> >>>> _______________________________________________ >>> >>>> Gambas-user mailing list >>> >>>> Gambas-user at lists.sourceforge.net >>> >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>>> >>> >>>> >>> >>> ------------------------------------------------------------------------------ >>> >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> >>> The future of the web can't happen without you. Join us at MIX09 to help >>> >>> pave the way to the Next Web now. Learn more and register at >>> >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> >>> _______________________________________________ >>> >>> Gambas-user mailing list >>> >>> Gambas-user at lists.sourceforge.net >>> >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>> >>> >>> >>> >>> >>> >> The simpler is often the better :) May be you could write >>> >> two procedures sort of PUSH and POP routines. Since the >>> >> datas to keep should be limited enough, the better is to >>> >> store all of them at each step with the last Object/form >>> >> name. Since all data are implicitly correct (they passed >>> >> correctly the preceeding step!) this is just a matter of >>> >> display the form and to restore all the variables with the >>> >> POPed values without control. This suppose of course the >>> >> BACK could only reverse step by step. If you add something >>> >> else in the BACK process, you could not be sure to return on >>> >> the same initial state. >>> >> >>> >> Dominique Simonart >>> >> >>> >> >>> >> ------------------------------------------------------------------------------ >>> >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> >> The future of the web can't happen without you. Join us at MIX09 to help >>> >> pave the way to the Next Web now. Learn more and register at >>> >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> >> _______________________________________________ >>> >> Gambas-user mailing list >>> >> Gambas-user at lists.sourceforge.net >>> >> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> >>> >> >>> > >>> > ------------------------------------------------------------------------------ >>> > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> > The future of the web can't happen without you. Join us at MIX09 to help >>> > pave the way to the Next Web now. Learn more and register at >>> > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> > _______________________________________________ >>> > Gambas-user mailing list >>> > Gambas-user at lists.sourceforge.net >>> > https://lists.sourceforge.net/lists/listinfo/gambas-user >>> > >>> > >>> > >>> Well, here is a very dirty tentative to show what could be done. >>> I don't really tested all the cases and it is surely not robust too! >>> >>> I take 5 forms, each of one with a checkbox to simulate different user >>> input and 3 buttons, Back, Next and Cancel >>> the chaining is not totally linear as I understand your wizard is >>> The "stack" is a Gridview (sort of static array bidimensional) wich I >>> display on the main form after all the steps >>> the first column is the tag of the active form, and the others give the >>> status of the 5 checkboxes >>> >>> hope this help >>> Dominique Simonart >> ------- End of Original Message ------- >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas.fr at ...626... Sat Dec 13 09:23:30 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 13 Dec 2008 09:23:30 +0100 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <1f1e8c1b0812111140g6a7ade10ncc5c0fcce99ddac8@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> <4941D65C.3060705@...11...> <20081212174619.M65094@...951...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> Message-ID: <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> it better to have a demo ... and it work fine ... take it and tell me if that is what you want. -------------- next part -------------- A non-text attachment was scrubbed... Name: demowizard-0.0.2.tar.gz Type: application/x-gzip Size: 10858 bytes Desc: not available URL: From ron at ...1740... Sat Dec 13 13:28:33 2008 From: ron at ...1740... (Ron) Date: Sat, 13 Dec 2008 13:28:33 +0100 Subject: [Gambas-user] Hex string to float In-Reply-To: <20081212203820.M23548@...951...> References: <4940F76D.800@...1740...> <4942630E.3040704@...1740...> <200812121942.10361.ronstk@...239...> <20081212203820.M23548@...951...> Message-ID: <4943AA71.7020202@...1740...> nando schreef: > Two Questions: > 1) Is the HEX you show below the HEX representation of 4B of a IEEE 4B Float? > 2) How do you get these values? (read in from file? something else?) > -Fernando > > Yes those where IEEE floats, I needed the routine to decode values read from zigbee devices called plugwise, they measure power usage very precise see here http://www.domoticaforum.eu/topic.asp?TOPIC_ID=1771 Regards, Ron_2nd From hjherbert at ...20... Sat Dec 13 17:06:09 2008 From: hjherbert at ...20... (hjherbert at ...20...) Date: Sat, 13 Dec 2008 17:06:09 +0100 Subject: [Gambas-user] Hex string to float Message-ID: <1129321177@...20...> Float number as you mean are 32 bit float numbers see http://en.wikipedia.org/wiki/Single_precision Float numbers in GAMBAS are 64 bit float numbers see http://en.wikipedia.org/wiki/Double_precision The follow program demonstrates how to convert a 64 Bit long value into a 64 bit gambas FLOAT (=double precision) value: PUBLIC SUB Main() DIM f AS Float DIM l AS Long DIM hH AS File l = &h3fd5555555555555& OPEN "/tmp/hexfloat.tmp" FOR WRITE CREATE AS #hH WRITE #hH, l CLOSE #hH OPEN "/tmp/hexfloat.tmp" FOR READ AS #hH READ #hH, f CLOSE #hH PRINT "l=", l, "HEX", Hex$(l), " f=", f END From hjherbert at ...20... Sat Dec 13 17:21:39 2008 From: hjherbert at ...20... (hjherbert at ...20...) Date: Sat, 13 Dec 2008 17:21:39 +0100 Subject: [Gambas-user] Hex string to float Message-ID: <1129324997@...20...> ... For 32 Float use the "Single" data type. See http://gambasdoc.org/help/cat/datatypes See http://gambasdoc.org/help/lang/type/single The example conversion may be done by this way: PUBLIC SUB DemoSingle() DIM i AS Integer DIM f AS Single DIM hH AS File i = &h3fd55555& OPEN "/tmp/hexfloat.tmp" FOR WRITE CREATE AS #hH WRITE #hH, i CLOSE #hH OPEN "/tmp/hexfloat.tmp" FOR READ AS #hH READ #hH, f CLOSE #hH PRINT "i=", i, "HEX", Hex$(i), " f=", f END From nando_f at ...951... Sat Dec 13 18:26:06 2008 From: nando_f at ...951... (nando) Date: Sat, 13 Dec 2008 12:26:06 -0500 Subject: [Gambas-user] Hex string to float In-Reply-To: <4943AA71.7020202@...1740...> References: <4940F76D.800@...1740...> <4942630E.3040704@...1740...> <200812121942.10361.ronstk@...239...> <20081212203820.M23548@...951...> <4943AA71.7020202@...1740...> Message-ID: <20081213172135.M10295@...951...> A few more questions: How do you get these values (reading a stream, file, rs232, ?) How do you save these when you read them? Are you reading/capturing 4 bytes or 8 Hex digits? -Fernando ---------- Original Message ----------- From: Ron To: nando_f at ...951..., mailing list for gambas users Sent: Sat, 13 Dec 2008 13:28:33 +0100 Subject: Re: [Gambas-user] Hex string to float > nando schreef: > > Two Questions: > > 1) Is the HEX you show below the HEX representation of 4B of a IEEE 4B Float? > > 2) How do you get these values? (read in from file? something else?) > > -Fernando > > > > > > Yes those where IEEE floats, I needed the routine to decode values read > from zigbee devices called plugwise, they measure power usage very precise > see here http://www.domoticaforum.eu/topic.asp?TOPIC_ID=1771 > > Regards, > Ron_2nd > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From nando_f at ...951... Sat Dec 13 18:43:50 2008 From: nando_f at ...951... (nando) Date: Sat, 13 Dec 2008 12:43:50 -0500 Subject: [Gambas-user] Hex string to float In-Reply-To: <1129324997@...20...> References: <1129324997@...20...> Message-ID: <20081213173452.M59655@...951...> I'm sorry, but I cannot see this as correct. Saving a 4 byte value in integer format then reading in the same 4 byte value and place it in an float variable performs no conversion. Conversion is needed due to how we want to interpret the type of data. ---------- Original Message ----------- From: hjherbert at ...20... To: gambas-user at lists.sourceforge.net Sent: Sat, 13 Dec 2008 17:21:39 +0100 Subject: Re: [Gambas-user] Hex string to float > ... For 32 Float use the "Single" data type. > See http://gambasdoc.org/help/cat/datatypes > See http://gambasdoc.org/help/lang/type/single > > The example conversion may be done by this way: > > PUBLIC SUB DemoSingle() > DIM i AS Integer > DIM f AS Single > DIM hH AS File > > i = &h3fd55555& > OPEN "/tmp/hexfloat.tmp" FOR WRITE CREATE AS #hH > WRITE #hH, i > CLOSE #hH > OPEN "/tmp/hexfloat.tmp" FOR READ AS #hH > READ #hH, f > CLOSE #hH > PRINT "i=", i, "HEX", Hex$(i), " f=", f > END > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From jussi.lahtinen at ...626... Sat Dec 13 18:54:04 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sat, 13 Dec 2008 19:54:04 +0200 Subject: [Gambas-user] An other problem with object oriented approach. Message-ID: <384d3900812130954k17617d8ah9e88e3dbdc123a0f@...627...> Hi! I'm converting Vb6 project to Gambas. And because Gambas doesn't have UDT/structures, I have to rethink some of the code (not necessary bad thing). I'm converting some parts of the code to object oriented way. But I run into some problems with it. I have module which contains mainly global arrays and global UDT arrays. That module describe items, every item is identified by index number. Like this (vb6 code): Global Alive(Max_Number_Of_Items) as boolean So if I want to know if item 2 is alive, I'll write: IF Alive[2] = TRUE THEN Problem is in identification, items have to know who is who. Old array based code is something like this: IF Alive[Who] = TRUE THEN ComWith = CommunicateWith[Who] IF Alive[ComWith] = TRUE THEN WhereX[ComWith] = ... WhereY[ComWith] = ... ... And when I want to save/load items to/from file, I use Id <--> Index translation function which translates CommunicateWith array with ID array. But that is way too slow to use at normal execution, it is useful only on file operations. If I convert these items to objects, there is not much point to use Alive array (etc.), I'll just remove dead items and add new one only when needed. But that creates problem with identification, since I can't use index numbers anymore! And looping every item to see if it have right Id number (that matches to CommunicateWith[WhoEverAsk]) is way too slow (like in Id <--> Index translation function). Slow because there are many(!) items, and every item should be checked against every item! So, any ideas how to implement fast identification between objects? Other words, how to translate Id to Index without looping? I'm trying to learn object oriented style and right now it's very difficult to stretch my brains around it... Jussi From gambas at ...1938... Sat Dec 13 18:57:08 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Sat, 13 Dec 2008 18:57:08 +0100 Subject: [Gambas-user] Command completion Message-ID: <200812131857.08427.gambas@...1938...> Hi Benoit, in Gambas3 (snapshot from friday), when writing a long line, so that the IDE begins to scroll, there is no command completion anymore. Greetz Stevie From wdahn at ...1000... Sat Dec 13 19:10:30 2008 From: wdahn at ...1000... (Werner) Date: Sun, 14 Dec 2008 02:10:30 +0800 Subject: [Gambas-user] An other problem with object oriented approach. In-Reply-To: <384d3900812130954k17617d8ah9e88e3dbdc123a0f@...627...> References: <384d3900812130954k17617d8ah9e88e3dbdc123a0f@...627...> Message-ID: <4943FA96.1010609@...1000...> Jussi Lahtinen wrote: > Hi! > > I'm converting Vb6 project to Gambas. > And because Gambas doesn't have UDT/structures, I have to rethink some > of the code (not necessary bad thing). > I'm converting some parts of the code to object oriented way. > But I run into some problems with it. > I have module which contains mainly global arrays and global UDT arrays. > That module describe items, every item is identified by index number. > Like this (vb6 code): > Global Alive(Max_Number_Of_Items) as boolean > > So if I want to know if item 2 is alive, I'll write: > IF Alive[2] = TRUE THEN > > Problem is in identification, items have to know who is who. > Old array based code is something like this: > > IF Alive[Who] = TRUE THEN > ComWith = CommunicateWith[Who] > IF Alive[ComWith] = TRUE THEN > WhereX[ComWith] = ... > WhereY[ComWith] = ... > ... > > And when I want to save/load items to/from file, I use Id <--> Index > translation function which translates CommunicateWith array with ID > array. > But that is way too slow to use at normal execution, it is useful only > on file operations. > If I convert these items to objects, there is not much point to use > Alive array (etc.), I'll just remove dead items and add new one only > when needed. But that creates problem with identification, since I > can't use index numbers anymore! > And looping every item to see if it have right Id number (that matches > to CommunicateWith[WhoEverAsk]) is way too slow (like in > Id <--> Index translation function). > Slow because there are many(!) items, and every item should be checked > against every item! > > So, any ideas how to implement fast identification between objects? > Other words, how to translate Id to Index without looping? > > I'm trying to learn object oriented style and right now it's very > difficult to stretch my brains around it... > > > Jussi > If there is anything unique in your items you could use a collection instead of an array and use the unique part as a key. Werner From doriano.blengino at ...1909... Sat Dec 13 20:05:54 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Sat, 13 Dec 2008 20:05:54 +0100 Subject: [Gambas-user] Hex string to float In-Reply-To: <20081213173452.M59655@...951...> References: <1129324997@...20...> <20081213173452.M59655@...951...> Message-ID: <49440792.1020205@...1909...> nando ha scritto: > I'm sorry, but I cannot see this as correct. > Saving a 4 byte value in integer format then > reading in the same 4 byte value and place it in an float variable > performs no conversion. > Conversion is needed due to how we want to interpret the type of data. > Indeed it does (perhaps a different syntax should be used - the one which writes in binary format). The problem is that it is easy to write an integer constant in the correct form (&h...); different is the case when you read them from somewhere - they can have a different byte order or format (in this case you can manipulate them). Another problem is to use a file for doing this - this is a great waste of resources; gambas has pointers too, but they are difficult to use. Regards, Doriano > > > ---------- Original Message ----------- > From: hjherbert at ...20... > To: gambas-user at lists.sourceforge.net > Sent: Sat, 13 Dec 2008 17:21:39 +0100 > Subject: Re: [Gambas-user] Hex string to float > > >> ... For 32 Float use the "Single" data type. >> See http://gambasdoc.org/help/cat/datatypes >> See http://gambasdoc.org/help/lang/type/single >> >> The example conversion may be done by this way: >> >> PUBLIC SUB DemoSingle() >> DIM i AS Integer >> DIM f AS Single >> DIM hH AS File >> >> i = &h3fd55555& >> OPEN "/tmp/hexfloat.tmp" FOR WRITE CREATE AS #hH >> WRITE #hH, i >> CLOSE #hH >> OPEN "/tmp/hexfloat.tmp" FOR READ AS #hH >> READ #hH, f >> CLOSE #hH >> PRINT "i=", i, "HEX", Hex$(i), " f=", f >> END >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From gambas.fr at ...626... Sat Dec 13 20:22:12 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Sat, 13 Dec 2008 20:22:12 +0100 Subject: [Gambas-user] An other problem with object oriented approach. In-Reply-To: <4943FA96.1010609@...1000...> References: <384d3900812130954k17617d8ah9e88e3dbdc123a0f@...627...> <4943FA96.1010609@...1000...> Message-ID: <6324a42a0812131122n58822608s95cfd6c0aa34fecb@...627...> yes you soluce is collection 2008/12/13 Werner : > Jussi Lahtinen wrote: >> Hi! >> >> I'm converting Vb6 project to Gambas. >> And because Gambas doesn't have UDT/structures, I have to rethink some >> of the code (not necessary bad thing). >> I'm converting some parts of the code to object oriented way. >> But I run into some problems with it. >> I have module which contains mainly global arrays and global UDT arrays. >> That module describe items, every item is identified by index number. >> Like this (vb6 code): >> Global Alive(Max_Number_Of_Items) as boolean >> >> So if I want to know if item 2 is alive, I'll write: >> IF Alive[2] = TRUE THEN >> >> Problem is in identification, items have to know who is who. >> Old array based code is something like this: >> >> IF Alive[Who] = TRUE THEN >> ComWith = CommunicateWith[Who] >> IF Alive[ComWith] = TRUE THEN >> WhereX[ComWith] = ... >> WhereY[ComWith] = ... >> ... >> >> And when I want to save/load items to/from file, I use Id <--> Index >> translation function which translates CommunicateWith array with ID >> array. >> But that is way too slow to use at normal execution, it is useful only >> on file operations. >> If I convert these items to objects, there is not much point to use >> Alive array (etc.), I'll just remove dead items and add new one only >> when needed. But that creates problem with identification, since I >> can't use index numbers anymore! >> And looping every item to see if it have right Id number (that matches >> to CommunicateWith[WhoEverAsk]) is way too slow (like in >> Id <--> Index translation function). >> Slow because there are many(!) items, and every item should be checked >> against every item! >> >> So, any ideas how to implement fast identification between objects? >> Other words, how to translate Id to Index without looping? >> >> I'm trying to learn object oriented style and right now it's very >> difficult to stretch my brains around it... >> >> >> Jussi >> > If there is anything unique in your items you could use a collection > instead of an array and use the unique part as a key. > Werner > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jussi.lahtinen at ...626... Sat Dec 13 21:37:30 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sat, 13 Dec 2008 22:37:30 +0200 Subject: [Gambas-user] An other problem with object oriented approach. In-Reply-To: <6324a42a0812131122n58822608s95cfd6c0aa34fecb@...627...> References: <384d3900812130954k17617d8ah9e88e3dbdc123a0f@...627...> <4943FA96.1010609@...1000...> <6324a42a0812131122n58822608s95cfd6c0aa34fecb@...627...> Message-ID: <384d3900812131237r6219d7fcoe41081e3ac9f9f95@...627...> Ok, thanks! Those items have unique long type id number. Maybe I'm wrong but to me string keys sounds slow. Perhaps binary mode is quicker ( http://gambasdoc.org/help/comp/gb/collection/_new?show ). But I think this is the right way to go! I didn't find this from documentation, so do anyone know what $ sign means at declaration. Example: PRIVATE $iTotal AS Long Jussi On Sat, Dec 13, 2008 at 9:22 PM, Fabien Bodard wrote: > yes you soluce is collection > > > > 2008/12/13 Werner : >> Jussi Lahtinen wrote: >>> Hi! >>> >>> I'm converting Vb6 project to Gambas. >>> And because Gambas doesn't have UDT/structures, I have to rethink some >>> of the code (not necessary bad thing). >>> I'm converting some parts of the code to object oriented way. >>> But I run into some problems with it. >>> I have module which contains mainly global arrays and global UDT arrays. >>> That module describe items, every item is identified by index number. >>> Like this (vb6 code): >>> Global Alive(Max_Number_Of_Items) as boolean >>> >>> So if I want to know if item 2 is alive, I'll write: >>> IF Alive[2] = TRUE THEN >>> >>> Problem is in identification, items have to know who is who. >>> Old array based code is something like this: >>> >>> IF Alive[Who] = TRUE THEN >>> ComWith = CommunicateWith[Who] >>> IF Alive[ComWith] = TRUE THEN >>> WhereX[ComWith] = ... >>> WhereY[ComWith] = ... >>> ... >>> >>> And when I want to save/load items to/from file, I use Id <--> Index >>> translation function which translates CommunicateWith array with ID >>> array. >>> But that is way too slow to use at normal execution, it is useful only >>> on file operations. >>> If I convert these items to objects, there is not much point to use >>> Alive array (etc.), I'll just remove dead items and add new one only >>> when needed. But that creates problem with identification, since I >>> can't use index numbers anymore! >>> And looping every item to see if it have right Id number (that matches >>> to CommunicateWith[WhoEverAsk]) is way too slow (like in >>> Id <--> Index translation function). >>> Slow because there are many(!) items, and every item should be checked >>> against every item! >>> >>> So, any ideas how to implement fast identification between objects? >>> Other words, how to translate Id to Index without looping? >>> >>> I'm trying to learn object oriented style and right now it's very >>> difficult to stretch my brains around it... >>> >>> >>> Jussi >>> >> If there is anything unique in your items you could use a collection >> instead of an array and use the unique part as a key. >> Werner >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Sat Dec 13 23:45:31 2008 From: gambas at ...1... (Benoit Minisini) Date: Sat, 13 Dec 2008 23:45:31 +0100 Subject: [Gambas-user] An other problem with object oriented approach. In-Reply-To: <384d3900812131237r6219d7fcoe41081e3ac9f9f95@...627...> References: <384d3900812130954k17617d8ah9e88e3dbdc123a0f@...627...> <6324a42a0812131122n58822608s95cfd6c0aa34fecb@...627...> <384d3900812131237r6219d7fcoe41081e3ac9f9f95@...627...> Message-ID: <200812132345.31513.gambas@...1...> On samedi 13 d?cembre 2008, Jussi Lahtinen wrote: > Ok, thanks! > Those items have unique long type id number. > Maybe I'm wrong but to me string keys sounds slow. > Perhaps binary mode is quicker ( > http://gambasdoc.org/help/comp/gb/collection/_new?show ). > But I think this is the right way to go! > > I didn't find this from documentation, so do anyone know what $ sign > means at declaration. > Example: > PRIVATE $iTotal AS Long > > > Jussi > The '$' sign is just a character that you can use inside an indentifier. I use it at the beginning to name a private class variable. For public class variable, I use Pascal notation. Regards, -- Benoit Minisini From leonardo at ...1237... Sun Dec 14 00:52:49 2008 From: leonardo at ...1237... (Leonardo Miliani) Date: Sun, 14 Dec 2008 00:52:49 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <200812091254.24313.gambas@...1...> References: <493B093E.8050509@...1237...> <200812090142.29337.gambas@...1...> <493E3AFC.10602@...1237...> <200812091254.24313.gambas@...1...> Message-ID: <49444AD1.9070501@...1237...> Benoit Minisini ha scritto: > On mardi 9 d?cembre 2008, Leonardo Miliani wrote: >> Benoit Minisini ha scritto: >>> On mardi 9 d?cembre 2008, Ga?l Le Hec'H wrote: >>>> I confirm the problem on fedora 10 with gnome 2.24.2 and gambas2 2.9.0 >>>> with the clock example >>>> >>>> Ga?l Le Hec'H >>> Just an idea: do you use Compiz? >> No, I don't. >> I attach a screenshot to let you see the problem. > > The mask is actually applied. Just that the window manager shows the windows > borders, whereas it was requested not to do that. > Strange thing... If I create a new project, the mask property works correctly and the borders don't visualize... So the problems appears only opening old projects: is there any change internally at Gambas? -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software Co-fondatore di Gambas-it.org Il sito di riferimento della comunit? italiana degli utenti di Gambas www.gambas-it.org From rterry at ...1946... Sun Dec 14 04:30:42 2008 From: rterry at ...1946... (richard terry) Date: Sun, 14 Dec 2008 14:30:42 +1100 Subject: [Gambas-user] Wish list for a tooltip feature Message-ID: <200812141430.42126.rterry@...1946...> I wondered if there would be any way or perhaps future feature to be able to set the tooltip font/size? Reason being that in some circumstances the font size is quite large compared to ones underlying control/design. Regards Richard From gambas at ...1... Sun Dec 14 08:39:51 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 14 Dec 2008 08:39:51 +0100 Subject: [Gambas-user] Wish list for a tooltip feature In-Reply-To: <200812141430.42126.rterry@...1946...> References: <200812141430.42126.rterry@...1946...> Message-ID: <200812140839.51817.gambas@...1...> On dimanche 14 d?cembre 2008, richard terry wrote: > I wondered if there would be any way or perhaps future feature to be able > to set the tooltip font/size? > > Reason being that in some circumstances the font size is quite large > compared to ones underlying control/design. > > Regards > > Richard > Quite large? By default the tooltip font is the desktop default font. Do you have a screenshot? -- Benoit Minisini From gambas at ...1... Sun Dec 14 08:40:51 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 14 Dec 2008 08:40:51 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <49444AD1.9070501@...1237...> References: <493B093E.8050509@...1237...> <200812091254.24313.gambas@...1...> <49444AD1.9070501@...1237...> Message-ID: <200812140840.51673.gambas@...1...> On dimanche 14 d?cembre 2008, Leonardo Miliani wrote: > Benoit Minisini ha scritto: > > On mardi 9 d?cembre 2008, Leonardo Miliani wrote: > >> Benoit Minisini ha scritto: > >>> On mardi 9 d?cembre 2008, Ga?l Le Hec'H wrote: > >>>> I confirm the problem on fedora 10 with gnome 2.24.2 and gambas2 2.9.0 > >>>> with the clock example > >>>> > >>>> Ga?l Le Hec'H > >>> > >>> Just an idea: do you use Compiz? > >> > >> No, I don't. > >> I attach a screenshot to let you see the problem. > > > > The mask is actually applied. Just that the window manager shows the > > windows borders, whereas it was requested not to do that. > > Strange thing... > If I create a new project, the mask property works correctly and the > borders don't visualize... So the problems appears only opening old > projects: is there any change internally at Gambas? Can you send me one of these old projects? (It seems to be a rule: always send the project!) -- Benoit Minisini From leonardo at ...1237... Sun Dec 14 10:29:11 2008 From: leonardo at ...1237... (Leonardo Miliani) Date: Sun, 14 Dec 2008 10:29:11 +0100 Subject: [Gambas-user] Bug in Gambas 2.9 and Gnome 2.24 In-Reply-To: <200812140840.51673.gambas@...1...> References: <493B093E.8050509@...1237...> <200812091254.24313.gambas@...1...> <49444AD1.9070501@...1237...> <200812140840.51673.gambas@...1...> Message-ID: <4944D1E7.1030504@...1237...> Benoit Minisini ha scritto: > On dimanche 14 d?cembre 2008, Leonardo Miliani wrote: >> Benoit Minisini ha scritto: >>> On mardi 9 d?cembre 2008, Leonardo Miliani wrote: >>>> Benoit Minisini ha scritto: >>>>> On mardi 9 d?cembre 2008, Ga?l Le Hec'H wrote: >>>>>> I confirm the problem on fedora 10 with gnome 2.24.2 and gambas2 2.9.0 >>>>>> with the clock example >>>>>> >>>>>> Ga?l Le Hec'H >>>>> Just an idea: do you use Compiz? >>>> No, I don't. >>>> I attach a screenshot to let you see the problem. >>> The mask is actually applied. Just that the window manager shows the >>> windows borders, whereas it was requested not to do that. >> Strange thing... >> If I create a new project, the mask property works correctly and the >> borders don't visualize... So the problems appears only opening old >> projects: is there any change internally at Gambas? > > Can you send me one of these old projects? (It seems to be a rule: always send > the project!) > The old project is the Clock example... -- Ciao. Leo. Web: www.leonardomiliani.com E-mail: leonardo at ...1237... Scegli software opensource - Choose opensource software Co-fondatore di Gambas-it.org Il sito di riferimento della comunit? italiana degli utenti di Gambas www.gambas-it.org From md9327 at ...120... Sun Dec 14 13:05:35 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sun, 14 Dec 2008 13:05:35 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type Message-ID: <1229256335.26984.1.camel@...37...> Gambas2 - versione 2.9.0 The single anomaly verification in a circumstance, that I will try to describe: - I have created a small static class that executes the logon to a database, executes query and returns the data in a structure much similar one to the logic applied to the Result/Field objects; at last the logon comes sluice. This my logic is created in order to avoid to leave the logon open and, since the Result object maintains the data single to opened logon, my class copy these data in an appropriate structure of Array of objects, that it comes returned to the procedures that use this function. - the calling procedures use this class, that the structure returns given, that comes used for determined scopes. - the logons can be made on database PostgreSQL, MySQL and SQLite; the query they come correctly executed, returning the corrected values, unless for MySQL. Like described in the first mail, one of the query executes a loading of information from a table of system of MySQL, used in order to determine the structure of the database. - some fields of this table are of type ?longtext? (BLOB). - Strangely, these fields return a value NULL, although their content is instead a valid data. - Verifying the Result object, immediately after the execution of the query, I have found that the value of this field is truly NULL, and this excludes an anomaly of my procedures. - To ulterior I have had confirmation, constructing it a small procedure of test, in which it executes the same operations made from my program, and that it uses the same static class; strangely, the query executed from the test program, it has given back a valid value in the field ?longtest?. - The thing has made me to rise a doubt: since my program is rather complex, he is probable exists some problem in memory (stack) with the management of fields BLOB? - Knowing enough language C/C++, I have given to a glance to the code source of the library, but the only thing that I have found is that fields BLOB come managed in way detail, but has not found details conditions that could make me to doubt on they a wrong management. The only thing that has come to me in mind, is perhaps that a problem of memory with programs exists many complexes, for which this type of data (blob) comes lost? - I have found this single anomaly in MySQL, but it is also true that the others dbms do not use this type of data (blob) in the system tables. Some suggestion? Thanks From md9327 at ...120... Sun Dec 14 13:08:36 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sun, 14 Dec 2008 13:08:36 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite Message-ID: <1229256516.26984.4.camel@...37...> In my application I execute a rescue on XML file of some data. The rescue executes before a conversion: Conv (string, ?UTF-8?, ?ASCII?) During my tests, I have noticed that some errors are taken place: 1) if the string is larger than 2000 characters (approximately), XmlWrite.Attribute() crash; 2) if the language comes set up to Chinese (UTF-8), the conversion with Conv() crash; same behavior if is used XmlWrite.Attribute(), or XmlWrite.Element(), without to execute conversions. I have noticed that the errors take place alone if System.Language=zh_CN and System.Charset=UTF-8, while with various languages seems to go all good. Error message: encoding error : output conversion failed due to conv error, bytes 0xE5 0x31 0x32 0xE5 I/O error : encoder error The bytes indicated from the message they do not seem to correspond, neither are comprised, in no string between those which they come saved in XML file. To notice that the reading from XML file is OK, while the writing finishes with the error described in mine precedence mail, if the writing of XML file with System.Language=zh_CN (Chinese); with other languages (Italian, French, English and Spanish) it is all to OK. >From some tests it begins them seemed that the anomaly depended also from the dimensions of the string, but this had to cause the crash also with the other formulations, what that instead does not happen. The strange thing that I have noticed, is that the dimensions of the content of the string, with Language=zh_CN, are much smaller of the usual; I imagine that this depends from as the String object it manages the data, but that turns out me also the Chinese characters use advanced values to 256. In any case, the application is too much large and complex for being sent and described in a mail? However, the errors take place (DEBUG) in the Save() method, for which at the moment shipment only the functions interested. If they serve more information, no problems. The function toString () works OK, and returns the attended string, but the conversion finishes then in error. '--- ' Save settings ' PUBLIC SUB Save() DIM oGroup AS pgConfigGroup DIM oItem AS pgConfigItem DIM oXml AS XmlWriter 'open file for writing oXml = NEW XmlWriter oXml.Open($filename, TRUE, "UTF8") 'write header oXml.StartElement(pgApplication.Name) oXml.Attribute("Type", Str("Config")) oXml.Attribute("Version", pgUtil.SetVersion(VERSION)) oXml.Attribute("Date", Str(Now())) 'write elements FOR EACH oGroup IN $data oXml.StartElement(oGroup.Name) FOR EACH oItem IN oGroup.Items oXml.Attribute(oItem.Name, Conv(oItem.toString(), "UTF-8", "ASCII")) NEXT oXml.EndElement NEXT 'write footer oXml.EndElement oXml.EndDocument END ... ... ... '--- ' Convert any value into single string ' PUBLIC FUNCTION toString() AS String DIM iPos AS Integer DIM aText AS String[] SELECT CASE $type CASE TYPE_STRING 'gb.String RETURN Str(IIf(IsNull($value), "", $value)) CASE TYPE_INTEGER 'gb.Integer RETURN Str(IIf(IsNull($value), "0", $value)) CASE TYPE_BOOLEAN 'gb.Boolean RETURN Str(IIf(IsNull($value), "false", IIf($value, "true", "false"))) CASE TYPE_STRINGARRAY 'String[] object IF (IsNull($value)) OR IF ($value.Count = 0) THEN RETURN Str("") RETURN Str($value.Join(",")) CASE TYPE_INTEGERARRAY 'Integer[] object IF (IsNull($value)) OR IF ($value.Count = 0) THEN RETURN Str("") aText = NEW String[] FOR EACH iPos IN $value aText.Add(Str(iPos)) NEXT RETURN Str(aText.Join(",")) CASE TYPE_COLOR 'custom color object RETURN Str(IIf(IsNull($value), "0,0,0", pgColor.ColorToStr($value))) END SELECT END Help? From nando_f at ...951... Sun Dec 14 21:23:04 2008 From: nando_f at ...951... (nando) Date: Sun, 14 Dec 2008 15:23:04 -0500 Subject: [Gambas-user] Hex string to float In-Reply-To: <49440792.1020205@...1909...> References: <1129324997@...20...> <20081213173452.M59655@...951...> <49440792.1020205@...1909...> Message-ID: <20081214201057.M47842@...951...> My apologies to all...I stand corrected for my mistake. The i = &h3fd55555& converts hex to integer and is easiest to do it this way. This method does performs as the original person wanted but is a waste to do disk IO. Perhaps a pipe, write the integer, read the single. Although I haven't investigated, Gambas3 has pointers. Copying 4B from a pointer to the 4B int to the 4B single will do it. There are (older) versions of BASIC that had (something like) MKI$, MKS$, MKD$ and counterparts (something like) CVI, CVS, CVD. They took a string and converted it to an Int Single Double. No conversion happened because the string was binary correct for the type. All it did was copy 2B, 4B 8B from/to a numeric var to/from string. If Benoit were to incorporate these functions, it makes Gambas easily perform IO of data types with ease to convert to native variables. Thanks, -Fernando ---------- Original Message ----------- From: Doriano Blengino To: nando_f at ...951..., mailing list for gambas users Sent: Sat, 13 Dec 2008 20:05:54 +0100 Subject: Re: [Gambas-user] Hex string to float > nando ha scritto: > > I'm sorry, but I cannot see this as correct. > > Saving a 4 byte value in integer format then > > reading in the same 4 byte value and place it in an float variable > > performs no conversion. > > Conversion is needed due to how we want to interpret the type of data. > > > Indeed it does (perhaps a different syntax should be used - the one > which writes in binary format). The problem is that it is easy to write > an integer constant in the correct form (&h...); different is the case > when you read them from somewhere - they can have a different byte order > or format (in this case you can manipulate them). > > Another problem is to use a file for doing this - this is a great waste > of resources; gambas has pointers too, but they are difficult to use. > > Regards, > Doriano > > > > > > ---------- Original Message ----------- > > From: hjherbert at ...20... > > To: gambas-user at lists.sourceforge.net > > Sent: Sat, 13 Dec 2008 17:21:39 +0100 > > Subject: Re: [Gambas-user] Hex string to float > > > > > >> ... For 32 Float use the "Single" data type. > >> See http://gambasdoc.org/help/cat/datatypes > >> See http://gambasdoc.org/help/lang/type/single > >> > >> The example conversion may be done by this way: > >> > >> PUBLIC SUB DemoSingle() > >> DIM i AS Integer > >> DIM f AS Single > >> DIM hH AS File > >> > >> i = &h3fd55555& > >> OPEN "/tmp/hexfloat.tmp" FOR WRITE CREATE AS #hH > >> WRITE #hH, i > >> CLOSE #hH > >> OPEN "/tmp/hexfloat.tmp" FOR READ AS #hH > >> READ #hH, f > >> CLOSE #hH > >> PRINT "i=", i, "HEX", Hex$(i), " f=", f > >> END > >> > >> ------------------------------------------------------------------------------ > >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >> The future of the web can't happen without you. Join us at MIX09 to help > >> pave the way to the Next Web now. Learn more and register at > >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > >> > > ------- End of Original Message ------- > > > > > > ------------------------------------------------------------------------------ > > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > > The future of the web can't happen without you. Join us at MIX09 to help > > pave the way to the Next Web now. Learn more and register at > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > -- > Doriano Blengino > > "Listen twice before you speak. > This is why we have two ears, but only one mouth." > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From rterry at ...1946... Sun Dec 14 22:14:28 2008 From: rterry at ...1946... (richard terry) Date: Mon, 15 Dec 2008 08:14:28 +1100 Subject: [Gambas-user] Wish list for a tooltip feature In-Reply-To: <200812142204.58099.gambas@...1...> References: <200812141430.42126.rterry@...1946...> <200812150735.02009.rterry@...1946...> <200812142204.58099.gambas@...1...> Message-ID: <200812150814.28389.rterry@...1946...> On Mon, 15 Dec 2008 08:04:58 am Benoit Minisini wrote: > On dimanche 14 d?cembre 2008, richard terry wrote: > > On Sun, 14 Dec 2008 06:39:51 pm you wrote: > > > On dimanche 14 d?cembre 2008, richard terry wrote: > > > > I wondered if there would be any way or perhaps future feature to be > > > > able to set the tooltip font/size? > > > > > > > > Reason being that in some circumstances the font size is quite large > > > > compared to ones underlying control/design. > > > > > > > > Regards > > > > > > > > Richard > > > > > > Quite large? By default the tooltip font is the desktop default font. > > > Do you have a screenshot? > > > > Maybe it does match the tooltips font, but as the fonts in my program > > are -1, -2 quiite often, the popup tooltip looks big - here I'm using it > > as a list of BP's and dates if the user clicks over spread out list which > > has been graphed below. Looks too big and ugly. Hey, a popup html label > > would be the go!!!! > > > > Regards > > > > richard > > Set Application.Tooltip.Font so! Ah, sorry, that works well, but perhaps the popup tooltip could be a html label for greater versitility?. Regards Richard From gambas at ...1... Sun Dec 14 22:28:35 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 14 Dec 2008 22:28:35 +0100 Subject: [Gambas-user] Hex string to float In-Reply-To: <20081214201057.M47842@...951...> References: <1129324997@...20...> <49440792.1020205@...1909...> <20081214201057.M47842@...951...> Message-ID: <200812142228.35988.gambas@...1...> On dimanche 14 d?cembre 2008, nando wrote: > My apologies to all...I stand corrected for my mistake. > The i = &h3fd55555& converts hex to integer and is easiest to do it this > way. This method does performs as the original person wanted but is a waste > to do disk IO. Perhaps a pipe, write the integer, read the single. > Although I haven't investigated, Gambas3 has pointers. > Copying 4B from a pointer to the 4B int to the 4B single will do it. > There are (older) versions of BASIC that had (something like) MKI$, MKS$, > MKD$ and counterparts (something like) CVI, CVS, CVD. They took a string > and converted it to an Int Single Double. No conversion happened because > the string was binary correct for the type. All it did was copy 2B, 4B 8B > from/to a numeric var to/from string. > If Benoit were to incorporate these functions, it makes Gambas easily > perform IO of data types with ease to convert to native variables. > Thanks, > -Fernando > Yeh, this is planed. Anyway, you can do these conversion in Gambas 2 (and 3) this way: DIM sSrc AS String DIM eDst AS Float DIM pPtr AS Pointer pPtr = Alloc(8) WRITE #pPtr, sSrc, 8 READ #pPtr, eDst Free(pPtr) But beware with the endianness! -- Benoit Minisini From ron at ...1740... Sun Dec 14 23:21:44 2008 From: ron at ...1740... (Ron) Date: Sun, 14 Dec 2008 23:21:44 +0100 Subject: [Gambas-user] Hex string to float In-Reply-To: <200812142228.35988.gambas@...1...> References: <1129324997@...20...> <49440792.1020205@...1909...> <20081214201057.M47842@...951...> <200812142228.35988.gambas@...1...> Message-ID: <494586F8.6060305@...1740...> Benoit Minisini wrote: > On dimanche 14 d?cembre 2008, nando wrote: > >> My apologies to all...I stand corrected for my mistake. >> The i = &h3fd55555& converts hex to integer and is easiest to do it this >> way. This method does performs as the original person wanted but is a waste >> to do disk IO. Perhaps a pipe, write the integer, read the single. >> Although I haven't investigated, Gambas3 has pointers. >> Copying 4B from a pointer to the 4B int to the 4B single will do it. >> There are (older) versions of BASIC that had (something like) MKI$, MKS$, >> MKD$ and counterparts (something like) CVI, CVS, CVD. They took a string >> and converted it to an Int Single Double. No conversion happened because >> the string was binary correct for the type. All it did was copy 2B, 4B 8B >> from/to a numeric var to/from string. >> If Benoit were to incorporate these functions, it makes Gambas easily >> perform IO of data types with ease to convert to native variables. >> Thanks, >> -Fernando >> >> > > Yeh, this is planed. > > Anyway, you can do these conversion in Gambas 2 (and 3) this way: > > DIM sSrc AS String > DIM eDst AS Float > DIM pPtr AS Pointer > > pPtr = Alloc(8) > WRITE #pPtr, sSrc, 8 > READ #pPtr, eDst > Free(pPtr) > > But beware with the endianness! > > I'm not sure about who's float this thread is about at this moment, or if I use these routines false, but these calculations do not output a correct result for my need (converting a 8char lenght hex string to a ieee float http://steve.hollasch.net/cgindex/coding/ieeefloat.html , my original routine does, thought could maybe use some optimizations. It's now down to: PUBLIC FUNCTION HexToFloat(sHex AS String) AS Float DIM sTemp AS String DIM iSign AS Integer DIM fExponent, fMant AS Float ' sign iSign = IIf((Val("&H" & Mid(sHex, 1, 2)) AND &H80) = 128, -1, 1) ' exponent fExponent = (Val("&H" & Mid(sHex, 1, 3)) AND &H7F8) / 2 ^ 3 - 127 ' mantissa fMant = (Val("&H" & Mid(sHex, 3, 6)) AND &H7FFFFF) / 2 ^ 23 + 1 RETURN iSign * fMant * 2 ^ fExponent END Regards, Ron_2nd From sourceforge-raindog2 at ...94... Sun Dec 14 22:38:13 2008 From: sourceforge-raindog2 at ...94... (Rob) Date: Sun, 14 Dec 2008 16:38:13 -0500 Subject: [Gambas-user] Problem with gambas wiki web site In-Reply-To: <200812121730.46376.gambas@...1...> References: <200812121730.46376.gambas@...1...> Message-ID: <200812141638.14128.sourceforge-raindog2@...94...> On Friday 12 December 2008 11:30, Benoit Minisini wrote: > Apparently gambasdoc.org does not answer anymore, nor kudla.org, the > domain where you can write to Rob Kudla, the gambasdoc.org server owner. > If you read that Rob, please tell us what happens! We had an ice storm here in the northern part of New York. My company's servers were completely offline for at least a day. I still have no power (or heat, or net connection) at home, they don't know whether it'll be back in 2 hours or 2 days, and it's about 5 degrees C there. Now I'm staying with a friend and this is the first time I've gotten online since Thursday night. I imagine the outage lasted long enough that some mail to me must have bounced. I see some gaps in the delivery times on my Linux mailing lists. This is a very uncommon occurrence (first power failure longer than 7 hours I've ever experienced) but obviously I need to prepare better for power outages. It looks like the site's back up now, anyway. Let me know if anything acts strangely. Rob From jguardon at ...2035... Sun Dec 14 22:32:29 2008 From: jguardon at ...2035... (Jesus Guardon) Date: Sun, 14 Dec 2008 13:32:29 -0800 (PST) Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <493955B5.5090203@...1909...> References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> Message-ID: <21004918.post@...1379...> Doriano Blengino wrote: > > simple linear transformation is possible by using draw.translate() and > draw.scale(); draw.reset() will reset the transformation matrix. > Draw.push() and draw.pop() exist to save and restore the matrix. > > I think this is enough to map simple world 2D coordinates; it is > effective and scales everything but text. > > For more complicated things, they should be implemented in software. > > Regards, > Doriano Blengino > Hi all Well, I'm totally lost with this subject. What I'm trying to do is to map the real world coordinates into a picture of a geographical map of Europe, for plotting parallels, meridians and some other stuff. Lets say we have a picture of Europe 800x600px and its real coordinates are: 72N -25W (upper left corner) and -18S 44E (bottom right corner). How do I translate pixels to coordinates to draw on the map directly using real coordinates? I don't understand very well what matrices are, and how to apply with Gambas syntax. Any example or explanation on how to accomplish this project are welcome. This is what I did so far in VB.net, but this is another history... :-) (in Spanish): http://ea7dfh.es/MapLoc/ Thanks, Jesus -- View this message in context: http://www.nabble.com/Coordinate-system-in-Gambas-Graphics-tp20818380p21004918.html Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Sun Dec 14 23:36:16 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 14 Dec 2008 23:36:16 +0100 Subject: [Gambas-user] Problem with gambas wiki web site In-Reply-To: <200812141638.14128.sourceforge-raindog2@...94...> References: <200812121730.46376.gambas@...1...> <200812141638.14128.sourceforge-raindog2@...94...> Message-ID: <200812142336.16810.gambas@...1...> On dimanche 14 d?cembre 2008, Rob wrote: > On Friday 12 December 2008 11:30, Benoit Minisini wrote: > > Apparently gambasdoc.org does not answer anymore, nor kudla.org, the > > domain where you can write to Rob Kudla, the gambasdoc.org server owner. > > If you read that Rob, please tell us what happens! > > We had an ice storm here in the northern part of New York. My company's > servers were completely offline for at least a day. I still have no power > (or heat, or net connection) at home, they don't know whether it'll be > back in 2 hours or 2 days, and it's about 5 degrees C there. Now I'm > staying with a friend and this is the first time I've gotten online since > Thursday night. > > I imagine the outage lasted long enough that some mail to me must have > bounced. I see some gaps in the delivery times on my Linux mailing lists. > This is a very uncommon occurrence (first power failure longer than 7 > hours I've ever experienced) but obviously I need to prepare better for > power outages. It looks like the site's back up now, anyway. Let me know > if anything acts strangely. > > Rob > wow... Everything seems to be normal now. -- Benoit Minisini From nando_f at ...951... Mon Dec 15 00:52:24 2008 From: nando_f at ...951... (nando) Date: Sun, 14 Dec 2008 18:52:24 -0500 Subject: [Gambas-user] Hex string to float In-Reply-To: <200812142228.35988.gambas@...1...> References: <1129324997@...20...> <49440792.1020205@...1909...> <20081214201057.M47842@...951...> <200812142228.35988.gambas@...1...> Message-ID: <20081214235211.M42216@...951...> brilliant! ---------- Original Message ----------- From: Benoit Minisini To: nando_f at ...951..., mailing list for gambas users Sent: Sun, 14 Dec 2008 22:28:35 +0100 Subject: Re: [Gambas-user] Hex string to float > On dimanche 14 d?cembre 2008, nando wrote: > > My apologies to all...I stand corrected for my mistake. > > The i = &h3fd55555& converts hex to integer and is easiest to do it this > > way. This method does performs as the original person wanted but is a waste > > to do disk IO. Perhaps a pipe, write the integer, read the single. > > Although I haven't investigated, Gambas3 has pointers. > > Copying 4B from a pointer to the 4B int to the 4B single will do it. > > There are (older) versions of BASIC that had (something like) MKI$, MKS$, > > MKD$ and counterparts (something like) CVI, CVS, CVD. They took a string > > and converted it to an Int Single Double. No conversion happened because > > the string was binary correct for the type. All it did was copy 2B, 4B 8B > > from/to a numeric var to/from string. > > If Benoit were to incorporate these functions, it makes Gambas easily > > perform IO of data types with ease to convert to native variables. > > Thanks, > > -Fernando > > > > Yeh, this is planed. > > Anyway, you can do these conversion in Gambas 2 (and 3) this way: > > DIM sSrc AS String > DIM eDst AS Float > DIM pPtr AS Pointer > > pPtr = Alloc(8) > WRITE #pPtr, sSrc, 8 > READ #pPtr, eDst > Free(pPtr) > > But beware with the endianness! > > -- > Benoit Minisini > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From doriano.blengino at ...1909... Mon Dec 15 10:40:05 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Mon, 15 Dec 2008 10:40:05 +0100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <21004918.post@...1379...> References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> <21004918.post@...1379...> Message-ID: <494625F5.6030608@...1909...> Jesus Guardon ha scritto: > > Doriano Blengino wrote: > >> simple linear transformation is possible by using draw.translate() and >> draw.scale(); draw.reset() will reset the transformation matrix. >> Draw.push() and draw.pop() exist to save and restore the matrix. >> >> > Hi all > > Well, I'm totally lost with this subject. What I'm trying to do is to map > the real world coordinates into a picture of a geographical map of Europe, > for plotting parallels, meridians and some other stuff. > > Lets say we have a picture of Europe 800x600px and its real coordinates are: > 72N -25W (upper left corner) and -18S 44E (bottom right corner). How do I > translate pixels to coordinates to draw on the map directly using real > coordinates? > I don't understand very well what matrices are, and how to apply with Gambas > syntax. > Any example or explanation on how to accomplish this project are welcome. > > This is what I did so far in VB.net, but this is another history... :-) > (in Spanish): http://ea7dfh.es/MapLoc/ > I've set up a simple project to show how the transformation matrix works. It draws a line from (0;0) to an arbitrary point you specify in LX: and LY:. You can play with Draw.XXX fields to see they effect. What I discovered is that (gambas vesion 2.0.0): 1) For me, negative scalings do not work; this is a *serious* limitation. 2) Offsets are multiplied by scaling, ie they are expressed in "real world" coordinates. 3) Perhaps I am missing something, but it seems to me that you can not read what is the current transformation matrix; the program should keep track of this. Now, I don't know what "72N" and "-25W" mean (I think north and west, but that is all), anyway, supposing that they are arbitrary measurement units, then your map is 44+25 units wide, and 72+18 units tall, ie 69 x 90. You want map this to a 800 x 600. If you don't care about aspect ratio, then do Draw.scale(800 / 69, 600 / 90). If you want to mantain aspect ratio (it should be), you assign the same value to scalex and scaley, the smaller of the two: 800/69=11.59, 600/90=6.66, so do Draw.scale(6.66, 6.66). As your upper left corner is -25W and 72N, you must do Draw.translate(25, -72). At this point, plotting a (25; 72) should go to (0; 0) in the drawing area. From here ahead, I think there is a problem with the computer graphics having Y axis pointing to the bottom, so may be your map will be flipped up side down. Every Y coordinate should be transformed by newy = MapHeight-y, so a different draw.translate() must be issued. Anyway, it seems to me that the combination of Scale() and Translate() does the following: coordinate_to_plot = (programmed_coordinate + translate_value) * scale_value Hope this is enough - I well could have done lot of errors, but the test project can let you experiment. Regards, Doriano -------------- next part -------------- A non-text attachment was scrubbed... Name: TestDraw-0.0.1.tar.gz Type: application/x-gzip Size: 8134 bytes Desc: not available URL: From wig at ...1809... Mon Dec 15 12:22:40 2008 From: wig at ...1809... (wig) Date: Mon, 15 Dec 2008 12:22:40 +0100 (CET) Subject: [Gambas-user] import mysql dump Message-ID: <40852.81.247.107.186.1229340160.squirrel@...1810...> Although I can create table by table from within Gambas with hCon.Databases.Add(sDbName), I wondered if there is a way to "import" a mysql dump file, so that I can create the tables with data (in one command). Untill now I allways used phpMyAdmin dump/export and import for creating the database structure and initial data, but I want to integrate it in my Gambas application. From m0e.lnx at ...626... Mon Dec 15 14:59:38 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Mon, 15 Dec 2008 07:59:38 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <494176B8.7080804@...11...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> <4941D65C.3060705@...11...> <20081212174619.M65094@...951...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> Message-ID: <1f1e8c1b0812150559j1e280b8bvbaecdb2cade5e9b4@...627...> Yes!... this is exactly how I need it to work. Thank you On Sat, Dec 13, 2008 at 2:23 AM, Fabien Bodard wrote: > it better to have a demo ... and it work fine ... > > take it and tell me if that is what you want. > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > From wdahn at ...1000... Mon Dec 15 16:03:34 2008 From: wdahn at ...1000... (Werner) Date: Mon, 15 Dec 2008 23:03:34 +0800 Subject: [Gambas-user] import mysql dump In-Reply-To: <40852.81.247.107.186.1229340160.squirrel@...1810...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> Message-ID: <494671C6.5040203@...1000...> wig wrote: > Although I can create table by table from within Gambas with > hCon.Databases.Add(sDbName), I wondered if there is a way to "import" a > mysql dump file, so that I can create the tables with data (in one > command). > > Untill now I allways used phpMyAdmin dump/export and import for creating > the database structure and initial data, but I want to integrate it in my > Gambas application. > > > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > You could use the EXEC command to run the appropriate mysqlsomething utility (don't recall which) Regards Werner From m0e.lnx at ...626... Mon Dec 15 16:34:30 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Mon, 15 Dec 2008 09:34:30 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812150559j1e280b8bvbaecdb2cade5e9b4@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <1f1e8c1b0812111250r5a63b209h1e7ebf4e9c2d01fd@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> <4941D65C.3060705@...11...> <20081212174619.M65094@...951...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> <1f1e8c1b0812150559j1e280b8bvbaecdb2cade5e9b4@...627...> Message-ID: <1f1e8c1b0812150734l46a048c9g4d9d309c7edc4c22@...627...> After testing this, I do have a question though. My forms have objects like treeviews, listboxes, etc which get populated by running external functions. So, when I implement your example into my project, the navigation works perfectly, My forms however do not. My content shows up only when I'm going though it the first time around. if I click the back button, and navigate my way back and forth, my forms are displayed, but the objects are mot populated. How can I fix this? On Mon, Dec 15, 2008 at 7:59 AM, M0E Lnx wrote: > Yes!... this is exactly how I need it to work. Thank you > > On Sat, Dec 13, 2008 at 2:23 AM, Fabien Bodard wrote: >> it better to have a demo ... and it work fine ... >> >> take it and tell me if that is what you want. >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> > From m0e.lnx at ...626... Mon Dec 15 16:36:27 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Mon, 15 Dec 2008 09:36:27 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812150734l46a048c9g4d9d309c7edc4c22@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> <4941D65C.3060705@...11...> <20081212174619.M65094@...951...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> <1f1e8c1b0812150559j1e280b8bvbaecdb2cade5e9b4@...627...> <1f1e8c1b0812150734l46a048c9g4d9d309c7edc4c22@...627...> Message-ID: <1f1e8c1b0812150736r4344c375k4e56d4542dc4d19c@...627...> BTW, the functions that populate my content are called in each form's _Open() event On Mon, Dec 15, 2008 at 9:34 AM, M0E Lnx wrote: > After testing this, I do have a question though. > > My forms have objects like treeviews, listboxes, etc which get > populated by running external functions. > So, when I implement your example into my project, the navigation > works perfectly, My forms however do not. > > My content shows up only when I'm going though it the first time > around. if I click the back button, and navigate my way back and > forth, my forms are displayed, but the objects are mot populated. > > How can I fix this? > > On Mon, Dec 15, 2008 at 7:59 AM, M0E Lnx wrote: >> Yes!... this is exactly how I need it to work. Thank you >> >> On Sat, Dec 13, 2008 at 2:23 AM, Fabien Bodard wrote: >>> it better to have a demo ... and it work fine ... >>> >>> take it and tell me if that is what you want. >>> >>> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>> >> > From steven at ...1652... Mon Dec 15 17:56:13 2008 From: steven at ...1652... (Steven Lobbezoo) Date: Mon, 15 Dec 2008 17:56:13 +0100 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812150736r4344c375k4e56d4542dc4d19c@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <494188E6.6020604@...11...> <1f1e8c1b0812111433v3a689e9n21121d8179465887@...627...> <4941D65C.3060705@...11...> <20081212174619.M65094@...951...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> <1f1e8c1b0812150559j1e280b8bvbaecdb2cade5e9b4@...627...> <1f1e8c1b0812150734l46a048c9g4d9d309c7edc4c22@...627...> <1f1e8c1b0812150736r4344c375k4e56d4542dc4d19c@...627...> Message-ID: <1229360173.3697.85.camel@...1973...> I think you need to use the form's show event, not the open event. Steven Le lundi 15 d?cembre 2008 ? 09:36 -0600, M0E Lnx a ?crit : > BTW, the functions that populate my content are called in each form's > _Open() event > > > On Mon, Dec 15, 2008 at 9:34 AM, M0E Lnx wrote: > > After testing this, I do have a question though. > > > > My forms have objects like treeviews, listboxes, etc which get > > populated by running external functions. > > So, when I implement your example into my project, the navigation > > works perfectly, My forms however do not. > > > > My content shows up only when I'm going though it the first time > > around. if I click the back button, and navigate my way back and > > forth, my forms are displayed, but the objects are mot populated. > > > > How can I fix this? > > > > On Mon, Dec 15, 2008 at 7:59 AM, M0E Lnx wrote: > >> Yes!... this is exactly how I need it to work. Thank you > >> > >> On Sat, Dec 13, 2008 at 2:23 AM, Fabien Bodard wrote: > >>> it better to have a demo ... and it work fine ... > >>> > >>> take it and tell me if that is what you want. > >>> > >>> ------------------------------------------------------------------------------ > >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > >>> The future of the web can't happen without you. Join us at MIX09 to help > >>> pave the way to the Next Web now. Learn more and register at > >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > >>> _______________________________________________ > >>> Gambas-user mailing list > >>> Gambas-user at lists.sourceforge.net > >>> https://lists.sourceforge.net/lists/listinfo/gambas-user > >>> > >>> > >> > > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From m0e.lnx at ...626... Mon Dec 15 19:00:12 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Mon, 15 Dec 2008 12:00:12 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1229360173.3697.85.camel@...1973...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <4941D65C.3060705@...11...> <20081212174619.M65094@...951...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> <1f1e8c1b0812150559j1e280b8bvbaecdb2cade5e9b4@...627...> <1f1e8c1b0812150734l46a048c9g4d9d309c7edc4c22@...627...> <1f1e8c1b0812150736r4344c375k4e56d4542dc4d19c@...627...> <1229360173.3697.85.camel@...1973...> Message-ID: <1f1e8c1b0812151000k1579693cse8513ba06690a772@...627...> I've tried the Show event, but I get the same results. The forms.Show or Open events are not getting called. They're just getting Raised So, How do I run code in the forms Show or Open event? On Mon, Dec 15, 2008 at 10:56 AM, Steven Lobbezoo wrote: > I think you need to use the form's show event, not the open event. > > Steven > > > Le lundi 15 d?cembre 2008 ? 09:36 -0600, M0E Lnx a ?crit : > >> BTW, the functions that populate my content are called in each form's >> _Open() event >> >> >> On Mon, Dec 15, 2008 at 9:34 AM, M0E Lnx wrote: >> > After testing this, I do have a question though. >> > >> > My forms have objects like treeviews, listboxes, etc which get >> > populated by running external functions. >> > So, when I implement your example into my project, the navigation >> > works perfectly, My forms however do not. >> > >> > My content shows up only when I'm going though it the first time >> > around. if I click the back button, and navigate my way back and >> > forth, my forms are displayed, but the objects are mot populated. >> > >> > How can I fix this? >> > >> > On Mon, Dec 15, 2008 at 7:59 AM, M0E Lnx wrote: >> >> Yes!... this is exactly how I need it to work. Thank you >> >> >> >> On Sat, Dec 13, 2008 at 2:23 AM, Fabien Bodard wrote: >> >>> it better to have a demo ... and it work fine ... >> >>> >> >>> take it and tell me if that is what you want. >> >>> >> >>> ------------------------------------------------------------------------------ >> >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> >>> The future of the web can't happen without you. Join us at MIX09 to help >> >>> pave the way to the Next Web now. Learn more and register at >> >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> >>> _______________________________________________ >> >>> Gambas-user mailing list >> >>> Gambas-user at lists.sourceforge.net >> >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >>> >> >>> >> >> >> > >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jeberlo at ...626... Mon Dec 15 21:01:16 2008 From: jeberlo at ...626... (je ber lo) Date: Mon, 15 Dec 2008 21:01:16 +0100 Subject: [Gambas-user] error calling external function but not when debugging Message-ID: hello, I'm using gambas 2.8 on debian and I'm getting different result when debugging code ( the result is a md5 hash string (32 characters)) but no when executing in a normal way. The error is Failed to set text from markup due to error parsing markup: Error on line 1 char 10: Invalid UTF-8 encoded text - not valid '??$R ???\u0002}60b725f10c9c85c70d97880dfe8191b3' The correct result is string 60b725f10c9c85c70d97880dfe8191b3 sometimes I get the following message too. *** glibc detected *** dinamic: double free or corruption (out): 0x08894530 *** I declare the function EXTERN md5file(filename AS String, resultado AS Pointer) AS Pointer IN "mimd5sum" I call the function with DIM cas AS Pointer DIM cas2 AS Pointer DIM cad AS String cas = Alloc(33) cas2 = md5file("/prueba.txt", cas) cad = StrPtr(cas2) Message(cad) Free(cas) and the function in laguage C is: void miMDPrint (MD5_CTX *mdContext, char* resultado) { int i; char cadtemporal[3]=""; for (i = 0; i < 16; i++) { sprintf (cadtemporal, "%02x", mdContext->digest[i]); strcat(resultado, cadtemporal); } //strcat(resultado,""); } char* md5file (char* filename,char* resultado) { FILE *inFile = fopen (filename, "rb"); MD5_CTX mdContext; int bytes; unsigned char data[1024]; if (inFile == NULL) { //printf ("%s can't be opened.\n", filename); return NULL; } MD5Init (&mdContext); while ((bytes = fread (data, 1, 1024, inFile)) != 0) MD5Update (&mdContext, data, bytes); MD5Final (&mdContext); miMDPrint (&mdContext,resultado); fclose (inFile); return resultado; } Any idea about this problem is welcome. Regards. From jguardon at ...2035... Mon Dec 15 21:41:21 2008 From: jguardon at ...2035... (Jesus Guardon) Date: Mon, 15 Dec 2008 12:41:21 -0800 (PST) Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <494625F5.6030608@...1909...> References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> <21004918.post@...1379...> <494625F5.6030608@...1909...> Message-ID: <21021618.post@...1379...> Hi Doriano and list First of all, many thanks for your input. Yes, you are right about geographic coordinates; in real world the intersection between Ecuatorial line and Greenwich meridian is the coordinate 0;0. Meridians above increase up to 90 degrees to North and below to -90 South. By the way, parallels increase up to 180 deg to East and -180 to West from Greenwich (parallel 0). So the upper left corner (in case of a whole World map) should be -180;90 and the lower right corner 180;-90. Based on this, the result rectangle will be 360 units wide * 180 units tall. But still is unclear if I can use negative values mapped to a rectangle, as you appointed in your previous post. The idea is to have a procedure that can do e.g. drawCoordinate(-3, 40), and draws a point (or whatever I want) on the correct place. Let me play for a while with your program, write some garbage on my notebook and I will post here my results. Again, thank you for your interest. Jesus Guardon Gambas 2.9 Doriano Blengino wrote: > > I've set up a simple project to show how the transformation matrix works. > It draws a line from (0;0) to an arbitrary point you specify in LX: and > LY:. > You can play with Draw.XXX fields to see they effect. > What I discovered is that (gambas vesion 2.0.0): > > 1) For me, negative scalings do not work; this is a *serious* limitation. > 2) Offsets are multiplied by scaling, ie they are expressed in "real > world" coordinates. > 3) Perhaps I am missing something, but it seems to me that you can not > read what is the current transformation matrix; the program should keep > track of this. > > > Now, I don't know what "72N" and "-25W" mean (I think north and west, > but that is all), anyway, supposing that they are arbitrary measurement > units, then your map is 44+25 units wide, and 72+18 units tall, ie 69 x > 90. > You want map this to a 800 x 600. If you don't care about aspect ratio, > then do Draw.scale(800 / 69, 600 / 90). > If you want to mantain aspect ratio (it should be), you assign the same > value to scalex and scaley, the smaller of the two: 800/69=11.59, > 600/90=6.66, so do Draw.scale(6.66, 6.66). > As your upper left corner is -25W and 72N, you must do > Draw.translate(25, -72). > At this point, plotting a (25; 72) should go to (0; 0) in the drawing > area. > From here ahead, I think there is a problem with the computer graphics > having Y axis pointing to the bottom, so may be your map will be flipped > up side down. Every Y coordinate should be transformed by newy = > MapHeight-y, so a different draw.translate() must be issued. > > Anyway, it seems to me that the combination of Scale() and Translate() > does the following: > > coordinate_to_plot = (programmed_coordinate + translate_value) * > scale_value > > Hope this is enough - I well could have done lot of errors, but the test > project can let you experiment. > > Regards, > Doriano > > > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, > Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > -- View this message in context: http://www.nabble.com/Coordinate-system-in-Gambas-Graphics-tp20818380p21021618.html Sent from the gambas-user mailing list archive at Nabble.com. From doriano.blengino at ...1909... Mon Dec 15 23:22:37 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Mon, 15 Dec 2008 23:22:37 +0100 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <21021618.post@...1379...> References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> <21004918.post@...1379...> <494625F5.6030608@...1909...> <21021618.post@...1379...> Message-ID: <4946D8AD.8020300@...1909...> Jesus Guardon ha scritto: > Hi Doriano and list > > First of all, many thanks for your input. > > Yes, you are right about geographic coordinates; in real world the > intersection between Ecuatorial line and Greenwich meridian is the > coordinate 0;0. Meridians above increase up to 90 degrees to North and > below to -90 South. By the way, parallels increase up to 180 deg to East and > -180 to West from Greenwich (parallel 0). So the upper left corner (in case > of a whole World map) should be -180;90 and the lower right corner 180;-90. > Based on this, the result rectangle will be 360 units wide * 180 units tall. > Are you sure meridians go from -90 to 90? Ore are they parallels? I ask this because I live near the 45? parallel: a sign in the motorway states "Half way from Ecuator to Pole". I think Parallels are, just as they name says, "parallel" to the ecuator; Meridians are those that define the time (Greenwich, +1, -1, and so on...) So, correct me if I am wrong, Parallels go from south to north, and Meridians from east to west (or vice-versa). > But still is unclear if I can use negative values mapped to a rectangle, as > you appointed in your previous post. The idea is to have a procedure that > can do e.g. drawCoordinate(-3, 40), and draws a point (or whatever I want) > on the correct place. > As far as I understand, you *can* use negative world coordinates; they will be happily translated to physical (device) coordinates. If the result of this transformation lies in the range 0..Max (0 to 799 for horizontal, and 0 to 599 for vertical) then they will be visible, otherwise they will be clipped. The problem is that your world coordinates, as one could expect, are oriented in the "up" direction: south is negative and north is positive. To map the world (360 x 180) on your 800 x 400 picture you do this: Draw.scale(800/360, 400/180) I chose a picture of 800x400 pixels so the scaling in the 2 axis is the same, but I could be wrong (because meridians are not parallel, right?). Then, we have to move the origin, because the zero of both horizontal and vertical axes must go to the center of the picture: Draw.translate(180, 90) With this setup, if you plot a real world point at 0N, 0W, the coordinates inside the picture will be: X = (0 + 180) * 800/360 -> 400 (the center of the image) Y = (0 + 90) * 400/180 -> 200 (the mid of the image) If you plot a 36, 45 (more or less where I live): X = (36 + 180) * 800/360 -> a little step to the right of the center of the image Y = (45 + 90) * 400/180 -> 300, well below the ecuator... WRONG! I don't live in Africa... As I stated before, we should have a negative Y scaling; Benoit could confirm or not: does a negative scaling work? Well, we simply have to reverse the Y axis; instead of using the North-South coordinate as is, we must use (90-coordinate) and move the origin this way: draw.translate(180, 0) Doing so, the coordinate where I live (the 45? Parallel), should become: Y = ((90-45) + 0) * 400/180 -> 100, near the top of the image The North Pole: Y = ((90-90) + 0) * 400/180 -> 0, at the top of the image and the South Pole: Y = ((90- -90) + 0) * 400/180 -> 180*400/180 -> 400, the bottom of the image ...perhaps I made a mess - it's not clear to me how this geographic coordinates work but, at least for me, it has been funny... :-) Regards, Doriano > Let me play for a while with your program, write some garbage on my notebook > and I will post here my results. Again, thank you for your interest. > > Jesus Guardon > > Gambas 2.9 > > > Doriano Blengino wrote: > >> I've set up a simple project to show how the transformation matrix works. >> It draws a line from (0;0) to an arbitrary point you specify in LX: and >> LY:. >> You can play with Draw.XXX fields to see they effect. >> What I discovered is that (gambas vesion 2.0.0): >> >> 1) For me, negative scalings do not work; this is a *serious* limitation. >> 2) Offsets are multiplied by scaling, ie they are expressed in "real >> world" coordinates. >> 3) Perhaps I am missing something, but it seems to me that you can not >> read what is the current transformation matrix; the program should keep >> track of this. >> >> >> Now, I don't know what "72N" and "-25W" mean (I think north and west, >> but that is all), anyway, supposing that they are arbitrary measurement >> units, then your map is 44+25 units wide, and 72+18 units tall, ie 69 x >> 90. >> You want map this to a 800 x 600. If you don't care about aspect ratio, >> then do Draw.scale(800 / 69, 600 / 90). >> If you want to mantain aspect ratio (it should be), you assign the same >> value to scalex and scaley, the smaller of the two: 800/69=11.59, >> 600/90=6.66, so do Draw.scale(6.66, 6.66). >> As your upper left corner is -25W and 72N, you must do >> Draw.translate(25, -72). >> At this point, plotting a (25; 72) should go to (0; 0) in the drawing >> area. >> From here ahead, I think there is a problem with the computer graphics >> having Y axis pointing to the bottom, so may be your map will be flipped >> up side down. Every Y coordinate should be transformed by newy = >> MapHeight-y, so a different draw.translate() must be issued. >> >> Anyway, it seems to me that the combination of Scale() and Translate() >> does the following: >> >> coordinate_to_plot = (programmed_coordinate + translate_value) * >> scale_value >> >> Hope this is enough - I well could have done lot of errors, but the test >> project can let you experiment. >> >> Regards, >> Doriano >> >> >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, >> Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> >> > > -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From leemcpherson at ...626... Tue Dec 16 02:14:59 2008 From: leemcpherson at ...626... (Lee McPherson) Date: Mon, 15 Dec 2008 20:14:59 -0500 Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <21021618.post@...1379...> References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> <21004918.post@...1379...> <494625F5.6030608@...1909...> <21021618.post@...1379...> Message-ID: <49470113.5080802@...626...> Forgive me for not following the whole thread, but are you trying to convert a spherical lat and long to a planar x,y coordinate system? Or are you starting with those distorted maps where Greenland is the size of the United States on a flat map? Because if you want to use real world maps and data on a flat plane, you'll have to do some more math. There are several ways to do this if you're looking for accuracy. The military and other agencies use UTM. http://www.uwgb.edu/dutchs/UsefulData/UTMFormulas.htm -Lee Jesus Guardon wrote: > Hi Doriano and list > > First of all, many thanks for your input. > > Yes, you are right about geographic coordinates; in real world the > intersection between Ecuatorial line and Greenwich meridian is the > coordinate 0;0. Meridians above increase up to 90 degrees to North and > below to -90 South. By the way, parallels increase up to 180 deg to East and > -180 to West from Greenwich (parallel 0). So the upper left corner (in case > of a whole World map) should be -180;90 and the lower right corner 180;-90. > Based on this, the result rectangle will be 360 units wide * 180 units tall. > > But still is unclear if I can use negative values mapped to a rectangle, as > you appointed in your previous post. The idea is to have a procedure that > can do e.g. drawCoordinate(-3, 40), and draws a point (or whatever I want) > on the correct place. > > Let me play for a while with your program, write some garbage on my notebook > and I will post here my results. Again, thank you for your interest. > > Jesus Guardon > > Gambas 2.9 > > > Doriano Blengino wrote: > >> I've set up a simple project to show how the transformation matrix works. >> It draws a line from (0;0) to an arbitrary point you specify in LX: and >> LY:. >> You can play with Draw.XXX fields to see they effect. >> What I discovered is that (gambas vesion 2.0.0): >> >> 1) For me, negative scalings do not work; this is a *serious* limitation. >> 2) Offsets are multiplied by scaling, ie they are expressed in "real >> world" coordinates. >> 3) Perhaps I am missing something, but it seems to me that you can not >> read what is the current transformation matrix; the program should keep >> track of this. >> >> >> Now, I don't know what "72N" and "-25W" mean (I think north and west, >> but that is all), anyway, supposing that they are arbitrary measurement >> units, then your map is 44+25 units wide, and 72+18 units tall, ie 69 x >> 90. >> You want map this to a 800 x 600. If you don't care about aspect ratio, >> then do Draw.scale(800 / 69, 600 / 90). >> If you want to mantain aspect ratio (it should be), you assign the same >> value to scalex and scaley, the smaller of the two: 800/69=11.59, >> 600/90=6.66, so do Draw.scale(6.66, 6.66). >> As your upper left corner is -25W and 72N, you must do >> Draw.translate(25, -72). >> At this point, plotting a (25; 72) should go to (0; 0) in the drawing >> area. >> From here ahead, I think there is a problem with the computer graphics >> having Y axis pointing to the bottom, so may be your map will be flipped >> up side down. Every Y coordinate should be transformed by newy = >> MapHeight-y, so a different draw.translate() must be issued. >> >> Anyway, it seems to me that the combination of Scale() and Translate() >> does the following: >> >> coordinate_to_plot = (programmed_coordinate + translate_value) * >> scale_value >> >> Hope this is enough - I well could have done lot of errors, but the test >> project can let you experiment. >> >> Regards, >> Doriano >> >> >> >> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, >> Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> >> > > From jguardon at ...2035... Tue Dec 16 07:54:51 2008 From: jguardon at ...2035... (Jesus Guardon) Date: Mon, 15 Dec 2008 22:54:51 -0800 (PST) Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <49470113.5080802@...626...> References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> <21004918.post@...1379...> <494625F5.6030608@...1909...> <21021618.post@...1379...> <49470113.5080802@...626...> Message-ID: <21028179.post@...1379...> Or are you starting with those distorted maps where Greenland is the size of the United States on a flat map? -Lee Yes, I'm using UTM Maps, because they are regularly spaced. I am not an expert in Map Projections, but it works for me. Cheers Jesus Guardon -- View this message in context: http://www.nabble.com/Coordinate-system-in-Gambas-Graphics-tp20818380p21028179.html Sent from the gambas-user mailing list archive at Nabble.com. From jguardon at ...2035... Tue Dec 16 08:03:35 2008 From: jguardon at ...2035... (Jesus Guardon) Date: Mon, 15 Dec 2008 23:03:35 -0800 (PST) Subject: [Gambas-user] Coordinate system in Gambas Graphics In-Reply-To: <4946D8AD.8020300@...1909...> References: <200812040734.41502.rterry@...1946...> <6324a42a0812041210p222d5a81xb775bc61fdf34c6c@...627...> <6324a42a0812050621k15d9dc26o696e41a7625ce514@...627...> <493955B5.5090203@...1909...> <21004918.post@...1379...> <494625F5.6030608@...1909...> <21021618.post@...1379...> <4946D8AD.8020300@...1909...> Message-ID: <21028266.post@...1379...> Are you sure meridians go from -90 to 90? Ore are they parallels? So, correct me if I am wrong, Parallels go from south to north, and Meridians from east to west (or vice-versa). Oooops, yes, of course it was my mistake!. May be English isn't my native language... LOL Now I think I've got it. So this afternoon I'll try to do a working example. As usual, many thanks for your help, your little program helped a lot. Jesus -- View this message in context: http://www.nabble.com/Coordinate-system-in-Gambas-Graphics-tp20818380p21028266.html Sent from the gambas-user mailing list archive at Nabble.com. From wig at ...1809... Tue Dec 16 12:20:06 2008 From: wig at ...1809... (wig) Date: Tue, 16 Dec 2008 12:20:06 +0100 (CET) Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <494671C6.5040203@...1000...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <494671C6.5040203@...1000...> Message-ID: <41382.81.245.34.4.1229426406.squirrel@...1810...> > wig wrote: >> Although I can create table by table from within Gambas with >> hCon.Databases.Add(sDbName), I wondered if there is a way to "import" a >> mysql dump file, so that I can create the tables with data (in one >> command). >> >> Untill now I allways used phpMyAdmin dump/export and import for creating >> the database structure and initial data, but I want to integrate it in >> my >> Gambas application. >> >> > You could use the EXEC command to run the appropriate mysqlsomething > utility (don't recall which) > > Regards > Werner > I couldn't get it to work with EXEC; sImport = "< " & Application.Path & "/mytables.sql" ' ... EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport] Everything works fine except the last part that gives the file to read from. I get the general help of mysql, not a specific error like when I change the password to a wrong one. Maybe there is a difference between the normal parameters and the way to give the file to import from? I could get it to work with SHELL though: sImport = "< " & Application.Path & "/mytables.sql" '... sCommand = "mysql " & sUser & " " & sPassword & " " & sHost & " " & sDatabase & " " & sImport DEBUG sCommand SHELL sCommand WAIT Ok! Don't know which is the "preferred" way but this works. From jscops at ...11... Tue Dec 16 12:21:17 2008 From: jscops at ...11... (Jack) Date: Tue, 16 Dec 2008 12:21:17 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <41382.81.245.34.4.1229426406.squirrel@...1810...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <494671C6.5040203@...1000...> <41382.81.245.34.4.1229426406.squirrel@...1810...> Message-ID: <200812161221.17505.jscops@...11...> Le mardi 16 d?cembre 2008 12:20:06 wig, vous avez ?crit?: > > wig wrote: > >> Although I can create table by table from within Gambas with > >> hCon.Databases.Add(sDbName), I wondered if there is a way to "import" a > >> mysql dump file, so that I can create the tables with data (in one > >> command). > >> > >> Untill now I allways used phpMyAdmin dump/export and import for creating > >> the database structure and initial data, but I want to integrate it in > >> my > >> Gambas application. > > > > You could use the EXEC command to run the appropriate mysqlsomething > > utility (don't recall which) > > > > Regards > > Werner > > I couldn't get it to work with EXEC; > > sImport = "< " & Application.Path & "/mytables.sql" > ' ... > EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport] > > Everything works fine except the last part that gives the file to read > from. > > I get the general help of mysql, not a specific error like when I change > the password to a wrong one. > > Maybe there is a difference between the normal parameters and the way to > give the file to import from? > > > I could get it to work with SHELL though: > > sImport = "< " & Application.Path & "/mytables.sql" > '... > sCommand = "mysql " & sUser & " " & sPassword & " " & sHost & " " & > sDatabase & " " & sImport > DEBUG sCommand > SHELL sCommand WAIT > > Ok! Don't know which is the "preferred" way but this works. > > to save your base you can use this Gambas command. SHELL "mysqldump" & " " & "-u" & " " & db.Login & " " & "-p" & db.Password & " " & "Name-of-your-base" & " " & "--add-drop-table" & " " & ">" & " " & User.home & "/Name-of-your-base.sql" & " 2>/tmp/result" WAIT To restore your base you can use this. IF IsNull(db.Password) THEN 'if no password SHELL "mysql" & " " & "-u" & " " & db.login & " " & "Name-of-your-base" & " " & "<" & Sauves.Text & "/Name-of-your-base.sql" & " 2>/tmp/result" WAIT ELSE SHELL "mysql" & " " & "-u" & " " & db.login & " " & "-p" & db.Password & " " & "Name-of-your-base" & " " & "<" & Sauves.Text & "/Name-of-your-base.sql" & " 2>/tmp/result" WAIT ENDIF Note: 2>/tmp/result is for intercept the command shell error I hope this script help you. Cordialement. Jacky From m0e.lnx at ...626... Tue Dec 16 14:59:16 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Tue, 16 Dec 2008 07:59:16 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812151000k1579693cse8513ba06690a772@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <20081212174619.M65094@...951...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> <1f1e8c1b0812150559j1e280b8bvbaecdb2cade5e9b4@...627...> <1f1e8c1b0812150734l46a048c9g4d9d309c7edc4c22@...627...> <1f1e8c1b0812150736r4344c375k4e56d4542dc4d19c@...627...> <1229360173.3697.85.camel@...1973...> <1f1e8c1b0812151000k1579693cse8513ba06690a772@...627...> Message-ID: <1f1e8c1b0812160559y2f5853fft2853783ebea452ec@...627...> Attn: Fabien, Your sample works for me, but I need a way to execute the code in each form's _Open() or _Show() event... Or any sub for that matter. I noticed that the code is only ran once (the very first time the form is loaded). Can you suggest a way of doing this? On Mon, Dec 15, 2008 at 12:00 PM, M0E Lnx wrote: > I've tried the Show event, but I get the same results. > > The forms.Show or Open events are not getting called. They're just > getting Raised > > So, How do I run code in the forms Show or Open event? > > On Mon, Dec 15, 2008 at 10:56 AM, Steven Lobbezoo wrote: >> I think you need to use the form's show event, not the open event. >> >> Steven >> >> >> Le lundi 15 d?cembre 2008 ? 09:36 -0600, M0E Lnx a ?crit : >> >>> BTW, the functions that populate my content are called in each form's >>> _Open() event >>> >>> >>> On Mon, Dec 15, 2008 at 9:34 AM, M0E Lnx wrote: >>> > After testing this, I do have a question though. >>> > >>> > My forms have objects like treeviews, listboxes, etc which get >>> > populated by running external functions. >>> > So, when I implement your example into my project, the navigation >>> > works perfectly, My forms however do not. >>> > >>> > My content shows up only when I'm going though it the first time >>> > around. if I click the back button, and navigate my way back and >>> > forth, my forms are displayed, but the objects are mot populated. >>> > >>> > How can I fix this? >>> > >>> > On Mon, Dec 15, 2008 at 7:59 AM, M0E Lnx wrote: >>> >> Yes!... this is exactly how I need it to work. Thank you >>> >> >>> >> On Sat, Dec 13, 2008 at 2:23 AM, Fabien Bodard wrote: >>> >>> it better to have a demo ... and it work fine ... >>> >>> >>> >>> take it and tell me if that is what you want. >>> >>> >>> >>> ------------------------------------------------------------------------------ >>> >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> >>> The future of the web can't happen without you. Join us at MIX09 to help >>> >>> pave the way to the Next Web now. Learn more and register at >>> >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> >>> _______________________________________________ >>> >>> Gambas-user mailing list >>> >>> Gambas-user at lists.sourceforge.net >>> >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>> >>> >>> >>> >> >>> > >>> >>> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> ------------------------------------------------------------------------------ >> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >> The future of the web can't happen without you. Join us at MIX09 to help >> pave the way to the Next Web now. Learn more and register at >> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > From wig at ...1809... Tue Dec 16 16:16:48 2008 From: wig at ...1809... (wig) Date: Tue, 16 Dec 2008 16:16:48 +0100 (CET) Subject: [Gambas-user] import mysql dump EXEC parameters? In-Reply-To: <200812161221.17505.jscops@...11...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <494671C6.5040203@...1000...> <41382.81.245.34.4.1229426406.squirrel@...1810...> <200812161221.17505.jscops@...11...> Message-ID: <40399.81.245.34.4.1229440608.squirrel@...1810...> Indeed, can be extended to intercept the command shell error, rest is the same, in the end it is one big string that is deliverd to SHELL. But with EXEC, it seems to be different: separate parameters are to be delivered and it is not clear how to deliver the part with the sql file: This does not work: EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport, sSqlFile] WAIT It gives: mysql Ver 14.12 Distrib 5.0.45, for suse-linux-gnu (i686) using readline 5.2 .. etc I am most in doubt about ' ... sImport = "<" sSqlFile = Application.Path & "/mytables.sql" Probably the file should not be passed as text parameter? When changing the user, password, host, database I get "normal" errors like: EXEC ["mysql", sUser, sPassword, sHost, "wrongdatabase"] WAIT Gives: ERROR 1049 (42000): Unknown database 'wrongdatabase' > > to save your base you can use this Gambas command. > > SHELL "mysqldump" & " " & "-u" & " " & db.Login & " " & "-p" & db.Password > & " > " & "Name-of-your-base" & " " & "--add-drop-table" & " " & ">" & " " & > User.home & "/Name-of-your-base.sql" & " 2>/tmp/result" WAIT > > > To restore your base you can use this. > > IF IsNull(db.Password) THEN 'if no password > SHELL "mysql" & " " & "-u" & " " & db.login & " " & > "Name-of-your-base" & > " " & "<" & Sauves.Text & "/Name-of-your-base.sql" & " 2>/tmp/result" WAIT > ELSE > SHELL "mysql" & " " & "-u" & " " & db.login & " " & "-p" & db.Password > & " > " & "Name-of-your-base" & " " & "<" & Sauves.Text & > "/Name-of-your-base.sql" & > " 2>/tmp/result" WAIT > ENDIF > > Note: 2>/tmp/result is for intercept the command shell error > > I hope this script help you. > > Cordialement. > > Jacky > >> >> I couldn't get it to work with EXEC; >> >> sImport = "< " & Application.Path & "/mytables.sql" >> ' ... >> EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport] >> >> Everything works fine except the last part that gives the file to read >> from. >> >> I get the general help of mysql, not a specific error like when I change >> the password to a wrong one. >> >> Maybe there is a difference between the normal parameters and the way to >> give the file to import from? >> >> >> I could get it to work with SHELL though: >> >> sImport = "< " & Application.Path & "/mytables.sql" >> '... >> sCommand = "mysql " & sUser & " " & sPassword & " " & sHost & " " & >> sDatabase & " " & sImport >> DEBUG sCommand >> SHELL sCommand WAIT >> >> Ok! Don't know which is the "preferred" way but this works. >> >> >> > You could use the EXEC command to run the appropriate mysqlsomething >> > utility (don't recall which) >> > >> > Regards >> > Werner > Le mardi 16 d?cembre 2008 12:20:06 wig, vous avez ?crit : >> > wig wrote: >> >> Although I can create table by table from within Gambas with >> >> hCon.Databases.Add(sDbName), I wondered if there is a way to "import" >> a >> >> mysql dump file, so that I can create the tables with data (in one >> >> command). >> >> >> >> Untill now I allways used phpMyAdmin dump/export and import for >> creating >> >> the database structure and initial data, but I want to integrate it >> in >> >> my >> >> Gambas application. >> > From demosthenesk at ...626... Tue Dec 16 16:23:41 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Tue, 16 Dec 2008 17:23:41 +0200 Subject: [Gambas-user] last line of editor Message-ID: Hi to all, i have a text area and i want when i feed text to it to go to the last line of it, so i wrote the next code that works fine PUBLIC SUB txaSQL_Change() txaSQL.Pos = Len(txaSQL.Text) END how can i have the same result with an editor control? -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From david_villalobos_c at ...43... Tue Dec 16 17:02:19 2008 From: david_villalobos_c at ...43... (David Villalobos Cambronero) Date: Tue, 16 Dec 2008 08:02:19 -0800 (PST) Subject: [Gambas-user] Error on Connection when closing Message-ID: <23846.5284.qm@...1678...> Hi, I got an error when close my connection at runtime, the error is easy, the connection is not closed, it still accepts queries. Is the .Close() Method supposed to close the connection meaning that it won't accept queries or I'm wrong. See the attached example. Gambas 3, svn 1740, Mandriva 2008.1 32 Bits and MySQL. Benoit, can you confirm. Regards -- David -------------- next part -------------- A non-text attachment was scrubbed... Name: Error.Conn-0.0.1.tar.gz Type: application/x-gzip Size: 7872 bytes Desc: not available URL: From ronstk at ...239... Tue Dec 16 17:20:14 2008 From: ronstk at ...239... (Ron_1st) Date: Tue, 16 Dec 2008 17:20:14 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <41382.81.245.34.4.1229426406.squirrel@...1810...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <494671C6.5040203@...1000...> <41382.81.245.34.4.1229426406.squirrel@...1810...> Message-ID: <200812161720.14850.ronstk@...239...> On Tuesday 16 December 2008, wig wrote: > sImport = "< " & Application.Path & "/mytables.sql" > > EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport] > sImport = "< " sSqlFile = Application.Path & "/mytables.sql" EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport, sSqlFile ] Every item on the line for EXEC should be a seprate item in the array. The "<" is a seperate item/part of the line, it has space on both adjacent sides! Best regards Ron_1st From wally at ...2037... Tue Dec 16 18:11:48 2008 From: wally at ...2037... (Wally) Date: Tue, 16 Dec 2008 18:11:48 +0100 Subject: [Gambas-user] parent of current item Message-ID: <200812161811.48253.wally@...2037...> How to get the parent of the current item in treeview ? (the key's are populated by random numbers) regs wally From m0e.lnx at ...626... Tue Dec 16 19:00:59 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Tue, 16 Dec 2008 12:00:59 -0600 Subject: [Gambas-user] parent of current item In-Reply-To: <200812161811.48253.wally@...2037...> References: <200812161811.48253.wally@...2037...> Message-ID: <1f1e8c1b0812161000i2ae24126qb15615cbd4afc847@...627...> If you do not provide a Key, gambas will assign one, but you can provide one as a string. Like this Prep -Prep0 -Prep1 Inst -Inst0 -Inst1 Conf -Conf0 -Conf1 On Tue, Dec 16, 2008 at 11:11 AM, Wally wrote: > How to get the parent of the current item in treeview ? > (the key's are populated by random numbers) > > regs wally > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From alw at ...2038... Tue Dec 16 18:38:39 2008 From: alw at ...2038... (Al Williams) Date: Tue, 16 Dec 2008 11:38:39 -0600 Subject: [Gambas-user] Byte I/O to serial port Message-ID: <4947E79F.1040700@...2038...> From alw at ...2038... Tue Dec 16 19:37:13 2008 From: alw at ...2038... (Al Williams) Date: Tue, 16 Dec 2008 12:37:13 -0600 Subject: [Gambas-user] Byte I/O to serial port In-Reply-To: <4947E79F.1040700@...2038...> References: <4947E79F.1040700@...2038...> Message-ID: <4947F559.5090604@...2038...> From jeberlo at ...626... Tue Dec 16 19:43:47 2008 From: jeberlo at ...626... (je ber lo) Date: Tue, 16 Dec 2008 19:43:47 +0100 Subject: [Gambas-user] error calling external function but not when debugging Message-ID: Hello, I'have resolved my problem. The approach I have taken is: In the external function in C convert the char array into a Gambas String (length + array of char) then in Gambas I get the string thru the Read #pointer, stringvar function. Could anybody confirm if this is the best approach? Regards. From m0e.lnx at ...626... Tue Dec 16 19:55:38 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Tue, 16 Dec 2008 12:55:38 -0600 Subject: [Gambas-user] Emulating wizard Back/Next navigation In-Reply-To: <1f1e8c1b0812160559y2f5853fft2853783ebea452ec@...627...> References: <1f1e8c1b0812101239n58e637el56e7aaab659ebbb3@...627...> <1f1e8c1b0812121018r1c9cba17je9dfff0ea39e7bc@...627...> <6324a42a0812122320y5847e059r3fa1c63d8e176f8@...627...> <6324a42a0812130023s4dae7054y602964f7522ff96c@...627...> <1f1e8c1b0812150559j1e280b8bvbaecdb2cade5e9b4@...627...> <1f1e8c1b0812150734l46a048c9g4d9d309c7edc4c22@...627...> <1f1e8c1b0812150736r4344c375k4e56d4542dc4d19c@...627...> <1229360173.3697.85.camel@...1973...> <1f1e8c1b0812151000k1579693cse8513ba06690a772@...627...> <1f1e8c1b0812160559y2f5853fft2853783ebea452ec@...627...> Message-ID: <1f1e8c1b0812161055u4dd8f7f9pfb86327d1b74ffbe@...627...> Bump? On Tue, Dec 16, 2008 at 7:59 AM, M0E Lnx wrote: > Attn: Fabien, > Your sample works for me, but I need a way to execute the code in each > form's _Open() or _Show() event... Or any sub for that matter. > > I noticed that the code is only ran once (the very first time the form > is loaded). Can you suggest a way of doing this? > > > On Mon, Dec 15, 2008 at 12:00 PM, M0E Lnx wrote: >> I've tried the Show event, but I get the same results. >> >> The forms.Show or Open events are not getting called. They're just >> getting Raised >> >> So, How do I run code in the forms Show or Open event? >> >> On Mon, Dec 15, 2008 at 10:56 AM, Steven Lobbezoo wrote: >>> I think you need to use the form's show event, not the open event. >>> >>> Steven >>> >>> >>> Le lundi 15 d?cembre 2008 ? 09:36 -0600, M0E Lnx a ?crit : >>> >>>> BTW, the functions that populate my content are called in each form's >>>> _Open() event >>>> >>>> >>>> On Mon, Dec 15, 2008 at 9:34 AM, M0E Lnx wrote: >>>> > After testing this, I do have a question though. >>>> > >>>> > My forms have objects like treeviews, listboxes, etc which get >>>> > populated by running external functions. >>>> > So, when I implement your example into my project, the navigation >>>> > works perfectly, My forms however do not. >>>> > >>>> > My content shows up only when I'm going though it the first time >>>> > around. if I click the back button, and navigate my way back and >>>> > forth, my forms are displayed, but the objects are mot populated. >>>> > >>>> > How can I fix this? >>>> > >>>> > On Mon, Dec 15, 2008 at 7:59 AM, M0E Lnx wrote: >>>> >> Yes!... this is exactly how I need it to work. Thank you >>>> >> >>>> >> On Sat, Dec 13, 2008 at 2:23 AM, Fabien Bodard wrote: >>>> >>> it better to have a demo ... and it work fine ... >>>> >>> >>>> >>> take it and tell me if that is what you want. >>>> >>> >>>> >>> ------------------------------------------------------------------------------ >>>> >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>> >>> The future of the web can't happen without you. Join us at MIX09 to help >>>> >>> pave the way to the Next Web now. Learn more and register at >>>> >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>> >>> _______________________________________________ >>>> >>> Gambas-user mailing list >>>> >>> Gambas-user at lists.sourceforge.net >>>> >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> >>>> >>> >>>> >> >>>> > >>>> >>>> ------------------------------------------------------------------------------ >>>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>>> The future of the web can't happen without you. Join us at MIX09 to help >>>> pave the way to the Next Web now. Learn more and register at >>>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> ------------------------------------------------------------------------------ >>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. >>> The future of the web can't happen without you. Join us at MIX09 to help >>> pave the way to the Next Web now. Learn more and register at >>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> > From doriano.blengino at ...1909... Tue Dec 16 20:50:23 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Tue, 16 Dec 2008 20:50:23 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <200812161720.14850.ronstk@...239...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <494671C6.5040203@...1000...> <41382.81.245.34.4.1229426406.squirrel@...1810...> <200812161720.14850.ronstk@...239...> Message-ID: <4948067F.10809@...1909...> Ron_1st ha scritto: > On Tuesday 16 December 2008, wig wrote: > >> sImport = "< " & Application.Path & "/mytables.sql" >> >> EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport] >> >> > > sImport = "< " > sSqlFile = Application.Path & "/mytables.sql" > > EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport, sSqlFile ] > > Every item on the line for EXEC should be a seprate item in the array. > The "<" is a seperate item/part of the line, it has space on both adjacent sides! > No, the "<" construct is a shell construct, not a linux/unix one. It is /bin/sh, or whatever, which interprets this notation and does a lot of job about it. The gambas SHELL instruction calls /bin/sh, which is powerful (environment, PATH search, redirection and much more), so you can use all its features. EXEC calls the unix system call execXX() (there are various) which are faster but not as powerful as /bin/sh. I think the most notably differences are: 1. Using SHELL you specify the command to execute as you would do on the command line. ls is ls, and fdisk is fdisk. In EXEC, you *must* specify the correct path: /bin/ls, /sbin/fdisk... - Linux won't search the file for you. EXEC ["mysql", ...] can not work. 2. Again, parameters and constructs of SHELL are the same as those in the command line; you can use < > | and so on, and must quote words which contain spaces and other special chars. Using EXEC you don't have (well, you must not) quote parameters. and you don't have /bin/sh constructs. Regards, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From doriano.blengino at ...1909... Tue Dec 16 21:12:54 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Tue, 16 Dec 2008 21:12:54 +0100 Subject: [Gambas-user] parent of current item In-Reply-To: <200812161811.48253.wally@...2037...> References: <200812161811.48253.wally@...2037...> Message-ID: <49480BC6.6080200@...1909...> Wally ha scritto: > How to get the parent of the current item in treeview ? > (the key's are populated by random numbers) > > regs wally > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > Use TreeView.MoveParent(). Found this in the documentation (qt/TreeView). Regards, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From doriano.blengino at ...1909... Tue Dec 16 21:15:37 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Tue, 16 Dec 2008 21:15:37 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop Message-ID: <49480C69.4090608@...1909...> Hi list, how can I implement drag&drop with the desktop? I mean, drag an item (a filename, for example) to an icon on the desktop, and viceversa, a file from a file manager to a running gambas application? Regards, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From wally at ...2037... Tue Dec 16 21:20:37 2008 From: wally at ...2037... (Wally) Date: Tue, 16 Dec 2008 21:20:37 +0100 Subject: [Gambas-user] parent of current item In-Reply-To: <49480BC6.6080200@...1909...> References: <200812161811.48253.wally@...2037...> <49480BC6.6080200@...1909...> Message-ID: <200812162120.37564.wally@...2037...> On Tue December 16 2008 21:12:54 Doriano Blengino wrote: > Wally ha scritto: > > How to get the parent of the current item in treeview ? > > (the key's are populated by random numbers) > > > > regs wally > > > > ------------------------------------------------------------------------- > >----- SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, > > Nevada. The future of the web can't happen without you. Join us at MIX09 > > to help pave the way to the Next Web now. Learn more and register at > > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.c > >om/ _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > Use TreeView.MoveParent(). > > Found this in the documentation (qt/TreeView). > > Regards, yes, this works fine ! after moveparent i use treeview1.item.key and not treeview1,current.key. the moveparent moves the internal cursor not the "current" position thx From almodook at ...2007... Tue Dec 16 21:35:38 2008 From: almodook at ...2007... (moon_walker) Date: Tue, 16 Dec 2008 12:35:38 -0800 (PST) Subject: [Gambas-user] SQLite and INT4 vs. INTEGER Message-ID: <21041236.post@...1379...> Hi Benoit, i am developing a cross platform application. The linux side is on GAMBAS and the Win side is on C#.NET. The common part is the SQLite database. There is some foreign relations which are coupled with comboboxes. So the child table has some foreign key fields joined to parent primary keys. In the parent tables the primary keys are defined as autoincrement. Since i was unable to use the type gb.serial at all, i defined this keys in SQLite-datamanager in firefox. I realised that SQLite only allows autoincrement for primary key INTEGER. However gambas database manager use INT4 for the foreign key fields in the child table. This causes inconsistency in .NET since it is impossible to create relations on type mismatched fields (INT4 vs INTEGER). If i switch all related fields to INTEGER then GAMBAS is unable to handle tha databounded combobox. I would prefer that instead of INT4, only INTEGER would be used general by SQLite area. thx br Attila -- View this message in context: http://www.nabble.com/SQLite-and-INT4-vs.-INTEGER-tp21041236p21041236.html Sent from the gambas-user mailing list archive at Nabble.com. From m0e.lnx at ...626... Tue Dec 16 22:24:04 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Tue, 16 Dec 2008 15:24:04 -0600 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <49480C69.4090608@...1909...> References: <49480C69.4090608@...1909...> Message-ID: <1f1e8c1b0812161324i252e302r280575439318f327@...627...> AFAIK, such a feature doesn't exist yet... I remember asking about it some time ago. At least not in 2.x On Tue, Dec 16, 2008 at 2:15 PM, Doriano Blengino wrote: > Hi list, > > how can I implement drag&drop with the desktop? > > I mean, drag an item (a filename, for example) to an icon on the > desktop, and viceversa, a file from a file manager to a running gambas > application? > > Regards, > > -- > Doriano Blengino > > "Listen twice before you speak. > This is why we have two ears, but only one mouth." > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jussi.lahtinen at ...626... Tue Dec 16 22:30:08 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Tue, 16 Dec 2008 23:30:08 +0200 Subject: [Gambas-user] Gambas3 compilation problem In-Reply-To: <384d3900812100950j12b2bd9bibb5e7c664d8d483b@...627...> References: <384d3900812100950j12b2bd9bibb5e7c664d8d483b@...627...> Message-ID: <384d3900812161330w48a32b02u5fab3c2c6f2db2e@...627...> Hi! I must rise this again, it is still problem... ideas? Anyone? I tried it again with revision 1740, and same problem. Do I need to install something from somewhere..? Thanks! Jussi On Wed, Dec 10, 2008 at 7:50 PM, Jussi Lahtinen wrote: > Hi! > > I'm on Ubuntu 8.10 64 bit. I have compiled Gambas2.9 without problems, > so everything should be ok with my system..? > > I've done this: > > 1. > svn checkout https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk/ > > Checked out revision 1733. > Everything ok. > > > 2. > ./reconf-all > > Got messages: > libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, `.'. > libtoolize: copying file `./ltmain.sh' > libtoolize: putting auxiliary files in `.'. > libtoolize: copying file `libltdl/config/compile' > libtoolize: copying file `libltdl/config/config.guess' > libtoolize: copying file `libltdl/config/config.sub' > libtoolize: copying file `libltdl/config/depcomp' > libtoolize: copying file `libltdl/config/install-sh' > libtoolize: copying file `libltdl/config/missing' > libtoolize: copying file `libltdl/config/ltmain.sh' > libtoolize: putting macros in `libltdl/m4'. > libtoolize: copying file `libltdl/m4/argz.m4' > libtoolize: copying file `libltdl/m4/libtool.m4' > libtoolize: copying file `libltdl/m4/ltdl.m4' > libtoolize: copying file `libltdl/m4/ltoptions.m4' > libtoolize: copying file `libltdl/m4/ltsugar.m4' > libtoolize: copying file `libltdl/m4/ltversion.m4' > libtoolize: copying file `libltdl/m4/lt~obsolete.m4' > libtoolize: putting libltdl files in `libltdl'. > libtoolize: copying file `libltdl/COPYING.LIB' > libtoolize: copying file `libltdl/README' > libtoolize: copying file `libltdl/Makefile.am' > libtoolize: copying file `libltdl/configure.ac' > libtoolize: copying file `libltdl/aclocal.m4' > libtoolize: copying file `libltdl/Makefile.in' > libtoolize: copying file `libltdl/config-h.in' > libtoolize: copying file `libltdl/configure' > libtoolize: copying file `libltdl/argz_.h' > libtoolize: copying file `libltdl/argz.c' > libtoolize: copying file `libltdl/loaders/dld_link.c' > libtoolize: copying file `libltdl/loaders/dlopen.c' > libtoolize: copying file `libltdl/loaders/dyld.c' > libtoolize: copying file `libltdl/loaders/load_add_on.c' > libtoolize: copying file `libltdl/loaders/loadlibrary.c' > libtoolize: copying file `libltdl/loaders/shl_load.c' > libtoolize: copying file `libltdl/lt__dirent.c' > libtoolize: copying file `libltdl/lt__strl.c' > libtoolize: copying file `libltdl/libltdl/lt__alloc.h' > libtoolize: copying file `libltdl/libltdl/lt__dirent.h' > libtoolize: copying file `libltdl/libltdl/lt__glibc.h' > libtoolize: copying file `libltdl/libltdl/lt__private.h' > libtoolize: copying file `libltdl/libltdl/lt__strl.h' > libtoolize: copying file `libltdl/libltdl/lt_dlloader.h' > libtoolize: copying file `libltdl/libltdl/lt_error.h' > libtoolize: copying file `libltdl/libltdl/lt_system.h' > libtoolize: copying file `libltdl/libltdl/slist.h' > libtoolize: copying file `libltdl/loaders/preopen.c' > libtoolize: copying file `libltdl/lt__alloc.c' > libtoolize: copying file `libltdl/lt_dlloader.c' > libtoolize: copying file `libltdl/lt_error.c' > libtoolize: copying file `libltdl/ltdl.c' > libtoolize: copying file `libltdl/ltdl.h' > libtoolize: copying file `libltdl/slist.c' > libtoolize: You should add the contents of the following files to `aclocal.m4': > libtoolize: `libltdl/m4/libtool.m4' > libtoolize: `libltdl/m4/ltoptions.m4' > libtoolize: `libltdl/m4/ltversion.m4' > libtoolize: `libltdl/m4/ltsugar.m4' > libtoolize: `libltdl/m4/lt~obsolete.m4' > libtoolize: `libltdl/m4/argz.m4' > libtoolize: `libltdl/m4/ltdl.m4' > libtoolize: or else add `AC_CONFIG_MACRO_DIR([libltdl/m4])' to configure.ac. > libtoolize: Remember to add `LT_CONFIG_LTDL_DIR([libltdl])' to `configure.ac'. > libtoolize: Consider using `AC_CONFIG_AUX_DIR([libltdl/config])' in > configure.ac. > libtoolize: Consider adding `-I m4' to ACLOCAL_AMFLAGS in Makefile.am. > configure.ac: required file `./mkinstalldirs' not found > autoreconf: automake failed with exit status: 1 > > Ideas? > > > Jussi > From gambas at ...1... Wed Dec 17 00:21:54 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 17 Dec 2008 00:21:54 +0100 Subject: [Gambas-user] Gambas3 compilation problem In-Reply-To: <384d3900812161330w48a32b02u5fab3c2c6f2db2e@...627...> References: <384d3900812100950j12b2bd9bibb5e7c664d8d483b@...627...> <384d3900812161330w48a32b02u5fab3c2c6f2db2e@...627...> Message-ID: <200812170021.54100.gambas@...1...> On mardi 16 d?cembre 2008, Jussi Lahtinen wrote: > Hi! > I must rise this again, it is still problem... ideas? Anyone? > I tried it again with revision 1740, and same problem. > Do I need to install something from somewhere..? > Thanks! > > > Jussi > > As briefly explained on the wiki, on the Ubuntu page, you must replace the default libtool package (version 2) by an older one (version 1.5). Otherwise, Gambas does not compile correctly! Regards, -- Benoit Minisini From ronstk at ...239... Wed Dec 17 04:37:02 2008 From: ronstk at ...239... (Ron_1st) Date: Wed, 17 Dec 2008 04:37:02 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <4948067F.10809@...1909...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812161720.14850.ronstk@...239...> <4948067F.10809@...1909...> Message-ID: <200812170437.02878.ronstk@...239...> On Tuesday 16 December 2008, Doriano Blengino wrote: > Ron_1st ha scritto: > > On Tuesday 16 December 2008, wig wrote: > > > >> sImport = "< " & Application.Path & "/mytables.sql" > >> > >> EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport] > >> > >> > > > > sImport = "< " > > sSqlFile = Application.Path & "/mytables.sql" > > > > EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport, sSqlFile ] > > > > Every item on the line for EXEC should be a seprate item in the array. > > The "<" is a seperate item/part of the line, it has space on both adjacent sides! > > > No, > > the "<" construct is a shell construct, not a linux/unix one. It is > /bin/sh, or whatever, which interprets this notation and does a lot of > job about it. > The gambas SHELL instruction calls /bin/sh, which is powerful > (environment, PATH search, redirection and much more), so you can use > all its features. > > EXEC calls the unix system call execXX() (there are various) which are > faster but not as powerful as /bin/sh. > > I think the most notably differences are: > 1. Using SHELL you specify the command to execute as you would do on the > command line. ls is ls, and fdisk is fdisk. In EXEC, you *must* specify > the correct path: /bin/ls, /sbin/fdisk... - Linux won't search the file > for you. EXEC ["mysql", ...] can not work. > > 2. Again, parameters and constructs of SHELL are the same as those in > the command line; you can use < > | and so on, and must quote words > which contain spaces and other special chars. Using EXEC you don't have > (well, you must not) quote parameters. and you don't have /bin/sh > constructs. > > Regards, > Thanks for explaination. When I do understand it correct the error in the line > > EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport, sSqlFile ] is the missing path for "mysql" (?) Best regards Ron_1st From doriano.blengino at ...1909... Wed Dec 17 07:27:48 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 07:27:48 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <200812170437.02878.ronstk@...239...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812161720.14850.ronstk@...239...> <4948067F.10809@...1909...> <200812170437.02878.ronstk@...239...> Message-ID: <49489BE4.2000208@...1909...> Ron_1st ha scritto: > On Tuesday 16 December 2008, Doriano Blengino wrote: > >> Ron_1st ha scritto: >> >>> On Tuesday 16 December 2008, wig wrote: >>> >>> >>>> sImport = "< " & Application.Path & "/mytables.sql" >>>> >>>> EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport] >>>> >>>> >>>> >>> sImport = "< " >>> sSqlFile = Application.Path & "/mytables.sql" >>> >>> EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport, sSqlFile ] >>> >>> Every item on the line for EXEC should be a seprate item in the array. >>> The "<" is a seperate item/part of the line, it has space on both adjacent sides! >>> >>> >> No, >> >> the "<" construct is a shell construct, not a linux/unix one. It is >> /bin/sh, or whatever, which interprets this notation and does a lot of >> job about it. >> The gambas SHELL instruction calls /bin/sh, which is powerful >> (environment, PATH search, redirection and much more), so you can use >> all its features. >> >> >> > When I do understand it correct the error in the line > >>> EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport, sSqlFile ] >>> > is the missing path for "mysql" (?) > Pardon me. I got confused about the exec system call. I went to read the documentation, and made a simple test. EXEC finds the normal executables, in some way; so this is not the problem. Your problem is that you can not do redirection using "<". It is the shell /bin/sh that does that; if you use such character in an EXEC statement, all you obtain is to pass the "<" character to the command you are invoking which, 99% of the times, will interpret it as a file name or part of it. You can do what you want do by this: dim sql_result as string SHELL "mysql -u user01 -p pwd01 ... < " & Application.Path &/ "mytables.sql" TO sql_result The "to sql_result" implies that the command is fully executed before returning, and you can analyze the string to look for errors and such. To use EXEC instead, you shoud do: EXEC ["/bin/sh", "-c", "mysql -u user01 -p pwd01 ... < " & Application.Path &/ "mytables.sql"] to sql_result (As you see, it simply calls /bin/sh passing it a command to execute. IE, this is the same as SHELL!) You can avoid to call "/bin/sh" if you don't need /bin/sh functionalities. Another, more controlled way, but more complicated, is to create the pipes yourself, and do what the shell would do. SHELL ... FOR INPUT OUTPUT ... This way, you can feed the command whatever you want, not just a file but live data you create on the fly, perhaps reading them from a file you opened... but this is another matter. Regards, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From doriano.blengino at ...1909... Wed Dec 17 07:35:40 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 07:35:40 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <1f1e8c1b0812161324i252e302r280575439318f327@...627...> References: <49480C69.4090608@...1909...> <1f1e8c1b0812161324i252e302r280575439318f327@...627...> Message-ID: <49489DBC.8080506@...1909...> M0E Lnx ha scritto: > AFAIK, such a feature doesn't exist yet... I remember asking about it > some time ago. > At least not in 2.x > > On Tue, Dec 16, 2008 at 2:15 PM, Doriano Blengino > wrote: > >> Hi list, >> >> how can I implement drag&drop with the desktop? >> >> I mean, drag an item (a filename, for example) to an icon on the >> desktop, and viceversa, a file from a file manager to a running gambas >> application? >> >> >> > > I should refine my question. Probably gambas does not have native support for this, but I am not afraid to declare external functions to implement it. Those function probably are found in kdelibs. The problem is: what to search for in those libs? And could a gambas program cope with data types and callbacks, events ar whatever required to do this? Thanks, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From gambas.fr at ...626... Wed Dec 17 08:32:50 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Wed, 17 Dec 2008 08:32:50 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <49489DBC.8080506@...1909...> References: <49480C69.4090608@...1909...> <1f1e8c1b0812161324i252e302r280575439318f327@...627...> <49489DBC.8080506@...1909...> Message-ID: <6324a42a0812162332q5b182811id0950ef007bdeb3c@...627...> it's not a gambas ability the problem is to give the good data format ' Gambas class file PUBLIC SUB _new() END PUBLIC SUB Form_Open() ListBox1.Add(Application.Path &/ "FMain.form") END PUBLIC SUB ListBox1_Drag() END PUBLIC SUB ListBox1_Drop() END PUBLIC SUB Form_Drop() Message(Drag.Data) PRINT Drag.Format END PUBLIC SUB ListBox1_MouseDown() ListBox1.Drag(ListBox1[0].Text, "text/uri-list") END 2008/12/17 Doriano Blengino : > M0E Lnx ha scritto: >> AFAIK, such a feature doesn't exist yet... I remember asking about it >> some time ago. >> At least not in 2.x >> >> On Tue, Dec 16, 2008 at 2:15 PM, Doriano Blengino >> wrote: >> >>> Hi list, >>> >>> how can I implement drag&drop with the desktop? >>> >>> I mean, drag an item (a filename, for example) to an icon on the >>> desktop, and viceversa, a file from a file manager to a running gambas >>> application? >>> >>> >>> >> >> > I should refine my question. Probably gambas does not have native > support for this, but I am not afraid to declare external functions to > implement it. Those function probably are found in kdelibs. The problem > is: what to search for in those libs? And could a gambas program cope > with data types and callbacks, events ar whatever required to do this? > > Thanks, > > -- > Doriano Blengino > > "Listen twice before you speak. > This is why we have two ears, but only one mouth." > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From doriano.blengino at ...1909... Wed Dec 17 10:35:14 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 10:35:14 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <6324a42a0812162332q5b182811id0950ef007bdeb3c@...627...> References: <49480C69.4090608@...1909...> <1f1e8c1b0812161324i252e302r280575439318f327@...627...> <49489DBC.8080506@...1909...> <6324a42a0812162332q5b182811id0950ef007bdeb3c@...627...> Message-ID: <4948C7D2.6030505@...1909...> Dear Fabien, you didn't read my message carefully. I specified I wanted to interact with desktop (kde), it is in the mail subject too. Anyway, I tried your example. When doing D&D in the same application instance, the receiver correctly gets data and format. Dragging between two instances of the same application does work no more - the receiver (Drop event handler) only receives the format data. This is encouraging. This evening I will try some more at home, here at work I don't have KDE. Cheers, Doriano. Fabien Bodard ha scritto: > it's not a gambas ability the problem is to give the good data format > > > ' Gambas class file > > PUBLIC SUB _new() > > END > > PUBLIC SUB Form_Open() > ListBox1.Add(Application.Path &/ "FMain.form") > END > > PUBLIC SUB ListBox1_Drag() > > > > END > > PUBLIC SUB ListBox1_Drop() > > > > END > > PUBLIC SUB Form_Drop() > > Message(Drag.Data) > PRINT Drag.Format > > END > > PUBLIC SUB ListBox1_MouseDown() > > ListBox1.Drag(ListBox1[0].Text, "text/uri-list") > > > END > > > 2008/12/17 Doriano Blengino : > >> M0E Lnx ha scritto: >> >>> AFAIK, such a feature doesn't exist yet... I remember asking about it >>> some time ago. >>> At least not in 2.x >>> >>> On Tue, Dec 16, 2008 at 2:15 PM, Doriano Blengino >>> wrote: >>> >>> >>>> Hi list, >>>> >>>> how can I implement drag&drop with the desktop? >>>> >>>> I mean, drag an item (a filename, for example) to an icon on the >>>> desktop, and viceversa, a file from a file manager to a running gambas >>>> application? >>>> >>>> >>>> >>>> >>> >> I should refine my question. Probably gambas does not have native >> support for this, but I am not afraid to declare external functions to >> implement it. Those function probably are found in kdelibs. The problem >> is: what to search for in those libs? And could a gambas program cope >> with data types and callbacks, events ar whatever required to do this? >> >> From wally at ...2037... Wed Dec 17 11:10:34 2008 From: wally at ...2037... (Wally) Date: Wed, 17 Dec 2008 11:10:34 +0100 Subject: [Gambas-user] Accessing the Treeview Collection Message-ID: <200812171110.34310.wally@...2037...> How to access all items in a Treeview using not using movefirst, movenext etc. ? FOR EACH ... IN Treeview ??? .... NEXT regs wally From gambas.fr at ...626... Wed Dec 17 12:41:02 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Wed, 17 Dec 2008 12:41:02 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <4948C7D2.6030505@...1909...> References: <49480C69.4090608@...1909...> <1f1e8c1b0812161324i252e302r280575439318f327@...627...> <49489DBC.8080506@...1909...> <6324a42a0812162332q5b182811id0950ef007bdeb3c@...627...> <4948C7D2.6030505@...1909...> Message-ID: <6324a42a0812170341g5244f83jcef942d811c1d826@...627...> doriano you have not read carefully my message too ! this is an exemple to interact with desktop it work on KDE4..; 2008/12/17 Doriano Blengino : > Dear Fabien, > > you didn't read my message carefully. I specified I wanted to interact > with desktop (kde), it is in the mail subject too. > > Anyway, I tried your example. When doing D&D in the same application > instance, the receiver correctly gets data and format. Dragging between > two instances of the same application does work no more - the receiver > (Drop event handler) only receives the format data. > > This is encouraging. This evening I will try some more at home, here at > work I don't have KDE. > > Cheers, > Doriano. > > > > Fabien Bodard ha scritto: >> it's not a gambas ability the problem is to give the good data format >> >> >> ' Gambas class file >> >> PUBLIC SUB _new() >> >> END >> >> PUBLIC SUB Form_Open() >> ListBox1.Add(Application.Path &/ "FMain.form") >> END >> >> PUBLIC SUB ListBox1_Drag() >> >> >> >> END >> >> PUBLIC SUB ListBox1_Drop() >> >> >> >> END >> >> PUBLIC SUB Form_Drop() >> >> Message(Drag.Data) >> PRINT Drag.Format >> >> END >> >> PUBLIC SUB ListBox1_MouseDown() >> >> ListBox1.Drag(ListBox1[0].Text, "text/uri-list") >> >> >> END >> >> >> 2008/12/17 Doriano Blengino : >> >>> M0E Lnx ha scritto: >>> >>>> AFAIK, such a feature doesn't exist yet... I remember asking about it >>>> some time ago. >>>> At least not in 2.x >>>> >>>> On Tue, Dec 16, 2008 at 2:15 PM, Doriano Blengino >>>> wrote: >>>> >>>> >>>>> Hi list, >>>>> >>>>> how can I implement drag&drop with the desktop? >>>>> >>>>> I mean, drag an item (a filename, for example) to an icon on the >>>>> desktop, and viceversa, a file from a file manager to a running gambas >>>>> application? >>>>> >>>>> >>>>> >>>>> >>>> >>> I should refine my question. Probably gambas does not have native >>> support for this, but I am not afraid to declare external functions to >>> implement it. Those function probably are found in kdelibs. The problem >>> is: what to search for in those libs? And could a gambas program cope >>> with data types and callbacks, events ar whatever required to do this? >>> >>> > > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -------------- next part -------------- A non-text attachment was scrubbed... Name: dragdemo-0.0.1.tar.gz Type: application/x-gzip Size: 8069 bytes Desc: not available URL: From ronstk at ...239... Wed Dec 17 13:09:52 2008 From: ronstk at ...239... (Ron_1st) Date: Wed, 17 Dec 2008 13:09:52 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <49489BE4.2000208@...1909...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812170437.02878.ronstk@...239...> <49489BE4.2000208@...1909...> Message-ID: <200812171309.53123.ronstk@...239...> On Wednesday 17 December 2008, Doriano Blengino wrote: > Ron_1st ha scritto: ----8<---- > >> > > When I do understand it correct the error in the line > > > >>> EXEC ["mysql", sUser, sPassword, sHost, sDatabase, sImport, sSqlFile ] > >>> > > is the missing path for "mysql" (?) > > > Pardon me. I got confused about the exec system call. > I went to read the documentation, and made a simple test. EXEC finds the > normal executables, in some way; so this is not the problem. OK > > Your problem is that you can not do redirection using "<". It is the > shell /bin/sh that does that; if you use such character in an EXEC > statement, all you obtain is to pass the "<" character to the command > you are invoking which, 99% of the times, will interpret it as a file > name or part of it. > > You can do what you want do by this: > > dim sql_result as string > SHELL "mysql -u user01 -p pwd01 ... < " & Application.Path &/ > "mytables.sql" TO sql_result > > The "to sql_result" implies that the command is fully executed before > returning, and you can analyze the string to look for errors and such. > To use EXEC instead, you shoud do: > > EXEC ["/bin/sh", "-c", "mysql -u user01 -p pwd01 ... < " & > Application.Path &/ "mytables.sql"] to sql_result > > (As you see, it simply calls /bin/sh passing it a command to execute. > IE, this is the same as SHELL!) > > You can avoid to call "/bin/sh" if you don't need /bin/sh functionalities. > > Another, more controlled way, but more complicated, is to create the > pipes yourself, and do what the shell would do. > > SHELL ... FOR INPUT OUTPUT ... > > This way, you can feed the command whatever you want, not just a file > but live data you create on the fly, perhaps reading them from a file > you opened... but this is another matter. Thanks for the lesson, now I understand the difference between EXEC and SHELL a lot more. > > Regards, > > -- > Doriano Blengino > "Listen twice before you speak. > This is why we have two ears, but only one mouth." Best regards Ron_1st -- A: Delete the text you reply on. Q: What to do to get my post on top? A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? P.S. Just a side note. At the moment when I 'reply' kmail strips every thing below the '--' as signature. As result your name is also stripped (I did cut/paste to get it back here) and also automagicly the advertisement from SF is gone away. As in normal written mail the name of the writter is below the 'regards' and it looks to me the '--' shouls below your name instead above. From doriano.blengino at ...1909... Wed Dec 17 13:48:46 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 13:48:46 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <6324a42a0812170341g5244f83jcef942d811c1d826@...627...> References: <49480C69.4090608@...1909...> <1f1e8c1b0812161324i252e302r280575439318f327@...627...> <49489DBC.8080506@...1909...> <6324a42a0812162332q5b182811id0950ef007bdeb3c@...627...> <4948C7D2.6030505@...1909...> <6324a42a0812170341g5244f83jcef942d811c1d826@...627...> Message-ID: <4948F52E.1010701@...1909...> Fabien Bodard ha scritto: > doriano you have not read carefully my message too ! > > this is an exemple to interact with desktop it work on KDE4..; > > Fabien, you are so kind. In your last message there was no word saying "kde" :-), so I assumed you misunderstood. As I stated before, the first example failed to D&D between two instances. Here at work I have no KDE, too; this evening I will try again at home. The last example you sended fails with error 11 - no problem, may be my gambas version is too old (2.0.0); nevertheless I don't understand why it does so... Regards, Doriano From doriano.blengino at ...1909... Wed Dec 17 14:04:21 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 14:04:21 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <200812171309.53123.ronstk@...239...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812170437.02878.ronstk@...239...> <49489BE4.2000208@...1909...> <200812171309.53123.ronstk@...239...> Message-ID: <4948F8D5.8000804@...1909...> Ron_1st ha scritto: > P.S. Just a side note. At the moment when I 'reply' kmail strips every > thing below the '--' as signature. As result your name is also > stripped (I did cut/paste to get it back here) and also automagicly > the advertisement from SF is gone away. As in normal written mail the > name of the writter is below the 'regards' and it looks to me the '--' > shouls below your name instead above. Yes, Mozilla does it too. I started little time ago to use standard signatures, and never noticed this. I am not sure, perhaps Mozilla and kmail do the wrong thing; the "--" followed by the name is the standard way to sign mails. As soon as I configured the signature, it seemed to me that signing in mail body was a duplication, because my name was already present in the bottom. I don't think I am eligible to have a double sign (I'm not so important!), so I started to omit the one in the body, relying on the one in the bottom... does somebody have an authoritative answer about this stupid thing? Anyway, thanks to have pointed this out, regards, Doriano Blengino From doriano.blengino at ...1909... Wed Dec 17 14:09:31 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 14:09:31 +0100 Subject: [Gambas-user] Accessing the Treeview Collection In-Reply-To: <200812171110.34310.wally@...2037...> References: <200812171110.34310.wally@...2037...> Message-ID: <4948FA0B.1000205@...1909...> Wally ha scritto: > How to access all items in a Treeview using > not using movefirst, movenext etc. ? > > FOR EACH ... IN Treeview ??? > .... > NEXT > > regs wally > Do this: if not xxx.MoveFirst() then repeat xxx.item.xxx() ' do things with the current item until xxx.MoveNext() endif TreeView.MoveXXX() return TRUE if there were no more items to move to. Hope this is enough for you to start. Regards, Doriano From gambas at ...1... Wed Dec 17 14:40:57 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 17 Dec 2008 14:40:57 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <4948F8D5.8000804@...1909...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812171309.53123.ronstk@...239...> <4948F8D5.8000804@...1909...> Message-ID: <200812171440.57797.gambas@...1...> On mercredi 17 d?cembre 2008, Doriano Blengino wrote: > Ron_1st ha scritto: > > P.S. Just a side note. At the moment when I 'reply' kmail strips every > > thing below the '--' as signature. As result your name is also > > stripped (I did cut/paste to get it back here) and also automagicly > > the advertisement from SF is gone away. As in normal written mail the > > name of the writter is below the 'regards' and it looks to me the '--' > > shouls below your name instead above. > > Yes, Mozilla does it too. > I started little time ago to use standard signatures, and never noticed > this. > > I am not sure, perhaps Mozilla and kmail do the wrong thing; the "--" > followed by the name is the standard way to sign mails. Actually, it is "-- ". Did you notice the space after the "--"? -- Benoit Minisini From gambas at ...1... Wed Dec 17 14:41:40 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 17 Dec 2008 14:41:40 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <4948F52E.1010701@...1909...> References: <49480C69.4090608@...1909...> <6324a42a0812170341g5244f83jcef942d811c1d826@...627...> <4948F52E.1010701@...1909...> Message-ID: <200812171441.40163.gambas@...1...> On mercredi 17 d?cembre 2008, Doriano Blengino wrote: > Fabien Bodard ha scritto: > > doriano you have not read carefully my message too ! > > > > this is an exemple to interact with desktop it work on KDE4..; > > Fabien, > > you are so kind. In your last message there was no word saying "kde" > > :-), so I assumed you misunderstood. > > As I stated before, the first example failed to D&D between two instances. > Here at work I have no KDE, too; this evening I will try again at home. > > The last example you sended fails with error 11 - no problem, may be my > gambas version is too old (2.0.0); nevertheless I don't understand why > it does so... > > Regards, > Doriano > gb.gtk was not very reliable in 2.0.0. You should use a more recent version! -- Benoit Minisini From wally at ...2037... Wed Dec 17 14:43:07 2008 From: wally at ...2037... (Wally) Date: Wed, 17 Dec 2008 14:43:07 +0100 Subject: [Gambas-user] Accessing the Treeview Collection In-Reply-To: <4948FA0B.1000205@...1909...> References: <200812171110.34310.wally@...2037...> <4948FA0B.1000205@...1909...> Message-ID: <200812171443.07959.wally@...2037...> On Wed December 17 2008 14:09:31 Doriano Blengino wrote: > Wally ha scritto: > > How to access all items in a Treeview using > > not using movefirst, movenext etc. ? > > > > FOR EACH ... IN Treeview ??? > > .... > > NEXT > > > > regs wally > > Do this: > > if not xxx.MoveFirst() then > repeat > xxx.item.xxx() ' do things with the current item > until xxx.MoveNext() > endif > > TreeView.MoveXXX() return TRUE if there were no more items to move to. > > Hope this is enough for you to start. > > Regards, > Doriano > Hi Doriano, PUBLIC SUB Button2_Click() IF NOT TreeView1.MoveFirst() THEN REPEAT 'do things with the current item 'xxx.item.xxx() 'TextArea1.Text &= TreeView1.Item.Key() ' NOT AN OBJECT ! TextArea1.Text &= TreeView1.Item.Key & "\n" 'give just the root-childs UNTIL TreeView1.MoveNext() ENDIF END I got only the root-childs with this code but i think it should be possible with additional treeview.item.count and treevie.item.children loops. I presumed the trreview holds the items in a collection and the collection objects are accessible via FOR EACH IN. regs wally From jussi.lahtinen at ...626... Wed Dec 17 14:47:23 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 17 Dec 2008 15:47:23 +0200 Subject: [Gambas-user] Gambas3 compilation problem In-Reply-To: <200812170021.54100.gambas@...1...> References: <384d3900812100950j12b2bd9bibb5e7c664d8d483b@...627...> <384d3900812161330w48a32b02u5fab3c2c6f2db2e@...627...> <200812170021.54100.gambas@...1...> Message-ID: <384d3900812170547p7e17b8c9r8034627588a8fb7e@...627...> That's odd... since I already compiled Gambas2.9 without problems with libtool 2.2.4 ! So libtool problem is only with gambas3? I readed that wiki entry. I run this command: sudo dpkg --force-downgrade -i libtool_1.5.26-1ubuntu1_amd64.deb And I get these messages: dpkg: error processing libtool_1.5.26-1ubuntu1_amd64.deb (--install): cannot access archive: No such file or directory Errors were encountered while processing: libtool_1.5.26-1ubuntu1_amd64.deb Jussi On Wed, Dec 17, 2008 at 1:21 AM, Benoit Minisini wrote: > On mardi 16 d?cembre 2008, Jussi Lahtinen wrote: >> Hi! >> I must rise this again, it is still problem... ideas? Anyone? >> I tried it again with revision 1740, and same problem. >> Do I need to install something from somewhere..? >> Thanks! >> >> >> Jussi >> >> > > As briefly explained on the wiki, on the Ubuntu page, you must replace the > default libtool package (version 2) by an older one (version 1.5). Otherwise, > Gambas does not compile correctly! > > Regards, > > -- > Benoit Minisini > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From ronstk at ...239... Wed Dec 17 14:53:10 2008 From: ronstk at ...239... (Ron_1st) Date: Wed, 17 Dec 2008 14:53:10 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <4948F8D5.8000804@...1909...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812171309.53123.ronstk@...239...> <4948F8D5.8000804@...1909...> Message-ID: <200812171453.10704.ronstk@...239...> On Wednesday 17 December 2008, Doriano Blengino wrote: > Ron_1st ha scritto: > > P.S. Just a side note. At the moment when I 'reply' kmail strips every > > thing below the '--' as signature. As result your name is also > > stripped (I did cut/paste to get it back here) and also automagicly > > the advertisement from SF is gone away. As in normal written mail the > > name of the writter is below the 'regards' and it looks to me the '--' > > shouls below your name instead above. > > Yes, Mozilla does it too. > I started little time ago to use standard signatures, and never noticed > this. > > I am not sure, perhaps Mozilla and kmail do the wrong thing; the "--" > followed by the name is the standard way to sign mails. As soon as I > configured the signature, it seemed to me that signing in mail body was > a duplication, because my name was already present in the bottom. I > don't think I am eligible to have a double sign (I'm not so important!), I did learn the EXEC/SHELL from you, that is importand! ;) > so I started to omit the one in the body, relying on the one in the > bottom... does somebody have an authoritative answer about this stupid > thing? > > Anyway, thanks to have pointed this out, > > regards, > Doriano Blengino > > It was just I did want to know after problems with my signature in the past, I did search for some information about it. My problem was the missing space after the '--' , it must be '-- ' (with space, RFC 3676 section 4.3) After sending the note I did google and lookup at 'http://email.about.com/cs/netiquettetips/qt/et030601.htm' I think it is a easy misunderstanding of the example(s) given on many sites. He (the writer of the article) is using his own name below the '-- ' because he made the statement and then you get the silly name lines twice. When the statement is by you then you get indead: Regards, Doriano -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." This way your omit of your name is logic but you did the wrong place. In fact you may see a signature as any statement made by someone and place the name of that person as tribute on top of it, below the '-- '. There is no need to use your name if the statment is made by yourself or the writer of the email. You can/may omit the _second_ line with your name and use (if the statement is from yours) next: Regards, Doriano -- "Listen twice before you speak. This is why we have two ears, but only one mouth." I could sign my email with: Best regards, Ron_1st -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth."Best regards, I hope this gives some light in darkness :) Greets, grusse, groeten, Ron_1st -- Benoit Minisini So, Gambas Almost Means BASic! From gambas at ...1... Wed Dec 17 14:57:29 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 17 Dec 2008 14:57:29 +0100 Subject: [Gambas-user] Gambas3 compilation problem In-Reply-To: <384d3900812170547p7e17b8c9r8034627588a8fb7e@...627...> References: <384d3900812100950j12b2bd9bibb5e7c664d8d483b@...627...> <200812170021.54100.gambas@...1...> <384d3900812170547p7e17b8c9r8034627588a8fb7e@...627...> Message-ID: <200812171457.29830.gambas@...1...> On mercredi 17 d?cembre 2008, Jussi Lahtinen wrote: > That's odd... since I already compiled Gambas2.9 without problems with > libtool 2.2.4 ! Really? Can you send me the full output of the compilation of Gambas 2.9 with libtool 2.2.4? If you don't know how to do that, it is explained on the website ('Reporting a problem' page). > So libtool problem is only with gambas3? Maybe. I don't know, as Mandriva only has libtool 1.5. > > I readed that wiki entry. > I run this command: > sudo dpkg --force-downgrade -i libtool_1.5.26-1ubuntu1_amd64.deb > > And I get these messages: > > dpkg: error processing libtool_1.5.26-1ubuntu1_amd64.deb (--install): > cannot access archive: No such file or directory > Errors were encountered while processing: > libtool_1.5.26-1ubuntu1_amd64.deb You must download the package first I suppose... Regards, -- Benoit Minisini From doriano.blengino at ...1909... Wed Dec 17 14:56:47 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 14:56:47 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <200812171440.57797.gambas@...1...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812171309.53123.ronstk@...239...> <4948F8D5.8000804@...1909...> <200812171440.57797.gambas@...1...> Message-ID: <4949051F.7050105@...1909...> Benoit Minisini ha scritto: > On mercredi 17 d?cembre 2008, Doriano Blengino wrote: > >> Ron_1st ha scritto: >> >>> P.S. Just a side note. At the moment when I 'reply' kmail strips every >>> thing below the '--' as signature. As result your name is also >>> stripped (I did cut/paste to get it back here) and also automagicly >>> the advertisement from SF is gone away. As in normal written mail the >>> name of the writter is below the 'regards' and it looks to me the '--' >>> shouls below your name instead above. >>> >> Yes, Mozilla does it too. >> I started little time ago to use standard signatures, and never noticed >> this. >> >> I am not sure, perhaps Mozilla and kmail do the wrong thing; the "--" >> followed by the name is the standard way to sign mails. >> > > Actually, it is "-- ". Did you notice the space after the "--"? > > What do you want to say with this? Anyway, yes; the messages have a space after the two dashes (just checked). These dashes (with a trailing space) are automatically put in by the mail client, not by me... Problem is: should an email client cut out the signature when replying, or not? kmail, Mozilla/Seamonkey and Thunderbird do. Assuming they are right, one should put a sign in the body of an email, but I wanted not to do it, and you too did not in the last two mails... Regards, Doriano From ronstk at ...239... Wed Dec 17 15:06:08 2008 From: ronstk at ...239... (Ron_1st) Date: Wed, 17 Dec 2008 15:06:08 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <200812171440.57797.gambas@...1...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <4948F8D5.8000804@...1909...> <200812171440.57797.gambas@...1...> Message-ID: <200812171506.09143.ronstk@...239...> On Wednesday 17 December 2008, Benoit Minisini wrote: > On mercredi 17 d?cembre 2008, Doriano Blengino wrote: > > Ron_1st ha scritto: > > > P.S. Just a side note. At the moment when I 'reply' kmail strips every > > > thing below the '--' as signature. As result your name is also > > > stripped (I did cut/paste to get it back here) and also automagicly > > > the advertisement from SF is gone away. As in normal written mail the > > > name of the writter is below the 'regards' and it looks to me the '--' > > > shouls below your name instead above. > > > > Yes, Mozilla does it too. > > I started little time ago to use standard signatures, and never noticed > > this. > > > > I am not sure, perhaps Mozilla and kmail do the wrong thing; the "--" > > followed by the name is the standard way to sign mails. > > Actually, it is "-- ". Did you notice the space after the "--"? > Yes I did but forgot to notice it because you do not see it easy :) Did you notice your name is also stripped off when a reply is done? Best regards, Ron_1st -- Obama Yes we can! From doriano.blengino at ...1909... Wed Dec 17 15:10:09 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 15:10:09 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <200812171441.40163.gambas@...1...> References: <49480C69.4090608@...1909...> <6324a42a0812170341g5244f83jcef942d811c1d826@...627...> <4948F52E.1010701@...1909...> <200812171441.40163.gambas@...1...> Message-ID: <49490841.4040008@...1909...> Benoit Minisini ha scritto: > On mercredi 17 d?cembre 2008, Doriano Blengino wrote: > >> Fabien Bodard ha scritto: >> >>> doriano you have not read carefully my message too ! >>> >>> this is an exemple to interact with desktop it work on KDE4..; >>> >> Fabien, >> >> you are so kind. In your last message there was no word saying "kde" >> >> :-), so I assumed you misunderstood. >> >> As I stated before, the first example failed to D&D between two instances. >> Here at work I have no KDE, too; this evening I will try again at home. >> >> The last example you sended fails with error 11 - no problem, may be my >> gambas version is too old (2.0.0); nevertheless I don't understand why >> it does so... >> > > gb.gtk was not very reliable in 2.0.0. You should use a more recent version! > > I don't understand why this error 11 happen, simply because I wrote quite the same thing, and it worked (at least, without error 11). When loaded Fabien's example, even after "Build all", it crashes. Probably this happens because I loaded a newer file with an older IDE/compiler/interpreter. This evening I will do more consistent tests. About the version too old... I am perfectly happy with it. GTK is bad, but QT work wells enough; I don't want to mess my computer up - to install a more recent version of gambas I should upgrade too many things; I have no desire and time neither to do something like that. Then, if I will discover that I absolutely need drag and drop, and D&D only works with more recent versions, then I will update my system. But first I will check where the problem is. Happy D&D'ing to everybody, Doriano Blengino From ronstk at ...239... Wed Dec 17 15:15:24 2008 From: ronstk at ...239... (Ron_1st) Date: Wed, 17 Dec 2008 15:15:24 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <4949051F.7050105@...1909...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812171440.57797.gambas@...1...> <4949051F.7050105@...1909...> Message-ID: <200812171515.24474.ronstk@...239...> On Wednesday 17 December 2008, Doriano Blengino wrote: > Problem is: should an email client cut out the signature when replying, > or not? kmail, Mozilla/Seamonkey and Thunderbird do. Assuming they are > right, one should put a sign in the body of an email, but I wanted not > to do it, and you too did not in the last two mails... > I do would say yes, simple nowadays webmail and SF are adding advertisements to the email and they are then also stripped. This keep them simple to the point. What do I do with email from someone in itali here on the list advertising his free email acount on liberty.it and I can use it. Why should I/you/anybody reply with it inside the email to the list back. See some conversation between people adding multiple advertisemet from SF 8 times in sequence here. This is one of the reasons people do top posting. (reading book from lastpage to first page). See signature here ;) Best regards, Ron_1st -- A: Delete the text you reply on. Q: What to do to get my post on top? A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? From ronstk at ...239... Wed Dec 17 15:30:42 2008 From: ronstk at ...239... (Ron_1st) Date: Wed, 17 Dec 2008 15:30:42 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <49490841.4040008@...1909...> References: <49480C69.4090608@...1909...> <200812171441.40163.gambas@...1...> <49490841.4040008@...1909...> Message-ID: <200812171530.42635.ronstk@...239...> On Wednesday 17 December 2008, Doriano Blengino wrote: > Benoit Minisini ha scritto: > > On mercredi 17 d?cembre 2008, Doriano Blengino wrote: > > > >> Fabien Bodard ha scritto: > >> > >>> doriano you have not read carefully my message too ! > >>> > >>> this is an exemple to interact with desktop it work on KDE4..; > >>> > >> Fabien, > >> > >> you are so kind. In your last message there was no word saying "kde" > >> > >> :-), so I assumed you misunderstood. > >> > >> As I stated before, the first example failed to D&D between two instances. > >> Here at work I have no KDE, too; this evening I will try again at home. > >> > >> The last example you sended fails with error 11 - no problem, may be my > >> gambas version is too old (2.0.0); nevertheless I don't understand why > >> it does so... > >> > > > > gb.gtk was not very reliable in 2.0.0. You should use a more recent version! > > > > > I don't understand why this error 11 happen, simply because I wrote > quite the same thing, and it worked (at least, without error 11). When > loaded Fabien's example, even after "Build all", it crashes. Probably > this happens because I loaded a newer file with an older > IDE/compiler/interpreter. > > This evening I will do more consistent tests. About the version too > old... I am perfectly happy with it. GTK is bad, but QT work wells > enough; I don't want to mess my computer up - to install a more recent > version of gambas I should upgrade too many things; I have no desire and > time neither to do something like that. Then, if I will discover that I > absolutely need drag and drop, and D&D only works with more recent > versions, then I will update my system. But first I will check where the > problem is. > > Happy D&D'ing to everybody, > Doriano Blengino > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > I see some common parts about upgrade. However it cost you now a lot of time to get it as you wishes and that cost a lot of time. Upgrade wil/can resque a part of this time and next development can/will be faster so you transfer the lost time to profit time in future. Your 'first I will check' is the time you learn mostly how to solve other problems to. Its just what is important, learning or less development time, what matters. Best regards, Ron_1st -- A: Delete the text you reply on. Q: What to do to get my post on top? A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? (( see the (unwanted) adds from SF)) From ronstk at ...239... Wed Dec 17 15:40:49 2008 From: ronstk at ...239... (Ron_1st) Date: Wed, 17 Dec 2008 15:40:49 +0100 Subject: [Gambas-user] Accessing the Treeview Collection In-Reply-To: <200812171443.07959.wally@...2037...> References: <200812171110.34310.wally@...2037...> <4948FA0B.1000205@...1909...> <200812171443.07959.wally@...2037...> Message-ID: <200812171540.49977.ronstk@...239...> On Wednesday 17 December 2008, Wally wrote: > On Wed December 17 2008 14:09:31 Doriano Blengino wrote: > > Wally ha scritto: > > > How to access all items in a Treeview using > > > not using movefirst, movenext etc. ? > > > > > > FOR EACH ... IN Treeview ??? > > > .... > > > NEXT > > > > > > regs wally > > > > Do this: > > > > if not xxx.MoveFirst() then > > repeat > > xxx.item.xxx() ' do things with the current item > > until xxx.MoveNext() > > endif > > > > TreeView.MoveXXX() return TRUE if there were no more items to move to. > > > > Hope this is enough for you to start. > > > > Regards, > > Doriano > > > > Hi Doriano, > > PUBLIC SUB Button2_Click() > > IF NOT TreeView1.MoveFirst() THEN > REPEAT > 'do things with the current item > 'xxx.item.xxx() > 'TextArea1.Text &= TreeView1.Item.Key() > ' NOT AN OBJECT ! > TextArea1.Text &= TreeView1.Item.Key & "\n" > 'give just the root-childs > UNTIL TreeView1.MoveNext() > ENDIF > > END > > I got only the root-childs with this code but i think > it should be possible with additional treeview.item.count and > treevie.item.children loops. > I presumed the trreview holds the items in a collection and > the collection objects are accessible via FOR EACH IN. > > regs wally > See also the .MoveAbove and .MoveBelow as complmentary(not strictly). From doriano.blengino at ...1909... Wed Dec 17 15:38:56 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 15:38:56 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <200812171515.24474.ronstk@...239...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812171440.57797.gambas@...1...> <4949051F.7050105@...1909...> <200812171515.24474.ronstk@...239...> Message-ID: <49490F00.4020404@...1909...> Ron_1st ha scritto: > On Wednesday 17 December 2008, Doriano Blengino wrote: > >> Problem is: should an email client cut out the signature when replying, >> or not? kmail, Mozilla/Seamonkey and Thunderbird do. Assuming they are >> right, one should put a sign in the body of an email, but I wanted not >> to do it, and you too did not in the last two mails... >> >> > > I do would say yes, simple nowadays webmail and SF are adding advertisements > to the email and they are then also stripped. This keep them simple to the point. > > What do I do with email from someone in itali here on the list advertising > his free email acount on liberty.it and I can use it. > Why should I/you/anybody reply with it inside the email to the list back. > See some conversation between people adding multiple advertisemet from SF > 8 times in sequence here. This is one of the reasons people do top posting. > (reading book from lastpage to first page). See signature here ;) > > And, in fact, one should edit its message before send, and delete the unrelevant parts. After your last message, which said you went to see internet netiquette, I went too. I discovered the top five rules of email netiquette, and noticed they are always infringed... Well, one of those rules was stating that one should do replies by taking the whole original message, delete unnecessary parts, and write his sentences below. But people is too lazy, commercials are growing more and more aggressive, so mail clients start to be more intelligent. And all this is leading us where I would not want to go... perhaps I am getting too old for computers... Cheers, Doriano From doriano.blengino at ...1909... Wed Dec 17 15:45:35 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 17 Dec 2008 15:45:35 +0100 Subject: [Gambas-user] Accessing the Treeview Collection In-Reply-To: <200812171443.07959.wally@...2037...> References: <200812171110.34310.wally@...2037...> <4948FA0B.1000205@...1909...> <200812171443.07959.wally@...2037...> Message-ID: <4949108F.3060804@...1909...> Wally ha scritto: > On Wed December 17 2008 14:09:31 Doriano Blengino wrote: > >> Wally ha scritto: >> >>> How to access all items in a Treeview using >>> not using movefirst, movenext etc. ? >>> >>> FOR EACH ... IN Treeview ??? >>> .... >>> NEXT >>> >>> regs wally >>> >> Do this: >> >> if not xxx.MoveFirst() then >> repeat >> xxx.item.xxx() ' do things with the current item >> until xxx.MoveNext() >> endif >> >> TreeView.MoveXXX() return TRUE if there were no more items to move to. >> >> Hope this is enough for you to start. >> >> Regards, >> Doriano >> >> > > Hi Doriano, > > PUBLIC SUB Button2_Click() > > IF NOT TreeView1.MoveFirst() THEN > REPEAT > 'do things with the current item > 'xxx.item.xxx() > 'TextArea1.Text &= TreeView1.Item.Key() > ' NOT AN OBJECT ! > > TextArea1.Text &= TreeView1.Item.Key & "\n" > 'give just the root-childs > UNTIL TreeView1.MoveNext() > ENDIF > > END > > I got only the root-childs with this code but i think > it should be possible with additional treeview.item.count and > treevie.item.children loops. > I presumed the trreview holds the items in a collection and > the collection objects are accessible via FOR EACH IN. > > regs wally > Hmmm, docs say that MoveNext() iterates to "next children"; MoveBelow() goes to the "next visible item below". I don't see anything wrong, and MoveNext() should work. Indeed, I used this scheme (MoveFirst + MoveNext), and it seems to me that it works... ...ask Benoit. Regards, Doriano From m0e.lnx at ...626... Wed Dec 17 16:49:34 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Wed, 17 Dec 2008 09:49:34 -0600 Subject: [Gambas-user] sidepanel object + gb.gtk bug Message-ID: <1f1e8c1b0812170749x24bfa7cm36197c3e751c3aa9@...627...> I develop a couple of application in gambas2-2.9.0, both of which have a sidepanel object. Both use gb.gtk. I've found something that I believe is a bug. Does not happen when I use the gb.qt component When I click the little "<" on the side panel (to hide it) it goes well, but when I click it again to restore it, it will not restore it. The little arrow will only turn the other way, but the panel is still hidden. I can drag it and resize it back to normal size, and hiding/restoring after that works flawlessly... but the first time it gets stuck. From wdahn at ...1000... Wed Dec 17 18:11:20 2008 From: wdahn at ...1000... (Werner) Date: Thu, 18 Dec 2008 01:11:20 +0800 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <49490F00.4020404@...1909...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812171440.57797.gambas@...1...> <4949051F.7050105@...1909...> <200812171515.24474.ronstk@...239...> <49490F00.4020404@...1909...> Message-ID: <494932B8.7050906@...1000...> > And all this is leading us where I would not want to go... perhaps I am > getting too old for computers... > Please don't! And I bet I'm older than you. I still remember your insight on udp broadcasting. Thanks for that. Werner From jussi.lahtinen at ...626... Wed Dec 17 18:35:26 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 17 Dec 2008 19:35:26 +0200 Subject: [Gambas-user] Gambas3 compilation problem In-Reply-To: <200812171457.29830.gambas@...1...> References: <384d3900812100950j12b2bd9bibb5e7c664d8d483b@...627...> <200812170021.54100.gambas@...1...> <384d3900812170547p7e17b8c9r8034627588a8fb7e@...627...> <200812171457.29830.gambas@...1...> Message-ID: <384d3900812170935h702a7453v736b5dd65dfebf0a@...627...> >> That's odd... since I already compiled Gambas2.9 without problems with >> libtool 2.2.4 ! > > Really? Can you send me the full output of the compilation of Gambas 2.9 with > libtool 2.2.4? If you don't know how to do that, it is explained on the > website ('Reporting a problem' page). Ok, I tried to ./reconf on gambas2.9 source folder, and I got exactly same errors than with gambas3 source. I'm pretty confused right now. I upgraded Ubuntu 8.04 to 8.10 at 31 Oct 2008. Then I found gambas and I installed it from ubuntu repository. I noticed that it is not latest version so I compiled 2.9 from source at 19 Nov 2008. So when has libtool version changed? I assumed libtool 2.2.4 was shipped with Ubuntu 8.10. So I have no clue which libtool version I really had when I compiled 2.9. > You must download the package first I suppose... Hah! Crap... of course. That command doesn't use repositories... Ok, I downloaded libtool 1.5. Then: sudo dpkg --force-downgrade -i libtool_1.5.26-1ubuntu1_amd64.deb Done ok. Then: svn checkout https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk/ Checked out revision 1742. Then: ./reconf-all And I get these two lines: configure.ac: required file `./mkinstalldirs' not found autoreconf: automake failed with exit status: 1 Jussi From wally at ...2037... Wed Dec 17 20:10:48 2008 From: wally at ...2037... (Wally) Date: Wed, 17 Dec 2008 20:10:48 +0100 Subject: [Gambas-user] Accessing the Treeview Collection In-Reply-To: <4949108F.3060804@...1909...> References: <200812171110.34310.wally@...2037...> <200812171443.07959.wally@...2037...> <4949108F.3060804@...1909...> Message-ID: <200812172010.48849.wally@...2037...> On Wed December 17 2008 15:45:35 Doriano Blengino wrote: > Wally ha scritto: > > On Wed December 17 2008 14:09:31 Doriano Blengino wrote: > >> Wally ha scritto: > >>> How to access all items in a Treeview using > >>> not using movefirst, movenext etc. ? > >>> > >>> FOR EACH ... IN Treeview ??? > >>> .... > >>> NEXT > >>> > >>> regs wally > >> > >> Do this: > >> > >> if not xxx.MoveFirst() then > >> repeat > >> xxx.item.xxx() ' do things with the current item > >> until xxx.MoveNext() > >> endif > >> > >> TreeView.MoveXXX() return TRUE if there were no more items to move to. > >> > >> Hope this is enough for you to start. > >> > >> Regards, > >> Doriano > > > > Hi Doriano, > > > > PUBLIC SUB Button2_Click() > > > > IF NOT TreeView1.MoveFirst() THEN > > REPEAT > > 'do things with the current item > > 'xxx.item.xxx() > > 'TextArea1.Text &= TreeView1.Item.Key() > > ' NOT AN OBJECT ! > > > > TextArea1.Text &= TreeView1.Item.Key & "\n" > > 'give just the root-childs > > UNTIL TreeView1.MoveNext() > > ENDIF > > > > END > > > > I got only the root-childs with this code but i think > > it should be possible with additional treeview.item.count and > > treevie.item.children loops. > > I presumed the trreview holds the items in a collection and > > the collection objects are accessible via FOR EACH IN. > > > > regs wally > > Hmmm, > docs say that MoveNext() iterates to "next children"; MoveBelow() goes > to the "next visible item below". > I don't see anything wrong, and MoveNext() should work. Indeed, I used > this scheme (MoveFirst + MoveNext), and it seems to me that it works... > > ...ask Benoit. > > Regards, > Doriano I think the following code does it and its clear. (except the "ugly" labels and goto's ) thx, for ideas how to make more brief. '################################################################## PUBLIC SUB Button3_Click() 'get all keys from treeview ' GoTop start TreeView1.MoveFirst TextArea1.Text &= TreeView1.Item.Key & "\n" GOTO CC 'CC CheckOnChild CC: IF NOT TreeView1.MoveChild() TextArea1.Text &= TreeView1.Item.Key & "\n" GOTO CC ELSE TreeView1.MoveBack GOTO CS ENDIF 'CS CheckOnSibling CS: IF NOT TreeView1.MoveNext() TextArea1.Text &= TreeView1.Item.Key & "\n" GOTO CC ELSE TreeView1.MoveBack GOTO CP ENDIF 'CP CheckOnParent CP: IF NOT TreeView1.MoveParent() GOTO CS ELSE TextArea1.Text &= "Finished" & "\n" ENDIF END '################################################################## regs wally From Karl.Reinl at ...9... Wed Dec 17 20:14:01 2008 From: Karl.Reinl at ...9... (Charlie Reinl) Date: Wed, 17 Dec 2008 20:14:01 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <49490F00.4020404@...1909...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812171440.57797.gambas@...1...> <4949051F.7050105@...1909...> <200812171515.24474.ronstk@...239...> <49490F00.4020404@...1909...> Message-ID: <1229541241.6507.25.camel@...40...> ---8< ------ I cutted it all --- Salut Doriano, someone who knows what 'internet netiquette' is, is not too old to use computers. That would mean, that all who have seen World War 2nd, are too old to eat, because food was scarce at this time. No! Nowadays memory and speed is no more a problem, so 'internet netiquette' also, is no more a problem! Call it progress !?!?!, but eat, oh pardon, no you are not too old for computers. But you know a part of the future / past. -- Amicalment Charlie From doriano.blengino at ...1909... Thu Dec 18 00:01:13 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Thu, 18 Dec 2008 00:01:13 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <1229541241.6507.25.camel@...40...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <200812171440.57797.gambas@...1...> <4949051F.7050105@...1909...> <200812171515.24474.ronstk@...239...> <49490F00.4020404@...1909...> <1229541241.6507.25.camel@...40...> Message-ID: <494984B9.4030008@...1909...> Charlie Reinl ha scritto: > ---8< ------ I cutted it all --- > > Salut Doriano, > > someone who knows what 'internet netiquette' is, > is not too old to use computers. > > That would mean, that all who have seen World War 2nd, > are too old to eat, because food was scarce at this time. > > No! Nowadays memory and speed is no more a problem, so 'internet > netiquette' also, is no more a problem! > > Call it progress !?!?!, but eat, oh pardon, no you are not too old for > computers. But you know a part of the future / past. > > Oops, perhaps my sentence was too loud. Just to clarify: I am 45 years old. I don't know if I am old enough to speak like an old man (I think "no") and no, I never seen the World War 2nd. My sentence was mainly ironic, but there is a little truth in it. One does not become old in one step - there is a whole life in between. But, step by step, we all approach a different style of thinking. So, my thought is no more the same as when I was 20. If I was 20, I would think "Wow! This new email client strips off the signature, along with advertising!". Now, I think "I am really annoyed by libraries, marketing, profits, C sources, investors, banks, insurances, lawyers, bad people, tarballs, dependencies. Why I have to see all this advertising rubbish and all this compiling problems?". The next step will be "Computers are so complicated, and the whole world is so wrong...". At that time, I will be "old". At this time, I am not old enough to hate computers, but I am on the way: I hate javascript and flash graphics in stupid web pages, spamming, advertising and MS Word documents in emails, viruses and trojans, Wi-Fi, and a fair quantity of contemporary music... Sad to say, but the only place where things are not getting worse is this new wind of Linux and free software. I hope that this new wind has fertile lands to invade. Well - this is enough. Sorry for annoying anyone which could read this email. This is not the right place to speak about life. Cheers to everybody (should I sign or not? Ok, let's do it...), Doriano -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From jussi.lahtinen at ...626... Thu Dec 18 00:21:57 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Thu, 18 Dec 2008 01:21:57 +0200 Subject: [Gambas-user] Better way to delete element from array when enumerating Message-ID: <384d3900812171521i47b12bc1s14aa91da71d646c1@...627...> Hi! I have code like this: Dim element as ClassX FOR EACH element IN objectarray IF element = something THEN objectarray.Remove(objectarray.Find(element)) ENDIF NEXT This works, but I'm almost sure that there is better way to do this. Feel kind of dumb to find same element two times... Jussi From gambas at ...1... Thu Dec 18 01:57:38 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 18 Dec 2008 01:57:38 +0100 Subject: [Gambas-user] Error on Connection when closing In-Reply-To: <23846.5284.qm@...1678...> References: <23846.5284.qm@...1678...> Message-ID: <200812180157.38613.gambas@...1...> On mardi 16 d?cembre 2008, David Villalobos Cambronero wrote: > Hi, I got an error when close my connection at runtime, the error is easy, > the connection is not closed, it still accepts queries. > > Is the .Close() Method supposed to close the connection meaning that it > won't accept queries or I'm wrong. See the attached example. > > Gambas 3, svn 1740, Mandriva 2008.1 32 Bits and MySQL. > > Benoit, can you confirm. > > Regards > > > -- > David This is "normal": a closed connection is automatically reopened as soon as it is used. Someone requested this feature, but I don't remember who. Regards, -- Benoit Minisini From gambas at ...1... Thu Dec 18 02:02:55 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 18 Dec 2008 02:02:55 +0100 Subject: [Gambas-user] last line of editor In-Reply-To: References: Message-ID: <200812180202.55887.gambas@...1...> On mardi 16 d?cembre 2008, Demosthenes Koptsis wrote: > Hi to all, > > i have a text area and i want when i feed text to it to go to the last > line of it, so i wrote the next code that works fine > > PUBLIC SUB txaSQL_Change() > > txaSQL.Pos = Len(txaSQL.Text) > > END > > how can i have the same result with an editor control? TheEditor.Goto(TheEditor.Lines.Count, 0) -- Benoit Minisini From gambas at ...1... Thu Dec 18 02:06:09 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 18 Dec 2008 02:06:09 +0100 Subject: [Gambas-user] error calling external function but not when debugging In-Reply-To: References: Message-ID: <200812180206.09681.gambas@...1...> On lundi 15 d?cembre 2008, je ber lo wrote: > hello, I'm using gambas 2.8 on debian and I'm getting different result when > debugging code ( the result is a md5 hash string (32 characters)) but no > when executing in a normal way. The error is > > Failed to set text from markup due to error parsing markup: Error on line 1 > char 10: Invalid UTF-8 encoded text - not valid '??$R > ???\u0002}60b725f10c9c85c70d97880dfe8191b3' > > The correct result is string 60b725f10c9c85c70d97880dfe8191b3 > > sometimes I get the following message too. *** glibc detected *** > dinamic: double free or corruption (out): 0x08894530 *** > > > I declare the function > > EXTERN md5file(filename AS String, resultado AS Pointer) AS Pointer IN > "mimd5sum" > > I call the function with > > DIM cas AS Pointer > DIM cas2 AS Pointer > DIM cad AS String > > cas = Alloc(33) > cas2 = md5file("/prueba.txt", cas) > cad = StrPtr(cas2) > Message(cad) > Free(cas) > > > and the function in laguage C is: > > void miMDPrint (MD5_CTX *mdContext, char* resultado) > { > int i; > > char cadtemporal[3]=""; > > for (i = 0; i < 16; i++) { > sprintf (cadtemporal, "%02x", mdContext->digest[i]); > strcat(resultado, cadtemporal); > } > //strcat(resultado,""); > > > } > > > char* md5file (char* filename,char* resultado) > { > > FILE *inFile = fopen (filename, "rb"); > MD5_CTX mdContext; > int bytes; > unsigned char data[1024]; > > if (inFile == NULL) { > //printf ("%s can't be opened.\n", filename); > return NULL; > } > > MD5Init (&mdContext); > while ((bytes = fread (data, 1, 1024, inFile)) != 0) > MD5Update (&mdContext, data, bytes); > MD5Final (&mdContext); > miMDPrint (&mdContext,resultado); > fclose (inFile); > > return resultado; > > } > > Any idea about this problem is welcome. > > Regards. Please send your project, the library, and the needed file data, and explain exactly what should be done to reproduce the bug. Regards, -- Benoit Minisini From gambas at ...1... Thu Dec 18 02:09:00 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 18 Dec 2008 02:09:00 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229256516.26984.4.camel@...37...> References: <1229256516.26984.4.camel@...37...> Message-ID: <200812180209.00696.gambas@...1...> On dimanche 14 d?cembre 2008, Luigi Carlotto wrote: > In my application I execute a rescue on XML file of some data. > The rescue executes before a conversion: Conv (string, ?UTF-8?, ?ASCII?) > During my tests, I have noticed that some errors are taken place: > 1) if the string is larger than 2000 characters (approximately), > XmlWrite.Attribute() crash; > 2) if the language comes set up to Chinese (UTF-8), the conversion with > Conv() crash; same behavior if is used XmlWrite.Attribute(), or > XmlWrite.Element(), without to execute conversions. > I have noticed that the errors take place alone if System.Language=zh_CN > and System.Charset=UTF-8, while with various languages seems to go all > good. > > Error message: > > encoding error : output conversion failed due to conv error, bytes 0xE5 > 0x31 0x32 0xE5 > I/O error : encoder error > > The bytes indicated from the message they do not seem to correspond, > neither are comprised, in no string between those which they come saved > in XML file. > > To notice that the reading from XML file is OK, while the writing > finishes with the error described in mine precedence mail, if the > writing of XML file with System.Language=zh_CN (Chinese); with other > languages (Italian, French, English and Spanish) it is all to OK. > > >From some tests it begins them seemed that the anomaly depended also > > from the dimensions of the string, but this had to cause the crash also > with the other formulations, what that instead does not happen. The > strange thing that I have noticed, is that the dimensions of the content > of the string, with Language=zh_CN, are much smaller of the usual; I > imagine that this depends from as the String object it manages the data, > but that turns out me also the Chinese characters use advanced values to > 256. > > In any case, the application is too much large and complex for being > sent and described in a mail? However, the errors take place (DEBUG) in > the Save() method, for which at the moment shipment only the functions > interested. If they serve more information, no problems. > > The function toString () works OK, and returns the attended string, but > the conversion finishes then in error. > > '--- > ' Save settings > ' > PUBLIC SUB Save() > DIM oGroup AS pgConfigGroup > DIM oItem AS pgConfigItem > DIM oXml AS XmlWriter > 'open file for writing > oXml = NEW XmlWriter > oXml.Open($filename, TRUE, "UTF8") > 'write header > oXml.StartElement(pgApplication.Name) > oXml.Attribute("Type", Str("Config")) > oXml.Attribute("Version", pgUtil.SetVersion(VERSION)) > oXml.Attribute("Date", Str(Now())) > 'write elements > FOR EACH oGroup IN $data > oXml.StartElement(oGroup.Name) > FOR EACH oItem IN oGroup.Items > oXml.Attribute(oItem.Name, Conv(oItem.toString(), "UTF-8", > "ASCII")) > NEXT > oXml.EndElement > NEXT > 'write footer > oXml.EndElement > oXml.EndDocument > END > ... > ... > ... > '--- > ' Convert any value into single string > ' > PUBLIC FUNCTION toString() AS String > DIM iPos AS Integer > DIM aText AS String[] > SELECT CASE $type > CASE TYPE_STRING 'gb.String > RETURN Str(IIf(IsNull($value), "", $value)) > CASE TYPE_INTEGER 'gb.Integer > RETURN Str(IIf(IsNull($value), "0", $value)) > CASE TYPE_BOOLEAN 'gb.Boolean > RETURN Str(IIf(IsNull($value), "false", IIf($value, "true", > "false"))) > CASE TYPE_STRINGARRAY 'String[] object > IF (IsNull($value)) OR IF ($value.Count = 0) THEN RETURN Str("") > RETURN Str($value.Join(",")) > CASE TYPE_INTEGERARRAY 'Integer[] object > IF (IsNull($value)) OR IF ($value.Count = 0) THEN RETURN Str("") > aText = NEW String[] > FOR EACH iPos IN $value > aText.Add(Str(iPos)) > NEXT > RETURN Str(aText.Join(",")) > CASE TYPE_COLOR 'custom color object > RETURN Str(IIf(IsNull($value), "0,0,0", pgColor.ColorToStr($value))) > END SELECT > END > > Help? As explained privately, the conversion from UTF-8 to ASCII function should fail as soon as the string has no ASCII character. But it should not crash (i.e. signal #11). Anyway, there is no point in converting UTF-8 to ASCII, because there are only two possibilities: the UTF-8 string has only ASCII characters, and the UTF-8 string is already an ASCII string, and so the conversion is possible, or the UTF-8 has some non-ASCII characters, and the conversion is impossible and fails. Regards, -- Benoit Minisini From gambas at ...1... Thu Dec 18 02:10:20 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 18 Dec 2008 02:10:20 +0100 Subject: [Gambas-user] Command completion In-Reply-To: <200812131857.08427.gambas@...1938...> References: <200812131857.08427.gambas@...1938...> Message-ID: <200812180210.20915.gambas@...1...> On samedi 13 d?cembre 2008, gambas at ...1938... wrote: > Hi Benoit, > > in Gambas3 (snapshot from friday), when writing a long line, so that the > IDE begins to scroll, there is no command completion anymore. > > Greetz > Stevie > In Gambas 2 too. As soon as something scrolls in the editor, completion and signature popups are hidden. I admit that the editor should be more clever and just move them. -- Benoit Minisini From doriano.blengino at ...1909... Thu Dec 18 08:38:13 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Thu, 18 Dec 2008 08:38:13 +0100 Subject: [Gambas-user] Drag & Drop to KDE Desktop In-Reply-To: <200812171530.42635.ronstk@...239...> References: <49480C69.4090608@...1909...> <200812171441.40163.gambas@...1...> <49490841.4040008@...1909...> <200812171530.42635.ronstk@...239...> Message-ID: <4949FDE5.9040705@...1909...> Ron_1st ha scritto: > On Wednesday 17 December 2008, Doriano Blengino wrote: > >> Benoit Minisini ha scritto: >> >>> On mercredi 17 d?cembre 2008, Doriano Blengino wrote: >>> >>> >>>> Fabien Bodard ha scritto: >>>> >>>> >>>>> doriano you have not read carefully my message too ! >>>>> >>>>> this is an exemple to interact with desktop it work on KDE4..; >>>>> >>>>> >>>> Fabien, >>>> >>>> you are so kind. In your last message there was no word saying "kde" >>>> >>>> :-), so I assumed you misunderstood. >>>> >>>> As I stated before, the first example failed to D&D between two instances. >>>> Here at work I have no KDE, too; this evening I will try again at home. >>>> >>>> The last example you sended fails with error 11 - no problem, may be my >>>> gambas version is too old (2.0.0); nevertheless I don't understand why >>>> it does so... >>>> >>>> >>> gb.gtk was not very reliable in 2.0.0. You should use a more recent version! >>> >>> >>> >> I don't understand why this error 11 happen, simply because I wrote >> quite the same thing, and it worked (at least, without error 11). When >> loaded Fabien's example, even after "Build all", it crashes. Probably >> this happens because I loaded a newer file with an older >> IDE/compiler/interpreter. >> >> I conducted my tests about drag and drop. As I was suspecting, with QT and KDE it works flawlessly, even if my version is only 2.0.0. I deleted by mistake the original Fabien's project, but probably that project would had crashed, the same way as it happened at work. But tomorrow I will take it again, because I am still convinced that there is nothing wrong in it. GTK does not work at all - who cares, it has other problems too, so I stick to QT. About the data and format to drag, I opened Konqueror to drag files into my application and see what it was sending: an uri in the form "file://..." with format "text/uri-list". Simple enough. So, I have all I wanted to have: my customized gambas 2.0.0 and drag & drop in my desktop. At work I use a X11 server in a windows XP machine... drag & drop did'nt work but anyway there are no icons to drag data to... perhaps. -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From gambas at ...1938... Thu Dec 18 11:46:26 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Thu, 18 Dec 2008 11:46:26 +0100 Subject: [Gambas-user] import mysql dump EXEC or SHELL? In-Reply-To: <494984B9.4030008@...1909...> References: <40852.81.247.107.186.1229340160.squirrel@...1810...> <1229541241.6507.25.camel@...40...> <494984B9.4030008@...1909...> Message-ID: <200812181146.26769.gambas@...1938...> Am Donnerstag, 18. Dezember 2008 00:01:13 schrieb Doriano Blengino: > Charlie Reinl ha scritto: > Oops, perhaps my sentence was too loud. > Just to clarify: I am 45 years old. I don't know if I am old enough to > speak like an old man (I think "no") and no, I never seen the World War > 2nd. > > My sentence was mainly ironic, but there is a little truth in it. One > does not become old in one step - there is a whole life in between. But, > step by step, we all approach a different style of thinking. So, my > thought is no more the same as when I was 20. > If I was 20, I would think "Wow! This new email client strips off the > signature, along with advertising!". Now, I think "I am really annoyed > by libraries, marketing, profits, C sources, investors, banks, > insurances, lawyers, bad people, tarballs, dependencies. Why I have to > see all this advertising rubbish and all this compiling problems?". The > next step will be "Computers are so complicated, and the whole world is > so wrong...". At that time, I will be "old". > > At this time, I am not old enough to hate computers, but I am on the > way: I hate javascript and flash graphics in stupid web pages, spamming, > advertising and MS Word documents in emails, viruses and trojans, Wi-Fi, > and a fair quantity of contemporary music... > > Sad to say, but the only place where things are not getting worse is > this new wind of Linux and free software. I hope that this new wind has > fertile lands to invade. > > Well - this is enough. Sorry for annoying anyone which could read this > email. This is not the right place to speak about life. > > Cheers to everybody (should I sign or not? Ok, let's do it...), > Doriano Full Ack for this post! :-) Greetz Stevie From wally at ...2037... Thu Dec 18 12:16:19 2008 From: wally at ...2037... (Wally) Date: Thu, 18 Dec 2008 12:16:19 +0100 Subject: [Gambas-user] Code Editor feature Message-ID: <200812181216.19737.wally@...2037...> I wonder if there might be a way to use drag & drop(shift/Ctrl) with code fragments in the Gambas Code Editor. Also would be great to fold (epand/collapse) SUB's and FUNCTIONS. Is it already possible or is it a feature reauest ? regs wally From leo_senpao at ...1541... Thu Dec 18 16:44:30 2008 From: leo_senpao at ...1541... (Leo Sendra) Date: Thu, 18 Dec 2008 23:44:30 +0800 (SGT) Subject: [Gambas-user] Ask about POS Printer and Gambas Message-ID: <154394.49258.qm@...1989...> Hi all, Does anybody have some experiences using printer Samsung SRP-270?? How to code this printer in Gambas?? Thanks ___________________________________________________________________________ Nama baru untuk Anda! Dapatkan nama yang selalu Anda inginkan di domain baru @ymail dan @rocketmail. Cepat sebelum diambil orang lain! http://mail.promotions.yahoo.com/newdomains/id/ From eilert-sprachen at ...221... Thu Dec 18 18:28:55 2008 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Thu, 18 Dec 2008 18:28:55 +0100 Subject: [Gambas-user] Ask about POS Printer and Gambas In-Reply-To: <154394.49258.qm@...1989...> References: <154394.49258.qm@...1989...> Message-ID: <494A8857.6030202@...221...> Leo Sendra schrieb: > Hi all, > > Does anybody have some experiences using printer Samsung SRP-270?? > How to code this printer in Gambas?? > > Thanks > > Ok, googling the web brought me up some sites offering this printer. On one of them, the technical features included "Compatible with competitor's emulation's including Epson, Star and Citizen" So I would say, what you need first is a printer "driver" for your Linux distribution (Epson or Star driver), i. e. you should be able to address it like any other standard matrix printer. Just with smaller paper size :-) Then comes the Gambas part: writing code that uses the printer object to write something to the printer, but you will not really have to care about technical background anymore. According to that description, this printer can print graphics, so the Linux fonts and stuff should be possible without big problems. Rolf From demosthenesk at ...626... Thu Dec 18 20:42:22 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Thu, 18 Dec 2008 21:42:22 +0200 Subject: [Gambas-user] last line of editor In-Reply-To: <200812180202.55887.gambas@...1...> References: <200812180202.55887.gambas@...1...> Message-ID: Actually this was my thought, to put this statement in SUB Editor_Change() but it doesnot work, that's why i ask you...what am i doing wrong? my code is PBLIC SUB edtSQL_Change() edtSQL.Goto(edtSQL.Lines.Count, 0) END but when i change editors text with edtSQL.text="somethiing" does not go to last line On 12/18/08, Benoit Minisini wrote: > On mardi 16 d?cembre 2008, Demosthenes Koptsis wrote: >> Hi to all, >> >> i have a text area and i want when i feed text to it to go to the last >> line of it, so i wrote the next code that works fine >> >> PUBLIC SUB txaSQL_Change() >> >> txaSQL.Pos = Len(txaSQL.Text) >> >> END >> >> how can i have the same result with an editor control? > > TheEditor.Goto(TheEditor.Lines.Count, 0) > > -- > Benoit Minisini > > ------------------------------------------------------------------------------ > SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. > The future of the web can't happen without you. Join us at MIX09 to help > pave the way to the Next Web now. Learn more and register at > http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From gambas at ...1... Thu Dec 18 23:00:41 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 18 Dec 2008 23:00:41 +0100 Subject: [Gambas-user] last line of editor In-Reply-To: References: <200812180202.55887.gambas@...1...> Message-ID: <200812182300.41633.gambas@...1...> On jeudi 18 d?cembre 2008, Demosthenes Koptsis wrote: > Actually this was my thought, to put this statement in SUB Editor_Change() > > but it doesnot work, that's why i ask you...what am i doing wrong? > > my code is > > PBLIC SUB edtSQL_Change() > > edtSQL.Goto(edtSQL.Lines.Count, 0) > > END > Moving the cursor during a Change event is risky, as you don't know if the editor will move the cursor again after the event. > but when i change editors text with edtSQL.text="somethiing" does not > go to last line > Setting the Text property changes the text, raises the Change event, and the moves the cursor to the top. So if you want to put it at the end, you must use the Goto() method just after. Regards, -- Benoit Minisini From wig at ...1809... Fri Dec 19 11:39:07 2008 From: wig at ...1809... (wig) Date: Fri, 19 Dec 2008 11:39:07 +0100 (CET) Subject: [Gambas-user] Localisation: find available language(s) Message-ID: <59794.81.245.45.56.1229683147.squirrel@...1810...> I want to show the available languages (translations) for my project. Is there a way to "get" the available languages in Gambas like aLanguages = Application.Languages ? Or is it stored as metadata in some file? If not, I understand that in the project directory .. myproject/.lang .. I can find the language files ending on .po and .mo I could use them as indication of available languages. Or is there a better way? From gambas at ...1... Fri Dec 19 14:10:53 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 19 Dec 2008 14:10:53 +0100 Subject: [Gambas-user] Localisation: find available language(s) In-Reply-To: <59794.81.245.45.56.1229683147.squirrel@...1810...> References: <59794.81.245.45.56.1229683147.squirrel@...1810...> Message-ID: <200812191410.54041.gambas@...1...> On vendredi 19 d?cembre 2008, wig wrote: > I want to show the available languages (translations) for my project. > > Is there a way to "get" the available languages in Gambas like > > aLanguages = Application.Languages ? > > Or is it stored as metadata in some file? > > If not, I understand that in the project directory .. > myproject/.lang > .. I can find the language files ending on .po and .mo > > I could use them as indication of available languages. > > Or is there a better way? > There is no better way. But it work only in trunk because of a bug that was fixed recently. Regards, -- Benoit Minisini From gambas at ...1... Fri Dec 19 14:14:40 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 19 Dec 2008 14:14:40 +0100 Subject: [Gambas-user] Code Editor feature In-Reply-To: <200812181216.19737.wally@...2037...> References: <200812181216.19737.wally@...2037...> Message-ID: <200812191414.40085.gambas@...1...> On jeudi 18 d?cembre 2008, Wally wrote: > I wonder if there might be a way to use drag & drop(shift/Ctrl) > with code fragments in the Gambas Code Editor. Can you give more details? > > Also would be great to fold (epand/collapse) SUB's and FUNCTIONS. This was done in the development version (Gambas 3). Regards, -- Benoit Minisini From ronstk at ...239... Fri Dec 19 16:41:37 2008 From: ronstk at ...239... (Ron_1st) Date: Fri, 19 Dec 2008 16:41:37 +0100 Subject: [Gambas-user] Code Editor feature In-Reply-To: <200812191414.40085.gambas@...1...> References: <200812181216.19737.wally@...2037...> <200812191414.40085.gambas@...1...> Message-ID: <200812191641.38083.ronstk@...239...> On Friday 19 December 2008, Benoit Minisini wrote: > On jeudi 18 d?cembre 2008, Wally wrote: > > I wonder if there might be a way to use drag & drop(shift/Ctrl) > > with code fragments in the Gambas Code Editor. > > Can you give more details? > > > > > Also would be great to fold (epand/collapse) SUB's and FUNCTIONS. > > This was done in the development version (Gambas 3). > > Regards, > The drag and drop was available in the old editor( without line numbers), pre 1.0 version of gambas. After the switch to the new editor (with linenumbers) it was gone. I have at that time already send a report about missing this. The best example I can give you ATM is in kate (KDE) I'm creating a lot of source files and to i.e. reorder the text I select words, lines or even part of words and drag it to other places. I works simple by select the part you need and at the next mouse down inside the selected text part and moving the mouse will start the D&D process. At release of mouse the part stays on the new place. The second question is also a great wish of me. I'm happy to get it in Gambas 3, Kate does not have it yet(?) Best regards, Ron_1st -- From gambas at ...1... Sat Dec 20 19:31:11 2008 From: gambas at ...1... (Benoit Minisini) Date: Sat, 20 Dec 2008 19:31:11 +0100 Subject: [Gambas-user] SQLite and INT4 vs. INTEGER In-Reply-To: <21041236.post@...1379...> References: <21041236.post@...1379...> Message-ID: <200812201931.11133.gambas@...1...> On mardi 16 d?cembre 2008, moon_walker wrote: > Hi Benoit, > > i am developing a cross platform application. The linux side is on GAMBAS > and the Win side is on > C#.NET. The common part is the SQLite database. > > There is some foreign relations which are coupled with comboboxes. > So the child table has some foreign key fields joined to parent primary > keys. > > In the parent tables the primary keys are defined as autoincrement. Since i > was unable to use the type gb.serial at all, i defined this keys in > SQLite-datamanager in firefox. I realised that SQLite only allows > autoincrement for primary key INTEGER. However gambas database manager use > INT4 for the foreign key fields in the child table. > This causes inconsistency in .NET since it is impossible to create > relations on type mismatched fields (INT4 vs INTEGER). If i switch all > related fields to INTEGER then GAMBAS is unable to handle tha databounded > combobox. > > I would prefer that instead of INT4, only INTEGER would be used general by > SQLite area. > > thx > br > Attila I didn't find any clean way to know if a field is an autoincrement field with sqlite 3 API. There is a function, but it is not necesarilly compiled in all versions of sqlite 3 (and apparently not on Mandriva). So the AUTOINCREMENT feature is detected by the use of INTEGER, whereas INT4 is used with norma integer fields. If I find a way to detect autoincrement fields, you won't have any problem! -- Benoit Minisini From jussi.lahtinen at ...626... Sat Dec 20 21:52:09 2008 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sat, 20 Dec 2008 22:52:09 +0200 Subject: [Gambas-user] Sidepanel bug? Message-ID: <384d3900812201252k6abe2115o12030f7ab9e05791@...627...> Hi! Is this planned behavior; Orientation left/right changes just hide buttons placement, NOT direction where sidepanel opens? I need sidepanel to right side of screen, now it is not possible. Problem is noticed on QT at program run state. Gambas2.9 at ...2029... 8.10 Jussi From joshiggins at ...1601... Sun Dec 21 02:17:56 2008 From: joshiggins at ...1601... (Joshua Higgins) Date: Sun, 21 Dec 2008 01:17:56 +0000 Subject: [Gambas-user] read commandline invocation Message-ID: <4247f5440812201717v1212d121p255acc0bf5e97169@...627...> Probably a stupid question, but I can't figure it out :S How do I get my Gambas program to read how it was invoked from the command line? Thanks. -- joshua higgins >>>>>>------ From gambas at ...1... Sun Dec 21 06:18:05 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 21 Dec 2008 06:18:05 +0100 Subject: [Gambas-user] sidepanel object + gb.gtk bug In-Reply-To: <1f1e8c1b0812170749x24bfa7cm36197c3e751c3aa9@...627...> References: <1f1e8c1b0812170749x24bfa7cm36197c3e751c3aa9@...627...> Message-ID: <200812210618.05724.gambas@...1...> On mercredi 17 d?cembre 2008, M0E Lnx wrote: > I develop a couple of application in gambas2-2.9.0, both of which have > a sidepanel object. Both use gb.gtk. > I've found something that I believe is a bug. Does not happen when I > use the gb.qt component > > When I click the little "<" on the side panel (to hide it) it goes > well, but when I click it again to restore it, it will not restore it. > The little arrow will only turn the other way, but the panel is still > hidden. > > I can drag it and resize it back to normal size, and hiding/restoring > after that works flawlessly... but the first time it gets stuck. > I cannot reproduce the problem: can you send me a little project that has the bug? -- Benoit Minisini From gambas at ...1... Sun Dec 21 06:20:24 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 21 Dec 2008 06:20:24 +0100 Subject: [Gambas-user] Sidepanel bug? In-Reply-To: <384d3900812201252k6abe2115o12030f7ab9e05791@...627...> References: <384d3900812201252k6abe2115o12030f7ab9e05791@...627...> Message-ID: <200812210620.24129.gambas@...1...> On samedi 20 d?cembre 2008, Jussi Lahtinen wrote: > Hi! > > Is this planned behavior; > Orientation left/right changes just hide buttons placement, NOT > direction where sidepanel opens? > I need sidepanel to right side of screen, now it is not possible. > Problem is noticed on QT at program run state. > > Gambas2.9 at ...2029... 8.10 > > > Jussi > The hide buttons just shrink the side panel. The width is shrinked if a Left or Right orientation is set, and the height if the orientation is Top or Bottom. If you want to it to move, you must put it inside accurate containers (HBox or VBox). Regards, -- Benoit Minisini From gambas at ...1... Sun Dec 21 06:29:45 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 21 Dec 2008 06:29:45 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type In-Reply-To: <1229256335.26984.1.camel@...37...> References: <1229256335.26984.1.camel@...37...> Message-ID: <200812210629.45480.gambas@...1...> On dimanche 14 d?cembre 2008, Luigi Carlotto wrote: > Gambas2 - versione 2.9.0 > > The single anomaly verification in a circumstance, that I will try to > describe: > > - I have created a small static class that executes the logon to a > database, executes query and returns the data in a structure much > similar one to the logic applied to the Result/Field objects; at last > the logon comes sluice. This my logic is created in order to avoid to > leave the logon open and, since the Result object maintains the data > single to opened logon, my class copy these data in an appropriate > structure of Array of objects, that it comes returned to the procedures > that use this function. > - the calling procedures use this class, that the structure returns > given, that comes used for determined scopes. > - the logons can be made on database PostgreSQL, MySQL and SQLite; the > query they come correctly executed, returning the corrected values, > unless for MySQL. Like described in the first mail, one of the query > executes a loading of information from a table of system of MySQL, used > in order to determine the structure of the database. > - some fields of this table are of type ?longtext? (BLOB). > - Strangely, these fields return a value NULL, although their content is > instead a valid data. > - Verifying the Result object, immediately after the execution of the > query, I have found that the value of this field is truly NULL, and this > excludes an anomaly of my procedures. > - To ulterior I have had confirmation, constructing it a small procedure > of test, in which it executes the same operations made from my program, > and that it uses the same static class; strangely, the query executed > from the test program, it has given back a valid value in the field > ?longtest?. > - The thing has made me to rise a doubt: since my program is rather > complex, he is probable exists some problem in memory (stack) with the > management of fields BLOB? > - Knowing enough language C/C++, I have given to a glance to the code > source of the library, but the only thing that I have found is that > fields BLOB come managed in way detail, but has not found details > conditions that could make me to doubt on they a wrong management. The > only thing that has come to me in mind, is perhaps that a problem of > memory with programs exists many complexes, for which this type of data > (blob) comes lost? > - I have found this single anomaly in MySQL, but it is also true that > the others dbms do not use this type of data (blob) in the system > tables. > > Some suggestion? > > Thanks Can you send me a little mysql database that implies some data in the ROUTINES table of information_schema? -- Benoit Minisini From md9327 at ...120... Sun Dec 21 17:09:43 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sun, 21 Dec 2008 17:09:43 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type In-Reply-To: <1229256335.26984.1.camel@...37...> References: <1229256335.26984.1.camel@...37...> Message-ID: <1229875783.5199.10.camel@...37...> In reality, in my application, use the logons only for operations of reading of the information of the structure of the database, since the application is a program for the design of database (es. ErWIN, Oracle Designer, etc). The query they come executed on the system tables, like in the following example: DIM sql AS String = "" sql &= "SELECT specific_name" sql &= " , routine_catalog" sql &= " , routine_schema" sql &= " , routine_name" sql &= " , routine_type" sql &= " , dtd_identifier" sql &= " , routine_body" sql &= " , routine_definition" sql &= " , external_name" sql &= " , external_language" sql &= " , parameter_style" sql &= " , is_deterministic" sql &= " , sql_data_access" sql &= " , sql_path" sql &= " , security_type" sql &= " , created" sql &= " , last_altered" sql &= " , sql_mode" sql &= " , routine_comment" sql &= " , definer" sql &= " FROM information_schema.routines" sql &= " WHERE routine_name = '" & name & "'" sql &= " AND routine_schema = '" & schema & "'" The table ?information_schema.routines? ago part of the tables of system of MySQL, and the field ?routine_definition? is a type field ?longtext?. In the query other fields of the same type are present also, and also these are been involved in the problem. For this reason I cannot supply given, because these come managed directly from MySQL, and depend from the situation current present in the database, and initially the table in issue single filler relative information to the objects of the database as soon as created. From md9327 at ...120... Sun Dec 21 17:16:05 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sun, 21 Dec 2008 17:16:05 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229256516.26984.4.camel@...37...> References: <1229256516.26984.4.camel@...37...> Message-ID: <1229876165.5199.17.camel@...37...> Come tu affermi, un problema di conversione pu? essere sicuramente causato da un carattere non convertibile; per?, nelle ultime mail, avevo specificato che le stringhe usate nei miei test, avevano tutti caratteri in ASCII puro (<127). E' possibile che alcuni caratteri di controllo (es. Line Feed), possano causare qualche problema? Ho fatto alcune prove nella Console, ma non ho riscontrato problemi con questo tipo di caratteri. As you assert, a conversion problem can be sure caused from a not convertibile character; but, in the last mails, I had specified that the strings used in my tests, had all characters in pure ASCII (<127). It is possible that some characters of control (es. Line Feed), can cause some problem? I have made some tests in the Gambas2 Console, but I have not found problems with this type of characters. From gambas at ...1... Sun Dec 21 17:15:09 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 21 Dec 2008 17:15:09 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type In-Reply-To: <1229875783.5199.10.camel@...37...> References: <1229256335.26984.1.camel@...37...> <1229875783.5199.10.camel@...37...> Message-ID: <200812211715.09551.gambas@...1...> On dimanche 21 d?cembre 2008, Luigi Carlotto wrote: > In reality, in my application, use the logons only for operations of > reading of the information of the structure of the database, since the > application is a program for the design of database (es. ErWIN, Oracle > Designer, etc). > > The query they come executed on the system tables, like in the following > example: > > DIM sql AS String = "" > sql &= "SELECT specific_name" > sql &= " , routine_catalog" > sql &= " , routine_schema" > sql &= " , routine_name" > sql &= " , routine_type" > sql &= " , dtd_identifier" > sql &= " , routine_body" > sql &= " , routine_definition" > sql &= " , external_name" > sql &= " , external_language" > sql &= " , parameter_style" > sql &= " , is_deterministic" > sql &= " , sql_data_access" > sql &= " , sql_path" > sql &= " , security_type" > sql &= " , created" > sql &= " , last_altered" > sql &= " , sql_mode" > sql &= " , routine_comment" > sql &= " , definer" > sql &= " FROM information_schema.routines" > sql &= " WHERE routine_name = '" & name & "'" > sql &= " AND routine_schema = '" & schema & "'" > > The table ?information_schema.routines? ago part of the tables of system > of MySQL, and the field ?routine_definition? is a type field ?longtext?. > In the query other fields of the same type are present also, and also > these are been involved in the problem. > For this reason I cannot supply given, because these come managed > directly from MySQL, and depend from the situation current present in > the database, and initially the table in issue single filler relative > information to the objects of the database as soon as created. > --------------------------------------------------------------------------- Knowing that some fields work and other don't is not really helpful. Just send me a SQL dump of the database, without the data: the information_schema table will then be recreated automatically and filled with the same information. Logically... Regards, -- Benoit Minisini From gambas at ...1... Sun Dec 21 17:29:17 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 21 Dec 2008 17:29:17 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229876165.5199.17.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> Message-ID: <200812211729.17713.gambas@...1...> On dimanche 21 d?cembre 2008, Luigi Carlotto wrote: > Come tu affermi, un problema di conversione pu? essere sicuramente > causato da un carattere non convertibile; per?, nelle ultime mail, avevo > specificato che le stringhe usate nei miei test, avevano tutti caratteri > in ASCII puro (<127). > E' possibile che alcuni caratteri di controllo (es. Line Feed), possano > causare qualche problema? > Ho fatto alcune prove nella Console, ma non ho riscontrato problemi con > questo tipo di caratteri. > > As you assert, a conversion problem can be sure caused from a not > convertibile character; but, in the last mails, I had specified that the > strings used in my tests, had all characters in pure ASCII (<127). > It is possible that some characters of control (es. Line Feed), can > cause some problem? > I have made some tests in the Gambas2 Console, but I have not found > problems with this type of characters. If you are sure that your strings are ASCII, why doing Conv(TheString, "UTF-8", "ASCII")? And the error message printed by the underlying iconv library is clear: your string is not ASCII. According to you, The toString() methods always returns an accurate string. According to the source code, Conv() receives a non-ascii string. Can you check that, by splitting your code? FOR EACH oItem IN oGroup.Items sType = oItem.toString() sType = Conv(sType, "UTF-8", "ASCII") oXml.Attribute(oItem.Name, sType) NEXT As for the crash with attributes values larger than 2000 characters, I will look later. But maybe you could send me a little project that shows the bug in that specific case? It will help a lot. Regards, -- Benoit Minisini From gambas at ...1... Sun Dec 21 17:35:45 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 21 Dec 2008 17:35:45 +0100 Subject: [Gambas-user] Better way to delete element from array when enumerating In-Reply-To: <384d3900812171521i47b12bc1s14aa91da71d646c1@...627...> References: <384d3900812171521i47b12bc1s14aa91da71d646c1@...627...> Message-ID: <200812211735.45871.gambas@...1...> On jeudi 18 d?cembre 2008, Jussi Lahtinen wrote: > Hi! > > I have code like this: > > Dim element as ClassX > > FOR EACH element IN objectarray > IF element = something THEN > objectarray.Remove(objectarray.Find(element)) > ENDIF > NEXT > > This works, but I'm almost sure that there is better way to do this. > Feel kind of dumb to find same element two times... > > > Jussi > DO iInd = objectarray.Find(element) IF iInd < 0 THEN BREAK objectarray.Remove(iInd) LOOP Or: iInd = 0 WHILE iInd < objectarray.Count IF objectarray[iInd] = element THEN objectarray.Remove(iInd) ELSE INC iInd ENDIF WEND -- Benoit Minisini From gambas at ...1938... Sun Dec 21 17:42:37 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Sun, 21 Dec 2008 17:42:37 +0100 Subject: [Gambas-user] read commandline invocation In-Reply-To: <4247f5440812201717v1212d121p255acc0bf5e97169@...627...> References: <4247f5440812201717v1212d121p255acc0bf5e97169@...627...> Message-ID: <200812211742.37194.gambas@...1938...> Am Sonntag, 21. Dezember 2008 02:17:56 schrieb Joshua Higgins: > Probably a stupid question, but I can't figure it out :S > How do I get my Gambas program to read how it was invoked from the command > line? > > Thanks. I think Application.Read is your friend. ;-) Greetz Stevie From almodook at ...2007... Mon Dec 22 09:05:43 2008 From: almodook at ...2007... (moon_walker) Date: Mon, 22 Dec 2008 00:05:43 -0800 (PST) Subject: [Gambas-user] SQLite and INT4 vs. INTEGER In-Reply-To: <21041236.post@...1379...> References: <21041236.post@...1379...> Message-ID: <21124076.post@...1379...> Thank you for your answer. Meantime i realised the autoincrementation for INT4 "manually" in my project. Because i am a novice developer I learned a lot with this trouble at least. :-) br attila moon_walker wrote: > > Hi Benoit, > > i am developing a cross platform application. The linux side is on GAMBAS > and the Win side is on > C#.NET. The common part is the SQLite database. > > There is some foreign relations which are coupled with comboboxes. > So the child table has some foreign key fields joined to parent primary > keys. > > In the parent tables the primary keys are defined as autoincrement. Since > i was unable to use the type gb.serial at all, i defined this keys in > SQLite-datamanager in firefox. I realised that SQLite only allows > autoincrement for primary key INTEGER. However gambas database manager use > INT4 for the foreign key fields in the child table. > This causes inconsistency in .NET since it is impossible to create > relations on type mismatched fields (INT4 vs INTEGER). If i switch all > related fields to INTEGER then GAMBAS is unable to handle tha databounded > combobox. > > I would prefer that instead of INT4, only INTEGER would be used general by > SQLite area. > > thx > br > Attila > > -- View this message in context: http://www.nabble.com/SQLite-and-INT4-vs.-INTEGER-tp21041236p21124076.html Sent from the gambas-user mailing list archive at Nabble.com. From m0e.lnx at ...626... Mon Dec 22 14:48:49 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Mon, 22 Dec 2008 07:48:49 -0600 Subject: [Gambas-user] Sidepanel bug? In-Reply-To: <200812210620.24129.gambas@...1...> References: <384d3900812201252k6abe2115o12030f7ab9e05791@...627...> <200812210620.24129.gambas@...1...> Message-ID: <1f1e8c1b0812220548w7f600526ue3006be0b3fba89a@...627...> I did report a bug with this object in gb.gtk though. the first time you try to shrink it, it does shink, but you can't restore it again you have to manually drag it and resize it back to it's normal size. Shrinking and expanding work fine after the that. On Sat, Dec 20, 2008 at 11:20 PM, Benoit Minisini wrote: > On samedi 20 d?cembre 2008, Jussi Lahtinen wrote: >> Hi! >> >> Is this planned behavior; >> Orientation left/right changes just hide buttons placement, NOT >> direction where sidepanel opens? >> I need sidepanel to right side of screen, now it is not possible. >> Problem is noticed on QT at program run state. >> >> Gambas2.9 at ...2029... 8.10 >> >> >> Jussi >> > > The hide buttons just shrink the side panel. The width is shrinked if a Left > or Right orientation is set, and the height if the orientation is Top or > Bottom. > > If you want to it to move, you must put it inside accurate containers (HBox or > VBox). > > Regards, > > -- > Benoit Minisini > > ------------------------------------------------------------------------------ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From m0e.lnx at ...626... Mon Dec 22 14:55:20 2008 From: m0e.lnx at ...626... (M0E Lnx) Date: Mon, 22 Dec 2008 13:55:20 +0000 Subject: [Gambas-user] sidepanel object + gb.gtk bug In-Reply-To: <200812210618.05724.gambas@...1...> References: <1f1e8c1b0812170749x24bfa7cm36197c3e751c3aa9@...627...> <200812210618.05724.gambas@...1...> Message-ID: <1f1e8c1b0812220555y5ca12d6ua1335b19251beb9@...627...> See attachment On Sat, Dec 20, 2008 at 11:18 PM, Benoit Minisini wrote: > On mercredi 17 d?cembre 2008, M0E Lnx wrote: >> I develop a couple of application in gambas2-2.9.0, both of which have >> a sidepanel object. Both use gb.gtk. >> I've found something that I believe is a bug. Does not happen when I >> use the gb.qt component >> >> When I click the little "<" on the side panel (to hide it) it goes >> well, but when I click it again to restore it, it will not restore it. >> The little arrow will only turn the other way, but the panel is still >> hidden. >> >> I can drag it and resize it back to normal size, and hiding/restoring >> after that works flawlessly... but the first time it gets stuck. >> > > I cannot reproduce the problem: can you send me a little project that has the > bug? > > -- > Benoit Minisini > > ------------------------------------------------------------------------------ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -------------- next part -------------- A non-text attachment was scrubbed... Name: sidepanelbug-0.0.1.tar.gz Type: application/x-gzip Size: 7658 bytes Desc: not available URL: From doriano.blengino at ...1909... Mon Dec 22 17:31:03 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Mon, 22 Dec 2008 17:31:03 +0100 Subject: [Gambas-user] read commandline invocation In-Reply-To: <200812211742.37194.gambas@...1938...> References: <4247f5440812201717v1212d121p255acc0bf5e97169@...627...> <200812211742.37194.gambas@...1938...> Message-ID: <494FC0C7.7040703@...1909...> gambas at ...1938... ha scritto: > Am Sonntag, 21. Dezember 2008 02:17:56 schrieb Joshua Higgins: > >> Probably a stupid question, but I can't figure it out :S >> How do I get my Gambas program to read how it was invoked from the command >> line? >> >> Thanks. >> > I think Application.Read is your friend. ;-) > Application.Args[index] is what you are looking for... "print application.args[0]" will print the command name (/usr/bin/test.gambas for example). Regards, Doriano From md9327 at ...120... Mon Dec 22 20:13:16 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Mon, 22 Dec 2008 20:13:16 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type In-Reply-To: <1229875783.5199.10.camel@...37...> References: <1229256335.26984.1.camel@...37...> <1229875783.5199.10.camel@...37...> Message-ID: <1229973196.5199.23.camel@...37...> It pardons me, but the table in object is not part of mine database, but of the same motor of MySQL. The fact that is complete with the data, or without data, is not the true problem. My function reads the content of this table in order to determine the structure of a database, and not the data. The data contained in this table, come inserted automatically from the motor of MySQL, when they come created objects in the database. In the normal situation, the table contains the information approximately the structure of the objects that MySQL creates of default, when it comes created database any. The table ?routines? is of property of the ?information_schema? schema, that it is of property of MySQL, and on which writing operations cannot be made, but only of reading. The same library of Gambas2, uses this table for populate the objects ?Table?, ?Field?, etc To this point, it still pardons me, I I do not believe that to send the dump of this table he is of great usefullness since, if an installation of MySQL is had, it is possible to verify the problem directly. As creed of to have written, the problem does not seem that or caused from the reading of the field, but its maintenance in memory, if managed from a complex application? This, obviously, is only a hypothesis? Thanks to you for the patience! From gambas at ...1... Mon Dec 22 20:21:57 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 22 Dec 2008 20:21:57 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type In-Reply-To: <1229973196.5199.23.camel@...37...> References: <1229256335.26984.1.camel@...37...> <1229875783.5199.10.camel@...37...> <1229973196.5199.23.camel@...37...> Message-ID: <200812222021.57593.gambas@...1...> On lundi 22 d?cembre 2008, Luigi Carlotto wrote: > It pardons me, but the table in object is not part of mine database, but > of the same motor of MySQL. > The fact that is complete with the data, or without data, is not the > true problem. > My function reads the content of this table in order to determine the > structure of a database, and not the data. > The data contained in this table, come inserted automatically from the > motor of MySQL, when they come created objects in the database. > > In the normal situation, the table contains the information > approximately the structure of the objects that MySQL creates of > default, when it comes created database any. > The table ?routines? is of property of the ?information_schema? schema, > that it is of property of MySQL, and on which writing operations cannot > be made, but only of reading. > The same library of Gambas2, uses this table for populate the objects > ?Table?, ?Field?, etc > > To this point, it still pardons me, I I do not believe that to send the > dump of this table he is of great usefullness since, if an installation > of MySQL is had, it is possible to verify the problem directly. > As creed of to have written, the problem does not seem that or caused > from the reading of the field, but its maintenance in memory, if managed > from a complex application? This, obviously, is only a hypothesis? > > Thanks to you for the patience! > --------------------------------------------------------------------------- Be logical: information_table is void by default, and is filled according to the data and metadata of the database contents. If you send me the database contents, I will be able to recreate the information_table contents that Gambas cannot read. And then I may fix the bug. If you don't send me the data, I cannot do anything. I have nothing to test. Regards, -- Benoit Minisini From md9327 at ...120... Mon Dec 22 20:38:45 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Mon, 22 Dec 2008 20:38:45 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229876165.5199.17.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> Message-ID: <1229974725.5199.29.camel@...37...> > If you are sure that your strings are ASCII, why doing > Conv(TheString, "UTF-8", "ASCII")? Yes! > And the error message printed by the underlying iconv library is clear: your > string is not ASCII. No (see result)! > According to you, The toString() methods always returns an accurate string. Yes! > According to the source code, Conv() receives a non-ascii string. No! > Can you check that, by splitting your code? > FOR EACH oItem IN oGroup.Items > sType = oItem.toString() > sType = Conv(sType, "UTF-8", "ASCII") > oXml.Attribute(oItem.Name, sType) > NEXT Result: ... 150 FOR EACH oItem IN oGroup.Items 151 sType = oItem.toString() 152 PRINT sType 153 sType = Conv(sType, "UTF-8", "ASCII") 154 oXml.Attribute(oItem.Name, sType) 155 NEXT ... sType="ACTION,ADD,ALL,ALTER,ANALYZE,AND,AS,ASC,ASENSITIVE,BEFORE,BETWEEN,BIGINT,BINARY,BIT,BLOB,BOTH,BY,CALL,CASCADE,CASE,CHANGE,CHAR,CHARACTER,CHECK,COLLATE,COLUMN,CONDITION,CONNECTION,CONSTRAINT,CONTINUE,CONVERT,CREATE,CROSS,CURRENT_DATE,CURRENT_TIME,CURRENT_TIMESTAMP,CURRENT_USER,CURSOR,CURSOR DATABASE,DATABASES,DATE,DAY_HOUR,DAY_MICROSECOND,DAY_MINUTE,DAY_SECOND,DEC,DECIMAL,DECLARE,DEFAULT,DELAYED,DELETE,DESC,DESCRIBE,DETERMINISTIC,DISTINCT,DISTINCTROW,DIV,DOUBLE,DROP,DUAL,EACH,ELSE,ELSEIF,ENCLOSED,ENUM,ESCAPED,EXISTS,EXIT,EXPLAIN,FALSE,FETCH,FLOAT,FLOAT4,FLOAT8,FOR,FORCE,FOREIGN,FROM,FULLTEXT,GOTO,GRANT,GROUP,HAVING,HIGH_PRIORITY,HOUR_MICROSECOND,HOUR_MINUTE,HOUR_SECOND,IF,IGNORE,IN,INDEX,INFILE,INNER,INOUT,INSENSITIVE,INSERT,INT,INT1,INT2,INT3,INT4,INT8,INTEGER,INTERVAL,INTO,IS,ITERATE,JOIN,KEY,KEYS,KILL,LABEL,LEADING,LEAVE,LEFT,LIKE,LIMIT,LINES,LOAD,LOCALTIME,LOCALTIMESTAMP,LOCK,LONG,LONGBLOB,LONGTEXT,LOOP,LOW_PRIORITY,MATCH,MEDIUMBLOB,MEDIUMINT,MEDIUMTEXT,MIDDLEINT,MINUTE_MICROSECOND,MINUTE_SECOND,MOD,MODIFIES,NATURALNOT,NO,NO_WRITE_TO_BINLOG,NULL NUMERIC,ON,OPTIMIZE,OPTION,OPTIONALLY,OR,ORDER,OUT,OUTER,OUTFILE,PRECISION,PRIMARY,PROCEDURE,PURGE,READ,READS,REAL,REFERENCES,REGEXP,RELEASE,RENAME,REPEAT,REPLACE,REQUIRE,RESTRICT,RETURN,REVOKE,RIGHT,RLIKE,SCHEMA,SCHEMAS,SECOND_MICROSECOND,SELECT,SENSITIVE,SEPARATOR,SET,SHOW,SMALLINT,SONAME,SPATIAL,SPECIFIC,SQL,SQLEXCEPTION,SQLSTATE,SQLWARNING,SQL_BIG_RESULT,SQL_CALC_FOUND_ROWS,SQL_SMALL_RESULT,SSL STARTING,STRAIGHT_JOIN,TABLE TERMINATED,TEXT,THEN,TIME,TIMESTAMP,TINYBLOB,TINYINT,TINYTEXT,TO,TRAILING,TRIGGER,TRUE,UNDO,UNION,UNIQUE,UNLOCK,UNSIGNED,UPDATE,UPGRADE,USAGE,USE,USING,UTC_DATE,UTC_TIME,UTC_TIMESTAMP,VALUES,VARBINARY,VARCHAR,VARCHARACTER,VARYING,WHEN,WHERE,WHILE,WITH,WRITE,XOR,YEAR_MONTH,ZEROFILL" Error: Error writing XML data Code: -1 Class: pgConfig Where: pgConfig.Save.154 As you can see, the error not verification in the conversion, but in the writing on XML, and the string ?sType? (too long...) contains alone characters ASCII. > As for the crash with attributes values larger than 2000 characters, I will > look later. But maybe you could send me a little project that shows the bug > in that specific case? It will help a lot. Ok! (see result). Thanks From gambas at ...1... Mon Dec 22 20:47:34 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 22 Dec 2008 20:47:34 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229974725.5199.29.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> <1229974725.5199.29.camel@...37...> Message-ID: <200812222047.34089.gambas@...1...> On lundi 22 d?cembre 2008, Luigi Carlotto wrote: > > If you are sure that your strings are ASCII, why doing > > Conv(TheString, "UTF-8", "ASCII")? > > Yes! The question was "why?" > > > And the error message printed by the underlying iconv library is > > clear: your > > > string is not ASCII. > > No (see result)! > > > According to you, The toString() methods always returns an accurate > > string. > Yes! > > > According to the source code, Conv() receives a non-ascii string. > > No! > > > Can you check that, by splitting your code? > > > > FOR EACH oItem IN oGroup.Items > > sType = oItem.toString() > > sType = Conv(sType, "UTF-8", "ASCII") > > oXml.Attribute(oItem.Name, sType) > > NEXT > > Result: > > ... > 150 FOR EACH oItem IN oGroup.Items > 151 sType = oItem.toString() > 152 PRINT sType > 153 sType = Conv(sType, "UTF-8", "ASCII") > 154 oXml.Attribute(oItem.Name, sType) > 155 NEXT > ... > > sType="ACTION,ADD,ALL,ALTER,ANALYZE,AND,AS,ASC,ASENSITIVE,BEFORE,BETWEEN,BI >GINT,BINARY,BIT,BLOB,BOTH,BY,CALL,CASCADE,CASE,CHANGE,CHAR,CHARACTER,CHECK,C >OLLATE,COLUMN,CONDITION,CONNECTION,CONSTRAINT,CONTINUE,CONVERT,CREATE,CROSS, >CURRENT_DATE,CURRENT_TIME,CURRENT_TIMESTAMP,CURRENT_USER,CURSOR,CURSOR > DATABASE,DATABASES,DATE,DAY_HOUR,DAY_MICROSECOND,DAY_MINUTE,DAY_SECOND,DEC, >DECIMAL,DECLARE,DEFAULT,DELAYED,DELETE,DESC,DESCRIBE,DETERMINISTIC,DISTINCT, >DISTINCTROW,DIV,DOUBLE,DROP,DUAL,EACH,ELSE,ELSEIF,ENCLOSED,ENUM,ESCAPED,EXIS >TS,EXIT,EXPLAIN,FALSE,FETCH,FLOAT,FLOAT4,FLOAT8,FOR,FORCE,FOREIGN,FROM,FULLT >EXT,GOTO,GRANT,GROUP,HAVING,HIGH_PRIORITY,HOUR_MICROSECOND,HOUR_MINUTE,HOUR_ >SECOND,IF,IGNORE,IN,INDEX,INFILE,INNER,INOUT,INSENSITIVE,INSERT,INT,INT1,INT >2,INT3,INT4,INT8,INTEGER,INTERVAL,INTO,IS,ITERATE,JOIN,KEY,KEYS,KILL,LABEL,L >EADING,LEAVE,LEFT,LIKE,LIMIT,LINES,LOAD,LOCALTIME,LOCALTIMESTAMP,LOCK,LONG,L >ONGBLOB,LONGTEXT,LOOP,LOW_PRIORITY,MATCH,MEDIUMBLOB,MEDIUMINT,MEDIUMTEXT,MID >DLEINT,MINUTE_MICROSECOND,MINUTE_SECOND,MOD,MODIFIES,NATURALNOT,NO,NO_WRITE_ >TO_BINLOG,NULL > NUMERIC,ON,OPTIMIZE,OPTION,OPTIONALLY,OR,ORDER,OUT,OUTER,OUTFILE,PRECISION, >PRIMARY,PROCEDURE,PURGE,READ,READS,REAL,REFERENCES,REGEXP,RELEASE,RENAME,REP >EAT,REPLACE,REQUIRE,RESTRICT,RETURN,REVOKE,RIGHT,RLIKE,SCHEMA,SCHEMAS,SECOND >_MICROSECOND,SELECT,SENSITIVE,SEPARATOR,SET,SHOW,SMALLINT,SONAME,SPATIAL,SPE >CIFIC,SQL,SQLEXCEPTION,SQLSTATE,SQLWARNING,SQL_BIG_RESULT,SQL_CALC_FOUND_ROW >S,SQL_SMALL_RESULT,SSL STARTING,STRAIGHT_JOIN,TABLE > TERMINATED,TEXT,THEN,TIME,TIMESTAMP,TINYBLOB,TINYINT,TINYTEXT,TO,TRAILING,T >RIGGER,TRUE,UNDO,UNION,UNIQUE,UNLOCK,UNSIGNED,UPDATE,UPGRADE,USAGE,USE,USING >,UTC_DATE,UTC_TIME,UTC_TIMESTAMP,VALUES,VARBINARY,VARCHAR,VARCHARACTER,VARYI >NG,WHEN,WHERE,WHILE,WITH,WRITE,XOR,YEAR_MONTH,ZEROFILL" Error: Error writing > XML data > Code: -1 > Class: pgConfig > Where: pgConfig.Save.154 > > As you can see, the error not verification in the conversion, but in the > writing on XML, and the string ?sType? (too long...) contains alone > characters ASCII. > Why don't you have the same error as in your first post? Does the sType string have newlines inside? -- Benoit Minisini From md9327 at ...120... Mon Dec 22 20:51:35 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Mon, 22 Dec 2008 20:51:35 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type In-Reply-To: <1229973196.5199.23.camel@...37...> References: <1229256335.26984.1.camel@...37...> <1229875783.5199.10.camel@...37...> <1229973196.5199.23.camel@...37...> Message-ID: <1229975495.5199.32.camel@...37...> Il giorno lun, 22/12/2008 alle 20.13 +0100, Luigi Carlotto ha scritto: > It pardons me, but the table in object is not part of mine database, > but of the same motor of MySQL. > The fact that is complete with the data, or without data, is not the > true problem. > My function reads the content of this table in order to determine the > structure of a database, and not the data. > The data contained in this table, come inserted automatically from the > motor of MySQL, when they come created objects in the database. > > In the normal situation, the table contains the information > approximately the structure of the objects that MySQL creates of > default, when it comes created database any. > The table ?routines? is of property of the ?information_schema? > schema, that it is of property of MySQL, and on which writing > operations cannot be made, but only of reading. > The same library of Gambas2, uses this table for populate the objects > ?Table?, ?Field?, etc > > To this point, it still pardons me, I I do not believe that to send > the dump of this table he is of great usefullness since, if an > installation of MySQL is had, it is possible to verify the problem > directly. > As creed of to have written, the problem does not seem that or caused > from the reading of the field, but its maintenance in memory, if > managed from a complex application? This, obviously, is only a > hypothesis? > > Thanks to you for the patience! In attached the dump of the database of test. A table is present only... Thanks -------------- next part -------------- A non-text attachment was scrubbed... Name: mydump.sql Type: text/x-vhdl Size: 2011 bytes Desc: not available URL: From gambas at ...1... Mon Dec 22 20:56:23 2008 From: gambas at ...1... (Benoit Minisini) Date: Mon, 22 Dec 2008 20:56:23 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type In-Reply-To: <1229975495.5199.32.camel@...37...> References: <1229256335.26984.1.camel@...37...> <1229973196.5199.23.camel@...37...> <1229975495.5199.32.camel@...37...> Message-ID: <200812222056.23287.gambas@...1...> On lundi 22 d?cembre 2008, Luigi Carlotto wrote: > Il giorno lun, 22/12/2008 alle 20.13 +0100, Luigi Carlotto ha scritto: > > It pardons me, but the table in object is not part of mine database, > > but of the same motor of MySQL. > > The fact that is complete with the data, or without data, is not the > > true problem. > > My function reads the content of this table in order to determine the > > structure of a database, and not the data. > > The data contained in this table, come inserted automatically from the > > motor of MySQL, when they come created objects in the database. > > > > In the normal situation, the table contains the information > > approximately the structure of the objects that MySQL creates of > > default, when it comes created database any. > > The table ?routines? is of property of the ?information_schema? > > schema, that it is of property of MySQL, and on which writing > > operations cannot be made, but only of reading. > > The same library of Gambas2, uses this table for populate the objects > > ?Table?, ?Field?, etc > > > > To this point, it still pardons me, I I do not believe that to send > > the dump of this table he is of great usefullness since, if an > > installation of MySQL is had, it is possible to verify the problem > > directly. > > As creed of to have written, the problem does not seem that or caused > > from the reading of the field, but its maintenance in memory, if > > managed from a complex application? This, obviously, is only a > > hypothesis? > > > > Thanks to you for the patience! > > In attached the dump of the database of test. > A table is present only... > > Thanks There is nothing that fills the ROUTINE table, so I think something is missing in the dump file. I guess that the ROUTINE table is indirectly filled by MySQL user-defined database functions, isn't it? -- Benoit Minisini From md9327 at ...120... Mon Dec 22 21:27:17 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Mon, 22 Dec 2008 21:27:17 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229974725.5199.29.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> <1229974725.5199.29.camel@...37...> Message-ID: <1229977637.5199.33.camel@...37...> Il giorno lun, 22/12/2008 alle 20.38 +0100, Luigi Carlotto ha scritto: > > If you are sure that your strings are ASCII, why doing > > Conv(TheString, "UTF-8", "ASCII")? > Yes! > > > And the error message printed by the underlying iconv library is > clear: your > > string is not ASCII. > No (see result)! > > > According to you, The toString() methods always returns an accurate > string. > Yes! > > > According to the source code, Conv() receives a non-ascii string. > No! > > > Can you check that, by splitting your code? > > > FOR EACH oItem IN oGroup.Items > > sType = oItem.toString() > > sType = Conv(sType, "UTF-8", "ASCII") > > oXml.Attribute(oItem.Name, sType) > > NEXT > > Result: > > ... > 150 FOR EACH oItem IN oGroup.Items > 151 sType = oItem.toString() > 152 PRINT sType > 153 sType = Conv(sType, "UTF-8", "ASCII") > 154 oXml.Attribute(oItem.Name, sType) > 155 NEXT > ... > > sType="ACTION,ADD,ALL,ALTER,ANALYZE,AND,AS,ASC,ASENSITIVE,BEFORE,BETWEEN,BIGINT,BINARY,BIT,BLOB,BOTH,BY,CALL,CASCADE,CASE,CHANGE,CHAR,CHARACTER,CHECK,COLLATE,COLUMN,CONDITION,CONNECTION,CONSTRAINT,CONTINUE,CONVERT,CREATE,CROSS,CURRENT_DATE,CURRENT_TIME,CURRENT_TIMESTAMP,CURRENT_USER,CURSOR,CURSOR DATABASE,DATABASES,DATE,DAY_HOUR,DAY_MICROSECOND,DAY_MINUTE,DAY_SECOND,DEC,DECIMAL,DECLARE,DEFAULT,DELAYED,DELETE,DESC,DESCRIBE,DETERMINISTIC,DISTINCT,DISTINCTROW,DIV,DOUBLE,DROP,DUAL,EACH,ELSE,ELSEIF,ENCLOSED,ENUM,ESCAPED,EXISTS,EXIT,EXPLAIN,FALSE,FETCH,FLOAT,FLOAT4,FLOAT8,FOR,FORCE,FOREIGN,FROM,FULLTEXT,GOTO,GRANT,GROUP,HAVING,HIGH_PRIORITY,HOUR_MICROSECOND,HOUR_MINUTE,HOUR_SECOND,IF,IGNORE,IN,INDEX,INFILE,INNER,INOUT,INSENSITIVE,INSERT,INT,INT1,INT2,INT3,INT4,INT8,INTEGER,INTERVAL,INTO,IS,ITERATE,JOIN,KEY,KEYS,KILL,LABEL,LEADING,LEAVE,LEFT,LIKE,LIMIT,LINES,LOAD,LOCALTIME,LOCALTIMESTAMP,LOCK,LONG,LONGBLOB,LONGTEXT,LOOP,LOW_PRIORITY,MATCH,MEDIUMBLOB,MEDIUMINT,MEDIUMTEXT,MIDDLEINT,MINUTE_MICROSECOND,MINUTE_SECOND,MOD,MODIFIES,NATURALNOT,NO,NO_WRITE_TO_BINLOG,NULL NUMERIC,ON,OPTIMIZE,OPTION,OPTIONALLY,OR,ORDER,OUT,OUTER,OUTFILE,PRECISION,PRIMARY,PROCEDURE,PURGE,READ,READS,REAL,REFERENCES,REGEXP,RELEASE,RENAME,REPEAT,REPLACE,REQUIRE,RESTRICT,RETURN,REVOKE,RIGHT,RLIKE,SCHEMA,SCHEMAS,SECOND_MICROSECOND,SELECT,SENSITIVE,SEPARATOR,SET,SHOW,SMALLINT,SONAME,SPATIAL,SPECIFIC,SQL,SQLEXCEPTION,SQLSTATE,SQLWARNING,SQL_BIG_RESULT,SQL_CALC_FOUND_ROWS,SQL_SMALL_RESULT,SSL STARTING,STRAIGHT_JOIN,TABLE TERMINATED,TEXT,THEN,TIME,TIMESTAMP,TINYBLOB,TINYINT,TINYTEXT,TO,TRAILING,TRIGGER,TRUE,UNDO,UNION,UNIQUE,UNLOCK,UNSIGNED,UPDATE,UPGRADE,USAGE,USE,USING,UTC_DATE,UTC_TIME,UTC_TIMESTAMP,VALUES,VARBINARY,VARCHAR,VARCHARACTER,VARYING,WHEN,WHERE,WHILE,WITH,WRITE,XOR,YEAR_MONTH,ZEROFILL" > Error: Error writing XML data > Code: -1 > Class: pgConfig > Where: pgConfig.Save.154 > > As you can see, the error not verification in the conversion, but in > the writing on XML, and the string ?sType? (too long...) contains > alone characters ASCII. > > > As for the crash with attributes values larger than 2000 characters, > I will > > look later. But maybe you could send me a little project that shows > the bug > > in that specific case? It will help a lot. > Ok! (see result). > > Thanks I have forgotten to add the rest of the error message, but it is identical to the first one post. encoding error: output conversion failed two to conv error, bytes 0xE5 0x31 0x32 0xE5 I/O error: encoder error Error: Given Error writing XML Tails: -1 The string does not contain characters of control (es. LineFeed). From joshiggins at ...1601... Mon Dec 22 21:34:26 2008 From: joshiggins at ...1601... (Joshua Higgins) Date: Mon, 22 Dec 2008 20:34:26 +0000 Subject: [Gambas-user] read commandline invocation In-Reply-To: <494FC0C7.7040703@...1909...> References: <4247f5440812201717v1212d121p255acc0bf5e97169@...627...> <200812211742.37194.gambas@...1938...> <494FC0C7.7040703@...1909...> Message-ID: <4247f5440812221234ne8b5d11ja0cf871e4b55424b@...627...> Thanks :-) 2008/12/22 Doriano Blengino > gambas at ...1938... ha scritto: > > Am Sonntag, 21. Dezember 2008 02:17:56 schrieb Joshua Higgins: > > > >> Probably a stupid question, but I can't figure it out :S > >> How do I get my Gambas program to read how it was invoked from the > command > >> line? > >> > >> Thanks. > >> > > I think Application.Read is your friend. ;-) > > > Application.Args[index] is what you are looking for... "print > application.args[0]" will print the command name (/usr/bin/test.gambas > for example). > > Regards, > Doriano > > > ------------------------------------------------------------------------------ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- joshua higgins >>>>>>------ From md9327 at ...120... Mon Dec 22 21:41:14 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Mon, 22 Dec 2008 21:41:14 +0100 Subject: [Gambas-user] Problem with MySQL LONGTEXT field type In-Reply-To: <1229975495.5199.32.camel@...37...> References: <1229256335.26984.1.camel@...37...> <1229875783.5199.10.camel@...37...> <1229973196.5199.23.camel@...37...> <1229975495.5199.32.camel@...37...> Message-ID: <1229978474.5199.35.camel@...37...> Il giorno lun, 22/12/2008 alle 20.51 +0100, Luigi Carlotto ha scritto: > Il giorno lun, 22/12/2008 alle 20.13 +0100, Luigi Carlotto ha scritto: > > > It pardons me, but the table in object is not part of mine database, > > but of the same motor of MySQL. > > The fact that is complete with the data, or without data, is not the > > true problem. > > My function reads the content of this table in order to determine > > the structure of a database, and not the data. > > The data contained in this table, come inserted automatically from > > the motor of MySQL, when they come created objects in the database. > > > > In the normal situation, the table contains the information > > approximately the structure of the objects that MySQL creates of > > default, when it comes created database any. > > The table ?routines? is of property of the ?information_schema? > > schema, that it is of property of MySQL, and on which writing > > operations cannot be made, but only of reading. > > The same library of Gambas2, uses this table for populate the > > objects ?Table?, ?Field?, etc > > > > To this point, it still pardons me, I I do not believe that to send > > the dump of this table he is of great usefullness since, if an > > installation of MySQL is had, it is possible to verify the problem > > directly. > > As creed of to have written, the problem does not seem that or > > caused from the reading of the field, but its maintenance in memory, > > if managed from a complex application? This, obviously, is only a > > hypothesis? > > > > Thanks to you for the patience! > > > In attached the dump of the database of test. > A table is present only... > > Thanks > The dump it contains a single object of the database of test, a table, and only little records. As I have said, my application does not use the content of the table, but it gains its structure from the tables of system of MySQL. My application uses the structure of the database in order to represent in graphical way the layout of the database, the data is not useful to such scope. In order to make this operation, it is connected to the database and, through the system tables, it gains the information of the structure of the database. The application can be connected to the types of database: PostgreSQL, MySQL and SQLite. Various from PostgreSQL, some tables of MySQL use fields of type longtext (blob), for which it is necessary to read these fields, for being able to determine, as an example: name of the field, type, dimensions, COMMENT, etc This happens in the same way with bookcases of Gambas? I believe thus that or, at least from the reading of the code source. Also phpPgAdmin (PHP) executes query on these tables of system, in order to represent the objects contained in the database; same thing in phpMyAdmin. From ronstk at ...239... Tue Dec 23 02:48:44 2008 From: ronstk at ...239... (Ron_1st) Date: Tue, 23 Dec 2008 02:48:44 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229974725.5199.29.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> <1229974725.5199.29.camel@...37...> Message-ID: <200812230248.45141.ronstk@...239...> On Monday 22 December 2008, Luigi Carlotto wrote: > sType="ACTION,ADD,ALL,ALTER,ANALYZE,AND,AS,ASC,ASENSITIVE,BEFORE,BETWEEN,BIGINT,BINARY,BIT,BLOB,BOTH,BY,CALL,CASCADE,CASE,CHANGE,CHAR,CHARACTER,CHECK,COLLATE,COLUMN,CONDITION,CONNECTION,CONSTRAINT,CONTINUE,CONVERT,CREATE,CROSS,CURRENT_DATE,CURRENT_TIME,CURRENT_TIMESTAMP,CURRENT_USER,CURSOR,CURSOR DATABASE,DATABASES,DATE,DAY_HOUR,DAY_MICROSECOND,DAY_MINUTE,DAY_SECOND,DEC,DECIMAL,DECLARE,DEFAULT,DELAYED,DELETE,DESC,DESCRIBE,DETERMINISTIC,DISTINCT,DISTINCTROW,DIV,DOUBLE,DROP,DUAL,EACH,ELSE,ELSEIF,ENCLOSED,ENUM,ESCAPED,EXISTS,EXIT,EXPLAIN,FALSE,FETCH,FLOAT,FLOAT4,FLOAT8,FOR,FORCE,FOREIGN,FROM,FULLTEXT,GOTO,GRANT,GROUP,HAVING,HIGH_PRIORITY,HOUR_MICROSECOND,HOUR_MINUTE,HOUR_SECOND,IF,IGNORE,IN,INDEX,INFILE,INNER,INOUT,INSENSITIVE,INSERT,INT,INT1,INT2,INT3,INT4,INT8,INTEGER,INTERVAL,INTO,IS,ITERATE,JOIN,KEY,KEYS,KILL,LABEL,LEADING,LEAVE,LEFT,LIKE,LIMIT,LINES,LOAD,LOCALTIME,LOCALTIMESTAMP,LOCK,LONG,LONGBLOB,LONGTEXT,LOOP,LOW_PRIORITY,MATCH,MEDIUMBLOB,MEDIUMINT,MEDIUMTEXT,MIDDLEINT,MINUTE_MICROSECOND,MINUTE_SECOND,MOD,MODIFIES,NATURALNOT,NO,NO_WRITE_TO_BINLOG,NULL NUMERIC,ON,OPTIMIZE,OPTION,OPTIONALLY,OR,ORDER,OUT,OUTER,OUTFILE,PRECISION,PRIMARY,PROCEDURE,PURGE,READ,READS,REAL,REFERENCES,REGEXP,RELEASE,RENAME,REPEAT,REPLACE,REQUIRE,RESTRICT,RETURN,REVOKE,RIGHT,RLIKE,SCHEMA,SCHEMAS,SECOND_MICROSECOND,SELECT,SENSITIVE,SEPARATOR,SET,SHOW,SMALLINT,SONAME,SPATIAL,SPECIFIC,SQL,SQLEXCEPTION,SQLSTATE,SQLWARNING,SQL_BIG_RESULT,SQL_CALC_FOUND_ROWS,SQL_SMALL_RESULT,SSL STARTING,STRAIGHT_JOIN,TABLE TERMINATED,TEXT,THEN,TIME,TIMESTAMP,TINYBLOB,TINYINT,TINYTEXT,TO,TRAILING,TRIGGER,TRUE,UNDO,UNION,UNIQUE,UNLOCK,UNSIGNED,UPDATE,UPGRADE,USAGE,USE,USING,UTC_DATE,UTC_TIME,UTC_TIMESTAMP,VALUES,VARBINARY,VARCHAR,VARCHARACTER,VARYING,WHEN,WHERE,WHILE,WITH,WRITE,XOR,YEAR_MONTH,ZEROFILL" > Error: Error writing XML data > Code: -1 > Class: pgConfig > Where: pgConfig.Save.154 > I see something where the wrong characters may be at the end of following lines. First line: ...CURSOR,CURSOR DATABASE, Second line: ...,NO,NO_WRITE_TO_BINLOG,NULL NUMERIC,ON,OPTIMIZE Third line: ...,SQL_SMALL_RESULT,SSL NUMERIC,ON, Forth line: ...STRAIGHT_JOIN,TABLE TERMINATED,TEXT, In fact all items are comma seperated but a few does have a space in them. that is the reason they are spread to several lines. I sayd a _space_ because it looks like that by wrapping on it. It does not make sence to me to use spaces inside the items as the others are a continues string of several word parts, like TINYINT and TIMESTAMP, why should 'TABLETERMINATED' split to 'TABLE TERMINAED' ? I suggest to write a routine to show the ASCII number of all characters in the sType string to see discrepancies in it and look carefull to the space alikes positions. This way I would try to find why it goes wrong. Beside of this problem I think you do something wrong here. (just personal feeling) Beside of that it looks to me strange to have attributes with such long/big-size values. The words in the sType string are data and should be inside elements and not in the element declaration itself as attribute who are telling about those embeded elements and/or the properties about the element itself. is IMHO fault It should be declared as element object, attributes tells something about how to see/handle/interpret information inside the tag and not be the data itself as sType is here. ACTION ADD .... Just to clearout in html you do this
  • Keywords available
but mean
  • ACTION
  • ADD
  • ....
I know this is not the best example, for the TAG input you can have value="ACTION,ADD" but those elements are part of the FORM tag and are/have special(s) usage. I should have used DT and DD (definition) tags instead the list tags. As sayd before it is just a personal feeling, you circumstance can be compleet different. Best regards, Ron_1st -- From doriano.blengino at ...1909... Tue Dec 23 08:24:36 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Tue, 23 Dec 2008 08:24:36 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229977637.5199.33.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> <1229974725.5199.29.camel@...37...> <1229977637.5199.33.camel@...37...> Message-ID: <49509234.5070704@...1909...> Luigi Carlotto ha scritto: > I have forgotten to add the rest of the error message, but it is > identical to the first one post. > > encoding error: output conversion failed two to conv error, bytes 0xE5 > 0x31 0x32 0xE5 I/O error: encoder error > Error: Given Error writing XML > Tails: -1 > > The string does not contain characters of control (es. LineFeed). > > The hexadecimal bytes are clear enough to me: 0x31 is a "1", 0x32 a "2", and 0xE5 is *not* an ascii character but, in Unicode, a lowercase "A" with a small circle above it (don't know how to name it). This could be a date in italian/european format, like 25-12-2008 or 25/12/2008 (Christmas). I have seen that browsers, which can display different character sets, sometimes display a strange character instead of the normal one for the apostrophe. This can happen to dashes or hyphens and, who knows, to other characters too. It remember that was caused by an incorrect implementation of ISO-8859-xx. One quick way to verify this is to change the date, for example to 02-01-2009, and run the test again: if the hex bytes come out like 0xE5 0x30 0x31 0xE5, then this is the problem. Or, using a more scientific test like Benoit suggested, do an hexdump and see if there are strange characters: chars less than 0x20 are not good, and so are those greater than 0x7f. Supposing that this is the problem, I don't know what to say anymore - a bad encoding implementation (mysql or gambas fault) or bad pairing/coupling of encodings (programmer's fault) has to be found somewhere... Cheers, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From doriano.blengino at ...1909... Tue Dec 23 08:48:35 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Tue, 23 Dec 2008 08:48:35 +0100 Subject: [Gambas-user] Best wishes for Christmas and the coming new year In-Reply-To: <1229977637.5199.33.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> <1229974725.5199.29.camel@...37...> <1229977637.5199.33.camel@...37...> Message-ID: <495097D3.6020405@...1909...> I was not firmly sure to send this wishes to the list but, after a few milliseconds of intense thinking, I realized we all are, in some way, a 'community'. So I send this to you all, hoping you to have good holidays and and a wonderful 2009. Best regards to all, Doriano. -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From gambas at ...1938... Tue Dec 23 11:12:01 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Tue, 23 Dec 2008 11:12:01 +0100 Subject: [Gambas-user] read commandline invocation In-Reply-To: <494FC0C7.7040703@...1909...> References: <4247f5440812201717v1212d121p255acc0bf5e97169@...627...> <200812211742.37194.gambas@...1938...> <494FC0C7.7040703@...1909...> Message-ID: <200812231112.01915.gambas@...1938...> Am Montag, 22. Dezember 2008 17:31:03 schrieb Doriano Blengino: > gambas at ...1938... ha scritto: > > I think Application.Read is your friend. ;-) > > Application.Args[index] is what you are looking for... "print > application.args[0]" will print the command name (/usr/bin/test.gambas > for example). > > Regards, > Doriano Sorry... for my wrong answer! Did in hurry! :-( Greetz Stevie From gambas at ...1938... Wed Dec 24 11:16:51 2008 From: gambas at ...1938... (gambas at ...1938...) Date: Wed, 24 Dec 2008 11:16:51 +0100 Subject: [Gambas-user] Strange behaviour using gb.settings in a component Message-ID: <200812241116.52116.gambas@...1938...> Hi List, perhaps a silly question, but here it is: In my component I do: ' Gambas module file Export Private hCFG As Settings Public Sub _init() hCFG = New Settings(User.Home &/ "projekte/gambas/xyz.cfg") End After that I have defined my public functions. xyz.cfg holds some connection parameters which are only used by the component itself. When I execute my component directly, everything is fine!!!!! When calling a function of this component from my application like this: ' Gambas module file Private ABC As New Modxyz Public Sub Main() Print ABC.SomeFunction End and executiong the app in the IDE, I get: Syntax error in settings file at line #6: Connot load class 'Main'. Unable to load class file. In the meanwhile I checked out the following: When I comment out hCFG = New Settings(User.Home &/ "projekte/gambas/xyz.cfg") in the component. This error is gone...certainly I have no access to my configfile anymore and so the component can't read its connection parameters. Any idea, what I have to do, so that my config file could be read, when the component is called from an app? Thanks in advance and have a merry christmas! Greetz Stevie From classd2008 at ...626... Wed Dec 24 11:28:51 2008 From: classd2008 at ...626... (ClassD 2008) Date: Wed, 24 Dec 2008 08:28:51 -0200 Subject: [Gambas-user] How do in Gambas Message-ID: How do in Gambas 'VB type User name as string date as string id as long end type Thanks to all. From doriano.blengino at ...1909... Wed Dec 24 13:24:05 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 24 Dec 2008 13:24:05 +0100 Subject: [Gambas-user] Strange behaviour using gb.settings in a component In-Reply-To: <200812241116.52116.gambas@...1938...> References: <200812241116.52116.gambas@...1938...> Message-ID: <495229E5.60503@...1909...> gambas at ...1938... ha scritto: > Hi List, > > perhaps a silly question, but here it is: > In my component I do: > ' Gambas module file > Export > Private hCFG As Settings > > Public Sub _init() > hCFG = New Settings(User.Home &/ "projekte/gambas/xyz.cfg") > End > > After that I have defined my public functions. > xyz.cfg holds some connection parameters which are only used by the component > itself. > > When I execute my component directly, everything is fine!!!!! > When calling a function of this component from my application like this: > ' Gambas module file > Private ABC As New Modxyz > > Public Sub Main() > Print ABC.SomeFunction > End > > and executiong the app in the IDE, I get: > Syntax error in settings file at line #6: Connot load class 'Main'. Unable to > load class file. > Could be the real application has not the "gb.settings" checked in project properties? While the test application has? Anyway the error message is a little misguiding... Regards, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From doriano.blengino at ...1909... Wed Dec 24 13:27:40 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 24 Dec 2008 13:27:40 +0100 Subject: [Gambas-user] How do in Gambas In-Reply-To: References: Message-ID: <49522ABC.5010207@...1909...> ClassD 2008 ha scritto: > How do in Gambas > > 'VB > type User > name as string > date as string > id as long > end type > > You have to make a class file where you declare name, date, id as public. If you want you can also add methods to do operations on these variables. For example class user: ' gambas class file public name as string public date as string ... In the main program you can then instantiate as many "User" you want in the normal way (new User), put them in arrays or collections and so on. If you need just an instance, you can make the class static. Regards, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From gambas.fr at ...626... Wed Dec 24 13:23:30 2008 From: gambas.fr at ...626... (Fabien Bodard) Date: Wed, 24 Dec 2008 13:23:30 +0100 Subject: [Gambas-user] How do in Gambas In-Reply-To: References: Message-ID: <6324a42a0812240423g906bff4i21b86f806e311923@...627...> you may make a class 'gambas TUser.class 'Gambas class PUBLIC name as string PUBLIC date as string PUBLIC id as long then Dim MyUser as NEW TUser MyUser.name = "Mike" etc 2008/12/24 ClassD 2008 : > How do in Gambas > > 'VB > type User > name as string > date as string > id as long > end type > > Thanks to all. > ------------------------------------------------------------------------------ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Wed Dec 24 13:35:38 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 24 Dec 2008 13:35:38 +0100 Subject: [Gambas-user] Strange behaviour using gb.settings in a component In-Reply-To: <200812241116.52116.gambas@...1938...> References: <200812241116.52116.gambas@...1938...> Message-ID: <200812241335.38172.gambas@...1...> On mercredi 24 d?cembre 2008, gambas at ...1938... wrote: > Hi List, > > perhaps a silly question, but here it is: > In my component I do: > ' Gambas module file > Export > Private hCFG As Settings > > Public Sub _init() > hCFG = New Settings(User.Home &/ "projekte/gambas/xyz.cfg") > End > > After that I have defined my public functions. > xyz.cfg holds some connection parameters which are only used by the > component itself. > > When I execute my component directly, everything is fine!!!!! > When calling a function of this component from my application like this: > ' Gambas module file > Private ABC As New Modxyz > > Public Sub Main() > Print ABC.SomeFunction > End > > and executiong the app in the IDE, I get: > Syntax error in settings file at line #6: Connot load class 'Main'. Unable > to load class file. > > In the meanwhile I checked out the following: > When I comment out > hCFG = New Settings(User.Home &/ "projekte/gambas/xyz.cfg") > in the component. This error is gone...certainly I have no access to my > configfile anymore and so the component can't read its connection > parameters. > > Any idea, what I have to do, so that my config file could be read, when the > component is called from an app? > Thanks in advance and have a merry christmas! > > Greetz > Stevie > Please send me your project source code and your component source code. Regards, -- Benoit Minisini From jshackney at ...626... Thu Dec 25 06:00:15 2008 From: jshackney at ...626... (Jason Hackney) Date: Thu, 25 Dec 2008 00:00:15 -0500 Subject: [Gambas-user] how to edit data in table view In-Reply-To: <6324a42a0808131010k1ce00df3lbefa3e07a7a55224@...627...> References: <306344.29973.qm@...1954...> <6324a42a0808131010k1ce00df3lbefa3e07a7a55224@...627...> Message-ID: <799be1690812242100o54d2d0a0mc23a90351585e22@...627...> I know this is a few months on now, but I was wondering if anybody has downloaded Fabien's project? I tried running it but, still don't have the ability to edit the TableView. I created a new project (using Gambas 2.8) and copied the source of FMain.class into my project and created what I assumed was just a form with a TableView on it. I get the balloon messages, but cannot edit. On Wed, Aug 13, 2008 at 12:10 PM, Fabien Bodard wrote: > this way :) > > I've mad this short exemple for you... and others. But i think i need > to make a complete tutorial on gridview and table view. > > Regards, Fabien Bodard From md9327 at ...120... Thu Dec 25 13:44:31 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Thu, 25 Dec 2008 13:44:31 +0100 Subject: [Gambas-user] XML library with xml multilevel In-Reply-To: <1229978474.5199.35.camel@...37...> References: <1229256335.26984.1.camel@...37...> <1229875783.5199.10.camel@...37...> <1229973196.5199.23.camel@...37...> <1229975495.5199.32.camel@...37...> <1229978474.5199.35.camel@...37...> Message-ID: <1230209071.6677.21.camel@...37...> pgDesigner 2.9.0 Using the gb.xml library, me they are shrewed that the reading can be carried out single on files xml to 2 levels. I explain myself in better way? I have necessity to read xml files, that it contains a composed structure from elements, structured in hierarchical way on more levels, as an example:
questa ? una prova
In the example, the hierarchy of the rows xml is composed gives: 1) a main element (root) ??; 2) inside of the root, the element is present ??; 3) under ?? the element is present ??; 4) in its turn, the element ?
? contains a series of other heterogenous elements. Through the gb.xml library, the reading of the file does not notice of the closing of tag (Node.Type=XmlReaderNodeType.EndElement), if these are sluices on the same definition of the tag, like as an example: the reading evidences the opening of tag, but the not its closing, for which it renders impossible to ago understand if tag following the part of a advanced element, or is to the same level of the element precedence. The behavior is various in phase of writing where, through the methods ?StartElement? and ?EndElement?, it is possible to define complex structures. This logic, currently, only forces the use of structures xml on two levels. From wally at ...2037... Thu Dec 25 15:19:19 2008 From: wally at ...2037... (Wally) Date: Thu, 25 Dec 2008 15:19:19 +0100 Subject: [Gambas-user] searching an 3D array for values Message-ID: <200812251519.19733.wally@...2037...> How t get the "coordinates" [x,y,z] of all values in a 3D floatArray[a,b,c] which fits myfloatvalue ? How to get the next hit if floatArray.find got the first ? regs wally From alw at ...2038... Fri Dec 26 07:55:59 2008 From: alw at ...2038... (Al Williams) Date: Fri, 26 Dec 2008 00:55:59 -0600 Subject: [Gambas-user] gb.net.SerialPort Message-ID: <49547FFF.9050005@...2038...> From alw at ...2038... Fri Dec 26 07:57:59 2008 From: alw at ...2038... (Al Williams) Date: Fri, 26 Dec 2008 00:57:59 -0600 Subject: [Gambas-user] Adding widgets to the toolbox Message-ID: <49548077.6040907@...2038...> From demosthenesk at ...626... Fri Dec 26 17:24:08 2008 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Fri, 26 Dec 2008 18:24:08 +0200 Subject: [Gambas-user] gambas-mpg123player Message-ID: Hi list, i wrote a simple front-end for mpg123 console player in gambas2, have a look http://gambas-mpg123pl.sourceforge.net/index.html happy holidays to all!! -- ???? ???? ?? ?????!!! Regards, Demosthenes Koptsis From md9327 at ...120... Sat Dec 27 19:09:50 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sat, 27 Dec 2008 19:09:50 +0100 Subject: [Gambas-user] XML library with xml multilevel tags In-Reply-To: <1230209071.6677.21.camel@...37...> References: <1229256335.26984.1.camel@...37...> <1229875783.5199.10.camel@...37...> <1229973196.5199.23.camel@...37...> <1229975495.5199.32.camel@...37...> <1229978474.5199.35.camel@...37...> <1230209071.6677.21.camel@...37...> Message-ID: <1230401390.12085.2.camel@...37...> I do not comprise the reason, but mine precedence post has been included like answer in an other mail. ? however? Gambas 2.9.0 Using the gb.xml library, me they are shrewed that the reading can be carried out single on files xml to 2 levels. I explain myself in better way? I have necessity to read xml files, that it contains a composed structure from elements, structured in hierarchical way on more levels, as an example:
questa ? una prova
In the example, the hierarchy of the rows xml is composed gives: 1) a main element (root) ??; 2) inside of the root, the element is present ??; 3) under ?? the element is present ??; 4) in its turn, the element ?
? contains a series of other heterogenous elements. Through the gb.xml library, the reading of the file does not notice of the closing of tag (Node.Type=XmlReaderNodeType.EndElement), if these are sluices on the same definition of the tag, like as an example: the reading evidences the opening of tag, but the not its closing, for which it renders impossible to ago understand if tag following the part of a advanced element, or is to the same level of the element precedence. The behavior is various in phase of writing where, through the methods ?StartElement? and ?EndElement?, it is possible to define complex structures. This logic, currently, only forces the use of structures xml on two levels. From md9327 at ...120... Sat Dec 27 19:58:54 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sat, 27 Dec 2008 19:58:54 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1229977637.5199.33.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> <1229974725.5199.29.camel@...37...> <1229977637.5199.33.camel@...37...> Message-ID: <1230404334.12085.49.camel@...37...> The strings do not contain characters of ?Carriage Return? or ?Line Feed?, but only space; if you have noticed interruptions, it is only a problem with the mail, or the editor using the function cut&paste. Probably, the option of ?wrapping? of the editor, divides the line through spaces, but in the code all in a same and only string are comprised. The sql commandos are, sometimes, composed from more of a word key, and they do not have sense if dealt in separate way; an example could be the definition of a PostgreSQL field of type ?timestamp with time zones?. For program requirements, I have had to list in exact way, all the words key of the language sql, used from the motor of the database. I have already executed the test on the single characters of the string, and I have not evidenced anomalous situations. As I have already written, the problem verification in phase of passage of the string to function XML; the conversion executed from Conv() is very well. If I execute ?PRINT Conv(sType, ?UTF-8?, ?ASCII?)? from Console, the string it comes visualized in corrected way, with any LANG. You perfectly have reason on the anomalous use of the attributes, but I have had to use this logic because of an other problem, that I have uncovered using the gb.xml library; it seems that it is not way to read xml files, composed from tag multilevel. With my tests, I have verified that the use of a hierarchical structure, with advanced levels to 2, does not come read, that is, they come only read the tag of first and second level; if a third level is present, comes ignored, etc. Like in other languages, the document xml begins with tag ?root? (level 1), to which they are connected of the elements (level 2); Every element has, in its turn (attributes to part), a series under elements (level 3), and thus via, in hierarchical way. The methods of the library do not allow to read these ulterior elements, for which they have been forced to use a structure with 2 single levels, and the attributes for the values of the single element. But to part this, probably, and as I had supposed, exists some problem in the writing of attributes much large; but the single anomaly verification with the use of an Asian language, while with the European languages all it works well. It pardons me for my English bad one. From md9327 at ...120... Sat Dec 27 20:04:14 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sat, 27 Dec 2008 20:04:14 +0100 Subject: [Gambas-user] XML library with xml multilevel tags Message-ID: <1230404654.12085.51.camel@...37...> I do not comprise the reason, but mine precedence post has been included like answer in an other mail. ? however? Gambas 2.9.0 Using the gb.xml library, me they are shrewed that the reading can be carried out single on files xml to 2 levels. I explain myself in better way? I have necessity to read xml files, that it contains a composed structure from elements, structured in hierarchical way on more levels, as an example:
questa ? una prova
In the example, the hierarchy of the rows xml is composed gives: 1) a main element (root) ??; 2) inside of the root, the element is present ??; 3) under ?? the element is present ??; 4) in its turn, the element ?
? contains a series of other heterogenous elements. Through the gb.xml library, the reading of the file does not notice of the closing of tag (Node.Type=XmlReaderNodeType.EndElement), if these are sluices on the same definition of the tag, like as an example: the reading evidences the opening of tag, but the not its closing, for which it renders impossible to ago understand if tag following the part of a advanced element, or is to the same level of the element precedence. The behavior is various in phase of writing where, through the methods ?StartElement? and ?EndElement?, it is possible to define complex structures. This logic, currently, only forces the use of structures xml on two levels. From md9327 at ...120... Sat Dec 27 20:44:24 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sat, 27 Dec 2008 20:44:24 +0100 Subject: [Gambas-user] [Abort]: XML library with xml multilevel tags In-Reply-To: <1230404654.12085.51.camel@...37...> References: <1230404654.12085.51.camel@...37...> Message-ID: <1230407064.12085.54.camel@...37...> Il giorno sab, 27/12/2008 alle 20.04 +0100, Luigi Carlotto ha scritto: > I do not comprise the reason, but mine precedence post has been > included like answer in an other mail. > > ? however? > > > Gambas 2.9.0 > > Using the gb.xml library, me they are shrewed that the reading can be > carried out single on files xml to 2 levels. > I explain myself in better way? > I have necessity to read xml files, that it contains a composed > structure from elements, structured in hierarchical way on more > levels, as an example: > > > > Revision="14/03/2008 14:44:03" Description="bible" Driver="8.2" > Author="mgm" Display="0"> >
ColorText="0,0,0" ColorBackTitle="230,230,230" > ColorBackTitleSelected="76,89,166" ColorForeTitle="0,0,0" > ColorForeTitleSelected="255,255,255" Comment="006C006F0067" > Option="false" PrimaryKey="tb_log_pk"> > Comment="006900640065006E00740069006600690061006E0074" Length="0" > NullCheck="true" PrimaryKey="true" Type1="serial"/> > Unique="true"/> >
> questa ? una prova >
>
> > In the example, the hierarchy of the rows xml is composed gives: > 1) a main element (root) ??; > 2) inside of the root, the element is present ??; > 3) under ?? the element is present ??; > 4) in its turn, the element ?
? contains a series of other > heterogenous elements. > > Through the gb.xml library, the reading of the file does not notice of > the closing of tag (Node.Type=XmlReaderNodeType.EndElement), if these > are sluices on the same definition of the tag, like as an example: > > Unique="true"/> > > the reading evidences the opening of tag, but the not its closing, for > which it renders impossible to ago understand if tag following the > part of a advanced element, or is to the same level of the element > precedence. > > The behavior is various in phase of writing where, through the methods > ?StartElement? and ?EndElement?, it is possible to define complex > structures. > > This logic, currently, only forces the use of structures xml on two > levels. It pardons me, but with ulterior verifications I have understood where it was the problem. The bookcase gb.xml works correctly. From ronstk at ...239... Sat Dec 27 21:33:42 2008 From: ronstk at ...239... (Ron_1st) Date: Sat, 27 Dec 2008 21:33:42 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1230404334.12085.49.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229977637.5199.33.camel@...37...> <1230404334.12085.49.camel@...37...> Message-ID: <200812272133.43159.ronstk@...239...> On Saturday 27 December 2008, Luigi Carlotto wrote: > The strings do not contain characters of ?Carriage Return? or ?Line > Feed?, but only space; if you have noticed interruptions, it is only a > problem with the mail, or the editor using the function cut&paste. > Probably, the option of ?wrapping? of the editor, divides the line > through spaces, but in the code all in a same and only string are > comprised. > > The sql commandos are, sometimes, composed from more of a word key, and > they do not have sense if dealt in separate way; an example could be the > definition of a PostgreSQL field of type ?timestamp with time zones?. > For program requirements, I have had to list in exact way, all the words > key of the language sql, used from the motor of the database. > > I have already executed the test on the single characters of the string, > and I have not evidenced anomalous situations. > As I have already written, the problem verification in phase of passage > of the string to function XML; the conversion executed from Conv() is > very well. > If I execute ?PRINT Conv(sType, ?UTF-8?, ?ASCII?)? from Console, the > string it comes visualized in corrected way, with any LANG. > > You perfectly have reason on the anomalous use of the attributes, but I > have had to use this logic because of an other problem, that I have > uncovered using the gb.xml library; it seems that it is not way to read > xml files, composed from tag multilevel. > With my tests, I have verified that the use of a hierarchical structure, > with advanced levels to 2, does not come read, that is, they come only > read the tag of first and second level; if a third level is present, > comes ignored, etc. > > Like in other languages, the document xml begins with tag ?root? (level > 1), to which they are connected of the elements (level 2); Every element > has, in its turn (attributes to part), a series under elements (level > 3), and thus via, in hierarchical way. > The methods of the library do not allow to read these ulterior elements, > for which they have been forced to use a structure with 2 single levels, > and the attributes for the values of the single element. > > But to part this, probably, and as I had supposed, exists some problem > in the writing of attributes much large; but the single anomaly > verification with the use of an Asian language, while with the European > languages all it works well. > > It pardons me for my English bad one. > > OK, understand the nasty problem of two levels. It explains also why I had some problems to in the past. I switched over to PHP for that matter. Just a question, when using XML there is also a *.dtd explaining the elements and the hiearchi of them. Is it it allowed to have such long string and using spaces inside? Does a space have speial meaning in the attributes value declaration? In HTML using the class="first second" means the tag has two classes, 'first' and 'second' May be something like this is also valid for your XML usage. No problem for english, mine is also bad :) Best regards, Ron_1st -- From md9327 at ...120... Sun Dec 28 01:20:51 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sun, 28 Dec 2008 01:20:51 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1230404334.12085.49.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> <1229974725.5199.29.camel@...37...> <1229977637.5199.33.camel@...37...> <1230404334.12085.49.camel@...37...> Message-ID: <1230423651.12085.78.camel@...37...> Il giorno sab, 27/12/2008 alle 19.58 +0100, Luigi Carlotto ha scritto: > The strings do not contain characters of ?Carriage Return? or ?Line > Feed?, but only space; if you have noticed interruptions, it is only a > problem with the mail, or the editor using the function cut&paste. > Probably, the option of ?wrapping? of the editor, divides the line > through spaces, but in the code all in a same and only string are > comprised. > > The sql commandos are, sometimes, composed from more of a word key, > and they do not have sense if dealt in separate way; an example could > be the definition of a PostgreSQL field of type ?timestamp with time > zones?. For program requirements, I have had to list in exact way, all > the words key of the language sql, used from the motor of the > database. > > I have already executed the test on the single characters of the > string, and I have not evidenced anomalous situations. > As I have already written, the problem verification in phase of > passage of the string to function XML; the conversion executed from > Conv() is very well. > If I execute ?PRINT Conv(sType, ?UTF-8?, ?ASCII?)? from Console, the > string it comes visualized in corrected way, with any LANG. > > You perfectly have reason on the anomalous use of the attributes, but > I have had to use this logic because of an other problem, that I have > uncovered using the gb.xml library; it seems that it is not way to > read xml files, composed from tag multilevel. > With my tests, I have verified that the use of a hierarchical > structure, with advanced levels to 2, does not come read, that is, > they come only read the tag of first and second level; if a third > level is present, comes ignored, etc. > > Like in other languages, the document xml begins with tag > ?root? (level 1), to which they are connected of the elements (level > 2); Every element has, in its turn (attributes to part), a series > under elements (level 3), and thus via, in hierarchical way. > The methods of the library do not allow to read these ulterior > elements, for which they have been forced to use a structure with 2 > single levels, and the attributes for the values of the single > element. > > But to part this, probably, and as I had supposed, exists some problem > in the writing of attributes much large; but the single anomaly > verification with the use of an Asian language, while with the > European languages all it works well. > > It pardons me for my English bad one. > > I have modified the procedures of reading/writing of XML files, following your relative suggestion I use to it of the elements (eliminating the attributes). In spite of this modification, the problem still remains? I send new file, in attached, so that it can be read with browser or a editor of text, to eliminate problems of reading of invisible characters. The error code is always the same one: encoding error : output conversion failed due to conv error, bytes 0xE5 0x31 0x32 0xE5 I/O error : encoder error Error: Error writing XML data Code: -1 I have divided the code, so as to verify if the problem is caused from the conversion (Conv), or from the writing xml; you I can confirm that the error verification in correspondence of the writing xml, while the conversion comes made correctly. With the exception of the byte 0x31 (character ?1?) and 0x32 (character ?2?), character 0xE5 (224 binary) does not come understood; in effects, using PRINT Chr (224) in Gambas Console, they come printed two rectangles white. This character, but, is not present in the string where the program jams; the string is: ?--,/*, *? (excluded apexes). The same string comes many times over saved, in the same function, but the program jams alone on the last one. -------------- next part -------------- A non-text attachment was scrubbed... Name: pgdesigner2.conf Type: application/xml Size: 7612 bytes Desc: not available URL: From md9327 at ...120... Sun Dec 28 01:56:33 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sun, 28 Dec 2008 01:56:33 +0100 Subject: [Gambas-user] Problem with Conv() and XmlWrite In-Reply-To: <1230423651.12085.78.camel@...37...> References: <1229256516.26984.4.camel@...37...> <1229876165.5199.17.camel@...37...> <1229974725.5199.29.camel@...37...> <1229977637.5199.33.camel@...37...> <1230404334.12085.49.camel@...37...> <1230423651.12085.78.camel@...37...> Message-ID: <1230425793.12085.92.camel@...37...> Il giorno dom, 28/12/2008 alle 01.20 +0100, Luigi Carlotto ha scritto: > Il giorno sab, 27/12/2008 alle 19.58 +0100, Luigi Carlotto ha scritto: > > > The strings do not contain characters of ?Carriage Return? or ?Line > > Feed?, but only space; if you have noticed interruptions, it is only > > a problem with the mail, or the editor using the function cut&paste. > > Probably, the option of ?wrapping? of the editor, divides the line > > through spaces, but in the code all in a same and only string are > > comprised. > > > > The sql commandos are, sometimes, composed from more of a word key, > > and they do not have sense if dealt in separate way; an example > > could be the definition of a PostgreSQL field of type ?timestamp > > with time zones?. For program requirements, I have had to list in > > exact way, all the words key of the language sql, used from the > > motor of the database. > > > > I have already executed the test on the single characters of the > > string, and I have not evidenced anomalous situations. > > As I have already written, the problem verification in phase of > > passage of the string to function XML; the conversion executed from > > Conv() is very well. > > If I execute ?PRINT Conv(sType, ?UTF-8?, ?ASCII?)? from Console, the > > string it comes visualized in corrected way, with any LANG. > > > > You perfectly have reason on the anomalous use of the attributes, > > but I have had to use this logic because of an other problem, that I > > have uncovered using the gb.xml library; it seems that it is not way > > to read xml files, composed from tag multilevel. > > With my tests, I have verified that the use of a hierarchical > > structure, with advanced levels to 2, does not come read, that is, > > they come only read the tag of first and second level; if a third > > level is present, comes ignored, etc. > > > > Like in other languages, the document xml begins with tag > > ?root? (level 1), to which they are connected of the elements (level > > 2); Every element has, in its turn (attributes to part), a series > > under elements (level 3), and thus via, in hierarchical way. > > The methods of the library do not allow to read these ulterior > > elements, for which they have been forced to use a structure with 2 > > single levels, and the attributes for the values of the single > > element. > > > > But to part this, probably, and as I had supposed, exists some > > problem in the writing of attributes much large; but the single > > anomaly verification with the use of an Asian language, while with > > the European languages all it works well. > > > > It pardons me for my English bad one. > > > > > > > I have modified the procedures of reading/writing of XML files, > following your relative suggestion I use to it of the elements > (eliminating the attributes). > In spite of this modification, the problem still remains? > I send new file, in attached, so that it can be read with browser or a > editor of text, to eliminate problems of reading of invisible > characters. > The error code is always the same one: > > encoding error : output conversion failed due to conv error, bytes > 0xE5 0x31 0x32 0xE5 > I/O error : encoder error > Error: Error writing XML data > Code: -1 > > I have divided the code, so as to verify if the problem is caused from > the conversion (Conv), or from the writing xml; you I can confirm that > the error verification in correspondence of the writing xml, while the > conversion comes made correctly. > > With the exception of the byte 0x31 (character ?1?) and 0x32 > (character ?2?), character 0xE5 (224 binary) does not come understood; > in effects, using PRINT Chr (224) in Gambas Console, they come printed > two rectangles white. This character, but, is not present in the > string where the program jams; the string is: ?--,/*, *? (excluded > apexes). The same string comes many times over saved, in the same > function, but the program jams alone on the last one. > > In attached shipment 3 classes, that I have constructed on the base of the objects of the gb.xml library (XmlReader and XmlWriter). These classes directly work in memory, loading the xml files in a structure, that it can be read inside of a program. The writing comes carried out through the same structure of memory. This logic me slightly seems or faster, and fastly releases the connections to the file. Only problem, perhaps, could be the management of large files; I have tried with xml of 2Mbyte, and I am fast. Perhaps he can be useful in Gambas? The structure follows logic, also applied in other languages, than part from an object Document (pgXmlDocument), that a Root element contains; like then for all the other elements (pgXmlElement), it contains an Array of elements and an Array of attributes (pgXmlAttribute). The connection with the object father, comes managed from the property Parent (Root does not have Parent, obviously). It makes me to know if it can interest. -------------- next part -------------- ' Gambas class file ' Module : pgXml.class ' Author : Luigi Carlotto ' Mail : luigi.carlotto at ...120... ' Description: Xml object management. INHERITS pgObject CREATE PRIVATE -------------- next part -------------- ' Gambas class file ' Module : pgXmlAttribute.class ' Author : Luigi Carlotto ' Mail : luigi.carlotto at ...120... ' Description: Xml Attribute object management. INHERITS pgXml PROPERTY READ Parent AS pgXmlElement PROPERTY Name AS String PROPERTY Value AS String PRIVATE $parent AS pgXmlElement PRIVATE $name AS String 'name of attribute PRIVATE $value AS String 'value of attribute PUBLIC SUB _new(parent AS pgXmlElement, name AS String, OPTIONAL value AS String = "") $parent = parent $name = name $value = value END PRIVATE FUNCTION Parent_Read() AS pgXmlElement RETURN $parent END PRIVATE FUNCTION Name_Read() AS String RETURN $name END PRIVATE SUB Name_Write(Value AS String) $name = Value END PRIVATE FUNCTION Value_Read() AS String RETURN $value END PRIVATE SUB Value_Write(Value AS String) $value = Value END -------------- next part -------------- ' Gambas class file ' Module : pgXmlDocument.class ' Author : Luigi Carlotto ' Mail : luigi.carlotto at ...120... ' Description: Xml Document object management. INHERITS pgXml ' Properties PROPERTY READ Root AS pgXmlElement PRIVATE $root AS pgXmlElement 'root '--- ' Constructor ' PUBLIC SUB _new() $root = NEW pgXmlElement(NULL, "root") END PRIVATE FUNCTION Root_Read() AS pgXmlElement RETURN $root END '--- ' Load data ' ' @parameter : String : Path ' PUBLIC SUB Load(path AS String) DIM oRoot AS pgXmlElement DIM oElement AS pgXmlElement DIM oAttribute AS pgXmlAttribute DIM oXml AS NEW XmlReader $root.Name = "root" $root.Elements.Clear() $root.Attributes.Clear() oRoot = $root oXml.Open(path) DO UNTIL (oXml.Eof) SELECT CASE oXml.Node.Type CASE XmlReaderNodeType.Element oElement = NEW pgXmlElement(oRoot, oXml.Node.Name, oXml.Node.Value) FOR EACH oXml.Node.Attributes oAttribute = NEW pgXmlAttribute(oElement, oXml.Node.Name, oXml.Node.Value) oElement.Attributes.Add(oAttribute) NEXT oRoot.Elements.Add(oElement) oRoot = oElement CASE XmlReaderNodeType.EndElement oRoot = oRoot.Parent CASE XmlReaderNodeType.Text oElement.Value &= pgString.Trim(oXml.Node.Value) END SELECT oXml.Read() LOOP oXml.Close() END PRIVATE SUB _loadElement(oXml AS XmlWriter, oRoot AS pgXmlElement) END '--- ' Save data ' ' @parameter : String : Path ' @parameter : String : Indent ' @parameter : String : Encoding ' PUBLIC SUB Save(path AS String, OPTIONAL indent AS Boolean = TRUE, OPTIONAL encoding AS String = "UTF8") DIM oXml AS NEW XmlWriter DIM oXmlElement AS pgXmlElement oXml.Open(path, indent, encoding) FOR EACH oXmlElement IN $root.Elements _saveElement(oXml, oXmlElement) NEXT oXml.EndDocument() END PRIVATE SUB _saveElement(oXml AS XmlWriter, oRoot AS pgXmlElement) DIM oXmlElement AS pgXmlElement DIM oXmlAttribute AS pgXmlAttribute oXml.StartElement(oRoot.Name) IF (oRoot.Attributes.Count > 0) THEN FOR EACH oXmlAttribute IN oRoot.Attributes oXml.Attribute(oXmlAttribute.Name, oXmlAttribute.Value) NEXT END IF IF (oRoot.Elements.Count > 0) THEN FOR EACH oXmlElement IN oRoot.Elements _saveElement(oXml, oXmlElement) NEXT END IF oXml.Text(oRoot.Value) oXml.EndElement() END PUBLIC SUB Print(filename AS String) DIM hFile AS File DIM oXmlElement AS pgXmlElement IF ($root.Elements.Count > 0) THEN hFile = OPEN filename FOR OUTPUT CREATE FOR EACH oXmlElement IN $root.Elements _printElement(hFile, oXmlElement) NEXT CLOSE #hFile END IF END PRIVATE SUB _printElement(hFile AS file, oRoot AS pgXmlElement, OPTIONAL level AS Integer = 0) DIM oElement AS pgXmlElement DIM oAttribute AS pgXmlAttribute IF (NOT pgTest.IsNull(oRoot)) THEN PRINT #hFile, String(level, " ") & "Start Element: " & oRoot.Name PRINT #hFile, String(level, " ") & " Value: \"" & oRoot.Value & "\"" IF (oRoot.Attributes.Count > 0) THEN FOR EACH oAttribute IN oRoot.Attributes PRINT #hFile, String(level, " ") & " Attribute:" & oAttribute.Name & " = \"" & oAttribute.Value & "\"" NEXT END IF IF (oRoot.Elements.Count > 0) THEN FOR EACH oElement IN oRoot.Elements _printElement(hFile, oElement, level + 1) NEXT END IF PRINT #hFile, String(level, " ") & "End Element: " & oRoot.Name END IF END -------------- next part -------------- ' Gambas class file ' Module : pgXmlElement.class ' Author : Luigi Carlotto ' Mail : luigi.carlotto at ...120... ' Description: Xml Element object management. INHERITS pgXml PROPERTY READ Parent AS pgXmlElement PROPERTY Name AS String PROPERTY Value AS String PROPERTY READ Attributes AS Object[] PROPERTY READ Elements AS Object[] PROPERTY Tag AS Boolean PRIVATE $parent AS pgXmlElement PRIVATE $name AS String 'name of element PRIVATE $value AS String 'value of element PRIVATE $attributes AS Object[] 'array of attributes PRIVATE $elements AS Object[] 'array of elements PRIVATE $tag AS Boolean PUBLIC SUB _new(parent AS pgXmlElement, name AS String, OPTIONAL value AS String = "") $parent = parent $name = name $value = value $attributes = pgBase.NewObjectArray() $elements = pgBase.NewObjectArray() END PRIVATE FUNCTION Parent_Read() AS pgXmlElement RETURN $parent END PRIVATE FUNCTION Name_Read() AS String RETURN $name END PRIVATE SUB Name_Write(Value AS String) $name = Value END PRIVATE FUNCTION Value_Read() AS String RETURN $value END PRIVATE SUB Value_Write(Value AS String) $value = Value END PRIVATE FUNCTION Attributes_Read() AS Object[] RETURN $attributes END PRIVATE FUNCTION Elements_Read() AS Object[] RETURN $elements END PRIVATE FUNCTION Tag_Read() AS Boolean RETURN $tag END PRIVATE SUB Tag_Write(Value AS Boolean) $tag = Value END PUBLIC FUNCTION AddAttribute(name AS String, OPTIONAL value AS String = "") AS pgXmlAttribute DIM oXmlAttribute AS pgXmlAttribute oXmlAttribute = NEW pgXmlAttribute(ME, name, value) $attributes.Add(oXmlAttribute) RETURN oXmlAttribute END PUBLIC FUNCTION AddElement(name AS String, OPTIONAL value AS String = "") AS pgXmlElement DIM oXmlElement AS pgXmlElement oXmlElement = NEW pgXmlElement(ME, name, value) $elements.Add(oXmlElement) RETURN oXmlElement END From md9327 at ...120... Sun Dec 28 02:14:04 2008 From: md9327 at ...120... (Luigi Carlotto) Date: Sun, 28 Dec 2008 02:14:04 +0100 Subject: [Gambas-user] XML library with xml multilevel tags In-Reply-To: <1230404654.12085.51.camel@...37...> References: <1230404654.12085.51.camel@...37...> Message-ID: <1230426844.12085.102.camel@...37...> Il giorno sab, 27/12/2008 alle 20.04 +0100, Luigi Carlotto ha scritto: > I do not comprise the reason, but mine precedence post has been > included like answer in an other mail. > > ? however? > > > Gambas 2.9.0 > > Using the gb.xml library, me they are shrewed that the reading can be > carried out single on files xml to 2 levels. > I explain myself in better way? > I have necessity to read xml files, that it contains a composed > structure from elements, structured in hierarchical way on more > levels, as an example: > > > > Revision="14/03/2008 14:44:03" Description="bible" Driver="8.2" > Author="mgm" Display="0"> >
ColorText="0,0,0" ColorBackTitle="230,230,230" > ColorBackTitleSelected="76,89,166" ColorForeTitle="0,0,0" > ColorForeTitleSelected="255,255,255" Comment="006C006F0067" > Option="false" PrimaryKey="tb_log_pk"> > Comment="006900640065006E00740069006600690061006E0074" Length="0" > NullCheck="true" PrimaryKey="true" Type1="serial"/> > Unique="true"/> >
> questa ? una prova >
>
> > In the example, the hierarchy of the rows xml is composed gives: > 1) a main element (root) ??; > 2) inside of the root, the element is present ??; > 3) under ?? the element is present ??; > 4) in its turn, the element ?
? contains a series of other > heterogenous elements. > > Through the gb.xml library, the reading of the file does not notice of > the closing of tag (Node.Type=XmlReaderNodeType.EndElement), if these > are sluices on the same definition of the tag, like as an example: > > Unique="true"/> > > the reading evidences the opening of tag, but the not its closing, for > which it renders impossible to ago understand if tag following the > part of a advanced element, or is to the same level of the element > precedence. > > The behavior is various in phase of writing where, through the methods > ?StartElement? and ?EndElement?, it is possible to define complex > structures. > > This logic, currently, only forces the use of structures xml on two > levels. The spaces contained in the strings do not have particolary functions, but they make part of the name of the object, and it is not possible to eliminate them. In other cases, use the comma in order to separate a list of elements (es. an Array, Join function), than in reading comes reconverted in Array (Split function). With regard to the levels, I have resolved, constructing a series of classes, based on the objects XmlReader and XmlWriter. Logic of these objects allows to only read to rows xml multilevel, but if the tag they are not sluices on if same. In contrary case, the gb.xml library does not notice of the closing of the tag, for which the hierarchy it does not come constructed in correct way. These classes directly work in memory, loading the xml files in a structure, that it can be read inside of a program. The writing comes carried out through the same structure of memory. This logic me slightly seems or faster, and fastly releases the connections to the file. Only problem, perhaps, could be the management of large files; I have tried with xml of 2Mbyte, and I am fast. Perhaps he can be useful in Gambas? The structure follows logic, also applied in other languages, than part from an object Document (pgXmlDocument), that a Root element contains; like then for all the other elements (pgXmlElement), it contains an Array of elements and an Array of attributes (pgXmlAttribute). The connection with the object father, comes managed from the property Parent (Root does not have Parent, obviously). It makes me to know if it can interest. -------------- next part -------------- ' Gambas class file ' Module : pgXml.class ' Author : Luigi Carlotto ' Mail : luigi.carlotto at ...120... ' Description: Xml object management. INHERITS pgObject CREATE PRIVATE -------------- next part -------------- ' Gambas class file ' Module : pgXmlAttribute.class ' Author : Luigi Carlotto ' Mail : luigi.carlotto at ...120... ' Description: Xml Attribute object management. INHERITS pgXml PROPERTY READ Parent AS pgXmlElement PROPERTY Name AS String PROPERTY Value AS String PRIVATE $parent AS pgXmlElement PRIVATE $name AS String 'name of attribute PRIVATE $value AS String 'value of attribute PUBLIC SUB _new(parent AS pgXmlElement, name AS String, OPTIONAL value AS String = "") $parent = parent $name = name $value = value END PRIVATE FUNCTION Parent_Read() AS pgXmlElement RETURN $parent END PRIVATE FUNCTION Name_Read() AS String RETURN $name END PRIVATE SUB Name_Write(Value AS String) $name = Value END PRIVATE FUNCTION Value_Read() AS String RETURN $value END PRIVATE SUB Value_Write(Value AS String) $value = Value END -------------- next part -------------- ' Gambas class file ' Module : pgXmlDocument.class ' Author : Luigi Carlotto ' Mail : luigi.carlotto at ...120... ' Description: Xml Document object management. INHERITS pgXml ' Properties PROPERTY READ Root AS pgXmlElement PRIVATE $root AS pgXmlElement 'root '--- ' Constructor ' PUBLIC SUB _new() $root = NEW pgXmlElement(NULL, "root") END PRIVATE FUNCTION Root_Read() AS pgXmlElement RETURN $root END '--- ' Load data ' ' @parameter : String : Path ' PUBLIC SUB Load(path AS String) DIM oRoot AS pgXmlElement DIM oElement AS pgXmlElement DIM oAttribute AS pgXmlAttribute DIM oXml AS NEW XmlReader $root.Name = "root" $root.Elements.Clear() $root.Attributes.Clear() oRoot = $root oXml.Open(path) DO UNTIL (oXml.Eof) SELECT CASE oXml.Node.Type CASE XmlReaderNodeType.Element oElement = NEW pgXmlElement(oRoot, oXml.Node.Name, oXml.Node.Value) FOR EACH oXml.Node.Attributes oAttribute = NEW pgXmlAttribute(oElement, oXml.Node.Name, oXml.Node.Value) oElement.Attributes.Add(oAttribute) NEXT oRoot.Elements.Add(oElement) oRoot = oElement CASE XmlReaderNodeType.EndElement oRoot = oRoot.Parent CASE XmlReaderNodeType.Text oElement.Value &= pgString.Trim(oXml.Node.Value) END SELECT oXml.Read() LOOP oXml.Close() END PRIVATE SUB _loadElement(oXml AS XmlWriter, oRoot AS pgXmlElement) END '--- ' Save data ' ' @parameter : String : Path ' @parameter : String : Indent ' @parameter : String : Encoding ' PUBLIC SUB Save(path AS String, OPTIONAL indent AS Boolean = TRUE, OPTIONAL encoding AS String = "UTF8") DIM oXml AS NEW XmlWriter DIM oXmlElement AS pgXmlElement oXml.Open(path, indent, encoding) FOR EACH oXmlElement IN $root.Elements _saveElement(oXml, oXmlElement) NEXT oXml.EndDocument() END PRIVATE SUB _saveElement(oXml AS XmlWriter, oRoot AS pgXmlElement) DIM oXmlElement AS pgXmlElement DIM oXmlAttribute AS pgXmlAttribute oXml.StartElement(oRoot.Name) IF (oRoot.Attributes.Count > 0) THEN FOR EACH oXmlAttribute IN oRoot.Attributes oXml.Attribute(oXmlAttribute.Name, oXmlAttribute.Value) NEXT END IF IF (oRoot.Elements.Count > 0) THEN FOR EACH oXmlElement IN oRoot.Elements _saveElement(oXml, oXmlElement) NEXT END IF oXml.Text(oRoot.Value) oXml.EndElement() END '--- ' Print structure ' ' @parameter : String : Filename ' PUBLIC SUB Print(filename AS String) DIM hFile AS File DIM oXmlElement AS pgXmlElement IF ($root.Elements.Count > 0) THEN hFile = OPEN filename FOR OUTPUT CREATE FOR EACH oXmlElement IN $root.Elements _printElement(hFile, oXmlElement) NEXT CLOSE #hFile END IF END PRIVATE SUB _printElement(hFile AS file, oRoot AS pgXmlElement, OPTIONAL level AS Integer = 0) DIM oElement AS pgXmlElement DIM oAttribute AS pgXmlAttribute IF (NOT pgTest.IsNull(oRoot)) THEN PRINT #hFile, String(level, " ") & "Start Element: " & oRoot.Name PRINT #hFile, String(level, " ") & " Value: \"" & oRoot.Value & "\"" IF (oRoot.Attributes.Count > 0) THEN FOR EACH oAttribute IN oRoot.Attributes PRINT #hFile, String(level, " ") & " Attribute:" & oAttribute.Name & " = \"" & oAttribute.Value & "\"" NEXT END IF IF (oRoot.Elements.Count > 0) THEN FOR EACH oElement IN oRoot.Elements _printElement(hFile, oElement, level + 1) NEXT END IF PRINT #hFile, String(level, " ") & "End Element: " & oRoot.Name END IF END -------------- next part -------------- ' Gambas class file ' Module : pgXmlElement.class ' Author : Luigi Carlotto ' Mail : luigi.carlotto at ...120... ' Description: Xml Element object management. INHERITS pgXml PROPERTY READ Parent AS pgXmlElement PROPERTY Name AS String PROPERTY Value AS String PROPERTY READ Attributes AS Object[] PROPERTY READ Elements AS Object[] PROPERTY Tag AS Boolean PRIVATE $parent AS pgXmlElement PRIVATE $name AS String 'name of element PRIVATE $value AS String 'value of element PRIVATE $attributes AS Object[] 'array of attributes PRIVATE $elements AS Object[] 'array of elements PRIVATE $tag AS Boolean PUBLIC SUB _new(parent AS pgXmlElement, name AS String, OPTIONAL value AS String = "") $parent = parent $name = name $value = value $attributes = pgBase.NewObjectArray() $elements = pgBase.NewObjectArray() END PRIVATE FUNCTION Parent_Read() AS pgXmlElement RETURN $parent END PRIVATE FUNCTION Name_Read() AS String RETURN $name END PRIVATE SUB Name_Write(Value AS String) $name = Value END PRIVATE FUNCTION Value_Read() AS String RETURN $value END PRIVATE SUB Value_Write(Value AS String) $value = Value END PRIVATE FUNCTION Attributes_Read() AS Object[] RETURN $attributes END PRIVATE FUNCTION Elements_Read() AS Object[] RETURN $elements END PRIVATE FUNCTION Tag_Read() AS Boolean RETURN $tag END PRIVATE SUB Tag_Write(Value AS Boolean) $tag = Value END PUBLIC FUNCTION AddAttribute(name AS String, OPTIONAL value AS String = "") AS pgXmlAttribute DIM oXmlAttribute AS pgXmlAttribute oXmlAttribute = NEW pgXmlAttribute(ME, name, value) $attributes.Add(oXmlAttribute) RETURN oXmlAttribute END PUBLIC FUNCTION AddElement(name AS String, OPTIONAL value AS String = "") AS pgXmlElement DIM oXmlElement AS pgXmlElement oXmlElement = NEW pgXmlElement(ME, name, value) $elements.Add(oXmlElement) RETURN oXmlElement END From gambas at ...1... Sun Dec 28 20:27:13 2008 From: gambas at ...1... (Benoit Minisini) Date: Sun, 28 Dec 2008 20:27:13 +0100 Subject: [Gambas-user] Gambas 3 revision #1747 Message-ID: <200812282027.13582.gambas@...1...> Hi, For those who are in front of their computer during the X-mas holidays... There should be, as not everone in the world celebrate X-mas and/or have holidays at the same time... First, you may see a lot of change in the last revision of Gambas 3. Most of them are bug fixes ported from Gambas 2, except a new component named "gb.image.info". This is a little present for you. :-) That component allows you to get information about an image file without having to fully load it. It works this way: WITH ImageStat(System.User.Home &/ "photo.jpg") PRINT .Type PRINT .Width;; .Height;; .Depth END WITH The Type property is a MIME type ("image/jpeg" in that example), and is got from the file contents, not the file extension. The Depth is 24 for a true color image, 32 for a true color image with an alpha channel, and 8 for a palette-based image like GIF. You may get other values. The component have known bugs yet. For example ImageStat("~/photo.jpeg") does not work. So it is in alpha state at the moment. Last, just to tell everyone too, I have to develop a component for my job soon. That component will allow you to make images without having to use gb.qt or gb.gtk. It may be named "gb.image", and the current "gb.image" component will be renamed as "gb.image.effect" or something similar. That component will be based on the "GD" library (and libjpeg, libpng...). If you know a better library, please tell me. Meanwhile, enjoy "gb.image.info"! Regards, -- Benoit Minisini From gambas at ...1... Tue Dec 30 01:27:18 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 30 Dec 2008 01:27:18 +0100 Subject: [Gambas-user] Release of Gambas 2.10 Message-ID: <200812300127.18801.gambas@...1...> Hi, Here is a new release of Gambas 2. This is actually Gambas 2.10.1, as last minute bugs were discovered in the database component and the database manager. This is a bug fix release mainly. Here is a list of some bug fixes: - Possible crashes in the IDE property sheet and while saving forms. - Crash in the debugger when selecting the "Collection" identifier. - Automatic completion now works correctly on lines having non-ASCII characters. - Dir() and RDir() now work correctly on relative paths. - Enumerating something inside a _next() enumerator method now is safe. - SUPER now works inside overriden static methods. - Fix string and blob quoting in the PostgreSQL component. - Sockets will not take 100% CPU anymore. - Startup forms hidden at design time are not shown automatically anymore. - The XSLT component works again. There are a lot of fixes in the GTK+ component too. Here is the full ChangeLog: --8<--------------------------------------------------------------------------- [CONFIGURATION] * BUG: Fix unresolved variables in gb.qt generated Makefiles and possibly somewhere else. * NEW: Update libtool to the last version from Mandriva 2009 updates. [DEVELOPMENT ENVIRONMENT] * BUG: Fix the routine that returns the Desktop path. * BUG: Fix a possible crash in the property sheet when closing forms. * BUG: Fix a crash when saving a form with a tabstrip having a selected child. * BUG: Searching backward inside a subroutine should not freeze anymore. * BUG: Control and window dimensions can go up to 4096x4096 pixels. * BUG: When unchecking GUI components in a project, the edited forms are automatically closed. * BUG: Do not use the form icon on form class editors when refreshing the project. * BUG: In the icon editor, filling with a transparent color won't enter an infinite loop anymore. * BUG: Selecting the "Collection" word while debugging does not crash the IDE anymore. * NEW: Popup menu entries in code editor and form editor to define the current class as startup class. * NEW: Pressing Escape now closes a debugging window. * NEW: Added support for Valencian language, an official tongue in the Autonomous Community of Valencia, Spain. [DATABASE MANAGER] * BUG: Add "firebird" in the list of databases. [INTERPRETER] * BUG: Dir() and RDir() now work correctly on relative paths. * BUG: Enumerating something inside a _next() enumerator method now is safe. * BUG: Correctly handle interrupted system calls in streams defined outside of the interpreter. * BUG: Fix currency formats. * BUG: SUPER now works inside overriden static methods. * NEW: A domain name '(none)' is ignored when forging the FQDN for components that need it, like gb.net.smtp. [GB.DB] * NEW: Database types do not have to be in lowercase anymore. * BUG: Correctly raise a "type mismatch" error when a query argument is not translatable to SQL in Exec(), Find() and Edit() methods. [GB.DB.ODBC] * BUG: Handle ODBC drivers that can return the number of records in a query better. [GB.DB.POSTGRESQL] * BUG: Fix string quoting for postgresql >= 8.2. * BUG: Fix blob and string quoting. * BUG: Detect primary keys even if their name does not end with '_pkey'. * BUG: Correctly detect system databases. [GB.DEBUG] * BUG: If there is an I/O error between a debugged process and the IDE, the process is aborted. * BUG: Evaluating a class name returns better information now. [GB.EVAL] * BUG: Highlight.Analyze now correctly handles code lines having non ASCII characters inside. [GB.FORM] * BUG: TableView edit field position is now correct when the TableView window has a menu bar. * BUG: The Balloon does not take the focus anymore. [GB.GTK] * BUG: UserControl and UserContainer _Container properties are correctly implemented now. Consequently, the gb.form containers start working as expected. * BUG: Window.Background and Window.Foreground now work correctly when the window is embedded. * BUG: ClientX, ClientY, ClientW and ClientH container properties for Panel now take the frame into account, as in gb.qt. * BUG: TextLabel now deals correctly with its Font property. * BUG: TextLabel with AutoResize set now resizes the same way as in gb.qt. * BUG: Draw.RichText() now deals correctly with the Draw.Font property. * BUG: Windows having SkipTaskbar set now get the focus correctly when activated. * BUG: Setting ListBox.List and ComboBox.List does not raise the Click event anymore, as in gb.qt. * BUG: Searching an item in a ComboBox does not crash anymore. * BUG: TrayIcons do not raise events anymore if a modal dialog is shown. * BUG: If no toplevel menu is visible, then the window menubar is hidden. * BUG: As in gb.gt, toplevel menus with no text (separators) are hidden. * BUG: The TrayIcons _next and _get special methods do not crash anymore. * BUG: Buttons color properties now should work as expected. * BUG: The error message box now uses the application title, not the application name. * BUG: Fix non-modal window event loop management. * BUG: Fix a leak in font objects management. * BUG: Picture.Load() yet loads an image, but internally converts it to a pixmap. It speeds up following draws based on this picture. * BUG: Startup forms hidden at design time are not shown automatically anymore. * BUG: Startup forms are visible by default again. * BUG: Fix the warning when closing a window. [GB.NET] * BUG: The socket watch callbacks were incorrectly initialized! * BUG: Fix the Handle property for Socket, SerialPort and UdpSocket classes. * BUG: The Socket Ready event is correctly raised now. [GB.QT] * BUG: Windows having SkipTaskbar set now get the focus correctly when activated. * BUG: Remove warning messages when changing control colors. * BUG: Disable automatic extra indent of Labels. * BUG: Startup forms hidden at design time are not shown automatically anymore. * BUG: Don't allow widgets to be destroyed while processing non-input events. * NEW: The Editor.Print() method automatically split lines longer than 256 characters. [GB.QT.EXT] * BUG: Fix Editor margin width when showing line numbers. [GB.XML] * BUG: Remove a method declared twice. [GB.XML.XSLT] * BUG: The XSLT component works again. --8<--------------------------------------------------------------------------- Enjoy it! -- Benoit Minisini From rterry at ...1946... Tue Dec 30 07:33:54 2008 From: rterry at ...1946... (richard terry) Date: Tue, 30 Dec 2008 17:33:54 +1100 Subject: [Gambas-user] 1755 build failed! (sob sob) gambas3 Message-ID: <200812301733.54774.rterry@...1946...> /usr/bin/ld: cannot find -lqt-mt collect2: ld returned 1 exit status make[5]: *** [gb.qt.kde.html.la] Error 1 make[5]: Leaving directory `/home/richard/gambas3-svn/src/trunk/gb.qt.kde/src/html' make[4]: *** [all-recursive] Error 1 make[4]: Leaving directory `/home/richard/gambas3-svn/src/trunk/gb.qt.kde/src' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/home/richard/gambas3-svn/src/trunk/gb.qt.kde' make[2]: *** [all] Error 2 make[2]: Leaving directory `/home/richard/gambas3-svn/src/trunk/gb.qt.kde' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/richard/gambas3-svn/src/trunk' make: *** [all] Error 2 ==> ERROR: Build Failed. Aborting... Any idea's Regards Richard From d.paleino at ...626... Tue Dec 30 09:43:04 2008 From: d.paleino at ...626... (David Paleino) Date: Tue, 30 Dec 2008 09:43:04 +0100 Subject: [Gambas-user] 1755 build failed! (sob sob) gambas3 References: <200812301733.54774.rterry@...1946...> Message-ID: <20081230094304.587cf848@...626...> On Tue, 30 Dec 2008 17:33:54 +1100, richard terry wrote: > /usr/bin/ld: cannot find -lqt-mt Do you have qt3 headers installed? On Debian (and -like) systems it would be "libqt3-mt-dev". Just my two cents, David -- . ''`. Debian maintainer | http://wiki.debian.org/DavidPaleino : :' : Linuxer #334216 --|-- http://www.hanskalabs.net/ `. `'` GPG: 1392B174 ----|---- http://snipr.com/qa_page `- 2BAB C625 4E66 E7B8 450A C3E1 E6AA 9017 1392 B174 -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 197 bytes Desc: not available URL: From gambas at ...1... Tue Dec 30 13:04:42 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 30 Dec 2008 13:04:42 +0100 Subject: [Gambas-user] 1755 build failed! (sob sob) gambas3 In-Reply-To: <200812301733.54774.rterry@...1946...> References: <200812301733.54774.rterry@...1946...> Message-ID: <200812301304.42508.gambas@...1...> On mardi 30 d?cembre 2008, richard terry wrote: > /usr/bin/ld: cannot find -lqt-mt > collect2: ld returned 1 exit status > make[5]: *** [gb.qt.kde.html.la] Error 1 > make[5]: Leaving directory > `/home/richard/gambas3-svn/src/trunk/gb.qt.kde/src/html' > make[4]: *** [all-recursive] Error 1 > make[4]: Leaving directory > `/home/richard/gambas3-svn/src/trunk/gb.qt.kde/src' make[3]: *** > [all-recursive] Error 1 > make[3]: Leaving directory `/home/richard/gambas3-svn/src/trunk/gb.qt.kde' > make[2]: *** [all] Error 2 > make[2]: Leaving directory `/home/richard/gambas3-svn/src/trunk/gb.qt.kde' > make[1]: *** [all-recursive] Error 1 > make[1]: Leaving directory `/home/richard/gambas3-svn/src/trunk' > make: *** [all] Error 2 > ==> ERROR: Build Failed. > Aborting... > > Any idea's > > Regards > > Richard > First, do a "./reconf && ./configure -C". Then check that the qt 3 library is installed on your system. Regards, -- Benoit Minisini From admin at ...1080... Tue Dec 30 13:34:10 2008 From: admin at ...1080... (werner 007) Date: Tue, 30 Dec 2008 04:34:10 -0800 (PST) Subject: [Gambas-user] URL encoding "%20" Message-ID: <21216641.post@...1379...> Does anybody know a easy way to convert url encoded strings (like "%20") to normal characters? Btw: Nice would be Conv$("%20", url, utf8). Regards, werner(007) -- View this message in context: http://www.nabble.com/URL-encoding-%22-20%22-tp21216641p21216641.html Sent from the gambas-user mailing list archive at Nabble.com. From admin at ...1080... Tue Dec 30 14:03:46 2008 From: admin at ...1080... (werner 007) Date: Tue, 30 Dec 2008 05:03:46 -0800 (PST) Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <21216641.post@...1379...> References: <21216641.post@...1379...> Message-ID: <21216909.post@...1379...> werner 007 wrote: > > Does anybody know a easy way to convert url encoded strings (like "%20") > to normal characters? > > Btw: Nice would be Conv$("%20", url, utf8). > > > Regards, werner(007) > Ok, i got the answer by my self. The chars of not printable and non-ascii are represented as Hex. To convert it back: PUBLIC FUNCTION url_encode(url_string AS String) AS String DIM i AS Integer FOR i = 0 TO 32 url_string = Replace(url_string, "%" & Hex$(i, 2), Chr(i)) NEXT FOR i = 127 TO 255 url_string = Replace(url_string, "%" & Hex$(i, 2), Chr(i)) NEXT RETURN url_string END -- View this message in context: http://www.nabble.com/URL-encoding-%22-20%22-tp21216641p21216909.html Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Tue Dec 30 20:20:12 2008 From: gambas at ...1... (Benoit Minisini) Date: Tue, 30 Dec 2008 20:20:12 +0100 Subject: [Gambas-user] Bug in gb.net curl component In-Reply-To: <19cca6e50812301023s7c254231l2b8a65ac29a4872f@...627...> References: <19cca6e50812301023s7c254231l2b8a65ac29a4872f@...627...> Message-ID: <200812302020.13055.gambas@...1...> On mardi 30 d?cembre 2008, you wrote: > Dear Benoit: > > This is a really bug, I think it appears in gambas 2.9 and persist in > gambas 2.10, in gambas 2.7 works fine. It's really simple. And fails also > in http get example in gambas. When I put this url: > > http.url=" > http://217.76.137.224/multimedia/milenio3/diciembre2008/milenio3_20081228_p >arte2.mp3 " > > And code reach the > > http.get > > The application wait eternaly and not continue. > > In gambas 2.7 http.get pass well and start downloading and calling event > Read. > > I attach my program who parse and url and extract all mp3 and start > downloading one per one. In gambas 2.7 works fine, but in gambas 2.9 and > 2.10 when start donwload, hangs up. > > Regards > Lorenzo Tejera I found the bug: the FtpClient and HttpClient control Async property is not correctly initialized to TRUE. As a workaround, just explicitely set the Async property to TRUE before running the Get() method. It should work! Regards, -- Benoit Minisini From sourceforge-raindog2 at ...94... Tue Dec 30 21:23:11 2008 From: sourceforge-raindog2 at ...94... (Rob) Date: Tue, 30 Dec 2008 15:23:11 -0500 Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <21216909.post@...1379...> References: <21216641.post@...1379...> <21216909.post@...1379...> Message-ID: <200812301523.11188.sourceforge-raindog2@...94...> On Tuesday 30 December 2008 08:03, werner 007 wrote: > Ok, i got the answer by my self. > The chars of not printable and non-ascii are represented as Hex. > To convert it back: That'll work, but it'll also run Replace() 160 times each time you do a conversion. I'd do something like this: function urlencode(strin as string) as string dim strout as string dim i as integer dim a as integer for i = 1 to len(strin) a = asc(mid(strin, i, 1)) if a < 33 or a > 126 then strout = strout & "%" & Hex$(a, 2) else strout = strout & mid(strin, i, 1) endif next return strout end Rob From pokerbirch at ...1601... Tue Dec 30 21:31:57 2008 From: pokerbirch at ...1601... (birchy) Date: Tue, 30 Dec 2008 12:31:57 -0800 (PST) Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <200812021542.04023.gambas@...1...> References: <20435022.post@...1379...> <200811111555.45564.gambas@...1...> <200811111601.49341.gambas@...1...> <20759131.post@...1379...> <20791388.post@...1379...> <200812021450.47939.gambas@...1...> <20792906.post@...1379...> <200812021521.52101.gambas@...1...> <20793347.post@...1379...> <200812021542.04023.gambas@...1...> Message-ID: <21222728.post@...1379...> Benoit Minisini wrote: > Maybe if you explain precisely what you need I could give you some advice? Hi, sorry for the delay, i have been busy with other things. I now have a number of questions as i have been using a Python binding of CURL called PyCurl... 1) Does Gambas implement the libcurl library or does it use curl via a command prompt? 2) I have still not found a satisfactory HTML parsing library because many of the values i want to extract are within JavaScript tags. Many people suggest using BeautifulSoup, but i don't know if i can use this within Gambas?? I can parse the document manually using string functions but it can get quite ugly. I have read that Perl has a Tokenizer library which may be useful for my purposes. My basic requirement is to be able to extract specific sections of html which i can then parse manually. For instance, lets say we have a table in our html, and it is the first one:
index.php images/image1.gif images/image2.jpg
What i would like to do is have a function something like: myString = GetTable(0), which would return a string containing all of the above text. I think this is how a Tokenizer works, though i'm not sure? Do you have any suggestions other than using string functions? -- View this message in context: http://www.nabble.com/Web-application---CURL-and-Cookies--tp20435022p21222728.html Sent from the gambas-user mailing list archive at Nabble.com. From sourceforge-raindog2 at ...94... Tue Dec 30 21:55:34 2008 From: sourceforge-raindog2 at ...94... (Rob) Date: Tue, 30 Dec 2008 15:55:34 -0500 Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <21222728.post@...1379...> References: <20435022.post@...1379...> <200812021542.04023.gambas@...1...> <21222728.post@...1379...> Message-ID: <200812301555.34930.sourceforge-raindog2@...94...> On Tuesday 30 December 2008 15:31, birchy wrote: > 1) Does Gambas implement the libcurl library or does it use curl via a > command prompt? Gambas (specifically gb.net.curl) uses libcurl. > 2) I have still not found a satisfactory HTML parsing library because > many of the values i want to extract are within JavaScript tags. Many > people suggest using BeautifulSoup, but i don't know if i can use this > within Gambas?? I can parse the document manually using string functions If the document you want to parse is XHTML, you could try using gb.xml. Unfortunately, that seems to be undocumented right now. If it's a legacy HTML document, libxml does have an HTML parser available, but it seems that gb.xml doesn't expose that functionality at present so you'd need to use external function declarations to use it. Rob From ronstk at ...239... Tue Dec 30 22:22:54 2008 From: ronstk at ...239... (Ron_1st) Date: Tue, 30 Dec 2008 22:22:54 +0100 Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <200812301555.34930.sourceforge-raindog2@...94...> References: <20435022.post@...1379...> <21222728.post@...1379...> <200812301555.34930.sourceforge-raindog2@...94...> Message-ID: <200812302222.54409.ronstk@...239...> On Tuesday 30 December 2008, Rob wrote: > On Tuesday 30 December 2008 15:31, birchy wrote: > > 1) Does Gambas implement the libcurl library or does it use curl via a > > command prompt? > > Gambas (specifically gb.net.curl) uses libcurl. > > > 2) I have still not found a satisfactory HTML parsing library because > > many of the values i want to extract are within JavaScript tags. Many > > people suggest using BeautifulSoup, but i don't know if i can use this > > within Gambas?? I can parse the document manually using string functions > > If the document you want to parse is XHTML, you could try using gb.xml. > Unfortunately, that seems to be undocumented right now. > > If it's a legacy HTML document, libxml does have an HTML parser available, > but it seems that gb.xml doesn't expose that functionality at present so > you'd need to use external function declarations to use it. > > Rob > I found problems with xml parsing while the html pages are not always valid written but could pass w3c check. Second it needs the XML doctype as first line and that is not available when the page is get from the web. Cold solved by adding yourself of course but then it is also required the tags are lowercase. A global to lowercase cant be done, contest corrupting, and do it for tags and attributes only is just to point how to get them correct. its a part of chicken and egg here. Good 2009 to all Best regards, Ron_1st From pokerbirch at ...1601... Tue Dec 30 22:47:17 2008 From: pokerbirch at ...1601... (birchy) Date: Tue, 30 Dec 2008 13:47:17 -0800 (PST) Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <200812301555.34930.sourceforge-raindog2@...94...> References: <20435022.post@...1379...> <200811111555.45564.gambas@...1...> <200811111601.49341.gambas@...1...> <20759131.post@...1379...> <20791388.post@...1379...> <200812021450.47939.gambas@...1...> <20792906.post@...1379...> <200812021521.52101.gambas@...1...> <20793347.post@...1379...> <200812021542.04023.gambas@...1...> <21222728.post@...1379...> <200812301555.34930.sourceforge-raindog2@...94...> Message-ID: <21223619.post@...1379...> Rob Kudla wrote: > Gambas (specifically gb.net.curl) uses libcurl. Excellent. Regarding cookie handling, gb.net.curl has HttpClient.CookieFile which allows you to define a file for cookies. According to the libcurl tutorial http://curl.netmirror.org/libcurl/c/libcurl-tutorial.html here ('Cookies Without Chocolate Chips'...near the bottom), it says: (libcurl tutorial wrote: > The CURLOPT_COOKIEFILE option also automatically enables the cookie parser > in libcurl. Until the cookie parser is enabled, libcurl will not parse or > understand incoming cookies and they will just be ignored. However, when > the parser is enabled the cookies will be understood and the cookies will > be kept in memory and used properly in subsequent requests when the same > handle is used. Many times this is enough, and you may not have to save > the cookies to disk at all. Note that the file you specify to > CURLOPT_COOKIEFILE doesn't have to exist to enable the parser, so a common > way to just enable the parser and not read able might be to use a file > name you know doesn't exist. I assume that gb.net.curl uses this same behaviour? If so, simply setting ANY value for HttpClient.CookieFile() should enable automatic cookie handling? If this is the case, perhaps an attribute such as HttpClient.AutomateCookies(boolean) could be added in order to remove the need for manual cookie handling? It does the same thing as setting HttpClient.CookieFile() but just makes it much easier to understand. Most of the time, the end user is not actually interested in the cookie data itself...all he or she wants is to maintain a login session by sending the correct cookies. Perhaps a similar automation could be added for handling gzip as well? Again, it's an unnecessary manual job that could be turned into a one liner: HttpClient.AutomateGzip(boolean). All it requires is adding the 'Accept-Encoding: gzip' header to every request and then decompress the response if the 'Content-Encoding: gzip' header is present. Rob Kudla wrote: > you could try using gb.xml. Unfortunately, that seems to be undocumented > right now. As discussed previously in this thread http://www.nabble.com/Re%3A-Web-application---CURL-and-Cookies--p20793152.html here , gb.xml does expose the html parsing element of libxml, however the results are extremely poor. I guess that manual parsing with string functions is the only accurate way to achieve this. -- View this message in context: http://www.nabble.com/Web-application---CURL-and-Cookies--tp20435022p21223619.html Sent from the gambas-user mailing list archive at Nabble.com. From sourceforge-raindog2 at ...94... Tue Dec 30 23:20:52 2008 From: sourceforge-raindog2 at ...94... (Rob) Date: Tue, 30 Dec 2008 17:20:52 -0500 Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <21223619.post@...1379...> References: <20435022.post@...1379...> <200812301555.34930.sourceforge-raindog2@...94...> <21223619.post@...1379...> Message-ID: <200812301720.52548.sourceforge-raindog2@...94...> On Tuesday 30 December 2008 16:47, birchy wrote: > I guess that manual parsing with string functions is the only accurate > way to achieve this. I'd probably try to write a class that wrapped gb.pcre to do that, but I would say that, since I wrote gb.pcre ;) Rob From pokerbirch at ...1601... Wed Dec 31 00:06:11 2008 From: pokerbirch at ...1601... (birchy) Date: Tue, 30 Dec 2008 15:06:11 -0800 (PST) Subject: [Gambas-user] Web application - CURL and Cookies? In-Reply-To: <200812301720.52548.sourceforge-raindog2@...94...> References: <20435022.post@...1379...> <200811111555.45564.gambas@...1...> <200811111601.49341.gambas@...1...> <20759131.post@...1379...> <20791388.post@...1379...> <200812021450.47939.gambas@...1...> <20792906.post@...1379...> <200812021521.52101.gambas@...1...> <20793347.post@...1379...> <200812021542.04023.gambas@...1...> <21222728.post@...1379...> <200812301555.34930.sourceforge-raindog2@...94...> <21223619.post@...1379...> <200812301720.52548.sourceforge-raindog2@...94...> Message-ID: <21224504.post@...1379...> Rob Kudla wrote: > I'd probably try to write a class that wrapped gb.pcre to do that, but I > would say that, since I wrote gb.pcre ;) Well i'd have to learn regex first, but i am already bald, so i have no hair to pull out. :o) What do you think about my other suggestions regarding automating cookie and gzip handling? In this day and age, i'm surprised that we still have to handle them manually. -- View this message in context: http://www.nabble.com/Web-application---CURL-and-Cookies--tp20435022p21224504.html Sent from the gambas-user mailing list archive at Nabble.com. From admin at ...1080... Wed Dec 31 01:44:05 2008 From: admin at ...1080... (werner 007) Date: Tue, 30 Dec 2008 16:44:05 -0800 (PST) Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <200812301523.11188.sourceforge-raindog2@...94...> References: <21216641.post@...1379...> <21216909.post@...1379...> <200812301523.11188.sourceforge-raindog2@...94...> Message-ID: <21225597.post@...1379...> Rob Kudla wrote: > > On Tuesday 30 December 2008 08:03, werner 007 wrote: >> Ok, i got the answer by my self. >> The chars of not printable and non-ascii are represented as Hex. >> To convert it back: > > That'll work, but it'll also run Replace() 160 times each time you do a > conversion. I'd do something like this: > > function urlencode(strin as string) as string > dim strout as string > dim i as integer > dim a as integer > for i = 1 to len(strin) > a = asc(mid(strin, i, 1)) > if a < 33 or a > 126 then > strout = strout & "%" & Hex$(a, 2) > else > strout = strout & mid(strin, i, 1) > endif > next > return strout > end > > Rob > > Hi Rob First when i read your solution i was thinking "damn, i was lazy to make a good job". But then, we are not looking for single chars but for three at once. So i modified your idea to FUNCTION urlencode(strin AS String) AS String DIM strout AS String DIM i AS Integer DIM a AS Integer IF InStr(strin, "%") THEN ' we can safe cpu FOR i = 1 TO Len(strin) IF Mid(strin, i, 1) = "%" THEN ' we can proceed next 2 digits IF IsNumber(Val(Mid(strin, i + 1, 2))) THEN strout &= Chr((CInt(Mid(strin, i + 1, 2)) / 10) * 16) 'convert hex to decimal i = i + 2 ELSE strout = strout & Mid(strin, i, 1) END IF ELSE strout = strout & Mid(strin, i, 1) END IF NEXT END IF RETURN strout END Werner(007) -- View this message in context: http://www.nabble.com/URL-encoding-%22-20%22-tp21216641p21225597.html Sent from the gambas-user mailing list archive at Nabble.com. From nando_f at ...951... Wed Dec 31 03:11:46 2008 From: nando_f at ...951... (nando) Date: Tue, 30 Dec 2008 21:11:46 -0500 Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <21225597.post@...1379...> References: <21216641.post@...1379...> <21216909.post@...1379...> <200812301523.11188.sourceforge-raindog2@...94...> <21225597.post@...1379...> Message-ID: <20081231020655.M81650@...951...> This is what I use. It simply replaces all %?? hex values with the correct char and not just %20 with char$(32). FUNCTION urlencode(s AS String) AS String DIM p AS Integer 'position in string for % DIM h1 AS Integer 'the hex 2 digits, separately DIM h2 AS Integer REPEAT p = Instr(s,"%") 'is there a % in the string IF p > 0 THEN h1 = CInt(Mid(s, p + 1, 1)) 'isolate first of the 2 hex chars h2 = CInt(Mid(s, p + 2, 1)) * 16 'isolate second of the 2 hex chars s = Left$(s, p - 1) & Chr$(h1 + h2) & Mid$(s, p + 3) 'recombine result ENDIF UNTIL p=0 RETURN s END ---------- Original Message ----------- From: werner 007 To: gambas-user at lists.sourceforge.net Sent: Tue, 30 Dec 2008 16:44:05 -0800 (PST) Subject: Re: [Gambas-user] URL encoding "%20" > Rob Kudla wrote: > > > > On Tuesday 30 December 2008 08:03, werner 007 wrote: > >> Ok, i got the answer by my self. > >> The chars of not printable and non-ascii are represented as Hex. > >> To convert it back: > > > > That'll work, but it'll also run Replace() 160 times each time you do a > > conversion. I'd do something like this: > > > > function urlencode(strin as string) as string > > dim strout as string > > dim i as integer > > dim a as integer > > for i = 1 to len(strin) > > a = asc(mid(strin, i, 1)) > > if a < 33 or a > 126 then > > strout = strout & "%" & Hex$(a, 2) > > else > > strout = strout & mid(strin, i, 1) > > endif > > next > > return strout > > end > > > > Rob > > > > > > Hi Rob > > First when i read your solution i was thinking "damn, i was lazy to make a > good job". > But then, we are not looking for single chars but for three at once. > So i modified your idea to > > FUNCTION urlencode(strin AS String) AS String > DIM strout AS String > DIM i AS Integer > DIM a AS Integer > IF InStr(strin, "%") THEN ' we can safe cpu > FOR i = 1 TO Len(strin) > IF Mid(strin, i, 1) = "%" THEN ' we can proceed next 2 digits > IF IsNumber(Val(Mid(strin, i + 1, 2))) THEN > strout &= Chr((CInt(Mid(strin, i + 1, 2)) / 10) * 16) 'convert hex > to decimal > i = i + 2 > ELSE > strout = strout & Mid(strin, i, 1) > END IF > ELSE > strout = strout & Mid(strin, i, 1) > END IF > NEXT > END IF > RETURN strout > END > > Werner(007) > > -- > View this message in context: http://www.nabble.com/URL-encoding-%22-20%22-tp21216641p21225597.html > Sent from the gambas-user mailing list archive at Nabble.com. > > ------------------------------------------------------------------------------ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From sourceforge-raindog2 at ...94... Wed Dec 31 03:26:04 2008 From: sourceforge-raindog2 at ...94... (Rob) Date: Tue, 30 Dec 2008 21:26:04 -0500 Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <21225597.post@...1379...> References: <21216641.post@...1379...> <200812301523.11188.sourceforge-raindog2@...94...> <21225597.post@...1379...> Message-ID: <200812302126.04251.sourceforge-raindog2@...94...> On Tuesday 30 December 2008 19:44, werner 007 wrote: > First when i read your solution i was thinking "damn, i was lazy to make > a good job". > But then, we are not looking for single chars but for three at once. I misunderstood you, then. URL encoding is replacing non-printable characters with %xx. URL DEcoding is replacing %xx with the original non-printable character. What I wrote will be fine for encoding and what you wrote in this response will be fine if you rename the function to "urldecode". Rob From doriano.blengino at ...1909... Wed Dec 31 08:59:15 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 31 Dec 2008 08:59:15 +0100 Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <200812302126.04251.sourceforge-raindog2@...94...> References: <21216641.post@...1379...> <200812301523.11188.sourceforge-raindog2@...94...> <21225597.post@...1379...> <200812302126.04251.sourceforge-raindog2@...94...> Message-ID: <495B2653.6030504@...1909...> Rob ha scritto: > On Tuesday 30 December 2008 19:44, werner 007 wrote: > >> First when i read your solution i was thinking "damn, i was lazy to make >> a good job". >> But then, we are not looking for single chars but for three at once. >> > > I misunderstood you, then. URL encoding is replacing non-printable > characters with %xx. URL DEcoding is replacing %xx with the original > non-printable character. What I wrote will be fine for encoding and what > you wrote in this response will be fine if you rename the function > to "urldecode". > > ...and don't forget that URL's ENcoding and DEcoding deals with other characters too (not merely the non-printable ones), for example the "%" itself should be encoded, and probably others (I don't have the specs at hands). The correct ENcoding of " % " (blank-percent-blank) is "%20%25%20", *not* "%20%%20"... -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From gambas at ...1... Wed Dec 31 10:22:15 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 31 Dec 2008 10:22:15 +0100 Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <495B2653.6030504@...1909...> References: <21216641.post@...1379...> <200812302126.04251.sourceforge-raindog2@...94...> <495B2653.6030504@...1909...> Message-ID: <200812311022.16176.gambas@...1...> On mercredi 31 d?cembre 2008, Doriano Blengino wrote: > Rob ha scritto: > > On Tuesday 30 December 2008 19:44, werner 007 wrote: > >> First when i read your solution i was thinking "damn, i was lazy to make > >> a good job". > >> But then, we are not looking for single chars but for three at once. > > > > I misunderstood you, then. URL encoding is replacing non-printable > > characters with %xx. URL DEcoding is replacing %xx with the original > > non-printable character. What I wrote will be fine for encoding and what > > you wrote in this response will be fine if you rename the function > > to "urldecode". > > ...and don't forget that URL's ENcoding and DEcoding deals with other > characters too (not merely the non-printable ones), for example the "%" > itself should be encoded, and probably others (I don't have the specs at > hands). The correct ENcoding of " % " (blank-percent-blank) is > "%20%25%20", *not* "%20%%20"... You have CGI.Encode() and CGI.Decode() in the gb.web component that do what you are talking about. You can take the source code if you need. Regards, -- Benoit Minisini From gambas at ...1... Wed Dec 31 17:06:47 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 31 Dec 2008 17:06:47 +0100 Subject: [Gambas-user] Another present! Message-ID: <200812311706.47320.gambas@...1...> Hi, After the gb.image.info component, here is a new present, for the new year: `` Automatic shortcut configuration '' Well, what's that? As soon as you use the gb.form.mdi component, and that you define the Action property of all menus / buttons accordingly, you just have to call the Action.Configure() static method to get a dialog box that allows the user to configure the application shortcuts. Shortcuts are associated with action names, *without* the optional dot at the beginning. Reminder: action names beginning with a dot are local actions. See the wiki page on the Action class for more details. The IDE implements that, so that you can see it. There are some caveats: - Shortcuts work only if there is a menu entry associated with the action. - Shortcut action names are not translated yet. A new function is needed in Gambas for that. - Shortcuts are initialized each time a form is opened. Not created. That leads to useless work when your form is persistent. - The list of actions is stored by the IDE in a folder named ".action" when a form is saved to the disk. If you want to use Action.Configure() in an already existing project, you must use the "Update all forms" menu entry in the IDE to force the saving of all forms and generate all action files. - Actions having the same name must have the same shortcut. Even if they are local actions of different forms. This is not really a caveat, as this makes things logical to the user. All that is in Gambas 3, revision #1758. Enjoy it, and report bugs as usual! -- Benoit Minisini From admin at ...1080... Wed Dec 31 18:14:21 2008 From: admin at ...1080... (werner 007) Date: Wed, 31 Dec 2008 09:14:21 -0800 (PST) Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <200812311022.16176.gambas@...1...> References: <21216641.post@...1379...> <21216909.post@...1379...> <200812301523.11188.sourceforge-raindog2@...94...> <21225597.post@...1379...> <200812302126.04251.sourceforge-raindog2@...94...> <495B2653.6030504@...1909...> <200812311022.16176.gambas@...1...> Message-ID: <21234409.post@...1379...> @Rob: Yes you are right. @Benoit: Thanks @Doriano: http://www.blooberry.com/indexdot/html/topics/urlencoding.htm @Nando: All the samples does not only %20 ;) Wish a good New Year to all Regards, Werner(007) -- View this message in context: http://www.nabble.com/URL-encoding-%22-20%22-tp21216641p21234409.html Sent from the gambas-user mailing list archive at Nabble.com. From doriano.blengino at ...1909... Wed Dec 31 18:54:12 2008 From: doriano.blengino at ...1909... (Doriano Blengino) Date: Wed, 31 Dec 2008 18:54:12 +0100 Subject: [Gambas-user] gambas-mpg123player In-Reply-To: References: Message-ID: <495BB1C4.20409@...1909...> Demosthenes Koptsis ha scritto: > Hi list, > > i wrote a simple front-end for mpg123 console player in gambas2, > have a look > > http://gambas-mpg123pl.sourceforge.net/index.html > Had a look to your application; simple but effective. If I didn't have Beep Media Player, now I could use your application; only misses an equalizer... and perhaps smaller buttons. I like front-ends because they are easy to make and works nicely; I made some time ago a front-end for mplayer under windows, and now I cannot use anything else. Clearly, I made it exactly as I liked it, but I've never seen things like aspect ratio correction (5% wider because my LCD has not square pixels), or automatic rescaling (open a 320x240, and a 800x600 video: why the heck they should have different sizes when viewing?) in other players. So, put in your program the mandatory things (don't know if a equalizer is), add some unique feature (a song search function, for example - the normal open file dialog box is too limited for this kind of things, and no players are smart enough to add something more functional), and people will start to use your application. Only one thing to say: the install procedure is a little brute: it overwrites libraries without confirmation - dangerous. Probably you know that the gambas IDE can generate install packages (.deb, .rpm and others), this could be an improvement. This is my opinion only - take it easy... Cheers and happy 2009, -- Doriano Blengino "Listen twice before you speak. This is why we have two ears, but only one mouth." From nando_f at ...951... Wed Dec 31 20:07:01 2008 From: nando_f at ...951... (nando) Date: Wed, 31 Dec 2008 14:07:01 -0500 Subject: [Gambas-user] URL encoding "%20" In-Reply-To: <21234409.post@...1379...> References: <21216641.post@...1379...> <21216909.post@...1379...> <200812301523.11188.sourceforge-raindog2@...94...> <21225597.post@...1379...> <200812302126.04251.sourceforge-raindog2@...94...> <495B2653.6030504@...1909...> <200812311022.16176.gambas@...1...> <21234409.post@...1379...> Message-ID: <20081231190523.M55322@...951...> Quite funny! Mine was called decodeurl but I cut and pasted your function name without even thinking the opposite meaning. Very funny indeed! Everyone, have a drink and make it worth it! Happy New Year ---------- Original Message ----------- From: werner 007 To: gambas-user at lists.sourceforge.net Sent: Wed, 31 Dec 2008 09:14:21 -0800 (PST) Subject: Re: [Gambas-user] URL encoding "%20" > @Rob: Yes you are right. > @Benoit: Thanks > @Doriano: http://www.blooberry.com/indexdot/html/topics/urlencoding.htm > @Nando: All the samples does not only %20 ;) > > Wish a good New Year to all > > Regards, Werner(007) > -- > View this message in context: http://www.nabble.com/URL-encoding-%22-20%22-tp21216641p21234409.html > Sent from the gambas-user mailing list archive at Nabble.com. > > ------------------------------------------------------------------------------ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message -------