For next pre-release we upgrade our MBS Xojo Network Plugin with new DataAvailable event for SSH2ChannelMBS class. This allows to easier use the SSH connection and react event based on incoming data. And we used the chance to build a new example for a GUI based SSH Terminal application example:
Like the TCPSockets in Xojo, the trick is a timer running in the background to check regularly for new data. We start it when you call Execute method and then the timer checks for new data. If you don't use the DataAvailable event, we disable the timer of course, so you can just read yourself.
Originally we started the SSH classes to solve the problem, that normal SSH command line tool doesn't accept password as parameter or via pipe input. With our SSH2SessionMBS class you can provide password, use keyboard interactive password passing or private key file. The last one is the most secure of course.
Will come later this week with 20.5pr3. Please do not hesitate to contact us if you have questions.
It may be good to combine this link feature with underline \ul# and then switch color with \FC and the right color. For blue, we use 16711680, which is 255 * 256 * 256 as returned by DynaPDF.RGB funtion:
In Xojo use this with WriteFText and WriteFTextEx functions in DynaPDFMBS class. If you like to use styled text from TextArea control, please use ConvertStyledText function to get the text converted for WriteFText. Then you can add links after that and before you pass text to WriteFText funtions.
Over time we collected a few functions in our plugins to help with variants. Beside the internal routines to convert from/to various classes like SAValue, NSObject, CFObject, PROPVARIANT and VARAINT and Xojo variants, we got a lot of useful helps for your daily coding.
We often encounter variants containing arrays and like to assign them to a local variable in Xojo. But you can't just assign an array inside a variant to an array of variant in Xojo. This raises a TypeMismatchException without explanation message. See Feedback case 24167.
Our GetVariantArrayMBS function checks whether the variant contains an array of type object. If so, we return it as an array of variant and you can use it.
When you have a variant of some type of array, you have no way in Xojo to know the upper bound easily (see Feedback case 31799). You would have to query the type of array, then assign to a matching local variable, handle over 20 types for that then know the upper bound. Our GetVariantArrayUboundMBS function makes this easier as it works for all array types.
The GetVariantArrayValueMBS function allows you to query an array values independent of the type of array as variant. No need to query type and assign to local variable, risking a TypeMismatchException. You simply pass index, we lookup type of array and carefully check which variant value to return. As our plugin knows the upper bound, we can do bounds checking and raise an OutOfBoundsException if needed and include a message text of course.
Need to set a value in an array? You can use SetVariantArrayValueMBS function to set a value in any type of array universally.
The GetVariantAsDictionaryArrayMBS function is relatively new in one of the last releases. Our code to convert JSON to Xojo objects uses dictionary arrays, but how to cast them correctly? Well, in Xojo you have no way to check whether an array is of type object/variant and then check whether all items inside are Dictionary (or nil). Our plugin function does exactly that and helps to process easily arrays of Dictionary stored in variant.
We put in some safe guards, so it will raise an exception if something isn't as expected. Feedback case 61541.
We just added this function to expose our way to know in the plugin, whether a variant contains an unsigned integer. The built-in VarType() function as well as variant.type property will return 2 for both Int32 and UInt32 and 3 for both Int64 and UInt64. Our GetVariantTypeMBS function returns 102 for UInt32 and 103 for UInt64. Adding 100 to the constant value seems to be the easiest for now. There is a feature request for Xojo (Feedback case 36888) to add their own constants and use them everywhere. In case that gets implemented, we could change our functions to return the new values. So be sure you define yourself a kVariantTypeUInt32 = 102 and kVariantTypeUInt64 = 103 constant, so you have one place in future to adjust those values if needed.
The new GetVariantTypeMBS function is coming for version 20.5pr2 of our plugins together with better UInt32/UInt64 variant handling in a dozen classes.
Please do not hesitate to contact us with questions or if you have ideas for new functionality!
Xojo Inc. dropped an update for Xojo 2020r1: Download and Release Notes. It improves the web target with 32 bug fixes, 5 changes and 6 new things. This fixes the most urgent things in the Web 2 framework and is certainly welcome to get quick fixes there. Most welcome are Pressed events for WebLabel, WebImageViewer and WebCanvas. We hope in future to have an universal Pressed event for all controls, which carries additional parameters like modifier keys.
For desktop projects, you find a bug fix for the HTMLViewer issue Bob talked about. A text conversion bug was fixed, so we may encounter failed assertion in REALstring.cpp less frequent. Still we prefer those being exceptions and not assertions as we want to get a stack trace and show our bug reporter dialog. The fixes for Double.IsInfinite and Double.IsNotANumber make you wonder whether this functions have been tested at all by anyone before releasing. United tests may be a good for such basic functions! HTMLViewer on macOS can now pass floating values and the Linux IDE should now show the help even if some webkit library is missing.
In general the update is very welcome. Kudos for Xojo Inc. to do a .1 release and pushing the fixes to us without letting us wait months for the next bigger release.
As of today we have no idea what may come in r2 this year as Xojo Inc. hasn't announced anything in this regard. We do hope for a more bug fix orientated release. Web 2.0 and API 2.0 may have enough issues to keep engineers busy. Add a dozen bug fixes for long standing issues and we would be happy. As Apple is launching Apple Silicon soon, support for that target should be prioritized, so Xojo is ready and developers like us have a chance to test Xojo projects and our plugin functionality before Apple ships the hardware to customers. We already compiled 20.4 release for macOS with ARM 64-bit to make sure things do compile.
We have started to look on the Windows Learning APIs to implement some functions for our plugins. Since 2017 we have CoreML functions for macOS. FileMaker 19 now ships similar functions built-in, but we think the plugin can still do more. As we are now using newer Visual Studio 2019, we can finally also check the Windows Learning functions:
You can use ONNX Models with the classes, so check the Microsoft website on how to get models. This mainly points to the ONNX Model Zoo, which has some interesting models available.
A difference between the macOS/iOS implementation by Apple and the one by Microsoft is the missing of labels for the latter. For Windows you get a Labels.txt file with the list of what index in the result points to what label they mean. Our example code will show how to handle this.
Those functions and new classes are coming for next pre-release versions in October 2020. We may get a good start set and may add more as needed later. Especially as we learn what other models may need as input and output features.
In this article I want to introduce you the new functionalities from the MBS Xojo Plugins in version 20.4.
The new FileMaker Plugin
Our plugins welcome a new plugin in their circle, the FMAPI plugin. With this plugin you can use Claris FileMaker Server Data or Admin APIs from Xojo.
With instances of the FMDataMBS you get a connection to the FileMaker Server. For the login you need user name and password or OAuthRequestId and OAuthIdentifier for oAuth. A connection attempt can look like this:
We can then run searches on this connected database, read, modify, add, duplicate and delete records. We pass queries to the database to the appropriate functions. These are instances of the class FMRequestMBS with various details. On return we get result objects of class FMResponseMBS.
Just seven months till the XDC 2021 in London, England. Tickets are still available for $750 USD till 1st October 20201st April 2021 instead of $950 later.
It will be held April 21-23, 2021October 13-15, 2021 in London, England at the Holiday Inn Bloomsbury. This conferences is the best place to meet Xojo developers from around the world in real live, make contacts, present yourself as expert and learn what is new in Xojo. Tickets are available in the Xojo store and if you bring your partner, you can order an extra guest ticket for the dinner events.
Wether you are full or part time Xojo developer, this is your chance to learn all about the Web 2.0 framework, the Android progress and what's new in the Xojo world.
To get there, please use public transportation. The piccadilly line brings you right from Heathrow Airport to Russell Square Station, just next to the hotel. That trip should cost about 3 £ and you may just pay by tap in/out with your NFC enabled credit card or phone. Otherwise buy an Oyster card and load money on it if you don't have such a card. If you come by Eurostar train through the tunnel from France, you can exit Pancras station and just walk to the hotel. Otherwise take one station via subway to Russell Square Station. That station is right behind the hotel block.
See you soon there!
PS: We hope COVID-19 is mostly done by April 2021. As Geoff Perlman, CEO of Xojo Inc., said in a recent hangout event, in case of cancellation that would be end of the year and everyone is refunded. So you can sign up and book flights early in January.
Nickenich, Germany - (September 15th, 2020) -- MonkeyBread Software today is pleased to announce MBS Xojo Plugins 20.4 for macOS, Linux and Windows, the latest update to their product that is easily the most powerful plugin collection currently available for Xojo. MBS Xojo Plugins have been updated and now includes over 2600 classes and 70,000 documented features, and the versatile plugins have gained more new functions:
The main feature of the newer plugin version is our move from Visual Studio 2008 to the more current version 2019. We now use universal runtime library, the same Visual Studio runtime as Xojo. As Windows 10 includes those DLLs by default and Windows 7 and 8 can install them, the plugin should run fine there. We worked on this for over a year to get all our libraries ported and recompiled. All parts come together and now we can ship our Windows plugins built with current tools and start to add more Windows 10 APIs over time.
We add classes for Windows Store in our new WinFrameworks plugin. You can now offer trial applications with in-app purchases to unlock the full version. Our plugin allows you to query the products, the SKU list and the status of current licenses.
For Windows we added location classes, so you can query the location of the computer, similar to our CoreLocation classes on macOS. Great for apps running on Windows tablet PCs with a built-in GPS.
To connect to Claris FileMaker Server's Data and Admin API, we got a new FMAPI plugin. The plugin class FMDataMBS for Data API and FMAdminMBS class for the Admin API takes care about authentication and sending queries. The results are provided as JSON and parsed as variants, dictionaries and arrays. This greatly simplifies talking to FileMaker Servers from Xojo. For example build a Xojo app to run on your Raspberry Pi, collect data and push them to a FileMaker database.
If you use file dialogs in Xojo for macOS or Windows, you can now use our plugin classes to modify the dialogs. For this use NSSavePanelObserverMBS class on macOS or WinFileDialogObserverMBS class on Windows. You may use both to add custom controls to a save or open dialog.
For DynaPDF Plugin we decided to implement DynaPDFErrorExceptionMBS class. If you don't implement an Error event, we raise exceptions when an error happens. This should help beginners to not miss errors. And as you can load a custom DynaPDF library, we have a DynaPDFMissingFunctionExceptionMBS class to inform you that a function is not available. To make debugging easier, we added ActiveFontInfo property, which you can inspect in debugger to see what the current font is.
The HTMLViewer classes for WebKit 2 got more preferences in WKPreferencesMBS class to enable inspector via developer extras, disable image loading, printing backgrounds and set standard font size and family. For WKWebViewMBS we added properties to disable background drawing for transparent views.
Our MapKit support on macOS got improvements with new MKMarkerAnnotationViewMBS class to display marker annotations. The MKAnnotationViewMBS class has new prepareForReuse and prepareForDisplay events to better handle reuse of views and lower memory usage. We can query all annotation views via new annotationViews function in MKMapViewMBS class.
We improved JSONMBS class with new ArrayItems function, rewrote HotkeyMBS class for Windows to use native API, added cameraDeviceDidEnableAccessRestriction and cameraDeviceDidRemoveAccessRestriction events to ImageCaptureEventsMBS class to notify you about device unlocking, we added font style handling to GMImageMBS class, added new GetVariantAsDictionaryArrayMBS function to get a dictionary array stored inside a variant and we added support for WinDataObjectMBS class to receive email attachments from Outlook via Drag & Drop.
To speed up pre-compilation in Xojo for console projects, we changed over 300 classes to mark them console unsafe. This way those classes will be ignored for console targets. Please contact us if you need one of those classes in your web or console projects.
Finally we updated bzip2 library to version 1.0.8, CURL to 7.72.0, DynaPDF to 22.214.171.124 with ZUGFeRD 2.1, GraphicsMagick to 1.3.35, jpeg to 9d, jpeg-turbo to 2.0.5, pcre to 8.44, SQLAPI to 5.1.1, SQLite to 3.33.0 including decimal extension and updated to Xcode 10.6.
Dim browser As WKWebViewMBS = browser.WKWebView //yourwebviewerDim pi As NSPrintInfoMBS = NSPrintInfoMBS.sharedPrintInfo
Dim po As NSPrintOperationMBS = browser.printOperation(pi)
Dim file As FolderItem = SpecialFolder.Desktop.Child("test.pdf")
pi.horizontalPagination = pi.NSAutoPagination
pi.verticalPagination = pi.NSAutoPagination
po.showsPrintPanel = False
po.showsProgressPanel = True
This prints to a file as destination and asks for auto pagination of the pages. We disable print panel, but show a progress panel.
About two weeks ago Xojo Inc. released their Xojo update. It got a lot of attention for the Web 2.0 feature. Between all the complains about r1 coming end of August and Web 2.0 not being finished to what people expected, there are a few good things for desktop developers, but first the Web target:
Over the years I heard a lot of speeches about managing expectations. And I wished Xojo Inc. would have managed expectations better and called the current shipping Web 2.0 support a developer preview. And of course had a spring release with bug fixes and a few features earlier in 2020. For us all web development stays with Xojo 2019 and will move to Web 2.0 probably next year in spring when a few more releases add the urgently needed functionality. Xojo Inc. already announced they will do additions like an improved WebCanvas and some more events for mouse & keyboard. We'll see what will ship later this year.
Tip: When you start a new project, create it in Xojo 2019 and then open it in 2020r1. If the project has 2019 in the header as creation version, then auto complete will show API 1 methods and you can enjoy using msgbox and other familiar commands.
As plugin developer the release has brought developers to update their licenses. There is a notable surge in sales for updates and even new licenses for our Xojo plugins! We welcome the new developers in the Xojo world. Great to see people moving from older versions to the current to try the new features.
As Apple switches to Apple Silicon, their own ARM CPUs, we expect Xojo to soon support that with a new checkbox in the compiler options. And then more developers may want to renew theirs licenses with Xojo to move to a newer Xojo version and support their clients for the new platform. Our plugins already are compiled for Apple Silicon here and Xojo can be the tool to port your app with the click of a checkbox to add universal support. And much later, Xojo may still support Intel as target once Xcode will no longer do that in a few years.
We build all plugins for Linux ARM 64-bit here and would love to see such a target added to Xojo. But that may not be high on the priority list. By making sure things build with multiple compilers (llvm, gcc and Visual Studio), we keep finding bugs as different compilers have warnings for different problems.
Please try 2020r1 for desktop/console projects, play with Web 2.0 and report any issue you see. For Web projects stay with Xojo 2019 in production and move to Web 2 later when a future Xojo release adds missing items. For desktop projects, you may check what changes may be needed going from older to current version, maybe use a few #if XojoVersion >= 2020 then in the code to use newer API where needed.
The examples shipping with MBS Xojo Plugins are currently made with Xojo 2019. We tried to update a few for Xojo 2020r1, especially web projects. But the current Web 2 framework in the Xojo application is not complete yet from our perspective. More like a developer preview, where you take a sneak peal and wait for a future 2020r2 release to include more functionality.
For several examples we miss mouse related events. The WebImageView for example has a Pressed event for example. But misses to tell us where it was pressed, so the ChartDirector examples won't fly.
The missing MsgBox name is annoying as that name is deep in my muscle memory. It can still be replaced with MessageBox instead.
Some projects use WebTimer, which doesn't load properly and show internal trouble. You know when the compiler can't tell you what's wrong and just points to the control name on the layout.
The renamed methods for the API 2 can be adapted, but are very annoying. Why not keep old names with deprecation warnings or just hidden from auto complete.
Finally projects saved with Web 2 in Xojo 2020r1 may not load in older Xojo versions.
So for the rest of this year, we expect our examples to stay with Xojo 2019r1.