Android Question Properties, Functions, Events, etc - where to look?

ProstoSasha

Member
Hi!
I'm a complete beginner, but I'm making my way little by little. And the biggest difficulty is the lack of information on Properties, Functions, Events, etc. Now I'm trying to master "B4XFloatTextField".
Where can all this be seen?
Thank you all!
 

Mahares

Expert
Licensed User
Longtime User
Where can all this be seen?
There are several ways to learn about B4XFloatTextField:
  1. In the forum search box, type B4XFloatTextField, you will get many links. The 6th link in the first page shows you that it is a customview and part of XUI Views library. It tells you a bit about it. B4XFloatTextField - A TextField / EditText with a floating hint
  2. Explore and read some of the posts you see in the search,
  3. Make sure you have the XUI Views library checked in libraries pane on the IDE right side. To see the events available for it, in the IDE type Sub, then tap the space key, then click the Tab key, scroll down to B4XFloatTextField, press enter to see the events.
  4. Start creating simple projects exploring B4XFloatTextField. When you get stuck, ask questions by creating a thread in the forum. You will be surprised how much help you will get.
  5. If you want to get deep into Erel’s code unzip the internal XUIviews.b4xlib library and read the module about it via Notepad ++
 
Upvote 0

ProstoSasha

Member
Oh! Thank you very much! Point 3 of your answer is just fine! I will try.
It's not about B4XFloatTextField (this is just an example), but a general problem: when you look at the library description (example https://www.b4x.com/android/forum/threads/b4x-xui-views-cross-platform-views-and-dialogs.100836 /) there is no basic information there. For example, like here https://www.b4x.com/android/forum/t...-based-on-b4xdialog-and-as_timepicker.149354/
Thank you for responding. And then I fell into despondency))
I don't speak English, and this is machine translation, so I apologize for possible mistakes.
Good luck and success! And simple human joy)
 
Upvote 0

Mahares

Expert
Licensed User
Longtime User
It's not about B4XFloatTextField (this is just an example),
You use the same principle for most other features: Go to the library documentation, familiarize yourself with its features, run its example(s). Resort to forum for help and similar examples. There are several video and non video tutorials also.
Please note that in some library docs made by Erel, you may not quickly absorb it, but he always provides the underlying libraries (especially the b4xlib) for you to unzip and dive into a lot deeper by studying the code.
 
Upvote 0

zed

Active Member
Licensed User
@Mahares forgot the essential.
Welcom.
But he didn't forget to say the right things.
Browse the tutorials, try the examples. Come back to the forum for any questions. There will always be someone to help you.
You'll quickly realize that B4X is awesome.
 
Upvote 0

emexes

Expert
Licensed User
And the biggest difficulty is the lack of information on Properties, Functions, Events, etc.
Now I'm trying to master "B4XFloatTextField".
Where can all this be seen?

I've started using ChatGPT as a starting point. It is not always 100% correct, but is usually better than I expect it to be.

https://chat.openai.com/share/0d1f7726-48bd-473b-9ba6-91c37a213fa7

eg:

User:
show me an example of using the setfont method of b4xfloattextfield

ChatGPT:
As of my last knowledge update in January 2022, B4X (Basic4Android) is a development platform that supports several programming languages, including B4A (Basic4Android), B4i (Basic4iOS), and B4J (Basic4Java). Each platform may have its own specific syntax for working with UI controls.

Here's a general example in B4A, assuming you have a B4XFloatTextField named FloatTextField:



In this example:
  1. We create a B4XFloatTextField named FloatTextField in the Activity_Create sub.
  2. We load a custom font (assuming it's located in the assets folder) using Typeface.LoadFromAssets.
  3. We set the font for the B4XFloatTextField using the SetFont method, passing the loaded font (MyFont) and the desired font size (16 in this case).
Make sure to replace "YourFont.ttf" with the actual name of your font file. Also, ensure that the font file is placed in the assets folder of your B4X project.
 

Attachments

  • 1701182491093.png
    25.6 KB · Views: 72
Upvote 0

ProstoSasha

Member
What a twist!
I will try it.
Thanks!
 
Upvote 0

ProstoSasha

Member
There are several ways to learn about B4XFloatTextField...
Is there a simple regular way to get a complete list of any component?
As in the description of this library (just an example):

  • AS_TimePickerDialog
    • Functions:
      • Class_Globals As String
      • getHour As Int
      • getKeyboardEnabled As Boolean
      • getMinute As Int
      • getMinuteSteps As Int
      • getTimeFormat As String
      • getTimeFormat_12h As String
      • getTimeFormat_24h As String
      • Initialize (Parent As B4XView) As String
        Initializes the object. You can add parameters to this method if needed.
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • setHour (Hour As Int) As String
      • setKeyboardEnabled (Enabled As Boolean) As String
      • setMinute (Minute As Int) As String
      • setMinuteSteps (Steps As Int) As String
        Indicates in how many steps the selector can be moved
        Default: 1
      • setTimeFormat (Format As String) As String
        24h|12h
        Default: 24h
      • ShowDialog As ResumableSub
        <code> Wait For (TimePickerDialog.ShowDialog) Complete (PickerDialogResponse As AS_TimePickerDialog_DialogResponse)
        If PickerDialogResponse.Result = xui.DialogResponse_Positive Then
        End If</code>
      • Theming As AS_TimePickerDialog_Theming
    • Properties:
      • Hour As Int
      • KeyboardEnabled As Boolean
      • Minute As Int
      • MinuteSteps As Int
        Indicates in how many steps the selector can be moved
        Default: 1
      • TimeFormat As String
        24h|12h
        Default: 24h
      • TimeFormat_12h As String [read only]
      • TimeFormat_24h As String [read only]
  • AS_TimePickerDialog_DialogResponse
    • Fields:
      ...etc
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…