
|
Delphi vs. VB or C++
I'm in the process of choosing technology for developing small custom Win32 apps, just by myself. I'm mainly a freelance Perl programmer (websites, network apps), but every now and then I bump into projects requiring some Win32 programming, usually some kind of client application. I know I can do that with Perl to some extent, but I want a compact downloadable install, and means to develop rich interfaces quickly. My apps will not be big or algorithmically complicated.
So which one to pick? After doing a bit of homework, I'm leaning towards Delphi. What are its drawbacks in comparison to VB and C++, and with regard to my objectives? I used to write all of Object Pascal, C++, and VB several years ago, so language-wise my learning curve would be roughly the same for all three.
Egor
Thursday, April 29, 2004
If you do perl how's about win32::gui ? That makes nice looking win32 apps in perl:
http://dada.perl.it/
http://sourceforge.net/projects/perl-win32-gui/
You can wrap it all in a nice installer too, and ship with the perl runtime.
Matthew Lock
Thursday, April 29, 2004
This looks interesting too: http://www.bahnhof.se/~johanl/perl/Loft/
Matthew Lock
Thursday, April 29, 2004
Sorry, yet another win32::gui link http://perso.club-internet.fr/rocherl/Win32GUI.html
Matthew Lock
Thursday, April 29, 2004
In my opinion, Delphi has no drawbacks compared to C++ or VB.
Delphi has a lot more components than VB. The components are of higher quality. The language itself is a lot better.
The execution speed of Delphi is only slightly lower than the execution speed of C++.
The only real draw-back of Delphi is the fact that Borland didn't know how to market it properly, and so many employers don't know about it.
MX
Thursday, April 29, 2004
"but I want a compact downloadable install, and means to develop rich interfaces quickly. "
Discussed TO DEATH on this board:
http://www.google.com/search?sourceid=navclient&ie=UTF-8&oe=UTF-8&q=site:discuss%2Efogcreek%2Ecom+delphi+vb+c
But... I still like to discuss it, so here's my $.02 worth.
Based only on that criteria, Delphi wins hands down.
(I'm a vb 6 programmer learning Delphi now)
Haven't programmed in C++, did a tinsy bit of C in college (just remember a haze of {}'s)
But...
C++ : harder to write code in (from what I hear). Small, fast exe's
VB 6: easy to write code in. Not OO. Dead language. No future versions.
.net: 30+ MB Runtime (CLR, compressed is 20 MB). Since you never know if your customer has the CLR, you have to ask ("huh? what's a CLR, how do I know I've got it", they ask)
Delphi: Just learning this: almost as easy as VB 6. Fast, small EXEs. (A hello world can get down as small as 50k or so with a LOT Of tweakign of libraries). Without any effort I had a compiled hello world at 400k, as I recall).
There is a big learning curve initially compared with vb. You have to declare a functions's interface and THEN it's implementation. That threw me for a while. Then I read the book :-). That was the thing with vb 6: hardly needed a manual.
But Delphi is SWEET. It's sooo logical. It's a consisten abstraction. I.e., when you think "hmmm... I wonder if I could just assign a procedure to be an event handler for Button1_Click:=MyEventHandler()
Wow! It did what I thought it might. VB6, which I loved, was soo full of exceptions. It was just stretched too far. No wonder they started from scratch.
Oh, and Delphi makes killer UI's. Tons of controls in the VCL, plus tons more out there freeware and cheapware. often with source code.
Just getting sick of all those ;'s
They shoudl call it P;; Instead of Delphi.
Mr. Analogy
Thursday, April 29, 2004
Thanks for Win32 Perl pointers guys, but I think I want something that has a visual interface designer, and is overall a polished product. Plus I need the ability to create custom IE toolbars (forgot to mention that in the initial post, sorry).
Can anyone compare Delphi to C++ in development speed, especially for interface-intensive apps?
Egor
Friday, April 30, 2004
Hey, http://discuss.fogcreek.com/redirect.asp?http://www.bahnhof.se/~johanl/perl/Loft/ is a visual interface designer
Matthew Lock
Friday, April 30, 2004
REALbasic? http://www.realbasic.com
Drag n drop GUI, lovely coding language...compiled not interpreted and the professional license runs as a single executable on windows, macosx, mac classic and linux.
native widgets, builtin threading, remote debugging...I could go on and on...
FullNameRequired
Friday, April 30, 2004
Delphi's language is a quasi 'object-oriented' version of Pascal (with all the typing headaches and verbosity that implies). It lacks important features like parametric types, operator overloading, multiple inheritance, and so on. It comes with a pretty nice library (the date/time and basic statistical functions are more extensive than the default library that comes from any other compiler vendor -- that's a trivial thing but it's a nice touch), and it's really easy to make controls (either native VCL controls or ActiveX controls). Unfortunately the basic library doesn't come with critical tools like regular expression or CFG parsers.
Kalani
Friday, April 30, 2004
REAL Basic looks interesting. Thanks, FullNameRequired. Have you used it for real-world apps? Does it have regular expressions library?
Egor
Friday, April 30, 2004
Hi Egor,
yeah, Im using it more and more these days for the appropriate projects. Its a lovely OO language, and it has a full regex class that can do all the expected stuff.
Its ideal for (what I think) you want.
Its got built in sockets, with things like a HTTPsocket, POPSocket or SMTPSocket builton top, you can do console apps, standard application apps or..some third option that I cannot remember off the top of my head (personally Ive never used it for anything other than standard applications)
Its not as fully mature as something like Visual Basic, still too young for that, but its very nice in its own right.
FullNameRequired
Friday, April 30, 2004
I can't believe this thread hasn't descended in a tirade of meaningless babble yet!
Then or course, we all know VB is best.
Realist
Friday, April 30, 2004
I'd recommend Delphi to you any day. First of all, it's extremely easy to pick up. There are a few good ones. If I recall correctly I'd recommend:
http://regexpstudio.com/TRegExpr/TRegExpr.html
There's some regular expression debugger on that site too, never tried it though.
It's rapid in every aspect. You can easily interface with COM and pumping out your custom COM-controls isn't much harder. The GUI design is intuitive at a level that microsoft hasn't achieved yet. Although I do prefer Visual studio .net's ide for coding...
Marcus
Friday, April 30, 2004
Wow, Realbasic must have grown quite a bit the last 6 months or so. I remember looking at it a while ago, but it wasnt cross platform, and the VB import stuff must be new too.
Doesnt look half bad now.
Eric Debois
Friday, April 30, 2004
hey Eric,
must have been more than 6 months ago :) its been able to compile crossplatform for a few years.
oh!....but only had a windows IDE since 5.2(?) so maybe thats what you mean..that would be approx 6-8 months ago.
FullNameRequired
Friday, April 30, 2004
ok, thats probably it. Or mayby Im confused. There is quite alot of basic variants out there.
Im looking at purebasic myself. (Not terribly advanced, but it does a full native compile.)
Eric Debois
Friday, April 30, 2004
mmm...purebasic looks interesting. love those screenshots.
AmigaOS is an interesting choice :) whats the bet it started on there.
Have you used it much eric? how would you rate it?
FullNameRequired
Friday, April 30, 2004
"I want a compact downloadable install, and means to develop rich interfaces quickly."
Well, it's Delphi, then.
"After doing a bit of homework, I'm leaning towards Delphi. What are its drawbacks in comparison to VB and C++, and with regard to my objectives?"
You didn't state as a goal getting a job (as opposed to being self-employed) based on the language you choose, so I'd say go with Delphi.
In the meantime, don't lose sight of C#. I haven't had the time (meaning, the disposition) to look at it yet, but from what I've read, it copies several concepts from Delphi (which is natural, since both languages share the same "father"). This means that when the CLR is no longer a burden, you can go with Delphi.Net, or you can switch to C#.
Paulo Caetano
Friday, April 30, 2004
>>Have you used it much eric? how would you rate it?
Ive played abit with the demo version. Thats it. It strikes me as powerful but unpolished. It isnt geared towards stuff like databases so its not of much value to me professionally. The interface designer isnt exactly top of the line either.
For other stuff its pretty cool though. It looks perfect for hacking out batch file processors and stuff.
Eric Debois
Friday, April 30, 2004
> Delphi's language is a quasi 'object-oriented'
> version of Pascal (with all the typing headaches
> and verbosity that implies).
Delphi is a fully object oriented programming language.
That means it fully supports inheritance, encapsulation and polymorphism.
Any language that supports those 3 features is an OOP language.
Delphi is not a PURE OOP language. That is, you can define a function which is not a method of an object.
This is an advantage or a disadvantage, depending on how you view it.
> It lacks important features like parametric
> types, operator overloading, multiple
> inheritance, and so on.
Java also lacks ALL these features.
Java is a simplified C++. The productivity boost of Java over C++ comes from these simplifications.
The fact that Java lacks these things you mentioned was many times commented in the industry as a VERY positive thing.
So - yes, Delphi doesn't have the features you mentioned. This is an important ADVANTAGE for 80% of the applications.
> Unfortunately the basic library doesn't
> come with critical tools like regular
> expression or CFG parsers.
There is an excellent "free with source" regular expression library available.
A wealth of libraries and components is available for free - check out http://www.torry.net/ which is a component directory.
MX
Friday, April 30, 2004
"t isnt geared towards stuff like databases so its not of much value to me professionally."
right, thats one nice thing about REALbasic, its got plugins for a bunch of databases (10 or 20 or something stupid), most packaged with the IDE, while those that are not are available via third party.
<g> on the downside most of them haven't been kept as up to date as some of the other stuff....I cannot shake the feeling that some fool in their management is thinking of them as a cost centre instead of a huge asset.
overall they all work pretty well though, the mysql plugin is a tad slow but still usable and thats the one I use mostly.
<g> anyway, thats enough guerilla marketing from me.
FullNameRequired
Friday, April 30, 2004
REAL BASIC issues
1. Neat language, easy to learn if you know vb6
2. Very limited set of visual controls. (Ex: not Picture+ text command buttons. cant' change color of buttons). There may be third party controls for this.
3. Large "hello world" exe size: 1 MB as I recall. This is b/c it has a runtime that gets compiled into the exe. (Still better than VB6, which has a 1 MB runtime but doesn't give you a compiled EXE.
4. Somewhat limited OOP :
If you create an object, you can't dynamically assign events. In fact, you have to put the object on your form to get at the events. So, for instance, I can't assign an object at runtime and then handle events the object fires. Now, you can work around this by having all of your objects on the form and the code already in the events, then you CHOOSE the object you want to use at run time. But this seems to shades of vb6 ("it'll do XYZ, you just have to work harder on the code")
5. Pesonal bias: I worry about the Windows version being a bit of a step child. So far, there doesn't seem to be an basis for this. Just a paranoia.
6. Doesn't do some basic stuff natively (can't display jpeg's) without a third party control. There is some set of libraries that's relatively cheap, but adds a bit (1 MB or more, I *think*) to the runtime. Now we're up to 2 MB and depending on TWO vendors just to display JPEGs.
7. For $100 (non DB edition) it's a slick little language. It's nearly as good as VB6. (Better than vb6 if you don't need fancy controls).
Mr. Analogy
Friday, April 30, 2004
"very limited set of visual controls. (Ex: not Picture+ text command buttons. cant' change color of buttons). "
actually thats not entirely true, you can create bevel buttons with icons or menus without problems, and you can very easily create specialised buttons with your own colour/look by subclassing the canvas class and drawing it yourself.
Basically RB makes it very easy to work within the UI guidelines of each platform, but if you want to step outside those (say, with differently coloured buttons) you generally have to roll your own custom controls...luckily this is very easy as well using the canvas class.
" Large "hello world" exe size: 1 MB as I recall. "
<shrug> the flipside of this is that it doesn't get much bigger when you start doing non-trivial programs.
<g> Ive always failed to understand why people worry about the size of an entirely trivial program....personally I dont write many of them...
"If you create an object, you can't dynamically assign events. In fact, you have to put the object on your form to get at the events. "
umm..what? no you dont. I can subclass any object I want, add new events, call them and handle those events with a further subclass.
I must be misunderstanding what you mean? you certainly _do not_ have to move the object to a form to get access to those events.
" I worry about the Windows version being a bit of a step child. So far, there doesn't seem to be an basis for this. Just a paranoia."
heh.
"Doesn't do some basic stuff natively (can't display jpeg's) without a third party control."
thats actually incorrect as well. you can use either quicktime or the windows builtin stuff to display jpegs. Personally I prefer the quicktime approach, the windows builtin image handling stuff is pretty sad.
"For $100 (non DB edition) it's a slick little language. It's nearly as good as VB6."
nah, vb6 is a much older and IMO more mature language...in lots of ways RB has a way to go before it reaches the maturity of vb6. (although it does IMO have a rather nicer syntax overall)
personally if I was only targetting windows I would use vb6...no question.
As it is I have to target both mac and windows so I use RB, and because I now have experience in RB I use it even for windows only projects.
But if you dont ever expect to be writing for mac or linux, then use vb6 would be my recommendation....its far more mature.
FullNameRequired
Friday, April 30, 2004
"Delphi's language [snip] lacks important features like parametric types, operator overloading, multiple inheritance, and so on."
Delphi 8 (a.k.a. Delphi.NET) supports operator overloading. You also have to qualify what you mean by "multiple inheritance". Delphi's object model is similar to Java and C#, single implementation inheritance, multiple interface inheritance.
Leo S.
Tuesday, May 11, 2004
I think If you want to use these OOP languages as a real programmer who want to earn himself by programming , It's the best recommend to you to choose delphi for your main language . I can not avoid these realities that C++ compiler is faster than delpgi in afew instances , But comparing these two language ethier all the OOP languages , Delphi can be faster for a complete application and its supports in the future aspects like debugging or changing you code to make the new changes into you application and even working with that as a programming team . You can have the fast , Powerfull and more easy to use , comparing to VC++ , chances developing an application with Delphi .
This is my Impressa :
"When you can open a bolt with a screwdriver Why sould you try it by hand ?"
iman davoodian
Sunday, May 23, 2004
Recent Topics
Fog Creek Home
|