├── .gitignore ├── .vscode └── settings.json ├── CHANGELOG.md ├── FAQ.md ├── LICENSE ├── README.md ├── TroubleShooting.md ├── VSCodeConfigHelper.sln ├── VSCodeConfigHelper ├── App.config ├── FodyWeavers.xml ├── FodyWeavers.xsd ├── Form1.Designer.cs ├── Form1.cs ├── Form1.resx ├── FormSettings.Designer.cs ├── FormSettings.cs ├── FormSettings.resx ├── Logging.cs ├── MinGWLink.cs ├── Program.cs ├── Properties │ ├── AssemblyInfo.cs │ ├── Resources.Designer.cs │ ├── Resources.resx │ ├── Settings.Designer.cs │ ├── Settings.settings │ └── app.manifest ├── VSCodeConfigHelper.csproj ├── VSCodeConfigHelper.ico └── packages.config ├── VS_Code_in_Linux.md ├── VS_Code_in_Mac.md ├── docs ├── CNAME ├── assets │ ├── Snapshot.png │ ├── VSCodeConfigHelper.png │ ├── external.png │ └── internal.png ├── favicon.ico ├── index.html ├── index.js └── version.json ├── package.sh └── publish.sh /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | # User-specific files 7 | *.suo 8 | *.user 9 | *.userosscache 10 | *.sln.docstates 11 | 12 | # User-specific files (MonoDevelop/Xamarin Studio) 13 | *.userprefs 14 | 15 | # Build results 16 | [Dd]ebug/ 17 | [Dd]ebugPublic/ 18 | [Rr]elease/ 19 | [Rr]eleases/ 20 | x64/ 21 | x86/ 22 | bld/ 23 | [Bb]in/ 24 | [Oo]bj/ 25 | [Ll]og/ 26 | 27 | # Visual Studio 2015/2017 cache/options directory 28 | .vs/ 29 | # Uncomment if you have tasks that create the project's static files in wwwroot 30 | #wwwroot/ 31 | 32 | # Visual Studio 2017 auto generated files 33 | Generated\ Files/ 34 | 35 | # MSTest test Results 36 | [Tt]est[Rr]esult*/ 37 | [Bb]uild[Ll]og.* 38 | 39 | # NUNIT 40 | *.VisualState.xml 41 | TestResult.xml 42 | 43 | # Build Results of an ATL Project 44 | [Dd]ebugPS/ 45 | [Rr]eleasePS/ 46 | dlldata.c 47 | 48 | # Benchmark Results 49 | BenchmarkDotNet.Artifacts/ 50 | 51 | # .NET Core 52 | project.lock.json 53 | project.fragment.lock.json 54 | artifacts/ 55 | 56 | # StyleCop 57 | StyleCopReport.xml 58 | 59 | # Files built by Visual Studio 60 | *_i.c 61 | *_p.c 62 | *_i.h 63 | *.ilk 64 | *.meta 65 | *.obj 66 | *.iobj 67 | *.pch 68 | *.pdb 69 | *.ipdb 70 | *.pgc 71 | *.pgd 72 | *.rsp 73 | *.sbr 74 | *.tlb 75 | *.tli 76 | *.tlh 77 | *.tmp 78 | *.tmp_proj 79 | *.log 80 | *.vspscc 81 | *.vssscc 82 | .builds 83 | *.pidb 84 | *.svclog 85 | *.scc 86 | 87 | # Chutzpah Test files 88 | _Chutzpah* 89 | 90 | # Visual C++ cache files 91 | ipch/ 92 | *.aps 93 | *.ncb 94 | *.opendb 95 | *.opensdf 96 | *.sdf 97 | *.cachefile 98 | *.VC.db 99 | *.VC.VC.opendb 100 | 101 | # Visual Studio profiler 102 | *.psess 103 | *.vsp 104 | *.vspx 105 | *.sap 106 | 107 | # Visual Studio Trace Files 108 | *.e2e 109 | 110 | # TFS 2012 Local Workspace 111 | $tf/ 112 | 113 | # Guidance Automation Toolkit 114 | *.gpState 115 | 116 | # ReSharper is a .NET coding add-in 117 | _ReSharper*/ 118 | *.[Rr]e[Ss]harper 119 | *.DotSettings.user 120 | 121 | # JustCode is a .NET coding add-in 122 | .JustCode 123 | 124 | # TeamCity is a build add-in 125 | _TeamCity* 126 | 127 | # DotCover is a Code Coverage Tool 128 | *.dotCover 129 | 130 | # AxoCover is a Code Coverage Tool 131 | .axoCover/* 132 | !.axoCover/settings.json 133 | 134 | # Visual Studio code coverage results 135 | *.coverage 136 | *.coveragexml 137 | 138 | # NCrunch 139 | _NCrunch_* 140 | .*crunch*.local.xml 141 | nCrunchTemp_* 142 | 143 | # MightyMoose 144 | *.mm.* 145 | AutoTest.Net/ 146 | 147 | # Web workbench (sass) 148 | .sass-cache/ 149 | 150 | # Installshield output folder 151 | [Ee]xpress/ 152 | 153 | # DocProject is a documentation generator add-in 154 | DocProject/buildhelp/ 155 | DocProject/Help/*.HxT 156 | DocProject/Help/*.HxC 157 | DocProject/Help/*.hhc 158 | DocProject/Help/*.hhk 159 | DocProject/Help/*.hhp 160 | DocProject/Help/Html2 161 | DocProject/Help/html 162 | 163 | # Click-Once directory 164 | publish/ 165 | 166 | # Publish Web Output 167 | *.[Pp]ublish.xml 168 | *.azurePubxml 169 | # Note: Comment the next line if you want to checkin your web deploy settings, 170 | # but database connection strings (with potential passwords) will be unencrypted 171 | *.pubxml 172 | *.publishproj 173 | 174 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 175 | # checkin your Azure Web App publish settings, but sensitive information contained 176 | # in these scripts will be unencrypted 177 | PublishScripts/ 178 | 179 | # NuGet Packages 180 | *.nupkg 181 | # The packages folder can be ignored because of Package Restore 182 | **/[Pp]ackages/* 183 | # except build/, which is used as an MSBuild target. 184 | !**/[Pp]ackages/build/ 185 | # Uncomment if necessary however generally it will be regenerated when needed 186 | #!**/[Pp]ackages/repositories.config 187 | # NuGet v3's project.json files produces more ignorable files 188 | *.nuget.props 189 | *.nuget.targets 190 | 191 | # Microsoft Azure Build Output 192 | csx/ 193 | *.build.csdef 194 | 195 | # Microsoft Azure Emulator 196 | ecf/ 197 | rcf/ 198 | 199 | # Windows Store app package directories and files 200 | AppPackages/ 201 | BundleArtifacts/ 202 | Package.StoreAssociation.xml 203 | _pkginfo.txt 204 | *.appx 205 | 206 | # Visual Studio cache files 207 | # files ending in .cache can be ignored 208 | *.[Cc]ache 209 | # but keep track of directories ending in .cache 210 | !*.[Cc]ache/ 211 | 212 | # Others 213 | ClientBin/ 214 | ~$* 215 | *~ 216 | *.dbmdl 217 | *.dbproj.schemaview 218 | *.jfm 219 | *.pfx 220 | *.publishsettings 221 | orleans.codegen.cs 222 | 223 | # Including strong name files can present a security risk 224 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 225 | #*.snk 226 | 227 | # Since there are multiple workflows, uncomment next line to ignore bower_components 228 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 229 | #bower_components/ 230 | 231 | # RIA/Silverlight projects 232 | Generated_Code/ 233 | 234 | # Backup & report files from converting an old project file 235 | # to a newer Visual Studio version. Backup files are not needed, 236 | # because we have git ;-) 237 | _UpgradeReport_Files/ 238 | Backup*/ 239 | UpgradeLog*.XML 240 | UpgradeLog*.htm 241 | ServiceFabricBackup/ 242 | *.rptproj.bak 243 | 244 | # SQL Server files 245 | *.mdf 246 | *.ldf 247 | *.ndf 248 | 249 | # Business Intelligence projects 250 | *.rdl.data 251 | *.bim.layout 252 | *.bim_*.settings 253 | *.rptproj.rsuser 254 | 255 | # Microsoft Fakes 256 | FakesAssemblies/ 257 | 258 | # GhostDoc plugin setting file 259 | *.GhostDoc.xml 260 | 261 | # Node.js Tools for Visual Studio 262 | .ntvs_analysis.dat 263 | node_modules/ 264 | 265 | # Visual Studio 6 build log 266 | *.plg 267 | 268 | # Visual Studio 6 workspace options file 269 | *.opt 270 | 271 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 272 | *.vbw 273 | 274 | # Visual Studio LightSwitch build output 275 | **/*.HTMLClient/GeneratedArtifacts 276 | **/*.DesktopClient/GeneratedArtifacts 277 | **/*.DesktopClient/ModelManifest.xml 278 | **/*.Server/GeneratedArtifacts 279 | **/*.Server/ModelManifest.xml 280 | _Pvt_Extensions 281 | 282 | # Paket dependency manager 283 | .paket/paket.exe 284 | paket-files/ 285 | 286 | # FAKE - F# Make 287 | .fake/ 288 | 289 | # JetBrains Rider 290 | .idea/ 291 | *.sln.iml 292 | 293 | # CodeRush 294 | .cr/ 295 | 296 | # Python Tools for Visual Studio (PTVS) 297 | __pycache__/ 298 | *.pyc 299 | 300 | # Cake - Uncomment if you are using it 301 | # tools/** 302 | # !tools/packages.config 303 | 304 | # Tabs Studio 305 | *.tss 306 | 307 | # Telerik's JustMock configuration file 308 | *.jmconfig 309 | 310 | # BizTalk build output 311 | *.btp.cs 312 | *.btm.cs 313 | *.odx.cs 314 | *.xsd.cs 315 | 316 | # OpenCover UI analysis results 317 | OpenCover/ 318 | 319 | # Azure Stream Analytics local run output 320 | ASALocalRun/ 321 | 322 | # MSBuild Binary and Structured Log 323 | *.binlog 324 | 325 | # NVidia Nsight GPU debugger configuration file 326 | *.nvuser 327 | 328 | # MFractors (Xamarin productivity tool) working folder 329 | .mfractor/ 330 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "liveServer.settings.port": 5501 3 | } -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # 版本更新记录 2 | 3 | ## [3.x](https://github.com/Guyutongxue/VSCodeConfigHelper3/blob/main/CHANGELOG.md) 4 | 5 | ## 2.2.14 6 | 7 | *2021.9.10* 8 | 9 | - 更新默认 MinGW 到 GCC 11.2.0 10 | - 检查更新或首次运行时提示更新到 v3 11 | 12 | ## 2.2.13 13 | 14 | *2021.4.30* 15 | 16 | - 更新默认 MinGW 到 GCC 11.1.0 17 | 18 | ### 2.2.13.1 19 | 20 | *2021.5.15* 21 | 22 | - 紧急修复蓝奏云域名解析错误的问题 23 | 24 | ## 2.2.12 25 | 26 | *2021.4.10* 27 | 28 | - 更新默认 MinGW 到 GCC 10.3.0 29 | - 修复错误的 MinGW 路径潜在问题提示 30 | 31 | ## 2.2.11 32 | 33 | *2021.3.6* 34 | 35 | - 修复环境变量未应用导致的“退出代码1”错误([#9](https://github.com/Guyutongxue/VSCodeConfigHelper/issues/9)) 36 | - 当由于未知原因无法获取编译器版本时不再导致程序停止工作([#12](https://github.com/Guyutongxue/VSCodeConfigHelper/issues/12)) 37 | 38 | ## 2.2.10 39 | 40 | *2021.1.5* 41 | 42 | - 尝试修复可能需要重启才能成功编译的问题([#7](https://github.com/Guyutongxue/VSCodeConfigHelper/issues/7)) 43 | 44 | ### 2.2.10.1 45 | 46 | *2021.1.6* 47 | 48 | - 尽量避免 MinGW 路径中空格带来的潜在问题([#8](https://github.com/Guyutongxue/VSCodeConfigHelper/issues/8)) 49 | 50 | ## 2.2.9 51 | 52 | *2020.11.30* 53 | 54 | - 配置成功后不再移除缓存文件([#6](https://github.com/Guyutongxue/VSCodeConfigHelper/issues/6)) 55 | - 尝试修复许多 Win7 用户 `cmd.exe` 不在环境变量 `Path` 内导致的错误 56 | 57 | ## 2.2.8 58 | 59 | *2020.10.10* 60 | 61 | - 再次修复 [#5](https://github.com/Guyutongxue/VSCodeConfigHelper/issues/5) 62 | 63 | ## 2.2.7 64 | 65 | *2020.9.20* 66 | 67 | - 尝试修复 [#5](https://github.com/Guyutongxue/VSCodeConfigHelper/issues/5) 68 | - 限制 MinGW 路径不含中文 69 | 70 | ## 2.2.6 71 | 72 | *2020.9.6* 73 | 74 | - 更新默认 MinGW 到谷雨同学个人搭建版本 75 | 76 | ## 2.2.5 77 | 78 | *2020.8.21* 79 | 80 | - 更新 WinLibs GCC 到 10.2.0。(现在可以用中文变量名了!) 81 | - 增加发送统计数据 82 | 83 | ### 2.2.5.1 84 | 85 | - 修复拼写错误 86 | 87 | ## 2.2.4 88 | 89 | *2020.6.17* 90 | 91 | - 增加了用户手动设置(非安装的)VS Code 路径选项(需按 Shift + 刷新) 92 | - 修复了安装扩展完成后意外抛出异常的错误 93 | 94 | ## 2.2.3 95 | 96 | *2020.6.15* 97 | 98 | - 调整了 JSON 文件的选项,使编译、运行的显示更加简洁 99 | 100 | ## 2.2.2 101 | 102 | *2020.6.2* 103 | 104 | - 完善了异常捕获机制。如有问题请将 `VSCH.log` 文件以附件形式发送至开发者邮箱。 105 | 106 | ## 2.2.1 107 | 108 | *2020.5.26* 109 | 110 | - 调整一些细节,现在再次配置可以直接一路下一步了。 111 | 112 | (这个版本主要测试自动部署功能是否完善。) 113 | 114 | ## 2.2.0 115 | 116 | *2020.5.15* 117 | 118 | - 更新了 WinLibs,现在支持配置 C++20 了 119 | - 恢复了 1.x 时配置 C 语言的选项 120 | - 可以更换标准版本了 121 | - 可以保存未配置完的设置了 122 | - 增加了检测更新机制 123 | 124 | ## 2.1.1 125 | 126 | *2020.5.9* 127 | 128 | - 增加了程序日志 129 | 130 | ## 2.1.0 131 | 132 | *2020.4.19* 133 | 134 | - 增加了另外两个 MinGW 发行版 135 | - 此版本不小心重置了北大网盘链接 136 | 137 | ## 2.0.1 138 | 139 | *2020.4.16* 140 | 141 | - 修复某 UI bug 142 | - 增加了“添加桌面快捷方式”的选项,用于对付小白 143 | 144 | ## 2.0.0 145 | 146 | *2020.4.16* 147 | 148 | - 重新设计了界面 149 | - 调整了配置顺序 150 | - 增加对 PATH 中多个编译环境的管理 151 | - 增加了对 VSCode 版本的检测 152 | - 全自动安装扩展 153 | - 增加了外部终端的设置(实验性) 154 | 155 | ## 1.1.2 156 | 157 | *2020.4.2* 158 | 159 | - 优化启动 VS Code 的功能,成功率增加 160 | - 增加配置纯 C 语言的选项 161 | - 避免默认重复生成测试代码 162 | 163 | ## 1.1.1 164 | 165 | *2020.1.18* 166 | 167 | - 分离创建测试代码并启动 VS Code 的选项 168 | - 当配置不成功时,增加缓存以便下次运行 169 | 170 | ## 1.1.0 171 | 172 | *2020.1.18* 173 | 174 | - 增加创建测试代码并启动 VS Code 的选项 175 | - 取消管理员权限要求 176 | - 将 VS Code 下载地址改为直链 177 | - 对于不同的权限,设置不同的变量,下载不同的安装包 178 | - 修复不能将括号、引号、&等符号作为文件名的 bug 179 | 180 | ## 1.0.0-beta5 181 | 182 | *2020.1.14* 183 | 184 | - 增加程序强名称签名 185 | - 增加高分屏感知,禁用自动缩放 186 | - 加入了选择 MinGW 下载源、配置编译参数两项设置 187 | - 删除 Fody 组件 188 | - 更改描述说明 189 | - 更改框架版本至 .NET Framework 4.5 (因为 VS Code 调试插件最低要求为此) 190 | 191 | ## 1.0.0-beta4 192 | 193 | *2020.1.7* 194 | 195 | - 增加禁止非 ASCII 字符的提示 196 | 197 | ## 1.0.0-beta3 198 | 199 | *2020.1.2* 200 | 201 | - 优化文字提示 202 | 203 | ## 1.0.0-beta2 204 | 205 | *2020.1.1* 206 | 207 | - 加入使用方法链接 208 | 209 | ## 1.0.0-beta1 210 | 211 | *2020.1.1* 212 | 213 | - Initial Release 214 | -------------------------------------------------------------------------------- /FAQ.md: -------------------------------------------------------------------------------- 1 | # FAQ 2 | 3 | **此页面是关于一些工具使用和原理方面问题的解答。如果您在配置后未能理想地编译、运行,调试,请您浏览 [疑难解答](TroubleShooting.md) 获取帮助。** 4 | 5 | ## 为什么要选择工作文件夹? 6 | 7 | VS Code 的核心理念和 Visual Studio 类似也是基于“项目”这一基本单位的。在 VS Code 中,项目的表现形式就是文件夹。您的一切编译、运行配置都只适用于这个文件夹内部,这样您可以针对不同的语言、不同的用途进行个性化的配置。 8 | 9 | **因此当您需要对另外一个文件夹配置时**,您可以选择重新在新文件夹下运行此工具,或者将 `.vscode` 文件夹复制到新的路径下。有关 `.vscode` 文件夹的更多信息请参阅 [最后的配置都做了什么?](#最后的配置都做了什么?) 章节。 10 | 11 | ## 什么是 MinGW-w64 ? 不同版本之间有什么区别? 12 | 13 | MinGW (Minimalist GNU for Windows),是一个适用于Windows 应用程序的极简开发环境,提供了一个完整的开源编程工具集,Mingw-w64 则是 MinGW 的“升级版” ,提供了对 64 位计算机的支持。本工具同时兼容 [Cygwin](http://www.cygwin.com/) 等开发环境。 14 | 15 | 基于 MinGW-w64,有许多个人开发者或者团队在其上进行了改进和更新。其中最有影响力的一支为 [TDM-GCC](http://tdm-gcc.tdragon.net/)。它通常集成了更新的稳定版本的 GCC 编译器,同时囊括了 MinGW-w64 的一些实用补丁和运行时 API。同时,TDM-GCC 也提供特别针对 32 位系统的编译环境。 16 | 17 | [WinLibs](http://winlibs.com) 是个人开发者 Brecht Sanders 基于 MinGW-w64 和 LLVM 的一套 Windows 下编译套件。它是目前更新最快、功能最全的编译环境,因此本工具也提供了其下载链接。但是由于快速迭代和更新,编译环境存在不稳定的成分。 18 | 19 | ## 下载下来的 MinGW-w64 文件打不开,怎么办? 20 | 21 | 您刚刚所下载的文件是 7-Zip 格式,一种效率较高的压缩文件。您可以通过任何主流的解压缩工具(如 WinRAR、Bandizip 等)解压,也可以使用专门的 [7-Zip 工具](https://www.7-zip.org/) 解压。 22 | 23 | ## “安装扩展”是在做什么? 24 | 25 | VS Code 本身仅仅是一个文本编辑器,正是由于它强大的扩展生态,才能让它实现程序的编译、运行和调试。这里安装的扩展是微软官方制作的 C/C++ 插件,提供了简洁易用的调试和 IntelliSense 智能提示功能。 26 | 27 | ## 最后的配置都做了什么? 28 | 29 | 当 VS Code 打开工作文件夹时,会读取 `.vscode` 子文件夹内部的数个 JSON 文件作为配置信息。这些 JSON 文件将通过固定的格式指示 VS Code 如何调用编译器,如何调试,并提供运行路径等必要的信息。本工具所做的就是通过您输入的 MinGW 路径自动配置好上述 JSON 文件。这些 JSON 文件分别是: 30 | 31 | - `launch.json` 提供调试程序所需的信息,包括调试目标、调试器路径等; 32 | - `tasks.json` 定义了生成任务,即编译过程,包括编译参数、编译器路径等; 33 | - `settings.json` 定义了工作文件夹的设置,包括 C/C++ 插件的一些设置。 34 | 35 | 有些时候你会见到叫做 `c_cpp_properties.json` 的文件,它会存放关于 C/C++ 插件的一些特别设置。本工具没有配置这个 JSON 文件,相关的设置会通过读取 `settings.json` 来实现。 36 | 37 | ## 为什么工作文件夹不支持中文? 38 | 39 | 由于 MinGW 中 gdb 调试器并不支持 Unicode 编码的路径参数,详情可见[此处](https://github.com/Microsoft/vscode-cpptools/issues/1998)的讨论。对此我感到十分抱歉,还请您尝试其它命名,谢谢。 40 | 41 | ## -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 2, June 1991 3 | 4 | Copyright (C) 1989, 1991 Free Software Foundation, Inc., 5 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 6 | Everyone is permitted to copy and distribute verbatim copies 7 | of this license document, but changing it is not allowed. 8 | 9 | Preamble 10 | 11 | The licenses for most software are designed to take away your 12 | freedom to share and change it. By contrast, the GNU General Public 13 | License is intended to guarantee your freedom to share and change free 14 | software--to make sure the software is free for all its users. This 15 | General Public License applies to most of the Free Software 16 | Foundation's software and to any other program whose authors commit to 17 | using it. (Some other Free Software Foundation software is covered by 18 | the GNU Lesser General Public License instead.) You can apply it to 19 | your programs, too. 20 | 21 | When we speak of free software, we are referring to freedom, not 22 | price. Our General Public Licenses are designed to make sure that you 23 | have the freedom to distribute copies of free software (and charge for 24 | this service if you wish), that you receive source code or can get it 25 | if you want it, that you can change the software or use pieces of it 26 | in new free programs; and that you know you can do these things. 27 | 28 | To protect your rights, we need to make restrictions that forbid 29 | anyone to deny you these rights or to ask you to surrender the rights. 30 | These restrictions translate to certain responsibilities for you if you 31 | distribute copies of the software, or if you modify it. 32 | 33 | For example, if you distribute copies of such a program, whether 34 | gratis or for a fee, you must give the recipients all the rights that 35 | you have. You must make sure that they, too, receive or can get the 36 | source code. And you must show them these terms so they know their 37 | rights. 38 | 39 | We protect your rights with two steps: (1) copyright the software, and 40 | (2) offer you this license which gives you legal permission to copy, 41 | distribute and/or modify the software. 42 | 43 | Also, for each author's protection and ours, we want to make certain 44 | that everyone understands that there is no warranty for this free 45 | software. If the software is modified by someone else and passed on, we 46 | want its recipients to know that what they have is not the original, so 47 | that any problems introduced by others will not reflect on the original 48 | authors' reputations. 49 | 50 | Finally, any free program is threatened constantly by software 51 | patents. We wish to avoid the danger that redistributors of a free 52 | program will individually obtain patent licenses, in effect making the 53 | program proprietary. To prevent this, we have made it clear that any 54 | patent must be licensed for everyone's free use or not licensed at all. 55 | 56 | The precise terms and conditions for copying, distribution and 57 | modification follow. 58 | 59 | GNU GENERAL PUBLIC LICENSE 60 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 61 | 62 | 0. This License applies to any program or other work which contains 63 | a notice placed by the copyright holder saying it may be distributed 64 | under the terms of this General Public License. The "Program", below, 65 | refers to any such program or work, and a "work based on the Program" 66 | means either the Program or any derivative work under copyright law: 67 | that is to say, a work containing the Program or a portion of it, 68 | either verbatim or with modifications and/or translated into another 69 | language. (Hereinafter, translation is included without limitation in 70 | the term "modification".) Each licensee is addressed as "you". 71 | 72 | Activities other than copying, distribution and modification are not 73 | covered by this License; they are outside its scope. The act of 74 | running the Program is not restricted, and the output from the Program 75 | is covered only if its contents constitute a work based on the 76 | Program (independent of having been made by running the Program). 77 | Whether that is true depends on what the Program does. 78 | 79 | 1. You may copy and distribute verbatim copies of the Program's 80 | source code as you receive it, in any medium, provided that you 81 | conspicuously and appropriately publish on each copy an appropriate 82 | copyright notice and disclaimer of warranty; keep intact all the 83 | notices that refer to this License and to the absence of any warranty; 84 | and give any other recipients of the Program a copy of this License 85 | along with the Program. 86 | 87 | You may charge a fee for the physical act of transferring a copy, and 88 | you may at your option offer warranty protection in exchange for a fee. 89 | 90 | 2. You may modify your copy or copies of the Program or any portion 91 | of it, thus forming a work based on the Program, and copy and 92 | distribute such modifications or work under the terms of Section 1 93 | above, provided that you also meet all of these conditions: 94 | 95 | a) You must cause the modified files to carry prominent notices 96 | stating that you changed the files and the date of any change. 97 | 98 | b) You must cause any work that you distribute or publish, that in 99 | whole or in part contains or is derived from the Program or any 100 | part thereof, to be licensed as a whole at no charge to all third 101 | parties under the terms of this License. 102 | 103 | c) If the modified program normally reads commands interactively 104 | when run, you must cause it, when started running for such 105 | interactive use in the most ordinary way, to print or display an 106 | announcement including an appropriate copyright notice and a 107 | notice that there is no warranty (or else, saying that you provide 108 | a warranty) and that users may redistribute the program under 109 | these conditions, and telling the user how to view a copy of this 110 | License. (Exception: if the Program itself is interactive but 111 | does not normally print such an announcement, your work based on 112 | the Program is not required to print an announcement.) 113 | 114 | These requirements apply to the modified work as a whole. If 115 | identifiable sections of that work are not derived from the Program, 116 | and can be reasonably considered independent and separate works in 117 | themselves, then this License, and its terms, do not apply to those 118 | sections when you distribute them as separate works. But when you 119 | distribute the same sections as part of a whole which is a work based 120 | on the Program, the distribution of the whole must be on the terms of 121 | this License, whose permissions for other licensees extend to the 122 | entire whole, and thus to each and every part regardless of who wrote it. 123 | 124 | Thus, it is not the intent of this section to claim rights or contest 125 | your rights to work written entirely by you; rather, the intent is to 126 | exercise the right to control the distribution of derivative or 127 | collective works based on the Program. 128 | 129 | In addition, mere aggregation of another work not based on the Program 130 | with the Program (or with a work based on the Program) on a volume of 131 | a storage or distribution medium does not bring the other work under 132 | the scope of this License. 133 | 134 | 3. You may copy and distribute the Program (or a work based on it, 135 | under Section 2) in object code or executable form under the terms of 136 | Sections 1 and 2 above provided that you also do one of the following: 137 | 138 | a) Accompany it with the complete corresponding machine-readable 139 | source code, which must be distributed under the terms of Sections 140 | 1 and 2 above on a medium customarily used for software interchange; or, 141 | 142 | b) Accompany it with a written offer, valid for at least three 143 | years, to give any third party, for a charge no more than your 144 | cost of physically performing source distribution, a complete 145 | machine-readable copy of the corresponding source code, to be 146 | distributed under the terms of Sections 1 and 2 above on a medium 147 | customarily used for software interchange; or, 148 | 149 | c) Accompany it with the information you received as to the offer 150 | to distribute corresponding source code. (This alternative is 151 | allowed only for noncommercial distribution and only if you 152 | received the program in object code or executable form with such 153 | an offer, in accord with Subsection b above.) 154 | 155 | The source code for a work means the preferred form of the work for 156 | making modifications to it. For an executable work, complete source 157 | code means all the source code for all modules it contains, plus any 158 | associated interface definition files, plus the scripts used to 159 | control compilation and installation of the executable. However, as a 160 | special exception, the source code distributed need not include 161 | anything that is normally distributed (in either source or binary 162 | form) with the major components (compiler, kernel, and so on) of the 163 | operating system on which the executable runs, unless that component 164 | itself accompanies the executable. 165 | 166 | If distribution of executable or object code is made by offering 167 | access to copy from a designated place, then offering equivalent 168 | access to copy the source code from the same place counts as 169 | distribution of the source code, even though third parties are not 170 | compelled to copy the source along with the object code. 171 | 172 | 4. You may not copy, modify, sublicense, or distribute the Program 173 | except as expressly provided under this License. Any attempt 174 | otherwise to copy, modify, sublicense or distribute the Program is 175 | void, and will automatically terminate your rights under this License. 176 | However, parties who have received copies, or rights, from you under 177 | this License will not have their licenses terminated so long as such 178 | parties remain in full compliance. 179 | 180 | 5. You are not required to accept this License, since you have not 181 | signed it. However, nothing else grants you permission to modify or 182 | distribute the Program or its derivative works. These actions are 183 | prohibited by law if you do not accept this License. Therefore, by 184 | modifying or distributing the Program (or any work based on the 185 | Program), you indicate your acceptance of this License to do so, and 186 | all its terms and conditions for copying, distributing or modifying 187 | the Program or works based on it. 188 | 189 | 6. Each time you redistribute the Program (or any work based on the 190 | Program), the recipient automatically receives a license from the 191 | original licensor to copy, distribute or modify the Program subject to 192 | these terms and conditions. You may not impose any further 193 | restrictions on the recipients' exercise of the rights granted herein. 194 | You are not responsible for enforcing compliance by third parties to 195 | this License. 196 | 197 | 7. If, as a consequence of a court judgment or allegation of patent 198 | infringement or for any other reason (not limited to patent issues), 199 | conditions are imposed on you (whether by court order, agreement or 200 | otherwise) that contradict the conditions of this License, they do not 201 | excuse you from the conditions of this License. If you cannot 202 | distribute so as to satisfy simultaneously your obligations under this 203 | License and any other pertinent obligations, then as a consequence you 204 | may not distribute the Program at all. For example, if a patent 205 | license would not permit royalty-free redistribution of the Program by 206 | all those who receive copies directly or indirectly through you, then 207 | the only way you could satisfy both it and this License would be to 208 | refrain entirely from distribution of the Program. 209 | 210 | If any portion of this section is held invalid or unenforceable under 211 | any particular circumstance, the balance of the section is intended to 212 | apply and the section as a whole is intended to apply in other 213 | circumstances. 214 | 215 | It is not the purpose of this section to induce you to infringe any 216 | patents or other property right claims or to contest validity of any 217 | such claims; this section has the sole purpose of protecting the 218 | integrity of the free software distribution system, which is 219 | implemented by public license practices. Many people have made 220 | generous contributions to the wide range of software distributed 221 | through that system in reliance on consistent application of that 222 | system; it is up to the author/donor to decide if he or she is willing 223 | to distribute software through any other system and a licensee cannot 224 | impose that choice. 225 | 226 | This section is intended to make thoroughly clear what is believed to 227 | be a consequence of the rest of this License. 228 | 229 | 8. If the distribution and/or use of the Program is restricted in 230 | certain countries either by patents or by copyrighted interfaces, the 231 | original copyright holder who places the Program under this License 232 | may add an explicit geographical distribution limitation excluding 233 | those countries, so that distribution is permitted only in or among 234 | countries not thus excluded. In such case, this License incorporates 235 | the limitation as if written in the body of this License. 236 | 237 | 9. The Free Software Foundation may publish revised and/or new versions 238 | of the General Public License from time to time. Such new versions will 239 | be similar in spirit to the present version, but may differ in detail to 240 | address new problems or concerns. 241 | 242 | Each version is given a distinguishing version number. If the Program 243 | specifies a version number of this License which applies to it and "any 244 | later version", you have the option of following the terms and conditions 245 | either of that version or of any later version published by the Free 246 | Software Foundation. If the Program does not specify a version number of 247 | this License, you may choose any version ever published by the Free Software 248 | Foundation. 249 | 250 | 10. If you wish to incorporate parts of the Program into other free 251 | programs whose distribution conditions are different, write to the author 252 | to ask for permission. For software which is copyrighted by the Free 253 | Software Foundation, write to the Free Software Foundation; we sometimes 254 | make exceptions for this. Our decision will be guided by the two goals 255 | of preserving the free status of all derivatives of our free software and 256 | of promoting the sharing and reuse of software generally. 257 | 258 | NO WARRANTY 259 | 260 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY 261 | FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN 262 | OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES 263 | PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED 264 | OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 265 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS 266 | TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE 267 | PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, 268 | REPAIR OR CORRECTION. 269 | 270 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 271 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR 272 | REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, 273 | INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING 274 | OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED 275 | TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY 276 | YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER 277 | PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE 278 | POSSIBILITY OF SUCH DAMAGES. 279 | 280 | END OF TERMS AND CONDITIONS 281 | 282 | How to Apply These Terms to Your New Programs 283 | 284 | If you develop a new program, and you want it to be of the greatest 285 | possible use to the public, the best way to achieve this is to make it 286 | free software which everyone can redistribute and change under these terms. 287 | 288 | To do so, attach the following notices to the program. It is safest 289 | to attach them to the start of each source file to most effectively 290 | convey the exclusion of warranty; and each file should have at least 291 | the "copyright" line and a pointer to where the full notice is found. 292 | 293 | 294 | Copyright (C) 295 | 296 | This program is free software; you can redistribute it and/or modify 297 | it under the terms of the GNU General Public License as published by 298 | the Free Software Foundation; either version 2 of the License, or 299 | (at your option) any later version. 300 | 301 | This program is distributed in the hope that it will be useful, 302 | but WITHOUT ANY WARRANTY; without even the implied warranty of 303 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 304 | GNU General Public License for more details. 305 | 306 | You should have received a copy of the GNU General Public License along 307 | with this program; if not, write to the Free Software Foundation, Inc., 308 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 309 | 310 | Also add information on how to contact you by electronic and paper mail. 311 | 312 | If the program is interactive, make it output a short notice like this 313 | when it starts in an interactive mode: 314 | 315 | Gnomovision version 69, Copyright (C) year name of author 316 | Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 317 | This is free software, and you are welcome to redistribute it 318 | under certain conditions; type `show c' for details. 319 | 320 | The hypothetical commands `show w' and `show c' should show the appropriate 321 | parts of the General Public License. Of course, the commands you use may 322 | be called something other than `show w' and `show c'; they could even be 323 | mouse-clicks or menu items--whatever suits your program. 324 | 325 | You should also get your employer (if you work as a programmer) or your 326 | school, if any, to sign a "copyright disclaimer" for the program, if 327 | necessary. Here is a sample; alter the names: 328 | 329 | Yoyodyne, Inc., hereby disclaims all copyright interest in the program 330 | `Gnomovision' (which makes passes at compilers) written by James Hacker. 331 | 332 | , 1 April 1989 333 | Ty Coon, President of Vice 334 | 335 | This General Public License does not permit incorporating your program into 336 | proprietary programs. If your program is a subroutine library, you may 337 | consider it more useful to permit linking proprietary applications with the 338 | library. If this is what you want to do, use the GNU Lesser General 339 | Public License instead of this License. 340 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # VSCodeConfigHelper (v1.x and v2.x) 2 | 3 | ## ⚠️ Warning 4 | 5 | **此仓库用于存放 1.x 和 2.x 旧版工具的代码。旧版工具将不再接受功能更新,请前往 [VSCodeConfigHelper3](https://github.com/Guyutongxue/VSCodeConfigHelper3) 了解关于新版 3.x 的信息。** 6 | 7 | VSCodeConfigHelper 是一个配置 Visual Studio Code C++ 环境的工具。它专为编程新手打造,致力于让学生专注于编程的学习而非环境的配置工作上。 8 | 9 | **[旧版工具下载地址](https://github.com/Guyutongxue/VSCodeConfigHelper/releases)** 10 | 11 | ## 使用方法 12 | 13 | 此工具只能在 Windows (版本不低于 Windows 7 Service Pack 1)环境下使用。如果您使用的是 macOS,请参阅[此处](VS_Code_in_Mac.md)。如果您使用的是 GNU/Linux,您来这里做什么? 14 | 15 | 您**只**需要一个支持 7-Zip 解压缩的软件。您可以使用*任何*主流的工具包括 WinRAR、Bandizip 甚至“好压”。 16 | 17 | 然后,您只需要[下载](https://github.com/Guyutongxue/VSCodeConfigHelper/releases)此工具,然后按照上面的提示进行即可: 18 | 19 | 1. 第一步:输入一个**不包含中文**或者特殊字符的文件夹,作为您的工作文件夹。您的一切代码和程序都将存放在该文件夹下。若一切顺利,请点击下一步。 20 | 2. 第二步:配置您的 MinGW-w64。 21 | - 如果您是第一次配置,请您点击下载链接,然后使用 7-Zip 解压缩工具解压。请妥善保存解压得到的文件,并将其路径输入到工具中。若一切顺利,你将看到绿色的输出。此时请您点击下一步。 22 | - 如果这不是您第一次配置,请您选中您想要使用的编译环境。请注意,如果该编译环境是红色字体,说明该编译环境并不推荐,可能导致异常。选择完毕后,请您点击下一步。 23 | 3. 第三步:安装 VS Code 和插件。 24 | - 如果您已经安装了 VS Code,则工具会自动检测并提示您。如果您观察到了红色字体的输出,说明您当前安装的 VS Code 可能与 MinGW-w64 不兼容。建议您重新通过工具提供的链接下载并安装。安装完成后,请点击刷新按钮。 25 | - 如果您未安装 VS Code,请通过工具提供的链接下载并安装。安装完成后,请点击刷新按钮。 26 | - 请您点击下方的安装扩展按钮。若安装成功,则提示“已安装”。此时您可以点击下一步。 27 | 4. 第四步:选择您喜爱的样式。建议您选择内置终端样式,避免意外情形发生。选择完成后,点击下一步进行配置。 28 | 5. 第五步:您的配置已完成。您可以选择生成 “Hello World” 测试代码,或者启动 VS Code。 29 | 30 | 若您选择内置终端样式,请按 F5 (在不同设备上可能是 Fn+F5),期望在底部弹出一个终端并打印出 `Hello,world!` 。 31 | 32 | 若您选择弹出窗口样式,请安 F6(在不同设备上可能是 Fn+F6),期望在弹出一个终端窗口并打印出 `Hello,world!` 。 33 | 34 | 之后您启动 VS Code 时,请选择打开**工作文件夹**,也就是您第一步填写的文件夹。**(不是 .vscode 文件夹。)** 35 | 36 | ## 遇到了 Windows Defender SmartScreen ... 的问题 37 | 38 | 请您选择“仍要运行”。 39 | 40 | ## 遇到了 .NET Framework ... 的问题 41 | 42 | 如果您无法启动工具,出现这种情况: 43 | 44 | ![.NET Framework not found](https://s2.ax1x.com/2020/01/14/lqbwOU.jpg) 45 | 46 | 请前往 [Microsoft 下载](https://www.microsoft.com/zh-CN/download/details.aspx?id=53344) 获取 .NET Framework 4.6.2 环境。 47 | 48 | ## 参阅 49 | 50 | ### [FAQ](FAQ.md) 51 | 52 | ### [疑难解答](TroubleShooting.md) 53 | 54 | ----- 55 | 56 | ## 关于此项目 57 | 58 | 本项目使用 Visual Studio 2019 开发,基于 .NET Framework 4.5 。代码采用 GPLv2 协议开源,欢迎您贡献出您自己的一份力量。您只需要克隆本仓库,然后使用 Visual Studio 打开解决方案文件即可生成、调试。 59 | -------------------------------------------------------------------------------- /TroubleShooting.md: -------------------------------------------------------------------------------- 1 | # 疑难解答 / Troubleshooting 2 | 3 | *更新于 2020.3.29* 4 | 5 | 以下罗列了您使用 VSCodeConfigHelper 可能遇到的错误,并提供解决方案。您可以在此页面按下 Ctrl+F 进行搜索。 6 | 7 | ## 按下 F5 出现了“选择环境”菜单 8 | 9 | 然后您要确保您打开的是**工作区文件夹**,而非单个文件。您可以查看 VS Code 左侧“资源管理器”选项卡:如果出现了“无打开的文件夹”字样,您可以点击下方的“打开文件夹”按钮,选择您配置的**工作区文件夹**打开。当您打开工作区时,您应当看到一个 `.vscode` 目录。 10 | 11 | ## 终端进程“C:\Windows\System32\cmd.exe /c *\*”启动失败(退出代码: 1)。 12 | 13 | 解决方法同下条。 14 | 15 | ## 'g++.exe' 不是内部或外部命令,也不是可运行的程序或批处理文件。 16 | 17 | 请您尝试重新启动 VS Code。请注意,您需要关闭所有的 VS Code 活动窗口。如果您开启了任何终端窗口(如 CMD、PowerShell),您也需要关闭它们。 18 | 19 | 若问题未解决,尝试重新启动系统。若仍然未解决,则尝试在 CMD 或者 PowerShell (按下Win+R,输入 `cmd` 或 `powershell`)中运行以下命令: 20 | 21 | ```CMD 22 | g++ --version 23 | ``` 24 | 25 | 并按下 Enter。若出现类似: 26 | 27 | ``` 28 | g++.exe (x86_64-win32-seh-rev0, Built by MinGW-W64 Project) 8.1.0 29 | ``` 30 | 31 | 字样,则尝试重新安装 VS Code。请您务必通过**此工具提供的下载链接**安装。 32 | 33 | 若同样出现了 34 | 35 | ``` 36 | 'g++.exe' 不是内部或外部命令,也不是可运行的程序或批处理文件。 37 | ``` 38 | 39 | 字样,则检查您的环境变量配置。您应当检查本工具的“配置 MinGW”页面,选择或添加您的 MinGW。 40 | 41 | ## Unable to start debugging. Program path '*\*' is missing or invalid. 42 | 43 | 请您避免使用非英文字母(如中文或中文标点)的文件命名。这是由于 MinGW-w64 中的 GDB 调试器不支持 Unicode 字符导致的错误,目前仍然没有办法解决。因此请您**使用英文字母、下划线等字符来为你的文件命名**。同时,我们也不建议在文件名中包含空格。 44 | 45 | ## 编译成功,但调试时没有响应 46 | 47 | 特定版本的 Windows 10 可能存在隐藏的设计失误导致此问题发声。请在**控制面板**检查以下选项:时钟和区域->区域->更改位置->管理->更改系统区域设置, `Beta版:使用Unicode UTF8提供全球语言支持(U)` 复选框是否勾选。请确保此复选框**不被勾选**。 48 | 49 | 若问题仍存在,请检查您使用的 MinGW-w64 版本是否正确。某些版本的 MinGW 可能不包含 64 位编译工具从而导致此错误的发生。请您尝试删除您正在使用的 MinGW-w64,然后通过**此工具提供的下载链接**重新下载 MinGW-w64。 50 | 51 | 如果您曾经配置过其它版本的 MinGW,您可能需要移除它们。您只需要在本工具的“配置 MinGW”界面选择或添加您想保留的 MinGW 版本,工具将自动为您删除其它 MinGW。 52 | 53 | ## 检测到 #include 错误。请更新 includePath。已为此翻译单元(*\*)禁用波形曲线…… 54 | 55 | 请您首先尝试重新启动 VS Code。请注意,您需要关闭所有的 VS Code 活动窗口。如果您开启了任何终端窗口(如 CMD、PowerShell),您也需要关闭它们。 56 | 57 | 然后您要确保您打开的是**工作区文件夹**,而非单个文件。您可以查看 VS Code 左侧“资源管理器”选项卡:如果出现了“无打开的文件夹”字样,您可以点击下方的“打开文件夹”按钮,选择您配置的**工作区文件夹**打开。当您打开工作区时,您应当看到一个 `.vscode` 目录。 58 | 59 | 如果上述操作未能解决问题,您安装的 VS Code 版本可能与 MinGW-w64 不匹配。请卸载 VS Code,并通过**此工具提供的下载链接**进行安装。 60 | 61 | ## 终端 shell 路径“cmd.exe”不存在 62 | 63 | 请检查您的环境变量中是否正确:打开控制面板->系统和安全->系统->高级系统设置->环境变量(N)...,然后确保其中包含 `C:\Windows\System32` 这一路径。若您使用 Windows 7,请您确保路径之间用分号分隔。 64 | 65 | ## 代码高亮出现问题 66 | 67 | [重新安装](https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools) `C/C++` 扩展即可。 68 | 69 | 70 | ## 使用外部弹窗样式时,调试时黑窗一闪而过 71 | 72 | 这个是正常现象,因为调试的时候不会在程序运行结束的时候停住;也就是说,当处于调试状态时,程序运行完毕后就会直接退出。因此这时只能看到一个一闪而过的窗口。 73 | 74 | 这里给出的建议是,只有在需要调试的时候调试,同时调试的时候加上断点。如果实在需要调试后暂停看输出的话,也可以结尾加上 75 | ```C++ 76 | system("pause"); // 需 #include 77 | ``` 78 | 之类的语句来防止窗口退出。 79 | 80 | ## 上述疑难解答未能解决我的问题 / 遇到了其它问题 81 | 82 | 您可以通过[邮件](mailto:guyutongxue@163.com)联系开发者,也可以[发起 Issue](https://github.com/Guyutongxue/VSCodeConfigHelper/issues)。 83 | -------------------------------------------------------------------------------- /VSCodeConfigHelper.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Version 16 4 | VisualStudioVersion = 16.0.28729.10 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VSCodeConfigHelper", "VSCodeConfigHelper\VSCodeConfigHelper.csproj", "{0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Debug|x64 = Debug|x64 12 | Debug|x86 = Debug|x86 13 | Release|Any CPU = Release|Any CPU 14 | Release|x64 = Release|x64 15 | Release|x86 = Release|x86 16 | EndGlobalSection 17 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 18 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 19 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Debug|Any CPU.Build.0 = Debug|Any CPU 20 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Debug|x64.ActiveCfg = Debug|x64 21 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Debug|x64.Build.0 = Debug|x64 22 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Debug|x86.ActiveCfg = Debug|x86 23 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Debug|x86.Build.0 = Debug|x86 24 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Release|Any CPU.ActiveCfg = Release|Any CPU 25 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Release|Any CPU.Build.0 = Release|Any CPU 26 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Release|x64.ActiveCfg = Release|x64 27 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Release|x64.Build.0 = Release|x64 28 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Release|x86.ActiveCfg = Release|x86 29 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9}.Release|x86.Build.0 = Release|x86 30 | EndGlobalSection 31 | GlobalSection(SolutionProperties) = preSolution 32 | HideSolutionNode = FALSE 33 | EndGlobalSection 34 | GlobalSection(ExtensibilityGlobals) = postSolution 35 | SolutionGuid = {696A7763-D4F1-4CFD-B761-F070577F3036} 36 | EndGlobalSection 37 | EndGlobal 38 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/FodyWeavers.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/FodyWeavers.xsd: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | A list of assembly names to exclude from the default action of "embed all Copy Local references", delimited with line breaks 13 | 14 | 15 | 16 | 17 | A list of assembly names to include from the default action of "embed all Copy Local references", delimited with line breaks. 18 | 19 | 20 | 21 | 22 | A list of unmanaged 32 bit assembly names to include, delimited with line breaks. 23 | 24 | 25 | 26 | 27 | A list of unmanaged 64 bit assembly names to include, delimited with line breaks. 28 | 29 | 30 | 31 | 32 | The order of preloaded assemblies, delimited with line breaks. 33 | 34 | 35 | 36 | 37 | 38 | This will copy embedded files to disk before loading them into memory. This is helpful for some scenarios that expected an assembly to be loaded from a physical file. 39 | 40 | 41 | 42 | 43 | Controls if .pdbs for reference assemblies are also embedded. 44 | 45 | 46 | 47 | 48 | Embedded assemblies are compressed by default, and uncompressed when they are loaded. You can turn compression off with this option. 49 | 50 | 51 | 52 | 53 | As part of Costura, embedded assemblies are no longer included as part of the build. This cleanup can be turned off. 54 | 55 | 56 | 57 | 58 | Costura by default will load as part of the module initialization. This flag disables that behavior. Make sure you call CosturaUtility.Initialize() somewhere in your code. 59 | 60 | 61 | 62 | 63 | Costura will by default use assemblies with a name like 'resources.dll' as a satellite resource and prepend the output path. This flag disables that behavior. 64 | 65 | 66 | 67 | 68 | A list of assembly names to exclude from the default action of "embed all Copy Local references", delimited with | 69 | 70 | 71 | 72 | 73 | A list of assembly names to include from the default action of "embed all Copy Local references", delimited with |. 74 | 75 | 76 | 77 | 78 | A list of unmanaged 32 bit assembly names to include, delimited with |. 79 | 80 | 81 | 82 | 83 | A list of unmanaged 64 bit assembly names to include, delimited with |. 84 | 85 | 86 | 87 | 88 | The order of preloaded assemblies, delimited with |. 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 'true' to run assembly verification (PEVerify) on the target assembly after all weavers have been executed. 97 | 98 | 99 | 100 | 101 | A comma-separated list of error codes that can be safely ignored in assembly verification. 102 | 103 | 104 | 105 | 106 | 'false' to turn off automatic generation of the XML Schema file. 107 | 108 | 109 | 110 | 111 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Form1.Designer.cs: -------------------------------------------------------------------------------- 1 | namespace VSCodeConfigHelper 2 | { 3 | partial class Form1 4 | { 5 | /// 6 | /// 必需的设计器变量。 7 | /// 8 | private System.ComponentModel.IContainer components = null; 9 | 10 | /// 11 | /// 清理所有正在使用的资源。 12 | /// 13 | /// 如果应释放托管资源,为 true;否则为 false。 14 | protected override void Dispose(bool disposing) 15 | { 16 | if (disposing && (components != null)) 17 | { 18 | components.Dispose(); 19 | } 20 | base.Dispose(disposing); 21 | } 22 | 23 | #region Windows 窗体设计器生成的代码 24 | 25 | /// 26 | /// 设计器支持所需的方法 - 不要修改 27 | /// 使用代码编辑器修改此方法的内容。 28 | /// 29 | private void InitializeComponent() 30 | { 31 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1)); 32 | this.linkLabelManual = new System.Windows.Forms.LinkLabel(); 33 | this.labelAuthor = new System.Windows.Forms.Label(); 34 | this.checkBoxGenTest = new System.Windows.Forms.CheckBox(); 35 | this.checkBoxOpen = new System.Windows.Forms.CheckBox(); 36 | this.buttonExtension = new System.Windows.Forms.Button(); 37 | this.labelMinGWState = new System.Windows.Forms.Label(); 38 | this.linkLabelVSCode = new System.Windows.Forms.LinkLabel(); 39 | this.labelWorkspaceStatus = new System.Windows.Forms.Label(); 40 | this.buttonViewWorkspace = new System.Windows.Forms.Button(); 41 | this.textBoxWorkspacePath = new System.Windows.Forms.TextBox(); 42 | this.linkLabelMinGW = new System.Windows.Forms.LinkLabel(); 43 | this.labelMinGWPathHint = new System.Windows.Forms.Label(); 44 | this.textBoxMinGWPath = new System.Windows.Forms.TextBox(); 45 | this.buttonViewMinGW = new System.Windows.Forms.Button(); 46 | this.folderBrowserDialog1 = new System.Windows.Forms.FolderBrowserDialog(); 47 | this.tabControlMain = new System.Windows.Forms.TabControl(); 48 | this.tabPageWelcome = new System.Windows.Forms.TabPage(); 49 | this.labelWelcomeTitle = new System.Windows.Forms.Label(); 50 | this.buttonWelcomCancel = new System.Windows.Forms.Button(); 51 | this.buttonWelcomeNext = new System.Windows.Forms.Button(); 52 | this.labelFolderHelp = new System.Windows.Forms.Label(); 53 | this.labelFolderHint = new System.Windows.Forms.Label(); 54 | this.labelWelcomeText = new System.Windows.Forms.Label(); 55 | this.tabPageMinGW = new System.Windows.Forms.TabPage(); 56 | this.labelMinGWTitle = new System.Windows.Forms.Label(); 57 | this.panelMinGWTable = new System.Windows.Forms.Panel(); 58 | this.buttonMinGWAdd = new System.Windows.Forms.Button(); 59 | this.listViewMinGW = new System.Windows.Forms.ListView(); 60 | this.columnHeaderName = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); 61 | this.columnHeaderPath = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); 62 | this.columnHeaderVersion = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); 63 | this.labelMinGWHint = new System.Windows.Forms.Label(); 64 | this.buttonMinGWPrev = new System.Windows.Forms.Button(); 65 | this.buttonMinGWCancel = new System.Windows.Forms.Button(); 66 | this.buttonMinGWNext = new System.Windows.Forms.Button(); 67 | this.tabPageCode = new System.Windows.Forms.TabPage(); 68 | this.labelCodeTitle = new System.Windows.Forms.Label(); 69 | this.labelExtensionHint = new System.Windows.Forms.Label(); 70 | this.buttonRefresh = new System.Windows.Forms.Button(); 71 | this.labelCodeHint = new System.Windows.Forms.Label(); 72 | this.buttonCodePrev = new System.Windows.Forms.Button(); 73 | this.buttonCodeCancel = new System.Windows.Forms.Button(); 74 | this.buttonCodeNext = new System.Windows.Forms.Button(); 75 | this.tabPageStyle = new System.Windows.Forms.TabPage(); 76 | this.pictureBoxExternal = new System.Windows.Forms.PictureBox(); 77 | this.pictureBoxInternal = new System.Windows.Forms.PictureBox(); 78 | this.labelExternalHint = new System.Windows.Forms.Label(); 79 | this.labelInternalHint = new System.Windows.Forms.Label(); 80 | this.radioButtonExternal = new System.Windows.Forms.RadioButton(); 81 | this.radioButtonInternal = new System.Windows.Forms.RadioButton(); 82 | this.labelStyleTitle = new System.Windows.Forms.Label(); 83 | this.buttonConfigPrev = new System.Windows.Forms.Button(); 84 | this.buttonConfigCancel = new System.Windows.Forms.Button(); 85 | this.buttonConfigNext = new System.Windows.Forms.Button(); 86 | this.tabPageFinish = new System.Windows.Forms.TabPage(); 87 | this.checkBoxHitCount = new System.Windows.Forms.CheckBox(); 88 | this.checkBoxDesktopShortcut = new System.Windows.Forms.CheckBox(); 89 | this.labelFinishHint = new System.Windows.Forms.Label(); 90 | this.labelFinishTitle = new System.Windows.Forms.Label(); 91 | this.buttonFinishAll = new System.Windows.Forms.Button(); 92 | this.buttonSettings = new System.Windows.Forms.Button(); 93 | this.panelNavigate = new System.Windows.Forms.Panel(); 94 | this.pictureBoxLogo = new System.Windows.Forms.PictureBox(); 95 | this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog(); 96 | this.tabControlMain.SuspendLayout(); 97 | this.tabPageWelcome.SuspendLayout(); 98 | this.tabPageMinGW.SuspendLayout(); 99 | this.panelMinGWTable.SuspendLayout(); 100 | this.tabPageCode.SuspendLayout(); 101 | this.tabPageStyle.SuspendLayout(); 102 | ((System.ComponentModel.ISupportInitialize)(this.pictureBoxExternal)).BeginInit(); 103 | ((System.ComponentModel.ISupportInitialize)(this.pictureBoxInternal)).BeginInit(); 104 | this.tabPageFinish.SuspendLayout(); 105 | ((System.ComponentModel.ISupportInitialize)(this.pictureBoxLogo)).BeginInit(); 106 | this.SuspendLayout(); 107 | // 108 | // linkLabelManual 109 | // 110 | this.linkLabelManual.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 111 | this.linkLabelManual.AutoSize = true; 112 | this.linkLabelManual.Location = new System.Drawing.Point(84, 366); 113 | this.linkLabelManual.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); 114 | this.linkLabelManual.Name = "linkLabelManual"; 115 | this.linkLabelManual.Size = new System.Drawing.Size(67, 15); 116 | this.linkLabelManual.TabIndex = 4; 117 | this.linkLabelManual.TabStop = true; 118 | this.linkLabelManual.Text = "使用帮助"; 119 | this.linkLabelManual.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkLabelManual_LinkClicked); 120 | // 121 | // labelAuthor 122 | // 123 | this.labelAuthor.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 124 | this.labelAuthor.Location = new System.Drawing.Point(183, 366); 125 | this.labelAuthor.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); 126 | this.labelAuthor.Name = "labelAuthor"; 127 | this.labelAuthor.Size = new System.Drawing.Size(582, 21); 128 | this.labelAuthor.TabIndex = 0; 129 | this.labelAuthor.Text = "版权"; 130 | this.labelAuthor.TextAlign = System.Drawing.ContentAlignment.TopRight; 131 | // 132 | // checkBoxGenTest 133 | // 134 | this.checkBoxGenTest.AutoSize = true; 135 | this.checkBoxGenTest.Checked = true; 136 | this.checkBoxGenTest.CheckState = System.Windows.Forms.CheckState.Checked; 137 | this.checkBoxGenTest.Location = new System.Drawing.Point(34, 108); 138 | this.checkBoxGenTest.Name = "checkBoxGenTest"; 139 | this.checkBoxGenTest.Size = new System.Drawing.Size(119, 19); 140 | this.checkBoxGenTest.TabIndex = 26; 141 | this.checkBoxGenTest.Text = "生成测试代码"; 142 | this.checkBoxGenTest.UseVisualStyleBackColor = true; 143 | // 144 | // checkBoxOpen 145 | // 146 | this.checkBoxOpen.AutoSize = true; 147 | this.checkBoxOpen.Checked = true; 148 | this.checkBoxOpen.CheckState = System.Windows.Forms.CheckState.Checked; 149 | this.checkBoxOpen.Location = new System.Drawing.Point(34, 133); 150 | this.checkBoxOpen.Name = "checkBoxOpen"; 151 | this.checkBoxOpen.Size = new System.Drawing.Size(123, 19); 152 | this.checkBoxOpen.TabIndex = 25; 153 | this.checkBoxOpen.Text = "启动 VS Code"; 154 | this.checkBoxOpen.UseVisualStyleBackColor = true; 155 | // 156 | // buttonExtension 157 | // 158 | this.buttonExtension.Location = new System.Drawing.Point(39, 184); 159 | this.buttonExtension.Margin = new System.Windows.Forms.Padding(4); 160 | this.buttonExtension.Name = "buttonExtension"; 161 | this.buttonExtension.Size = new System.Drawing.Size(100, 29); 162 | this.buttonExtension.TabIndex = 8; 163 | this.buttonExtension.Text = "安装扩展"; 164 | this.buttonExtension.UseVisualStyleBackColor = true; 165 | this.buttonExtension.Click += new System.EventHandler(this.ButtonExtension_Click); 166 | // 167 | // labelMinGWState 168 | // 169 | this.labelMinGWState.Location = new System.Drawing.Point(60, 232); 170 | this.labelMinGWState.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); 171 | this.labelMinGWState.Name = "labelMinGWState"; 172 | this.labelMinGWState.Size = new System.Drawing.Size(411, 45); 173 | this.labelMinGWState.TabIndex = 4; 174 | this.labelMinGWState.Text = " "; 175 | // 176 | // linkLabelVSCode 177 | // 178 | this.linkLabelVSCode.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 179 | this.linkLabelVSCode.Location = new System.Drawing.Point(445, 97); 180 | this.linkLabelVSCode.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); 181 | this.linkLabelVSCode.Name = "linkLabelVSCode"; 182 | this.linkLabelVSCode.Size = new System.Drawing.Size(91, 15); 183 | this.linkLabelVSCode.TabIndex = 16; 184 | this.linkLabelVSCode.TabStop = true; 185 | this.linkLabelVSCode.Text = "下载地址"; 186 | this.linkLabelVSCode.TextAlign = System.Drawing.ContentAlignment.MiddleRight; 187 | this.linkLabelVSCode.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkLabelVSCode_LinkClicked); 188 | // 189 | // labelWorkspaceStatus 190 | // 191 | this.labelWorkspaceStatus.AutoSize = true; 192 | this.labelWorkspaceStatus.ForeColor = System.Drawing.Color.Red; 193 | this.labelWorkspaceStatus.Location = new System.Drawing.Point(31, 159); 194 | this.labelWorkspaceStatus.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); 195 | this.labelWorkspaceStatus.Name = "labelWorkspaceStatus"; 196 | this.labelWorkspaceStatus.Size = new System.Drawing.Size(277, 15); 197 | this.labelWorkspaceStatus.TabIndex = 24; 198 | this.labelWorkspaceStatus.Text = "路径中不能包含空格、中文或者其它特殊字符。"; 199 | this.labelWorkspaceStatus.Visible = false; 200 | // 201 | // buttonViewWorkspace 202 | // 203 | this.buttonViewWorkspace.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 204 | this.buttonViewWorkspace.Location = new System.Drawing.Point(461, 130); 205 | this.buttonViewWorkspace.Margin = new System.Windows.Forms.Padding(4); 206 | this.buttonViewWorkspace.Name = "buttonViewWorkspace"; 207 | this.buttonViewWorkspace.Size = new System.Drawing.Size(100, 25); 208 | this.buttonViewWorkspace.TabIndex = 20; 209 | this.buttonViewWorkspace.Text = "浏览..."; 210 | this.buttonViewWorkspace.UseVisualStyleBackColor = true; 211 | this.buttonViewWorkspace.Click += new System.EventHandler(this.ButtonViewWorkspace_Click); 212 | // 213 | // textBoxWorkspacePath 214 | // 215 | this.textBoxWorkspacePath.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 216 | | System.Windows.Forms.AnchorStyles.Right))); 217 | this.textBoxWorkspacePath.Location = new System.Drawing.Point(34, 130); 218 | this.textBoxWorkspacePath.Margin = new System.Windows.Forms.Padding(4); 219 | this.textBoxWorkspacePath.Name = "textBoxWorkspacePath"; 220 | this.textBoxWorkspacePath.Size = new System.Drawing.Size(419, 25); 221 | this.textBoxWorkspacePath.TabIndex = 19; 222 | this.textBoxWorkspacePath.TextChanged += new System.EventHandler(this.TextBoxWorkspacePath_TextChanged); 223 | // 224 | // linkLabelMinGW 225 | // 226 | this.linkLabelMinGW.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 227 | this.linkLabelMinGW.Location = new System.Drawing.Point(476, 55); 228 | this.linkLabelMinGW.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); 229 | this.linkLabelMinGW.Name = "linkLabelMinGW"; 230 | this.linkLabelMinGW.Size = new System.Drawing.Size(91, 15); 231 | this.linkLabelMinGW.TabIndex = 15; 232 | this.linkLabelMinGW.TabStop = true; 233 | this.linkLabelMinGW.Text = "下载地址..."; 234 | this.linkLabelMinGW.TextAlign = System.Drawing.ContentAlignment.MiddleRight; 235 | this.linkLabelMinGW.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkLabelMinGW_LinkClicked); 236 | // 237 | // labelMinGWPathHint 238 | // 239 | this.labelMinGWPathHint.Location = new System.Drawing.Point(28, 118); 240 | this.labelMinGWPathHint.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); 241 | this.labelMinGWPathHint.Name = "labelMinGWPathHint"; 242 | this.labelMinGWPathHint.Size = new System.Drawing.Size(446, 56); 243 | this.labelMinGWPathHint.TabIndex = 14; 244 | this.labelMinGWPathHint.TextAlign = System.Drawing.ContentAlignment.BottomLeft; 245 | // 246 | // textBoxMinGWPath 247 | // 248 | this.textBoxMinGWPath.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 249 | | System.Windows.Forms.AnchorStyles.Right))); 250 | this.textBoxMinGWPath.Location = new System.Drawing.Point(28, 192); 251 | this.textBoxMinGWPath.Margin = new System.Windows.Forms.Padding(4); 252 | this.textBoxMinGWPath.Name = "textBoxMinGWPath"; 253 | this.textBoxMinGWPath.Size = new System.Drawing.Size(421, 25); 254 | this.textBoxMinGWPath.TabIndex = 1; 255 | this.textBoxMinGWPath.TextChanged += new System.EventHandler(this.TextBoxMinGWPath_TextChanged); 256 | // 257 | // buttonViewMinGW 258 | // 259 | this.buttonViewMinGW.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 260 | this.buttonViewMinGW.Location = new System.Drawing.Point(457, 192); 261 | this.buttonViewMinGW.Margin = new System.Windows.Forms.Padding(4); 262 | this.buttonViewMinGW.Name = "buttonViewMinGW"; 263 | this.buttonViewMinGW.Size = new System.Drawing.Size(100, 25); 264 | this.buttonViewMinGW.TabIndex = 0; 265 | this.buttonViewMinGW.Text = "浏览..."; 266 | this.buttonViewMinGW.UseVisualStyleBackColor = true; 267 | this.buttonViewMinGW.Click += new System.EventHandler(this.ButtonViewMinGW_Click); 268 | // 269 | // tabControlMain 270 | // 271 | this.tabControlMain.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 272 | | System.Windows.Forms.AnchorStyles.Left) 273 | | System.Windows.Forms.AnchorStyles.Right))); 274 | this.tabControlMain.Appearance = System.Windows.Forms.TabAppearance.FlatButtons; 275 | this.tabControlMain.Controls.Add(this.tabPageWelcome); 276 | this.tabControlMain.Controls.Add(this.tabPageMinGW); 277 | this.tabControlMain.Controls.Add(this.tabPageCode); 278 | this.tabControlMain.Controls.Add(this.tabPageStyle); 279 | this.tabControlMain.Controls.Add(this.tabPageFinish); 280 | this.tabControlMain.ItemSize = new System.Drawing.Size(20, 20); 281 | this.tabControlMain.Location = new System.Drawing.Point(175, 12); 282 | this.tabControlMain.Name = "tabControlMain"; 283 | this.tabControlMain.SelectedIndex = 0; 284 | this.tabControlMain.Size = new System.Drawing.Size(594, 345); 285 | this.tabControlMain.SizeMode = System.Windows.Forms.TabSizeMode.Fixed; 286 | this.tabControlMain.TabIndex = 1; 287 | this.tabControlMain.SelectedIndexChanged += new System.EventHandler(this.tabControlMain_SelectedIndexChanged); 288 | // 289 | // tabPageWelcome 290 | // 291 | this.tabPageWelcome.BackColor = System.Drawing.SystemColors.ControlLightLight; 292 | this.tabPageWelcome.Controls.Add(this.labelWelcomeTitle); 293 | this.tabPageWelcome.Controls.Add(this.buttonWelcomCancel); 294 | this.tabPageWelcome.Controls.Add(this.buttonWelcomeNext); 295 | this.tabPageWelcome.Controls.Add(this.labelFolderHelp); 296 | this.tabPageWelcome.Controls.Add(this.labelFolderHint); 297 | this.tabPageWelcome.Controls.Add(this.labelWorkspaceStatus); 298 | this.tabPageWelcome.Controls.Add(this.labelWelcomeText); 299 | this.tabPageWelcome.Controls.Add(this.buttonViewWorkspace); 300 | this.tabPageWelcome.Controls.Add(this.textBoxWorkspacePath); 301 | this.tabPageWelcome.Location = new System.Drawing.Point(4, 24); 302 | this.tabPageWelcome.Name = "tabPageWelcome"; 303 | this.tabPageWelcome.Padding = new System.Windows.Forms.Padding(3); 304 | this.tabPageWelcome.Size = new System.Drawing.Size(586, 317); 305 | this.tabPageWelcome.TabIndex = 0; 306 | // 307 | // labelWelcomeTitle 308 | // 309 | this.labelWelcomeTitle.AutoSize = true; 310 | this.labelWelcomeTitle.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); 311 | this.labelWelcomeTitle.Location = new System.Drawing.Point(28, 3); 312 | this.labelWelcomeTitle.Name = "labelWelcomeTitle"; 313 | this.labelWelcomeTitle.Size = new System.Drawing.Size(65, 32); 314 | this.labelWelcomeTitle.TabIndex = 27; 315 | this.labelWelcomeTitle.Text = "欢迎"; 316 | // 317 | // buttonWelcomCancel 318 | // 319 | this.buttonWelcomCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 320 | this.buttonWelcomCancel.Location = new System.Drawing.Point(480, 282); 321 | this.buttonWelcomCancel.Name = "buttonWelcomCancel"; 322 | this.buttonWelcomCancel.Size = new System.Drawing.Size(100, 29); 323 | this.buttonWelcomCancel.TabIndex = 26; 324 | this.buttonWelcomCancel.Text = "退出"; 325 | this.buttonWelcomCancel.UseVisualStyleBackColor = true; 326 | this.buttonWelcomCancel.Click += new System.EventHandler(this.buttonCancel_Click); 327 | // 328 | // buttonWelcomeNext 329 | // 330 | this.buttonWelcomeNext.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 331 | this.buttonWelcomeNext.Enabled = false; 332 | this.buttonWelcomeNext.Location = new System.Drawing.Point(374, 282); 333 | this.buttonWelcomeNext.Name = "buttonWelcomeNext"; 334 | this.buttonWelcomeNext.Size = new System.Drawing.Size(100, 29); 335 | this.buttonWelcomeNext.TabIndex = 25; 336 | this.buttonWelcomeNext.Text = "下一步"; 337 | this.buttonWelcomeNext.UseVisualStyleBackColor = true; 338 | this.buttonWelcomeNext.Click += new System.EventHandler(this.buttonWelcomeNext_Click); 339 | // 340 | // labelFolderHelp 341 | // 342 | this.labelFolderHelp.Location = new System.Drawing.Point(31, 194); 343 | this.labelFolderHelp.Name = "labelFolderHelp"; 344 | this.labelFolderHelp.Size = new System.Drawing.Size(424, 38); 345 | this.labelFolderHelp.TabIndex = 2; 346 | this.labelFolderHelp.Text = "VS Code的配置大多在特定文件夹下生效,方便您为不同的语言和不同的需求个性化配置。点击下一步以继续。"; 347 | // 348 | // labelFolderHint 349 | // 350 | this.labelFolderHint.AutoSize = true; 351 | this.labelFolderHint.Location = new System.Drawing.Point(31, 111); 352 | this.labelFolderHint.Name = "labelFolderHint"; 353 | this.labelFolderHint.Size = new System.Drawing.Size(427, 15); 354 | this.labelFolderHint.TabIndex = 1; 355 | this.labelFolderHint.Text = "请选择一个工作文件夹。您将来的程序和代码都将存放在此处:"; 356 | // 357 | // labelWelcomeText 358 | // 359 | this.labelWelcomeText.Location = new System.Drawing.Point(31, 57); 360 | this.labelWelcomeText.Name = "labelWelcomeText"; 361 | this.labelWelcomeText.Size = new System.Drawing.Size(422, 36); 362 | this.labelWelcomeText.TabIndex = 0; 363 | this.labelWelcomeText.Text = "欢迎您使用 VS Code C/C++ 配置工具。本工具将帮助您完成 VS Code 的配置。"; 364 | // 365 | // tabPageMinGW 366 | // 367 | this.tabPageMinGW.BackColor = System.Drawing.SystemColors.ControlLightLight; 368 | this.tabPageMinGW.Controls.Add(this.labelMinGWTitle); 369 | this.tabPageMinGW.Controls.Add(this.panelMinGWTable); 370 | this.tabPageMinGW.Controls.Add(this.labelMinGWHint); 371 | this.tabPageMinGW.Controls.Add(this.buttonMinGWPrev); 372 | this.tabPageMinGW.Controls.Add(this.buttonMinGWCancel); 373 | this.tabPageMinGW.Controls.Add(this.buttonMinGWNext); 374 | this.tabPageMinGW.Controls.Add(this.labelMinGWPathHint); 375 | this.tabPageMinGW.Controls.Add(this.buttonViewMinGW); 376 | this.tabPageMinGW.Controls.Add(this.textBoxMinGWPath); 377 | this.tabPageMinGW.Controls.Add(this.linkLabelMinGW); 378 | this.tabPageMinGW.Controls.Add(this.labelMinGWState); 379 | this.tabPageMinGW.Location = new System.Drawing.Point(4, 24); 380 | this.tabPageMinGW.Name = "tabPageMinGW"; 381 | this.tabPageMinGW.Padding = new System.Windows.Forms.Padding(3); 382 | this.tabPageMinGW.Size = new System.Drawing.Size(586, 317); 383 | this.tabPageMinGW.TabIndex = 1; 384 | // 385 | // labelMinGWTitle 386 | // 387 | this.labelMinGWTitle.AutoSize = true; 388 | this.labelMinGWTitle.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); 389 | this.labelMinGWTitle.Location = new System.Drawing.Point(28, 3); 390 | this.labelMinGWTitle.Name = "labelMinGWTitle"; 391 | this.labelMinGWTitle.Size = new System.Drawing.Size(162, 32); 392 | this.labelMinGWTitle.TabIndex = 33; 393 | this.labelMinGWTitle.Text = "配置 MinGW"; 394 | // 395 | // panelMinGWTable 396 | // 397 | this.panelMinGWTable.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 398 | | System.Windows.Forms.AnchorStyles.Left) 399 | | System.Windows.Forms.AnchorStyles.Right))); 400 | this.panelMinGWTable.Controls.Add(this.buttonMinGWAdd); 401 | this.panelMinGWTable.Controls.Add(this.listViewMinGW); 402 | this.panelMinGWTable.Location = new System.Drawing.Point(26, 100); 403 | this.panelMinGWTable.Name = "panelMinGWTable"; 404 | this.panelMinGWTable.Size = new System.Drawing.Size(541, 182); 405 | this.panelMinGWTable.TabIndex = 32; 406 | this.panelMinGWTable.Visible = false; 407 | // 408 | // buttonMinGWAdd 409 | // 410 | this.buttonMinGWAdd.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 411 | this.buttonMinGWAdd.Location = new System.Drawing.Point(2, 153); 412 | this.buttonMinGWAdd.Name = "buttonMinGWAdd"; 413 | this.buttonMinGWAdd.Size = new System.Drawing.Size(104, 23); 414 | this.buttonMinGWAdd.TabIndex = 32; 415 | this.buttonMinGWAdd.Text = "添加..."; 416 | this.buttonMinGWAdd.UseVisualStyleBackColor = true; 417 | this.buttonMinGWAdd.Click += new System.EventHandler(this.buttonMinGWAdd_Click); 418 | // 419 | // listViewMinGW 420 | // 421 | this.listViewMinGW.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 422 | | System.Windows.Forms.AnchorStyles.Left) 423 | | System.Windows.Forms.AnchorStyles.Right))); 424 | this.listViewMinGW.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] { 425 | this.columnHeaderName, 426 | this.columnHeaderPath, 427 | this.columnHeaderVersion}); 428 | this.listViewMinGW.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 429 | this.listViewMinGW.FullRowSelect = true; 430 | this.listViewMinGW.HideSelection = false; 431 | this.listViewMinGW.Location = new System.Drawing.Point(3, 5); 432 | this.listViewMinGW.MultiSelect = false; 433 | this.listViewMinGW.Name = "listViewMinGW"; 434 | this.listViewMinGW.ShowItemToolTips = true; 435 | this.listViewMinGW.Size = new System.Drawing.Size(528, 142); 436 | this.listViewMinGW.TabIndex = 31; 437 | this.listViewMinGW.UseCompatibleStateImageBehavior = false; 438 | this.listViewMinGW.View = System.Windows.Forms.View.Details; 439 | this.listViewMinGW.SelectedIndexChanged += new System.EventHandler(this.listViewMinGW_SelectedIndexChanged); 440 | // 441 | // columnHeaderName 442 | // 443 | this.columnHeaderName.Text = "编译环境名称"; 444 | this.columnHeaderName.Width = 145; 445 | // 446 | // columnHeaderPath 447 | // 448 | this.columnHeaderPath.Text = "路径"; 449 | this.columnHeaderPath.Width = 256; 450 | // 451 | // columnHeaderVersion 452 | // 453 | this.columnHeaderVersion.Text = "版本信息"; 454 | this.columnHeaderVersion.Width = 200; 455 | // 456 | // labelMinGWHint 457 | // 458 | this.labelMinGWHint.Location = new System.Drawing.Point(25, 55); 459 | this.labelMinGWHint.Name = "labelMinGWHint"; 460 | this.labelMinGWHint.Size = new System.Drawing.Size(456, 42); 461 | this.labelMinGWHint.TabIndex = 30; 462 | this.labelMinGWHint.Text = "您还没有安装 MinGW,请您点击右侧链接下载。"; 463 | // 464 | // buttonMinGWPrev 465 | // 466 | this.buttonMinGWPrev.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 467 | this.buttonMinGWPrev.Location = new System.Drawing.Point(268, 282); 468 | this.buttonMinGWPrev.Name = "buttonMinGWPrev"; 469 | this.buttonMinGWPrev.Size = new System.Drawing.Size(100, 29); 470 | this.buttonMinGWPrev.TabIndex = 29; 471 | this.buttonMinGWPrev.Text = "上一步"; 472 | this.buttonMinGWPrev.UseVisualStyleBackColor = true; 473 | this.buttonMinGWPrev.Click += new System.EventHandler(this.buttonPrev_Click); 474 | // 475 | // buttonMinGWCancel 476 | // 477 | this.buttonMinGWCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 478 | this.buttonMinGWCancel.Location = new System.Drawing.Point(480, 282); 479 | this.buttonMinGWCancel.Name = "buttonMinGWCancel"; 480 | this.buttonMinGWCancel.Size = new System.Drawing.Size(100, 29); 481 | this.buttonMinGWCancel.TabIndex = 28; 482 | this.buttonMinGWCancel.Text = "退出"; 483 | this.buttonMinGWCancel.UseVisualStyleBackColor = true; 484 | this.buttonMinGWCancel.Click += new System.EventHandler(this.buttonCancel_Click); 485 | // 486 | // buttonMinGWNext 487 | // 488 | this.buttonMinGWNext.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 489 | this.buttonMinGWNext.Enabled = false; 490 | this.buttonMinGWNext.Location = new System.Drawing.Point(374, 282); 491 | this.buttonMinGWNext.Name = "buttonMinGWNext"; 492 | this.buttonMinGWNext.Size = new System.Drawing.Size(100, 29); 493 | this.buttonMinGWNext.TabIndex = 27; 494 | this.buttonMinGWNext.Text = "下一步"; 495 | this.buttonMinGWNext.UseVisualStyleBackColor = true; 496 | this.buttonMinGWNext.Click += new System.EventHandler(this.buttonMinGWNext_Click); 497 | // 498 | // tabPageCode 499 | // 500 | this.tabPageCode.BackColor = System.Drawing.SystemColors.ControlLightLight; 501 | this.tabPageCode.Controls.Add(this.labelCodeTitle); 502 | this.tabPageCode.Controls.Add(this.labelExtensionHint); 503 | this.tabPageCode.Controls.Add(this.buttonRefresh); 504 | this.tabPageCode.Controls.Add(this.labelCodeHint); 505 | this.tabPageCode.Controls.Add(this.buttonCodePrev); 506 | this.tabPageCode.Controls.Add(this.buttonCodeCancel); 507 | this.tabPageCode.Controls.Add(this.buttonCodeNext); 508 | this.tabPageCode.Controls.Add(this.linkLabelVSCode); 509 | this.tabPageCode.Controls.Add(this.buttonExtension); 510 | this.tabPageCode.Location = new System.Drawing.Point(4, 24); 511 | this.tabPageCode.Name = "tabPageCode"; 512 | this.tabPageCode.Padding = new System.Windows.Forms.Padding(3); 513 | this.tabPageCode.Size = new System.Drawing.Size(586, 317); 514 | this.tabPageCode.TabIndex = 3; 515 | // 516 | // labelCodeTitle 517 | // 518 | this.labelCodeTitle.AutoSize = true; 519 | this.labelCodeTitle.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); 520 | this.labelCodeTitle.Location = new System.Drawing.Point(28, 3); 521 | this.labelCodeTitle.Name = "labelCodeTitle"; 522 | this.labelCodeTitle.Size = new System.Drawing.Size(255, 32); 523 | this.labelCodeTitle.TabIndex = 34; 524 | this.labelCodeTitle.Text = "安装 VS Code 和扩展"; 525 | // 526 | // labelExtensionHint 527 | // 528 | this.labelExtensionHint.Location = new System.Drawing.Point(146, 191); 529 | this.labelExtensionHint.Name = "labelExtensionHint"; 530 | this.labelExtensionHint.Size = new System.Drawing.Size(292, 45); 531 | this.labelExtensionHint.TabIndex = 33; 532 | this.labelExtensionHint.Text = "请点击左侧按钮安装 C/C++ 扩展。"; 533 | // 534 | // buttonRefresh 535 | // 536 | this.buttonRefresh.Location = new System.Drawing.Point(39, 90); 537 | this.buttonRefresh.Name = "buttonRefresh"; 538 | this.buttonRefresh.Size = new System.Drawing.Size(100, 29); 539 | this.buttonRefresh.TabIndex = 32; 540 | this.buttonRefresh.Text = "刷新"; 541 | this.buttonRefresh.UseVisualStyleBackColor = true; 542 | this.buttonRefresh.Click += new System.EventHandler(this.buttonRefresh_Click); 543 | // 544 | // labelCodeHint 545 | // 546 | this.labelCodeHint.Location = new System.Drawing.Point(145, 90); 547 | this.labelCodeHint.Name = "labelCodeHint"; 548 | this.labelCodeHint.Size = new System.Drawing.Size(293, 67); 549 | this.labelCodeHint.TabIndex = 31; 550 | this.labelCodeHint.Text = "未检测到已安装的 VS Code。请点击右侧地址下载安装。"; 551 | // 552 | // buttonCodePrev 553 | // 554 | this.buttonCodePrev.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 555 | this.buttonCodePrev.Location = new System.Drawing.Point(268, 282); 556 | this.buttonCodePrev.Name = "buttonCodePrev"; 557 | this.buttonCodePrev.Size = new System.Drawing.Size(100, 29); 558 | this.buttonCodePrev.TabIndex = 29; 559 | this.buttonCodePrev.Text = "上一步"; 560 | this.buttonCodePrev.UseVisualStyleBackColor = true; 561 | this.buttonCodePrev.Click += new System.EventHandler(this.buttonPrev_Click); 562 | // 563 | // buttonCodeCancel 564 | // 565 | this.buttonCodeCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 566 | this.buttonCodeCancel.Location = new System.Drawing.Point(480, 282); 567 | this.buttonCodeCancel.Name = "buttonCodeCancel"; 568 | this.buttonCodeCancel.Size = new System.Drawing.Size(100, 29); 569 | this.buttonCodeCancel.TabIndex = 28; 570 | this.buttonCodeCancel.Text = "退出"; 571 | this.buttonCodeCancel.UseVisualStyleBackColor = true; 572 | this.buttonCodeCancel.Click += new System.EventHandler(this.buttonCancel_Click); 573 | // 574 | // buttonCodeNext 575 | // 576 | this.buttonCodeNext.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 577 | this.buttonCodeNext.Enabled = false; 578 | this.buttonCodeNext.Location = new System.Drawing.Point(374, 282); 579 | this.buttonCodeNext.Name = "buttonCodeNext"; 580 | this.buttonCodeNext.Size = new System.Drawing.Size(100, 29); 581 | this.buttonCodeNext.TabIndex = 27; 582 | this.buttonCodeNext.Text = "下一步"; 583 | this.buttonCodeNext.UseVisualStyleBackColor = true; 584 | this.buttonCodeNext.Click += new System.EventHandler(this.buttonCodeNext_Click); 585 | // 586 | // tabPageStyle 587 | // 588 | this.tabPageStyle.BackColor = System.Drawing.SystemColors.ControlLightLight; 589 | this.tabPageStyle.Controls.Add(this.pictureBoxExternal); 590 | this.tabPageStyle.Controls.Add(this.pictureBoxInternal); 591 | this.tabPageStyle.Controls.Add(this.labelExternalHint); 592 | this.tabPageStyle.Controls.Add(this.labelInternalHint); 593 | this.tabPageStyle.Controls.Add(this.radioButtonExternal); 594 | this.tabPageStyle.Controls.Add(this.radioButtonInternal); 595 | this.tabPageStyle.Controls.Add(this.labelStyleTitle); 596 | this.tabPageStyle.Controls.Add(this.buttonConfigPrev); 597 | this.tabPageStyle.Controls.Add(this.buttonConfigCancel); 598 | this.tabPageStyle.Controls.Add(this.buttonConfigNext); 599 | this.tabPageStyle.Location = new System.Drawing.Point(4, 24); 600 | this.tabPageStyle.Name = "tabPageStyle"; 601 | this.tabPageStyle.Padding = new System.Windows.Forms.Padding(3); 602 | this.tabPageStyle.Size = new System.Drawing.Size(586, 317); 603 | this.tabPageStyle.TabIndex = 4; 604 | // 605 | // pictureBoxExternal 606 | // 607 | this.pictureBoxExternal.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 608 | this.pictureBoxExternal.Image = ((System.Drawing.Image)(resources.GetObject("pictureBoxExternal.Image"))); 609 | this.pictureBoxExternal.Location = new System.Drawing.Point(461, 164); 610 | this.pictureBoxExternal.Name = "pictureBoxExternal"; 611 | this.pictureBoxExternal.Size = new System.Drawing.Size(100, 100); 612 | this.pictureBoxExternal.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; 613 | this.pictureBoxExternal.TabIndex = 41; 614 | this.pictureBoxExternal.TabStop = false; 615 | // 616 | // pictureBoxInternal 617 | // 618 | this.pictureBoxInternal.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 619 | this.pictureBoxInternal.Image = ((System.Drawing.Image)(resources.GetObject("pictureBoxInternal.Image"))); 620 | this.pictureBoxInternal.Location = new System.Drawing.Point(461, 38); 621 | this.pictureBoxInternal.Name = "pictureBoxInternal"; 622 | this.pictureBoxInternal.Size = new System.Drawing.Size(100, 100); 623 | this.pictureBoxInternal.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; 624 | this.pictureBoxInternal.TabIndex = 40; 625 | this.pictureBoxInternal.TabStop = false; 626 | // 627 | // labelExternalHint 628 | // 629 | this.labelExternalHint.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 630 | | System.Windows.Forms.AnchorStyles.Right))); 631 | this.labelExternalHint.Location = new System.Drawing.Point(33, 186); 632 | this.labelExternalHint.Name = "labelExternalHint"; 633 | this.labelExternalHint.Size = new System.Drawing.Size(419, 93); 634 | this.labelExternalHint.TabIndex = 39; 635 | this.labelExternalHint.Text = "弹出窗口说明"; 636 | // 637 | // labelInternalHint 638 | // 639 | this.labelInternalHint.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 640 | | System.Windows.Forms.AnchorStyles.Right))); 641 | this.labelInternalHint.Location = new System.Drawing.Point(33, 60); 642 | this.labelInternalHint.Name = "labelInternalHint"; 643 | this.labelInternalHint.Size = new System.Drawing.Size(419, 101); 644 | this.labelInternalHint.TabIndex = 38; 645 | this.labelInternalHint.Text = "内置终端说明"; 646 | // 647 | // radioButtonExternal 648 | // 649 | this.radioButtonExternal.AutoSize = true; 650 | this.radioButtonExternal.Location = new System.Drawing.Point(36, 164); 651 | this.radioButtonExternal.Name = "radioButtonExternal"; 652 | this.radioButtonExternal.Size = new System.Drawing.Size(223, 19); 653 | this.radioButtonExternal.TabIndex = 37; 654 | this.radioButtonExternal.Text = "外部弹窗样式(实验性功能)"; 655 | this.radioButtonExternal.UseVisualStyleBackColor = true; 656 | // 657 | // radioButtonInternal 658 | // 659 | this.radioButtonInternal.AutoSize = true; 660 | this.radioButtonInternal.Checked = true; 661 | this.radioButtonInternal.Location = new System.Drawing.Point(36, 38); 662 | this.radioButtonInternal.Name = "radioButtonInternal"; 663 | this.radioButtonInternal.Size = new System.Drawing.Size(118, 19); 664 | this.radioButtonInternal.TabIndex = 36; 665 | this.radioButtonInternal.TabStop = true; 666 | this.radioButtonInternal.Text = "内部终端样式"; 667 | this.radioButtonInternal.UseVisualStyleBackColor = true; 668 | // 669 | // labelStyleTitle 670 | // 671 | this.labelStyleTitle.AutoSize = true; 672 | this.labelStyleTitle.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); 673 | this.labelStyleTitle.Location = new System.Drawing.Point(28, 3); 674 | this.labelStyleTitle.Name = "labelStyleTitle"; 675 | this.labelStyleTitle.Size = new System.Drawing.Size(215, 32); 676 | this.labelStyleTitle.TabIndex = 35; 677 | this.labelStyleTitle.Text = "选择您喜欢的样式"; 678 | // 679 | // buttonConfigPrev 680 | // 681 | this.buttonConfigPrev.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 682 | this.buttonConfigPrev.Location = new System.Drawing.Point(268, 282); 683 | this.buttonConfigPrev.Name = "buttonConfigPrev"; 684 | this.buttonConfigPrev.Size = new System.Drawing.Size(100, 29); 685 | this.buttonConfigPrev.TabIndex = 29; 686 | this.buttonConfigPrev.Text = "上一步"; 687 | this.buttonConfigPrev.UseVisualStyleBackColor = true; 688 | this.buttonConfigPrev.Click += new System.EventHandler(this.buttonPrev_Click); 689 | // 690 | // buttonConfigCancel 691 | // 692 | this.buttonConfigCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 693 | this.buttonConfigCancel.Location = new System.Drawing.Point(480, 282); 694 | this.buttonConfigCancel.Name = "buttonConfigCancel"; 695 | this.buttonConfigCancel.Size = new System.Drawing.Size(100, 29); 696 | this.buttonConfigCancel.TabIndex = 28; 697 | this.buttonConfigCancel.Text = "退出"; 698 | this.buttonConfigCancel.UseVisualStyleBackColor = true; 699 | this.buttonConfigCancel.Click += new System.EventHandler(this.buttonCancel_Click); 700 | // 701 | // buttonConfigNext 702 | // 703 | this.buttonConfigNext.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 704 | this.buttonConfigNext.Location = new System.Drawing.Point(374, 282); 705 | this.buttonConfigNext.Name = "buttonConfigNext"; 706 | this.buttonConfigNext.Size = new System.Drawing.Size(100, 29); 707 | this.buttonConfigNext.TabIndex = 27; 708 | this.buttonConfigNext.Text = "下一步"; 709 | this.buttonConfigNext.UseVisualStyleBackColor = true; 710 | this.buttonConfigNext.Click += new System.EventHandler(this.buttonConfigNext_Click); 711 | // 712 | // tabPageFinish 713 | // 714 | this.tabPageFinish.BackColor = System.Drawing.SystemColors.ControlLightLight; 715 | this.tabPageFinish.Controls.Add(this.checkBoxHitCount); 716 | this.tabPageFinish.Controls.Add(this.checkBoxDesktopShortcut); 717 | this.tabPageFinish.Controls.Add(this.labelFinishHint); 718 | this.tabPageFinish.Controls.Add(this.labelFinishTitle); 719 | this.tabPageFinish.Controls.Add(this.checkBoxGenTest); 720 | this.tabPageFinish.Controls.Add(this.checkBoxOpen); 721 | this.tabPageFinish.Controls.Add(this.buttonFinishAll); 722 | this.tabPageFinish.Location = new System.Drawing.Point(4, 24); 723 | this.tabPageFinish.Name = "tabPageFinish"; 724 | this.tabPageFinish.Size = new System.Drawing.Size(586, 317); 725 | this.tabPageFinish.TabIndex = 5; 726 | // 727 | // checkBoxHitCount 728 | // 729 | this.checkBoxHitCount.AutoSize = true; 730 | this.checkBoxHitCount.Checked = true; 731 | this.checkBoxHitCount.CheckState = System.Windows.Forms.CheckState.Checked; 732 | this.checkBoxHitCount.Location = new System.Drawing.Point(34, 288); 733 | this.checkBoxHitCount.Name = "checkBoxHitCount"; 734 | this.checkBoxHitCount.Size = new System.Drawing.Size(119, 19); 735 | this.checkBoxHitCount.TabIndex = 39; 736 | this.checkBoxHitCount.Text = "发送统计数据"; 737 | this.checkBoxHitCount.UseVisualStyleBackColor = true; 738 | // 739 | // checkBoxDesktopShortcut 740 | // 741 | this.checkBoxDesktopShortcut.AutoSize = true; 742 | this.checkBoxDesktopShortcut.Location = new System.Drawing.Point(34, 158); 743 | this.checkBoxDesktopShortcut.Name = "checkBoxDesktopShortcut"; 744 | this.checkBoxDesktopShortcut.Size = new System.Drawing.Size(299, 19); 745 | this.checkBoxDesktopShortcut.TabIndex = 38; 746 | this.checkBoxDesktopShortcut.Text = "创建桌面快捷方式(建议“小白”勾选)"; 747 | this.checkBoxDesktopShortcut.UseVisualStyleBackColor = true; 748 | // 749 | // labelFinishHint 750 | // 751 | this.labelFinishHint.AutoSize = true; 752 | this.labelFinishHint.Location = new System.Drawing.Point(25, 53); 753 | this.labelFinishHint.Name = "labelFinishHint"; 754 | this.labelFinishHint.Size = new System.Drawing.Size(217, 15); 755 | this.labelFinishHint.TabIndex = 37; 756 | this.labelFinishHint.Text = "恭喜您,您已成功完成了配置。"; 757 | // 758 | // labelFinishTitle 759 | // 760 | this.labelFinishTitle.AutoSize = true; 761 | this.labelFinishTitle.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); 762 | this.labelFinishTitle.Location = new System.Drawing.Point(28, 3); 763 | this.labelFinishTitle.Name = "labelFinishTitle"; 764 | this.labelFinishTitle.Size = new System.Drawing.Size(165, 32); 765 | this.labelFinishTitle.TabIndex = 36; 766 | this.labelFinishTitle.Text = "配置成功完成"; 767 | // 768 | // buttonFinishAll 769 | // 770 | this.buttonFinishAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 771 | this.buttonFinishAll.Location = new System.Drawing.Point(374, 282); 772 | this.buttonFinishAll.Name = "buttonFinishAll"; 773 | this.buttonFinishAll.Size = new System.Drawing.Size(100, 29); 774 | this.buttonFinishAll.TabIndex = 30; 775 | this.buttonFinishAll.Text = "完成"; 776 | this.buttonFinishAll.UseVisualStyleBackColor = true; 777 | this.buttonFinishAll.Click += new System.EventHandler(this.buttonFinishAll_Click); 778 | // 779 | // buttonSettings 780 | // 781 | this.buttonSettings.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 782 | this.buttonSettings.Location = new System.Drawing.Point(30, 328); 783 | this.buttonSettings.Name = "buttonSettings"; 784 | this.buttonSettings.Size = new System.Drawing.Size(120, 29); 785 | this.buttonSettings.TabIndex = 2; 786 | this.buttonSettings.Text = "设置"; 787 | this.buttonSettings.UseVisualStyleBackColor = true; 788 | this.buttonSettings.Click += new System.EventHandler(this.buttonSettings_Click); 789 | // 790 | // panelNavigate 791 | // 792 | this.panelNavigate.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 793 | | System.Windows.Forms.AnchorStyles.Left))); 794 | this.panelNavigate.Location = new System.Drawing.Point(30, 157); 795 | this.panelNavigate.Name = "panelNavigate"; 796 | this.panelNavigate.Size = new System.Drawing.Size(120, 165); 797 | this.panelNavigate.TabIndex = 5; 798 | this.panelNavigate.Paint += new System.Windows.Forms.PaintEventHandler(this.panelNavigate_Paint); 799 | // 800 | // pictureBoxLogo 801 | // 802 | this.pictureBoxLogo.Image = ((System.Drawing.Image)(resources.GetObject("pictureBoxLogo.Image"))); 803 | this.pictureBoxLogo.Location = new System.Drawing.Point(30, 12); 804 | this.pictureBoxLogo.Name = "pictureBoxLogo"; 805 | this.pictureBoxLogo.Size = new System.Drawing.Size(120, 120); 806 | this.pictureBoxLogo.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom; 807 | this.pictureBoxLogo.TabIndex = 6; 808 | this.pictureBoxLogo.TabStop = false; 809 | // 810 | // Form1 811 | // 812 | this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F); 813 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 814 | this.ClientSize = new System.Drawing.Size(781, 396); 815 | this.Controls.Add(this.pictureBoxLogo); 816 | this.Controls.Add(this.panelNavigate); 817 | this.Controls.Add(this.linkLabelManual); 818 | this.Controls.Add(this.buttonSettings); 819 | this.Controls.Add(this.tabControlMain); 820 | this.Controls.Add(this.labelAuthor); 821 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; 822 | this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); 823 | this.Margin = new System.Windows.Forms.Padding(4); 824 | this.MaximizeBox = false; 825 | this.MinimizeBox = false; 826 | this.Name = "Form1"; 827 | this.Text = "VS Code C++配置工具"; 828 | this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.Form1_FormClosing); 829 | this.Load += new System.EventHandler(this.Form1_Load); 830 | this.tabControlMain.ResumeLayout(false); 831 | this.tabPageWelcome.ResumeLayout(false); 832 | this.tabPageWelcome.PerformLayout(); 833 | this.tabPageMinGW.ResumeLayout(false); 834 | this.tabPageMinGW.PerformLayout(); 835 | this.panelMinGWTable.ResumeLayout(false); 836 | this.tabPageCode.ResumeLayout(false); 837 | this.tabPageCode.PerformLayout(); 838 | this.tabPageStyle.ResumeLayout(false); 839 | this.tabPageStyle.PerformLayout(); 840 | ((System.ComponentModel.ISupportInitialize)(this.pictureBoxExternal)).EndInit(); 841 | ((System.ComponentModel.ISupportInitialize)(this.pictureBoxInternal)).EndInit(); 842 | this.tabPageFinish.ResumeLayout(false); 843 | this.tabPageFinish.PerformLayout(); 844 | ((System.ComponentModel.ISupportInitialize)(this.pictureBoxLogo)).EndInit(); 845 | this.ResumeLayout(false); 846 | this.PerformLayout(); 847 | 848 | } 849 | 850 | #endregion 851 | private System.Windows.Forms.TextBox textBoxMinGWPath; 852 | private System.Windows.Forms.Button buttonViewMinGW; 853 | private System.Windows.Forms.FolderBrowserDialog folderBrowserDialog1; 854 | private System.Windows.Forms.Label labelMinGWState; 855 | private System.Windows.Forms.Button buttonExtension; 856 | private System.Windows.Forms.Label labelMinGWPathHint; 857 | private System.Windows.Forms.LinkLabel linkLabelVSCode; 858 | private System.Windows.Forms.LinkLabel linkLabelMinGW; 859 | private System.Windows.Forms.Button buttonViewWorkspace; 860 | private System.Windows.Forms.TextBox textBoxWorkspacePath; 861 | private System.Windows.Forms.Label labelAuthor; 862 | private System.Windows.Forms.LinkLabel linkLabelManual; 863 | private System.Windows.Forms.Label labelWorkspaceStatus; 864 | private System.Windows.Forms.CheckBox checkBoxOpen; 865 | private System.Windows.Forms.CheckBox checkBoxGenTest; 866 | private System.Windows.Forms.TabControl tabControlMain; 867 | private System.Windows.Forms.TabPage tabPageWelcome; 868 | private System.Windows.Forms.TabPage tabPageMinGW; 869 | private System.Windows.Forms.Label labelFolderHelp; 870 | private System.Windows.Forms.Label labelFolderHint; 871 | private System.Windows.Forms.Label labelWelcomeText; 872 | private System.Windows.Forms.Button buttonWelcomCancel; 873 | private System.Windows.Forms.Button buttonWelcomeNext; 874 | private System.Windows.Forms.Label labelMinGWHint; 875 | private System.Windows.Forms.Button buttonMinGWPrev; 876 | private System.Windows.Forms.Button buttonMinGWCancel; 877 | private System.Windows.Forms.Button buttonMinGWNext; 878 | private System.Windows.Forms.TabPage tabPageCode; 879 | private System.Windows.Forms.Button buttonCodePrev; 880 | private System.Windows.Forms.Button buttonCodeCancel; 881 | private System.Windows.Forms.Button buttonCodeNext; 882 | private System.Windows.Forms.TabPage tabPageStyle; 883 | private System.Windows.Forms.Button buttonConfigPrev; 884 | private System.Windows.Forms.Button buttonConfigCancel; 885 | private System.Windows.Forms.Button buttonConfigNext; 886 | private System.Windows.Forms.ListView listViewMinGW; 887 | private System.Windows.Forms.ColumnHeader columnHeaderName; 888 | private System.Windows.Forms.ColumnHeader columnHeaderPath; 889 | private System.Windows.Forms.ColumnHeader columnHeaderVersion; 890 | private System.Windows.Forms.Panel panelMinGWTable; 891 | private System.Windows.Forms.Button buttonMinGWAdd; 892 | private System.Windows.Forms.Label labelCodeHint; 893 | private System.Windows.Forms.TabPage tabPageFinish; 894 | private System.Windows.Forms.Button buttonFinishAll; 895 | private System.Windows.Forms.Button buttonSettings; 896 | private System.Windows.Forms.Button buttonRefresh; 897 | private System.Windows.Forms.Label labelWelcomeTitle; 898 | private System.Windows.Forms.Label labelMinGWTitle; 899 | private System.Windows.Forms.Label labelExtensionHint; 900 | private System.Windows.Forms.Label labelCodeTitle; 901 | private System.Windows.Forms.Label labelStyleTitle; 902 | private System.Windows.Forms.Label labelFinishHint; 903 | private System.Windows.Forms.Label labelFinishTitle; 904 | private System.Windows.Forms.Panel panelNavigate; 905 | private System.Windows.Forms.RadioButton radioButtonExternal; 906 | private System.Windows.Forms.RadioButton radioButtonInternal; 907 | private System.Windows.Forms.Label labelExternalHint; 908 | private System.Windows.Forms.Label labelInternalHint; 909 | private System.Windows.Forms.PictureBox pictureBoxExternal; 910 | private System.Windows.Forms.PictureBox pictureBoxInternal; 911 | private System.Windows.Forms.PictureBox pictureBoxLogo; 912 | private System.Windows.Forms.CheckBox checkBoxDesktopShortcut; 913 | private System.Windows.Forms.OpenFileDialog openFileDialog1; 914 | private System.Windows.Forms.CheckBox checkBoxHitCount; 915 | } 916 | } 917 | 918 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/FormSettings.Designer.cs: -------------------------------------------------------------------------------- 1 | namespace VSCodeConfigHelper 2 | { 3 | partial class FormSettings 4 | { 5 | /// 6 | /// Required designer variable. 7 | /// 8 | private System.ComponentModel.IContainer components = null; 9 | 10 | /// 11 | /// Clean up any resources being used. 12 | /// 13 | /// true if managed resources should be disposed; otherwise, false. 14 | protected override void Dispose(bool disposing) 15 | { 16 | if (disposing && (components != null)) 17 | { 18 | components.Dispose(); 19 | } 20 | base.Dispose(disposing); 21 | } 22 | 23 | #region Windows Form Designer generated code 24 | 25 | /// 26 | /// Required method for Designer support - do not modify 27 | /// the contents of this method with the code editor. 28 | /// 29 | private void InitializeComponent() 30 | { 31 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FormSettings)); 32 | this.groupBoxPrivil = new System.Windows.Forms.GroupBox(); 33 | this.buttonAuth = new System.Windows.Forms.Button(); 34 | this.labelAuth = new System.Windows.Forms.Label(); 35 | this.groupBoxArg = new System.Windows.Forms.GroupBox(); 36 | this.buttonArgDefault = new System.Windows.Forms.Button(); 37 | this.labelArgInstruction = new System.Windows.Forms.Label(); 38 | this.buttonSaveArgs = new System.Windows.Forms.Button(); 39 | this.labelArgWarning = new System.Windows.Forms.Label(); 40 | this.textBoxArgs = new System.Windows.Forms.TextBox(); 41 | this.groupBoxMinGWSrc = new System.Windows.Forms.GroupBox(); 42 | this.labelMinGWSrcInstruction = new System.Windows.Forms.Label(); 43 | this.radioButtonOffical = new System.Windows.Forms.RadioButton(); 44 | this.radioButtonDisk = new System.Windows.Forms.RadioButton(); 45 | this.linkLabelLicense = new System.Windows.Forms.LinkLabel(); 46 | this.pictureGitHub = new System.Windows.Forms.PictureBox(); 47 | this.tabControlSettings = new System.Windows.Forms.TabControl(); 48 | this.tabPageDownload = new System.Windows.Forms.TabPage(); 49 | this.groupBoxMinGWDistro = new System.Windows.Forms.GroupBox(); 50 | this.linkLabelTDM = new System.Windows.Forms.LinkLabel(); 51 | this.linkLabelMinGWw64 = new System.Windows.Forms.LinkLabel(); 52 | this.labelDistroHint = new System.Windows.Forms.Label(); 53 | this.radioButtonOfficial = new System.Windows.Forms.RadioButton(); 54 | this.radioButtonGytx = new System.Windows.Forms.RadioButton(); 55 | this.radioButtonTDM = new System.Windows.Forms.RadioButton(); 56 | this.tabPageInstall = new System.Windows.Forms.TabPage(); 57 | this.buttonUpdate = new System.Windows.Forms.Button(); 58 | this.tabPageConfig = new System.Windows.Forms.TabPage(); 59 | this.groupBoxStandard = new System.Windows.Forms.GroupBox(); 60 | this.labelStandard = new System.Windows.Forms.Label(); 61 | this.labelLang = new System.Windows.Forms.Label(); 62 | this.comboBoxLang = new System.Windows.Forms.ComboBox(); 63 | this.comboBoxStandard = new System.Windows.Forms.ComboBox(); 64 | this.groupBoxPrivil.SuspendLayout(); 65 | this.groupBoxArg.SuspendLayout(); 66 | this.groupBoxMinGWSrc.SuspendLayout(); 67 | ((System.ComponentModel.ISupportInitialize)(this.pictureGitHub)).BeginInit(); 68 | this.tabControlSettings.SuspendLayout(); 69 | this.tabPageDownload.SuspendLayout(); 70 | this.groupBoxMinGWDistro.SuspendLayout(); 71 | this.tabPageInstall.SuspendLayout(); 72 | this.tabPageConfig.SuspendLayout(); 73 | this.groupBoxStandard.SuspendLayout(); 74 | this.SuspendLayout(); 75 | // 76 | // groupBoxPrivil 77 | // 78 | this.groupBoxPrivil.Controls.Add(this.buttonAuth); 79 | this.groupBoxPrivil.Controls.Add(this.labelAuth); 80 | this.groupBoxPrivil.Location = new System.Drawing.Point(2, 5); 81 | this.groupBoxPrivil.Margin = new System.Windows.Forms.Padding(2); 82 | this.groupBoxPrivil.Name = "groupBoxPrivil"; 83 | this.groupBoxPrivil.Padding = new System.Windows.Forms.Padding(2); 84 | this.groupBoxPrivil.Size = new System.Drawing.Size(308, 132); 85 | this.groupBoxPrivil.TabIndex = 9; 86 | this.groupBoxPrivil.TabStop = false; 87 | this.groupBoxPrivil.Text = "当前权限"; 88 | // 89 | // buttonAuth 90 | // 91 | this.buttonAuth.Location = new System.Drawing.Point(196, 58); 92 | this.buttonAuth.Margin = new System.Windows.Forms.Padding(2); 93 | this.buttonAuth.Name = "buttonAuth"; 94 | this.buttonAuth.Size = new System.Drawing.Size(106, 23); 95 | this.buttonAuth.TabIndex = 0; 96 | this.buttonAuth.Text = "使用管理员身份"; 97 | this.buttonAuth.UseVisualStyleBackColor = true; 98 | this.buttonAuth.Click += new System.EventHandler(this.buttonAuth_Click); 99 | // 100 | // labelAuth 101 | // 102 | this.labelAuth.Location = new System.Drawing.Point(4, 17); 103 | this.labelAuth.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 104 | this.labelAuth.Name = "labelAuth"; 105 | this.labelAuth.Size = new System.Drawing.Size(187, 113); 106 | this.labelAuth.TabIndex = 1; 107 | // 108 | // groupBoxArg 109 | // 110 | this.groupBoxArg.Controls.Add(this.buttonArgDefault); 111 | this.groupBoxArg.Controls.Add(this.labelArgInstruction); 112 | this.groupBoxArg.Controls.Add(this.buttonSaveArgs); 113 | this.groupBoxArg.Controls.Add(this.labelArgWarning); 114 | this.groupBoxArg.Controls.Add(this.textBoxArgs); 115 | this.groupBoxArg.Location = new System.Drawing.Point(2, 54); 116 | this.groupBoxArg.Margin = new System.Windows.Forms.Padding(2); 117 | this.groupBoxArg.Name = "groupBoxArg"; 118 | this.groupBoxArg.Padding = new System.Windows.Forms.Padding(2); 119 | this.groupBoxArg.Size = new System.Drawing.Size(308, 167); 120 | this.groupBoxArg.TabIndex = 8; 121 | this.groupBoxArg.TabStop = false; 122 | this.groupBoxArg.Text = "配置编译参数"; 123 | // 124 | // buttonArgDefault 125 | // 126 | this.buttonArgDefault.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 127 | this.buttonArgDefault.Location = new System.Drawing.Point(4, 139); 128 | this.buttonArgDefault.Margin = new System.Windows.Forms.Padding(2); 129 | this.buttonArgDefault.Name = "buttonArgDefault"; 130 | this.buttonArgDefault.Size = new System.Drawing.Size(63, 23); 131 | this.buttonArgDefault.TabIndex = 2; 132 | this.buttonArgDefault.Text = "恢复默认"; 133 | this.buttonArgDefault.UseVisualStyleBackColor = true; 134 | this.buttonArgDefault.Click += new System.EventHandler(this.buttonArgDefault_Click); 135 | // 136 | // labelArgInstruction 137 | // 138 | this.labelArgInstruction.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 139 | this.labelArgInstruction.Location = new System.Drawing.Point(140, 138); 140 | this.labelArgInstruction.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 141 | this.labelArgInstruction.Name = "labelArgInstruction"; 142 | this.labelArgInstruction.Size = new System.Drawing.Size(170, 24); 143 | this.labelArgInstruction.TabIndex = 5; 144 | this.labelArgInstruction.Text = "每行一个参数;支持 VS Code 配置变量。"; 145 | // 146 | // buttonSaveArgs 147 | // 148 | this.buttonSaveArgs.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 149 | this.buttonSaveArgs.Location = new System.Drawing.Point(72, 139); 150 | this.buttonSaveArgs.Margin = new System.Windows.Forms.Padding(2); 151 | this.buttonSaveArgs.Name = "buttonSaveArgs"; 152 | this.buttonSaveArgs.Size = new System.Drawing.Size(63, 23); 153 | this.buttonSaveArgs.TabIndex = 4; 154 | this.buttonSaveArgs.Text = "保存"; 155 | this.buttonSaveArgs.UseVisualStyleBackColor = true; 156 | this.buttonSaveArgs.Click += new System.EventHandler(this.buttonSaveArgs_Click); 157 | // 158 | // labelArgWarning 159 | // 160 | this.labelArgWarning.AutoSize = true; 161 | this.labelArgWarning.ForeColor = System.Drawing.Color.Red; 162 | this.labelArgWarning.Location = new System.Drawing.Point(4, 17); 163 | this.labelArgWarning.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 164 | this.labelArgWarning.Name = "labelArgWarning"; 165 | this.labelArgWarning.Size = new System.Drawing.Size(293, 12); 166 | this.labelArgWarning.TabIndex = 3; 167 | this.labelArgWarning.Text = "除非您知道自己在做什么,否则不要改动这里的内容。"; 168 | // 169 | // textBoxArgs 170 | // 171 | this.textBoxArgs.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 172 | | System.Windows.Forms.AnchorStyles.Left) 173 | | System.Windows.Forms.AnchorStyles.Right))); 174 | this.textBoxArgs.Location = new System.Drawing.Point(7, 39); 175 | this.textBoxArgs.Margin = new System.Windows.Forms.Padding(2); 176 | this.textBoxArgs.Multiline = true; 177 | this.textBoxArgs.Name = "textBoxArgs"; 178 | this.textBoxArgs.ScrollBars = System.Windows.Forms.ScrollBars.Both; 179 | this.textBoxArgs.Size = new System.Drawing.Size(298, 96); 180 | this.textBoxArgs.TabIndex = 2; 181 | // 182 | // groupBoxMinGWSrc 183 | // 184 | this.groupBoxMinGWSrc.Controls.Add(this.labelMinGWSrcInstruction); 185 | this.groupBoxMinGWSrc.Controls.Add(this.radioButtonOffical); 186 | this.groupBoxMinGWSrc.Controls.Add(this.radioButtonDisk); 187 | this.groupBoxMinGWSrc.Location = new System.Drawing.Point(2, 5); 188 | this.groupBoxMinGWSrc.Margin = new System.Windows.Forms.Padding(2); 189 | this.groupBoxMinGWSrc.Name = "groupBoxMinGWSrc"; 190 | this.groupBoxMinGWSrc.Padding = new System.Windows.Forms.Padding(2); 191 | this.groupBoxMinGWSrc.Size = new System.Drawing.Size(308, 72); 192 | this.groupBoxMinGWSrc.TabIndex = 7; 193 | this.groupBoxMinGWSrc.TabStop = false; 194 | this.groupBoxMinGWSrc.Text = "选择 MinGW 下载源"; 195 | // 196 | // labelMinGWSrcInstruction 197 | // 198 | this.labelMinGWSrcInstruction.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left) 199 | | System.Windows.Forms.AnchorStyles.Right))); 200 | this.labelMinGWSrcInstruction.Location = new System.Drawing.Point(4, 46); 201 | this.labelMinGWSrcInstruction.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 202 | this.labelMinGWSrcInstruction.Name = "labelMinGWSrcInstruction"; 203 | this.labelMinGWSrcInstruction.Size = new System.Drawing.Size(299, 24); 204 | this.labelMinGWSrcInstruction.TabIndex = 2; 205 | this.labelMinGWSrcInstruction.Text = "网盘下载快速稳定,但有可能失效。官方下载长期有效,但速度受网络环境所限制。"; 206 | // 207 | // radioButtonOffical 208 | // 209 | this.radioButtonOffical.AutoSize = true; 210 | this.radioButtonOffical.Location = new System.Drawing.Point(164, 19); 211 | this.radioButtonOffical.Margin = new System.Windows.Forms.Padding(2); 212 | this.radioButtonOffical.Name = "radioButtonOffical"; 213 | this.radioButtonOffical.Size = new System.Drawing.Size(47, 16); 214 | this.radioButtonOffical.TabIndex = 1; 215 | this.radioButtonOffical.Text = "官方"; 216 | this.radioButtonOffical.UseVisualStyleBackColor = true; 217 | // 218 | // radioButtonDisk 219 | // 220 | this.radioButtonDisk.AutoSize = true; 221 | this.radioButtonDisk.Checked = true; 222 | this.radioButtonDisk.Location = new System.Drawing.Point(34, 19); 223 | this.radioButtonDisk.Margin = new System.Windows.Forms.Padding(2); 224 | this.radioButtonDisk.Name = "radioButtonDisk"; 225 | this.radioButtonDisk.Size = new System.Drawing.Size(47, 16); 226 | this.radioButtonDisk.TabIndex = 1; 227 | this.radioButtonDisk.TabStop = true; 228 | this.radioButtonDisk.Text = "网盘"; 229 | this.radioButtonDisk.UseVisualStyleBackColor = true; 230 | // 231 | // linkLabelLicense 232 | // 233 | this.linkLabelLicense.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 234 | this.linkLabelLicense.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline; 235 | this.linkLabelLicense.Location = new System.Drawing.Point(14, 310); 236 | this.linkLabelLicense.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 237 | this.linkLabelLicense.Name = "linkLabelLicense"; 238 | this.linkLabelLicense.Size = new System.Drawing.Size(260, 24); 239 | this.linkLabelLicense.TabIndex = 10; 240 | this.linkLabelLicense.TabStop = true; 241 | this.linkLabelLicense.Text = "VSCodeConfigHelper 是自由软件,你可以基于 GPLv2 协议进行再发行或修改。"; 242 | this.linkLabelLicense.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelLicense_LinkClicked); 243 | // 244 | // pictureGitHub 245 | // 246 | this.pictureGitHub.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 247 | this.pictureGitHub.Cursor = System.Windows.Forms.Cursors.Hand; 248 | this.pictureGitHub.Image = ((System.Drawing.Image)(resources.GetObject("pictureGitHub.Image"))); 249 | this.pictureGitHub.Location = new System.Drawing.Point(287, 299); 250 | this.pictureGitHub.Margin = new System.Windows.Forms.Padding(2); 251 | this.pictureGitHub.Name = "pictureGitHub"; 252 | this.pictureGitHub.Size = new System.Drawing.Size(38, 40); 253 | this.pictureGitHub.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom; 254 | this.pictureGitHub.TabIndex = 11; 255 | this.pictureGitHub.TabStop = false; 256 | this.pictureGitHub.Click += new System.EventHandler(this.pictureGitHub_Click); 257 | // 258 | // tabControlSettings 259 | // 260 | this.tabControlSettings.Controls.Add(this.tabPageDownload); 261 | this.tabControlSettings.Controls.Add(this.tabPageInstall); 262 | this.tabControlSettings.Controls.Add(this.tabPageConfig); 263 | this.tabControlSettings.Location = new System.Drawing.Point(9, 10); 264 | this.tabControlSettings.Margin = new System.Windows.Forms.Padding(2); 265 | this.tabControlSettings.Name = "tabControlSettings"; 266 | this.tabControlSettings.SelectedIndex = 0; 267 | this.tabControlSettings.Size = new System.Drawing.Size(319, 284); 268 | this.tabControlSettings.TabIndex = 12; 269 | // 270 | // tabPageDownload 271 | // 272 | this.tabPageDownload.Controls.Add(this.groupBoxMinGWDistro); 273 | this.tabPageDownload.Controls.Add(this.groupBoxMinGWSrc); 274 | this.tabPageDownload.Location = new System.Drawing.Point(4, 22); 275 | this.tabPageDownload.Margin = new System.Windows.Forms.Padding(2); 276 | this.tabPageDownload.Name = "tabPageDownload"; 277 | this.tabPageDownload.Padding = new System.Windows.Forms.Padding(2); 278 | this.tabPageDownload.Size = new System.Drawing.Size(311, 258); 279 | this.tabPageDownload.TabIndex = 0; 280 | this.tabPageDownload.Text = "下载"; 281 | this.tabPageDownload.UseVisualStyleBackColor = true; 282 | // 283 | // groupBoxMinGWDistro 284 | // 285 | this.groupBoxMinGWDistro.Controls.Add(this.linkLabelTDM); 286 | this.groupBoxMinGWDistro.Controls.Add(this.linkLabelMinGWw64); 287 | this.groupBoxMinGWDistro.Controls.Add(this.labelDistroHint); 288 | this.groupBoxMinGWDistro.Controls.Add(this.radioButtonOfficial); 289 | this.groupBoxMinGWDistro.Controls.Add(this.radioButtonGytx); 290 | this.groupBoxMinGWDistro.Controls.Add(this.radioButtonTDM); 291 | this.groupBoxMinGWDistro.Location = new System.Drawing.Point(2, 82); 292 | this.groupBoxMinGWDistro.Margin = new System.Windows.Forms.Padding(2); 293 | this.groupBoxMinGWDistro.Name = "groupBoxMinGWDistro"; 294 | this.groupBoxMinGWDistro.Padding = new System.Windows.Forms.Padding(2); 295 | this.groupBoxMinGWDistro.Size = new System.Drawing.Size(308, 174); 296 | this.groupBoxMinGWDistro.TabIndex = 8; 297 | this.groupBoxMinGWDistro.TabStop = false; 298 | this.groupBoxMinGWDistro.Text = "MinGW 版本"; 299 | // 300 | // linkLabelTDM 301 | // 302 | this.linkLabelTDM.AutoSize = true; 303 | this.linkLabelTDM.Location = new System.Drawing.Point(238, 50); 304 | this.linkLabelTDM.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 305 | this.linkLabelTDM.Name = "linkLabelTDM"; 306 | this.linkLabelTDM.Size = new System.Drawing.Size(29, 12); 307 | this.linkLabelTDM.TabIndex = 14; 308 | this.linkLabelTDM.TabStop = true; 309 | this.linkLabelTDM.Text = "官网"; 310 | this.linkLabelTDM.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelTDM_LinkClicked); 311 | // 312 | // linkLabelMinGWw64 313 | // 314 | this.linkLabelMinGWw64.AutoSize = true; 315 | this.linkLabelMinGWw64.Location = new System.Drawing.Point(238, 70); 316 | this.linkLabelMinGWw64.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 317 | this.linkLabelMinGWw64.Name = "linkLabelMinGWw64"; 318 | this.linkLabelMinGWw64.Size = new System.Drawing.Size(29, 12); 319 | this.linkLabelMinGWw64.TabIndex = 13; 320 | this.linkLabelMinGWw64.TabStop = true; 321 | this.linkLabelMinGWw64.Text = "官网"; 322 | this.linkLabelMinGWw64.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelMinGWw64_LinkClicked); 323 | // 324 | // labelDistroHint 325 | // 326 | this.labelDistroHint.Location = new System.Drawing.Point(4, 111); 327 | this.labelDistroHint.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 328 | this.labelDistroHint.Name = "labelDistroHint"; 329 | this.labelDistroHint.Size = new System.Drawing.Size(299, 61); 330 | this.labelDistroHint.TabIndex = 12; 331 | this.labelDistroHint.Text = "说明"; 332 | // 333 | // radioButtonOfficial 334 | // 335 | this.radioButtonOfficial.AutoSize = true; 336 | this.radioButtonOfficial.Location = new System.Drawing.Point(34, 69); 337 | this.radioButtonOfficial.Margin = new System.Windows.Forms.Padding(2); 338 | this.radioButtonOfficial.Name = "radioButtonOfficial"; 339 | this.radioButtonOfficial.Size = new System.Drawing.Size(83, 16); 340 | this.radioButtonOfficial.TabIndex = 11; 341 | this.radioButtonOfficial.Text = "官方 8.1.0"; 342 | this.radioButtonOfficial.UseVisualStyleBackColor = true; 343 | this.radioButtonOfficial.CheckedChanged += new System.EventHandler(this.radioButtonWinLibs_CheckedChanged); 344 | // 345 | // radioButtonGytx 346 | // 347 | this.radioButtonGytx.AutoSize = true; 348 | this.radioButtonGytx.Checked = true; 349 | this.radioButtonGytx.Location = new System.Drawing.Point(34, 29); 350 | this.radioButtonGytx.Margin = new System.Windows.Forms.Padding(2); 351 | this.radioButtonGytx.Name = "radioButtonGytx"; 352 | this.radioButtonGytx.Size = new System.Drawing.Size(113, 16); 353 | this.radioButtonGytx.TabIndex = 10; 354 | this.radioButtonGytx.TabStop = true; 355 | this.radioButtonGytx.Text = "谷雨同学 11.1.0"; 356 | this.radioButtonGytx.UseVisualStyleBackColor = true; 357 | this.radioButtonGytx.CheckedChanged += new System.EventHandler(this.radioButtonMinGWw64_CheckedChanged); 358 | // 359 | // radioButtonTDM 360 | // 361 | this.radioButtonTDM.AutoSize = true; 362 | this.radioButtonTDM.Location = new System.Drawing.Point(34, 49); 363 | this.radioButtonTDM.Margin = new System.Windows.Forms.Padding(2); 364 | this.radioButtonTDM.Name = "radioButtonTDM"; 365 | this.radioButtonTDM.Size = new System.Drawing.Size(101, 16); 366 | this.radioButtonTDM.TabIndex = 9; 367 | this.radioButtonTDM.Text = "TDM-GCC 9.2.0"; 368 | this.radioButtonTDM.UseVisualStyleBackColor = true; 369 | this.radioButtonTDM.CheckedChanged += new System.EventHandler(this.radioButtonTDM_CheckedChanged); 370 | // 371 | // tabPageInstall 372 | // 373 | this.tabPageInstall.Controls.Add(this.buttonUpdate); 374 | this.tabPageInstall.Controls.Add(this.groupBoxPrivil); 375 | this.tabPageInstall.Location = new System.Drawing.Point(4, 22); 376 | this.tabPageInstall.Margin = new System.Windows.Forms.Padding(2); 377 | this.tabPageInstall.Name = "tabPageInstall"; 378 | this.tabPageInstall.Padding = new System.Windows.Forms.Padding(2); 379 | this.tabPageInstall.Size = new System.Drawing.Size(311, 258); 380 | this.tabPageInstall.TabIndex = 1; 381 | this.tabPageInstall.Text = "安装"; 382 | this.tabPageInstall.UseVisualStyleBackColor = true; 383 | // 384 | // buttonUpdate 385 | // 386 | this.buttonUpdate.Location = new System.Drawing.Point(94, 195); 387 | this.buttonUpdate.Margin = new System.Windows.Forms.Padding(2); 388 | this.buttonUpdate.Name = "buttonUpdate"; 389 | this.buttonUpdate.Size = new System.Drawing.Size(210, 23); 390 | this.buttonUpdate.TabIndex = 10; 391 | this.buttonUpdate.Text = "检查 VS Code Config Helper 更新"; 392 | this.buttonUpdate.UseVisualStyleBackColor = true; 393 | this.buttonUpdate.Click += new System.EventHandler(this.buttonUpdate_Click); 394 | // 395 | // tabPageConfig 396 | // 397 | this.tabPageConfig.Controls.Add(this.groupBoxStandard); 398 | this.tabPageConfig.Controls.Add(this.groupBoxArg); 399 | this.tabPageConfig.Location = new System.Drawing.Point(4, 22); 400 | this.tabPageConfig.Margin = new System.Windows.Forms.Padding(2); 401 | this.tabPageConfig.Name = "tabPageConfig"; 402 | this.tabPageConfig.Size = new System.Drawing.Size(311, 258); 403 | this.tabPageConfig.TabIndex = 2; 404 | this.tabPageConfig.Text = "配置"; 405 | this.tabPageConfig.UseVisualStyleBackColor = true; 406 | // 407 | // groupBoxStandard 408 | // 409 | this.groupBoxStandard.Controls.Add(this.labelStandard); 410 | this.groupBoxStandard.Controls.Add(this.labelLang); 411 | this.groupBoxStandard.Controls.Add(this.comboBoxLang); 412 | this.groupBoxStandard.Controls.Add(this.comboBoxStandard); 413 | this.groupBoxStandard.Location = new System.Drawing.Point(2, 2); 414 | this.groupBoxStandard.Margin = new System.Windows.Forms.Padding(2); 415 | this.groupBoxStandard.Name = "groupBoxStandard"; 416 | this.groupBoxStandard.Padding = new System.Windows.Forms.Padding(2); 417 | this.groupBoxStandard.Size = new System.Drawing.Size(308, 47); 418 | this.groupBoxStandard.TabIndex = 9; 419 | this.groupBoxStandard.TabStop = false; 420 | this.groupBoxStandard.Text = "设定语言标准"; 421 | // 422 | // labelStandard 423 | // 424 | this.labelStandard.AutoSize = true; 425 | this.labelStandard.Location = new System.Drawing.Point(140, 22); 426 | this.labelStandard.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 427 | this.labelStandard.Name = "labelStandard"; 428 | this.labelStandard.Size = new System.Drawing.Size(53, 12); 429 | this.labelStandard.TabIndex = 3; 430 | this.labelStandard.Text = "标准版本"; 431 | // 432 | // labelLang 433 | // 434 | this.labelLang.AutoSize = true; 435 | this.labelLang.Location = new System.Drawing.Point(46, 22); 436 | this.labelLang.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); 437 | this.labelLang.Name = "labelLang"; 438 | this.labelLang.Size = new System.Drawing.Size(29, 12); 439 | this.labelLang.TabIndex = 2; 440 | this.labelLang.Text = "语言"; 441 | // 442 | // comboBoxLang 443 | // 444 | this.comboBoxLang.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 445 | this.comboBoxLang.FormattingEnabled = true; 446 | this.comboBoxLang.Items.AddRange(new object[] { 447 | "C++", 448 | "C"}); 449 | this.comboBoxLang.Location = new System.Drawing.Point(79, 19); 450 | this.comboBoxLang.Margin = new System.Windows.Forms.Padding(2); 451 | this.comboBoxLang.Name = "comboBoxLang"; 452 | this.comboBoxLang.Size = new System.Drawing.Size(42, 20); 453 | this.comboBoxLang.TabIndex = 1; 454 | this.comboBoxLang.SelectedIndexChanged += new System.EventHandler(this.comboBoxLang_SelectedIndexChanged); 455 | // 456 | // comboBoxStandard 457 | // 458 | this.comboBoxStandard.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 459 | this.comboBoxStandard.FormattingEnabled = true; 460 | this.comboBoxStandard.Location = new System.Drawing.Point(194, 19); 461 | this.comboBoxStandard.Margin = new System.Windows.Forms.Padding(2); 462 | this.comboBoxStandard.Name = "comboBoxStandard"; 463 | this.comboBoxStandard.Size = new System.Drawing.Size(60, 20); 464 | this.comboBoxStandard.TabIndex = 0; 465 | this.comboBoxStandard.TextChanged += new System.EventHandler(this.comboBoxStandard_TextChanged); 466 | // 467 | // FormSettings 468 | // 469 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); 470 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 471 | this.ClientSize = new System.Drawing.Size(337, 342); 472 | this.Controls.Add(this.tabControlSettings); 473 | this.Controls.Add(this.pictureGitHub); 474 | this.Controls.Add(this.linkLabelLicense); 475 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow; 476 | this.Margin = new System.Windows.Forms.Padding(2); 477 | this.Name = "FormSettings"; 478 | this.Text = "设置"; 479 | this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FormSettings_FormClosing); 480 | this.Load += new System.EventHandler(this.FormSettings_Load); 481 | this.groupBoxPrivil.ResumeLayout(false); 482 | this.groupBoxArg.ResumeLayout(false); 483 | this.groupBoxArg.PerformLayout(); 484 | this.groupBoxMinGWSrc.ResumeLayout(false); 485 | this.groupBoxMinGWSrc.PerformLayout(); 486 | ((System.ComponentModel.ISupportInitialize)(this.pictureGitHub)).EndInit(); 487 | this.tabControlSettings.ResumeLayout(false); 488 | this.tabPageDownload.ResumeLayout(false); 489 | this.groupBoxMinGWDistro.ResumeLayout(false); 490 | this.groupBoxMinGWDistro.PerformLayout(); 491 | this.tabPageInstall.ResumeLayout(false); 492 | this.tabPageConfig.ResumeLayout(false); 493 | this.groupBoxStandard.ResumeLayout(false); 494 | this.groupBoxStandard.PerformLayout(); 495 | this.ResumeLayout(false); 496 | 497 | } 498 | 499 | #endregion 500 | 501 | private System.Windows.Forms.GroupBox groupBoxPrivil; 502 | private System.Windows.Forms.Button buttonAuth; 503 | private System.Windows.Forms.Label labelAuth; 504 | private System.Windows.Forms.GroupBox groupBoxArg; 505 | private System.Windows.Forms.Button buttonArgDefault; 506 | private System.Windows.Forms.Label labelArgInstruction; 507 | private System.Windows.Forms.Button buttonSaveArgs; 508 | private System.Windows.Forms.Label labelArgWarning; 509 | private System.Windows.Forms.TextBox textBoxArgs; 510 | private System.Windows.Forms.GroupBox groupBoxMinGWSrc; 511 | private System.Windows.Forms.Label labelMinGWSrcInstruction; 512 | private System.Windows.Forms.RadioButton radioButtonOffical; 513 | private System.Windows.Forms.RadioButton radioButtonDisk; 514 | private System.Windows.Forms.LinkLabel linkLabelLicense; 515 | private System.Windows.Forms.PictureBox pictureGitHub; 516 | private System.Windows.Forms.TabControl tabControlSettings; 517 | private System.Windows.Forms.TabPage tabPageDownload; 518 | private System.Windows.Forms.GroupBox groupBoxMinGWDistro; 519 | private System.Windows.Forms.RadioButton radioButtonOfficial; 520 | private System.Windows.Forms.RadioButton radioButtonGytx; 521 | private System.Windows.Forms.RadioButton radioButtonTDM; 522 | private System.Windows.Forms.TabPage tabPageInstall; 523 | private System.Windows.Forms.TabPage tabPageConfig; 524 | private System.Windows.Forms.Label labelDistroHint; 525 | private System.Windows.Forms.LinkLabel linkLabelTDM; 526 | private System.Windows.Forms.LinkLabel linkLabelMinGWw64; 527 | private System.Windows.Forms.GroupBox groupBoxStandard; 528 | private System.Windows.Forms.ComboBox comboBoxLang; 529 | private System.Windows.Forms.ComboBox comboBoxStandard; 530 | private System.Windows.Forms.Label labelStandard; 531 | private System.Windows.Forms.Label labelLang; 532 | private System.Windows.Forms.Button buttonUpdate; 533 | } 534 | } -------------------------------------------------------------------------------- /VSCodeConfigHelper/FormSettings.cs: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2020 Guyutongxue 2 | // 3 | // This file is part of VSCodeConfigHelper. 4 | // 5 | // VSCodeConfigHelper is free software: you can redistribute it and/or modify 6 | // it under the terms of the GNU General Public License as published by 7 | // the Free Software Foundation, either version 2 of the License, or 8 | // (at your option) any later version. 9 | // 10 | // VSCodeConfigHelper is distributed in the hope that it will be useful, 11 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the 13 | // GNU General Public License for more details. 14 | // 15 | // You should have received a copy of the GNU General Public License 16 | // along with VSCodeConfigHelper. If not, see. 17 | 18 | using System; 19 | using System.Collections.Generic; 20 | using System.ComponentModel; 21 | using System.Data; 22 | using System.Drawing; 23 | using System.Linq; 24 | using System.Text; 25 | using System.Threading.Tasks; 26 | using System.Windows.Forms; 27 | using System.Runtime.InteropServices; 28 | using System.IO; 29 | using System.Diagnostics; 30 | using System.Text.RegularExpressions; 31 | using Microsoft.Win32; 32 | using Newtonsoft.Json; 33 | using Newtonsoft.Json.Linq; 34 | using System.Net.Cache; 35 | using System.Net; 36 | 37 | namespace VSCodeConfigHelper 38 | { 39 | public partial class FormSettings : Form 40 | { 41 | 42 | #region Add Shield Icon 43 | 44 | [DllImport("user32.dll")] 45 | private static extern IntPtr SendMessage(HandleRef hWnd, uint Msg, IntPtr wParam, IntPtr lParam); 46 | 47 | /// 48 | /// Enables the elevated shield icon on the given button control 49 | /// 50 | /// 51 | /// Button control to enable the elevated shield icon on. 52 | /// 53 | private void EnableElevateIcon_BCM_SETSHIELD(Button ThisButton) 54 | { 55 | // Input validation, validate that ThisControl is not null 56 | if (ThisButton == null) return; 57 | 58 | // Define BCM_SETSHIELD locally, declared originally in Commctrl.h 59 | uint BCM_SETSHIELD = 0x0000160C; 60 | 61 | // Set button style to the system style 62 | ThisButton.FlatStyle = FlatStyle.System; 63 | 64 | // Send the BCM_SETSHIELD message to the button control 65 | SendMessage(new HandleRef(ThisButton, ThisButton.Handle), BCM_SETSHIELD, new IntPtr(0), new IntPtr(1)); 66 | } 67 | #endregion 68 | 69 | public FormSettings() 70 | { 71 | InitializeComponent(); 72 | } 73 | 74 | private void buttonSaveArgs_Click(object sender, EventArgs e) 75 | { 76 | 77 | GenerateArgs(); 78 | ShowArgs(); 79 | } 80 | 81 | private void FormSettings_Load(object sender, EventArgs e) 82 | { 83 | if (DateTime.Now.Date > new DateTime(2024, 10, 1)) radioButtonDisk.Enabled = false; 84 | if (Form1.isMinGWDisk) 85 | radioButtonDisk.Checked = true; 86 | else 87 | radioButtonOffical.Checked = true; 88 | 89 | switch (Form1.minGWDistro) 90 | { 91 | case 0: 92 | radioButtonGytx.Checked = true; 93 | break; 94 | case 1: 95 | radioButtonTDM.Checked = true; 96 | break; 97 | case 2: 98 | radioButtonOfficial.Checked = true; 99 | break; 100 | } 101 | string tempStandard = Form1.standard; 102 | if (Form1.isCpp) 103 | comboBoxLang.SelectedIndex = 0; 104 | else 105 | comboBoxLang.SelectedIndex = 1; 106 | LoadStandardComboBox(); 107 | comboBoxStandard.Text = tempStandard; 108 | if (Form1.IsAdministrator) 109 | { 110 | labelAuth.Width = 409; 111 | labelAuth.Text = "当前权限:系统管理员" + Environment.NewLine; 112 | labelAuth.Text += "您在此工具进行的操作(包括安装、设置环境变量和启动等)" + 113 | "将适用于所有用户,请谨慎操作。" + Environment.NewLine; 114 | labelAuth.Text += "若要使用普通用户权限,请重新使用非管理员权限运行此程序。"; 115 | buttonAuth.Visible = false; 116 | 117 | } 118 | else 119 | { 120 | labelAuth.Text = "当前权限:普通用户" + Environment.NewLine; 121 | labelAuth.Text += "您在此工具进行的操作(包括安装、设置环境变量和启动等)" + 122 | "将仅适用于此账户。" + Environment.NewLine; 123 | labelAuth.Text += "若要使用系统管理员权限,请点击右侧按钮。"; 124 | EnableElevateIcon_BCM_SETSHIELD(buttonAuth); 125 | } 126 | labelDistroHint.Text = 127 | "谷雨同学个人搭建的版本集成了最新版本的编译器。"+ Environment.NewLine + 128 | "TDM-GCC 是基于 MinGW 的另一发行版,提供了一些优化。"+ Environment.NewLine + 129 | "官方版本是最稳定、最常用的版本,但是长期未更新。"; 130 | ShowArgs(); 131 | } 132 | 133 | private void LoadStandardComboBox() 134 | { 135 | if (comboBoxLang.SelectedIndex == 0) 136 | { 137 | comboBoxStandard.Items.Clear(); 138 | comboBoxStandard.Items.AddRange(new string[] 139 | { 140 | "c++98", 141 | "c++03", 142 | "c++11", 143 | "c++14", 144 | "c++17", 145 | "c++20" 146 | }); 147 | comboBoxStandard.Text = Form1.ChosenMinGW.standard; 148 | //comboBoxStandard.SelectedIndex = 4; 149 | //// WinLibs (g++10.1) supports C++20 partly 150 | //if (radioButtonOfficial.Checked) 151 | // comboBoxStandard.SelectedIndex = 5; 152 | } 153 | else 154 | { 155 | comboBoxStandard.Items.Clear(); 156 | comboBoxStandard.Items.AddRange(new string[] 157 | { 158 | "c89", 159 | "c99", 160 | "c11", 161 | "c18" 162 | }); 163 | comboBoxStandard.SelectedIndex = 3; 164 | } 165 | } 166 | 167 | private void FormSettings_FormClosing(object sender, FormClosingEventArgs e) 168 | { 169 | Form1.isMinGWDisk = radioButtonDisk.Checked; 170 | } 171 | 172 | private void buttonAuth_Click(object sender, EventArgs e) 173 | { 174 | try 175 | { 176 | var exeName = Process.GetCurrentProcess().MainModule.FileName; 177 | ProcessStartInfo startInfo = new ProcessStartInfo(exeName); 178 | startInfo.Verb = "runas"; 179 | // prevent pop-up message box 180 | Form1.isSuccess = true; 181 | Process.Start(startInfo); 182 | Application.Exit(); 183 | } 184 | catch (Win32Exception) 185 | { 186 | // Do nothing. 187 | // If user cancel the operation by UAC, Process.Start will 188 | // throw an exception. Just ignore it. 189 | } 190 | } 191 | 192 | private void GenerateArgs() 193 | { 194 | string text = textBoxArgs.Text.Trim(); 195 | string[] argtext = text.Split(new[] { Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries); 196 | Form1.args = new JArray(argtext); 197 | } 198 | 199 | private void ShowArgs() 200 | { 201 | StringBuilder text = new StringBuilder(); 202 | foreach (object i in Form1.args) 203 | { 204 | text.AppendLine(i.ToString()); 205 | } 206 | textBoxArgs.Text = text.ToString().Trim(); 207 | } 208 | 209 | private void SetDefaultArgs() 210 | { 211 | Form1.args = Form1.GetDefaultArgs(); 212 | ShowArgs(); 213 | } 214 | 215 | private void buttonArgDefault_Click(object sender, EventArgs e) 216 | { 217 | SetDefaultArgs(); 218 | } 219 | 220 | /// 221 | /// 检测更新。 222 | /// 223 | /// 是否在未检测到更新或出现错误时提示 224 | public static void CheckUpdate(bool show) 225 | { 226 | try 227 | { 228 | ServicePointManager.SecurityProtocol = SecurityProtocolType.Ssl3 | SecurityProtocolType.Tls12 | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls; 229 | HttpWebRequest request = WebRequest.CreateHttp("https://api.github.com/repos/Guyutongxue/VSCodeConfigHelper3/releases/latest"); 230 | request.UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 Edg/81.0.416.72"; 231 | request.Method = "GET"; 232 | request.Timeout = 10000; 233 | HttpWebResponse response = (HttpWebResponse)request.GetResponse(); 234 | StreamReader sr = new StreamReader(response.GetResponseStream(), Encoding.UTF8); 235 | JObject versionInfo = (JObject)JsonConvert.DeserializeObject(sr.ReadToEnd()); 236 | sr.Close(); 237 | response.Close(); 238 | string latest = ((string)versionInfo["tag_name"]).Substring(1); 239 | if (show || !File.Exists("VSCHcache.txt")) 240 | { 241 | DialogResult result = MessageBox.Show( 242 | $"检测到新版本。{Environment.NewLine}最新版本:{latest}{Environment.NewLine}当前版本:{Application.ProductVersion}{Environment.NewLine}是否前往下载?", 243 | "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Information 244 | ); 245 | if (result == DialogResult.Yes) Process.Start("https://vscch3.vercel.app"); 246 | } 247 | } 248 | catch (Exception ex) 249 | { 250 | if (show) MessageBox.Show("检测更新时发生异常:" + ex.Message); 251 | } 252 | finally 253 | { 254 | } 255 | } 256 | 257 | 258 | // https://countapi.xyz/ 259 | // with namespace 'guyutongxue.github.io', key: b54f2252-e54a-4bd0-b4c2-33b47db6aa98 260 | public static string HitCount() 261 | { 262 | try 263 | { 264 | // Logging.Log("Hit a count."); 265 | ServicePointManager.SecurityProtocol = SecurityProtocolType.Ssl3 | SecurityProtocolType.Tls12 | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls; 266 | HttpWebRequest request = WebRequest.CreateHttp("https://api.countapi.xyz/hit/guyutongxue.github.io/b54f2252-e54a-4bd0-b4c2-33b47db6aa98"); 267 | request.UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 Edg/81.0.416.72"; 268 | request.Method = "GET"; 269 | request.Timeout = 5000; 270 | HttpWebResponse response = (HttpWebResponse)request.GetResponse(); 271 | StreamReader sr = new StreamReader(response.GetResponseStream(), Encoding.UTF8); 272 | return sr.ReadToEnd(); 273 | } 274 | catch (Exception ex) 275 | { 276 | Logging.Log($"Error occured while hitting counts: {ex.Message}", LogType.Error); 277 | return null; 278 | } 279 | } 280 | 281 | private void linkLabelLicense_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) 282 | { 283 | Process.Start("http://www.gnu.org/licenses/gpl-2.0.html"); 284 | } 285 | 286 | private void pictureGitHub_Click(object sender, EventArgs e) 287 | { 288 | Process.Start("https://github.com/Guyutongxue/VSCodeConfigHelper"); 289 | } 290 | 291 | private void radioButtonMinGWw64_CheckedChanged(object sender, EventArgs e) 292 | { 293 | if (radioButtonGytx.Checked) Form1.minGWDistro = 0; 294 | LoadStandardComboBox(); 295 | } 296 | 297 | private void radioButtonTDM_CheckedChanged(object sender, EventArgs e) 298 | { 299 | if (radioButtonTDM.Checked) Form1.minGWDistro = 1; 300 | LoadStandardComboBox(); 301 | } 302 | 303 | private void radioButtonWinLibs_CheckedChanged(object sender, EventArgs e) 304 | { 305 | if (radioButtonOfficial.Checked) Form1.minGWDistro = 2; 306 | LoadStandardComboBox(); 307 | } 308 | 309 | private void linkLabelMinGWw64_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) 310 | { 311 | Process.Start("https://sourceforge.net/projects/mingw-w64/"); 312 | } 313 | 314 | private void linkLabelTDM_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) 315 | { 316 | Process.Start("https://jmeubank.github.io/tdm-gcc/"); 317 | } 318 | 319 | private void linkLabelWinLibs_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) 320 | { 321 | Process.Start("http://winlibs.com/"); 322 | } 323 | 324 | private void comboBoxLang_SelectedIndexChanged(object sender, EventArgs e) 325 | { 326 | Form1.isCpp = comboBoxLang.SelectedIndex == 0; 327 | LoadStandardComboBox(); 328 | } 329 | 330 | 331 | private void comboBoxStandard_TextChanged(object sender, EventArgs e) 332 | { 333 | Form1.standard = comboBoxStandard.Text; 334 | SetDefaultArgs(); 335 | } 336 | 337 | private void buttonUpdate_Click(object sender, EventArgs e) 338 | { 339 | buttonUpdate.Enabled = false; 340 | buttonUpdate.Text = "正在连接服务器,请稍候……"; 341 | CheckUpdate(true); 342 | buttonUpdate.Enabled = true; 343 | buttonUpdate.Text = "检查 VS Code Config Helper 更新"; 344 | } 345 | } 346 | } 347 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/FormSettings.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 122 | 123 | iVBORw0KGgoAAAANSUhEUgAAAQAAAAEACAYAAABccqhmAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6 124 | JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAACXBIWXMAAA7DAAAOwwHHb6hkAAAAB3RJ 125 | TUUH5AQQCwsZb1KcgQAAEoFJREFUeF7tnQm4bWVdh2/OYSI4VogGaQbihBqKlpimgWiCOBWBGkUCpYlD 126 | A6IpTjlgpqTgwFNSKg4pggwaialJGg6lqJmZpiSOiKko5u8Fjh2P/8uZ1rfWt/d+3+d5H+Be9rn77v9a 127 | a6/1ff9hi4iIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiI 128 | iIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiMgkbBtvHveI+8dHxaPj 129 | n8cT48nx1HhWPPsK/z6eEd8U/ya+ND47Pj4eHO8dbxN3iFePItIBO8a94uHxuPi2+NH4pfh/A/vN+Nn4 130 | /shF5Jj40HjbeN0oIo3ZOR4Qnx/PiZ+L1ck6plwYuOi8PnLHcLe4fRSRTXKteJd4VOQ2/YuxOgl78+Px 131 | r+JBcacoImvkapGT/pnxvHhprE6yWfEL8c3xkHjTKCIF3N4fGd8Tvxurk2nWvSD+ddw3bhNFFpofiyzi 132 | vSJeGKuTZl7l7uYJ0bsCWTh4tn9IZNX+e7E6QRbFz8dj425RZK7hxGdf/dxYnQyL7EXx+Hi7KDJXXCXy 133 | jf/eWB38+v9+PZLTcMsoMvPcPZ4eq4Ndty7JTCQb3SCKzBw3iy+J347VAa5rk5yCR0QWTEW6h9v9342k 134 | zVYHtG5McgmoRxDpll0jB2p1AOvm/Uok3fgaUaQr+NaflVTdWZfKxVtFkcn5qfiqWB2o2k5SjB8ZRSaD 135 | LL6PxOoA1XFky/A6UWRUjogXx+qg1HF9V9wlijTnmvGFsToQdTo/E/eOIs24cTwlVgegTi/NSQ6NIoNz 136 | i/i+WB142pdPiSKDQYEKGWnVwaZ9ShNUkrJENsWd43/F6iDTvqXPgl2MZcPsGXtovKkblw5EXgRk3dBX 137 | n2YV1UGlsyUNSq8aRdYEve697Z8vqcwUWRWm6nwsVgeRzrZMOxLZKjeMbvXNt1QTivwI9OM3yWf+pQkr 138 | 7dlEfogXxOqA0fnzq/FOUeQyqOWvDhSdX5ln+NNRFhzGcH0jVgeJzrd0bzJbcIG5UbSef7Fl8KosKGSJ 139 | VQfFZmW23xMjLcFpGrJ/fEx8WWS+/v/G6nWLLo1U3xoZjEon4F+Nv3TFP8+O1Ws263fiPaIsGLSTqg6I 140 | IeQk3xo0tKS77WMjB/UlsfoZiyJ1/C+P+8Ud4ta4b6xeP4TnR+cPLBAk+9BTrjoYhvDJca38QqRybdHS 141 | jpmCzOLrWhfito+fitXPGsKXRlkAGDDRsnU33+hUEK4XpuQ+KX46Vj93XqSj76/FjRTokNNf/cwhJD/g 142 | flHmHJ4tqwNgKLmd3EyTSroM09Ci5R3KFJ4T7x83M+HnwFj97KEkBfx6UeYUTi6eOavgD+Wr4xDwmDLk 143 | aDF+DgkwPGr8Z/xE5GLFfjgH/icjn82FkWanQ40tp5HKIXGIYR7MAmjdiPU5UeaUF8cq6EN6ZBwSdhHe 144 | Gas/a7mXRlbR/zmeHJ8X2Xkg7ZWfcfvIxF0eNehtyDfddeO2cbvIIhjP4ztHTjTWJvaJLJayVXZCPDOy 145 | bcqEnuo9LJedDk4m6iuGgjur1tu2vG8+K5kzSP0cY1AnW1ZDc634uPjluPTnXBDfEUlh5rGGE5ZV9NZ1 146 | 75yEXEjuE3lPJ8UPRxpyLr03Llh3jS14S1z6c1p5anQY6RxBME+LVbCHlIzC3WIr+GY6OrJYxfThXrh2 147 | pIfCYfHR8cdjK9gxqT77oWWhUuaEfWMV5KHlFvwmUdrBXUf12Q8tZeHcecmMw3bTu2MV5KFlUY39amnH 148 | w2P12bfw4CgzzgGxCm4LPxS3idKOB8Xqs28haxs83siMwrc/GWdVcFv4gdjy+Vcur6uoPvtWehcww4z1 149 | 7L8kdwB+Y7TlwbH67FtJXQfzIGXGYOWftNMqqK00k6w9rTM5K90RmEHYFx+70o4hIj1tz80jlFlXn31L 150 | T4/mBcwYVHdVwWzptyJzBKUdx8Xqs28pcd09yoxAzv9UxTQsUkkb+BZ+e6w+99aSgCQzwpRNPp8epQ3U 151 | FUxVLs2kqOtH6RyaPJIjXwVxDP8h+rzYBtqDUfRUfe5j+LAonUNO+vLClLH9Wrx1lOGhwrH6zMfy76J0 152 | DsUyVfDGlGw1GRYmN015Z4dfiu7ydAxNJ86NVfDGkrZVJgO1gZHtNCypPvexJA9BOmXq238uPptpByar 153 | 88A45TqAjwEdQ6vtKmhjyO0hnXSkPYz5rmIwhiR7sc0sHULGVhW0MaQZhowDBVe0PqviMIbUmEhn0M9u 154 | qt76Z0VnzI3LL8aphqrQhk06g158VbBaS5oodQcyPoxaq2LSWtZ6huhyLAPytFgFq7UnRpmGW8S1dCge 155 | Wv5M2rZLJ5B5x214FayW0kKanQeZjimKg/ABUTqBMd8Mu6gC1dI3RpkWLsBTTFt+RpROGKvn/0ptFDE9 156 | UzR+QXacpBMOilWQWvrvkck6Mj1TdAmi+xMTlaQDGEFVBamlrEBLH+wUl09NGsOL4i5ROuCUWAWppbQb 157 | lz7gMeDsWMWppS3GwMk6ISvsg7EKUCuZsus2UF/QiKWKVUuPiDIxO0ZGclUBaiX9/x0b1Rf7xSpWLT02 158 | ysTcJo69DcT4bekLmrCMfRy8IcrE3CtWwWmpe8D9QYXe2P0CmTrVehy7rMKBsQpOSx8VpS+mWAv6aHQr 159 | eGL+IFbBaaktv/rknFjFq5WfiTtEmZBjYhWclrr90ydviVW8WkkTmJ+LMiEvilVwWnqPKP3x+ljFq5UW 160 | g3UA5bhVcFrqBaBPXhereLXyu9FeEBPzmlgFp6X3jNIfVGdW8WrpXlEmZIqg7xOlP06LVbxaeu8oE/Lm 161 | WAWmpdYB9Alj2ap4tXTvKBMyRSGQwyH64+pxik7BXgAm5k2xCkxLmT8gfbFt/LdYxaulbglPzNgrv/is 162 | KH1BW3hGeFfxaqkLwhPzqlgFpqXM/5O++PnIZOYqXq38XtwzyoQcH6vgtJTmE9IXDArhhKzi1Ur6UO4e 163 | ZUKeG6vgtPT8aBFIX0zRF5K2YLtGmZA/jlVwWspgCHPA+4IS7SpWLb0g0o9QJuR3YhWc1poA0hdjFwIh 164 | naFvGGVC6M1fBae1fxilD3gc+3is4tTS8+I1o0wIxRgUZVQBain5B9IHt4/fjFWcWso4OpkYBkRSl10F 165 | qKWMIrt+lOmhQ1MVo9a+IsrEXC9Ocft3aTQJpA+mKAjDJ0WZGIZCvDNWAWrt86NMC81AWY2v4tPah0Xp 166 | AG7FqgC1lqaQPxFlOn4jVrFp7XeizUA64chYBam1ZJ7dN8p0TNEDAP873iRKB9wnVkEaQ4dDTMcUQ2GW 167 | fG+kBFk64GfjFDsByAHIgSjjc1ysYjKG7gB0BHP6SMqoAjWGr4wyLmz/kpJdxWMMHQ7TGZyEVaDGkCSU 168 | O0YZjxNiFYsxvCTuEaUjfitWwRrLMyJbktKeu0VOwioOY/jJSP6JdMSUC0JLUpgkbeFxb4ref8tlAIl0 169 | xhTDIVf6xbhLlHbQjq367Mf08Cgd8hexCtiYsj10nSjDQzt2UrCrz30s3fXpGJJyqqCN7UnR9YBhIetu 170 | qq3e5b4/WgLcKTRnYGRzFbixfWGUYeAb91Ox+pzH9plROmaKLsFbk0eSq0bZOHeI/xGrz3ds6Ttx1ygd 171 | s1+sgjeVfxu3j7J+eKSbqtKv8kORxWbpGPZnadZRBXAqz410rZG1wV3TE+O3YvV5TuVTo8wAL4pVAKf0 172 | y/H34tWibB3abE8x8HU1Xf2fIe4SqdeuAjm1Z0aGWMgPs12k0Sq5FNXnNrVvi+7szAjcQr4rVoHsQW5t 173 | qSZzqszlHX0PjVMM9lyPB0aZIR4Zq0CuRRp9MGv+6fGw+JjIiv4/xotj9ZqN+I1IzgAzBq4RF4mdI9/4 174 | H4nVZ9OT7EK4kDtjELCN7h2/IG4NJgI9Pn46Vq/dqCwU/lHkOXNebzWZ4PvgyM5Ir7f6lU+JMoMcHauA 175 | ruaVJfHQCvy28WaR/2/o1FQWm3h8eVq8V6Tp5azCzH4ec8idPzn2kqS1Hlm8/ZkoMwg92y6MVWCvTEpN 176 | KS+uWJpF+ITL/mvLlv3j5+PKnzGUzLxn4ZAiGLrQckL9ZLxK7AmyMG8dHxD/JL4u0jR1yrLdIaTrkMww 177 | z4lVYFeTb/aj4sptO+4AHh1/5bL/uhwqAD8Rq58ztJxQPH5QdPTa+JJ45zg220TuUiiNfU/kOXnqcuyh 178 | /Xq0unPG4VZ9M0UkNPogHbWCZ9rHxh0iB8oUCUg8LvDnjw3rFKyMV+9pXjw+yhxAAUcV4LX61ciuwkqY 179 | DMTv8+1PowryxIfcJVjN8+ON45SQ3FS9t1mXmDsCfk7gmZk+7lWg1+Pj4nI46dkxOCfeiF8Ivx+r1w4t 180 | jyh7xx44NVbvcZZ9bpQ5guf2KtDrteoGu7Li7+2xeu2QssjWCyxMztPzP18Ws7z7IgUsWn0gVgFfjyzC 181 | VUNBuRtglZ7bxt1iyxOC97Bn7InXxOq9zqJHRJlD9olk+VVBX490hV35DcG3IL/HXje/x+PCytcNJcNQ 182 | e9sGJJtx6nZdQ8juih1/5pihGoacGJfD9iDtovg9st2A5JeVrxtCdh56gz6IH4vV+50Vafhx9yhzDNuC 183 | n4vVAbAeuZPgW285ZIzRGnxpQZDJwWfH6vUblSEkvfYWmGpK81Daxm1BeESsDoD1+u642oBI1gZOidXr 184 | NyLfslTQ9chQn+sU8rlyFycLwlC35w+MFdwdMMCCtFhuj/8sDtGjgB2GXqFzb699GK5M1i6YMC0LxI5x 185 | iMy9d8Sq8efyUWW/zS8ELgob3SKkdPitkQKhXuERqKcefmuVdHFZQO4XN7srwMJRtSXHtuPL4v/EldtK 186 | 5O7zvEkt/Na2C2kawm4Djw+8nhHovUMJNtmJ1d+nV6ljIFayoND0ozow1uPL49a4aVzasuOftCujczHN 187 | S+kwS/0/3W9/Mz4kUk1HodHt4g0ikHfP4mXv/QTZPvuXWH1GPUql6K2iLDDcvp8WqwNkrV4U13IgcRJz 188 | K89rPhuZcb+cO8W9Lv/XH0B9Ae2yuFN4Q+y5cxAXOL5RV34+vfrQKHJZNd1mb125VV8NdgSeF+mGw7My 189 | J/wSdJ1Z+lmc6EssL7Z5dVxt12FKuFPpuRfjco+JIj+Ak5HuL9XBslaXmoSsBv3wKCVeDltoNP8gR+HJ 190 | /MIVcFvN4iH23jdwVi4ApC3Pa9s12QRs6bGoVx00a5HX/nrcKCQQTVHbPxSzcAHgEaXXPArpgM2W87J6 191 | //C4iLAG0PMFgBZl9veTVVn+PL5R2V1YtO2lni8APF7Rs1BkTZC5Vx1I65GTYXnvwHmHCwDp0dVnMaUs 192 | uO4RRdbFsbE6oNYj6wI0zmSv/9pxnunxAvCF6Cg22TBs21UH1kZkvDQXFZJ9bhmpFlwNFqzIF/jlyISi 193 | O8ZeIaeipzwAvvk9+WXTPCNWB9hmpOkkCT6UC7O/f0L8y0ibb3oNvDHyCEF+wvLtyao5aS9wAfinuPzv 194 | OZW0Tp+iXbrMKcyxqw60sT0o9goXADrqVO97TKmxcJS3DA4VflM3vzw49gq1Csw4rN73WDLAdaco0gTq 195 | xqeccddzjgEXAHogVO97DBk6apKPNGfXONWzbs9rANQpvC9W77ullHQ/NbILITIK20XKgKsDsqWHxF6Z 196 | 4gJAvwWr+mQyaNbxtVgdnC1c6i7UIxQrLXVGHkO6MTGDQWRSqCQca//70NgrYzUEoe/gs+O8J1bJDEHj 197 | T4aQUgxUHbRDeVjsFfodnBer9z2U/xp7mYko8iPQ0aflAmHPY6tocTbE+LXKb0eyKG3dLd3DrSmJQ3T+ 198 | qQ7mzUi5cq9wAfhgrN73ZmT68spWaSLds0skrXfIXvnUA/QK5c9DXgBo23545NFCZGZhmvAZsTrI12uP 199 | cwGX4M6Hgqfqfa9H7pxYT3FEt8wNJKkcELmdrQ76tcrU4V6huvHDsXrfa/ErkXkJjFgXmUtIlqH34Fmx 200 | OglWs+cLAI8AVDhW7/vKpGyXBT4emUQWAhpoMubrpLieRKL7x17h73R6rN53JT36jorMSxBZWKgt+NPI 201 | Hnd1oixJoQ35Bj1Ds5PqvS95cWSGAt2TSacWkSvg5GZe4SsjTSyXTppL4pmRLkKzAMNMlldMsofPxYtv 202 | extziqwBVsDZ++aCcIdYTSDuGQaf8Iizb9w99jzRSERERERERERERERERERERERERERERERERERERERE 203 | RERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERE 204 | RERERERERET6Z8uW7wNyl9uY1G6A+QAAAABJRU5ErkJggg== 205 | 206 | 207 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Logging.cs: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2020 Guyutongxue 2 | // 3 | // This file is part of VSCodeConfigHelper. 4 | // 5 | // VSCodeConfigHelper is free software: you can redistribute it and/or modify 6 | // it under the terms of the GNU General Public License as published by 7 | // the Free Software Foundation, either version 2 of the License, or 8 | // (at your option) any later version. 9 | // 10 | // VSCodeConfigHelper is distributed in the hope that it will be useful, 11 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the 13 | // GNU General Public License for more details. 14 | // 15 | // You should have received a copy of the GNU General Public License 16 | // along with VSCodeConfigHelper. If not, see. 17 | 18 | using System; 19 | using System.Collections.Generic; 20 | using System.Linq; 21 | using System.Text; 22 | using System.Threading.Tasks; 23 | using System.IO; 24 | 25 | namespace VSCodeConfigHelper 26 | { 27 | public enum LogType 28 | { 29 | Info, 30 | Warning, 31 | Error, 32 | Multiline 33 | } 34 | public static class Logging 35 | { 36 | static string LogFilePath 37 | { 38 | get 39 | { 40 | return "VSCH.log"; 41 | } 42 | } 43 | public static void Clear() 44 | { 45 | if (File.Exists(LogFilePath)) File.Delete(LogFilePath); 46 | } 47 | 48 | public static void Log(Exception ex, string adj = "") 49 | { 50 | Log(adj + " error occured. ", LogType.Error); 51 | string detail = "Type: " + ex.GetType().Name + Environment.NewLine 52 | + "Info: " + ex.Message + Environment.NewLine 53 | + "StackTrace: " + Environment.NewLine + ex.StackTrace; 54 | Log(detail, LogType.Multiline); 55 | } 56 | public static void Log(string message, LogType type = LogType.Info) 57 | { 58 | StreamWriter sw = new StreamWriter(LogFilePath, true); 59 | 60 | string log = $"[{DateTime.Now:yyyy-MM-dd hh:mm:ss}] "; 61 | switch (type) 62 | { 63 | case LogType.Info: 64 | log += "[INFO] "; 65 | break; 66 | case LogType.Warning: 67 | log += "[WARNING] "; 68 | break; 69 | case LogType.Error: 70 | log += "[ERROR] "; 71 | break; 72 | case LogType.Multiline: 73 | log += Environment.NewLine; 74 | break; 75 | } 76 | log += message; 77 | log += Environment.NewLine; 78 | sw.Write(log); 79 | sw.Flush(); 80 | sw.Close(); 81 | } 82 | } 83 | } 84 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/MinGWLink.cs: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2020 Guyutongxue 2 | // 3 | // This file is part of VSCodeConfigHelper. 4 | // 5 | // VSCodeConfigHelper is free software: you can redistribute it and/or modify 6 | // it under the terms of the GNU General Public License as published by 7 | // the Free Software Foundation, either version 2 of the License, or 8 | // (at your option) any later version. 9 | // 10 | // VSCodeConfigHelper is distributed in the hope that it will be useful, 11 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the 13 | // GNU General Public License for more details. 14 | // 15 | // You should have received a copy of the GNU General Public License 16 | // along with VSCodeConfigHelper. If not, see. 17 | 18 | using System; 19 | using System.Collections.Generic; 20 | using System.Linq; 21 | using System.Text; 22 | using System.Threading.Tasks; 23 | 24 | namespace VSCodeConfigHelper 25 | { 26 | class Spec 27 | { 28 | public Spec(string official, string disk) 29 | { 30 | this.official = official; 31 | this.disk = disk; 32 | } 33 | readonly string official; 34 | readonly string disk; 35 | public string getLink(bool isDisk) 36 | { 37 | if (isDisk) return disk; 38 | else return official; 39 | } 40 | } 41 | 42 | public class MinGWLink 43 | { 44 | readonly Spec win32; 45 | readonly Spec win64; 46 | public readonly string standard; 47 | MinGWLink(string win32official, string win32disk, string win64official, string win64disk, string standard = "c++17") 48 | { 49 | win32 = new Spec(win32official, win32disk); 50 | win64 = new Spec(win64official, win64disk); 51 | this.standard = standard; 52 | } 53 | public string getLink(bool is64, bool isDisk) 54 | { 55 | if (is64) return win64.getLink(isDisk); 56 | else return win32.getLink(isDisk); 57 | } 58 | 59 | public static readonly MinGWLink official = new MinGWLink( 60 | @"https://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting%20Win32/Personal%20Builds/mingw-builds/8.1.0/threads-posix/dwarf/i686-8.1.0-release-posix-dwarf-rt_v6-rev0.7z", 61 | @"https://wws.lanzoux.com/iVdwNge4cde", 62 | @"https://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting%20Win64/Personal%20Builds/mingw-builds/8.1.0/threads-posix/seh/x86_64-8.1.0-release-posix-seh-rt_v6-rev0.7z", 63 | @"https://wws.lanzoux.com/iuRLbge4bni" 64 | ); 65 | 66 | public static readonly MinGWLink tdm = new MinGWLink( 67 | @"https://github.com/jmeubank/tdm-gcc/releases/download/v9.2.0-tdm-1/tdm-gcc-9.2.0.exe", 68 | @"https://wws.lanzoux.com/iRpRjge4r4f", 69 | @"https://github.com/jmeubank/tdm-gcc/releases/download/v9.2.0-tdm64-1/tdm64-gcc-9.2.0.exe", 70 | @"https://wws.lanzoux.com/iMhd6ge4qkf" 71 | ); 72 | 73 | public static readonly MinGWLink gytx = new MinGWLink( 74 | @"https://github.com/Guyutongxue/mingw-release/releases/download/v11.2.0-r1/gytx_i686-11.2.0-posix-dwarf_r1.7z", 75 | @"https://gytx.lanzoui.com/iAicTs48l8j", 76 | @"https://github.com/Guyutongxue/mingw-release/releases/download/v11.2.0-r1/gytx_x86_64-11.2.0-posix-seh_r1.7z", 77 | @"https://gytx.lanzoui.com/iy906s48llc", 78 | "c++20" 79 | ); 80 | 81 | } 82 | } 83 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using System.Windows.Forms; 6 | 7 | namespace VSCodeConfigHelper 8 | { 9 | static class Program 10 | { 11 | /// 12 | /// 应用程序的主入口点。 13 | /// 14 | [STAThread] 15 | static void Main() 16 | { 17 | try 18 | { 19 | Application.SetUnhandledExceptionMode(UnhandledExceptionMode.CatchException); 20 | // 处理UI线程异常 21 | Application.ThreadException += new System.Threading.ThreadExceptionEventHandler(Application_ThreadException); 22 | // 处理非UI线程异常 23 | AppDomain.CurrentDomain.UnhandledException += new UnhandledExceptionEventHandler(CurrentDomain_UnhandledException); 24 | 25 | Application.EnableVisualStyles(); 26 | Application.SetCompatibleTextRenderingDefault(false); 27 | Application.Run(new Form1()); 28 | } 29 | catch (Exception ex) 30 | { 31 | Logging.Log(ex, "UI"); 32 | MessageBox.Show("出现错误:" + ex.Message, "未知错误", MessageBoxButtons.OK, MessageBoxIcon.Error); 33 | } 34 | } 35 | 36 | static void Application_ThreadException(object sender, System.Threading.ThreadExceptionEventArgs e) 37 | { 38 | Logging.Log(e.Exception, "UI"); 39 | MessageBox.Show("出现错误:"+e.Exception.Message, "UI线程错误", MessageBoxButtons.OK, MessageBoxIcon.Error); 40 | } 41 | 42 | static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e) 43 | { 44 | Logging.Log(e.ExceptionObject as Exception, "non-UI"); 45 | MessageBox.Show("出现错误:" + ((Exception)e.ExceptionObject).Message, "非UI线程错误", MessageBoxButtons.OK, MessageBoxIcon.Error); 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // 有关程序集的一般信息由以下 6 | // 控制。更改这些特性值可修改 7 | // 与程序集关联的信息。 8 | [assembly: AssemblyTitle("VSCodeConfigHelper")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("VSCodeConfigHelper")] 13 | [assembly: AssemblyCopyright("Copyright © 2019")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // 将 ComVisible 设置为 false 会使此程序集中的类型 18 | //对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型 19 | //请将此类型的 ComVisible 特性设置为 true。 20 | [assembly: ComVisible(false)] 21 | 22 | // 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID 23 | [assembly: Guid("0c9ca75f-0bee-49a7-8a56-36539bae27e9")] 24 | 25 | // 程序集的版本信息由下列四个值组成: 26 | // 27 | // 主版本 28 | // 次版本 29 | // 生成号 30 | // 修订号 31 | // 32 | //可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值 33 | //通过使用 "*",如下所示: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("2.2.14.0")] 36 | [assembly: AssemblyFileVersion("2.2.14.0")] 37 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // 此代码由工具生成。 4 | // 运行时版本:4.0.30319.42000 5 | // 6 | // 对此文件的更改可能会导致不正确的行为,并且如果 7 | // 重新生成代码,这些更改将会丢失。 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace VSCodeConfigHelper.Properties { 12 | using System; 13 | 14 | 15 | /// 16 | /// 一个强类型的资源类,用于查找本地化的字符串等。 17 | /// 18 | // 此类是由 StronglyTypedResourceBuilder 19 | // 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。 20 | // 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen 21 | // (以 /str 作为命令选项),或重新生成 VS 项目。 22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")] 23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 25 | internal class Resources { 26 | 27 | private static global::System.Resources.ResourceManager resourceMan; 28 | 29 | private static global::System.Globalization.CultureInfo resourceCulture; 30 | 31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 32 | internal Resources() { 33 | } 34 | 35 | /// 36 | /// 返回此类使用的缓存的 ResourceManager 实例。 37 | /// 38 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 39 | internal static global::System.Resources.ResourceManager ResourceManager { 40 | get { 41 | if (object.ReferenceEquals(resourceMan, null)) { 42 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("VSCodeConfigHelper.Properties.Resources", typeof(Resources).Assembly); 43 | resourceMan = temp; 44 | } 45 | return resourceMan; 46 | } 47 | } 48 | 49 | /// 50 | /// 重写当前线程的 CurrentUICulture 属性 51 | /// 重写当前线程的 CurrentUICulture 属性。 52 | /// 53 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 54 | internal static global::System.Globalization.CultureInfo Culture { 55 | get { 56 | return resourceCulture; 57 | } 58 | set { 59 | resourceCulture = value; 60 | } 61 | } 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Properties/Resources.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | text/microsoft-resx 107 | 108 | 109 | 2.0 110 | 111 | 112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 113 | 114 | 115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // 此代码由工具生成。 4 | // 运行时版本:4.0.30319.42000 5 | // 6 | // 对此文件的更改可能会导致不正确的行为,并且如果 7 | // 重新生成代码,这些更改将会丢失。 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace VSCodeConfigHelper.Properties { 12 | 13 | 14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.4.0.0")] 16 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { 17 | 18 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 19 | 20 | public static Settings Default { 21 | get { 22 | return defaultInstance; 23 | } 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/Properties/app.manifest: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 47 | 48 | 49 | 50 | true 51 | 52 | 53 | 54 | 55 | 69 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/VSCodeConfigHelper.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {0C9CA75F-0BEE-49A7-8A56-36539BAE27E9} 8 | WinExe 9 | VSCodeConfigHelper 10 | VSCodeConfigHelper 11 | v4.5 12 | 512 13 | true 14 | true 15 | false 16 | 17 | 18 | 19 | publish\ 20 | true 21 | Disk 22 | false 23 | Foreground 24 | 7 25 | Days 26 | false 27 | false 28 | true 29 | 0 30 | 1.0.0.%2a 31 | false 32 | true 33 | 34 | 35 | AnyCPU 36 | true 37 | full 38 | false 39 | bin\Debug\ 40 | DEBUG;TRACE 41 | prompt 42 | 4 43 | false 44 | 45 | 46 | AnyCPU 47 | pdbonly 48 | true 49 | bin\Release\ 50 | TRACE 51 | prompt 52 | 4 53 | false 54 | 55 | 56 | LocalIntranet 57 | 58 | 59 | false 60 | 61 | 62 | 63 | 64 | Properties\app.manifest 65 | 66 | 67 | ..\docs\favicon.ico 68 | 69 | 70 | true 71 | bin\x64\Debug\ 72 | DEBUG;TRACE 73 | full 74 | x64 75 | prompt 76 | MinimumRecommendedRules.ruleset 77 | false 78 | 79 | 80 | bin\x64\Release\ 81 | TRACE 82 | true 83 | pdbonly 84 | x64 85 | prompt 86 | MinimumRecommendedRules.ruleset 87 | false 88 | 89 | 90 | true 91 | bin\x86\Debug\ 92 | DEBUG;TRACE 93 | full 94 | x86 95 | prompt 96 | MinimumRecommendedRules.ruleset 97 | false 98 | 99 | 100 | bin\x86\Release\ 101 | TRACE 102 | true 103 | pdbonly 104 | x86 105 | prompt 106 | MinimumRecommendedRules.ruleset 107 | false 108 | 109 | 110 | false 111 | 112 | 113 | false 114 | 115 | 116 | D7EA7A1DD03CB217297621D19B90CB3AD6B091F8 117 | 118 | 119 | VSCodeConfigHelper_TemporaryKey.pfx 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | ..\packages\Newtonsoft.Json.12.0.3\lib\net40\Newtonsoft.Json.dll 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | Form 143 | 144 | 145 | Form1.cs 146 | 147 | 148 | Form 149 | 150 | 151 | FormSettings.cs 152 | 153 | 154 | 155 | 156 | 157 | 158 | Form1.cs 159 | Designer 160 | 161 | 162 | FormSettings.cs 163 | 164 | 165 | ResXFileCodeGenerator 166 | Resources.Designer.cs 167 | Designer 168 | 169 | 170 | True 171 | Resources.resx 172 | True 173 | 174 | 175 | 176 | 177 | SettingsSingleFileGenerator 178 | Settings.Designer.cs 179 | 180 | 181 | True 182 | Settings.settings 183 | True 184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | False 192 | Microsoft .NET Framework 4.7.2 %28x86 和 x64%29 193 | true 194 | 195 | 196 | False 197 | .NET Framework 3.5 SP1 198 | false 199 | 200 | 201 | 202 | 203 | 204 | 205 | 206 | {F935DC20-1CF0-11D0-ADB9-00C04FD58A0B} 207 | 1 208 | 0 209 | 0 210 | tlbimp 211 | False 212 | True 213 | 214 | 215 | 216 | -------------------------------------------------------------------------------- /VSCodeConfigHelper/VSCodeConfigHelper.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSCodeConfigHelper/v2/d5b578fda57a105a0219a02a006108494d13cb7d/VSCodeConfigHelper/VSCodeConfigHelper.ico -------------------------------------------------------------------------------- /VSCodeConfigHelper/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /VS_Code_in_Linux.md: -------------------------------------------------------------------------------- 1 | # GNU/Linux 下配置 VS Code 2 | 3 | ## 安装 G++ 编译器 4 | 5 | Debian 或 Ubuntu: 6 | ```bash 7 | sudo apt install g++ 8 | ``` 9 | 其它发行版:参考您所采用的软件包管理器的安装方法。 10 | 11 | ## 安装 VS Code 12 | 13 | 前往[官网](https://code.visualstudio.com/)获取 deb 或 rpm 包安装。 14 | 15 | ## 配置 16 | 17 | 选定任意(有足够权限的路径)为工作文件夹。建立 `.vscode` 子文件夹,其中包含以下文件: 18 | 19 | ``` 20 | .vscode 21 | ├─ settings.json 22 | ├─ tasks.json 23 | └─ launch.json 24 | ``` 25 | 修改其内容为: 26 | #### settings.json 27 | ```JSON 28 | { 29 | "C_Cpp.default.intelliSenseMode": "gcc-x64", 30 | "C_Cpp.default.compilerPath": "/usr/bin/g++", 31 | "C_Cpp.default.cppStandard": "c++17" 32 | } 33 | ``` 34 | 35 | #### tasks.json 36 | ```JSON 37 | { 38 | "version": "2.0.0", 39 | "tasks": [ 40 | { 41 | "type": "shell", 42 | "label": "g++ build active file", 43 | "command": "g++", 44 | "args": [ 45 | "-g", 46 | "-std=c++20", 47 | "${file}", 48 | "-o", 49 | "${fileDirname}/${fileBasenameNoExtension}.out" 50 | ], 51 | "group": { 52 | "kind": "build", 53 | "isDefault": true 54 | }, 55 | "presentation": { 56 | "echo": false, 57 | "reveal": "silent", 58 | "focus": false, 59 | "panel": "shared", 60 | "showReuseMessage": false, 61 | "clear": true 62 | }, 63 | "problemMatcher": [ "$gcc" ] 64 | } 65 | ] 66 | } 67 | ``` 68 | 69 | #### launch.json 70 | ```JSON 71 | { 72 | "version": "0.2.0", 73 | "configurations": [ 74 | { 75 | "name": "g++ build and debug active file", 76 | "type": "cppdbg", 77 | "request": "launch", 78 | "program": "${fileDirname}/${fileBasenameNoExtension}.out", 79 | "args": [], 80 | "stopAtEntry": false, 81 | "cwd": "${workspaceFolder}", 82 | "environment": [], 83 | "externalConsole": false, 84 | "MIMode": "gdb", 85 | "miDebuggerPath": "/usr/bin/gdb", 86 | "setupCommands": [ 87 | { 88 | "description": "Enable pretty-printing for gdb", 89 | "text": "-enable-pretty-printing", 90 | "ignoreFailures": true 91 | } 92 | ], 93 | "preLaunchTask": "g++ build active file", 94 | "internalConsoleOptions": "neverOpen" 95 | } 96 | ] 97 | } 98 | ``` 99 | 100 | ## 尝试编译运行 101 | 102 | 新建任意 C++ 源文件,可以按 F5 编译并调试;按 Ctrl+F5 编译并运行;按 Ctrl+Shift+F5 编译。 103 | 104 | -------------------------------------------------------------------------------- /VS_Code_in_Mac.md: -------------------------------------------------------------------------------- 1 | # 在 Mac 上安装 VS Code 2 | 3 | ## 安装编译器 4 | 5 | 打开终端( Spotlight 搜索 “Terminal.app” ),输入 6 | 7 | ```bash 8 | xcode-select --install 9 | ``` 10 | 选择“安装”。 11 | 12 | ## 安装 VS Code 13 | 14 | 前往 https://code.visualstudio.com/ 下载安装包,然后双击打开,将 `Visual Studio Code.app` 拖到 应用程序 (`Applications`)文件夹。 15 | 16 | ## 配置 VS Code 17 | 18 | 前往[此处](https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools)安装 C/C++ 插件。点击 Install 即可。 19 | 20 | 打开一个保存 C++ 文档的文件夹(Open Folder)。按 ⌘+⇧+P,搜索选择“ C/C++: Edit Configurations... (UI)”。 21 | 22 | 将“编译器路径”(Compiler Path)设置为 `/usr/bin/clang` , IntelliSense 模式设置为 `clang-x64` 。 23 | 24 | 按 ⌘+⇧+P,搜索选择 “Tasks: Configure Default Build Task”,选择 “Create tasks.json file from template”,再选择 “Others” 选项。将生成的 `tasks.json` 用以下文本覆盖: 25 | 26 | ```JSON 27 | { 28 | "version": "2.0.0", 29 | "tasks": [ 30 | { 31 | "label": "Build with Clang", 32 | "type": "shell", 33 | "command": "clang++", 34 | "args": [ 35 | "-std=c++17", 36 | "-stdlib=libc++", 37 | "${file}", 38 | "-o", 39 | "${fileDirname}/${fileBasenameNoExtension}.out", 40 | "--debug" 41 | ], 42 | "group": { 43 | "kind": "build", 44 | "isDefault": true 45 | } 46 | } 47 | ] 48 | } 49 | ``` 50 | 51 | 最后,按 ⌘+⇧+P,搜索选择 “Debug: Open launch.json”,选择 “GDB/LLDB” 。将生成的 `launch.json` 用以下文本覆盖: 52 | 53 | ```JSON 54 | { 55 | "version": "0.2.0", 56 | "configurations": [ 57 | { 58 | "name": "(lldb) Launch", 59 | "type": "cppdbg", 60 | "request": "launch", 61 | "program": "${fileDirname}/${fileBasenameNoExtension}.out", 62 | "args": [], 63 | "stopAtEntry": false, 64 | "cwd": "${workspaceFolder}", 65 | "environment": [], 66 | "externalConsole": true, 67 | "MIMode": "lldb", 68 | "logging": { 69 | "trace": true, 70 | "traceResponse": true, 71 | "engineLogging": true 72 | }, 73 | "preLaunchTask": "Build with Clang" 74 | } 75 | ] 76 | } 77 | ``` 78 | 79 | ## 尝试编译调试 80 | 81 | **在该文件夹下**打开或新建一个 C++ 源代码,后缀名为 `.cpp`。比如: 82 | 83 | ```C++ 84 | #include 85 | using namespace std; 86 | int main(){ 87 | cout<<"Hello,world!"<F5 ,期望弹出一个终端并打印出 `Hello,world!` 。 92 | 93 | ----- 94 | 95 | **重要提示** VS Code 在 macOS 上调试仍然存在问题:可能无法弹出调试窗口。 96 | 97 | 暂时的解决方案如下: 98 | 99 | 将 `tasks.json` 修改为: 100 | ```JSON 101 | // tasks.json 102 | { 103 | "version": "2.0.0", 104 | "tasks": [ 105 | { 106 | "label": "Build with Clang", 107 | "type": "shell", 108 | "command": "clang++", 109 | "args": [ 110 | "-std=c++17", 111 | "-stdlib=libc++", 112 | "${file}", 113 | "-o", 114 | "${fileDirname}/${fileBasenameNoExtension}.out", 115 | "--debug" 116 | ], 117 | "group": { 118 | "kind": "build", 119 | "isDefault": true 120 | } 121 | }, 122 | { 123 | "label": "Open Terminal", 124 | "type": "shell", 125 | "command": "osascript -e 'tell application \"Terminal\"\ndo script \"echo hello\"\nend tell'", 126 | "problemMatcher": [] 127 | } 128 | ] 129 | } 130 | ``` 131 | 132 | 每次启动 VS Code 后,先按 ⌘+⇧+P,键入 `Run Tasks` 并选中,选择 `Open Terminal` 运行一次即可。 133 | 134 | 相关 Issue 参见[此处](https://github.com/microsoft/vscode-cpptools/issues/5079)。 135 | 136 | -------------------------------------------------------------------------------- /docs/CNAME: -------------------------------------------------------------------------------- 1 | v2.vscch.tk -------------------------------------------------------------------------------- /docs/assets/Snapshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSCodeConfigHelper/v2/d5b578fda57a105a0219a02a006108494d13cb7d/docs/assets/Snapshot.png -------------------------------------------------------------------------------- /docs/assets/VSCodeConfigHelper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSCodeConfigHelper/v2/d5b578fda57a105a0219a02a006108494d13cb7d/docs/assets/VSCodeConfigHelper.png -------------------------------------------------------------------------------- /docs/assets/external.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSCodeConfigHelper/v2/d5b578fda57a105a0219a02a006108494d13cb7d/docs/assets/external.png -------------------------------------------------------------------------------- /docs/assets/internal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSCodeConfigHelper/v2/d5b578fda57a105a0219a02a006108494d13cb7d/docs/assets/internal.png -------------------------------------------------------------------------------- /docs/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/VSCodeConfigHelper/v2/d5b578fda57a105a0219a02a006108494d13cb7d/docs/favicon.ico -------------------------------------------------------------------------------- /docs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | VS Code Config Helper 6 | 7 | 8 | 9 | 10 | 16 | 24 | 25 | 26 | 27 | 28 | 33 | 34 | 35 | 36 |
37 | 此页面是 2.x 旧版工具的主页。旧版工具将不再接受功能更新,请前往此处下载 4.x 新版工具。 39 |
40 |
41 |
42 |
43 |
44 | 45 |
46 |
47 |

VS Code Config Helper

48 |

简单、快捷的 VS Code C++ 配置工具

49 |
50 |
51 |
52 | 57 |
58 | 59 | 67 |
68 |
69 |
70 | 使用帮助 72 | 疑难解答 74 | 常见问题 76 |
77 |
78 |
79 |
80 | 已成功配置
81 | 次 82 |
83 |
84 | 初次配置耗时
85 | <10 分 86 |
87 |
88 | 再次配置耗时
89 | ≈15 秒 90 |
91 |
92 | 93 | 94 | 95 |
96 |
97 |
98 |

吹爆,这个太好用了

99 |
微信群里的 LBX 同学
100 |
101 |
102 |
103 |
104 |

试了很多位up的方法,在您这里成功了,非常感谢!!!!!!

105 |
Bilibili @常*路人 的评论
106 |
107 |
108 |
109 |
110 |

亲测可用!非常推荐这个实用的小工具。

111 |
知乎 @中* 的评论
112 |
113 |
114 |
115 | 116 |

VS Code Config Helper 是自由软件。你可以基于 GPLv2 协议进行再分发或修改。 118 |

119 | 120 |

谷雨同学 | Guyutongxue

121 |
122 | 123 | 135 | 168 | 169 | 171 | 172 | 173 | -------------------------------------------------------------------------------- /docs/index.js: -------------------------------------------------------------------------------- 1 | $.getJSON("version.json", function (result) { 2 | versionInfo = result; 3 | console.log(versionInfo); 4 | $("#version-text").text("版本 " + versionInfo.version + " 更新日期 " + versionInfo.date); 5 | }); 6 | 7 | $("[data-toggle='popover']").popover({ 8 | html: true, 9 | title: "使用蓝奏云下载", 10 | trigger: "click", 11 | content: function () { 12 | return lanzousPopup(); 13 | } 14 | }); 15 | 16 | $.getJSON("https://api.countapi.xyz/get/guyutongxue.github.io/b54f2252-e54a-4bd0-b4c2-33b47db6aa98", result => { 17 | const count = new countUp.CountUp('successCount', result.value, {prefix: '>'}); 18 | count.start(); 19 | }); 20 | 21 | function lanzousPopup() { 22 | let data = $(` 23 | 链接 24 |
25 | 密码 26 |
27 | 28 | 29 | 30 | 31 |
`); 32 | return data; 33 | } 34 | 35 | $(document).ready(() => { 36 | const clipboard = new ClipboardJS('#copybtn'); 37 | }) -------------------------------------------------------------------------------- /docs/version.json: -------------------------------------------------------------------------------- 1 | {"version":"2.2.14","link":"https://github.com/Guyutongxue/VSCodeConfigHelper/releases/download/v2.2.14/Release-v2.2.14.zip","date":"2021/09/10"} 2 | -------------------------------------------------------------------------------- /package.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | if [ ! -n "$1" ] 3 | then 4 | echo "Usage: $0 " && exit 5 | fi 6 | DP0="$( cd "$( dirname "$0" )" && pwd )" # Get the path of this script 7 | echo -e "\033[32mPackaging binaries...\033[0m" 8 | cd $DP0/VSCodeConfigHelper/bin/Release 9 | ls 10 | 7z a -tzip Release-v$1.zip VSCodeConfigHelper.exe Newtonsoft.Json.dll 11 | cd $DP0 12 | echo -e "\033[32mGenerating version info...\033[0m" 13 | echo -e "{\"version\":\"$1\",\"link\":\"https://github.com/Guyutongxue/VSCodeConfigHelper/releases/download/v$1/Release-v$1.zip\",\"date\":\"$( date "+%Y/%m/%d" )\"}" > $DP0/docs/version.json -------------------------------------------------------------------------------- /publish.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | if [ ! -n "$1" ] 3 | then 4 | echo "Usage: $0 " && exit 5 | fi 6 | DP0="$( cd "$( dirname "$0" )" && pwd )" # Get the path of this script 7 | echo -e "\033[32mCreating release...\033[0m" 8 | release_id=$( curl -u Guyutongxue:$github_token https://api.github.com/repos/Guyutongxue/VSCodeConfigHelper/releases -X POST -d "{\"tag_name\": \"v$1\", \"name\": \"v$1 Release\"}" | jq '.id' ) 9 | echo Release ID is $release_id 10 | echo -e "\033[32mUploading asset...\033[0m" 11 | curl -u Guyutongxue:$github_token https://uploads.github.com/repos/Guyutongxue/VSCodeConfigHelper/releases/$release_id/assets\?name\=Release-v$1.zip -X POST --data-binary @"$DP0/VSCodeConfigHelper/bin/Release/Release-v$1.zip" -H "Content-Type:application/zip" | jq 12 | echo -e "\033[32mFinished.\033[0m" --------------------------------------------------------------------------------