123456789101112131415161718192021222324252627282930313233343536 |
- import VectorType from '../enum/VectorType.js'
- import Geometry from './Geometry.js'
- export default class Cell extends Geometry {
- constructor(parent,vectorId) {
- super()
- this.width = 60; //每个格子默认宽度是60像素
- this.height = 24; //每个格子默认高度是24像素
- this.value = "";
- this.colIndex = 0;
- this.rowIndex = 0;
- this.parent = parent;
- this.geoType = VectorType.Cell
- this.setId(vectorId)
- }
- setWidth(width){
- this.width = width;
- }
- setHeight(height){
- this.height = height;
- }
- setValue(value){
- this.value = value;
- }
- setColIndex(colIndex){
- this.colIndex = colIndex;
- }
- setRowIndex(rowIndex){
- this.rowIndex = rowIndex;
- }
- }
|