Comunidad de diseño web y desarrollo en internet online

Chat estilo Whattsapp AS3

Citar            
MensajeEscrito el 30 Oct 2012 03:40 pm
Hola a todos, tengo hecho un chat en Flash + AS3 y para mostrar el chat he usado el componente de Flash "TextArea".
Hasta aquí todo bien, lo que me gustaría hacer ahora es que el texto que se muestra sea siguiendo el estilo del "Whattsapp", es decir, lo que escribe uno a la derecha, lo que escribe el otro a la izquierda y envuelto en un "bocadillo" con distinto color de fondo.
Hay alguna forma de hacerlo? Como se puede implementar?

Muchas gracias

Por Palacio

Claber

198 de clabLevel



 

firefox
Citar            
MensajeEscrito el 31 Oct 2012 02:32 pm
Para cambiar el color de fondo de un TextArea y el texto puedes hacer algo así

Código ActionScript :

var textArea:TextArea = new TextArea()
textArea.textField.opaqueBackground = 0x000000;

var myFormat:TextFormat = new TextFormat();
myFormat.color = 0xffffff;
textArea.setStyle("textFormat",myFormat);


Luego tendras que irlos creando on the fly y agregarlos a algun tipo de contenedor, digamos un MovieClip al que tienes que agregar un scrollBar, la cual finalmente tendras que actualizar cada vez que agregas campos de texto

Jorge

Por solisarg

BOFH

13669 de clabLevel

4 tutoriales
5 articulos

Genero:Masculino   Bastard Operators From Hell Premio_Secretos

Argentina

firefox

 

Cristalab BabyBlue v4 + V4 © 2011 Cristalab
Powered by ClabEngines v4, HTML5, love and ponies.