Title: Window1 Record Description: Stores the attributes of the workbook window. This is basically so the gui knows how big to make the window holding the spreadsheet document. REFERENCE: PG 421 Microsoft Excel 97 Developer's Kit (ISBN: 1-57231-498-2) @
| 31 | * @version 2.0-pre |
| 32 | */ |
| 33 | public final class WindowOneRecord extends StandardRecord { |
| 34 | public final static short sid = 0x3d; |
| 35 | |
| 36 | // our variable names stolen from old TV sets. |
| 37 | private short field_1_h_hold; // horizontal position |
| 38 | private short field_2_v_hold; // vertical position |
| 39 | private short field_3_width; |
| 40 | private short field_4_height; |
| 41 | private short field_5_options; |
| 42 | static final private BitField hidden = |
| 43 | BitFieldFactory.getInstance(0x01); // is this window is hidden |
| 44 | static final private BitField iconic = |
| 45 | BitFieldFactory.getInstance(0x02); // is this window is an icon |
| 46 | static final private BitField reserved = BitFieldFactory.getInstance(0x04); // reserved |
| 47 | static final private BitField hscroll = |
| 48 | BitFieldFactory.getInstance(0x08); // display horizontal scrollbar |
| 49 | static final private BitField vscroll = |
| 50 | BitFieldFactory.getInstance(0x10); // display vertical scrollbar |
| 51 | static final private BitField tabs = |
| 52 | BitFieldFactory.getInstance(0x20); // display tabs at the bottom |
| 53 | |
| 54 | // all the rest are "reserved" |
| 55 | private int field_6_active_sheet; |
| 56 | private int field_7_first_visible_tab; |
| 57 | private short field_8_num_selected_tabs; |
| 58 | private short field_9_tab_width_ratio; |
| 59 | |
| 60 | public WindowOneRecord() |
| 61 | { |
| 62 | } |
| 63 | |
| 64 | public WindowOneRecord(RecordInputStream in) |
| 65 | { |
| 66 | field_1_h_hold = in.readShort(); |
| 67 | field_2_v_hold = in.readShort(); |
| 68 | field_3_width = in.readShort(); |
| 69 | field_4_height = in.readShort(); |
| 70 | field_5_options = in.readShort(); |
| 71 | field_6_active_sheet = in.readShort(); |
| 72 | field_7_first_visible_tab = in.readShort(); |
| 73 | field_8_num_selected_tabs = in.readShort(); |
| 74 | field_9_tab_width_ratio = in.readShort(); |
| 75 | } |
| 76 | |
| 77 | /** |
| 78 | * set the horizontal position of the window (in 1/20ths of a point) |
| 79 | * @param h - horizontal location |
| 80 | */ |
| 81 | |
| 82 | public void setHorizontalHold(short h) |
| 83 | { |
| 84 | field_1_h_hold = h; |
| 85 | } |
| 86 | |
| 87 | /** |
| 88 | * set the vertical position of the window (in 1/20ths of a point) |
| 89 | * @param v - vertical location |
| 90 | */ |
nothing calls this directly
no test coverage detected