72 lines
924 B
Go
72 lines
924 B
Go
package svg
|
|
|
|
type (
|
|
// Rect models a <rect> element
|
|
Rect = VoidElement[RectTag, RectAttribute]
|
|
RectTag struct{}
|
|
|
|
// SVGAttributes are Attributes allowed on SVGs
|
|
RectAttribute interface {
|
|
Attribute
|
|
IsRectAttribute()
|
|
}
|
|
)
|
|
|
|
func (RectTag) PrintTag() string {
|
|
return "rect"
|
|
}
|
|
|
|
func (X) IsRectAttribute() {
|
|
}
|
|
|
|
func (XP) IsRectAttribute() {
|
|
}
|
|
|
|
func (Y) IsRectAttribute() {
|
|
}
|
|
|
|
func (YP) IsRectAttribute() {
|
|
}
|
|
|
|
func (Width) IsRectAttribute() {
|
|
}
|
|
|
|
func (WidthP) IsRectAttribute() {
|
|
}
|
|
|
|
func (Height) IsRectAttribute() {
|
|
}
|
|
|
|
func (HeightP) IsRectAttribute() {
|
|
}
|
|
|
|
func (RX) IsRectAttribute() {
|
|
}
|
|
|
|
func (RXP) IsRectAttribute() {
|
|
}
|
|
|
|
func (RY) IsRectAttribute() {
|
|
}
|
|
|
|
func (RYP) IsRectAttribute() {
|
|
}
|
|
|
|
func (PathLength) IsRectAttribute() {
|
|
}
|
|
|
|
func (Class) IsRectAttribute() {
|
|
}
|
|
|
|
func (Fill) IsRectAttribute() {
|
|
}
|
|
|
|
func (Stroke) IsRectAttribute() {
|
|
}
|
|
|
|
func (StrokeWidth) IsRectAttribute() {
|
|
}
|
|
|
|
func (Style) IsRectAttribute() {
|
|
}
|