Zurück   Flashforum > Flash > ActionScript > ActionScript 1

Antwort
 
LinkBack Themen-Optionen Ansicht
Alt 13-08-2003, 15:47   #1 (permalink)
trace = Brain Death
 
Registriert seit: Mar 2002
Ort: Essen
Beiträge: 267
dyn. textfeld -> global formatierung

huhu.

Irgendwie übernimmt mein "liebes" textfeld die schriftart und größe nicht.

WHY?!!?

ActionScript:
  1. // Globale Style Vars
  2.  
  3.  
  4. _global.textStyle = new TextFormat()
  5. _global.textStyle.font = "Arial";
  6. _global.textStyle.size = 20;
  7. _global.textStyle.color = 0xffffff;
  8. _global.textStyle.align = "left";
  9. _global.textStyle.bold = "false";
  10. _global.textStyle.italic = "false";
  11. _global.textStyle.underline = false;
  12. _global.textStyle.url = null;
  13. _global.textStyle.target = null;
  14. _global.textStyle.indent = null;
  15. _global.textStyle.leading = null;
  16. _global.textStyle.textColor = 0x000000;
  17. _global.textStyle.text = text;
  18.  
  19. //--------snip-----------
  20.  
  21.  
  22. // Textfeld 'name' erzeugen und styles anpassen
  23.  
  24. _root.createTextField("name",1,190,145,200,100);
  25.    
  26.  
  27.     name.type = "input"; // input = eingabetext
  28.     name.autoSize = "left";
  29.     name.setTextFormat(textstyle)
  30.     name.leftMargin = 100;
  31.     name.rightMargin = 100;
  32.     name.border = true;
  33.     name.borderColor = 0x003366;
  34.     name.background = true;
  35.     name.backgroundColor = 0xffffff;

p.s. bin noch nich so bewandert in as ;/

Geändert von nastyBasty (13-08-2003 um 15:48 Uhr)
nastyBasty ist offline   Mit Zitat antworten
Alt 13-08-2003, 16:06   #2 (permalink)
trace = Brain Death
 
Registriert seit: Mar 2002
Ort: Essen
Beiträge: 267
Zusatz:

Kann ich in meinem Eingebefeld text vordefinieren, sodaß text schon drinsteht und beim klick auf das Eingabefeld verschwindet.
nastyBasty ist offline   Mit Zitat antworten
Alt 13-08-2003, 20:04   #3 (permalink)
{flasher}
 
Benutzerbild von Majo
 
Registriert seit: Mar 2003
Ort: on water
Beiträge: 2.823
ActionScript:
  1. _global.textStyle = new TextFormat()
  2. _global.textStyle.font = "Verdana";
  3. _global.textStyle.size = 20;
  4. _global.textStyle.color = 0xff0000;
  5. _global.textStyle.align = "left";
  6. _global.textStyle.bold = false;
  7. _global.textStyle.italic = false;
  8. _global.textStyle.underline = false;
  9. _global.textStyle.url = null;
  10. _global.textStyle.target = null;
  11. _global.textStyle.indent = null;
  12. _global.textStyle.leading = null;
  13.  
  14. //--------snip-----------
  15. // Textfeld 'name' erzeugen und styles anpassen
  16. _root.createTextField("name",1,190,145,200,100);
  17. name.setNewTextFormat(_global.textStyle);
  18. //
  19. name.type = "input"; // input = eingabetext
  20. name.autoSize = "left";
  21. name.leftMargin = 100;
  22. name.rightMargin = 100;
  23. name.border = true;
  24. name.borderColor = 0x003366;
  25. name.background = true;
  26. name.backgroundColor = 0xff00ff;
  27. name.text = "hallo nastyBasty";
  28.  
  29. //
  30. function feldLeeren(ziel){
  31.     ziel.onSetFocus = function(){
  32.         ziel.text = "";
  33.     }
  34. };
  35. feldLeeren(name);

so gehts
__________________
hang loose
Majo ist offline   Mit Zitat antworten
Alt 14-08-2003, 08:12   #4 (permalink)
trace = Brain Death
 
Registriert seit: Mar 2002
Ort: Essen
Beiträge: 267
ach mist :/ hätt ich ja selbst drauf kommen müssen


ActionScript:
  1. name.setNewTextFormat(_global.textStyle);

Naja . Vielen Dank
nastyBasty ist offline   Mit Zitat antworten
Antwort

Lesezeichen

Themen-Optionen
Ansicht

Forumregeln
Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks sind an
Pingbacks sind an
Refbacks sind an



Alle Zeitangaben in WEZ +1. Es ist jetzt 07:53 Uhr.

Domains, Webhosting & Vserver von Host Europe
Unterstützt das Flashforum!
Adobe User Group


Copyright ©1999 – 2012 Marc Thiele