Adobe Extending Flash Professional CS4 Manuel d'utilisateur Page 164

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 560
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 163
142
EXTENDING FLASH CS4 PROFESSIONAL
Document object
Description
Method; sets the fill settings for the Tools panel, Property inspector, and any selected shapes. This allows a script to set
the fill settings before drawing the object, rather than drawing the object, selecting it, and changing the fill settings. It
also lets a script change the Tools panel and Property inspector fill settings.
Example
The following example changes the color of the fill color swatch in the Tools panel, Property inspector, and any
selected shapes to white:
var fill = fl.getDocumentDOM().getCustomFill();
fill.color = '#FFFFFF';
fill.style = "solid";
fl.getDocumentDOM().setCustomFill(fill);
See also
document.getCustomFill()
document.setCustomStroke()
Availability
Flash MX 2004.
Usage
document.setCustomStroke(stroke)
Parameters
stroke A Stroke object.
Returns
Nothing.
Description
Method; sets the stroke settings for the Tools panel, Property inspector, and any selected shapes. This allows a script
to set the stroke settings before drawing the object, rather than drawing the object, selecting it, and changing the stroke
settings. It also lets a script change the Tools panel and Property inspector stroke settings.
Example
The following example changes the stroke thickness setting in the Tools panel, Property inspector, and any selected
shapes:
var stroke = fl.getDocumentDOM().getCustomStroke();
stroke.thickness += 2;
fl.getDocumentDOM().setCustomStroke(stroke);
See also
document.getCustomStroke()
Vue de la page 163
1 2 ... 159 160 161 162 163 164 165 166 167 168 169 ... 559 560

Commentaires sur ces manuels

Pas de commentaire