mirror of
https://git.femboyfinancial.jp/james/lipsync.git
synced 2024-11-22 02:32:04 -08:00
139 lines
2.7 KiB
C#
139 lines
2.7 KiB
C#
|
/*
|
|||
|
* XmlRectangle.cs
|
|||
|
* Copyright (c) 2009 kbinani
|
|||
|
*
|
|||
|
* This file is part of bocoree.
|
|||
|
*
|
|||
|
* bocoree is free software; you can redistribute it and/or
|
|||
|
* modify it under the terms of the BSD License.
|
|||
|
*
|
|||
|
* bocoree is distributed in the hope that it will be useful,
|
|||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|||
|
*/
|
|||
|
#if JAVA
|
|||
|
package org.kbinani;
|
|||
|
|
|||
|
import java.awt.*;
|
|||
|
#else
|
|||
|
using System.Xml.Serialization;
|
|||
|
using bocoree.java.awt;
|
|||
|
|
|||
|
namespace bocoree{
|
|||
|
#endif
|
|||
|
|
|||
|
public class XmlRectangle{
|
|||
|
#if !JAVA
|
|||
|
[XmlIgnore]
|
|||
|
#endif
|
|||
|
public int x;
|
|||
|
#if !JAVA
|
|||
|
[XmlIgnore]
|
|||
|
#endif
|
|||
|
public int y;
|
|||
|
#if !JAVA
|
|||
|
[XmlIgnore]
|
|||
|
#endif
|
|||
|
public int width;
|
|||
|
#if !JAVA
|
|||
|
[XmlIgnore]
|
|||
|
#endif
|
|||
|
public int height;
|
|||
|
|
|||
|
public XmlRectangle()
|
|||
|
{
|
|||
|
}
|
|||
|
|
|||
|
public XmlRectangle( int x_, int y_, int width_, int height_ ){
|
|||
|
x = x_;
|
|||
|
y = y_;
|
|||
|
width = width_;
|
|||
|
height = height_;
|
|||
|
}
|
|||
|
|
|||
|
public XmlRectangle( Rectangle rc ) {
|
|||
|
x = rc.x;
|
|||
|
y = rc.y;
|
|||
|
width = rc.width;
|
|||
|
height = rc.height;
|
|||
|
}
|
|||
|
|
|||
|
public Rectangle toRectangle() {
|
|||
|
return new Rectangle( x, y, width, height );
|
|||
|
}
|
|||
|
|
|||
|
public int getX() {
|
|||
|
return x;
|
|||
|
}
|
|||
|
|
|||
|
public void setX( int value ) {
|
|||
|
x = value;
|
|||
|
}
|
|||
|
|
|||
|
public int getY() {
|
|||
|
return y;
|
|||
|
}
|
|||
|
|
|||
|
public void setY( int value ) {
|
|||
|
y = value;
|
|||
|
}
|
|||
|
|
|||
|
public int getWidth() {
|
|||
|
return width;
|
|||
|
}
|
|||
|
|
|||
|
public void setWidth( int value ) {
|
|||
|
width = value;
|
|||
|
}
|
|||
|
|
|||
|
public int getHeight() {
|
|||
|
return height;
|
|||
|
}
|
|||
|
|
|||
|
public void setHeight( int value ) {
|
|||
|
height = value;
|
|||
|
}
|
|||
|
#if !JAVA
|
|||
|
public int X{
|
|||
|
get{
|
|||
|
return getX();
|
|||
|
}
|
|||
|
set{
|
|||
|
setX( value );
|
|||
|
}
|
|||
|
}
|
|||
|
|
|||
|
public int Y{
|
|||
|
get{
|
|||
|
return getY();
|
|||
|
}
|
|||
|
set{
|
|||
|
setY( value );
|
|||
|
}
|
|||
|
}
|
|||
|
|
|||
|
public int Width{
|
|||
|
get{
|
|||
|
return getWidth();
|
|||
|
}
|
|||
|
set{
|
|||
|
setWidth( value );
|
|||
|
}
|
|||
|
}
|
|||
|
|
|||
|
public int Height{
|
|||
|
get{
|
|||
|
return getHeight();
|
|||
|
}
|
|||
|
set{
|
|||
|
setHeight( value );
|
|||
|
}
|
|||
|
}
|
|||
|
#endif
|
|||
|
|
|||
|
}
|
|||
|
|
|||
|
#if !JAVA
|
|||
|
}
|
|||
|
#endif
|