2011-05-07 08:39:17 -04:00
|
|
|
/*
|
|
|
|
* Paper.js
|
|
|
|
*
|
|
|
|
* This file is part of Paper.js, a JavaScript Vector Graphics Library,
|
|
|
|
* based on Scriptographer.org and designed to be largely API compatible.
|
|
|
|
* http://paperjs.org/
|
|
|
|
* http://scriptographer.org/
|
|
|
|
*
|
|
|
|
* Distributed under the MIT license. See LICENSE file for details.
|
|
|
|
*
|
|
|
|
* Copyright (c) 2011, Juerg Lehni & Jonathan Puckey
|
|
|
|
* http://lehni.org/ & http://jonathanpuckey.com/
|
|
|
|
*
|
|
|
|
* All rights reserved.
|
|
|
|
*/
|
|
|
|
|
2011-06-19 17:21:14 -04:00
|
|
|
var ChangeFlag = {
|
2011-06-19 17:20:28 -04:00
|
|
|
// Anything affecting the appearance of an item, including GEOMETRY,
|
|
|
|
// STROKE, STYLE and ATTRIBUTE (except for the invisible ones: locked, name)
|
|
|
|
APPEARANCE: 1,
|
|
|
|
// Change in item hierarchy
|
|
|
|
HIERARCHY: 2,
|
|
|
|
// Item geometry (path, bounds)
|
|
|
|
GEOMETRY: 4,
|
|
|
|
// Stroke geometry (excluding color)
|
|
|
|
STROKE: 8,
|
|
|
|
// Fill style or stroke color / dash
|
|
|
|
STYLE: 16,
|
|
|
|
// Item attributes: visible, blendMode, locked, name, opacity, clipMask ...
|
2011-06-19 17:36:04 -04:00
|
|
|
ATTRIBUTE: 32,
|
|
|
|
// Clipping in one of the child items
|
|
|
|
CLIPPING: 64
|
2011-06-19 17:20:28 -04:00
|
|
|
};
|
|
|
|
|
2011-06-19 17:36:04 -04:00
|
|
|
// Shortcuts to often used ChangeFlag values including APPEARANCE
|
2011-06-19 17:20:28 -04:00
|
|
|
var Change = {
|
2011-06-19 17:21:14 -04:00
|
|
|
HIERARCHY: ChangeFlag.HIERARCHY | ChangeFlag.APPEARANCE,
|
|
|
|
GEOMETRY: ChangeFlag.GEOMETRY | ChangeFlag.APPEARANCE,
|
|
|
|
STROKE: ChangeFlag.STROKE | ChangeFlag.APPEARANCE,
|
|
|
|
STYLE: ChangeFlag.STYLE | ChangeFlag.APPEARANCE,
|
|
|
|
ATTRIBUTE: ChangeFlag.ATTRIBUTE | ChangeFlag.APPEARANCE
|
2011-05-07 11:52:54 -04:00
|
|
|
};
|