Skip to content

Commit d4d1ac1

Browse files
committed
New theme. Config file location update.
Added Visual Studio Dark theme. Added ExecuteFileAsAdmin for PackMan.
1 parent 6fc8ef2 commit d4d1ac1

File tree

12 files changed

+66
-17
lines changed

12 files changed

+66
-17
lines changed

Source/DefaultFiles.rc

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -341,4 +341,28 @@ STRINGTABLE
341341
12020, "7895160, 1973790"
342342
12021, "4473924, 15658734"
343343
12022, "39423, 5328448"
344+
345+
/* Visual Studio Dark */
346+
13001, "$0063C793, clNone, 0, 0, 0"
347+
13002, "$00007AD5, $001E1E1E, 0, 0, 0"
348+
13003, "$003E8B60, $001E1E1E, 0, 1, 0"
349+
13004, "$0022CDFF, $001E1E1E, 0, 0, 0"
350+
13005, "$0022CDFF, clNone, 0, 0, 0"
351+
13006, "$00E6D8AD, $001E1E1E, 0, 0, 0"
352+
13007, "$002930FF, $001E1E1E, 0, 0, 0"
353+
13008, "$00A8CE9C, $021E1E1E, 0, 0, 0"
354+
13009, "$0022CDFF, clNone, 0, 0, 0"
355+
13010, "$009B9B9B, $021E1E1E, 0, 0, 0"
356+
13011, "$00D68E3D, $001E1E1E, 0, 1, 0"
357+
13012, "clNone, $001E1E1E, 0, 0, 0"
358+
13013, "$00859DD6, $021E1E1E, 0, 0, 0"
359+
13014, "$00B7E2E8, clNone, 0, 0, 0"
360+
13015, "clHighlight, clWhite, 0, 0, 0"
361+
13016, "clWhite, clMaroon, 0, 0, 0"
362+
13017, "16777215, 42107"
363+
13018, "16777215, 2894966"
364+
13019, "16777215, 11570432"
365+
13020, "11505963, 1973790"
366+
13021, "16777215, 7884582"
367+
13022, "10197915, 5328448"
344368
}

Source/EditorOptFrm.dfm

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -670,9 +670,7 @@ object EditorOptForm: TEditorOptForm
670670
'String'
671671
'Symbol'
672672
'WhiteSpace'
673-
'Directives'
674-
'Monokai'
675-
'Monokai Fresh')
673+
'Directives')
676674
ParentCtl3D = False
677675
TabOrder = 0
678676
OnClick = ElementListClick
@@ -743,7 +741,8 @@ object EditorOptForm: TEditorOptForm
743741
'Obvilion'
744742
'PlasticCodeWrap'
745743
'Monokai'
746-
'Monokai Fresh')
744+
'Monokai Fresh'
745+
'Visual Studio Dark')
747746
end
748747
object edSyntaxExt: TEdit
749748
Left = 182

Source/EditorOptFrm.pas

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1085,7 +1085,7 @@ procedure TEditorOptForm.cboQuickColorSelect(Sender: TObject);
10851085
i: integer;
10861086
attr: TSynHighlighterAttributes;
10871087
begin
1088-
if cboQuickColor.ItemIndex > 12 then begin // 12 == number of built-in styles
1088+
if cboQuickColor.ItemIndex > 13 then begin // 13 == number of built-in styles
10891089
// custom style; load from disk
10901090
LoadSyntax(cboQuickColor.Items[cboQuickColor.ItemIndex]);
10911091
end else begin

Source/LangFrm.dfm

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,8 @@ object LangForm: TLangForm
248248
'Obvilion'
249249
'PlasticCodeWrap'
250250
'Monokai'
251-
'Monokai Fresh')
251+
'Monokai Fresh'
252+
'Visual Studio Dark')
252253
end
253254
object cmbFont: TComboBox
254255
Left = 56

Source/LangFrm.pas

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,8 @@ procedure TLangForm.ColorChange(Sender: TObject);
198198
devEditor.HighColor := clBlack
199199
else if cmbColors.Text = 'Monokai Fresh' then
200200
devEditor.HighColor := clBlack
201+
else if cmbColors.Text = 'Visual Studio Dark' then
202+
devEditor.HighColor := clBlack
201203
else
202204
devEditor.HighColor := $FFFFCC; // Light Turquoise
203205

Source/Project.pas

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1475,7 +1475,7 @@ procedure TProject.ExportToHTML;
14751475
sl := TStringList.Create;
14761476
try
14771477
sl.Add('<html>');
1478-
sl.Add('<head><title>Dev-C++ project: ' + Self.Name + '</title></head>');
1478+
sl.Add('<head><title>Embarcadero Dev-C++ project: ' + Self.Name + '</title></head>');
14791479
sl.Add('<body bgcolor=#FFFFFF>');
14801480
sl.Add('<h2>Project: ' + Self.Name + '</h2>');
14811481
sl.Add('<b>Index of files:</b>');
@@ -1516,7 +1516,7 @@ procedure TProject.ExportToHTML;
15161516

15171517
sl.Add('</table>');
15181518
sl.Add('<hr width="80%"/>');
1519-
sl.Add('<p align="center"><font size="1">Exported by <a href="http://www.bloodshed.net/dev">' + DEVCPP + '</a> v' +
1519+
sl.Add('<p align="center"><font size="1">Exported by <a href="https://github.com/Embarcadero/Dev-Cpp">' + DEVCPP + '</a> v' +
15201520
DEVCPP_VERSION + '</font></p>');
15211521
sl.Add('</body>');
15221522
sl.Add('</html>');

Source/Utils.pas

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ procedure FilesFromWildcard(Directory: String; const Mask: String; Files: TStrin
5050
Multitasking: Boolean);
5151

5252
function ExecuteFile(const FileName, Params, DefaultDir: String; ShowCmd: Integer): THandle;
53+
function ExecuteFileAsAdmin(const FileName, Params, DefaultDir: String; ShowCmd: Integer): THandle;
5354
function RunAndGetOutput(const Cmd, WorkDir: String; LineOutputFunc: TLineOutputFunc; CheckAbortFunc:
5455
TCheckAbortFunc; ShowReturnValue: Boolean = True): String;
5556

@@ -418,7 +419,7 @@ procedure OpenHelpFile(const HelpFileName: String);
418419
var
419420
abshelp: String;
420421
begin // TODO: fix iframe opening problem
421-
abshelp := ReplaceFirstStr(devDirs.Help, '%path%\', devDirs.Exec) + HelpFileName;
422+
abshelp := '"'+ReplaceFirstStr(devDirs.Help, '%path%\', devDirs.Exec) + HelpFileName+'"';
422423
ShellExecute(GetDesktopWindow(), 'open', PChar(abshelp), nil, nil, SW_SHOWNORMAL);
423424
end;
424425

@@ -471,6 +472,13 @@ function ExecuteFile(const FileName, Params, DefaultDir: String; ShowCmd: Intege
471472
PChar(DefaultDir), ShowCmd);
472473
end;
473474

475+
function ExecuteFileAsAdmin(const FileName, Params, DefaultDir: String; ShowCmd: Integer): THandle;
476+
begin
477+
Result := ShellExecute(Application.MainForm.Handle, 'runas',
478+
PChar(FileName), PChar(Params),
479+
PChar(DefaultDir), ShowCmd);
480+
end;
481+
474482
function RunAndGetOutput(const Cmd, WorkDir: String;
475483
LineOutputFunc: TLineOutputFunc;
476484
CheckAbortFunc: TCheckAbortFunc;

Source/Version.pas

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ interface
3232

3333
// exe properties
3434
DEVCPP = 'Embarcadero Dev-C++';
35-
DEVCPP_VERSION = '6.0';
35+
DEVCPP_VERSION = '6.1';
3636

3737
// delimiters
3838
DEV_INTERNAL_OPEN = '$__DEV_INTERNAL_OPEN';

Source/devcpp.dpr

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,10 +141,10 @@ begin
141141
else
142142
devData.INIFileName := IncludeTrailingBackslash(ParamStr(2)) + INIFileName;
143143
end else begin
144-
// default dir should be %APPDATA%\Dev-Cpp
145-
AppData := IncludeTrailingBackslash(GetHomePath);
144+
// default dir should be C:\Users\<username>\Documents\Embarcadero\Dev-Cpp
145+
AppData := IncludeTrailingBackslash(TPath.GetDocumentsPath);
146146

147-
// Store the INI file in %APPDATA% or if we are not allowed to do so, in the exe directory
147+
// Store the INI file in C:\Users\<username>\Documents or if we are not allowed to do so, in the exe directory
148148
if (not devData.IsPortable) and ((AppData <> '') and (DirectoryExists(AppData + 'Embarcadero\Dev-Cpp') or CreateDir(AppData + 'Embarcadero\Dev-Cpp'))) then
149149
devData.INIFileName := AppData + 'Embarcadero\Dev-Cpp\' + INIFileName
150150
else

Source/devcpp.dproj

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -115,9 +115,8 @@
115115
<AppEnableRuntimeThemes>true</AppEnableRuntimeThemes>
116116
<AppDPIAwarenessMode>PerMonitorV2</AppDPIAwarenessMode>
117117
<DCC_ExeOutput>C:\Dev-Cpp\</DCC_ExeOutput>
118-
<VerInfo_MinorVer>0</VerInfo_MinorVer>
119-
<VerInfo_Keys>CompanyName=Embarcadero;FileDescription=$(MSBuildProjectName);FileVersion=6.0.0.0;InternalName=Devcpp;LegalCopyright=;LegalTrademarks=;OriginalFilename=Embarcadero Devcpp;ProductName=$(MSBuildProjectName);ProductVersion=6.0.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName)</VerInfo_Keys>
120-
<DCC_UnitSearchPath>VCL\TChromeTabs;$(DCC_UnitSearchPath)</DCC_UnitSearchPath>
118+
<VerInfo_MinorVer>1</VerInfo_MinorVer>
119+
<VerInfo_Keys>CompanyName=Embarcadero;FileDescription=$(MSBuildProjectName);FileVersion=6.1.0.0;InternalName=Devcpp;LegalCopyright=;LegalTrademarks=;OriginalFilename=Embarcadero Devcpp;ProductName=$(MSBuildProjectName);ProductVersion=6.1.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName)</VerInfo_Keys>
121120
<Icon_MainIcon>..\devcpp.ico</Icon_MainIcon>
122121
<VerInfo_MajorVer>6</VerInfo_MajorVer>
123122
</PropertyGroup>

0 commit comments

Comments
 (0)