01: /* ====================================================================
02: Licensed to the Apache Software Foundation (ASF) under one or more
03: contributor license agreements. See the NOTICE file distributed with
04: this work for additional information regarding copyright ownership.
05: The ASF licenses this file to You under the Apache License, Version 2.0
06: (the "License"); you may not use this file except in compliance with
07: the License. You may obtain a copy of the License at
08:
09: http://www.apache.org/licenses/LICENSE-2.0
10:
11: Unless required by applicable law or agreed to in writing, software
12: distributed under the License is distributed on an "AS IS" BASIS,
13: WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: See the License for the specific language governing permissions and
15: limitations under the License.
16: ==================================================================== */
17:
18: package org.apache.poi.hdf.model.hdftypes;
19:
20: import org.apache.poi.hdf.model.hdftypes.definitions.CHPAbstractType;
21:
22: /**
23: * Properties for character runs.
24: *
25: * @author Ryan Ackley
26: */
27:
28: public class CharacterProperties extends CHPAbstractType implements
29: Cloneable {
30:
31: public CharacterProperties() {
32: setDttmRMark(new short[2]);
33: setDttmRMarkDel(new short[2]);
34: setXstDispFldRMark(new byte[32]);
35: setBrc(new short[2]);
36: ;
37: setHps(20);
38: setFcPic(-1);
39: setIstd(10);
40: setLidFE(0x0400);
41: setLidDefault(0x0400);
42: setWCharScale(100);
43: //setFUsePgsuSettings(-1);
44: }
45:
46: /**
47: * Used to make a deep copy of this object.
48: */
49: public Object clone() throws CloneNotSupportedException {
50: CharacterProperties clone = (CharacterProperties) super .clone();
51: clone.setBrc(new short[2]);
52: System.arraycopy(getBrc(), 0, clone.getBrc(), 0, 2);
53: System.arraycopy(getDttmRMark(), 0, clone.getDttmRMark(), 0, 2);
54: System.arraycopy(getDttmRMarkDel(), 0, clone.getDttmRMarkDel(),
55: 0, 2);
56: System.arraycopy(getXstDispFldRMark(), 0, clone
57: .getXstDispFldRMark(), 0, 32);
58: return clone;
59: }
60: }
|