0 Replies Latest reply on Apr 9, 2008 10:05 AM by fryckoort

    mask question

    fryckoort Level 1
      Hi i want to apply a textField mask on several Sprite, the mask is apply only on the last (square2),

      tf.styleName="lyricdef";
      tf.autoSize = TextFieldAutoSize.CENTER;
      tf.text = "Toto";
      tf.cacheAsBitmap = true;
      addChild(tf);

      square.graphics.beginFill(0xFFFFFF);
      square.graphics.drawRect(120,70,tf.width,tf.height);
      square.graphics.endFill();
      lyricsBox.addChild(square);
      square.mask = tf;

      square2.graphics.beginFill(0x2D3AE3);
      square2.graphics.drawRect(120-tf.width,70,tf.width,tf.height);
      square2.graphics.endFill();
      addChild(square2);
      square2.mask = tf;

      can you help me ?