Hi friends,
with this extension we can create Buttons, Labels, Textboxes, Images and Sliders by code in a Layout (Arrangement).
- Features:
-
Set width and hight.
-
Set position in Arrangement.
-
Colors.
-
If you click over Button, Label or TextBox, trigger an event.
-
Rotate: 0 - 360, you can set Components in vertical or other angle.
-
Font Type Face, you can load a FTF file in asset, example: sevillana.ttf for Buttons, Labels and Textboxes, if this String is empty, font is set in Design.
-
TextAlignment, number: 0 - 6
-
Slider with rotate 90, is a Vertical Slider.
-
Remove all, remove all views (and layout)
-
List Views (example):
android.widget.Button{109d336ad VFED…C… … 210,220-360,345 #2} -
If you create Views, then change to other Screen and then return, views are removed.
New version:
- Slider with initialPosition.
- Slider with StopTrackingTouch.
- Create Images.
- Feliz Año Nuevo.
- Juan Antonio Villalpando.
**
http://kio4.com/appinventor/294_extension_crear_componente.htm
**
Hola amigos, con esta extensión podemos crear Botones, Etiquetas, CajaDeTextos, Imágenes y Deslizadores mediante código, además podemos poner nuevas fuentes, en el ejemplo he puesto la fuente sevillana.ttf.
También puedes poner los componentes en cualquier ángulo, por ejemplo si pone el rotate a 90, podremos ponerlos en vertical, así podemos tener un Deslizador en vertical por ejemplo.
Se puede situar los componentes en cualquier lugar del Disposición, incluso se pueden poner unos encima de otros.
Si están en una pantalla, por ejemplo la Screen1, cambias de pantalla y vuelves a la anterior, los componentes creados se borran. Podrías poner la creación de componentes en el bloque de inicio de pantalla para que se crearan cada vez que arranque la pantalla.
En la nueva versión he agregado la posibilidad de crear Imágenes, en el Deslizador podemos poner la posición inicial y también un evento que sucede cuando soltamos el Deslizador.
He puesto más información en:
http://kio4.com/appinventor/294_extension_crear_componente.htm
p194_crear_componentes.aia (100.4 KB)
com.KIO4_CreateView.aix (17.8 KB) (version 2)
com.KIO4_CreateView.aix (18.2 KB) (version 3)(april 2018)
com.KIO4_CreateView.aix (18.3 KB) (version 4) (may 2018) (last version)
-
Version 3:
-
Different way of dimensions width, height, topmargin, leftmargin.
-
RemoveViewAt, when write his number, remove that view. (Example in: Post79)
-
Version 4:
-
Now with NumbersOnly in TextBox.