The extension method style which gives you the dot notation isnt bad as far as readability goes BUT since you cannot replace every instance of an olld non-extension method with a dot notation one you end up with a mish mash of them
A simple example is something like checking if a key pressed is number key
In old style you could do
if instr("0123456789", key) .....
and there’s not replacement for that using something like
if "0123456789".Instr(key) .....
So the API 2 style only improve some readability
Renamed properties is, IMHO, not that nbig a deal and in some cases improves things and in some cases makes thing less clear and in some cases improves them
No
Just saying that API had use cases that API 2 cant cover because of how its done
They’d need to make some compiler related changes to make the second form work
And IF they did then API 2 might be slightly more consistent and read nicer than it does now
Currently that second use case requires you to add a string variable or constant that you can then use in that expression and THAT is a potential source of new bugs
He never said that, as Garry said, He just made up his mind and the rename is going to happen. He just decided to do it with new API2 classes, deprecating all the current controls. Just like web 2.0 is API2 only, looks like we are going to have a Desktop 2.0
Wow, I didn’t mean to open a can of worms here. Thanks to all for the comments and input.
I’m still lost though. What the heck is Xojo.Core? Is this the “modern” framework in between API1 and API2? Is this now deprecated/EOL’d? Can I simply go “back” to FolderItem?
Xojo.Core is part of the Xojo framework that came AFTER API 1 and before API 2 as part of iOS and had some portions on desktop etc
At this point since Xojo has said everything will be API 2 you might as well go back to that
Not really a can of worms but there are definitely some strongly held opinions
For anyone that had/has to use old IDE’s and newer ones to support a wide range of customers / client on a wide rang of OSes API 2 is a non-starter.
As soon as you adopt any of it you cannot go back to any old IDE which limits how far back you can support. If you have clients that still use old versions of Windows like XP of old versions of Windows Server, old linux distros which is somewhat common, or old versions of macOS you have to avoid API 2.
You’ll find there are a decent number of people that do have to do this for their customers.
Beyond that there are ancillary issues like :
all the code samples in every issue of xDev up to mid 2019 are now out of date
all the non-Xojo provided samples etc are out of date
even a lot of the posts & replies in Xojo’s own forum are, up to mid 2019, API 1 code that will require updating to be API 2 compliant
Xojo has chosen to proceed with renaming properties and events anyway
How does one determine which classes are part of this interim framework? Is it just everything off of the Xojo namespace or are there other areas to avoid as well?
And therein lies the difficulty as SOME things in API 2 are in the Xojo namespace
Things like Xojo.Point, Xojo.Rect etc will probably remain
If you move away from Xojo.IO, Xojo.Core, and the other sub namespaces in Xojo you’ll be “mostly” ok but not 100% again because some of that IS part of API 2
I am awaiting mor changes like the API1 removals in Xojo 2021 (or so): what will not works anymore in API1 with Apple Silicon hardware will be removed sooner.
A company cannot support two technologies (in that case API1 and API2).
And I suppose that Xojo 2019r1.1 will not works with Apple Silicon.
So, if you want to continue to use Xojo, go the API2 route or start to learn a different tool: do not waste your time with the hope of a return to API1.
I never started to use Xojo New Framework because each time I went there in the LR, I read iOS… and I do not wanted to program for iOS: I still do not have an iOS hardware. This may change in the future, but knowing their prices, I do not believe that.
Sorry to be so realistic.
Have you read the questions from newbies that do not read the LR… lately ?
(in the other forum)
Hmm, I haven’t seen any LR questions in the other forums, but I’ll keep and eye out for them. I actually looked in the LR before posting here and there was info regarding API1 and API2 but not this interim framework.
API 1 is unlikely to be removed
Xojo has said that it will remain in place for years
BUT the IDE will try & steer you to usng API 2 in any NEW projects (unless you override the default project template with one from 2019r1.1 and then you’ll get API 1.0 autocomplete as well)
I do not imagine it will be a matter of API1 NOT working with ARM, since Xojo shouldn’t have to rewrite the entire product, just recompile with an ARM LLVM , which they already have. This would be the easiest thing for them, since to “remove” API1 without a great deal of planning (not an Xojo strong suit evidenced by the previous years), it would break more than it would save in the long run.
That was just your interpretation. Xojo always said that the New framework was for all platforms and users should adopt it asap. iOS being the New platform back then, it was kind of New Framwork only.
This is the same as if you now understand that API2 is just for web just because Web2.0 is anounced to be API2 Only.