The name of the class and functions related in the stack trace changes, but the problem is always the same. Same function in Apples framework wants to call deprecated accessibilityIsAttributeSettable function, but that one is no longer implemented in Apple's own classes. It's a code path which doesn't happen for all users, so only a few get the crash and maybe this is related to some accessibility setting.
Anyway, via a new InstallNSAccessibilityPatchMBS function in our plugin, we'll patch it and install a accessibilityIsAttributeSettable function to just return false every time. If the class has such a method, the class method is preferred, but we install a fallback to avoid the crash.
As you may know you can use MBS Plugins with Xojo and FileMaker to write PDFs with DynaPDF functions. The WriteFText functions accept formatting commands in the text, so you can create various formats. We got a few examples in the following Xojo source code:
Change text rise and size to get footnote references
Change font to get e.g. a bold font
Create lists with hierarchies, numbered entries or multiline entries.
Check the sample code here:
//setfontcall pdf.SetFont "Helvetica", 0, 12.0, true, pdf.kcpUnicode
dim y asDouble = 50//changefontsizeandraiseforfootnotereferences
text = "\FSHelloWorld\FS\TR123\TR\FSJustatest."call pdf.WriteFTextEx(50, y, 200, -1, pdf.ktaLeft, text)
y = y + 20//changefonttogetbold
text = "\FT[Helvetica]Hello\FT[Helvetica-Bold]World\FT[Helvetica]everyone."call pdf.WriteFTextEx(50, y, 200, -1, pdf.ktaLeft, text)
y = y + 20//changecolorinthetext
text = _
"\FC[" + str(DynaPDFMBS.RGB(255, 0, 0)) + "]Red"+_
"\FC[" + str(DynaPDFMBS.RGB(0, 255, 0)) + "]Green"+_
"\FC[" + str(DynaPDFMBS.RGB(0, 0, 255)) + "]Blue"+_
"\FC[" + str(DynaPDFMBS.RGB(0, 0, 0)) + "]Black"call pdf.WriteFTextEx(50, y, 200, -1, pdf.ktaLeft, text)
y = y + 20//makelist
text = _
"\LIThird\EL#"call pdf.WriteFTextEx(50, y, 200, -1, pdf.ktaLeft, text)
The same formatting texts can be used in FileMaker, Xojo and any other development tool supported by DynaPDF like C++, VB, PHP and Delphi.
We got the announcement of an update to ChartDirector:
Advanced Software Engineering is pleased to announce the immediate availability of ChartDirector 6.3.
ChartDirector 6.3 adds support for embedded resources in executables. As embedded resources are mostly used in desktop GUI applications (as opposed to web or command line scripts), so ChartDirector 6.3 is only released for C++ and .NET (C#, VB).
ChartDirector can use images for the chart background, pattern colors, scatter symbols, CDML icons, … In previous versions of ChartDirector, these images have to be provided using file system paths. ChartDirector 6.3 allows these images to be embedded in executables as resources, and uses "resource paths" to access them. This eliminates the need to redistribute image files with the executable.
Apart from images, font files can also be embedded as resources.
In our Xojo plugins we have the IconMBS and IconFamilyMBS classes. They use Apples frameworks with icon functions, but those are not well maintained the last few MacOS releases and we see more and more issues. Probably as a lot of functions are based on the deprecated QuickDraw framework. So we deprecate IconFamilyMBS class for the next prerelease plugin.
So please change code and move to newer functions. For example instead of IconFamilyMBS class to get an icon in various sizes, you can use NSWorkSpaceMBS class methods. IconForFile functions returns the icon for a file and than you can use NSImageMBS class to scale down. With the following code you can quite easily get a 2x picture for a FolderItem:
const SizeWanted = 256 dim file as FolderItem = SpecialFolder.Desktop.Child("test.rtf")
dim n as NSImageMBS = NSWorkspaceMBS.iconForFile(file) //setsizewewant
n.setSize SizeWanted*2, SizeWanted*2
//makepicture dim p as Picture = n.CopyPictureWithMask
//make2xpicturehere: dim q asnew Picture(SizeWanted, SizeWanted, array(p))
If you need an icon for a file type, you can use the IconForFileType function. If you need to add an icon to a file, please use SetIcon method in NSWorkSpaceMBS class.
Wer Interesse hat an einem Termin mit mir für Softwareentwicklung, Schulungen, Entwicklungshilfe, Plugin Empfehlungen, assistierte Fehlersuche, Code-Review und IT-Beratung, der darf sich gerne melden für eine baldige Terminfindung.
The November/December (16.6) issue of xDev Magazine is now available. Here's a quick preview of what's inside:
Munich 2018 by Marc Zeedar
The MBS Xojo Conference in Germany gets bigger every year. This fall it was held in Munich and Marc went so you could stay home and read all about it.
Upgrading Xojo by Jim Meyer
No doubt you have a few older Xojo projects you haven't upgraded to the current version. How much trouble will it be to get them working in the latest IDE? Will it be worth it? Jim shares his experience.
Road Work by Marc Zeedar
These days, programmers can work almost anywhere there's Internet. Marc spent a few weeks in France testing the theory and has tips for working on the road.
Building a Controller by JC Cruz
Jose shows how to build a data-entry controller.
PLUS: Clipboards, database rules, database transactions, Xojo 2018r3, and more!