[fpc-pascal] VCL4J and its future

2021-07-31 Thread Mgr. Janusz Chmiel via fpc-pascal

Dear advanced professionals here,

There are currently two big projects which empowering PPCJVM Android JVM 
target. It is Pandroid and VCL4J. While Pandroid is professionally 
finished project, which do its best to give programmers possibility to 
create Pascal apps which are able to communicate with Android Java APIS, 
VCL4J had very probably other goal.


Allow Pascal programmers to create Pascal applications with minimal need 
of combining Java language with Pascal language at The command line. And 
I would like to kindly plea all most advanced experts here for their 
programmers opinion.



Does somebody of us think, that it would be possible to extend VCL4J so 
users would be able to call Android APIS so professionally like from 
Pandroid package?


Currently VCL4J can be still downloaded from here.


svn checkout https://svn.code.sf.net/p/javavcl/code/ javavcl-code

Project has still one may be very non remarkable advantage, but for 
classic style of Pascal programming, it is possible to use blockread, 
blockwrite, assign and other commands. Compiled app also support 
run-time error messages which are very professionally constructed. 
Bundle also contain very useful system units. I would like to know, if 
somebody very advanced here would create simple app, which would be able 
to directly interact with Android API functions. Or if it is really 
impossible and only Pandroid package contain The onlyone way to interact 
with Java stuff from Pascal by using PPCJVM and Android Target. Sure. 
Sighted majority can use The following well developed bundle.



https://github.com/jmpessoa/lazandroidmodulewizard

But because I Am too stupid to use this project without .lfm files and I 
can not my own way to use it without forms and its visual designer, it 
is project which is good for sighted majority, but not so good for 
visually impaired minority. This is The reason, why I still prefer Pandroid.



VCL4J also support Delphi VCL adjectives to position objects on The 
screen. Altop, allbottom, alright, etC. Using numbers to specify object 
dimensions is not mandatory, but I Am aware, that I can reach very ugly 
GUI if I will simply ignore those values, so Explore by touch Android 
service allow Me to use screen reader and I can use such GUI, but it 
will be not very pleasant GUI for sighted majority.


Thank you very much for yours time and for yours debate about VCL4J.



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] bundle tool and app bundle

2021-07-27 Thread Mgr. Janusz Chmiel via fpc-pascal
It should be possible to create App bundle file by using instructions 
available here.



https://developer.android.com/studio/build/building-cmdline

In The article session formatted as Heading number 4 named Build your 
app bundle using bundletool


Sure, it would had to be necessary to automate some tasks by using .bat 
or Sh script related to file copy to specific new folder. But for my 
personal needs, .apk format is The best choice, since app bundle format 
is not suitable for installing apps on The Android devices. It is 
intermediate format used by Google so they can sign and create .apk 
themselves according to GOogle policy. So it is possible to 
automatically generate .apk files for various devices and Android versions.



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] ppcjvm android30 target and recompilation of pascal units

2021-07-27 Thread Mgr. Janusz Chmiel via fpc-pascal

Dear specialists,

    Because Google  require that every developer, who would like to 
publish on Google Play store must build his apps by using Android 30 
target, there is A question. Is it necessary to build PPCJVM Android 
target units such as system.pu to use this newest Android target 30? Or 
it is not necessary? I have tried to use older generated units and there 
was no problem, when I have used Android 31 target, because 31 Android 
platform can be automatically downloaded by using latest Android studio 
when running it after installation.


Unfortunately, there is very big issue, which can prevent developers to 
use PPCJVM to create apps for Play store. Google also require, that 
programmer will publish app by using new format called Android App Bundle.


Thank you very much for yours questions related to recompilation of 
system unit and other.


I do not assume, that Android studio code will allow us to simply put 
.class files or other files somewhere generated by PPCJVM or Apache Ant 
and simply create app bundle for us from other code than The code, which 
have been created from Android Studio. May be, that there could be some 
work around, but I do not know about it.



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] gritwiev layout issue

2021-07-23 Thread Mgr. Janusz Chmiel via fpc-pascal

Dear specialists,

    I AM very sorry that I have spammed this mailing list by using my 
messages on HTMl format. Unfortunately, I can not find out, how to setup 
Microsoft E-mail Windows 10 app available on Windows store to send 
messages in plain text. So I have decided to communicate by using 
Thunderbird on this mailing list.



I would like to plea some advanced developers here, if somebody would 
write Me, how to convert The following XML attributes to Pandroid 
package compatible format.



android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:stretchMode="spacingWidthUniform"


Here are my settings.

Adapter := AWArrayAdapter.create(Self, 
AR.innerLayout.simple_list_item_1, items);

GridView.setVerticalSpacing(24);
GridView.setHorizontalSpacing(10);
GridView.setStretchMode(AR.Innerattr.COLUMNWIDTH);

But how to add

stretchMode="spacingWidthUniform"

To get PPCJVM Android JVM target compatible line of code.



  GridView.setColumnWidth(100);
  GridView.setNumColumns(AWGridView.AUTO_FIT);
I Am working with Pandroid for Windows package available from here:


zeljkoc/PandroidPackage: Package for Lazarus , Create android 
application (github.com) 


I Am calling AndroidR25 APi functions because I need to have ignore 
battery optimisations feature working.


Thank you very much for yours help and for yours programmers time.

With deepest appreciation and with The kindness regards.

Janusz Chmiel


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] ppcjvm and android applications development

2021-07-21 Thread Mgr. Janusz Chmiel via fpc-pascal
The majority of Lazarus developers will very probably prefer Android apps development by using LAMW for many reasons. Core elite programmers, who are concentrated around this project are doing their best to bring their own high wquality form designer. Android APIS are specially called by using their preprepared .pas sources so developer do not have to wory about direct communications with Android Api functions. In fact, programmer do not directly work with Android Pascal Android Api header files.Project is being developer very fast and there are more and more preprepared examples.App is based on JNI Android build in approach. The most important parts of Pascal app is being directly translated to The machine code by using ARM assembler. Android NDK tools are doing its best to prepare native .so library, which run perfectly on many devices. Because resulting project is being translated to machine processor code, it run very fast. As A result, resulting apps can be complex such as video or audio editor. Because routines will work really by using machine code. No Java virtuál machines. Next important fact is, that resulting GUI is very Accessible for screen readers users. But I do not want to talk about Lamw project. I would like to introduce two other projects, which can be used to create Android app by using Free Pascal compiler.It is Pandroid and Java VCL.Pandroid have been made in two forms. As A Linux bundle or as A Windows package. Here is Linux bundle. https://github.com/zeljkoc/pandroid And here is its Windows bundle compatible with Lazarus for Windows.https://github.com/zeljkoc/PandroidPackage Both forms of Pandroid bundles can produce .dex files generated from .class files. And it is even possible to incorporate support for native .so library creation. The advantage of Pandroid is its simple programmers design. Programmer do not have to combine .xml GUI layout files with .pas or .lpr sources. XMl attributes can be added to The .lpr or .pas files. Programmer do not have to type Hexadecimal constants to allow GUi to be created by using .xml layout related files.This project is also unique, because it support many versions of Android API Pascal header files. So programmer work really with Android APIS. Developer can or do not have to use DI or Pixel coordinates to specify every object on screen. Resulted apps are stable and fully compatible with Android screen readers based on build in Explore by touch Android systém service. Pandroid have been made by The way, so programmers can call Android API functions without complex issue. No error messages from FPCJVM run-time library occurs when calling Api functions.Programmer can compile to Android 29 API version so resulting apps can be safely published on Google Play store. Linux form of The bundle contain usbserial.pas API headersto communicate with USB connected devices, if Android device support USB on The go. Warning! Kernel must support The device which you would like to connect. There is even possibility to communicate with Bluetooth devices. Warning! If you would like to test all samples which are build in to Linux form of The Pandroid Bundle by using newer than Android R15 header files, may be that you will occur some issue.But AndroidR29 targets are really working. I Am not getting error message from Google Play protect app. Pandroid allow flexible programming. .lfm forms can be also used.If you will be publishing to The Play store, try to do yours best to use SDK manager to INSTALL The latest version of Android29 Platform. Because even Android Platform versions can be updated and it can contain important security updates. So use SDK manager to do that. Do not use bundled Android Platform version as A build target, because Google Play will refuse yours app and devices which will be using this app by isntall it outside The Play store will display warning. App can run, but warning can make users to be afraid because of this message.If you will try to use AndroidR29 Pascal Api header files, you will get errors when building some code, which create GUi and overide word is presented. Unfortunately, my brain is too stupid to find out Why is it so. But AndroidR25 APIS contain enough new functions. You can use newest API headers ir you do not want to create GUI.Or there is may be other stratégy to overcome this issue.Pandroid also contain Mysql databases support. Bundle is stable and usable for professional work, ecause its authos is using it actively to develop apps for big company. And his apps are perfectly working every day for many workers of this company. javavcl This older bundle have been primarily created to allow users to use Object pascal to create fully Accessible and fully functioning Java .jar compiled apps. Resulting apps are fully compatible with screen readers, so bundle is ideal for all programmers, who do not love Java and who would like to create .jar files by using Windows.Bundle contain also Lovecalc Android app, which showsThe techniq

[fpc-pascal] request ignore battery optimisation simple dialog recall plea

2021-07-21 Thread Mgr. Janusz Chmiel via fpc-pascal
I can not find out, how to recall simple form of ignore battery optimisation Android build in dialog. I do not want The complex dialog which consistsof many items such as list of allowed apps. Java developers of Termux Android application have made The following code to recall simple form of ignore battery optimisations dialog window build in to Android SYSUI.Here is The corresponding Java code to recall this dialog window.    String packageName = getPackageName();    if (!pm.isIgnoringBatteryOptimizations(packageName)) {    Intent whitelist = new Intent();    whitelist.setAction(Settings.ACTION_REQUEST_IGNORE_BATTERY_OPTIMIZATIONS);    whitelist.setData(Uri.parse("package:" + packageName));    whitelist.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);  Code become from termuxservice.java module. COuld somebody of us would find The way how to recall this dialog by using Pascal language, Pandroid package and AndroidR25.INC Api header files? Thank you very very much for yours help. Sure! It is possible to recall complex ignore battery optimisation dialog from Android settings, but I do not want this dialog window to be used.Thank you for yours programmers help.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] gritwiev layout issue

2021-07-21 Thread Mgr. Janusz Chmiel via fpc-pascal
I AM using Pandroid for Windows package available here.https://github.com/zeljkoc/PandroidPackageI need to setup The following XMl attributes to make Gritwiev to look more attractively.    android:layout_width="match_parent"    android:layout_height="match_parent"    android:gravity="center"    android:columnWidth="100dp"    android:numColumns="auto_fit"    android:verticalSpacing="24dp"    android:horizontalSpacing="10dp"    android:stretchMode="spacingWidthUniform" I have followed The tutorial available from here. https://www.raywenderlich.com/995-android-gridview-tutorial I have issue how to create FPCJVM compatible line android:stretchMode="spacingWidthUniform" And also lines    android:layout_width="match_parent"    android:layout_height="match_parent"    android:gravity="center" are problematic too. I AM calling AndroidR25 API Pascal headers created by MR Željko Cvijanović. I need to call those new API functions version to be able to recall Ignore optimisation dialog window on Android. I know, that MR Bart have used much mmore different approach. He has used other technique so user could create androidmanifest.xml with The same official format. So XMl attributes could be simply pasted from The article which I have followed. Unfortunately, I AM not sure, if The approach from MR Bart can be safely used also with new Android Pascal Api header files.I Am writing about app which is available here and it is excellent example of The programmers technique to build running Android apps by using only FPCJVM Android JVM target. https://lazarus.lazarus.freepascal.narkive.com/37AJSzpC/finished-full-jvm-android-applicationDo you think, that I could use this older approach to over come some issue with XML tags? So I do not have to transfer XML format to Pascal compatible format?I do not see at all but I want to create acceptable user interfaces also for sighted majority. 
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] please where is fpc-3.2.0rc1.arm64-linux

2020-05-17 Thread Mgr. Janusz Chmiel via fpc-pascal
Dear specialists,
Please is there some precompiled Linux ARM64 Binary of fpc-3.2.0rc1?
Because I can only find ARM not ARM64 Bit precompiled binary.

May be, that compiler is stored on some FTP site, but I have analysed
ftp.freepascal.org and I did not found.
Thank you for yours advice.

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] PPCJVM and Android Bionic compatibility question

2020-02-02 Thread Mgr. Janusz Chmiel via fpc-pascal
I Am very sorry. I have thought, that when I only change The subject of The
message, so that it will start new thread. I will be careful on this. So
instead pressinf reply to all on other thread, I will always type A new
message. I Am very sorry, some times I forget on The mailing list techniques
and some time I do error.

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] PPCJVM and Android Bionic compatibility question

2020-02-02 Thread Mgr. Janusz Chmiel via fpc-pascal
Dear specialists here,
How complex would be to recode Free Pascal compiler for ARM and
ARM64 Bit so it would be fully compatible with Android Bionic library, so it
would be executed as A external app from some Android app which have GUI?

Sure. There is even Termux which can run many Linux distros by using Proot.
But it would be really very very useful, if it would be possible to recode
PPCJVM so atleast this compiler would work directly on Android ARM and ARM64
devices by using Android OS without complex software modules such as whole
Termux, Proot and some Linux distribution.

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] would be possible to create .dex file from PPCJVM .class files with no depend on App compat library

2020-01-29 Thread Mgr. Janusz Chmiel via fpc-pascal
Dear specialists,
Does somebody of you know, if it would be possible to build functional
Android app from PPCJVM created .class files which will not depend on App
compat jar library?
I have found two fully functional solutions, which do not used appcompat
library.
Scatter on GOogle Play named create Android apps and one Termux project,
which have been created by MR Sdrausty. It build .apk packages with minimal
dependencies and fully functional, .dex sizes can be 40 100 KB, ETC.

But unfortunately, there is very very few projects, which can build .dex
files from .class files, which have been created by Free Pascal compiler.
My goal is to reduce memory allocations and increase GUI speed while
touching screen with Android accessibility suite. I believe, that if
resulting app have minimal dependencies, it allocates less memory and its
GUI responsiveness can be much more faster.
Mr Sven Bard have created one functional app several ayears ago. it was
metro organizer app.
It is very sad, that nobody have released good Android app builder which is
based on PPCJVM, it would allow developers to create very small
applications.


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal