b5ccf63a85
An Arabic attachment name displayed scrambled. Not a missed setting: FMX's original text engine does not shape complex scripts - no bidirectional reordering, no letter joining. Separating the size from the name limited the damage without removing it. Skia carries HarfBuzz and does the work. GlobalUseSkia goes before Application.Initialize; the canvas is chosen at init and switching later does not reclaim what is already built. The price is libsk4d.so, 25 MB raw, and an APK from 13 to 22 MB. Deploy rebuilds library\\lib just before calling aapt, so a hand-placed library disappears. A proper DeployFile entry was tried first - MSBuild ignores it, as it ignores every other one in this project. Hence repack-apk.ps1, which redoes aapt, zipalign and signing on the folder already prepared. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
41 lines
1.6 KiB
ObjectPascal
41 lines
1.6 KiB
ObjectPascal
program pmserverApk;
|
|
|
|
uses
|
|
System.StartUpCopy,
|
|
FMX.Forms,
|
|
// Skia remplace le moteur de rendu de FMX. Ce n'est pas un choix esthetique :
|
|
// celui d'origine ne met pas en forme les ecritures complexes - pas de
|
|
// reordonnancement bidirectionnel, pas de liaison des lettres arabes - et un
|
|
// nom de piece jointe en arabe s'affichait donc en desordre. Skia embarque
|
|
// HarfBuzz et fait ce travail correctement.
|
|
//
|
|
// Le prix est libsk4d.so, 25 Mo, a poser dans lib/arm64-v8a de l'APK. Le
|
|
// deploiement automatique s'en chargerait ; ici il ne deploie rien, donc la
|
|
// bibliotheque est mise en place a la main comme le manifeste et les .dex.
|
|
FMX.Skia,
|
|
mainApk in 'mainApk.pas' {Form8},
|
|
PMA.Crypto in 'android-client\PMA.Crypto.pas',
|
|
PMA.TestVector in 'android-client\PMA.TestVector.pas',
|
|
PMA.SyncClient in 'android-client\PMA.SyncClient.pas',
|
|
PMA.Store in 'android-client\PMA.Store.pas',
|
|
PMA.Biometric in 'android-client\PMA.Biometric.pas',
|
|
PMA.Vault in 'android-client\PMA.Vault.pas',
|
|
PMA.Totp in 'android-client\PMA.Totp.pas',
|
|
PMA.ScreenGuard in 'android-client\PMA.ScreenGuard.pas',
|
|
PMA.Clipboard in 'android-client\PMA.Clipboard.pas',
|
|
PMA.Theme in 'android-client\PMA.Theme.pas';
|
|
|
|
{$R *.res}
|
|
|
|
begin
|
|
// AVANT Application.Initialize : le canevas est choisi a l'initialisation,
|
|
// et le basculer ensuite ne rattrape pas ce qui est deja construit.
|
|
GlobalUseSkia := True;
|
|
Application.Initialize;
|
|
// Le style se pose apres l'initialisation mais avant la forme : l'appliquer
|
|
// plus tard laisserait les controles deja construits avec l'ancien.
|
|
ApplyDarkTheme;
|
|
Application.CreateForm(TForm8, Form8);
|
|
Application.Run;
|
|
end.
|