Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
seleniumhq
GitHub Repository: seleniumhq/selenium
Path: blob/trunk/third_party/closure/goog/graphics/rectelement.js
2868 views
1
// Copyright 2007 The Closure Library Authors. All Rights Reserved.
2
//
3
// Licensed under the Apache License, Version 2.0 (the "License");
4
// you may not use this file except in compliance with the License.
5
// You may obtain a copy of the License at
6
//
7
// http://www.apache.org/licenses/LICENSE-2.0
8
//
9
// Unless required by applicable law or agreed to in writing, software
10
// distributed under the License is distributed on an "AS-IS" BASIS,
11
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
// See the License for the specific language governing permissions and
13
// limitations under the License.
14
15
16
/**
17
* @fileoverview A thin wrapper around the DOM element for rectangles.
18
* @author [email protected] (Erik Arvidsson)
19
*/
20
21
22
goog.provide('goog.graphics.RectElement');
23
24
goog.require('goog.graphics.StrokeAndFillElement');
25
26
27
28
/**
29
* Interface for a graphics rectangle element.
30
* You should not construct objects from this constructor. The graphics
31
* will return an implementation of this interface for you.
32
* @param {Element} element The DOM element to wrap.
33
* @param {goog.graphics.AbstractGraphics} graphics The graphics creating
34
* this element.
35
* @param {goog.graphics.Stroke?} stroke The stroke to use for this element.
36
* @param {goog.graphics.Fill?} fill The fill to use for this element.
37
* @constructor
38
* @extends {goog.graphics.StrokeAndFillElement}
39
* @deprecated goog.graphics is deprecated. It existed to abstract over browser
40
* differences before the canvas tag was widely supported. See
41
* http://en.wikipedia.org/wiki/Canvas_element for details.
42
*/
43
goog.graphics.RectElement = function(element, graphics, stroke, fill) {
44
goog.graphics.StrokeAndFillElement.call(
45
this, element, graphics, stroke, fill);
46
};
47
goog.inherits(goog.graphics.RectElement, goog.graphics.StrokeAndFillElement);
48
49
50
/**
51
* Update the position of the rectangle.
52
* @param {number} x X coordinate (left).
53
* @param {number} y Y coordinate (top).
54
*/
55
goog.graphics.RectElement.prototype.setPosition = goog.abstractMethod;
56
57
58
/**
59
* Update the size of the rectangle.
60
* @param {number} width Width of rectangle.
61
* @param {number} height Height of rectangle.
62
*/
63
goog.graphics.RectElement.prototype.setSize = goog.abstractMethod;
64
65