Comunidad de diseño web y desarrollo en internet online

Tengo problemas con El componente TEXTAREA

Citar            
MensajeEscrito el 22 Abr 2006 04:53 am
Hey ojala puedan ayudarme, baje el ejemplo de el tutorial textarea y me funciona perfectamente pero lo que quiero saber es como ponerlo en otra posicion osea cuando carga el textarea lo hace en la pocisión :( :(
X: 0.0
Y: 0.0
y quiero moverla pero no se como... gracias de antemano...

Por rik_rik

11 de clabLevel



Genero:Masculino  

msie
Citar            
MensajeEscrito el 22 Abr 2006 06:38 am
hola. supongo que se refiere al codigo del tutorial del componente textarea, que es este. agregando simplemente dos líneas que pasan valores a las propiedades _x _y del mismo depues del attach
Algo asi:
mi_texto._x = 100;
mi_texto._y = 100;


//Atacheamos el componente
attachMovie("TextArea", "mi_texto", 1);

//Propiedades
mi_texto.setSize(300, 200);
mi_texto.editable = true
mi_texto.html = true;
mi_texto.maxChars = null;
mi_texto.password = false;
mi_texto.restrict = "^aeiou";
mi_texto.wordWrap = true;
mi_texto.vScrollPolicy = "on";
mi_texto.hScrollPolicy = "off";
mi_texto._x = 100;
mi_texto._y = 100;


//Texto
mi_texto.text = "<p>The properties of the <b>TextArea</b> class allow you to set the text content, formatting, and horizontal and vertical position at runtime.You can also indicate whether the field is editable, and whether it is a '<i>password</i>' field. You can also restrict the characters that a user can enter.</p><br><p>Setting a property of the TextArea class with ActionScript overrides the parameter of the same name set in the <b>Property inspector</b> or <b>Component Inspector panel</b>.</p><br><p>The <b>TextArea</b> component overrides the default Flash Player focus rectangle and draws a custom focus rectangle with rounded corners.</p><p>The <b>TextArea</b> component supports <i>CSS styles</i> and any additional HTML styles supported by Flash Player.</p><br><p>Each component class has a version property which is a class property. Class properties are only available on the class itself. The version property returns a string that indicates the version of the component. To access the version property, use the following code:</p><br><pre>trace(mx.controls.TextArea.version)</pre>";


//Listener para cuando se cambia el texto
alCambiar = new Object();
alCambiar.change = function(evento){
trace("Posición vertical actual: " + evento.target.vPosition);
trace("Posición vertical máxima: " + evento.target.maxVPosition);
trace("Posición horizontal actual: " + evento.target.hPosition);
trace("Posición horizontal máxima: " + evento.target.maxHPosition);
trace("Caracteres escritos en el texto: " + mi_texto.length);
}

//Eventos
mi_texto.addEventListener("change", alCambiar);

y listo ;) de la misma forma puede moverlo cuando quiera

Por goto();

5 de clabLevel



Genero:Masculino  

firefox
Citar            
MensajeEscrito el 22 Abr 2006 07:05 pm
muchas gracias!!!!! ^^ ^^ ^^ ^^

Por rik_rik

11 de clabLevel



Genero:Masculino  

msie
Citar            
MensajeEscrito el 22 Abr 2006 11:05 pm
de nada

Por goto();

5 de clabLevel



Genero:Masculino  

firefox
Citar            
MensajeEscrito el 26 Abr 2006 12:22 pm
y que hay que poner para elegir el tamaño de la fuente?? no es esto verdad??

attachMovie("TextArea", "mi_texto", 1);
mi_texto.setSize(300, 200);

Con eso lo que defines es el tamaña del area delText Area verdad? y para el tamaño de la fuente??

Por xematick

50 de clabLevel



Genero:Masculino  

msie
Citar            
MensajeEscrito el 02 Jun 2007 07:52 pm
Pues a mi no me funciona
:( :( :(

Por flashermx

48 de clabLevel



 

Ciudad Guzman Jalisco Mexico

msie

 

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