Back to index

lightning-sunbird  0.9+nobinonly
nsIDOMSVGGradientElement.idl
Go to the documentation of this file.
00001 /* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
00002 /* ***** BEGIN LICENSE BLOCK *****
00003  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
00004  *
00005  * The contents of this file are subject to the Mozilla Public License Version
00006  * 1.1 (the "License"); you may not use this file except in compliance with
00007  * the License. You may obtain a copy of the License at
00008  * http://www.mozilla.org/MPL/
00009  *
00010  * Software distributed under the License is distributed on an "AS IS" basis,
00011  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
00012  * for the specific language governing rights and limitations under the
00013  * License.
00014  *
00015  * The Original Code is the Mozilla SVG project.
00016  *
00017  * The Initial Developer of the Original Code is
00018  * Scooter Morris.
00019  * Portions created by the Initial Developer are Copyright (C) 2004
00020  * the Initial Developer. All Rights Reserved.
00021  *
00022  * Contributor(s):
00023  *   Scooter Morris <scootermorris@comcast.net>
00024  *
00025  * Alternatively, the contents of this file may be used under the terms of
00026  * either the GNU General Public License Version 2 or later (the "GPL"), or
00027  * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
00028  * in which case the provisions of the GPL or the LGPL are applicable instead
00029  * of those above. If you wish to allow use of your version of this file only
00030  * under the terms of either the GPL or the LGPL, and not to allow others to
00031  * use your version of this file under the terms of the MPL, indicate your
00032  * decision by deleting the provisions above and replace them with the notice
00033  * and other provisions required by the GPL or the LGPL. If you do not delete
00034  * the provisions above, a recipient may use your version of this file under
00035  * the terms of any one of the MPL, the GPL or the LGPL.
00036  *
00037  * ***** END LICENSE BLOCK ***** */
00038 
00039 #include "nsIDOMSVGElement.idl"
00040 
00050 interface nsIDOMSVGAnimatedEnumeration;
00051 interface nsIDOMSVGAnimatedTransformList;
00052 
00053 [scriptable, uuid(988b2de4-137b-4bb8-a15e-fe94038e9cf3)]
00054 interface nsIDOMSVGGradientElement
00055   : nsIDOMSVGElement
00056 /*
00057         The SVG DOM makes use of multiple interface inheritance.
00058         Since XPCOM only supports single interface inheritance,
00059         the best thing that we can do is to promise that whenever
00060         an object implements _this_ interface it will also
00061         implement the following interfaces. (We then have to QI to
00062         hop between them.)
00063         
00064     nsIDOMSVGURIReference,
00065     nsIDOMSVGStylable
00066 */
00067 { 
00068   const unsigned short SVG_SPREADMETHOD_UNKNOWN = 0;
00069   const unsigned short SVG_SPREADMETHOD_PAD     = 1;
00070   const unsigned short SVG_SPREADMETHOD_REFLECT = 2;
00071   const unsigned short SVG_SPREADMETHOD_REPEAT  = 3;
00072   // Extended to provide enumerations for gradientUnits
00073   // These constants are taken from SVGUnitTypes
00074   const unsigned short SVG_GRUNITS_UNKNOWN = 0;
00075   const unsigned short SVG_GRUNITS_OBJECTBOUNDINGBOX = 1;
00076   const unsigned short SVG_GRUNITS_USERSPACEONUSE = 2;
00077 
00078 
00079   readonly attribute nsIDOMSVGAnimatedEnumeration gradientUnits;
00080   readonly attribute nsIDOMSVGAnimatedTransformList gradientTransform;
00081   readonly attribute nsIDOMSVGAnimatedEnumeration spreadMethod;
00082 };
00083 
00084 
00094 // Linear gradient
00095 interface nsIDOMSVGAnimatedLength;
00096 
00097 [scriptable, uuid(7e15fce5-b208-43e1-952a-c570ebad0619)]
00098 interface nsIDOMSVGLinearGradientElement
00099   : nsIDOMSVGGradientElement
00100 { 
00101   readonly attribute nsIDOMSVGAnimatedLength x1;
00102   readonly attribute nsIDOMSVGAnimatedLength y1;
00103   readonly attribute nsIDOMSVGAnimatedLength x2;
00104   readonly attribute nsIDOMSVGAnimatedLength y2;
00105 };
00106 
00116 // Radial gradient
00117 interface nsIDOMSVGAnimatedLength;
00118 
00119 [scriptable, uuid(d0262ae1-31a4-44be-b82e-85e4cfe280fd)]
00120 interface nsIDOMSVGRadialGradientElement
00121   : nsIDOMSVGGradientElement
00122 { 
00123   readonly attribute nsIDOMSVGAnimatedLength cx;
00124   readonly attribute nsIDOMSVGAnimatedLength cy;
00125   readonly attribute nsIDOMSVGAnimatedLength r;
00126   readonly attribute nsIDOMSVGAnimatedLength fx;
00127   readonly attribute nsIDOMSVGAnimatedLength fy;
00128 };
00129 
00130