From otto at ...631... Fri Apr 3 20:16:35 2009 From: otto at ...631... (ottod) Date: Fri, 3 Apr 2009 11:16:35 -0700 (PDT) Subject: [Gambas-devel] Just a wild thought Message-ID: <22873888.post@...565...> I am trying to get the feel of Scala, this Java cousin that promises scripting-language-like terse syntax and support for functional programming. It is a very nice language but I think a little on the side of a write-only language. I love Gambas Basic incarnation, very well modeled. Then I find all over sites I visit, that Java is well entrenched in the server side and trying to get some desktop side usage; that .Net is coming from the reverse road, well used on the desktop and trying to steal some of Java space on the server. Many people reject the idea of desktop apps, saying web apps is the way to go, but that at least is contradictory, as the browser itself is a desktop app. If you make me choose between Vb.net and Gambas for desktop development, I choose Gambas without thinking twice. I do not even consider Java, as for me is like trying to write a business app in C. I have been programming 25 years and for a business app my ideal environment is something in the line of Foxpro (DOS, Win16, and Win32 versions) and Access. Data bound controls, reporting, powerful and easy validations, visual grids for display, easy database querying (people look strange at me when I tell them LINQ comes from Fox and was there since the 80's). Now, where is this post heading? Gambas is missing a full working report component. The language is very nice, the IDE is the best sample program I have seen for a language. But I think many things are being reinvented here because Gambas is an island. gb.pdf, gb.report, gb.db.*. With Scala I have seen them implement the language and the interpreter on top of the JVM, the compiler generating Java bytecodes, and the language allowing transparent access to Java massive amount of code from the last decade. So I get a nice language, much like Paris Hilton, nice looking and with many resources just inherited from the past. Some people on the Scala lists just hope that Scala will be THE LANGUAGE for desktop Java development but I think some years of work are required to get there. Now the question. Please give me your opinions, pragmatic please, not just theoretical. You Gambas code gurus, you Master Benoit (sorry I do not know how to write your name in the right way from a Spanish keyboard): can the Gambas compiler and interpreter be ported to Java instead of C and plug to Java components instead of OS/library components? "CAN" being asked in the sense of a practical time frame and programming talent, not in the sense of Turing machine possibility... I mean, what if we could get JasperReports and iReport Java components for free and consider finished the gb.report component to dedicate resources to other more interesting problems? gb.qt and gt.gtk replaced by Swing, but hidden beneath gb.gui and the layout done with the lovely Gambas IDE? Side effects as the possibility of running on Mac and Windows? Scala, jRuby have shown that the real value of Java is not the language as it is the platform itself. jRuby runs faster and safer on the JVM than Ruby's C based VM. Ruby's source code is not Valgrind safe so when running production code one does not know how it will behave. I read somewhere in the Gambas site that Gambas is almost half a million lines of code. How much of it is core and how much is supporting components? Is there something in Gambas architecture that will make this truly hard or mostly impossible? I am testing the waters, maybe from your comments I get the drive... -- View this message in context: http://www.nabble.com/Just-a-wild-thought-tp22873888p22873888.html Sent from the gambas-devel mailing list archive at Nabble.com. From sourceforge-raindog2 at ...19... Fri Apr 3 20:50:58 2009 From: sourceforge-raindog2 at ...19... (Rob) Date: Fri, 3 Apr 2009 14:50:58 -0400 Subject: [Gambas-devel] Just a wild thought In-Reply-To: <22873888.post@...565...> References: <22873888.post@...565...> Message-ID: <200904031450.58619.sourceforge-raindog2@...19...> On Friday 03 April 2009 14:16, ottod wrote: > Many people reject the > idea of desktop apps, saying web apps is the way to go, but that at > least is contradictory, as the browser itself is a desktop app. The browser is more than a desktop app; I can write a web app in any one of dozens of server languages, including Gambas (though on the browser side I can use any language I like as long as it's Javascript) and have it work on a desktop, an ARM-based $150 netbook, an iPhone and a Wii, and if I'm careful, my 5-year-old freebie cell phone as well. There is no other development language or framework for which that's true. Except for hardware-intensive programs like DVD burners and higher-end games, and despite repeated attempts by Microsoft such as VBscript, ActiveX and Silverlight to make web apps require one particular operating system, I think that a majority of development will be web development in the next 5 years -- if it's not true already. > keyboard): can the Gambas compiler and interpreter be ported to Java > instead of C and plug to Java components instead of OS/library > components? "CAN" being asked in the sense of a practical time frame and Richard Stallman made the same suggestion a few years ago. I disagreed with him then and I still do. I can't speak for Benoit, but I think it would be a redundant effort considering how many BASIC dialects for the Java virtual machine there already are: http://www.is-research.de/info/vmlanguages/basic/ Personally, Gambas' object model and component design philosophy (expose all you can but don't make it feel like a C API, basically) is more appealing to me than its syntax, which is kind of verbose for me as a Perl programmer but just right for a newbie. Just as when Microsoft terminated Visual Basic and created VB.NET as a vaguely similar but fundamentally different language, the resulting language wouldn't be Gambas anymore, but just another BASIC-like syntax overlay for Java. Rob From gambas at ...1... Fri Apr 3 21:15:21 2009 From: gambas at ...1... (=?iso-8859-1?q?Beno=EEt_Minisini?=) Date: Fri, 3 Apr 2009 21:15:21 +0200 Subject: [Gambas-devel] Just a wild thought In-Reply-To: <22873888.post@...565...> References: <22873888.post@...565...> Message-ID: <200904032115.22422.gambas@...1...> > I am trying to get the feel of Scala, this Java cousin that promises > scripting-language-like terse syntax and support for functional > programming. It is a very nice language but I think a little on the side of > a write-only language. I love Gambas Basic incarnation, very well modeled. > Then I find all over sites I visit, that Java is well entrenched in the > server side and trying to get some desktop side usage; that .Net is coming > from the reverse road, well used on the desktop and trying to steal some of > Java space on the server. Many people reject the idea of desktop apps, > saying web apps is the way to go, but that at least is contradictory, as > the browser itself is a desktop app. If you make me choose between Vb.net > and Gambas for desktop development, I choose Gambas without thinking twice. > I do not even consider Java, as for me is like trying to write a business > app in C. I have been programming 25 years and for a business app my ideal > environment is something in the line of Foxpro (DOS, Win16, and Win32 > versions) and Access. Data bound controls, reporting, powerful and easy > validations, visual grids for display, easy database querying (people look > strange at me when I tell them LINQ comes from Fox and was there since the > 80's). > Now, where is this post heading? Gambas is missing a full working report > component. The language is very nice, the IDE is the best sample program I > have seen for a language. But I think many things are being reinvented here > because Gambas is an island. gb.pdf, gb.report, gb.db.*. With Scala I have > seen them implement the language and the interpreter on top of the JVM, the > compiler generating Java bytecodes, and the language allowing transparent > access to Java massive amount of code from the last decade. So I get a nice > language, much like Paris Hilton, nice looking and with many resources just > inherited from the past. Some people on the Scala lists just hope that > Scala will be THE LANGUAGE for desktop Java development but I think some > years of work are required to get there. > Now the question. Please give me your opinions, pragmatic please, not just > theoretical. You Gambas code gurus, you Master Benoit (sorry I do not know > how to write your name in the right way from a Spanish keyboard): can the > Gambas compiler and interpreter be ported to Java instead of C and plug to > Java components instead of OS/library components? "CAN" being asked in the > sense of a practical time frame and programming talent, not in the sense of > Turing machine possibility... > I mean, what if we could get JasperReports and iReport Java components for > free and consider finished the gb.report component to dedicate resources to > other more interesting problems? gb.qt and gt.gtk replaced by Swing, but > hidden beneath gb.gui and the layout done with the lovely Gambas IDE? Side > effects as the possibility of running on Mac and Windows? Scala, jRuby have > shown that the real value of Java is not the language as it is the platform > itself. jRuby runs faster and safer on the JVM than Ruby's C based VM. > Ruby's source code is not Valgrind safe so when running production code one > does not know how it will behave. > I read somewhere in the Gambas site that Gambas is almost half a million > lines of code. How much of it is core and how much is supporting > components? Is there something in Gambas architecture that will make this > truly hard or mostly impossible? I am testing the waters, maybe from your > comments I get the drive... I think that the Java Virtual Machine misses some features needed by the Gambas language. In other words, Gambas is internaly a too dynamic language for the JVM. A Gambas class can be compiled without any explicit reference to anything declared somewhere else. In Java, you cannot do that, you must use the "import" keyword - But tell me if I am wrong, I didn't write a Java program for a while! The Gambas inheritance and method overriding mechanism is entirely dynamic too. It is solved at runtime. Consequently, you can override any class and any method of any class, even the native ones, and these overriden classes will be used instead of the old ones, even if classes compiled outside of your projects. In other words, if you declare a "exported" class named "TextBox" in your project, you will redefine the TextBox control everywhere. I am not sure if the Java virtual machine can support that. So it is impossible to use code written in Java from the Gambas interpreter. Or at least it would be not practical at all. Note that the same comment could be done for Parrot. Remember that I made Gambas because I wanted these features (and others). And because I like Basic and C/C++ of course. :-) Moreover, I don't really like Java, because it is a language that wanted to be ubiquitous. Gambas does not. It will try to use all existing libraries and command-line tools to do the job, which is want I want in my programming language. Of course, all the big disadventages you wrote are real: things must be rewritten, there is no platform independence unless someone does it... But, hey, this is free software. :-) Regards, -- Beno?t From gambas at ...1... Fri Apr 3 21:17:34 2009 From: gambas at ...1... (=?iso-8859-1?q?Beno=EEt_Minisini?=) Date: Fri, 3 Apr 2009 21:17:34 +0200 Subject: [Gambas-devel] Just a wild thought In-Reply-To: <200904031450.58619.sourceforge-raindog2@...19...> References: <22873888.post@...565...> <200904031450.58619.sourceforge-raindog2@...19...> Message-ID: <200904032117.34732.gambas@...1...> > On Friday 03 April 2009 14:16, ottod wrote: > > Many people reject the > > idea of desktop apps, saying web apps is the way to go, but that at > > least is contradictory, as the browser itself is a desktop app. > > The browser is more than a desktop app; I can write a web app in any one of > dozens of server languages, including Gambas (though on the browser side I > can use any language I like as long as it's Javascript) and have it work > on a desktop, an ARM-based $150 netbook, an iPhone and a Wii, and if I'm > careful, my 5-year-old freebie cell phone as well. There is no other > development language or framework for which that's true. Except for > hardware-intensive programs like DVD burners and higher-end games, and > despite repeated attempts by Microsoft such as VBscript, ActiveX and > Silverlight to make web apps require one particular operating system, I > think that a majority of development will be web development in the next 5 > years -- if it's not true already. > I fully agree. I have plan (but not time) to bring more Web development features to the Gambas IDE: support for ASP-like pages with syntax highlighting; Some sort of Web controls (i.e. classes that generate HTML/Javascript); An embedded http server, so that you can run your program in the IDE, and immediately run a browser to debug it. Regards, -- Beno?t From a.terpotiz at ...176... Tue Apr 28 22:28:42 2009 From: a.terpotiz at ...176... (goolem) Date: Tue, 28 Apr 2009 13:28:42 -0700 (PDT) Subject: [Gambas-devel] "Settings" Component MIA Message-ID: <23283089.post@...565...> Gareth Bult-3 wrote: > > Hi, > > Although I've included gb.settings into my project the following gives an > error; > > Settings["123"] = 10 > > "Not an array!" > > .. this uses to work .. has the syntax changed or is the module broken ? > > tia > Gareth. > > -- > Managing Director, Encryptec Limited > Tel: 0845 5082719, Mob: 0785 3305393 > Email: gareth at ...560... > Statements made are at all times subject to Encryptec's Terms and > Conditions of Business, which are available upon request. > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by: > SourcForge Community > SourceForge wants to tell your story. > http://p.sf.net/sfu/sf-spreadtheword > _______________________________________________ > Gambas-devel mailing list > Gambas-devel at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-devel > > Hi, I have the same Problem on Gambas 2.0.0. When i create a new Project and will use the Settings Componend on the Form so i will get the message "Not an Array". I use these Components: gb gb.form gb.gui and gb.settings. When i call the settings from a modul so it will be work. Sample Solution: Fmain.class: ' Gambas class file PUBLIC SUB Settings_Click() modValue.values(LAST.tag) END modValue.module: ' Gambas module file EXPORT SUB values(Action AS String) SELECT CASE Action CASE "save" settings["Windows/Top"] = FMain.Top settings["Windows/Left"] = FMain.Left settings["Windows/Width"] = FMain.Width settings["Windows/Height"] = FMain.Height CASE "load" FMain.top = settings["Windows/Top", FMain.Top] FMain.left = settings["Windows/Left", FMain.Left] FMain.Width = settings["Windows/Width", FMain.Width] FMain.Height = settings["Windows/Height", FMain.Height] END SELECT END SUB Fmain.form: # Gambas Form File 2.0 { Form Form MoveScaled(0,0,50,50) Text = ("") Icon = Picture["Logo.png"] { edit Menu Text = ("Bearbeiten") { Settings Menu Text = ("Einstellungen") { Save Menu Settings Name = "Save" Text = ("Sichern") Tag = "save" } { load Menu Settings Name = "load" Text = ("Laden") Tag = "load" } } } } if there a chance to use the settings componend in the form? andreas -- View this message in context: http://www.nabble.com/%22Settings%22-Component-MIA-tp21606478p23283089.html Sent from the gambas-devel mailing list archive at Nabble.com. From ronstk at ...124... Wed Apr 29 17:01:55 2009 From: ronstk at ...124... (Ron_1st) Date: Wed, 29 Apr 2009 17:01:55 +0200 Subject: [Gambas-devel] "Settings" Component MIA In-Reply-To: <23283089.post@...565...> References: <23283089.post@...565...> Message-ID: <200904291701.55922.ronstk@...124...> On Tuesday 28 April 2009, goolem wrote: > Fmain.class: > ' Gambas class file > > PUBLIC SUB Settings_Click() > > ? ? modValue.values(LAST.tag) ? ? > > END > > modValue.module: > ' Gambas module file > AFAIK Settings does not have a click event. The best tip I can give is rename the Menu entry now named 'Settings' to 'mnuSettings'. I'm afraid name collision is your problem here. And ajust the related things to that mnuSettings. Best regards, Ron_1st -- From a.terpotiz at ...176... Wed Apr 29 18:14:54 2009 From: a.terpotiz at ...176... (Andreas Terpotiz) Date: Wed, 29 Apr 2009 18:14:54 +0200 Subject: [Gambas-devel] "Settings" Component MIA In-Reply-To: <200904291701.55922.ronstk@...124...> References: <23283089.post@...565...> <200904291701.55922.ronstk@...124...> Message-ID: <49F87CFE.1010908@...176...> Ron_1st schrieb: > On Tuesday 28 April 2009, goolem wrote: > >> Fmain.class: >> ' Gambas class file >> >> PUBLIC SUB Settings_Click() >> >> modValue.values(LAST.tag) >> >> END >> >> modValue.module: >> ' Gambas module file >> >> > > AFAIK Settings does not have a click event. > The best tip I can give is rename the Menu entry now named 'Settings' > to 'mnuSettings'. I'm afraid name collision is your problem here. > And ajust the related things to that mnuSettings. > > > Best regards, > > Ron_1st > > Thank it works now. Best regards, Andreas From gambas.fr at ...176... Thu Apr 30 00:02:49 2009 From: gambas.fr at ...176... (Fabien Bodard) Date: Thu, 30 Apr 2009 00:02:49 +0200 Subject: [Gambas-devel] Little class Message-ID: <6324a42a0904291502g7f1e8442pbcf4fa1259e81cf5@...178...> Hi Benoit, This is a class to encapsulate the project tree and trying to add a filter on it. you must add just the class and a line in FMain Public Sub _new() Dim hFilter As New CTreeFilter(tvwProject) And set the arrangement of the treeview container to vertical. Regards, Fabien Bodard -------------- next part -------------- A non-text attachment was scrubbed... Name: CTreeFilter.class Type: application/octet-stream Size: 2914 bytes Desc: not available URL: From ronstk at ...124... Thu Apr 30 01:20:30 2009 From: ronstk at ...124... (Ron_1st) Date: Thu, 30 Apr 2009 01:20:30 +0200 Subject: [Gambas-devel] "Settings" Component MIA In-Reply-To: <49F87CFE.1010908@...176...> References: <23283089.post@...565...> <200904291701.55922.ronstk@...124...> <49F87CFE.1010908@...176...> Message-ID: <200904300120.30789.ronstk@...124...> On Wednesday 29 April 2009, Andreas Terpotiz wrote: > Thank it works now. > > Best regards, > Andreas > Good to hear the result. :) Best regards, Ron_1st -- From david_villalobos_c at ...7... Thu Apr 30 16:20:27 2009 From: david_villalobos_c at ...7... (David Villalobos Cambronero) Date: Thu, 30 Apr 2009 07:20:27 -0700 (PDT) Subject: [Gambas-devel] Little class In-Reply-To: <6324a42a0904291502g7f1e8442pbcf4fa1259e81cf5@...178...> References: <6324a42a0904291502g7f1e8442pbcf4fa1259e81cf5@...178...> Message-ID: <929323.86090.qm@...587...> Hey!!!!!!! This is great!!!!! Benoit, can you add it? Please, and, it will be difficult to have the option set the background color? :-) Regards -- David ----- Original Message ---- From: Fabien Bodard To: gambas-devel at lists.sourceforge.net Sent: Wednesday, April 29, 2009 4:02:49 PM Subject: [Gambas-devel] Little class Hi Benoit, This is a class to encapsulate the project tree and trying to add a filter on it. you must add just the class and a line in FMain Public Sub _new() Dim hFilter As New CTreeFilter(tvwProject) And set the arrangement of the treeview container to vertical. Regards, Fabien Bodard