New in this prerelease of the 23.1 plugins:
Download:
monkeybreadsoftware.de/xojo/download/plugin/Prerelease/ or
from DropBox.
Or ask us to be added to our shared DropBox folder.
While Xojo has some threading support, it could do better and today we think what would be needed for this.
Allow callbacks on other threads
Several modern APIs on all platforms may require you to provide a callback function, so you may just have a little global method called with a parameter. You remember the parameter and regularly check with a timer if the value was set. e.g. a code like this:
Sub MyCallback(granted as boolean)
GlobalModule.isGranted = granted
GlobalModule.gotResult = True
End Sub
This is the most simple way to do a callback, which may receive on a non-Xojo thread from the OS or a library. The code generated by the compiler looks like this translated back into Xojo code:
Sub MyCallback2(granted as boolean)
StackCheck
Var currentException = GetCurrentException
If currentException = Nil Then
GlobalModule.isGranted = granted
GlobalModule.gotResult = True
End If
If CurrentException <> Nil Then
ReraiseException(CurrentException)
UnlockObject(CurrentException)
End If
End Sub
(more)
Just two months left until the
XDC 2023 in London, England. Tickets are still available for $525 USD.
It will be held
April 26-28, 2023 in London, England at the
Hilton London Euston. 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.
Check out the
conference highlights video if you want to see what it's like - or ask one of the many attendees from the forum!
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. The first sessions are already listed, so
check the list and the
schedule.
To get there, please use public transportation. The piccadilly line brings you right from Heathrow Airport to Russell Square Station, near 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.
See you soon there!
This blog has his 15th anniversary today. We hope you enjoy reading it!
If you have idea for future blog posts, please let us know.
New in this prerelease of the 23.1 plugins:
- Fixed a problem with LinuxMoveMouse method in RemoteControlMBS module not working correctly.
- Fixed problem in BarcodeGeneratorMBS, where a warning from the zint library would be treated as an error.
- Updated LCMS2 library to version 2.15rc1.
- Updated CURL library to version 7.88.1.
- Added WebView2CookieManagerMBS and WebView2CookieMBS classes.
- Updated libxml to version 2.10.3.
- Disabled FTP access in libxml to avoid unintended network access.
- Fixed problem in SVG method in BarcodeGeneratorMBS class to work again.
- Updated SQLite to version 3.41.0.
- Fixed a bug in GetStoreProductsAsync method in WindowsStoreContextMBS class.
- Added GetAppLicenseSync method in WindowsStoreContextMBS class.
- Added PrintToPdf method and PrintCompleted event to WebView2ControlMBS class.
- Added boolean return to SetNeedAppearance method in DynaPDFMBS class.
Download:
monkeybreadsoftware.de/xojo/download/plugin/Prerelease/ or
from DropBox.
Or ask us to be added to our shared DropBox folder.
Since their invasion of Ukraine, the Russian military has bombarded Ukraine for twelve months. As of today, both sides still belief they can win the war, so we have no negotiations. And don't be fouled: This war could be over tomorrow, when Russia decides to move out of Ukraine.
And I don't think the majority of Russian people supports this war. The average Russians has no benefit and may see their relatives and friends get conscripted and die in a war they don't want. The war is certainly not about supporting some Russian people in Ukraine, but more likely to get a land bridge to Crimea with the Russian naval base in Sevastopol. And no idea why they didn't start 20 years ago to move the base to Russian territory on the Black Sea.
The biggest change for us in all the war time is to get independent on our power supply. Shortly after the invasion started, we requested offers for photovoltaik systems. Solar cells, battery pack and a controller system to make sure we use our own power as long as possible and just use the grid as backup. And when I look around on the other houses, I see quite a lot of people coming to the same conclusion: We as a country have to reduce imports of fossil fuel and what individual houses owners can do is to first to use solar energy to heat water (to support e.g. a gas heating) and second to use photovoltaics to make our own power. Don't forget the battery to store power and use your own energy at night.
As of today our photovoltaik system is working and already produces a lot of energy. On sunny winter days about 50 kWh, which is enough to fill the battery and serve our own needs. And even on cloudy days it produces a few kWh and reduces our power purchases a lot. We ordered a battery extension already to make sure we can store more energy to avoid buying energy even further. And we ordered the extension to run the system standalone without power from the grid.
On a bigger level like state or county, we can support efforts to build wind turbines and new power cables to connect them. We may get wind turbines nearby in the next years here. Not as efficient as a the coast, but a possibility to reuse an older one from the coast, which got replaced with a better one and is paid off.
This war changes the world and in a few years, it may be over. But the world will be different and I expect Russia will not come back to its previous power and less exports as they used to. Not to mentioned that they loose a lot of people in the war or due to evading conscriptions.
Let's do our best to help the Ukraines to get back peace by kicking out the Russian Army!
New in this prerelease of the 23.1 plugins:
Download:
monkeybreadsoftware.de/xojo/download/plugin/Prerelease/ or
from DropBox.
Or ask us to be added to our shared DropBox folder.
As you may know we have with ChartDirector a powerful library to make high quality charts for all operation systems and output them as pictures or PDF documents. We can show them interactively in a control to let the user click on values with the mouse.
As you may know we added 7 years ago the ScaleFactor property to the
CDBaseChartMBS class. It allows you to set a scale factor, which is used by our plugin to multiple all size values before passing them to ChartDirector. This way we got scaling for HiDPI into ChartDirector years before it was built-in.
(more)
As you may know we have our own MBS Xojo SQL Plugin for Xojo, which is an alternative to the built-in database classes in Xojo. Let us show you how we do a few things with our plugin, which you may not do like this with the official database plugins in Xojo.
The MBS Xojo SQL Plugin is a Xojo plugin for accessing multiple SQL databases (CubeSQL, Centura SQLBase, DB2, DuckDB, Firebird, Informix, InterBase, MariaDB, Microsoft Access, Microsoft SQL Server, MySQL, ODBC, Oracle Database Server, PostgreSQL, SQL Anywhere, SQLite, SQLCipher and Sybase). It uses native APIs of target DBMS so applications developed with this plugin run swiftly and efficiently. The product also provides a low-level interface that allows developers to access database-specific features. By encapsulating a vendor's API, the plugin acts as middleware and delivers database portability.
Trace Log
Our plugin has a Trace event in SQLDatabaseMBS and SQLConnectionMBS classes. You may decide to either subclass these classes and implement the event. Or you use addHandler to connect the event to your method to log SQL requests. The trace event provides all SQL run by the plugin and is at a low level, so it catches also the insert statements made by AddRow or InsertRecord methods.
e.g. like this sample implementation, which uses a TraceEnabled boolean property in SQLDatabaseMBS subclass to toggle whether we log SQL for debugging:
Sub Trace(traceInfo As Integer, SQL As String, Command As SQLCommandMBS)
If TraceEnabled Then
System.DebugLog SQL
End If
End Sub
(more)
For MBS Xojo Plugins 23.1 we add new classes to use the built-in OCR in Windows 10. Similar to the Vision framework on macOS, these classes provide an easy way to use the text recognition in Windows. We got these classes:
You can query the available languages on your computer with the AvailableRecognizerLanguages method. This usually only includes the installed language packs for Windows like in Germany the German one. But you can go to system settings and install another language if you need it.
(more)
New in this prerelease of the 23.1 plugins:
- Fixed a crash in ToHTML method in JSONMBS class.
- Added Command and Aggregate methods to MongoCollectionMBS class.
- Added Aggregate method to MongoDatabaseMBS class.
- Updated LibXL to version 4.1.
- Added IsWriteProtected method to XLBookMBS class.
- Added TabColor, DefaultRowHeight and GetTabRgbColor method to XLSheetMBS class.
- Added AddSelectionRange, GetActiveCell, GetTabRgbColor, RemoveSelection, SelectionRange and SetActiveCell to XLSheetMBS class.
- Improved CallDelegateCrashSafeMBS to check for stack corruption and prevent recursion.
- Improved CallDelegateCrashSafeMBS to catch trace trap signals and C++ exceptions.
- Updated tiff library to version 4.5.0.
- Improved WindowsOCREngineMBS class.
Download:
monkeybreadsoftware.de/xojo/download/plugin/Prerelease/ or
from DropBox.
Or ask us to be added to our shared DropBox folder.
We got a bit annoyed with the NAS being busy all day with various backups. And whenever two or three Macs do their Time Machine backups at the same time, the performance of the NAS goes way down with all the seeking of the hard disks.
Let's change Time Machine to run less often. As you may know Apple doesn't allow much configuration there for the backup interval and you can't change the system launch agent. But we can disable Time Machine in system preferences and make our own launch agent.
First you make a new text file (e.g. with BBEdit) with this content:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.monkeybreadsoftware.runbackup</string>
<key>ProgramArguments</key>
<array>
<string>/usr/bin/tmutil</string>
<string>startbackup</string>
<string>--auto</string>
<string>--rotation</string>
</array>
<key>StartInterval</key>
<integer>43200</integer>
<key>StandardOutPath</key>
<string>/tmp/runbackup.output.log</string>
<key>StandardErrorPath</key>
<string>/tmp/runbackup.error.log</string>
</dict>
</plist>
(more)
LibXL version 4.1.0 is available with this news:
- added the conditional formatting support for xlsx files
(new ConditionalFormatting and ConditionalFormat classes)
- added the possibility to get/set an active cell and selection ranges
- added the possibility to get a color from sheet tabs
- improved the string overwriting performance for xls files
- improved the reading performance for xlsx files
- improved the sorting performance in AutoFilter (xlsx)
- added ARM64 support for Windows
- fixed a bug with cutting sheet names to less than 31 characters in Chinese
- fixed a bug with loading some xls files ("Label size is incorrect")
- fixed a bug with union multiple column filters in the Sheet::applyFilter() method (xlsx)
- fixed an issue with loading some xls files (error message "invalid jpg file")
- fixed an issue with encoding dates before the 1st of March 1900 in the Book::datePack()
- fixed an issue with loading some xlsx files with special unicode character BOM (byte order mark)
at unexpected position inside XML files
- fixed issues with copying existing sheet with named ranges in the Book::insertSheet() what led to corrupted output files
- fixed a new-delete-type-mismatch memory issue on Linux and now LibXL works with jemalloc properly
- fixed an issue with saving UTF-8 encoded filename in the Book::save() method on Windows (xlsx)
- fixed a hanging issue with loading some xls files
- fixed a bug with saving xlsx files with a lot of OLE objects
- removed the PY_SSIZE_T_CLEAN warning in python interface
The LibXL library can be used with MBS Plugins in Xojo and FileMaker. Updated plugins will be available soon. As usual we add the new functions soon. If you need help or want to try the new version early, let me know.
New in this prerelease of the 23.1 plugins:
- Added OCR classes for Windows: WindowsOCREngineMBS, WindowsOCRExceptionMBS, WindowsOCRLanguageMBS, WindowsOCRLineMBS, WindowsOCRResultMBS and WindowsOCRWordMBS classes.
- Added ChangeNamedDest method to DynaPDFMBS class.
- Added kpvPDFUA1 constant to DynaPDFMBS class to use PDF/UA-1.
- Added krfRenderPrintState constant to DynaPDFRasterImageMBS and DynaPDFMBS classes.
- Added LoadLibrary, LibraryError and Available to JSContextMBS class.
- Added NamedDest and Action properties to DynaPDFBookmarkMBS class.
- Added optional rectangle parameter for OpenTag() function in DynaPDFMBS class.
- Added Options and TLS properties to MongoURIMBS class.
- Added support for JSContextMBS class to work on Windows and Linux if you provide a JavaScriptEngine library file to load.
- Added YieldToRB property to LCMS2TransformMBS class.
- Changed DatabaseName property in MongoURIMBS to be writable.
- Deprecated isLeopard, isSnowLeopard, isLion, isMountainLion, isWindows2000, isWindowsXP and isWindowsVista in SystemInformationMBS module since our plugins don't run there anymore.
- Deprecated WinCSDVersion and WindowsAero properties in SystemInformationMBS module.
- Deprecated WinServicePackMajor and WinServicePackMinor properties in SystemInformationMBS module.
- Fixed a bug with library loading for aarch64 on Linux for libiconv, libidn2 and libldap.
- Fixed isMonterey and isVentura to report correctly SystemInformationMBS module, broken in 23.0.
- Improved our BluetoothLE plugin classes for Windows to not leak objects on calling events.
- Patched SQLAPI to work again with Field() query without FetchNext.
- Removed 32-bit plugin parts for macOS.
- Removed PictureFromXFaceStringMBS, PictureFromXFaceMemoryBlockMBS, PictureFromXFaceMemoryBlockMBS and XFaceStringFromPictureMBS functions.
- Removed WindowsGrowlMBS, GrowlMBS, GrowlNotificationMBS and GrowlApplicationBridgeMBS classes.
- Updated DynaPDF to version 4.0.71.204.
- Updated XL Plugin to include library for Windows 64-bit ARM.
Download:
monkeybreadsoftware.de/xojo/download/plugin/Prerelease/ or
from DropBox.
Or ask us to be added to our shared DropBox folder.