Search the Community
Showing results for tags 'kastri'.
Found 4 results
-
Supporting iOS Dynamic Type (accessibility font size) in Delphi FMX apps
happySuzhou posted a topic in FMX
As I advance in age, I'm finding small text size in apps is becoming quite annoying and I'm realizing I should be doing a bit more to improve accessibility features in my own Delphi apps, particularly for iOS. I've been reading about the Dynamic Type settings in Apple iOS (I have my own device set on a larger text size too). I want my own app to show larger text across the whole app if a user has set this up on their device. But I'm struggling to see how to implement this in a Delphi FMX app. One solution seems to be to dip into the (brilliant!) Kastri library and pull out TUITraitEnvironment and LTraitCollection and read preferredContentSizeCategory. Kastri already has functions/properties for accessibility features. I could then set my main form's layout scale accordingly. Something like the attached (trying to follow and learn from other functions in Kastri units). Another alternative might be to change some setting (?) or the plist or something so that FireMonkey automatically adjusts the default font size in my StyleBook(s). Could anyone advise me? I must admit I'm finding it really hard to find relevant web pages on Delphi and Dynamic Type without the search engine showing information about RTTI instead of the similarly named Apple iOS feature. I could add a scale button on the app, of course, but I was hoping to help users like myself who don't like to reach for their reading glasses every time they launch a small font sized app. Also, if there's an obvious cross-platform setting I'm missing, please do point out the obvious! Best wishes and thanks in advance! supportinglargertext.txt -
Good morning, i now switch to send push notifications with firebase using the new method legacy with token with the example in kastri. I port the example in a thread and then implment the method. Can i use the example in a multi thread enviroment or some operation must be execute in main thread? I reported a small implementation of thread but sometime i get showmessage "Nothing to do ". Can someone help me? I attached an small example of my thread. Thank you Andrea Esempio.pas
- 3 replies
-
- firebase
- push notifications
-
(and 1 more)
Tagged with:
-
Hello, I've implemented Google authentication on my app using Firebase and the Kastri library. I've done all the configurations as per the GoogleSignin example project. On iOS, both in demo and on the Store, it works perfectly. On Android, it works correctly if I compile in development, but if I compile for the Store and upload it, the authentication returns a code 10. I've checked all the SHA-1 fingerprints for KeyStore.debug, development KeyStore, and the app in the Google Store at https://console.firebase.google.com/. I'm using the Client ID generated for the Web App (as per the example instructions) and not the Android ones (which just don't work). Do you have any suggestions on what it could be? Thanks Massimiliano
-
I am having a problem using the PDFControl on Android device. Have followed the example code for using the PDFControl in demo provided by Kastri but all I get is the PDF displayed in a narrow vertical area (small, about 10mm wide) up the middle of the screen. In the onCreate event I have placed if TOSVersion.Platform = TOSVersion.TPlatform.pfAndroid then begin FPDFControl := TPDFControl.Create(Self); FPDFControl.Align := TAlignLayout.Client; FPDFControl.Parent := TabItem17; end; The PDF needs to be displayed in TabItem17 of a TabControl. TabItem17 has nothing on it except for a TLayout at bottom of screen with a button to enable return to another TabItem. Following is the code used to load and display the PDF procedure TMainForm.Display_PDF(const sFile : string); begin {$IF DEFINED(ANDROID)} if FPDFControl <> nil then FPDFControl.LoadPDF(sFile); TabControl1.SetActiveTabWithTransition(TabItem17,TTabTransition.Slide, TTabTransitionDirection.Normal); {$ENDIF} {$ifdef win32} PDFBrowser.Navigate('file://' + sFile); TabControl1.SetActiveTabWithTransition(TabItem13,TTabTransition.Slide, TTabTransitionDirection.Normal); {$ENDIF} end; Can anybody please help with what I need to do to display the PDF properly. Thanks in advance. Bill Zwirs