Skip to content

Commit 5f95d0f

Browse files
committed
Merge branch 'release/v5.5'
2 parents 435918f + 10d76dc commit 5f95d0f

File tree

188 files changed

+2782
-1923
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

188 files changed

+2782
-1923
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
*.suo
66
*.user
77
*.sln.docstates
8+
.vs/
89

910
# Build results
1011

install/MapWindow5.iss

Lines changed: 44 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,19 @@
77
#define ExeBinPath "..\bin\x86\Release"
88
#define SamplePath "testdata"
99
#define CPU "Win32"
10-
#define vcredist "vcredist_x86-2015.exe"
10+
#define vcredist "vcredist_x86-2017.exe"
1111
#define SystemFlag "32bit"
1212
#define MyAppName "MapWindow5"
1313
#define MyAppPublisher "MapWindow Open Source GIS Community"
1414
#define MyAppURL "https://www.mapwindow.org/documentation/mapwindow5/"
1515
#define ReleaseNotes ExeBinPath + "\..\..\..\src\SolutionItems\ReleaseNotes.rtf"
16+
#define GdalLicensePath ExeBinPath + "\..\..\..\..\..\MapWinGIS\git\support\GDAL_SDK\licenses\
1617
1718
#define x64BitVersion true
1819
1920
#ifdef x64BitVersion
2021
#define CPU "x64"
21-
#define vcredist "vcredist_x64_2015.exe"
22+
#define vcredist "vcredist_x64-2017.exe"
2223
#define ExeBinPath "..\bin\x64\Release"
2324
#define SystemFlag "64bit"
2425
#endif
@@ -93,7 +94,7 @@ Source: "{#ExeBinPath}\Projections\*"; DestDir: "{app}\Projections"; Flags: igno
9394
;; Manuals sub folder
9495
Source: "{#ExeBinPath}\Manuals\*"; DestDir: "{app}\Manuals"; Flags: ignoreversion recursesubdirs createallsubdirs {#SystemFlag}; Components: MapWindow
9596
;; Plugins subfolder
96-
Source: "{#ExeBinPath}\Plugins\*.dll"; DestDir: "{app}\Plugins"; Flags: ignoreversion {#SystemFlag}; Components: MapWindow; Excludes: "Interop.MapWinGIS.dll,MW5.TemplatePlugin.dll,Syncfusion.*"
97+
Source: "{#ExeBinPath}\Plugins\*"; DestDir: "{app}\Plugins"; Flags: ignoreversion recursesubdirs createallsubdirs {#SystemFlag}; Components: MapWindow; Excludes: "Interop.MapWinGIS.dll,MW5.TemplatePlugin.dll,Syncfusion.*"
9798
;; Styles subfolder
9899
Source: "{#ExeBinPath}\Styles\*"; DestDir: "{app}\Styles"; Flags: ignoreversion recursesubdirs createallsubdirs {#SystemFlag}; Components: MapWindow
99100
;; SQLite interop:
@@ -105,7 +106,7 @@ Source: "{#ExeBinPath}\x86\*"; DestDir: "{app}\x86"; Flags: ignoreversion {#Syst
105106
;; Config files:
106107
Source: "{#ExeBinPath}\MapWindow.exe.config"; DestDir: "{app}"; Flags: ignoreversion {#SystemFlag}; Components: MapWindow; Permissions: users-modify
107108
;; Licenses
108-
Source: "D:\dev\MapwinGIS\GitHub\support\GDAL_SDK\licenses\*.rtf"; DestDir: "{app}\Licenses"; Flags: ignoreversion; Components: MapWindow
109+
Source: "{#GdalLicensePath}\*.rtf"; DestDir: "{app}\Licenses"; Flags: ignoreversion; Components: MapWindow
109110
Source: "{#ExeBinPath}\..\..\..\licenses\*"; DestDir: "{app}\Licenses"; Flags: ignoreversion {#SystemFlag}; Components: MapWindow
110111
111112
;; Sample data
@@ -123,7 +124,7 @@ Source: "{#ReleaseNotes}"; DestDir: "{app}"; Flags: ignoreversion; Components: M
123124
BeveledLabel={#MyAppName}
124125
125126
[Run]
126-
; Install VC++ 2015 if needed:
127+
; Install VC++ 2017 if needed:
127128
#ifdef x64BitVersion
128129
Filename: "{tmp}\{#vcredist}"; Parameters: "/quiet"; Flags: waituntilterminated; Check: VCRedistNeedsInstall_x64()
129130
#else
@@ -154,6 +155,7 @@ Root: "HKCR"; Subkey: ".mwproj"; ValueType: string; ValueData: "MW5Project"; Fla
154155
Root: "HKCR"; Subkey: "MW5Project"; ValueType: string; ValueData: "MW5 Project"; Flags: uninsdeletekey
155156
Root: "HKCR"; Subkey: "MW5Project\DefaultIcon"; ValueType: string; ValueData: "{app}\MAPWINDOW.EXE,0"
156157
Root: "HKCR"; Subkey: "MW5Project\shell\open\command"; ValueType: string; ValueData: """{app}\MAPWINDOW.EXE"" ""%1"""
158+
Root: "HKCR"; Subkey: "MW5Project\"; ValueName: "InstallDir"; ValueType: string; ValueData: "{app}"
157159
158160
[InstallDelete]
159161
Type: files; Name: "{app}\Plugins\MW5.TemplatePlugin.dll"; Components: MapWindow
@@ -203,6 +205,12 @@ const
203205
VC_2015_REDIST_X86 = '{8F271F6C-6E7B-3D0A-951B-6E7B694D78BD}'; //Microsoft.VS.VC_RuntimeMinimumVSU_x86,v14
204206
VC_2015_REDIST_X64 = '{221D6DB4-46E2-333C-B09B-5F49351D0980}'; //Microsoft.VS.VC_RuntimeMinimumVSU_amd64,v14
205207
208+
209+
// https://bell0bytes.eu/inno-setup-vc/
210+
// { Visual C++ 2017 Redistributable 14.16.27024 }
211+
VC_2017_REDIST_X86 = '{5EEFCEFB-E5F7-4C82-99A5-813F04AA4FBD}';
212+
VC_2017_REDIST_X64 = '{F1B0FB3A-E0EA-47A6-9383-3650655403B0}';
213+
206214
function MsiQueryProductState(szProduct: string): INSTALLSTATE;
207215
external 'MsiQueryProductState{#AW}@msi.dll stdcall';
208216
@@ -218,7 +226,7 @@ begin
218226
// this statement, the following won't install your VC redist only when
219227
// the Visual C++ 2008 Redist (x86) and Visual C++ 2008 SP1 Redist(x86)
220228
// are installed for the current user
221-
Result := not (VCVersionInstalled(VC_2015_REDIST_X86));
229+
Result := not (VCVersionInstalled(VC_2017_REDIST_X86));
222230
end;
223231
224232
function VCRedistNeedsInstall_x64(): Boolean;
@@ -228,7 +236,7 @@ begin
228236
// this statement, the following won't install your VC redist only when
229237
// the Visual C++ 2008 Redist (x86) and Visual C++ 2008 SP1 Redist(x86)
230238
// are installed for the current user
231-
Result := not (VCVersionInstalled(VC_2015_REDIST_X64));
239+
Result := not (VCVersionInstalled(VC_2017_REDIST_X64));
232240
end;
233241
234242
function NeedsAddPath(Param: string): boolean;
@@ -368,8 +376,8 @@ end;
368376
369377
function InitializeSetup(): Boolean;
370378
begin
371-
if not IsDotNetDetected('v4.5', 0) then begin
372-
MsgBox('MapWindow5 requires Microsoft .NET Framework 4.5.'#13#13
379+
if not IsDotNetDetected('v4.6', 0) then begin
380+
MsgBox('MapWindow5 requires Microsoft .NET Framework 4.6.'#13#13
373381
'Please use Windows Update to install this version,'#13
374382
'and then re-run this setup program.', mbInformation, MB_OK);
375383
result := false;
@@ -379,51 +387,50 @@ end;
379387
380388
[Languages]
381389
Name: "english"; MessagesFile: "compiler:Default.isl"
382-
;Name: "afrikaans"; MessagesFile: "compiler:Languages\Afrikaans.isl"
383-
;Name: "albanian"; MessagesFile: "compiler:Languages\Albanian.isl"
384-
;Name: "arabic"; MessagesFile: "compiler:Languages\Arabic.isl"
385-
;Name: "basque"; MessagesFile: "compiler:Languages\Basque.isl"
386-
;Name: "belarusian"; MessagesFile: "compiler:Languages\Belarusian.isl"
387-
;Name: "bosnian"; MessagesFile: "compiler:Languages\Bosnian.isl"
390+
;;Name: "afrikaans"; MessagesFile: "compiler:Languages\Afrikaans.isl"
391+
;;Name: "albanian"; MessagesFile: "compiler:Languages\Albanian.isl"
392+
;;Name: "arabic"; MessagesFile: "compiler:Languages\Arabic.isl"
393+
;;Name: "basque"; MessagesFile: "compiler:Languages\Basque.isl"
394+
;;Name: "belarusian"; MessagesFile: "compiler:Languages\Belarusian.isl"
395+
;;Name: "bosnian"; MessagesFile: "compiler:Languages\Bosnian.isl"
388396
Name: "brazilianportuguese"; MessagesFile: "compiler:Languages\BrazilianPortuguese.isl"
389-
;Name: "bulgarian"; MessagesFile: "compiler:Languages\Bulgarian.isl"
397+
;;Name: "bulgarian"; MessagesFile: "compiler:Languages\Bulgarian.isl"
390398
Name: "catalan"; MessagesFile: "compiler:Languages\Catalan.isl"
391-
;Name: "chinesesimp"; MessagesFile: "compiler:Languages\ChineseSimplified.isl"
392-
;Name: "chinesetrad"; MessagesFile: "compiler:Languages\ChineseTraditional.isl"
399+
;;Name: "chinesesimp"; MessagesFile: "compiler:Languages\ChineseSimplified.isl"
400+
;;Name: "chinesetrad"; MessagesFile: "compiler:Languages\ChineseTraditional.isl"
393401
Name: "corsican"; MessagesFile: "compiler:Languages\Corsican.isl"
394402
Name: "czech"; MessagesFile: "compiler:Languages\Czech.isl"
395403
Name: "danish"; MessagesFile: "compiler:Languages\Danish.isl"
396404
Name: "dutch"; MessagesFile: "compiler:Languages\Dutch.isl"
397-
;Name: "estonian"; MessagesFile: "compiler:Languages\Estonian.isl"
405+
;;Name: "estonian"; MessagesFile: "compiler:Languages\Estonian.isl"
398406
Name: "finnish"; MessagesFile: "compiler:Languages\Finnish.isl"
399407
Name: "french"; MessagesFile: "compiler:Languages\French.isl"
400-
;Name: "galician"; MessagesFile: "compiler:Languages\Galician.isl"
408+
;;Name: "galician"; MessagesFile: "compiler:Languages\Galician.isl"
401409
Name: "german"; MessagesFile: "compiler:Languages\German.isl"
402-
Name: "greek"; MessagesFile: "compiler:Languages\Greek.isl"
410+
;;Name: "greek"; MessagesFile: "compiler:Languages\Greek.isl"
403411
Name: "hebrew"; MessagesFile: "compiler:Languages\Hebrew.isl"
404-
Name: "hungarian"; MessagesFile: "compiler:Languages\Hungarian.isl"
405-
;Name: "icelandic"; MessagesFile: "compiler:Languages\Icelandic.isl"
406-
;Name: "indonesian"; MessagesFile: "compiler:Languages\Indonesian.isl"
412+
;;Name: "hungarian"; MessagesFile: "compiler:Languages\Hungarian.isl"
413+
Name: "icelandic"; MessagesFile: "compiler:Languages\Icelandic.isl"
414+
;;Name: "indonesian"; MessagesFile: "compiler:Languages\Indonesian.isl"
407415
Name: "italian"; MessagesFile: "compiler:Languages\Italian.isl"
408416
Name: "japanese"; MessagesFile: "compiler:Languages\Japanese.isl"
409-
;Name: "korean"; MessagesFile: "compiler:Languages\Korean.isl"
410-
;Name: "lithuanian"; MessagesFile: "compiler:Languages\Lithuanian.isl"
411-
;Name: "luxemburgish"; MessagesFile: "compiler:Languages\Luxemburgish.isl"
412-
;Name: "macedonian"; MessagesFile: "compiler:Languages\Macedonian.isl"
413-
;Name: "malaysian"; MessagesFile: "compiler:Languages\Malaysian.isl"
414-
;Name: "nepali"; MessagesFile: "compiler:Languages\Nepali.islu"
417+
;;Name: "korean"; MessagesFile: "compiler:Languages\Korean.isl"
418+
;;Name: "lithuanian"; MessagesFile: "compiler:Languages\Lithuanian.isl"
419+
;;Name: "luxemburgish"; MessagesFile: "compiler:Languages\Luxemburgish.isl"
420+
;;Name: "macedonian"; MessagesFile: "compiler:Languages\Macedonian.isl"
421+
;;Name: "malaysian"; MessagesFile: "compiler:Languages\Malaysian.isl"
422+
;;Name: "nepali"; MessagesFile: "compiler:Languages\Nepali.islu"
415423
Name: "norwegian"; MessagesFile: "compiler:Languages\Norwegian.isl"
416424
Name: "polish"; MessagesFile: "compiler:Languages\Polish.isl"
417425
Name: "portuguese"; MessagesFile: "compiler:Languages\Portuguese.isl"
418-
;Name: "romanian"; MessagesFile: "compiler:Languages\Romanian.isl"
426+
;;Name: "romanian"; MessagesFile: "compiler:Languages\Romanian.isl"
419427
Name: "russian"; MessagesFile: "compiler:Languages\Russian.isl"
420-
Name: "serbiancyrillic"; MessagesFile: "compiler:Languages\SerbianCyrillic.isl"
421-
Name: "serbianlatin"; MessagesFile: "compiler:Languages\SerbianLatin.isl"
422-
;Name: "slovak"; MessagesFile: "compiler:Languages\Slovak.isl"
428+
;;Name: "serbiancyrillic"; MessagesFile: "compiler:Languages\SerbianCyrillic.isl"
429+
;;Name: "serbianlatin"; MessagesFile: "compiler:Languages\SerbianLatin.isl"
430+
;;Name: "slovak"; MessagesFile: "compiler:Languages\Slovak.isl"
423431
Name: "slovenian"; MessagesFile: "compiler:Languages\Slovenian.isl"
424432
Name: "spanish"; MessagesFile: "compiler:Languages\Spanish.isl"
425-
;Name: "swedish"; MessagesFile: "compiler:Languages\Swedish.isl"
426-
;Name: "tatarish"; MessagesFile: "compiler:Languages\Tatar.isl"
433+
;;Name: "swedish"; MessagesFile: "compiler:Languages\Swedish.isl"
434+
;;Name: "tatarish"; MessagesFile: "compiler:Languages\Tatar.isl"
427435
Name: "turkish"; MessagesFile: "compiler:Languages\Turkish.isl"
428436
Name: "ukrainian"; MessagesFile: "compiler:Languages\Ukrainian.isl"
429-

src/.nuget/NuGet.Config

Lines changed: 0 additions & 6 deletions
This file was deleted.

src/.nuget/NuGet.targets

Lines changed: 0 additions & 144 deletions
This file was deleted.

src/MW5.Api/Concrete/CompositeLine.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,13 +126,15 @@ IEnumerator IEnumerable.GetEnumerator()
126126

127127
public bool Draw(IntPtr hdc, float x, float y, int clipWidth, int clipHeight, Color? backColor = null)
128128
{
129-
return _pattern.Draw(hdc, x, y, clipWidth, clipHeight, backColor.ToUInt());
129+
var hdcInt = hdc.ToInt32();
130+
return _pattern.Draw(hdcInt, x, y, clipWidth, clipHeight, backColor.ToUInt());
130131
}
131132

132133
public bool Draw(Graphics g, float x, float y, int clipWidth, int clipHeight, Color? backColor = null)
133134
{
134135
var hdc = g.GetHdc();
135-
bool result = _pattern.Draw(hdc, x, y, clipWidth, clipHeight, backColor.ToUInt());
136+
var hdcInt = hdc.ToInt32();
137+
var result = _pattern.Draw(hdcInt, x, y, clipWidth, clipHeight, backColor.ToUInt());
136138
g.ReleaseHdc(hdc);
137139
return result;
138140
}

src/MW5.Api/Concrete/DiagramsLayer.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -324,13 +324,15 @@ public PersistenceType SavingMode
324324

325325
public bool DrawChart(IntPtr hdc, float x, float y, bool hideLabels, Color? backColor)
326326
{
327-
return _charts.DrawChart(hdc, x, y, hideLabels, backColor.ToUInt());
327+
var hdcInt = hdc.ToInt32();
328+
return _charts.DrawChart(hdcInt, x, y, hideLabels, backColor.ToUInt());
328329
}
329330

330331
public bool DrawChart(Graphics g, float x, float y, bool hideLabels, Color? backColor)
331332
{
332333
var hdc = g.GetHdc();
333-
bool result = _charts.DrawChart(hdc, x, y, hideLabels, backColor.ToUInt());
334+
var hdcInt = hdc.ToInt32();
335+
var result = _charts.DrawChart(hdcInt, x, y, hideLabels, backColor.ToUInt());
334336
g.ReleaseHdc(hdc);
335337
return result;
336338
}

src/MW5.Api/Concrete/Feature.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,11 @@ public int Index
6767
get { return _shapeIndex; }
6868
}
6969

70+
public bool IsPartOfSet(IFeatureSet set)
71+
{
72+
return set?.InternalObject == InternalShapefile;
73+
}
74+
7075
public IGeometry Geometry
7176
{
7277
get

0 commit comments

Comments
 (0)