Changeset 96
- Timestamp:
- Aug 2, 2018, 10:41:11 AM (6 years ago)
- Location:
- trunk
- Files:
-
- 18 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Forms/UFormAbout.lfm
r74 r96 1 1 object FormAbout: TFormAbout 2 2 Left = 562 3 Height = 3 973 Height = 301 4 4 Top = 277 5 Width = 4735 Width = 515 6 6 Caption = 'About' 7 ClientHeight = 397 8 ClientWidth = 473 7 ClientHeight = 301 8 ClientWidth = 515 9 DesignTimePPI = 120 9 10 OnCreate = FormCreate 10 11 OnShow = FormShow 11 12 Position = poScreenCenter 12 LCLVersion = '1. 6.0.4'13 LCLVersion = '1.8.2.0' 13 14 object LabelDescription: TLabel 14 15 Left = 20 15 Height = 2416 Top = 1 0817 Width = 4 3316 Height = 1 17 Top = 132 18 Width = 475 18 19 Align = alTop 19 20 BorderSpacing.Around = 20 20 Caption = 'Simple BrainFuck IDE written in Lazarus/FPC.'21 21 ParentColor = False 22 22 WordWrap = True 23 23 end 24 24 object ButtonClose: TButton 25 Left = 36025 Left = 402 26 26 Height = 25 27 Top = 35727 Top = 261 28 28 Width = 93 29 29 Anchors = [akRight, akBottom] … … 34 34 object LabelContent: TLabel 35 35 Left = 20 36 Height = 2 437 Top = 15 238 Width = 4 3336 Height = 20 37 Top = 153 38 Width = 475 39 39 Align = alTop 40 40 BorderSpacing.Around = 20 … … 45 45 Left = 16 46 46 Height = 25 47 Top = 35747 Top = 261 48 48 Width = 176 49 49 Anchors = [akLeft, akBottom] … … 54 54 object Panel1: TPanel 55 55 Left = 0 56 Height = 8856 Height = 112 57 57 Top = 0 58 Width = 47358 Width = 515 59 59 Align = alTop 60 60 BevelOuter = bvNone 61 ClientHeight = 8862 ClientWidth = 47361 ClientHeight = 112 62 ClientWidth = 515 63 63 TabOrder = 2 64 64 object Image1: TImage … … 67 67 Top = 16 68 68 Width = 69 69 Picture.Data = {70 1754506F727461626C654E6574776F726B477261706869638907000089504E4771 0D0A1A0A0000000D49484452000000400000004008030000009DB781EC00000272 D6504C54450000000000000E0E0E2525252A2A2A4343430000000A0A0A13131373 1414141919190000000101010505050808080B0B0B121212131313151515252574 252727272D2D2D3838383F3F3F4444444747474848482323232424242929292B75 2B2B3232323838383B3B3B3C3C3C4040404343434444444C4C4C00000001000076 010001010101020002020100030100030003020202030303040200050200050077 0506020007030006000607000708000909000A0404040505050904000606060778 07070808080909090A04000C05000A000B0B000C0E000F0F001013080014080079 16090011001212001316001817001919001B0B0B0B0C0C0C0D0D0D0E0E0E101080 101313131616161A1A1A210D00230E00230026240F00250F00260F002710002A81 11002C12002D12003214003315003415003515003F19003400384B00501F1F1F82 2121212727272828282A2A2A2B2B2B4C1F004E20004F2000512100542200552283 005824005924005C25002E2E2E3737373A3A3A4545454646464747474B4B4B4C84 4C4C4F4F4F5E00655F00666100685E26007B32007C32007E330081350084360085 69007071007973007B76007E79008183008B8536008B39008C39008D39008F3A86 00903B00913B00933C00953D00963D00A54300A64300A74400A945008700908887 00919A00A4A700B2A800B3AE00B9B84B00B94B00BB4C00BE4D00BF4E00AF00BA88 B700C3B800C4BC00C8BE00CBBF00CCC100CEC200CFC800D5C900D6E100F0E30089 F2E400F3E700F7E800F8E900F9EB00FBEC00FCED00FDEE00FE5454545B5B5B6190 61616B6B6B6C6C6C5656565F5F5F5555555A5A5A717171717171CC5300CF540091 D15500D35600D75700E35C00E55D00E65D00E85E00E95F00EA5F00EB5F00ED6092 00F16200F26200F46300F56300F66400F76400F96500FA6500FB6600FC6600FD93 6700FE67007676767B7B7B8484848A8A8A8F8F8F9696969F9F9F9C9C9CA8A8A894 B5B5B5A3A3A3A4A4A4A6A6A6C1C1C1C9C9C9CCCCCCD5D5D5BFBFBFA8559EA50095 0000F274524E53003F3F3F3F3F7F7F7F7F7FBFBFBFBFBFBFBFBF7F7F7F7F7F7F96 7F7FBFBFBFBFBFBFBFBFBFBFBFBFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF97 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF98 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF99 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF100 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF101 FFFFFF7F7F7F7F7FBFBFFFFF7FBFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF102 FFFFFFFFFFFFFF3F7F7F7F3F3F3F7F3F3F7F7F7F3F3F3F3F7F9B001E6E000003103 7049444154789CCDD7F75BD3401807F0D41107EE857B82AF04B1540B282E1470104 E146C4BD702B225551C4858A7BEFBDF7DEA3716F11170E10C538C08DE87FE0A5105 A1A5B9DCB5D7DF7C7F808727F97E9EF7DEBBA494E3FEE3BACBF31EB7672524CC106 BCE3C9F345BEBA982ECCF706410FA804410001FD8EA8E7CE1E2FDACB9251972F107 40191D53BC72B8AF266D2D37E744CE683D350EA0877B4EF2BA080771CB4AEA3B108 CC7BD2BBB756600907797747EDDBAA2C359F1DA41D3EA1845B34A014531E0957109 2803645A804520EFE638C606D06E9623E50B31E79150900078B2E701482D8C01110 582949529C93E83C74CF22006DFE1BC8C08B4731003EF3930CE8A7A98536DE66111 726C722A02F4C53540310BB04EBECB2F2D1D658D294F92DAABE31D163C7D6C84112 3572073334404D1C303C90A457EB23F3E37D36BC92A4E4C60A00593820E4010D113 060D1E9AFE66D8E0410D0CB17BDF49195BA29478D4D60C2973BFC9080A20F058114 FE1EE4017E6992A5E426A0FFAAE7D233A37CC998223D5F35C042291DE0403C11115 18B8F6050246984CA6A814E9E5A621764002068015B0CD000C13F7654A6FB70D116 6F780079AB876E464B3838A9B115E88101D11AC070FFBDF47A633F000500885C117 8F86F8D09007E027E19A5EBB8DA90B3B52B7517B947AE6034AF9C4B5251CA429118 3E34603A0E508B0CE4D8CD8009688D016ECA0C5293273889C7589E0510E2D5F9119 DA82D201F3D3889D441D43E758A9DF8B255DCE8F571F0217DE664A0945550BE8120 E67203827A07B00FB41DE221AFE5A2289ACF9F5E1280FE5E262A752EC096AF66121 9FAF88F356403676372102AAD749854022702CAC53DF1597CD7364E064583B54122 A1B6BC87FA104C1548C0D146005EBBC4C3DE0838DE487D07760AB9AA35043200123 73C5334D117022340495BFF5860238C0713C0518653EDFC53683ED79D7AB6BF3124 DC342A70A1AB06C82600941940A27836189F4169429E8B0E24025E3BC5239A21125 5E2501B941DA6D0C0DE9BCF8A239116C430CF696AFE22F02A5B29A6B00A5F6F8126 E71FA44B23E5AB7588C0073D01305F38B5B419E0C06F22C05D07C68A20E739AE127 1523508B0630E6351FAAD6FAC4BA84F214A0126B073728C00FD6B7DA2FDA0CC6128 32023F694021C6257CA4019CAEAE652705C2D71DFB72F2D5E9CFDFCF55F87047129 066D1BED2BB7BB837FBB5900EE8B830E66B3008E8E25F969760180EF2C404B7A130 5E7F9305984907045F1680A703EA7DF807F2279CD37B7E68DE0000000049454E131 44AE426082132 }133 69 end 134 70 object LabelAppName: TLabel 135 71 Left = 104 136 Height = 5572 Height = 92 137 73 Top = 16 138 Width = 14874 Width = 388 139 75 Align = alCustom 76 Anchors = [akTop, akLeft, akRight, akBottom] 77 AutoSize = False 140 78 BorderSpacing.Around = 20 141 Caption = 'LazFuck' 142 Font.Height = -40 79 Font.Height = -50 143 80 ParentColor = False 144 81 ParentFont = False 145 WordWrap = True146 82 end 147 83 end -
trunk/Forms/UFormAbout.pas
r74 r96 56 56 if Assigned(ApplicationInfo) then begin 57 57 LabelAppName.Caption := ApplicationInfo.AppName; 58 LabelAppName.AutoSize := True; 59 LabelAppName.Font.Size := 30; 60 LabelDescription.Caption := ApplicationInfo.Description; 58 61 LabelContent.Caption := SVersion + ': ' + ApplicationInfo.Version + LineEnding + 59 62 SReleaseDate + ': ' + DateToStr(ApplicationInfo.ReleaseDate) + LineEnding + 60 63 SLicense + ': ' + ApplicationInfo.License; 64 Image1.Picture.Bitmap.Assign(Application.Icon); 61 65 end; 62 66 end; … … 70 74 procedure TFormAbout.FormCreate(Sender: TObject); 71 75 begin 76 Core.ThemeManager.UseTheme(Self); 72 77 ApplicationInfo := nil; 73 78 CoolTranslator := nil; -
trunk/Forms/UFormLog.lfm
r60 r96 7 7 ClientHeight = 500 8 8 ClientWidth = 800 9 LCLVersion = '1.3' 9 DesignTimePPI = 120 10 OnCreate = FormCreate 11 LCLVersion = '1.8.2.0' 10 12 object Memo1: TMemo 11 13 Left = 0 -
trunk/Forms/UFormLog.pas
r60 r96 14 14 TFormLog = class(TForm) 15 15 Memo1: TMemo; 16 procedure FormCreate(Sender: TObject); 16 17 private 17 18 { private declarations } … … 27 28 {$R *.lfm} 28 29 30 uses 31 UCore; 32 33 { TFormLog } 34 35 procedure TFormLog.FormCreate(Sender: TObject); 36 begin 37 Core.CoolTranslator1.TranslateComponentRecursive(Self); 38 Core.ThemeManager.UseTheme(Self); 39 end; 40 29 41 end. 30 42 -
trunk/Forms/UFormMain.pas
r93 r96 202 202 DockInit; 203 203 Core.PersistentForm1.Load(Self, True); 204 Core.ThemeManager.UseTheme(Self) 204 205 end; 205 206 end; … … 435 436 procedure TFormMain.AViewCompilersExecute(Sender: TObject); 436 437 begin 438 if not Assigned(FormTargets) then FormTargets := TFormTargets.Create(Self); 437 439 FormTargets.Show; 438 440 end; … … 445 447 procedure TFormMain.AViewLogExecute(Sender: TObject); 446 448 begin 449 if not Assigned(FormLog) then FormLog := TFormLog.Create(Self); 447 450 FormLog.Show; 448 451 end; … … 480 483 end; 481 484 end; 485 Core.ThemeManager.UseTheme(Self); 482 486 end; 483 487 finally -
trunk/Forms/UFormOptions.lfm
r91 r96 1 1 object FormOptions: TFormOptions 2 Left = 5103 Height = 4184 Top = 3245 Width = 5112 Left = 401 3 Height = 356 4 Top = 236 5 Width = 607 6 6 Caption = 'Options' 7 ClientHeight = 4188 ClientWidth = 5117 ClientHeight = 356 8 ClientWidth = 607 9 9 DesignTimePPI = 120 10 10 OnClose = FormClose … … 13 13 LCLVersion = '1.8.2.0' 14 14 object ButtonOk: TButton 15 Left = 42215 Left = 526 16 16 Height = 25 17 Top = 3 8617 Top = 324 18 18 Width = 75 19 19 Anchors = [akRight, akBottom] 20 20 Caption = 'Ok' 21 21 ModalResult = 1 22 OnClick = ButtonOkClick23 22 TabOrder = 0 24 23 end 25 24 object ButtonCancel: TButton 26 Left = 33425 Left = 430 27 26 Height = 25 28 Top = 3 8627 Top = 324 29 28 Width = 75 30 29 Anchors = [akRight, akBottom] … … 33 32 TabOrder = 1 34 33 end 35 object SpinEditCellSize: TSpinEdit 36 Left = 165 37 Height = 28 38 Top = 40 39 Width = 130 40 MaxValue = 2000000000 34 object PageControl1: TPageControl 35 Left = 8 36 Height = 310 37 Top = 8 38 Width = 593 39 ActivePage = TabSheetBuild 40 Anchors = [akTop, akLeft, akRight, akBottom] 41 TabIndex = 1 41 42 TabOrder = 2 42 end 43 object SpinEditMemorySize: TSpinEdit 44 Left = 165 45 Height = 28 46 Top = 6 47 Width = 130 48 MaxValue = 2000000000 49 TabOrder = 3 50 end 51 object Label1: TLabel 52 Left = 8 53 Height = 20 54 Top = 8 55 Width = 87 56 Caption = 'Memory size:' 57 ParentColor = False 58 end 59 object Label2: TLabel 60 Left = 8 61 Height = 20 62 Top = 40 63 Width = 57 64 Caption = 'Cell size:' 65 ParentColor = False 66 end 67 object Label3: TLabel 68 Left = 8 69 Height = 20 70 Top = 95 71 Width = 127 72 Caption = 'Interface language:' 73 ParentColor = False 74 end 75 object CheckBox1: TCheckBox 76 Left = 8 77 Height = 27 78 Top = 128 79 Width = 499 80 Anchors = [akTop, akLeft, akRight] 81 AutoSize = False 82 Caption = 'Reopend last opened project' 83 TabOrder = 4 84 end 85 object SpinEditDPIX: TSpinEdit 86 Left = 104 87 Height = 28 88 Top = 193 89 Width = 80 90 MaxValue = 1000 91 MinValue = 1 92 TabOrder = 5 93 Value = 1 94 end 95 object LabelDPI: TLabel 96 Left = 24 97 Height = 20 98 Top = 201 99 Width = 26 100 Caption = 'DPI:' 101 ParentColor = False 102 end 103 object SpinEditDPIY: TSpinEdit 104 Left = 208 105 Height = 28 106 Top = 193 107 Width = 80 108 MaxValue = 1000 109 MinValue = 1 110 TabOrder = 6 111 Value = 1 112 end 113 object LabelX: TLabel 114 Left = 192 115 Height = 20 116 Top = 201 117 Width = 7 118 Caption = 'x' 119 ParentColor = False 120 end 121 object CheckBoxDPIAuto: TCheckBox 122 Left = 8 123 Height = 27 124 Top = 168 125 Width = 491 126 Anchors = [akTop, akLeft, akRight] 127 AutoSize = False 128 Caption = 'Automatic DPI' 129 OnChange = CheckBoxDPIAutoChange 130 TabOrder = 7 131 end 132 object Label4: TLabel 133 Left = 16 134 Height = 20 135 Top = 248 136 Width = 159 137 Caption = 'Compiler optimizations:' 138 ParentColor = False 139 end 140 object ComboBoxLanguage: TComboBox 141 Left = 248 142 Height = 28 143 Top = 83 144 Width = 188 145 ItemHeight = 20 146 Style = csDropDownList 147 TabOrder = 8 148 end 149 object CheckBoxOptimizeAddSub: TCheckBox 150 Left = 39 151 Height = 24 152 Top = 280 153 Width = 189 154 Caption = 'Addition and subtraction' 155 TabOrder = 9 156 end 157 object CheckBoxOptimizeMerge: TCheckBox 158 Left = 39 159 Height = 24 160 Top = 304 161 Width = 181 162 Caption = 'Merge same operations' 163 TabOrder = 10 164 end 165 object CheckBoxOptimizeRelativeIndexes: TCheckBox 166 Left = 39 167 Height = 24 168 Top = 328 169 Width = 131 170 Caption = 'Relative indexes' 171 TabOrder = 11 172 end 173 object CheckBoxOptimizeCopyMultiply: TCheckBox 174 Left = 39 175 Height = 24 176 Top = 352 177 Width = 116 178 Caption = 'Copy multiply' 179 TabOrder = 12 180 end 181 object ComboBoxOptimization: TComboBox 182 Left = 256 183 Height = 28 184 Top = 248 185 Width = 188 186 ItemHeight = 20 187 Items.Strings = ( 188 'None' 189 'Normal' 190 ) 191 OnSelect = CheckBoxDPIAutoChange 192 Style = csDropDownList 193 TabOrder = 13 43 object TabSheetGeneral: TTabSheet 44 Caption = 'General' 45 ClientHeight = 277 46 ClientWidth = 585 47 object Panel1: TPanel 48 Left = 0 49 Height = 277 50 Top = 0 51 Width = 585 52 Align = alClient 53 BevelOuter = bvNone 54 ClientHeight = 277 55 ClientWidth = 585 56 TabOrder = 0 57 object Label3: TLabel 58 Left = 8 59 Height = 20 60 Top = 48 61 Width = 127 62 Caption = 'Interface language:' 63 ParentColor = False 64 end 65 object ComboBoxLanguage: TComboBox 66 Left = 256 67 Height = 28 68 Top = 48 69 Width = 188 70 ItemHeight = 20 71 Style = csDropDownList 72 TabOrder = 0 73 end 74 object CheckBox1: TCheckBox 75 Left = 8 76 Height = 27 77 Top = 85 78 Width = 1051 79 Anchors = [akTop, akLeft, akRight] 80 AutoSize = False 81 Caption = 'Reopend last opened project' 82 TabOrder = 1 83 end 84 object CheckBoxDPIAuto: TCheckBox 85 Left = 8 86 Height = 27 87 Top = 125 88 Width = 1043 89 Anchors = [akTop, akLeft, akRight] 90 AutoSize = False 91 Caption = 'Automatic DPI' 92 OnChange = CheckBoxDPIAutoChange 93 TabOrder = 2 94 end 95 object LabelDPI: TLabel 96 Left = 30 97 Height = 20 98 Top = 160 99 Width = 26 100 Caption = 'DPI:' 101 ParentColor = False 102 end 103 object SpinEditDPIX: TSpinEdit 104 Left = 112 105 Height = 28 106 Top = 158 107 Width = 80 108 MaxValue = 1000 109 MinValue = 1 110 TabOrder = 3 111 Value = 1 112 end 113 object SpinEditDPIY: TSpinEdit 114 Left = 216 115 Height = 28 116 Top = 160 117 Width = 80 118 MaxValue = 1000 119 MinValue = 1 120 TabOrder = 4 121 Value = 1 122 end 123 object LabelX: TLabel 124 Left = 200 125 Height = 20 126 Top = 160 127 Width = 7 128 Caption = 'x' 129 ParentColor = False 130 end 131 object LabelTheme: TLabel 132 Left = 8 133 Height = 20 134 Top = 16 135 Width = 48 136 Caption = 'Theme:' 137 ParentColor = False 138 end 139 object ComboBoxTheme: TComboBox 140 Left = 256 141 Height = 28 142 Top = 8 143 Width = 188 144 ItemHeight = 20 145 Style = csDropDownList 146 TabOrder = 5 147 end 148 end 149 end 150 object TabSheetBuild: TTabSheet 151 Caption = 'Build' 152 ClientHeight = 277 153 ClientWidth = 585 154 object Panel2: TPanel 155 Left = 0 156 Height = 277 157 Top = 0 158 Width = 585 159 Align = alClient 160 BevelOuter = bvNone 161 ClientHeight = 277 162 ClientWidth = 585 163 TabOrder = 0 164 object Label4: TLabel 165 Left = 8 166 Height = 20 167 Top = 104 168 Width = 159 169 Caption = 'Compiler optimizations:' 170 ParentColor = False 171 end 172 object ComboBoxOptimization: TComboBox 173 Left = 248 174 Height = 28 175 Top = 104 176 Width = 188 177 ItemHeight = 20 178 Items.Strings = ( 179 'None' 180 'Normal' 181 ) 182 OnSelect = CheckBoxDPIAutoChange 183 Style = csDropDownList 184 TabOrder = 0 185 end 186 object CheckBoxOptimizeAddSub: TCheckBox 187 Left = 31 188 Height = 24 189 Top = 136 190 Width = 189 191 Caption = 'Addition and subtraction' 192 TabOrder = 1 193 end 194 object CheckBoxOptimizeMerge: TCheckBox 195 Left = 31 196 Height = 24 197 Top = 160 198 Width = 181 199 Caption = 'Merge same operations' 200 TabOrder = 2 201 end 202 object CheckBoxOptimizeCopyMultiply: TCheckBox 203 Left = 31 204 Height = 24 205 Top = 208 206 Width = 116 207 Caption = 'Copy multiply' 208 TabOrder = 3 209 end 210 object CheckBoxOptimizeRelativeIndexes: TCheckBox 211 Left = 31 212 Height = 24 213 Top = 184 214 Width = 131 215 Caption = 'Relative indexes' 216 TabOrder = 4 217 end 218 object Label2: TLabel 219 Left = 8 220 Height = 20 221 Top = 40 222 Width = 57 223 Caption = 'Cell size:' 224 ParentColor = False 225 end 226 object Label1: TLabel 227 Left = 8 228 Height = 20 229 Top = 8 230 Width = 87 231 Caption = 'Memory size:' 232 ParentColor = False 233 end 234 object SpinEditMemorySize: TSpinEdit 235 Left = 165 236 Height = 28 237 Top = 6 238 Width = 130 239 MaxValue = 2000000000 240 TabOrder = 5 241 end 242 object SpinEditCellSize: TSpinEdit 243 Left = 165 244 Height = 28 245 Top = 40 246 Width = 130 247 MaxValue = 2000000000 248 TabOrder = 6 249 end 250 end 251 end 194 252 end 195 253 end -
trunk/Forms/UFormOptions.pas
r91 r96 7 7 uses 8 8 Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls, 9 Spin, UTarget;9 Spin, ComCtrls, ExtCtrls, UTarget, UTheme; 10 10 11 11 type … … 17 17 ButtonCancel: TButton; 18 18 CheckBox1: TCheckBox; 19 CheckBoxDPIAuto: TCheckBox; 19 20 CheckBoxOptimizeAddSub: TCheckBox; 20 CheckBox DPIAuto: TCheckBox;21 CheckBoxOptimizeCopyMultiply: TCheckBox; 21 22 CheckBoxOptimizeMerge: TCheckBox; 22 23 CheckBoxOptimizeRelativeIndexes: TCheckBox; 23 CheckBoxOptimizeCopyMultiply: TCheckBox;24 24 ComboBoxLanguage: TComboBox; 25 25 ComboBoxOptimization: TComboBox; 26 ComboBoxTheme: TComboBox; 26 27 Label1: TLabel; 27 28 Label2: TLabel; … … 29 30 Label4: TLabel; 30 31 LabelDPI: TLabel; 32 LabelTheme: TLabel; 31 33 LabelX: TLabel; 34 PageControl1: TPageControl; 35 Panel1: TPanel; 36 Panel2: TPanel; 37 SpinEditCellSize: TSpinEdit; 32 38 SpinEditDPIX: TSpinEdit; 33 39 SpinEditDPIY: TSpinEdit; 34 SpinEditCellSize: TSpinEdit;35 40 SpinEditMemorySize: TSpinEdit; 36 procedure ButtonOkClick(Sender: TObject); 41 TabSheetGeneral: TTabSheet; 42 TabSheetBuild: TTabSheet; 37 43 procedure CheckBoxDPIAutoChange(Sender: TObject); 38 44 procedure FormClose(Sender: TObject; var CloseAction: TCloseAction); … … 62 68 begin 63 69 Core.PersistentForm1.Load(Self); 64 65 Core.CoolTranslator1.LanguageListToStrings(ComboBoxLanguage.Items);66 ComboBoxLanguage.ItemIndex := ComboBoxLanguage.Items.IndexOfObject(Core.CoolTranslator1.Language);67 if ComboBoxLanguage.ItemIndex = -1 then ComboBoxLanguage.ItemIndex := 0;68 CheckBox1.Checked := Core.OpenProjectOnStart;69 70 end; 70 71 … … 87 88 procedure TFormOptions.Load; 88 89 begin 90 ComboBoxLanguage.ItemIndex := ComboBoxLanguage.Items.IndexOfObject(Core.CoolTranslator1.Language); 91 if ComboBoxLanguage.ItemIndex = -1 then ComboBoxLanguage.ItemIndex := 0; 92 ComboBoxTheme.ItemIndex := ComboBoxTheme.Items.IndexOfObject(Core.ThemeManager.Theme); 93 if ComboBoxTheme.ItemIndex = -1 then ComboBoxTheme.ItemIndex := 0; 94 CheckBox1.Checked := Core.OpenProjectOnStart; 89 95 CheckBoxOptimizeAddSub.Checked := Core.Optimizations.AddSub; 90 96 CheckBoxOptimizeMerge.Checked := Core.Optimizations.Merge; … … 102 108 procedure TFormOptions.Save; 103 109 begin 110 if ComboBoxLanguage.ItemIndex <> -1 then 111 Core.CoolTranslator1.Language := TLanguage(ComboBoxLanguage.Items.Objects[ComboBoxLanguage.ItemIndex]); 112 if ComboBoxTheme.ItemIndex <> -1 then 113 Core.ThemeManager.Theme := TTheme(ComboBoxTheme.Items.Objects[ComboBoxTheme.ItemIndex]); 114 Core.OpenProjectOnStart := CheckBox1.Checked; 104 115 Core.ScaleDPI1.DPI := Point(SpinEditDPIX.Value, SpinEditDPIY.Value); 105 116 Core.ScaleDPI1.AutoDetect := CheckBoxDPIAuto.Checked; … … 111 122 Core.Optimizations.RelativeIndexes := CheckBoxOptimizeRelativeIndexes.Checked; 112 123 Core.Optimizations.CopyMultiply := CheckBoxOptimizeCopyMultiply.Checked; 113 end;114 115 procedure TFormOptions.ButtonOkClick(Sender: TObject);116 begin117 if ComboBoxLanguage.ItemIndex <> -1 then118 Core.CoolTranslator1.Language := TLanguage(ComboBoxLanguage.Items.Objects[ComboBoxLanguage.ItemIndex]);119 Core.OpenProjectOnStart := CheckBox1.Checked;120 124 end; 121 125 … … 134 138 begin 135 139 Core.CoolTranslator1.TranslateComponentRecursive(Self); 140 Core.ThemeManager.UseTheme(Self); 141 Core.ThemeManager.Themes.LoadToStrings(ComboBoxTheme.Items); 142 Core.CoolTranslator1.LanguageListToStrings(ComboBoxLanguage.Items); 136 143 end; 137 144 -
trunk/Forms/UFormTargetOptions.pas
r92 r96 69 69 begin 70 70 Core.CoolTranslator1.TranslateComponentRecursive(Self); 71 Core.ThemeManager.UseTheme(Self); 71 72 end; 72 73 -
trunk/Forms/UFormTargets.lfm
r92 r96 8 8 ClientWidth = 574 9 9 DesignTimePPI = 120 10 OnCreate = FormCreate 10 11 OnShow = FormShow 11 12 LCLVersion = '1.8.2.0' -
trunk/Forms/UFormTargets.pas
r92 r96 14 14 TFormTargets = class(TForm) 15 15 ListView1: TListView; 16 procedure FormCreate(Sender: TObject); 16 17 procedure FormShow(Sender: TObject); 17 18 procedure ListView1Data(Sender: TObject; Item: TListItem); … … 39 40 begin 40 41 ReloadList; 42 end; 43 44 procedure TFormTargets.FormCreate(Sender: TObject); 45 begin 46 Core.CoolTranslator1.TranslateComponentRecursive(Self); 47 Core.ThemeManager.UseTheme(Self); 41 48 end; 42 49 -
trunk/Languages/LazFuck.cs.po
r92 r96 26 26 msgstr "O programu" 27 27 28 #: tformabout.labelappname.caption29 msgctxt "tformabout.labelappname.caption"30 msgid "LazFuck"31 msgstr "LazFuck"32 33 28 #: tformabout.labelcontent.caption 34 29 msgctxt "tformabout.labelcontent.caption" 35 30 msgid " " 36 31 msgstr " " 37 38 #: tformabout.labeldescription.caption39 msgid "Simple BrainFuck IDE written in Lazarus/FPC."40 msgstr "Jednoduché BrainFuck IDE napsané v Lazarus/FPC."41 32 42 33 #: tformcompilers.caption … … 399 390 msgstr "DPI:" 400 391 392 #: tformoptions.labeltheme.caption 393 msgid "Theme:" 394 msgstr "Téma:" 395 401 396 #: tformoptions.labelx.caption 402 397 msgctxt "tformoptions.labelx.caption" … … 404 399 msgstr "x" 405 400 401 #: tformoptions.tabsheetbuild.caption 402 msgid "Build" 403 msgstr "SestavenÃ" 404 405 #: tformoptions.tabsheetgeneral.caption 406 msgid "General" 407 msgstr "Obecné" 408 406 409 #: tformoutput.caption 407 410 msgid "Output" -
trunk/Languages/LazFuck.po
r92 r96 16 16 msgstr "" 17 17 18 #: tformabout.labelappname.caption19 msgctxt "tformabout.labelappname.caption"20 msgid "LazFuck"21 msgstr ""22 23 18 #: tformabout.labelcontent.caption 24 19 msgctxt "tformabout.labelcontent.caption" … … 26 21 msgstr "" 27 22 28 #: tformabout.labeldescription.caption29 msgid "Simple BrainFuck IDE written in Lazarus/FPC."30 msgstr ""31 32 23 #: tformcompilers.caption 33 24 msgctxt "TFORMCOMPILERS.CAPTION" … … 355 346 msgstr "" 356 347 348 #: tformoptions.labeltheme.caption 349 msgid "Theme:" 350 msgstr "" 351 357 352 #: tformoptions.labelx.caption 358 353 msgctxt "tformoptions.labelx.caption" … … 360 355 msgstr "" 361 356 357 #: tformoptions.tabsheetbuild.caption 358 msgid "Build" 359 msgstr "" 360 361 #: tformoptions.tabsheetgeneral.caption 362 msgid "General" 363 msgstr "" 364 362 365 #: tformoutput.caption 363 366 msgid "Output" -
trunk/LazFuck.lpr
r92 r96 42 42 Application.CreateForm(TFormSourceCode, FormSourceCode); 43 43 Application.CreateForm(TFormTargetCode, FormTargetCode); 44 Application.CreateForm(TFormLog, FormLog);45 Application.CreateForm(TFormTargets, FormTargets);46 44 Application.Run; 47 45 end. -
trunk/Target/UTargetInterpretter.pas
r91 r96 302 302 for I := 0 to Length(FProgram) - 1 do begin 303 303 Result := Result + BrainFuckCommandText[FProgram[I].Command]; 304 //if FProgram[I].Command in [cmInc, cmDec, cmPointerInc, cmPointerDec, 305 //cmSet, cmMultipy] then begin 306 if FProgram[I].Parameter > 1 then 307 Result := Result + IntToStr(FProgram[I].Parameter); 308 if FProgram[I].RelIndex > 1 then 304 if FProgram[I].Command in [cmInc, cmDec, cmPointerInc, cmPointerDec, 305 cmSet, cmMultipy] then begin 306 if FProgram[I].Parameter <> 1 then 307 Result := Result + IntToStr(FProgram[I].Parameter); 308 end; 309 if FProgram[I].RelIndex <> 0 then 309 310 Result := Result + 'R' + IntToStr(FProgram[I].RelIndex); 310 //end;311 311 end; 312 312 end; -
trunk/Target/UTargetJava.pas
r87 r96 6 6 7 7 uses 8 Classes, SysUtils, FileUtil, UTarget, UBFTarget, Process,Dialogs;8 Classes, SysUtils, FileUtil, UTarget, UBFTarget, Dialogs; 9 9 10 10 type -
trunk/UBFTarget.pas
r91 r96 12 12 TMachineCommand = (cmNoOperation, cmInc, cmDec, cmPointerInc, cmPointerDec, 13 13 cmOutput, cmInput, cmLoopStart, cmLoopEnd, cmDebug, cmSet, cmMultipy); 14 15 { TMachineOperation } 14 16 15 17 TMachineOperation = record … … 17 19 Parameter: Integer; 18 20 RelIndex: Integer; 21 function Create(Command: TMachineCommand; Parameter, RelIndex: Integer): TMachineOperation; 19 22 end; 20 23 … … 55 58 implementation 56 59 60 { TMachineOperation } 61 62 function TMachineOperation.Create(Command: TMachineCommand; Parameter, 63 RelIndex: Integer): TMachineOperation; 64 begin 65 Result.Command := Command; 66 Result.Parameter := Parameter; 67 Result.RelIndex := RelIndex; 68 end; 69 57 70 function TBFTarget.CheckClear: Boolean; 58 71 begin … … 108 121 NewProgram[NewProgramIndex].Parameter := CheckOccurenceSumParam(cmDec); 109 122 end; 110 else begin 111 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 112 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 113 end; 123 else NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 114 124 end; 115 125 DebugSteps.UpdateTargetPos(FProgramIndex, NewProgramIndex); … … 234 244 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 235 245 end else begin 236 NewProgram[NewProgramIndex].Command := cmSet; 237 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 246 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 238 247 end; 239 248 end; 240 249 cmLoopStart: begin 241 250 if CheckClear then begin 242 NewProgram[NewProgramIndex].Command := cmSet; 243 NewProgram[NewProgramIndex].Parameter := 0; 251 NewProgram[NewProgramIndex] := TMachineOperation.Create(cmSet, 0, 0); 244 252 Inc(FProgramIndex, 2); 245 253 end else begin 246 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 247 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 248 end; 249 end; 250 else begin 251 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 252 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 253 end; 254 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 255 end; 256 end; 257 else NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 254 258 end; 255 259 PreviousCommand := FProgram[FProgramIndex].Command; … … 294 298 end; 295 299 cmInc, cmDec, cmInput, cmOutput, cmSet: begin 296 NewProgram[NewProgramIndex] .Command := FProgram[FProgramIndex].Command;297 NewProgram[NewProgramIndex]. Parameter := FProgram[FProgramIndex].Parameter;298 NewProgram[NewProgramIndex].RelIndex :=RelIndex;300 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 301 NewProgram[NewProgramIndex].RelIndex := 302 NewProgram[NewProgramIndex].RelIndex + RelIndex; 299 303 end; 300 304 cmLoopStart, cmLoopEnd: begin 301 305 if RelIndex > 0 then begin 302 NewProgram[NewProgramIndex].Command := cmPointerInc; 303 NewProgram[NewProgramIndex].Parameter := RelIndex; 304 NewProgram[NewProgramIndex].RelIndex := 0; 306 NewProgram[NewProgramIndex] := TMachineOperation.Create(cmPointerInc, 307 RelIndex, 0); 305 308 Inc(NewProgramIndex); 306 309 RelIndex := 0; 307 310 end else 308 311 if RelIndex < 0 then begin 309 NewProgram[NewProgramIndex].Command := cmPointerDec; 310 NewProgram[NewProgramIndex].Parameter := Abs(RelIndex); 311 NewProgram[NewProgramIndex].RelIndex := 0; 312 NewProgram[NewProgramIndex] := TMachineOperation.Create(cmPointerDec, 313 Abs(RelIndex), 0); 312 314 Inc(NewProgramIndex); 313 315 RelIndex := 0; 314 316 end; 315 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 316 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 317 NewProgram[NewProgramIndex].RelIndex := 0; 318 end; 317 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 318 end; 319 else raise Exception.Create(Format('Unsupported command %d', [FProgram[FProgramIndex].Command])); 319 320 end; 320 321 DebugSteps.UpdateTargetPos(FProgramIndex, NewProgramIndex); … … 351 352 cmPointerInc: begin 352 353 PointerChange := PointerChange + FProgram[FProgramIndex].Parameter; 353 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 354 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 355 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex; 354 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 356 355 end; 357 356 cmPointerDec: begin 358 357 PointerChange := PointerChange - FProgram[FProgramIndex].Parameter; 359 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 360 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 361 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex; 358 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 362 359 end; 363 360 cmInc: begin 364 361 if not ProcessLoop then begin 365 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 366 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 367 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex; 362 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 368 363 end else begin 369 364 if ((FProgram[FProgramIndex].RelIndex + PointerChange) <> 0) then begin 365 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 370 366 NewProgram[NewProgramIndex].Command := cmMultipy; 371 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter;372 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex;373 367 end else Dec(NewProgramIndex); 374 368 end; … … 379 373 (FProgram[FProgramIndex].Parameter = 1) then 380 374 Inc(NumberOfBaseDecrement); 381 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 382 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 383 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex; 375 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 384 376 end else begin 385 377 if ((FProgram[FProgramIndex].RelIndex + PointerChange) <> 0) then begin 378 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 386 379 NewProgram[NewProgramIndex].Command := cmMultipy; 387 380 NewProgram[NewProgramIndex].Parameter := -FProgram[FProgramIndex].Parameter; 388 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex;389 381 end else Dec(NewProgramIndex); 390 382 end; 391 383 end; 392 384 cmInput, cmOutput: begin 393 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 394 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 395 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex; 385 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 396 386 Inc(NumberOfBaseDecrement, 2); 397 387 end; 398 388 cmSet: begin 399 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 400 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 401 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex; 389 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 402 390 Inc(NumberOfBaseDecrement, 2); 403 391 end; … … 408 396 LoopStartIndex := FProgramIndex; 409 397 LoopStartIndexNew := NewProgramIndex; 410 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 411 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 412 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex; 398 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 413 399 end else begin 414 400 Dec(NewProgramIndex); … … 422 408 ProcessLoop := True; 423 409 end else begin 424 NewProgram[NewProgramIndex].Command := FProgram[FProgramIndex].Command; 425 NewProgram[NewProgramIndex].Parameter := FProgram[FProgramIndex].Parameter; 426 NewProgram[NewProgramIndex].RelIndex := FProgram[FProgramIndex].RelIndex; 410 NewProgram[NewProgramIndex] := FProgram[FProgramIndex]; 427 411 end; 428 412 end else begin 429 NewProgram[NewProgramIndex].Command := cmSet; 430 NewProgram[NewProgramIndex].Parameter := 0; 431 NewProgram[NewProgramIndex].RelIndex := 0; 413 NewProgram[NewProgramIndex] := TMachineOperation.Create(cmSet, 0, 0); 432 414 ProcessLoop := False; 433 415 NumberOfBaseDecrement := 0; 434 416 end; 435 417 end; 418 else raise Exception.Create(Format('Unsupported command %d', [FProgram[FProgramIndex].Command])); 436 419 end; 437 420 DebugSteps.UpdateTargetPos(FProgramIndex, NewProgramIndex); … … 458 441 case FSourceCode[I] of 459 442 '+': begin 460 FProgram[FProgramIndex].Command := cmInc; 461 FProgram[FProgramIndex].Parameter := 1; 462 FProgram[FProgramIndex].RelIndex := 0; 443 FProgram[FProgramIndex] := TMachineOperation.Create(cmInc, 1, 0); 463 444 DebugSteps.AddStep(I - 1, FProgramIndex, soNormal); 464 445 end; 465 446 '-': begin 466 FProgram[FProgramIndex].Command := cmDec; 467 FProgram[FProgramIndex].Parameter := 1; 468 FProgram[FProgramIndex].RelIndex := 0; 447 FProgram[FProgramIndex] := TMachineOperation.Create(cmDec, 1, 0); 469 448 DebugSteps.AddStep(I - 1, FProgramIndex, soNormal); 470 449 end; 471 450 '>': begin 472 FProgram[FProgramIndex].Command := cmPointerInc; 473 FProgram[FProgramIndex].Parameter := 1; 474 FProgram[FProgramIndex].RelIndex := 0; 451 FProgram[FProgramIndex] := TMachineOperation.Create(cmPointerInc, 1, 0); 475 452 DebugSteps.AddStep(I - 1, FProgramIndex, soNormal); 476 453 end; 477 454 '<': begin 478 FProgram[FProgramIndex].Command := cmPointerDec; 479 FProgram[FProgramIndex].Parameter := 1; 480 FProgram[FProgramIndex].RelIndex := 0; 455 FProgram[FProgramIndex] := TMachineOperation.Create(cmPointerDec, 1, 0); 481 456 DebugSteps.AddStep(I - 1, FProgramIndex, soNormal); 482 457 end; 483 458 ',': begin 484 FProgram[FProgramIndex].Command := cmInput; 485 FProgram[FProgramIndex].Parameter := 0; 486 FProgram[FProgramIndex].RelIndex := 0; 459 FProgram[FProgramIndex] := TMachineOperation.Create(cmInput, 0, 0); 487 460 DebugSteps.AddStep(I - 1, FProgramIndex, soNormal); 488 461 end; 489 462 '.': begin 490 FProgram[FProgramIndex].Command := cmOutput; 491 FProgram[FProgramIndex].Parameter := 0; 492 FProgram[FProgramIndex].RelIndex := 0; 463 FProgram[FProgramIndex] := TMachineOperation.Create(cmOutput, 0, 0); 493 464 DebugSteps.AddStep(I - 1, FProgramIndex, soNormal); 494 465 end; 495 466 '[': begin 496 FProgram[FProgramIndex].Command := cmLoopStart; 497 FProgram[FProgramIndex].Parameter := 0; 498 FProgram[FProgramIndex].RelIndex := 0; 467 FProgram[FProgramIndex] := TMachineOperation.Create(cmLoopStart, 0, 0); 499 468 DebugSteps.AddStep(I - 1, FProgramIndex, soStepIn); 500 469 end; 501 470 ']': begin 502 FProgram[FProgramIndex].Command := cmLoopEnd; 503 FProgram[FProgramIndex].Parameter := 0; 504 FProgram[FProgramIndex].RelIndex := 0; 471 FProgram[FProgramIndex] := TMachineOperation.Create(cmLoopEnd, 0 ,0); 505 472 DebugSteps.AddStep(I - 1, FProgramIndex, soStepOut); 506 473 end -
trunk/UCore.lfm
r93 r96 20 20 EmailContact = 'robie@centrum.cz' 21 21 AppName = 'LazFuck' 22 Description = 'Simple BrainFuck IDE written in Lazarus/FPC.' 22 23 ReleaseDate = 43301 23 24 RegistryKey = '\Software\Chronosoft\LazFuck' … … 951 952 top = 100 952 953 end 954 object ThemeManager: TThemeManager 955 left = 302 956 top = 174 957 end 953 958 end -
trunk/UCore.pas
r93 r96 8 8 Classes, SysUtils, FileUtil, UApplicationInfo, ULastOpenedList, UProject, 9 9 UCoolTranslator, UTarget, URegistry, Registry, Graphics, Controls, UScaleDPI, 10 UPersistentForm, U BFTarget;10 UPersistentForm, UTheme, UBFTarget; 11 11 12 12 type … … 21 21 PersistentForm1: TPersistentForm; 22 22 ScaleDPI1: TScaleDPI; 23 ThemeManager: TThemeManager; 23 24 procedure DataModuleCreate(Sender: TObject); 24 25 procedure DataModuleDestroy(Sender: TObject); … … 109 110 MemorySize := ReadIntegerWithDefault('MemorySize', 30000); 110 111 CellSize := ReadIntegerWithDefault('CellSize', 256); 112 ThemeManager.Theme := ThemeManager.Themes.FindByName(ReadStringWithDefault('Theme', 'System')); 111 113 finally 112 114 Free; … … 134 136 WriteString('LanguageCode', CoolTranslator1.Language.Code) 135 137 else DeleteValue('LanguageCode'); 138 WriteString('Theme', ThemeManager.Theme.Name); 136 139 finally 137 140 Free;
Note:
See TracChangeset
for help on using the changeset viewer.