mirror of
https://github.com/konvajs/konva.git
synced 2025-12-17 18:01:15 +08:00
@@ -16,6 +16,7 @@
|
|||||||
* determine if node has children
|
* determine if node has children
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Container.prototype
|
* @memberof Kinetic.Container.prototype
|
||||||
|
* @returns {Boolean}
|
||||||
*/
|
*/
|
||||||
hasChildren: function() {
|
hasChildren: function() {
|
||||||
return this.getChildren().length > 0;
|
return this.getChildren().length > 0;
|
||||||
@@ -56,6 +57,7 @@
|
|||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Container.prototype
|
* @memberof Kinetic.Container.prototype
|
||||||
* @param {Node} child
|
* @param {Node} child
|
||||||
|
* @returns {Container}
|
||||||
*/
|
*/
|
||||||
add: function(child) {
|
add: function(child) {
|
||||||
var children = this.children;
|
var children = this.children;
|
||||||
@@ -86,6 +88,7 @@
|
|||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Container.prototype
|
* @memberof Kinetic.Container.prototype
|
||||||
* @param {String} selector
|
* @param {String} selector
|
||||||
|
* @returns {Collection}
|
||||||
* @example
|
* @example
|
||||||
* // select node with id foo<br>
|
* // select node with id foo<br>
|
||||||
* var node = stage.find('#foo');<br><br>
|
* var node = stage.find('#foo');<br><br>
|
||||||
|
|||||||
@@ -130,7 +130,7 @@
|
|||||||
/**
|
/**
|
||||||
* get layer canvas
|
* get layer canvas
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Node.prototype
|
* @memberof Kinetic.Layer.prototype
|
||||||
*/
|
*/
|
||||||
getCanvas: function() {
|
getCanvas: function() {
|
||||||
return this.canvas;
|
return this.canvas;
|
||||||
@@ -138,7 +138,7 @@
|
|||||||
/**
|
/**
|
||||||
* get layer hit canvas
|
* get layer hit canvas
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Node.prototype
|
* @memberof Kinetic.Layer.prototype
|
||||||
*/
|
*/
|
||||||
getHitCanvas: function() {
|
getHitCanvas: function() {
|
||||||
return this.hitCanvas;
|
return this.hitCanvas;
|
||||||
@@ -146,7 +146,7 @@
|
|||||||
/**
|
/**
|
||||||
* get layer canvas context
|
* get layer canvas context
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Node.prototype
|
* @memberof Kinetic.Layer.prototype
|
||||||
*/
|
*/
|
||||||
getContext: function() {
|
getContext: function() {
|
||||||
return this.getCanvas().getContext();
|
return this.getCanvas().getContext();
|
||||||
|
|||||||
@@ -1032,8 +1032,8 @@
|
|||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Node.prototype
|
* @memberof Kinetic.Node.prototype
|
||||||
* @param {String} eventType event type. can be a regular event, like click, mouseover, or mouseout, or it can be a custom event, like myCustomEvent
|
* @param {String} eventType event type. can be a regular event, like click, mouseover, or mouseout, or it can be a custom event, like myCustomEvent
|
||||||
* @param {EventObject} evt event object
|
* @param {EventObject} [evt] event object
|
||||||
* @param {Boolean} bubble setting the value to false, or leaving it undefined, will result in the event
|
* @param {Boolean} [bubble] setting the value to false, or leaving it undefined, will result in the event
|
||||||
* not bubbling. Setting the value to true will result in the event bubbling.
|
* not bubbling. Setting the value to true will result in the event bubbling.
|
||||||
* @returns {Kinetic.Node}
|
* @returns {Kinetic.Node}
|
||||||
* @example
|
* @example
|
||||||
@@ -1183,7 +1183,6 @@
|
|||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Node.prototype
|
* @memberof Kinetic.Node.prototype
|
||||||
* @param {Object} config
|
* @param {Object} config
|
||||||
* @param {Function} config.callback function executed when the composite has completed
|
|
||||||
* @param {String} [config.mimeType] can be "image/png" or "image/jpeg".
|
* @param {String} [config.mimeType] can be "image/png" or "image/jpeg".
|
||||||
* "image/png" is the default
|
* "image/png" is the default
|
||||||
* @param {Number} [config.x] x position of canvas section
|
* @param {Number} [config.x] x position of canvas section
|
||||||
@@ -1238,7 +1237,6 @@
|
|||||||
* @param {Number} [config.quality] jpeg quality. If using an "image/jpeg" mimeType,
|
* @param {Number} [config.quality] jpeg quality. If using an "image/jpeg" mimeType,
|
||||||
* you can specify the quality from 0 to 1, where 0 is very poor quality and 1
|
* you can specify the quality from 0 to 1, where 0 is very poor quality and 1
|
||||||
* is very high quality
|
* is very high quality
|
||||||
* @returns {Image}
|
|
||||||
* @example
|
* @example
|
||||||
* var image = node.toImage({<br>
|
* var image = node.toImage({<br>
|
||||||
* callback: function(img) {<br>
|
* callback: function(img) {<br>
|
||||||
|
|||||||
@@ -157,6 +157,7 @@
|
|||||||
* get pointer position which can be a touch position or mouse position
|
* get pointer position which can be a touch position or mouse position
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Stage.prototype
|
* @memberof Kinetic.Stage.prototype
|
||||||
|
* @returns {Object}
|
||||||
*/
|
*/
|
||||||
getPointerPosition: function() {
|
getPointerPosition: function() {
|
||||||
return this.pointerPos;
|
return this.pointerPos;
|
||||||
|
|||||||
@@ -174,6 +174,7 @@
|
|||||||
* play
|
* play
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Tween.prototype
|
* @memberof Kinetic.Tween.prototype
|
||||||
|
* @returns {Tween}
|
||||||
*/
|
*/
|
||||||
play: function() {
|
play: function() {
|
||||||
this.tween.play();
|
this.tween.play();
|
||||||
@@ -183,6 +184,7 @@
|
|||||||
* reverse
|
* reverse
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Tween.prototype
|
* @memberof Kinetic.Tween.prototype
|
||||||
|
* @returns {Tween}
|
||||||
*/
|
*/
|
||||||
reverse: function() {
|
reverse: function() {
|
||||||
this.tween.reverse();
|
this.tween.reverse();
|
||||||
@@ -192,6 +194,7 @@
|
|||||||
* reset
|
* reset
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Tween.prototype
|
* @memberof Kinetic.Tween.prototype
|
||||||
|
* @returns {Tween}
|
||||||
*/
|
*/
|
||||||
reset: function() {
|
reset: function() {
|
||||||
var node = this.node;
|
var node = this.node;
|
||||||
@@ -204,6 +207,7 @@
|
|||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Tween.prototype
|
* @memberof Kinetic.Tween.prototype
|
||||||
* @param {Integer} t time in seconds between 0 and the duration
|
* @param {Integer} t time in seconds between 0 and the duration
|
||||||
|
* @returns {Tween}
|
||||||
*/
|
*/
|
||||||
seek: function(t) {
|
seek: function(t) {
|
||||||
var node = this.node;
|
var node = this.node;
|
||||||
@@ -215,6 +219,7 @@
|
|||||||
* pause
|
* pause
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Tween.prototype
|
* @memberof Kinetic.Tween.prototype
|
||||||
|
* @returns {Tween}
|
||||||
*/
|
*/
|
||||||
pause: function() {
|
pause: function() {
|
||||||
this.tween.pause();
|
this.tween.pause();
|
||||||
@@ -224,6 +229,7 @@
|
|||||||
* finish
|
* finish
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Tween.prototype
|
* @memberof Kinetic.Tween.prototype
|
||||||
|
* @returns {Tween}
|
||||||
*/
|
*/
|
||||||
finish: function() {
|
finish: function() {
|
||||||
var node = this.node;
|
var node = this.node;
|
||||||
|
|||||||
@@ -68,7 +68,7 @@
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* get/set radius
|
* get/set radius
|
||||||
* @name setRadius
|
* @name radius
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Ellipse.prototype
|
* @memberof Kinetic.Ellipse.prototype
|
||||||
* @param {Object} radius
|
* @param {Object} radius
|
||||||
@@ -89,7 +89,7 @@
|
|||||||
Kinetic.Factory.addGetterSetter(Kinetic.Ellipse, 'radiusX', 0);
|
Kinetic.Factory.addGetterSetter(Kinetic.Ellipse, 'radiusX', 0);
|
||||||
/**
|
/**
|
||||||
* get/set radius x
|
* get/set radius x
|
||||||
* @name setRadiusX
|
* @name radiusX
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Ellipse.prototype
|
* @memberof Kinetic.Ellipse.prototype
|
||||||
* @param {Number} x
|
* @param {Number} x
|
||||||
@@ -105,7 +105,7 @@
|
|||||||
Kinetic.Factory.addGetterSetter(Kinetic.Ellipse, 'radiusY', 0);
|
Kinetic.Factory.addGetterSetter(Kinetic.Ellipse, 'radiusY', 0);
|
||||||
/**
|
/**
|
||||||
* get/set radius y
|
* get/set radius y
|
||||||
* @name setRadiusY
|
* @name radiusY
|
||||||
* @method
|
* @method
|
||||||
* @memberof Kinetic.Ellipse.prototype
|
* @memberof Kinetic.Ellipse.prototype
|
||||||
* @param {Number} y
|
* @param {Number} y
|
||||||
|
|||||||
@@ -7,7 +7,6 @@
|
|||||||
* @constructor
|
* @constructor
|
||||||
* @augments Kinetic.Shape
|
* @augments Kinetic.Shape
|
||||||
* @param {Object} config
|
* @param {Object} config
|
||||||
* @param {Number} config.angle in degrees
|
|
||||||
* @param {Number} config.innerRadius
|
* @param {Number} config.innerRadius
|
||||||
* @param {Number} config.outerRadius
|
* @param {Number} config.outerRadius
|
||||||
* @param {Boolean} [config.clockwise]
|
* @param {Boolean} [config.clockwise]
|
||||||
|
|||||||
Reference in New Issue
Block a user