|
|
 | | From: | Chris McFarling | | Subject: | Looking for cross-platform best practices | | Date: | Mon, 17 Jan 2005 00:52:39 -0800 |
|
|
 | I'm a part time web programmer (ASP,VBScript,Javascript,SQL) looking to transition into traditional application development. I've got some ideas for programs that I'd like to write so I'm currenly studying up on C++. As I think ahead to a time that I'm proficient enough to start actully creating applications, there are some requirements that I'd like to be able to fullfill. Here's what I'm looking for:
- Optimum approach to writing an app that will run on Windows and OS X (i.e. least amount of code, fewest number of tools) - Not JAVA based - GUI interface that strongly adhears to each platforms standard interface guidelines while maintaining consistency accross platforms - Database integration - both client/server architecture and dektop databse implementations - Ability to display image files (possibly large ones) on screen - As fast as possible (responsiveness to user, computational speed, etc) - Take full advantage of platform specific technologies (AppleScript, etc)
I have several years as an end user on both platforms so I know the ins and outs of each (from a user standpoint). I've also used enough crappy software in my time to know what sets a good app apart from a sloppy one. As I move ahead I'd like to start gathering the neccessary tools for my needs so I can start getting intimately familiar with what I'll be using. From reading through the threads on here, it's obvious that there are several approaches to cross platform programming. Is there a defacto standard for doing this type of thing though?
Ideally, I envision a solution in which all development is done on a single platform and compiled for both from that platform. From what I've read it seems that CodeWarrior Development Tools for Mac OS and Windows can accomplish this. I know RealBasic takes this approach too, although I'm assuming that RealBasic won't meet the requirement of being "as fast a s possible". Then there's XCode and Interface Builder and yada yada yada. I figure the best place to sort it all out is on a newsgroup such as this where I can get some feedback from people who have been-there-done-that already.
Thanks for any feedback.
Chris M
|
|
 | | From: | jonhoyle at mac.com | | Subject: | Re: Looking for cross-platform best practices | | Date: | 17 Jan 2005 16:14:14 -0800 |
|
|
 | Hi Chris,
My experience has been very positive using CodeWarrior C++ (both Mac & Windows) for the core code for speed and optimization and RealBasic as the GUI that rides on top of it. I tend to find that this really gives me the best of all worlds when it comes to cross-platform code generation.
Essentially, I begin with a CodeWarrior DLL project for Mac and Windows (ie Carbon Shared Library for Mac and Dynamic Linked Library for Win32). I write my model code in here, typically using a command line interface for it to make sure Unit Tests pass. (I can provide you with a sample CW 8.3 project I use as my template.)
Then I write my GUI in RealBasic, using Declares to call into the DLL. Since I use RB only for GUI, it's fairly thin since none of my model code uses RB objects. The RB calls essentially resolve to Mac and Win API calls under the hood, making life so much easier. GUI writing is a breeze this way, allowing me to spend most of my time writing the core in C++.
I have done other projects in th past doing the same thing, except using Java for the GUI instead of RealBasic. I find that Java's runtime is a bit heavy and less responsive as compared to RealBasic, and the coding much more involved, so I am not really interested in going back to that.
Hope that helps,
Jonathan
|
|
 | | From: | Paul | | Subject: | Re: Looking for cross-platform best practices | | Date: | Tue, 18 Jan 2005 21:32:09 GMT |
|
|
 | wrote in message news:1106007254.689360.5600@z14g2000cwz.googlegroups.com... > Hi Chris, > > My experience has been very positive using CodeWarrior C++ (both Mac & > Windows) for the core code for speed and optimization and RealBasic as > the GUI that rides on top of it. I tend to find that this really gives > me the best of all worlds when it comes to cross-platform code > generation. > > Essentially, I begin with a CodeWarrior DLL project for Mac and Windows > (ie Carbon Shared Library for Mac and Dynamic Linked Library for > Win32). I write my model code in here, typically using a command line > interface for it to make sure Unit Tests pass. (I can provide you with > a sample CW 8.3 project I use as my template.) > > Then I write my GUI in RealBasic, using Declares to call into the DLL. > Since I use RB only for GUI, it's fairly thin since none of my model > code uses RB objects. The RB calls essentially resolve to Mac and Win > API calls under the hood, making life so much easier. GUI writing is a > breeze this way, allowing me to spend most of my time writing the core > in C++. > > I have done other projects in th past doing the same thing, except > using Java for the GUI instead of RealBasic. I find that Java's > runtime is a bit heavy and less responsive as compared to RealBasic, > and the coding much more involved, so I am not really interested in > going back to that. >
I've looked into this and never really got going on it. How difficult is it to call back from a DLL into RB (if a control needs to updated by a DLL process, for example)?
I was once part of a (Win only) project that did this w/ a VB front end. They had decided to use a massive ActiveX control instead of a simple DLL, to get the ability to raise events back to VB. (It was slow and so complex that only a few people could actually do that, but it did sort of work.)
Paul
|
|
 | | From: | Deane Yang | | Subject: | Re: Looking for cross-platform best practices | | Date: | Wed, 19 Jan 2005 02:16:49 GMT |
|
|
 | This sounds pretty cool. I would be quite interested in a sample project that creates a Mac DLL that can be called by RealBasic. Any chance it can also be called by Excel X VBA code, too?
jonhoyle@mac.com wrote: > Hi Chris, > > My experience has been very positive using CodeWarrior C++ (both Mac & > Windows) for the core code for speed and optimization and RealBasic as > the GUI that rides on top of it. I tend to find that this really gives > me the best of all worlds when it comes to cross-platform code > generation. > > Essentially, I begin with a CodeWarrior DLL project for Mac and Windows > (ie Carbon Shared Library for Mac and Dynamic Linked Library for > Win32). I write my model code in here, typically using a command line > interface for it to make sure Unit Tests pass. (I can provide you with > a sample CW 8.3 project I use as my template.) > > Then I write my GUI in RealBasic, using Declares to call into the DLL. > Since I use RB only for GUI, it's fairly thin since none of my model > code uses RB objects. The RB calls essentially resolve to Mac and Win > API calls under the hood, making life so much easier. GUI writing is a > breeze this way, allowing me to spend most of my time writing the core > in C++. > > I have done other projects in th past doing the same thing, except > using Java for the GUI instead of RealBasic. I find that Java's > runtime is a bit heavy and less responsive as compared to RealBasic, > and the coding much more involved, so I am not really interested in > going back to that. > > Hope that helps, > > Jonathan >
|
|
 | | From: | Martin | | Subject: | Re: Looking for cross-platform best practices | | Date: | 17 Jan 2005 14:03:56 -0800 |
|
|
 | I personally don't have any experience with it, but have you looked at Runtime Revolution ? From the description, it may be close to what you are looking for....
Martin
|
|
 | | From: | Eric VERGNAUD | | Subject: | Re: Looking for cross-platform best practices | | Date: | Tue, 18 Jan 2005 00:25:56 +0100 |
|
|
 | dans l'article 1105999436.641293.256490@c13g2000cwb.googlegroups.com, Martin à anonymous_300@hotmail.com a écrit le 17/01/05 23:03 :
> I personally don't have any experience with it, but have you looked at > Runtime Revolution ? From the > description, it may be close to what you are looking for.... > > Martin >
No he's looking for C++.
Eric
|
|
 | | From: | David Dunham | | Subject: | Re: Looking for cross-platform best practices | | Date: | Tue, 18 Jan 2005 22:19:15 -0800 |
|
|
 | In article <4XKGd.7822$nt.593@fed1read06>, "Chris McFarling" wrote:
> Ideally, I envision a solution in which all development is done on a single > platform and compiled for both from that platform. From what I've read it > seems that CodeWarrior Development Tools for Mac OS and Windows can > accomplish this.
Probably, though I've always used a native IDE.
> I know RealBasic takes this approach too, although I'm > assuming that RealBasic won't meet the requirement of being "as fast a s > possible".
But maybe as fast as you need. You can always write plugins in C if you think you have to.
-- David Dunham A Sharp, LLC http://www.a-sharp.com/ "I say we should listen to the customers and give them what they want." "What they want is better products for free." --Scott Adams
|
|
 | | From: | Thomas Engelmeier | | Subject: | Re: Looking for cross-platform best practices | | Date: | Sat, 22 Jan 2005 21:08:53 +0100 |
|
|
 | In article <4XKGd.7822$nt.593@fed1read06>, "Chris McFarling" wrote:
> think ahead to a time that I'm proficient enough to start actully creating > applications, there are some requirements that I'd like to be able to > fullfill. Here's what I'm looking for: > > - Optimum approach to writing an app that will run on Windows and OS X (i.e. > least amount of code, fewest number of tools)
Verbose code can be good. Otherwise we all would write "least amount of code" Perl data manipulation ;-)
> - GUI interface that strongly adhears to each platforms standard interface > guidelines while maintaining consistency accross platforms
Usually this needs to be written native on both platforms. RealBasic UI´s are constrained but acceptable...
> - Database integration - both client/server architecture and dektop databse > implementations
Here you'd absolutely benefit from Java. The UI can still be implemented "Native" > - Ability to display image files (possibly large ones) on screen
Define large..
> - As fast as possible (responsiveness to user, computational speed, etc)
A bad algorithm in an efficient language gets beaten by an efficient algorithm in any language. The UI can be responsive in C++, Basic, Java or whatever based applications.
> From reading > through the threads on here, it's obvious that there are several approaches > to cross platform programming. Is there a defacto standard for doing this > type of thing though?
No. There are many tools that have different strenghts and weaknesses. Depending on your goal, you need to choose the right tool. "For someone who only has an hammer, ever problem looks like an nail".
HTH, Tom_E
-- This address is valid in its unmodified form but expires soon.
|
|
|