From pokerbirch at ...612... Thu Nov 6 14:43:56 2008 From: pokerbirch at ...612... (birchy) Date: Thu, 6 Nov 2008 05:43:56 -0800 (PST) Subject: [Gambas-devel] A suggestion for multi platform Gambas Message-ID: <20360749.post@...565...> I've just discovered that you do not need to know Java syntax in order to write a program that compiles and runs on the Java Virtual Machine. So the obvious question is: could Gambas be made to compile and run on the JVM which would make it multi-platform without having to do any O.S. specific coding? -- View this message in context: http://www.nabble.com/A-suggestion-for-multi-platform-Gambas-tp20360749p20360749.html Sent from the gambas-devel mailing list archive at Nabble.com. From henrique.andreassy at ...241... Thu Nov 6 14:46:21 2008 From: henrique.andreassy at ...241... (=?utf-8?B?RWRpc29uIEhlbnJpcXVlIEFuZHJlYXNzeSAoQ2V0aWwgLSBTdXBvcnRlIFTDqWNuaWNvKQ==?=) Date: Thu, 06 Nov 2008 11:46:21 -0200 Subject: [Gambas-devel] A suggestion for multi platform Gambas Message-ID: <963009994@...241...> Esse funcion?rio temporariamente n?o estar? acessando seus e-mails, os quais entretanto est?o sendo recebidos e armazenados em sua caixa postal. Posteriormente, quando de seu retorno ? empresa, o destinat?rio ir? acess?-los. Caso haja necessidade urgente, entre em contato com outro colaborador da mesma equipe. From gambas at ...1... Thu Nov 6 14:46:43 2008 From: gambas at ...1... (Benoit Minisini) Date: Thu, 6 Nov 2008 14:46:43 +0100 Subject: [Gambas-devel] A suggestion for multi platform Gambas In-Reply-To: <20360749.post@...565...> References: <20360749.post@...565...> Message-ID: <200811061446.43466.gambas@...1...> On jeudi 6 novembre 2008, birchy wrote: > I've just discovered that you do not need to know Java syntax in order to > write a program that compiles and runs on the Java Virtual Machine. So the > obvious question is: could Gambas be made to compile and run on the JVM > which would make it multi-platform without having to do any O.S. specific > coding? The answer is globally no, because they are features inside the Gambas interpreter that do not exist in Java, AFAIK. -- Benoit Minisini From pokerbirch at ...612... Thu Nov 6 15:43:19 2008 From: pokerbirch at ...612... (birchy) Date: Thu, 6 Nov 2008 06:43:19 -0800 (PST) Subject: [Gambas-devel] A suggestion for multi platform Gambas In-Reply-To: <200811061446.43466.gambas@...1...> References: <20360749.post@...565...> <200811061446.43466.gambas@...1...> Message-ID: <20362363.post@...565...> Bugzilla from gambas at ...1... wrote: > The answer is globally no, because they are features inside the Gambas > interpreter that do not exist in Java, AFAIK. Ok, fair comment. It was just a crazy idea i had. Keep up the good work, i'm new to Gambas but really enjoying it since i turned my back on all things M$. -- View this message in context: http://www.nabble.com/A-suggestion-for-multi-platform-Gambas-tp20360749p20362363.html Sent from the gambas-devel mailing list archive at Nabble.com. From gambas.fr at ...176... Thu Nov 6 15:54:52 2008 From: gambas.fr at ...176... (Fabien Bodard) Date: Thu, 6 Nov 2008 15:54:52 +0100 Subject: [Gambas-devel] A suggestion for multi platform Gambas In-Reply-To: <20362363.post@...565...> References: <20360749.post@...565...> <200811061446.43466.gambas@...1...> <20362363.post@...565...> Message-ID: <6324a42a0811060654y1806b684yb7fa27f8107bd27e@...178...> M$ have not all so bad ... just their systems and some coding tools hare to put in the trash... 2008/11/6 birchy : > > > Bugzilla from gambas at ...1... wrote: >> The answer is globally no, because they are features inside the Gambas >> interpreter that do not exist in Java, AFAIK. > > Ok, fair comment. It was just a crazy idea i had. > > Keep up the good work, i'm new to Gambas but really enjoying it since i > turned my back on all things M$. > -- > View this message in context: http://www.nabble.com/A-suggestion-for-multi-platform-Gambas-tp20360749p20362363.html > Sent from the gambas-devel mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------- > 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-devel mailing list > Gambas-devel at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-devel > From gambas.fr at ...176... Fri Nov 7 15:15:05 2008 From: gambas.fr at ...176... (Fabien Bodard) Date: Fri, 7 Nov 2008 15:15:05 +0100 Subject: [Gambas-devel] Some new littles things Message-ID: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> Hi benoit , I've done some little things that copy some py libs... like the openUrl. Did you think we can make some gb.lib extention that contain that ? for exemple that allow to extend the File class with a new function File.LoadUrl(Url, Proxy) This function allow to to read directly a web page in one shot. and return it in a string Really usefull to parse web page. It's juste one function for now but i'm sure i will find more of them :) Fabien From pokerbirch at ...612... Fri Nov 7 15:35:16 2008 From: pokerbirch at ...612... (birchy) Date: Fri, 7 Nov 2008 06:35:16 -0800 (PST) Subject: [Gambas-devel] Some new littles things In-Reply-To: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> References: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> Message-ID: <20381709.post@...565...> Fabien Bodard-4 wrote: > This function allow to to read directly a web page in one shot. and > return it in a string You have read my mind! This is exactly the kind of tool that i would use in a LOT of my projects. At the moment i am using the HttpClient of gb.web.curl. A HTML parsing library would be excellent, but i don't know how easy it would be to write one as html is not as uniform as xml. -- View this message in context: http://www.nabble.com/Some-new-littles-things-tp20381324p20381709.html Sent from the gambas-devel mailing list archive at Nabble.com. From ron at ...572... Fri Nov 7 15:54:27 2008 From: ron at ...572... (Ron) Date: Fri, 07 Nov 2008 15:54:27 +0100 Subject: [Gambas-devel] Some new littles things In-Reply-To: <20381709.post@...565...> References: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> <20381709.post@...565...> Message-ID: <491456A3.6080605@...572...> birchy schreef: > Fabien Bodard-4 wrote: > >> This function allow to to read directly a web page in one shot. and >> return it in a string >> > > You have read my mind! This is exactly the kind of tool that i would use in > a LOT of my projects. At the moment i am using the HttpClient of > gb.web.curl. A HTML parsing library would be excellent, but i don't know how > easy it would be to write one as html is not as uniform as xml. > I have these kind of routines in my code too, would be nice if those where standard. Regards. From gambas at ...1... Fri Nov 7 15:57:38 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 7 Nov 2008 15:57:38 +0100 Subject: [Gambas-devel] Some new littles things In-Reply-To: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> References: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> Message-ID: <200811071557.38348.gambas@...1...> On vendredi 7 novembre 2008, Fabien Bodard wrote: > Hi benoit , > > I've done some little things that copy some py libs... like the openUrl. > > Did you think we can make some gb.lib extention that contain that ? > > for exemple that allow to extend the File class with a new function > File.LoadUrl(Url, Proxy) > > This function allow to to read directly a web page in one shot. and > return it in a string > > Really usefull to parse web page. > > It's juste one function for now but i'm sure i will find more of them :) > > Fabien > What is the problem with using HttpClient in gb.net.curl? -- Benoit Minisini From gambas.fr at ...176... Fri Nov 7 16:03:56 2008 From: gambas.fr at ...176... (Fabien Bodard) Date: Fri, 7 Nov 2008 16:03:56 +0100 Subject: [Gambas-devel] Some new littles things In-Reply-To: <200811071557.38348.gambas@...1...> References: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> <200811071557.38348.gambas@...1...> Message-ID: <6324a42a0811070703p4f6ae611lbdd4b3fa9f65232f@...178...> 2008/11/7 Benoit Minisini : > On vendredi 7 novembre 2008, Fabien Bodard wrote: >> Hi benoit , >> >> I've done some little things that copy some py libs... like the openUrl. >> >> Did you think we can make some gb.lib extention that contain that ? >> >> for exemple that allow to extend the File class with a new function >> File.LoadUrl(Url, Proxy) >> >> This function allow to to read directly a web page in one shot. and >> return it in a string >> >> Really usefull to parse web page. >> >> It's juste one function for now but i'm sure i will find more of them :) >> >> Fabien >> > > What is the problem with using HttpClient in gb.net.curl? > > -- > 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-devel mailing list > Gambas-devel at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-devel > Nothing ... in fact i was just reallise that this kind of extention must be in the HttpClient Itself From pokerbirch at ...612... Fri Nov 7 16:36:51 2008 From: pokerbirch at ...612... (birchy) Date: Fri, 7 Nov 2008 07:36:51 -0800 (PST) Subject: [Gambas-devel] Some new littles things In-Reply-To: <200811071557.38348.gambas@...1...> References: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> <200811071557.38348.gambas@...1...> Message-ID: <20382898.post@...565...> Bugzilla from gambas at ...1... wrote: > What is the problem with using HttpClient in gb.net.curl? That is what i'm currently using and it seems to work ok. I think that curl can handle cookies and therefore gb should also have this ability? I'd also like to be able to set headers other than the "user-agent" but this doesn't seem to be available? And what about gZip? How would i set the "Accept-Encoding: gzip" header and implement gZip decompression within my http routines? The documentation seems incomplete. Does gb.net.curl use ALL of the curl features? -- View this message in context: http://www.nabble.com/Some-new-littles-things-tp20381324p20382898.html Sent from the gambas-devel mailing list archive at Nabble.com. From ronstk at ...124... Fri Nov 7 16:57:28 2008 From: ronstk at ...124... (Ron Onstenk) Date: Fri, 7 Nov 2008 17:57:28 +0200 Subject: [Gambas-devel] Some new littles things In-Reply-To: <20381709.post@...565...> References: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> <20381709.post@...565...> Message-ID: <200811071657.28956.ronstk@...124...> On Friday 07 November 2008, birchy wrote: > > Fabien Bodard-4 wrote: > > This function allow to to read directly a web page in one shot. and > > return it in a string Not realy. how about the required cookies, passing variable to the site like http://www.google.fr/?q=gambas+HttpClient&l=fr_FR with cookies telling the porno save search method in you preferences. > > You have read my mind! This is exactly the kind of tool that i would use in > a LOT of my projects. As in the linux world everything is a file the file component main usage is file storage as files on the hdd. > At the moment i am using the HttpClient of > gb.web.curl. Correct while this component gb.net.curl is build for handling this kind of files. This accepts fragmented files from the server as the file component can't do. > A HTML parsing library would be excellent, but i don't know how > easy it would be to write one as html is not as uniform as xml. html is xml but xml is not html. With the in

underlined bold text

despite it works almost the U and B tags must be inside the P, secondly the closing U and B are reverse order as the open. In this example the strict.dtd should fail but transitional may work. In fact it is not that HTML is not uniform or the parser but the website developer is the bad guy :) I'v seen this kind of code also in web pages made with non webpage editors as MS Word (play a little with colorize, U and B and you see the carbage result. About easy, it will not be the case in respect to invent all the variations you hit. A good example to look how complex it can be is the source of firefox. What you want is the DOM representation. The only thing I see is usage of the KHTML(gecko) library available in the web component. Just what we need is a multi dimension array containing the DOM or a gambas interface to request objects from the DOM and is partial alread in the xml component. In VB this is the WebBrowser and WebBrowser2 component. Just my 2 cents Ron 1st From gambas at ...1... Wed Nov 12 17:00:45 2008 From: gambas at ...1... (Benoit Minisini) Date: Wed, 12 Nov 2008 17:00:45 +0100 Subject: [Gambas-devel] Some new littles things In-Reply-To: <20382898.post@...565...> References: <6324a42a0811070615k313d44abp50fcebfdc2022e25@...178...> <200811071557.38348.gambas@...1...> <20382898.post@...565...> Message-ID: <200811121700.45981.gambas@...1...> On vendredi 7 novembre 2008, birchy wrote: > Bugzilla from gambas at ...1... wrote: > > What is the problem with using HttpClient in gb.net.curl? > > That is what i'm currently using and it seems to work ok. I think that curl > can handle cookies and therefore gb should also have this ability? I'd also > like to be able to set headers other than the "user-agent" but this doesn't > seem to be available? And what about gZip? How would i set the > "Accept-Encoding: gzip" header and implement gZip decompression within my > http routines? The documentation seems incomplete. Does gb.net.curl use ALL > of the curl features? As stated in the similar thread on the user mailing-list: HttpClient.CookieFile allows you to define a file where cookies will be read. And HttpClient.UpdateCookies should tell if the previous file will be updated during the HTTP request. gb.xml already know how to parse HTML. The XMLDocument class has a 'HTMLFromString' method for that. As for gzip encoding, I don't know if HttpClient can deal with that. A test is needed. Regards, -- Benoit Minisini From henrique.andreassy at ...241... Wed Nov 12 17:02:27 2008 From: henrique.andreassy at ...241... (=?utf-8?B?RWRpc29uIEhlbnJpcXVlIEFuZHJlYXNzeSAoQ2V0aWwgLSBTdXBvcnRlIFTDqWNuaWNvKQ==?=) Date: Wed, 12 Nov 2008 14:02:27 -0200 Subject: [Gambas-devel] Some new littles things Message-ID: <963407949@...241...> Esse funcion?rio temporariamente n?o estar? acessando seus e-mails, os quais entretanto est?o sendo recebidos e armazenados em sua caixa postal. Posteriormente, quando de seu retorno ? empresa, o destinat?rio ir? acess?-los. Caso haja necessidade urgente, entre em contato com outro colaborador da mesma equipe. From gambas at ...1... Fri Nov 21 13:32:51 2008 From: gambas at ...1... (Benoit Minisini) Date: Fri, 21 Nov 2008 13:32:51 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] Image help. In-Reply-To: <1227018352.4922d0701484e@...614...> References: <1227018352.4922d0701484e@...614...> Message-ID: <200811211332.51369.gambas@...1...> On mardi 18 novembre 2008, Wellington de Souza Pinto wrote: > Hi! > > My english is not very well, but i'm need help. > > > I have this functions and yours returns > > unsigned char *wimg; > wimg = fp_img_get_data(img); > > // This function Return my image in map of bits > // For understand! if i write an file in this mode work fine (This > is write for .pgm format) > > ... > width = fp_img_get_width(img); > height = fp_img_get_height(img); > > r = fprintf(fd, "P5 %d %d 255\n", width, height); > if (r < 0) { > printf("pgm header write failed, error %d", r); > return r; > } > > size_t write_size = width * height; > > r = fwrite(wimg, 1, write_size, fd); > if (r < write_size) { > printf("short write (%d)", r); > return -1; > } > > fclose(fd); > ... > > How to i convert the type (wimg) for use with GB.ReturnObject() > function? I'm need return an image. > > My C hability is not very well yet. > > Reguars, > > any ideia (wspinto at ...613...) > First: do not send e-mails to the developer svn mailing-list, this mailing-list is just for getting svn commit reports. Second: you should enhance your C habilities, otherwise you may not understand the following. Let's start the explanation anyway... You can't return a C pointer directly, Gambas can't use it. GB.ReturnObject() returns a Gambas object. If you want to use a C (or a C++) pointer that points at something useful through a Gambas object, you must reference the pointer inside the Gambas object structure. For example, the Control Gambas object has a pointer to the internal Qt widget C++ object. Then, you must take care about the life of your object: - When the Gambas object is destroyed, then the underlying C or C++ object must be freed. - When the underlying C/C++ object is freed by the library (not by the Gambas interpreter), your code must catch it, and makes the object invalid. You do that by: storing NULL in the C/C++ pointer located in the Gambas object structure, and use the GB_HOOK_CHECK() macro to implement a check function that returns TRUE when the Gambas object is invalid, i.e. then the previous pointer is NULL. I suggest you read the source code of a simple component, like gb.eval, to see how the basic things work. An example of GB_HOOK_CHECK() is located in the CWidget.cpp file on the gb.qt source code. As for the GB.Image() lack of documentation: the documentation is old, it is for Gambas 1. If I have time, I will try to complete the documentation. But if you had explain what you did exactly, I would have talked about these API functions before you find them by yourself. Regards, -- Benoit Minisini From henrique.andreassy at ...241... Fri Nov 21 13:34:20 2008 From: henrique.andreassy at ...241... (=?utf-8?B?RWRpc29uIEhlbnJpcXVlIEFuZHJlYXNzeSAoQ2V0aWwgLSBTdXBvcnRlIFTDqWNuaWNvKQ==?=) Date: Fri, 21 Nov 2008 10:34:20 -0200 Subject: [Gambas-devel] [Gambas-devel-svn] Image help. Message-ID: <963990602@...241...> Esse funcion?rio temporariamente n?o estar? acessando seus e-mails, os quais entretanto est?o sendo recebidos e armazenados em sua caixa postal. Posteriormente, quando de seu retorno ? empresa, o destinat?rio ir? acess?-los. Caso haja necessidade urgente, entre em contato com outro colaborador da mesma equipe. From pokerbirch at ...612... Sat Nov 29 21:03:22 2008 From: pokerbirch at ...612... (birchy) Date: Sat, 29 Nov 2008 12:03:22 -0800 (PST) Subject: [Gambas-devel] Component request: SOAP Web Services Message-ID: <20750861.post@...565...> As posted in http://www.nabble.com/Web-Services%3A-Working-with-WSDL-td20328779.html THIS gambas-user thread, i have an interest in using Gambas for my internet related projects. http://www.w3schools.com/soap/default.aspl SOAP is a W3C standard protocol that has become VERY common for interacting with web information services, for example: Google, Amazon, Paypal, Ebay, Microsoft, Betfair, etc, all offer SOAP based API. Many programming languages such as http://wiki.netbeans.org/SOAPNetBeans6 Java , http://www.codeproject.com/KB/XML/soap12inNet20.aspx .Net and http://developer.apple.com/internet/webservices/soapphp.html PHP offer automatic code/class generation for SOAP Web Services, and i would like to see this feature available in Gambas. I have spent a lot of time researching various methods that would allow Gambas to have Web Services and by far the simplest appears to be the open source http://www.cs.fsu.edu/~engelen/soap.html gSOAP library which is both multi platform AND included in most Linux repositories. In similar fashion to the above named languages, this lib auto-generates both XML files AND C/C++ code from a given http://en.wikipedia.org/wiki/Web_Services_Description_Language WSDL file. I am not familiar with C/C++ code but i believe that this lib would be a perfect base for a Gambas Web Services component?? Would anyone else be interested in this component? -- View this message in context: http://www.nabble.com/Component-request%3A-SOAP-Web-Services-tp20750861p20750861.html Sent from the gambas-devel mailing list archive at Nabble.com.