Finalize version.
[marekmrva_bc.git] / TypesClass.pas
blob047b61c0c545418fc12f706024fa95474909f96e
1 unit TypesClass;
3 interface
5 uses
6 Graphics;
8 type
10 PLine = ^TLine;
11 TLine = record
12 Line: String;
13 Number: Integer;
14 end;
15 TLines = array of TLine;
17 TFloatRecord = record
18 Significand: Int64;
19 Exponent: Word;
20 Sign: Boolean;
21 end;
23 TSeparateConstants = record
24 ExponCmp: Word;
25 SigniCmp, SigniAnd: Int64;
26 end;
28 TTranslateConstants = record
29 PosInf, NegInf, QNaN, SNaN: String;
30 end;
32 PSingle = ^Single;
33 PDouble = ^Double;
34 PExtended = ^Extended;
36 PBCDRecord = ^TBCDRecord;
37 TBCDRecord = packed record
38 Bytes: array [0..9] of Byte;
39 end;
41 TFlags = (Carry, Reserved1, Parity, Reserved3, AuxiliaryCarry, Reserved5,
42 Zero, Sign, Trap, InterruptEnable, Direction, Overflow, IOPL_0, IOPL_1,
43 NestedTask, Reserved15, Resume, Virtual8086, Alignment, VirtualInterrupt,
44 VirtualInterruptPending, ID, Reserved22, Reserved23, Reserved24, Reserved25,
45 Reserved26, Reserved27, Reserved28, Reserved29, Reserved30, Reserved31);
46 TEFlags = set of TFlags;
48 TFPUState = packed record
49 ControlWord, dumm1: Word;
50 StatusWord, dummy2: Word;
51 TagWord, dummy3: Word;
52 IP_Offset: Cardinal;
53 IP_Selector, Opcode: Word;
54 OP_Offset: Cardinal;
55 OP_Selector, dummy4: Word;
56 ST: array[0..7] of Extended;
57 end;
59 THardwareState = record
60 EFlags: Cardinal;
61 Reg_EAX: Cardinal;
62 FPUState: TFPUState;
63 end;
65 TColors = record
66 FG, BG: TColor;
67 end;
69 TColorLine = record
70 None, Selected: TColors;
71 end;
73 TGridTheme = record
74 Address, Assembly: TColorLine;
75 Highlight, Step: TColors;
76 end;
78 TViewTheme = record
79 Line: TColorLine;
80 Change: TColor;
81 end;
83 TChangeEvent = procedure(Sender: TObject) of object;
84 TInsertEvent = procedure(Sender: TObject; ARow: Integer; Text: String; Insert: Boolean) of object;
85 TRemoveEvent = procedure(Sender: TObject; ARow: Integer) of object;
86 TLogWriteEvent = procedure(Sender: TObject; Log: String; Error: Boolean = False) of object;
87 TLogClearEvent = TChangeEvent;
89 TStrings = array of String;
90 TOperandType = Char;
91 TBranchType = Char;
93 PInstructionRecord = ^TInstructionRecord;
94 TInstructionRecord = record
95 Name, Code, Description: String;
96 Branch: TBranchType;
97 end;
99 POperandRecord = ^TOperandRecord;
100 TOperandRecord = record
101 Name, Code: String;
102 OperandType: TOperandType;
103 Default: String;
104 Data: PChar;
105 end;
107 TOperandTypeRecord = record
108 OperandType: TOperandType;
109 Description: String;
110 end;
112 implementation
114 end.