| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
|
| 36 |
|
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
|
| 41 |
|
| 42 |
|
| 43 |
|
| 44 |
|
| 45 |
|
| 46 |
package h; |
| 47 |
|
| 48 |
import smetana.core.CString; |
| 49 |
import smetana.core.UnsupportedStructAndPtr; |
| 50 |
import smetana.core.__ptr__; |
| 51 |
import smetana.core.__struct__; |
| 52 |
import smetana.core.amiga.StarStruct; |
| 53 |
|
| 54 |
public class ST_textlabel_t extends UnsupportedStructAndPtr { |
| 55 |
|
| 56 |
private final StarStruct parent; |
| 57 |
|
| 58 |
public ST_textlabel_t() { |
| 59 |
this(null); |
| 60 |
} |
| 61 |
|
| 62 |
public ST_textlabel_t(StarStruct parent) { |
| 63 |
this.parent = parent; |
| 64 |
} |
| 65 |
|
| 66 |
public CString text, fontname, fontcolor; |
| 67 |
public int charset; |
| 68 |
public double fontsize; |
| 69 |
|
| 70 |
public final ST_pointf dimen = new ST_pointf(this); |
| 71 |
public final ST_pointf space = new ST_pointf(this); |
| 72 |
public final ST_pointf pos = new ST_pointf(this); |
| 73 |
|
| 74 |
|
| 75 |
|
| 76 |
|
| 77 |
|
| 78 |
|
| 79 |
public ST_textspan_t.Array span; |
| 80 |
public int nspans; |
| 81 |
|
| 82 |
|
| 83 |
|
| 84 |
|
| 85 |
public final __ptr__ html__ = null; |
| 86 |
|
| 87 |
|
| 88 |
public int valign; |
| 89 |
|
| 90 |
public int set; |
| 91 |
|
| 92 |
public boolean html; |
| 93 |
|
| 94 |
|
| 95 |
|
| 96 |
|
| 97 |
@Override |
| 98 |
public void setStruct(String fieldName, __struct__ newData) { |
| 99 |
if (fieldName.equals("space")) { |
| 100 |
space.copyDataFrom(newData); |
| 101 |
return; |
| 102 |
} |
| 103 |
if (fieldName.equals("pos")) { |
| 104 |
pos.copyDataFrom(newData); |
| 105 |
return; |
| 106 |
} |
| 107 |
super.setStruct(fieldName, newData); |
| 108 |
} |
| 109 |
|
| 110 |
@Override |
| 111 |
public __ptr__ setPtr(String fieldName, __ptr__ newData) { |
| 112 |
if (fieldName.equals("text")) { |
| 113 |
this.text = (CString) newData; |
| 114 |
return text; |
| 115 |
} |
| 116 |
if (fieldName.equals("fontname")) { |
| 117 |
this.fontname = (CString) newData; |
| 118 |
return fontname; |
| 119 |
} |
| 120 |
if (fieldName.equals("fontcolor")) { |
| 121 |
this.fontcolor = (CString) newData; |
| 122 |
return fontcolor; |
| 123 |
} |
| 124 |
if (fieldName.equals("u.txt.span")) { |
| 125 |
this.span = (ST_textspan_t.Array) newData; |
| 126 |
return span; |
| 127 |
} |
| 128 |
return super.setPtr(fieldName, newData); |
| 129 |
} |
| 130 |
|
| 131 |
@Override |
| 132 |
public void setDouble(String fieldName, double data) { |
| 133 |
if (fieldName.equals("fontsize")) { |
| 134 |
this.fontsize = data; |
| 135 |
return; |
| 136 |
} |
| 137 |
super.setDouble(fieldName, data); |
| 138 |
} |
| 139 |
|
| 140 |
@Override |
| 141 |
public void setInt(String fieldName, int data) { |
| 142 |
if (fieldName.equals("charset")) { |
| 143 |
this.charset = data; |
| 144 |
return; |
| 145 |
} |
| 146 |
if (fieldName.equals("valign")) { |
| 147 |
this.valign = data; |
| 148 |
return; |
| 149 |
} |
| 150 |
if (fieldName.equals("u.txt.nspans")) { |
| 151 |
this.nspans = data; |
| 152 |
return; |
| 153 |
} |
| 154 |
if (fieldName.equals("set")) { |
| 155 |
this.set = data; |
| 156 |
return; |
| 157 |
} |
| 158 |
super.setInt(fieldName, data); |
| 159 |
} |
| 160 |
|
| 161 |
@Override |
| 162 |
public boolean isSameThan(StarStruct other) { |
| 163 |
ST_textlabel_t other2 = (ST_textlabel_t) other; |
| 164 |
return this == other2; |
| 165 |
} |
| 166 |
|
| 167 |
|
| 168 |
} |
| 169 |
|
| 170 |
|
| 171 |
|
| 172 |
|
| 173 |
|
| 174 |
|
| 175 |
|
| 176 |
|
| 177 |
|
| 178 |
|
| 179 |
|
| 180 |
|
| 181 |
|
| 182 |
|
| 183 |
|
| 184 |
|
| 185 |
|
| 186 |
|
| 187 |
|
| 188 |
|
| 189 |
|