├── .gitignore ├── LittleTips.sln ├── LittleTips ├── App.config ├── App.xaml ├── App.xaml.cs ├── AppIcon │ ├── altium-designer.png │ ├── directory-opus.png │ ├── icons8-atom-editor-100.png │ ├── icons8-chrome-100.png │ ├── icons8-firefox-100.png │ ├── icons8-intellij-idea-100.png │ ├── icons8-memory-100.png │ ├── icons8-microsoft-edge-100.png │ ├── icons8-microsoft-excel-2019-100.png │ ├── icons8-microsoft-outlook-2019-100.png │ ├── icons8-microsoft-powerpoint-2019-100.png │ ├── icons8-microsoft-word-2019-100.png │ ├── icons8-notepad++-100.png │ ├── icons8-postman-api-100.png │ ├── icons8-pycharm-100.png │ ├── icons8-qq-100.png │ ├── icons8-sublime-text-100.png │ ├── icons8-visual-studio-100.png │ ├── icons8-visual-studio-code-2019-100.png │ ├── icons8-webstorm-100.png │ ├── icons8-wechat-100.png │ ├── icons8-windows-11-100.png │ ├── lceda-pro.ico │ ├── lceda.ico │ ├── navicat.png │ ├── phpstorm.png │ ├── tim.ico │ └── typora-128.png ├── AppShortcut │ ├── AltiumDesigner.json │ ├── DirectoryOpus.json │ ├── atom.json │ ├── chrome.json │ ├── edge.json │ ├── excel.json │ ├── explorer.json │ ├── firefox.json │ ├── intellij idea.json │ ├── lceda-pro.json │ ├── lceda.json │ ├── littletips.json │ ├── navicat.json │ ├── notepad++.json │ ├── outlook.json │ ├── phpstorm.json │ ├── postman.json │ ├── powerpnt.json │ ├── pycharm.json │ ├── sublime.json │ ├── typora.json │ ├── visual studio.json │ ├── vs code.json │ ├── webstorm.json │ └── word.json ├── ControlTemplates │ ├── CustomListBoxControlTemplate.xaml │ ├── CustomListBoxItemControlTemplate.xaml │ ├── CustomWindowTemplate.xaml │ └── ScrollViewer.xaml ├── Converters │ ├── BoolToCollapsedConverter.cs │ ├── BoolToVisibilityConverter.cs │ ├── ImagePathConverter.cs │ ├── ModifierKeyIndexToStringConverter.cs │ └── StarConverter.cs ├── CustomStyleSelector │ ├── ListBoxItemDataTemplateSelector.cs │ └── ListBoxItemStyleSelector.cs ├── Dto │ ├── ActivateResult.cs │ ├── App.cs │ └── CheckUpdateDto.cs ├── Fonts │ ├── Favorites.ttf │ ├── Fonts.xaml │ ├── JetBrainsMono │ │ ├── JetBrainsMono-Bold-Italic.ttf │ │ ├── JetBrainsMono-Bold.ttf │ │ ├── JetBrainsMono-BoldItalic.ttf │ │ ├── JetBrainsMono-ExtraBold.ttf │ │ ├── JetBrainsMono-ExtraBoldItalic.ttf │ │ ├── JetBrainsMono-ExtraLight.ttf │ │ ├── JetBrainsMono-ExtraLightItalic.ttf │ │ ├── JetBrainsMono-Italic.ttf │ │ ├── JetBrainsMono-Light.ttf │ │ ├── JetBrainsMono-LightItalic.ttf │ │ ├── JetBrainsMono-Medium.ttf │ │ ├── JetBrainsMono-MediumItalic.ttf │ │ ├── JetBrainsMono-Regular.ttf │ │ ├── JetBrainsMono-Thin.ttf │ │ └── JetBrainsMono-ThinItalic.ttf │ ├── iconfont.ttf │ └── segoe.ttf ├── Images │ ├── icons8-memory-100.ico │ ├── icons8-memory-100.png │ ├── icons8-receive-cash-48.png │ ├── icons8-receive-cash-96.png │ └── icons8-unknown-100.png ├── LittleTips.csproj ├── Properties │ ├── AssemblyInfo.cs │ ├── Resources.Designer.cs │ ├── Resources.resx │ ├── Settings.Designer.cs │ └── Settings.settings ├── Styles │ ├── Buttons.xaml │ ├── CustomGroupBoxStyle.xaml │ ├── CustomWindowStyle.xaml │ ├── DarkColors.xaml │ └── LightColors.xaml ├── Utils │ ├── ActiveWindow.cs │ ├── Common.cs │ ├── ID.cs │ ├── KeyboardHook.cs │ └── WindowBlur.cs ├── ViewModels │ ├── MainModel.cs │ ├── NotAdaptedModel.cs │ └── Shortcut.cs ├── Views │ ├── DonateWindow.xaml │ ├── DonateWindow.xaml.cs │ ├── MainWindow.xaml │ ├── MainWindow.xaml.cs │ ├── NotAdaptedWindow.xaml │ ├── NotAdaptedWindow.xaml.cs │ ├── TipsWindow.xaml │ ├── TipsWindow.xaml.cs │ ├── XMessageBox.xaml │ └── XMessageBox.xaml.cs ├── icons8-memory-100.ico └── light-bulb.ico ├── README.md ├── donate.jpg ├── icons8-paypal-48.png ├── licence.md └── screenshot.png /.gitignore: -------------------------------------------------------------------------------- 1 | bin/ 2 | .idea/ 3 | .vs/ 4 | obj/ 5 | /packages/ 6 | riderModule.iml 7 | /_ReSharper.Caches/ 8 | AppPackages/ 9 | BundleArtifacts/ -------------------------------------------------------------------------------- /LittleTips.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LittleTips", "LittleTips\LittleTips.csproj", "{2640DC0F-DA0F-40F3-BF2A-27B2228EF080}" 4 | EndProject 5 | Global 6 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 7 | Debug|Any CPU = Debug|Any CPU 8 | Release|Any CPU = Release|Any CPU 9 | EndGlobalSection 10 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 11 | {2640DC0F-DA0F-40F3-BF2A-27B2228EF080}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 12 | {2640DC0F-DA0F-40F3-BF2A-27B2228EF080}.Debug|Any CPU.Build.0 = Debug|Any CPU 13 | {2640DC0F-DA0F-40F3-BF2A-27B2228EF080}.Release|Any CPU.ActiveCfg = Release|Any CPU 14 | {2640DC0F-DA0F-40F3-BF2A-27B2228EF080}.Release|Any CPU.Build.0 = Release|Any CPU 15 | EndGlobalSection 16 | EndGlobal 17 | -------------------------------------------------------------------------------- /LittleTips/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 |
6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | False 15 | 16 | 17 | True 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | False 27 | 28 | 29 | 0 30 | 31 | 32 | 0 33 | 34 | 35 | 0 36 | 37 | 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /LittleTips/App.xaml: -------------------------------------------------------------------------------- 1 |  6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /LittleTips/App.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Threading.Tasks; 3 | using System.Windows; 4 | 5 | namespace LittleTips 6 | { 7 | public partial class App 8 | { 9 | public static readonly string VersionNumber = "1.0.5.2"; 10 | public static readonly string Version = $"Build Version {VersionNumber}, build on 2022.12"; 11 | public static readonly string Host = "https://github.com/chenjing1294/Little-Tips"; 12 | 13 | protected override void OnStartup(StartupEventArgs e) 14 | { 15 | RegisterEvents(); 16 | base.OnStartup(e); 17 | } 18 | 19 | #region 异常处理 20 | 21 | private void RegisterEvents() 22 | { 23 | //Task线程内未捕获异常处理事件 24 | TaskScheduler.UnobservedTaskException += TaskScheduler_UnobservedTaskException; 25 | 26 | //UI线程未捕获异常处理事件(UI主线程) 27 | this.DispatcherUnhandledException += App_DispatcherUnhandledException; 28 | 29 | //非UI线程未捕获异常处理事件(例如自己创建的一个子线程) 30 | AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException; 31 | } 32 | 33 | private static void TaskScheduler_UnobservedTaskException(object sender, UnobservedTaskExceptionEventArgs e) 34 | { 35 | try 36 | { 37 | if (e.Exception is Exception exception) 38 | { 39 | HandleException(exception); 40 | } 41 | } 42 | catch (Exception ex) 43 | { 44 | HandleException(ex); 45 | } 46 | finally 47 | { 48 | e.SetObserved(); 49 | } 50 | } 51 | 52 | //非UI线程未捕获异常处理事件(例如自己创建的一个子线程) 53 | private static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e) 54 | { 55 | try 56 | { 57 | if (e.ExceptionObject is Exception exception) 58 | { 59 | HandleException(exception); 60 | } 61 | } 62 | catch (Exception ex) 63 | { 64 | HandleException(ex); 65 | } 66 | } 67 | 68 | //UI线程未捕获异常处理事件(UI主线程) 69 | private static void App_DispatcherUnhandledException(object sender, System.Windows.Threading.DispatcherUnhandledExceptionEventArgs e) 70 | { 71 | try 72 | { 73 | HandleException(e.Exception); 74 | } 75 | catch (Exception ex) 76 | { 77 | HandleException(ex); 78 | } 79 | finally 80 | { 81 | e.Handled = true; 82 | } 83 | } 84 | 85 | private static void HandleException(Exception ex) 86 | { 87 | //记录日志 88 | string msg = ex.InnerException != null ? ex.InnerException.Message : ex.Message; 89 | MessageBox.Show(msg); 90 | } 91 | 92 | #endregion 93 | } 94 | } -------------------------------------------------------------------------------- /LittleTips/AppIcon/altium-designer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/altium-designer.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/directory-opus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/directory-opus.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-atom-editor-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-atom-editor-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-chrome-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-chrome-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-firefox-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-firefox-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-intellij-idea-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-intellij-idea-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-memory-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-memory-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-microsoft-edge-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-microsoft-edge-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-microsoft-excel-2019-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-microsoft-excel-2019-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-microsoft-outlook-2019-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-microsoft-outlook-2019-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-microsoft-powerpoint-2019-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-microsoft-powerpoint-2019-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-microsoft-word-2019-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-microsoft-word-2019-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-notepad++-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-notepad++-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-postman-api-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-postman-api-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-pycharm-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-pycharm-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-qq-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-qq-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-sublime-text-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-sublime-text-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-visual-studio-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-visual-studio-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-visual-studio-code-2019-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-visual-studio-code-2019-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-webstorm-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-webstorm-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-wechat-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-wechat-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/icons8-windows-11-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/icons8-windows-11-100.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/lceda-pro.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/lceda-pro.ico -------------------------------------------------------------------------------- /LittleTips/AppIcon/lceda.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/lceda.ico -------------------------------------------------------------------------------- /LittleTips/AppIcon/navicat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/navicat.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/phpstorm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/phpstorm.png -------------------------------------------------------------------------------- /LittleTips/AppIcon/tim.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/tim.ico -------------------------------------------------------------------------------- /LittleTips/AppIcon/typora-128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/AppIcon/typora-128.png -------------------------------------------------------------------------------- /LittleTips/AppShortcut/atom.json: -------------------------------------------------------------------------------- 1 | { 2 | "Id": "atom", 3 | "AppName": "Atom", 4 | "AppIcon": "icons8-atom-editor-100.png", 5 | "Categories": [ 6 | { 7 | "ChineseCategoryName": "通用", 8 | "EnglishCategoryName": "General", 9 | "Keys": [ 10 | { 11 | "Id": "7be29c5a-a8b0-45e0-aea1-9fece3d62eb2", 12 | "ShortcutKey": "Ctrl+,", 13 | "ChineseFunctionDescription": "首选项/设置", 14 | "EnglishFunctionDescription": "Preferences/Settings" 15 | }, 16 | { 17 | "Id": "782c49db-e149-4eac-a975-37d22aaf50bb", 18 | "ShortcutKey": "Shift+Ctrl+P", 19 | "ChineseFunctionDescription": "命令面板", 20 | "EnglishFunctionDescription": "Command Palette" 21 | }, 22 | { 23 | "Id": "4be3f9ca-e2bc-47fd-b5c0-552d0829b79a", 24 | "ShortcutKey": "Ctrl+P", 25 | "ChineseFunctionDescription": "打开文件", 26 | "EnglishFunctionDescription": "Open File (Fuzzy)" 27 | }, 28 | { 29 | "Id": "63285633-cd5c-4bc8-b3d7-87c0ab584188", 30 | "ShortcutKey": "Ctrl+T", 31 | "ChineseFunctionDescription": "打开文件", 32 | "EnglishFunctionDescription": "Open File (Fuzzy)" 33 | }, 34 | { 35 | "Id": "e8d041c1-0fd3-4ca8-981c-d8701458bb60", 36 | "ShortcutKey": "Ctrl+B", 37 | "ChineseFunctionDescription": "浏览打开的文件", 38 | "EnglishFunctionDescription": "Browse Open Files" 39 | }, 40 | { 41 | "Id": "3248b579-af6c-4baf-9673-1d80c4bb11ce", 42 | "ShortcutKey": "Ctrl+Pageup", 43 | "ChineseFunctionDescription": "上一个标签", 44 | "EnglishFunctionDescription": "Previous Tab" 45 | }, 46 | { 47 | "Id": "f57813e9-3884-4b5c-a5ef-85f9cb0a45aa", 48 | "ShortcutKey": "Ctrl+Pagedown", 49 | "ChineseFunctionDescription": "下一个标签", 50 | "EnglishFunctionDescription": "Next Tab" 51 | }, 52 | { 53 | "Id": "e5899b97-e1be-4068-9ec3-cc00f3b61399", 54 | "ShortcutKey": "Ctrl+Shift+L", 55 | "ChineseFunctionDescription": "语法选择器", 56 | "EnglishFunctionDescription": "Grammar Selector" 57 | }, 58 | { 59 | "Id": "e56cc6c6-6170-4226-836f-0b9c87b4c1e1", 60 | "ShortcutKey": "Ctrl+Shift+M", 61 | "ChineseFunctionDescription": "Markdown预览", 62 | "EnglishFunctionDescription": "Markdown Preview" 63 | }, 64 | { 65 | "Id": "d6aa590d-26c0-4e2f-b02f-3d79d222acb3", 66 | "ShortcutKey": "Ctrl+.", 67 | "ChineseFunctionDescription": "键绑定解析器", 68 | "EnglishFunctionDescription": "Key Binding Resolver" 69 | }, 70 | { 71 | "Id": "48628af6-d2b5-4e9e-8336-e360297fe639", 72 | "ShortcutKey": "Ctrl+K,Ctrl+B", 73 | "ChineseFunctionDescription": "切换树视图", 74 | "EnglishFunctionDescription": "Toggle Tree View" 75 | }, 76 | { 77 | "Id": "50eeea07-c4ca-493a-a25e-aa9efb2c0cba", 78 | "ShortcutKey": "Ctrl+\\", 79 | "ChineseFunctionDescription": "切换树视图", 80 | "EnglishFunctionDescription": "Toggle Tree View" 81 | }, 82 | { 83 | "Id": "bf5c675f-5066-4cab-8b55-3c3097f112ee", 84 | "ShortcutKey": "Alt+Ctrl+R", 85 | "ChineseFunctionDescription": "重新加载Atom", 86 | "EnglishFunctionDescription": "Reload Atom" 87 | }, 88 | { 89 | "Id": "9e774a09-f21f-42d3-9408-968c39e46757", 90 | "ShortcutKey": "Ctrl+Alt+I", 91 | "ChineseFunctionDescription": "开发人员工具", 92 | "EnglishFunctionDescription": "Toggle Developer Tools" 93 | }, 94 | { 95 | "Id": "a68ce405-067e-4e4f-aca3-167e9734bd06", 96 | "ShortcutKey": "Alt+Shift+S", 97 | "ChineseFunctionDescription": "显示可用片段", 98 | "EnglishFunctionDescription": "Show Available Snippets" 99 | } 100 | ] 101 | }, 102 | { 103 | "ChineseCategoryName": "窗口管理", 104 | "EnglishCategoryName": "Window Management", 105 | "Keys": [ 106 | { 107 | "Id": "67b5fda2-1d3d-4d01-96e0-d2804f053c73", 108 | "ShortcutKey": "Ctrl+N", 109 | "ChineseFunctionDescription": "新文件", 110 | "EnglishFunctionDescription": "New File" 111 | }, 112 | { 113 | "Id": "d2592c1a-a1ef-4441-a804-23a5413b7b02", 114 | "ShortcutKey": "Ctrl+Shift+N", 115 | "ChineseFunctionDescription": "新窗口", 116 | "EnglishFunctionDescription": "New Window" 117 | }, 118 | { 119 | "Id": "42f4fa67-ab5a-4cc4-83cd-18e86da3c0db", 120 | "ShortcutKey": "Ctrl+O", 121 | "ChineseFunctionDescription": "打开", 122 | "EnglishFunctionDescription": "Open" 123 | }, 124 | { 125 | "Id": "fb26cd13-38b9-4ee3-a963-0604f3cffe11", 126 | "ShortcutKey": "Ctrl+Shift+O", 127 | "ChineseFunctionDescription": "打开目录", 128 | "EnglishFunctionDescription": "Open Folder" 129 | }, 130 | { 131 | "Id": "ae5f75ef-a722-4142-8bcb-2442790b6b9d", 132 | "ShortcutKey": "Ctrl+S", 133 | "ChineseFunctionDescription": "保存", 134 | "EnglishFunctionDescription": "Save" 135 | }, 136 | { 137 | "Id": "90e0d76d-2299-4053-ace7-9ff1a046b88a", 138 | "ShortcutKey": "Ctrl+Shift+S", 139 | "ChineseFunctionDescription": "另存为", 140 | "EnglishFunctionDescription": "Save As" 141 | }, 142 | { 143 | "Id": "00027812-9caf-4a4c-b565-4b0045eaf7f7", 144 | "ShortcutKey": "Ctrl+W", 145 | "ChineseFunctionDescription": "关闭标签", 146 | "EnglishFunctionDescription": "Close Tab" 147 | }, 148 | { 149 | "Id": "4c304692-49cc-4b3a-b82e-2862d531d14e", 150 | "ShortcutKey": "Ctrl+Shift+W", 151 | "ChineseFunctionDescription": "关闭窗口", 152 | "EnglishFunctionDescription": "Close Window" 153 | }, 154 | { 155 | "Id": "04563e44-6702-42b9-a56e-2e00e048872e", 156 | "ShortcutKey": "Ctrl+K,↑/↓/←/→", 157 | "ChineseFunctionDescription": "拆分窗口", 158 | "EnglishFunctionDescription": "Split Window" 159 | }, 160 | { 161 | "Id": "1859e87f-5951-4990-9ff0-9ca5b0211674", 162 | "ShortcutKey": "Ctrl+K,Ctrl+↑/↓/←/→", 163 | "ChineseFunctionDescription": "焦点窗格", 164 | "EnglishFunctionDescription": "Focus Pane" 165 | }, 166 | { 167 | "Id": "23a040d3-aeea-4566-8ca8-2c5bcf4eef07", 168 | "ShortcutKey": "F11", 169 | "ChineseFunctionDescription": "切换全屏", 170 | "EnglishFunctionDescription": "Toggle full screen" 171 | } 172 | ] 173 | }, 174 | { 175 | "ChineseCategoryName": "编辑", 176 | "EnglishCategoryName": "Editing", 177 | "Keys": [ 178 | { 179 | "Id": "957f9ceb-282f-4ba7-8b4f-c142a4f848ec", 180 | "ShortcutKey": "Ctrl+Shift+D", 181 | "ChineseFunctionDescription": "复制行", 182 | "EnglishFunctionDescription": "Duplicate Lines" 183 | }, 184 | { 185 | "Id": "6227d2cd-e16b-4def-9181-cd5162e0cf32", 186 | "ShortcutKey": "Ctrl+Shift+K", 187 | "ChineseFunctionDescription": "删除行", 188 | "EnglishFunctionDescription": "Delete Line" 189 | }, 190 | { 191 | "Id": "3170e7f9-9888-4be9-bf39-c7b855e98e39", 192 | "ShortcutKey": "Ctrl+↑", 193 | "ChineseFunctionDescription": "向上移动行", 194 | "EnglishFunctionDescription": "Move Line Up" 195 | }, 196 | { 197 | "Id": "ce37e7b4-cffc-4b72-9ce5-0cbbab6500f8", 198 | "ShortcutKey": "Ctrl+↓", 199 | "ChineseFunctionDescription": "向下移动行", 200 | "EnglishFunctionDescription": "Move Line Down" 201 | }, 202 | { 203 | "Id": "a6602aaa-ef35-41e8-a45a-1378112bb775", 204 | "ShortcutKey": "Ctrl+F", 205 | "ChineseFunctionDescription": "查找/替换", 206 | "EnglishFunctionDescription": "Find/Replace" 207 | }, 208 | { 209 | "Id": "c2327245-4936-402d-ab6b-932e9b9d960f", 210 | "ShortcutKey": "F3", 211 | "ChineseFunctionDescription": "查找下一个", 212 | "EnglishFunctionDescription": "Find Next" 213 | }, 214 | { 215 | "Id": "014e533f-4d66-49f2-a505-7d69fa9353ee", 216 | "ShortcutKey": "Shift+F3", 217 | "ChineseFunctionDescription": "查找上一个", 218 | "EnglishFunctionDescription": "Find Previous" 219 | }, 220 | { 221 | "Id": "bb04d6e1-c95d-4985-a87f-393ed90dbc78", 222 | "ShortcutKey": "Ctrl+Shift+F", 223 | "ChineseFunctionDescription": "在项目中查找", 224 | "EnglishFunctionDescription": "Find in Project" 225 | }, 226 | { 227 | "Id": "0b81adbb-cf8d-467e-af89-73649289445a", 228 | "ShortcutKey": "Ctrl+G", 229 | "ChineseFunctionDescription": "转到行", 230 | "EnglishFunctionDescription": "Go To Line" 231 | }, 232 | { 233 | "Id": "7235bca4-12ff-4431-8ef5-71e44f9391ce", 234 | "ShortcutKey": "Ctrl+M", 235 | "ChineseFunctionDescription": "转到匹配的支架", 236 | "EnglishFunctionDescription": "Go To Matching Bracket" 237 | }, 238 | { 239 | "Id": "b973aaa8-957a-433f-a17f-42f1e6bd5b73", 240 | "ShortcutKey": "Ctrl+L", 241 | "ChineseFunctionDescription": "选择行", 242 | "EnglishFunctionDescription": "Select Line" 243 | }, 244 | { 245 | "Id": "f12d3dc7-1942-46ca-9c53-d5c2da1e8311", 246 | "ShortcutKey": "Ctrl+/", 247 | "ChineseFunctionDescription": "注释", 248 | "EnglishFunctionDescription": "Toggle Comment" 249 | }, 250 | { 251 | "Id": "1214e7aa-ee1f-49c3-828d-42c5a00be2a1", 252 | "ShortcutKey": "Ctrl+Alt+↑/↓", 253 | "ChineseFunctionDescription": "列选择", 254 | "EnglishFunctionDescription": "Column Selection" 255 | }, 256 | { 257 | "Id": "d4c04402-c69b-4f23-bb30-d97fb13d44b9", 258 | "ShortcutKey": "Ctrl+D", 259 | "ChineseFunctionDescription": "选择相同的词", 260 | "EnglishFunctionDescription": "Select Same Words" 261 | }, 262 | { 263 | "Id": "21fa7f81-0066-4857-8eb4-0c72a697977d", 264 | "ShortcutKey": "Ctrl+U", 265 | "ChineseFunctionDescription": "撤消选择", 266 | "EnglishFunctionDescription": "Undo Selection" 267 | }, 268 | { 269 | "Id": "08034710-464e-4928-9d2c-84f4c3b7e66a", 270 | "ShortcutKey": "Alt+F3", 271 | "ChineseFunctionDescription": "一次选择所有相同的单词", 272 | "EnglishFunctionDescription": "Select All The Same Words At Once" 273 | }, 274 | { 275 | "Id": "a59446bb-eb61-457e-a18c-94c2162b1824", 276 | "ShortcutKey": "Ctrl+R", 277 | "ChineseFunctionDescription": "显示符号调色板", 278 | "EnglishFunctionDescription": "Show Symbols Palette" 279 | }, 280 | { 281 | "Id": "ea887b97-9463-49df-9302-a398ce2ebffd", 282 | "ShortcutKey": "Ctrl+Space", 283 | "ChineseFunctionDescription": "显示自动完成", 284 | "EnglishFunctionDescription": "Show auto-completions" 285 | }, 286 | { 287 | "Id": "ce0a38fb-a4b9-49b2-b635-11ff520ff6bb", 288 | "ShortcutKey": "Ctrl+Alt+[", 289 | "ChineseFunctionDescription": "折叠代码段", 290 | "EnglishFunctionDescription": "Fold sections of code" 291 | }, 292 | { 293 | "Id": "a6e1f4aa-a38b-4164-9c0e-3126160848c7", 294 | "ShortcutKey": "Ctrl+Alt+]", 295 | "ChineseFunctionDescription": "展开代码段", 296 | "EnglishFunctionDescription": "Unfold sections of code" 297 | }, 298 | { 299 | "Id": "d8cfc445-ca05-4cb9-a382-e97e42749fcf", 300 | "ShortcutKey": "Ctrl+K,Ctrl+(0-9)", 301 | "ChineseFunctionDescription": "在特定缩进级别折叠/展开", 302 | "EnglishFunctionDescription": "Fold/Unfold at a specific indentation level" 303 | } 304 | ] 305 | }, 306 | { 307 | "ChineseCategoryName": "各种包", 308 | "EnglishCategoryName": "Various Packages", 309 | "Keys": [ 310 | { 311 | "Id": "6c354a01-e1d5-46d2-992a-da4480fe0952", 312 | "ShortcutKey": "Ctrl+Alt+B", 313 | "ChineseFunctionDescription": "构建项目", 314 | "EnglishFunctionDescription": "Build Project" 315 | }, 316 | { 317 | "Id": "6ddfb26b-37b5-4ee0-ac39-4d9db936cc0a", 318 | "ShortcutKey": "Ctrl+E", 319 | "ChineseFunctionDescription": "展开缩写", 320 | "EnglishFunctionDescription": "Expand Abbreviation" 321 | }, 322 | { 323 | "Id": "0372a59d-1023-4a2d-8c48-4e8290aab461", 324 | "ShortcutKey": "Ctrl+Shift+H", 325 | "ChineseFunctionDescription": "Git Plus 菜单", 326 | "EnglishFunctionDescription": "Git Plus Menu" 327 | }, 328 | { 329 | "Id": "f8366099-9889-4cb5-9ccc-5c1555961886", 330 | "ShortcutKey": "Alt+Shift+P", 331 | "ChineseFunctionDescription": "打开项目", 332 | "EnglishFunctionDescription": "Open Project" 333 | } 334 | ] 335 | } 336 | ] 337 | } -------------------------------------------------------------------------------- /LittleTips/AppShortcut/littletips.json: -------------------------------------------------------------------------------- 1 | { 2 | "Id": "littletips", 3 | "AppName": "Little Tips", 4 | "AppIcon": "icons8-memory-100.png", 5 | "Categories": [ 6 | { 7 | "ChineseCategoryName": "通用", 8 | "EnglishCategoryName": "General", 9 | "Keys": [ 10 | { 11 | "Id": "46664ff8-a593-11ec-859e-00ffd0778ed8", 12 | "ShortcutKey": "Ctrl+`", 13 | "ChineseFunctionDescription": "显示活动窗口的快捷键列表", 14 | "EnglishFunctionDescription": "Displays a list of shortcut keys for the active window" 15 | } 16 | ] 17 | } 18 | ] 19 | } -------------------------------------------------------------------------------- /LittleTips/AppShortcut/postman.json: -------------------------------------------------------------------------------- 1 | { 2 | "Id": "postman", 3 | "AppName": "Google Postman", 4 | "AppIcon": "icons8-postman-api-100.png", 5 | "Categories": [ 6 | { 7 | "ChineseCategoryName": "通用", 8 | "EnglishCategoryName": "General", 9 | "Keys": [ 10 | { 11 | "Id": "63410450-1be6-4e35-843a-e3c4013c4436", 12 | "ShortcutKey": "Ctrl+S", 13 | "ChineseFunctionDescription": "保存", 14 | "EnglishFunctionDescription": "Save" 15 | }, 16 | { 17 | "Id": "48f9b4aa-477c-4750-adfa-6425263a7a17", 18 | "ShortcutKey": "Ctrl+Shift+S", 19 | "ChineseFunctionDescription": "另存为", 20 | "EnglishFunctionDescription": "Save as" 21 | }, 22 | { 23 | "Id": "b6934b71-7bf6-4f9b-83e2-b7bb30cda720", 24 | "ShortcutKey": "Ctrl+Enter", 25 | "ChineseFunctionDescription": "发送请求", 26 | "EnglishFunctionDescription": "Send request" 27 | }, 28 | { 29 | "Id": "7dc2e110-b73e-4e2a-9896-110f1cd6dd43", 30 | "ShortcutKey": "Ctrl+\\", 31 | "ChineseFunctionDescription": "切换侧边栏", 32 | "EnglishFunctionDescription": "Toggle sidebar" 33 | }, 34 | { 35 | "Id": "1c1725e7-0eac-4a52-a6d7-8bff4ff7f9c5", 36 | "ShortcutKey": "Ctrl+L", 37 | "ChineseFunctionDescription": "跳转到URL栏", 38 | "EnglishFunctionDescription": "Jump to URL" 39 | }, 40 | { 41 | "Id": "72de8b0a-b81f-4e6a-bed2-0a12324bccef", 42 | "ShortcutKey": "Ctrl+Alt+C", 43 | "ChineseFunctionDescription": "打开控制台", 44 | "EnglishFunctionDescription": "Open console" 45 | } 46 | ] 47 | }, 48 | { 49 | "ChineseCategoryName": "导航", 50 | "EnglishCategoryName": "Navigation", 51 | "Keys": [ 52 | { 53 | "Id": "43e9d3c8-281c-46eb-bd1b-437fec1f412c", 54 | "ShortcutKey": "Ctrl+Alt+1", 55 | "ChineseFunctionDescription": "侧边栏", 56 | "EnglishFunctionDescription": "Focus sidebar" 57 | }, 58 | { 59 | "Id": "1f1dc271-8a00-49e0-b3ce-7cceac05dc20", 60 | "ShortcutKey": "Ctrl+Alt+2", 61 | "ChineseFunctionDescription": "生成器", 62 | "EnglishFunctionDescription": "Focus builder" 63 | }, 64 | { 65 | "Id": "68e84d52-05f8-49f0-b7a1-b9a77d515cb2", 66 | "ShortcutKey": "Ctrl+1 throw 9", 67 | "ChineseFunctionDescription": "切换第 n 个选项卡", 68 | "EnglishFunctionDescription": "Focus on nth tab" 69 | }, 70 | { 71 | "Id": "6404db1a-fb88-4325-a2b2-c69bd2605f7f", 72 | "ShortcutKey": "Ctrl+Shift+/", 73 | "ChineseFunctionDescription": "在选项卡之间切换", 74 | "EnglishFunctionDescription": "Switch between tabs" 75 | } 76 | ] 77 | }, 78 | { 79 | "ChineseCategoryName": "侧边栏", 80 | "EnglishCategoryName": "Sidebar", 81 | "Keys": [ 82 | { 83 | "Id": "91f2c7d4-0f78-4343-bfe8-4e3b41999111", 84 | "ShortcutKey": "↓", 85 | "ChineseFunctionDescription": "移至下一项", 86 | "EnglishFunctionDescription": "Move to next item" 87 | }, 88 | { 89 | "Id": "33f92bd3-7b51-45c5-bc75-b7f6c3eae327", 90 | "ShortcutKey": "↑", 91 | "ChineseFunctionDescription": "移至上一项", 92 | "EnglishFunctionDescription": "Move to previous item" 93 | }, 94 | { 95 | "Id": "082c234f-ce10-4488-a50a-4b7423bdaefa", 96 | "ShortcutKey": "←", 97 | "ChineseFunctionDescription": "收起收藏夹/文件夹", 98 | "EnglishFunctionDescription": "Collapse collection / folder" 99 | }, 100 | { 101 | "Id": "4256c21c-b256-4e04-92c8-23070b948e75", 102 | "ShortcutKey": "→", 103 | "ChineseFunctionDescription": "展开收藏夹/文件夹", 104 | "EnglishFunctionDescription": "Expand collection / folder" 105 | }, 106 | { 107 | "Id": "3ae79804-3f39-4769-9d40-40ee789ec76f", 108 | "ShortcutKey": "Shift+↓", 109 | "ChineseFunctionDescription": "选择当前和下一个项目", 110 | "EnglishFunctionDescription": "Select current and next item" 111 | }, 112 | { 113 | "Id": "82c438d6-41f3-4843-9bfd-47a8dc7dd283", 114 | "ShortcutKey": "Shift+↑", 115 | "ChineseFunctionDescription": "选择当前和上一个项目", 116 | "EnglishFunctionDescription": "Select current and previous item" 117 | }, 118 | { 119 | "Id": "5f8d21dc-f66a-4846-b53d-f5424195c9d7", 120 | "ShortcutKey": "Ctrl+F", 121 | "ChineseFunctionDescription": "搜索边栏", 122 | "EnglishFunctionDescription": "Search sidebar" 123 | }, 124 | { 125 | "Id": "3790cd74-cead-41e9-b435-985f2bf66192", 126 | "ShortcutKey": "Enter", 127 | "ChineseFunctionDescription": "在选项卡中打开请求", 128 | "EnglishFunctionDescription": "Open request in a tab" 129 | } 130 | ] 131 | }, 132 | { 133 | "ChineseCategoryName": "编辑", 134 | "EnglishCategoryName": "Edit", 135 | "Keys": [ 136 | { 137 | "Id": "bdc2b849-79b1-46aa-a677-40b0d83ab545", 138 | "ShortcutKey": "Ctrl+C", 139 | "ChineseFunctionDescription": "复制", 140 | "EnglishFunctionDescription": "Copy" 141 | }, 142 | { 143 | "Id": "2e7fa1cf-fd70-4b26-8b5c-cf1e997dd0fe", 144 | "ShortcutKey": "Ctrl+V", 145 | "ChineseFunctionDescription": "粘贴", 146 | "EnglishFunctionDescription": "Paste" 147 | }, 148 | { 149 | "Id": "c74bd1b2-296e-4058-b327-7032fc4dd6a0", 150 | "ShortcutKey": "Ctrl+D", 151 | "ChineseFunctionDescription": "复制", 152 | "EnglishFunctionDescription": "Duplicate" 153 | }, 154 | { 155 | "Id": "72450356-a346-49f7-aa75-afbf836aca5c", 156 | "ShortcutKey": "Ctrl+E", 157 | "ChineseFunctionDescription": "编辑/重命名", 158 | "EnglishFunctionDescription": "Edit / Rename" 159 | } 160 | ] 161 | } 162 | ] 163 | } -------------------------------------------------------------------------------- /LittleTips/AppShortcut/sublime.json: -------------------------------------------------------------------------------- 1 | { 2 | "Id": "sublime", 3 | "AppName": "Sublime", 4 | "AppIcon": "icons8-sublime-text-100.png", 5 | "Categories": [ 6 | { 7 | "ChineseCategoryName": "编辑", 8 | "EnglishCategoryName": "Edit", 9 | "Keys": [ 10 | { 11 | "Id": "9a35a4e6-67ea-408e-8447-1e4dab9e4e4c", 12 | "ShortcutKey": "Ctrl+X", 13 | "ChineseFunctionDescription": "剪切一行", 14 | "EnglishFunctionDescription": "Cut line" 15 | }, 16 | { 17 | "Id": "361ae28b-bffb-4aa0-a195-f772d57ce2d9", 18 | "ShortcutKey": "Ctrl+Enter", 19 | "ChineseFunctionDescription": "在后面插入行", 20 | "EnglishFunctionDescription": "Insert line after" 21 | }, 22 | { 23 | "Id": "3b4f8944-af50-4a7e-b7ff-32f1aafcd895", 24 | "ShortcutKey": "Shift+Ctrl+Enter", 25 | "ChineseFunctionDescription": "在前面插入行", 26 | "EnglishFunctionDescription": "Insert line before" 27 | }, 28 | { 29 | "Id": "0dd0a415-dc86-4561-ad80-af12ce031ed4", 30 | "ShortcutKey": "Shift+Ctrl+UP", 31 | "ChineseFunctionDescription": "向上移动行", 32 | "EnglishFunctionDescription": "Move line/selection up" 33 | }, 34 | { 35 | "Id": "6f79379e-875a-4fc6-80ea-0d1c192fc74b", 36 | "ShortcutKey": "Shift+Ctrl+DOWN", 37 | "ChineseFunctionDescription": "向下移动行", 38 | "EnglishFunctionDescription": "Move line/selection down" 39 | }, 40 | { 41 | "Id": "70daae80-44e6-45dd-b3e5-3061872bd360", 42 | "ShortcutKey": "Ctrl+L", 43 | "ChineseFunctionDescription": "选择行 - 重复以选择下一行", 44 | "EnglishFunctionDescription": "Select line - Repeat to select next lines" 45 | }, 46 | { 47 | "Id": "585fe40c-8a41-4203-87a8-6eaeb9e664aa", 48 | "ShortcutKey": "Ctrl+D", 49 | "ChineseFunctionDescription": "选择单词 - 重复选择其他出现", 50 | "EnglishFunctionDescription": "Select word - repeat select other occurrences" 51 | }, 52 | { 53 | "Id": "bae38fa5-2666-4c56-86e1-23681f6d9bed", 54 | "ShortcutKey": "Ctrl+M", 55 | "ChineseFunctionDescription": "转到匹配的括号", 56 | "EnglishFunctionDescription": "Go to matching parentheses" 57 | }, 58 | { 59 | "Id": "7eb47c71-025f-431d-acfa-442399679d39", 60 | "ShortcutKey": "Shift+Ctrl+M", 61 | "ChineseFunctionDescription": "选择当前括号的所有内容", 62 | "EnglishFunctionDescription": "Select all contents of the current parentheses" 63 | }, 64 | { 65 | "Id": "3bd3ad20-4670-44f0-aa18-fba2b072e179", 66 | "ShortcutKey": "Ctrl+K,Ctrl+K", 67 | "ChineseFunctionDescription": "从光标处删除到行尾", 68 | "EnglishFunctionDescription": "Delete from cursor to end of line" 69 | }, 70 | { 71 | "Id": "b6afc461-12c0-4586-9cdc-4b58abdc3d83", 72 | "ShortcutKey": "Ctrl+K,Ctrl+Backspace", 73 | "ChineseFunctionDescription": "从光标删除到行首", 74 | "EnglishFunctionDescription": "Delete from cursor to start of line" 75 | }, 76 | { 77 | "Id": "ba2e6063-4370-4691-aea6-2a465ae2d867", 78 | "ShortcutKey": "Ctrl+]", 79 | "ChineseFunctionDescription": "缩进当前行", 80 | "EnglishFunctionDescription": "Indent current line(s)" 81 | }, 82 | { 83 | "Id": "4b45bf4d-8d0a-4e5b-93ba-d596829f2350", 84 | "ShortcutKey": "Ctrl+[", 85 | "ChineseFunctionDescription": "取消缩进当前行", 86 | "EnglishFunctionDescription": "Un-indent current line(s)" 87 | }, 88 | { 89 | "Id": "fce59243-c47d-4004-9123-8e2c4e8a7d06", 90 | "ShortcutKey": "Shift+Ctrl+D", 91 | "ChineseFunctionDescription": "复制行", 92 | "EnglishFunctionDescription": "Duplicate line(s)" 93 | }, 94 | { 95 | "Id": "b2d23990-3dcd-4f8e-9ee8-fa4980df47bc", 96 | "ShortcutKey": "Ctrl+J", 97 | "ChineseFunctionDescription": "将下面的行加入到当前行的末尾", 98 | "EnglishFunctionDescription": "Join line below to the end of the current line" 99 | }, 100 | { 101 | "Id": "99f02fcb-835f-4ee5-80ec-57e8227a50e7", 102 | "ShortcutKey": "Ctrl+/", 103 | "ChineseFunctionDescription": "评论/取消注释当前行", 104 | "EnglishFunctionDescription": "Comment/un-comment current line" 105 | }, 106 | { 107 | "Id": "bc63b5d6-b6a7-4a89-9174-100cbbae60e3", 108 | "ShortcutKey": "Shift+Ctrl+/", 109 | "ChineseFunctionDescription": "阻止注释当前选择", 110 | "EnglishFunctionDescription": "Block comment current selection" 111 | }, 112 | { 113 | "Id": "04853d12-c810-4448-b1d1-e073e10ed55a", 114 | "ShortcutKey": "Ctrl+Y", 115 | "ChineseFunctionDescription": "重做或重复上一个键盘快捷键命令", 116 | "EnglishFunctionDescription": "Redo or repeat last keyboard shortcut command" 117 | }, 118 | { 119 | "Id": "8ed73c17-4932-45c0-ba51-c1055083df55", 120 | "ShortcutKey": "Shift+Ctrl+V", 121 | "ChineseFunctionDescription": "粘贴和缩进", 122 | "EnglishFunctionDescription": "Paste and indent correctly" 123 | }, 124 | { 125 | "Id": "e46eeb7b-a31c-423d-930e-ec15c3833910", 126 | "ShortcutKey": "Ctrl+Space", 127 | "ChineseFunctionDescription": "选择下一个自动完成建议", 128 | "EnglishFunctionDescription": "Select next auto-complete suggestion" 129 | }, 130 | { 131 | "Id": "39bc9e32-b71a-436a-a5c3-ee0bfbc0a0f7", 132 | "ShortcutKey": "Ctrl+U", 133 | "ChineseFunctionDescription": "撤销", 134 | "EnglishFunctionDescription": "Soft undo" 135 | } 136 | ] 137 | }, 138 | { 139 | "ChineseCategoryName": "导航", 140 | "EnglishCategoryName": "Navigation", 141 | "Keys": [ 142 | { 143 | "Id": "d8b989c8-0b9f-402a-b339-b5b9db0379a7", 144 | "ShortcutKey": "Ctrl+P", 145 | "ChineseFunctionDescription": "按名称快速打开文件", 146 | "EnglishFunctionDescription": "Quick-open files by name" 147 | }, 148 | { 149 | "Id": "e2edbbbf-ea71-4f65-bb3a-63d2ff515e88", 150 | "ShortcutKey": "Ctrl+;", 151 | "ChineseFunctionDescription": "转到当前文件中的单词", 152 | "EnglishFunctionDescription": "Goto word in current file" 153 | }, 154 | { 155 | "Id": "c89700f6-8d8c-460f-bb97-03f2817ee49d", 156 | "ShortcutKey": "Ctrl+R", 157 | "ChineseFunctionDescription": "转到符号", 158 | "EnglishFunctionDescription": "Goto symbol" 159 | }, 160 | { 161 | "Id": "55db0499-c2d6-4340-898b-9155109b6146", 162 | "ShortcutKey": "Ctrl+G", 163 | "ChineseFunctionDescription": "转到当前文件中的行", 164 | "EnglishFunctionDescription": "Goto line in current file" 165 | } 166 | ] 167 | }, 168 | { 169 | "ChineseCategoryName": "通用", 170 | "EnglishCategoryName": "General", 171 | "Keys": [ 172 | { 173 | "Id": "cf46ae7b-d220-4f90-aeec-221633a09207", 174 | "ShortcutKey": "Alt+.", 175 | "ChineseFunctionDescription": "关闭标签", 176 | "EnglishFunctionDescription": "Close tag" 177 | }, 178 | { 179 | "Id": "1a6bfa15-03f8-46b6-9847-cd151a157811", 180 | "ShortcutKey": "Ctrl+K,Ctrl+C", 181 | "ChineseFunctionDescription": "滚动到选择", 182 | "EnglishFunctionDescription": "Scroll to selection" 183 | }, 184 | { 185 | "Id": "e67f7dce-8e05-4822-b387-12f245d8125f", 186 | "ShortcutKey": "Shift+Ctrl+A", 187 | "ChineseFunctionDescription": "选择标签", 188 | "EnglishFunctionDescription": "Select tag" 189 | }, 190 | { 191 | "Id": "f833a6dd-3b8b-44d9-be6a-643c7f8a7d3b", 192 | "ShortcutKey": "Shift+Ctrl+J", 193 | "ChineseFunctionDescription": "选择缩进", 194 | "EnglishFunctionDescription": "Select indentation" 195 | }, 196 | { 197 | "Id": "9bdd811f-7a7d-4f64-90d5-ced3e3afb7c1", 198 | "ShortcutKey": "Shift+Ctrl+Space", 199 | "ChineseFunctionDescription": "选择范围", 200 | "EnglishFunctionDescription": "Select scope" 201 | }, 202 | { 203 | "Id": "d1eda93a-dd08-447d-9e00-6271b4b5fde8", 204 | "ShortcutKey": "Ctrl+K,Ctrl+B", 205 | "ChineseFunctionDescription": "切换侧边栏", 206 | "EnglishFunctionDescription": "Toggle side bar" 207 | }, 208 | { 209 | "Id": "e66726ce-e108-4cbf-a399-617fa4c8e041", 210 | "ShortcutKey": "Shift+Ctrl+P", 211 | "ChineseFunctionDescription": "命令提示符", 212 | "EnglishFunctionDescription": "Command prompt" 213 | } 214 | ] 215 | }, 216 | { 217 | "ChineseCategoryName": "查找/替换", 218 | "EnglishCategoryName": "Find/Replace", 219 | "Keys": [ 220 | { 221 | "Id": "0a04f75b-fb4a-4bf8-84eb-23d96cafe930", 222 | "ShortcutKey": "Shift+F3", 223 | "ChineseFunctionDescription": "查找上一个", 224 | "EnglishFunctionDescription": "Find previous" 225 | }, 226 | { 227 | "Id": "349d4627-319b-4543-8e5f-c1ba3a0d739a", 228 | "ShortcutKey": "F3", 229 | "ChineseFunctionDescription": "找下一个", 230 | "EnglishFunctionDescription": "Find next" 231 | }, 232 | { 233 | "Id": "755ded69-1449-4aab-bbad-45008495573b", 234 | "ShortcutKey": "Ctrl+F", 235 | "ChineseFunctionDescription": "查找", 236 | "EnglishFunctionDescription": "Find" 237 | }, 238 | { 239 | "Id": "e2cfd54b-41de-4dbd-a1e8-b3b6b52ca8b6", 240 | "ShortcutKey": "Ctrl+H", 241 | "ChineseFunctionDescription": "替换", 242 | "EnglishFunctionDescription": "Replace" 243 | }, 244 | { 245 | "Id": "cf06bab4-4382-46e4-a5d9-6337a15aca76", 246 | "ShortcutKey": "Shift+Ctrl+F", 247 | "ChineseFunctionDescription": "在文件中查找", 248 | "EnglishFunctionDescription": "Find in files" 249 | } 250 | ] 251 | }, 252 | { 253 | "ChineseCategoryName": "拆分窗口", 254 | "EnglishCategoryName": "Split window", 255 | "Keys": [ 256 | { 257 | "Id": "65669fc7-cbbb-42bb-a818-b300479f73a4", 258 | "ShortcutKey": "Shift+Alt+2", 259 | "ChineseFunctionDescription": "将视图拆分为两列", 260 | "EnglishFunctionDescription": "Split view into two columns" 261 | }, 262 | { 263 | "Id": "393b1fbc-b4fb-476b-ac0c-57cc6dcdba51", 264 | "ShortcutKey": "Shift+Alt+1", 265 | "ChineseFunctionDescription": "将视图还原为单列", 266 | "EnglishFunctionDescription": "Revert view to single column" 267 | }, 268 | { 269 | "Id": "df350a6c-46b6-4f09-a97a-11bd97166e8c", 270 | "ShortcutKey": "Shift+Alt+5", 271 | "ChineseFunctionDescription": "将视图设置为网格(4 组)", 272 | "EnglishFunctionDescription": "Set view to grid (4 groups)" 273 | }, 274 | { 275 | "Id": "fa6b976f-6e2f-44bf-a453-baf58c8016d6", 276 | "ShortcutKey": "Ctrl+2", 277 | "ChineseFunctionDescription": "跳到第 2 组", 278 | "EnglishFunctionDescription": "Jump to group 2" 279 | }, 280 | { 281 | "Id": "d889d7c9-fc39-40e4-af20-3fba0e575a5c", 282 | "ShortcutKey": "Shift+Ctrl+2", 283 | "ChineseFunctionDescription": "将文件移动到组 2", 284 | "EnglishFunctionDescription": "Move file to group 2" 285 | } 286 | ] 287 | }, 288 | { 289 | "ChineseCategoryName": "文本操作", 290 | "EnglishCategoryName": "Text manipulation", 291 | "Keys": [ 292 | { 293 | "Id": "02d2b3c4-638f-41ae-b662-b4a3eb51da5a", 294 | "ShortcutKey": "Ctrl+K,Ctrl+L", 295 | "ChineseFunctionDescription": "转换为小写", 296 | "EnglishFunctionDescription": "Transform to lowercase" 297 | }, 298 | { 299 | "Id": "5b5dc5cb-ae7d-49c3-b49f-c5f3cf572638", 300 | "ShortcutKey": "Ctrl+K,Ctrl+U", 301 | "ChineseFunctionDescription": "转换为大写", 302 | "EnglishFunctionDescription": "Transform to uppercase" 303 | }, 304 | { 305 | "Id": "f8162c6c-c3eb-478d-817f-b1927ff76785", 306 | "ShortcutKey": "Shift+c,Ctrl+K", 307 | "ChineseFunctionDescription": "删除行", 308 | "EnglishFunctionDescription": "Delete line" 309 | }, 310 | { 311 | "Id": "e467a5b0-e38d-4d4f-bb1a-7030e4df74cb", 312 | "ShortcutKey": "Ctrl+Backspace", 313 | "ChineseFunctionDescription": "向后删除单词", 314 | "EnglishFunctionDescription": "Delete word backwords" 315 | }, 316 | { 317 | "Id": "2460090b-f338-44be-add4-797f1c915173", 318 | "ShortcutKey": "Ctrl+Del", 319 | "ChineseFunctionDescription": "删除单词转发", 320 | "EnglishFunctionDescription": "Delete word forwards" 321 | } 322 | ] 323 | }, 324 | { 325 | "ChineseCategoryName": "文本选择", 326 | "EnglishCategoryName": "Text Selection", 327 | "Keys": [ 328 | { 329 | "Id": "f45e2fdb-6a74-49b8-9dd2-9411715f2c52", 330 | "ShortcutKey": "Alt+Ctrl+↓", 331 | "ChineseFunctionDescription": "用光标在下面添加新行", 332 | "EnglishFunctionDescription": "Add new line below with cursor" 333 | }, 334 | { 335 | "Id": "02394761-0565-43b9-b143-296d9252b227", 336 | "ShortcutKey": "Ctrl+K,Ctrl+D", 337 | "ChineseFunctionDescription": "跳过选择", 338 | "EnglishFunctionDescription": "Skip selection" 339 | }, 340 | { 341 | "Id": "9ee3bf7c-9f30-4c9f-9ae7-1ba02cdea19c", 342 | "ShortcutKey": "Shift+Ctrl+L", 343 | "ChineseFunctionDescription": "将选择拆分为行", 344 | "EnglishFunctionDescription": "Split selection into lines" 345 | }, 346 | { 347 | "Id": "d072e090-9fa6-4e08-a51c-df551b1e755e", 348 | "ShortcutKey": "Alt+F3", 349 | "ChineseFunctionDescription": "Add cursor at all occurrences of a word", 350 | "EnglishFunctionDescription": "Add cursor at all occurrences of a word" 351 | }, 352 | { 353 | "Id": "1e4d84ce-0f27-4d46-9a71-eba6939763a9", 354 | "ShortcutKey": "Alt+Ctrl+UP", 355 | "ChineseFunctionDescription": "用光标在上面添加新行", 356 | "EnglishFunctionDescription": "Add new line above with cursor" 357 | }, 358 | { 359 | "Id": "001544c2-572c-41a9-8fba-03fc292384b3", 360 | "ShortcutKey": "Esc", 361 | "ChineseFunctionDescription": "返回单选", 362 | "EnglishFunctionDescription": "Return to single selection" 363 | } 364 | ] 365 | }, 366 | { 367 | "ChineseCategoryName": "代码折叠和标记", 368 | "EnglishCategoryName": "Code Folding and Marks", 369 | "Keys": [ 370 | { 371 | "Id": "44bd59dd-8083-4fa2-af96-323b528a3f24", 372 | "ShortcutKey": "Ctrl+K,Ctrl+G", 373 | "ChineseFunctionDescription": "清除标记", 374 | "EnglishFunctionDescription": "Clear mark" 375 | }, 376 | { 377 | "Id": "743dc49f-32ee-4a0b-8969-6e9ed9ccbb80", 378 | "ShortcutKey": "Ctrl+K,Ctrl+X", 379 | "ChineseFunctionDescription": "用标记切换位置", 380 | "EnglishFunctionDescription": "Switch location with mark" 381 | }, 382 | { 383 | "Id": "824d699c-1987-4078-89ea-09e90b9cf438", 384 | "ShortcutKey": "Ctrl+K,Ctrl+A", 385 | "ChineseFunctionDescription": "选择标记", 386 | "EnglishFunctionDescription": "Select to mark" 387 | }, 388 | { 389 | "Id": "05829512-efe0-4322-9611-a9f72ed9a111", 390 | "ShortcutKey": "Ctrl+K,Ctrl+Space", 391 | "ChineseFunctionDescription": "设置标记", 392 | "EnglishFunctionDescription": "Set mark" 393 | }, 394 | { 395 | "Id": "6d953dcd-d3d0-448d-b21e-091d367c22b4", 396 | "ShortcutKey": "Ctrl+K,Ctrl+J", 397 | "ChineseFunctionDescription": "展开全部", 398 | "EnglishFunctionDescription": "Unfold all" 399 | }, 400 | { 401 | "Id": "14598a7b-3246-4ee4-8114-e0f43ccb4204", 402 | "ShortcutKey": "Shift+Ctrl+]", 403 | "ChineseFunctionDescription": "展开代码", 404 | "EnglishFunctionDescription": "Unfold code" 405 | }, 406 | { 407 | "Id": "a9399c4c-b70a-48e0-86e9-a1b8777f885c", 408 | "ShortcutKey": "Shift+Ctrl+[", 409 | "ChineseFunctionDescription": "折叠代码", 410 | "EnglishFunctionDescription": "Fold code" 411 | } 412 | ] 413 | }, 414 | { 415 | "ChineseCategoryName": "书签", 416 | "EnglishCategoryName": "Bookmarks", 417 | "Keys": [ 418 | { 419 | "Id": "a49107ae-7528-4db5-ac49-881e3a57419d", 420 | "ShortcutKey": "Alt+F2", 421 | "ChineseFunctionDescription": "选择所有书签", 422 | "EnglishFunctionDescription": "Select all bookmarks" 423 | }, 424 | { 425 | "Id": "2721c01a-6fe2-4aa7-8c53-182f6d2c5e5d", 426 | "ShortcutKey": "Shift+F2", 427 | "ChineseFunctionDescription": "上一个书签", 428 | "EnglishFunctionDescription": "Previous bookmark" 429 | }, 430 | { 431 | "Id": "cbc50c9f-4bd0-452e-ba28-fa561c9edaad", 432 | "ShortcutKey": "F2", 433 | "ChineseFunctionDescription": "下一个书签", 434 | "EnglishFunctionDescription": "Next bookmark" 435 | }, 436 | { 437 | "Id": "0092f01d-f2d4-441b-a79b-826d945745c8", 438 | "ShortcutKey": "Ctrl+F2", 439 | "ChineseFunctionDescription": "切换书签", 440 | "EnglishFunctionDescription": "Toggle bookmark" 441 | } 442 | ] 443 | } 444 | ] 445 | } -------------------------------------------------------------------------------- /LittleTips/AppShortcut/typora.json: -------------------------------------------------------------------------------- 1 | { 2 | "Id": "typora.exe", 3 | "AppName": "Typora", 4 | "AppIcon": "typora-128.png", 5 | "Categories": [ 6 | { 7 | "ChineseCategoryName": "文件", 8 | "EnglishCategoryName": "File", 9 | "Keys": [ 10 | { 11 | "Id": "8a1747cc-6ead-708d-0cef-dba02fc703a3", 12 | "ShortcutKey": "Ctrl+N", 13 | "ChineseFunctionDescription": "新建", 14 | "EnglishFunctionDescription": "New" 15 | }, 16 | { 17 | "Id": "6b08fbb5-8a9c-4446-81db-8e49aa0010eb", 18 | "ShortcutKey": "Ctrl+Shift+N", 19 | "ChineseFunctionDescription": "新窗口", 20 | "EnglishFunctionDescription": "New Windows" 21 | }, 22 | { 23 | "Id": "63b481a4-473b-c361-1657-875d73c5b9c8", 24 | "ShortcutKey": "Ctrl+O", 25 | "ChineseFunctionDescription": "打开", 26 | "EnglishFunctionDescription": "Open" 27 | }, 28 | { 29 | "Id": "01700b41-e472-ee05-48ad-3da33d331bae", 30 | "ShortcutKey": "Ctrl+P", 31 | "ChineseFunctionDescription": "快速打开", 32 | "EnglishFunctionDescription": "Open quickly" 33 | }, 34 | { 35 | "Id": "7ebac75d-bbfc-b698-e313-c6c8c11183da", 36 | "ShortcutKey": "Ctrl+Shift+T", 37 | "ChineseFunctionDescription": "重新打开关闭的文件", 38 | "EnglishFunctionDescription": "Reopen closed file" 39 | }, 40 | { 41 | "Id": "cfd1766f-219f-60e9-b517-39b6f24179b8", 42 | "ShortcutKey": "Ctrl+S", 43 | "ChineseFunctionDescription": "保存", 44 | "EnglishFunctionDescription": "Save" 45 | }, 46 | { 47 | "Id": "e3944828-4fe8-fa5a-4882-b562a91a06a7", 48 | "ShortcutKey": "Ctrl+Shift+S", 49 | "ChineseFunctionDescription": "另存为/复制", 50 | "EnglishFunctionDescription": "Save as/Copy" 51 | }, 52 | { 53 | "Id": "8d0e298d-9433-6699-92de-703504721cc2", 54 | "ShortcutKey": "Ctrl+,", 55 | "ChineseFunctionDescription": "偏好设置", 56 | "EnglishFunctionDescription": "Perference" 57 | }, 58 | { 59 | "Id": "724a6a51-9175-a41d-980b-63e63a1b78ec", 60 | "ShortcutKey": "Ctrl+W", 61 | "ChineseFunctionDescription": "关闭", 62 | "EnglishFunctionDescription": "Close" 63 | } 64 | ] 65 | }, 66 | { 67 | "ChineseCategoryName": "编辑", 68 | "EnglishCategoryName": "Edit", 69 | "Keys": [ 70 | { 71 | "Id": "5bdbcf07-0a1e-6f40-8df0-6912b9ac3700", 72 | "ShortcutKey": "Enter", 73 | "ChineseFunctionDescription": "新段落", 74 | "EnglishFunctionDescription": "New Paragraph" 75 | }, 76 | { 77 | "Id": "e6e9062e-69cb-5e5c-e9ef-85168cd612e3", 78 | "ShortcutKey": "Shift+Enter", 79 | "ChineseFunctionDescription": "新行", 80 | "EnglishFunctionDescription": "New LIne" 81 | }, 82 | { 83 | "Id": "c8d70aa0-7aa3-5dc4-33e0-252325d382e1", 84 | "ShortcutKey": "Ctrl+Shift+C", 85 | "ChineseFunctionDescription": "复制为markdown", 86 | "EnglishFunctionDescription": "Copy as markdown" 87 | }, 88 | { 89 | "Id": "dc32a432-3799-64ad-ca02-cd3127518f50", 90 | "ShortcutKey": "Ctrl+Shift+V", 91 | "ChineseFunctionDescription": "粘贴为纯文本", 92 | "EnglishFunctionDescription": "Paste as plain text" 93 | }, 94 | { 95 | "Id": "5469844a-dc53-9247-8a32-a8cce755d14a", 96 | "ShortcutKey": "Ctrl+L", 97 | "ChineseFunctionDescription": "选择行/句子 选择行(在表格中)", 98 | "EnglishFunctionDescription": "Select row/sentense" 99 | }, 100 | { 101 | "Id": "eb9b1c5c-5cd1-e943-6143-02c34007e378", 102 | "ShortcutKey": "Ctrl+Shift+Backspace", 103 | "ChineseFunctionDescription": "删除行(在表格中)", 104 | "EnglishFunctionDescription": "Delete row" 105 | }, 106 | { 107 | "Id": "1c950598-39c2-4178-66fe-19d2c6a6c567", 108 | "ShortcutKey": "Ctrl+E", 109 | "ChineseFunctionDescription": "选择样式范围 选择单元格(在表格中)", 110 | "EnglishFunctionDescription": "Select style range" 111 | }, 112 | { 113 | "Id": "3e5d8b47-9ef8-cb98-0192-1a7fae0fe502", 114 | "ShortcutKey": "Ctrl+D", 115 | "ChineseFunctionDescription": "选择单词", 116 | "EnglishFunctionDescription": "Select word" 117 | }, 118 | { 119 | "Id": "b582f86c-002d-d094-ebf0-9028fe51406d", 120 | "ShortcutKey": "Ctrl+Shift+D", 121 | "ChineseFunctionDescription": "删除单词", 122 | "EnglishFunctionDescription": "Delete word" 123 | }, 124 | { 125 | "Id": "711aed83-02f8-5667-16a3-255674628e2a", 126 | "ShortcutKey": "Ctrl+↑", 127 | "ChineseFunctionDescription": "跳到顶部", 128 | "EnglishFunctionDescription": "Jump top" 129 | }, 130 | { 131 | "Id": "c34ca312-8c0a-5e9c-dc5f-4805f0a36cda", 132 | "ShortcutKey": "Ctrl+J", 133 | "ChineseFunctionDescription": "跳到选择", 134 | "EnglishFunctionDescription": "Jump select" 135 | }, 136 | { 137 | "Id": "23dfd6df-d796-cda7-5af3-13a73ee13121", 138 | "ShortcutKey": "Ctrl+↓", 139 | "ChineseFunctionDescription": "跳到底部", 140 | "EnglishFunctionDescription": "Jump bottom" 141 | }, 142 | { 143 | "Id": "b30fc777-802a-c293-84ae-d34a3d6e105c", 144 | "ShortcutKey": "Ctrl+F", 145 | "ChineseFunctionDescription": "查找", 146 | "EnglishFunctionDescription": "Find" 147 | }, 148 | { 149 | "Id": "6936bb01-91af-7b40-659f-f94c43e7a8ca", 150 | "ShortcutKey": "F3/Enter", 151 | "ChineseFunctionDescription": "查找下一个", 152 | "EnglishFunctionDescription": "Find the next one" 153 | }, 154 | { 155 | "Id": "450109b4-6aac-a6cd-a07c-1b3ac7f7299d", 156 | "ShortcutKey": "Shift+F3/Enter", 157 | "ChineseFunctionDescription": "查找上一个", 158 | "EnglishFunctionDescription": "FInd the last one" 159 | }, 160 | { 161 | "Id": "1a92193a-4357-07a1-e847-7916763dba18", 162 | "ShortcutKey": "Ctrl+H", 163 | "ChineseFunctionDescription": "替换", 164 | "EnglishFunctionDescription": "Replace" 165 | } 166 | ] 167 | }, 168 | { 169 | "ChineseCategoryName": "段落", 170 | "EnglishCategoryName": "Paragraph", 171 | "Keys": [ 172 | { 173 | "Id": "2fb25843-4666-67a1-664c-d817d1ca390e", 174 | "ShortcutKey": "Ctrl + 1/2/3/4/5/6", 175 | "ChineseFunctionDescription": "标题1-6", 176 | "EnglishFunctionDescription": "Title 1-6" 177 | }, 178 | { 179 | "Id": "c7bd3d3b-92e0-9cbd-1a52-13911efd9120", 180 | "ShortcutKey": "Ctrl + 0", 181 | "ChineseFunctionDescription": "段落", 182 | "EnglishFunctionDescription": "Paragraph" 183 | }, 184 | { 185 | "Id": "38728a8e-01c9-8084-1a7d-b4dd6d38cd4c", 186 | "ShortcutKey": "Ctrl + =", 187 | "ChineseFunctionDescription": "增加标题级别", 188 | "EnglishFunctionDescription": "Raise title level" 189 | }, 190 | { 191 | "Id": "ddb192f2-7541-0eea-f010-b2cf901d0672", 192 | "ShortcutKey": "Ctrl + –", 193 | "ChineseFunctionDescription": "降低标题级别", 194 | "EnglishFunctionDescription": "Reduce title level" 195 | }, 196 | { 197 | "Id": "e7f9cbea-85dd-f3f4-caeb-82c8dc0617f4", 198 | "ShortcutKey": "Ctrl + T", 199 | "ChineseFunctionDescription": "表格", 200 | "EnglishFunctionDescription": "Table" 201 | }, 202 | { 203 | "Id": "b76bd83f-8525-655b-7e08-d3b84d468ee3", 204 | "ShortcutKey": "Ctrl + Shift + K", 205 | "ChineseFunctionDescription": "代码块", 206 | "EnglishFunctionDescription": "Code block" 207 | }, 208 | { 209 | "Id": "36e6e1cb-7173-f23e-5754-e30e528841a9", 210 | "ShortcutKey": "Ctrl + Shift + M", 211 | "ChineseFunctionDescription": "公式块", 212 | "EnglishFunctionDescription": "Formula block" 213 | }, 214 | { 215 | "Id": "103e5dd4-e3a2-1ada-807f-a5ea04ad7d54", 216 | "ShortcutKey": "Ctrl+Shift+Q", 217 | "ChineseFunctionDescription": "引用", 218 | "EnglishFunctionDescription": "Quote" 219 | }, 220 | { 221 | "Id": "53e19da3-cba2-3538-12c0-8c5ede7df753", 222 | "ShortcutKey": "Ctrl+Shift+[", 223 | "ChineseFunctionDescription": "有序列表", 224 | "EnglishFunctionDescription": "Ordered List" 225 | }, 226 | { 227 | "Id": "123886d8-b54c-f324-84f4-f1034d57930d", 228 | "ShortcutKey": "Ctrl+Shift+]", 229 | "ChineseFunctionDescription": "无序列表", 230 | "EnglishFunctionDescription": "Unordered List" 231 | }, 232 | { 233 | "Id": "72c22b32-1316-0062-1c2c-4275de58f318", 234 | "ShortcutKey": "Ctrl+[ / Tab", 235 | "ChineseFunctionDescription": "缩进", 236 | "EnglishFunctionDescription": "Indent" 237 | }, 238 | { 239 | "Id": "d26ea7b2-750a-5e46-c8ad-095655855b51", 240 | "ShortcutKey": "Ctrl+] / Shift+Tab", 241 | "ChineseFunctionDescription": "减少缩进", 242 | "EnglishFunctionDescription": "Decrease indent" 243 | } 244 | ] 245 | }, 246 | { 247 | "ChineseCategoryName": "格式", 248 | "EnglishCategoryName": "Format", 249 | "Keys": [ 250 | { 251 | "Id": "a661f703-92e0-04c9-e185-63cdc5505308", 252 | "ShortcutKey": "Ctrl+C", 253 | "ChineseFunctionDescription": "加粗", 254 | "EnglishFunctionDescription": "Bold" 255 | }, 256 | { 257 | "Id": "db9e0515-070a-1ea5-0e33-7fd21e4775d4", 258 | "ShortcutKey": "Ctrl+V", 259 | "ChineseFunctionDescription": "重点", 260 | "EnglishFunctionDescription": "Important" 261 | }, 262 | { 263 | "Id": "869529f7-a877-e9cf-491a-49828e2103de", 264 | "ShortcutKey": "Ctrl+D", 265 | "ChineseFunctionDescription": "下划线", 266 | "EnglishFunctionDescription": "Underline" 267 | }, 268 | { 269 | "Id": "c6469246-2a7c-5b0e-887e-aec1130d528b", 270 | "ShortcutKey": "Ctrl + Shift + `", 271 | "ChineseFunctionDescription": "代码", 272 | "EnglishFunctionDescription": "Code" 273 | }, 274 | { 275 | "Id": "00963e81-00ce-79ed-80db-a9f29b44511d", 276 | "ShortcutKey": "Alt + Shift + 5", 277 | "ChineseFunctionDescription": "删除线", 278 | "EnglishFunctionDescription": "Delete line" 279 | }, 280 | { 281 | "Id": "bb9d794c-0a09-28c3-488d-360e90b42189", 282 | "ShortcutKey": "Ctrl + K", 283 | "ChineseFunctionDescription": "超链接", 284 | "EnglishFunctionDescription": "Hyperlinks" 285 | }, 286 | { 287 | "Id": "5bb57655-b68d-4ce0-43c9-979c5f84282e", 288 | "ShortcutKey": "Ctrl + Shift + I", 289 | "ChineseFunctionDescription": "图片", 290 | "EnglishFunctionDescription": "Picture" 291 | }, 292 | { 293 | "Id": "deecf992-58b0-1d46-30bb-9b14691bee9a", 294 | "ShortcutKey": "Ctrl + \\", 295 | "ChineseFunctionDescription": "清楚格式", 296 | "EnglishFunctionDescription": "Clear format" 297 | } 298 | ] 299 | }, 300 | { 301 | "ChineseCategoryName": "视图", 302 | "EnglishCategoryName": "View", 303 | "Keys": [ 304 | { 305 | "Id": "96c696ce-4ba3-755d-a7a5-c0b6a3f0a091", 306 | "ShortcutKey": "Ctrl + Shift + L", 307 | "ChineseFunctionDescription": "切换侧边栏", 308 | "EnglishFunctionDescription": "Toggle sidebar" 309 | }, 310 | { 311 | "Id": "8c8ca1aa-49b7-5aa6-78fc-981bf801a5f5", 312 | "ShortcutKey": "Ctrl + Shift + 1", 313 | "ChineseFunctionDescription": "大纲", 314 | "EnglishFunctionDescription": "Outline" 315 | }, 316 | { 317 | "Id": "f83f8956-ba7f-67a5-a0d2-4864d8edbefd", 318 | "ShortcutKey": "Ctrl + Shift + 2", 319 | "ChineseFunctionDescription": "文章", 320 | "EnglishFunctionDescription": "Article" 321 | }, 322 | { 323 | "Id": "52fa3728-f0b1-d0c3-3359-7bbf166d53fb", 324 | "ShortcutKey": "Ctrl + Shift + 3", 325 | "ChineseFunctionDescription": "文件树", 326 | "EnglishFunctionDescription": "Document tree" 327 | }, 328 | { 329 | "Id": "1dfc671e-b456-2352-c1c4-4afb43dfedce", 330 | "ShortcutKey": "Ctrl + /", 331 | "ChineseFunctionDescription": "源代码模式", 332 | "EnglishFunctionDescription": "Source code mode" 333 | }, 334 | { 335 | "Id": "bcbfca8f-14d7-1566-b16a-c6ad83fccd5c", 336 | "ShortcutKey": "F8", 337 | "ChineseFunctionDescription": "对焦模式", 338 | "EnglishFunctionDescription": "Focus mode" 339 | }, 340 | { 341 | "Id": "0658f319-86ae-823e-1c1c-11e2cb158112", 342 | "ShortcutKey": "F9", 343 | "ChineseFunctionDescription": "打字机模式", 344 | "EnglishFunctionDescription": "Typewriter mode" 345 | }, 346 | { 347 | "Id": "e0c233bd-3b17-e7b7-4931-4a37b4ee8c55", 348 | "ShortcutKey": "F11", 349 | "ChineseFunctionDescription": "切换全屏", 350 | "EnglishFunctionDescription": "Toggle full screen" 351 | }, 352 | { 353 | "Id": "3a16bdb2-02db-a803-b623-eb3880877301", 354 | "ShortcutKey": "Ctrl + Shift + 0", 355 | "ChineseFunctionDescription": "实际尺寸", 356 | "EnglishFunctionDescription": "Actual size" 357 | }, 358 | { 359 | "Id": "79f5c6b0-5465-6f9f-828a-2bee21303291", 360 | "ShortcutKey": "Ctrl + Shift + =", 361 | "ChineseFunctionDescription": "放大", 362 | "EnglishFunctionDescription": "Enlarge" 363 | }, 364 | { 365 | "Id": "3246dadd-7220-4965-34eb-29d61f392efe", 366 | "ShortcutKey": "Ctrl + Shift + –", 367 | "ChineseFunctionDescription": "缩小", 368 | "EnglishFunctionDescription": "Narrow" 369 | }, 370 | { 371 | "Id": "63083e6f-f6fd-5755-9212-2966ee9354b9", 372 | "ShortcutKey": "Ctrl + Tab", 373 | "ChineseFunctionDescription": "在打开的文档之间切换", 374 | "EnglishFunctionDescription": "Switch betwen open documents" 375 | }, 376 | { 377 | "Id": "8c44a6ee-65cd-a16f-93ca-3f828caf22b5", 378 | "ShortcutKey": "Ctrl + Shift + I", 379 | "ChineseFunctionDescription": "开发者工具", 380 | "EnglishFunctionDescription": "Devtool" 381 | } 382 | ] 383 | } 384 | ] 385 | } -------------------------------------------------------------------------------- /LittleTips/ControlTemplates/CustomListBoxControlTemplate.xaml: -------------------------------------------------------------------------------- 1 |  3 | 4 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /LittleTips/ControlTemplates/CustomListBoxItemControlTemplate.xaml: -------------------------------------------------------------------------------- 1 |  4 | 5 | 33 | -------------------------------------------------------------------------------- /LittleTips/ControlTemplates/CustomWindowTemplate.xaml: -------------------------------------------------------------------------------- 1 |  3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /LittleTips/ControlTemplates/ScrollViewer.xaml: -------------------------------------------------------------------------------- 1 |  3 | 19 | 20 | 94 | 95 | 158 | 159 | 231 | 232 | 269 | -------------------------------------------------------------------------------- /LittleTips/Converters/BoolToCollapsedConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Windows; 4 | using System.Windows.Data; 5 | 6 | namespace LittleTips.Converters 7 | { 8 | public class BoolToCollapsedConverter : IValueConverter 9 | { 10 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture) 11 | { 12 | if ((bool) value) 13 | { 14 | return Visibility.Collapsed; 15 | } 16 | 17 | return Visibility.Visible; 18 | } 19 | 20 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) 21 | { 22 | throw new NotImplementedException(); 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /LittleTips/Converters/BoolToVisibilityConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Windows; 4 | using System.Windows.Data; 5 | 6 | namespace LittleTips.Converters 7 | { 8 | public class BoolToVisibilityConverter : IValueConverter 9 | { 10 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture) 11 | { 12 | if ((bool) value) 13 | { 14 | return Visibility.Visible; 15 | } 16 | 17 | return Visibility.Collapsed; 18 | } 19 | 20 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) 21 | { 22 | throw new NotImplementedException(); 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /LittleTips/Converters/ImagePathConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Windows.Data; 4 | using System.Windows.Media.Imaging; 5 | 6 | namespace LittleTips.Converters 7 | { 8 | public class ImagePathConverter : IValueConverter 9 | { 10 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture) 11 | { 12 | if (value is string path) 13 | { 14 | BitmapImage image = new BitmapImage(new Uri(path)); 15 | return image; 16 | } 17 | 18 | return null; 19 | } 20 | 21 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) 22 | { 23 | throw new NotImplementedException(); 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /LittleTips/Converters/ModifierKeyIndexToStringConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Windows.Data; 4 | 5 | namespace LittleTips.Converters 6 | { 7 | public class ModifierKeyIndexToStringConverter : IValueConverter 8 | { 9 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture) 10 | { 11 | if (value is int index) 12 | { 13 | switch (index) 14 | { 15 | case 0: //Ctrl 16 | return "Ctrl"; 17 | break; 18 | case 1: //Alt 19 | return "Alt"; 20 | break; 21 | case 2: //Shift 22 | return "Shift"; 23 | break; 24 | case 3: //Win 25 | return "Win"; 26 | break; 27 | default: 28 | return "Ctrl"; 29 | break; 30 | } 31 | } 32 | 33 | return null; 34 | } 35 | 36 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) 37 | { 38 | throw new NotImplementedException(); 39 | } 40 | } 41 | } -------------------------------------------------------------------------------- /LittleTips/Converters/StarConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Windows.Data; 4 | 5 | namespace LittleTips.Converters 6 | { 7 | public class StarConverter : IValueConverter 8 | { 9 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture) 10 | { 11 | if (value is bool isFavorite) 12 | { 13 | if (isFavorite) 14 | { 15 | return ""; 16 | } 17 | } 18 | 19 | return ""; 20 | } 21 | 22 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) 23 | { 24 | throw new NotImplementedException(); 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /LittleTips/CustomStyleSelector/ListBoxItemDataTemplateSelector.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | using System.Windows.Controls; 3 | using LittleTips.ViewModels; 4 | 5 | namespace LittleTips.CustomStyleSelector 6 | { 7 | public class ListBoxItemDataTemplateSelector : DataTemplateSelector 8 | { 9 | public DataTemplate DefaultListBoxItemDataTemplate { get; set; } 10 | public DataTemplate CategoryListBoxItemDataTemplate { get; set; } 11 | 12 | public override DataTemplate SelectTemplate(object item, DependencyObject container) 13 | { 14 | Shortcut shortcut = (Shortcut) item; 15 | if (!string.IsNullOrEmpty(shortcut.Category)) 16 | { 17 | return CategoryListBoxItemDataTemplate; 18 | } 19 | else 20 | { 21 | return DefaultListBoxItemDataTemplate; 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /LittleTips/CustomStyleSelector/ListBoxItemStyleSelector.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | using System.Windows.Controls; 3 | using LittleTips.ViewModels; 4 | 5 | namespace LittleTips.CustomStyleSelector 6 | { 7 | public class ListBoxItemStyleSelector : StyleSelector 8 | { 9 | public Style DefaultListboxItemStyle { get; set; } 10 | public Style CategoryListboxItemStyle { set; get; } 11 | 12 | public override Style SelectStyle(object item, DependencyObject container) 13 | { 14 | Shortcut shortcut = (Shortcut) item; 15 | if (!string.IsNullOrEmpty(shortcut.Category)) 16 | { 17 | return CategoryListboxItemStyle; 18 | } 19 | else 20 | { 21 | return DefaultListboxItemStyle; 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /LittleTips/Dto/ActivateResult.cs: -------------------------------------------------------------------------------- 1 | namespace LittleTips.Dto 2 | { 3 | public class ActivateResult 4 | { 5 | public int code { get; set; } 6 | public string token { get; set; } 7 | 8 | public bool activate { get; set; } //激活还是反激活 9 | } 10 | } -------------------------------------------------------------------------------- /LittleTips/Dto/App.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace LittleTips.Dto 5 | { 6 | public class App 7 | { 8 | public String Id { get; set; } 9 | public String AppName { get; set; } 10 | public String AppIcon { get; set; } 11 | public List Categories { get; set; } = new List(); 12 | } 13 | 14 | public class Category 15 | { 16 | public string ChineseCategoryName { get; set; } 17 | public string EnglishCategoryName { get; set; } 18 | public List Keys { get; set; } = new List(); 19 | } 20 | 21 | public class Key 22 | { 23 | public string Id { get; set; } 24 | public string ShortcutKey { get; set; } 25 | public string ChineseFunctionDescription { get; set; } 26 | public string EnglishFunctionDescription { get; set; } 27 | } 28 | } -------------------------------------------------------------------------------- /LittleTips/Dto/CheckUpdateDto.cs: -------------------------------------------------------------------------------- 1 | namespace LittleTips.Dto 2 | { 3 | public class CheckUpdateDto 4 | { 5 | public CheckUpdateDto(string version) 6 | { 7 | this.Version = version; 8 | } 9 | 10 | public string Version { get; set; } 11 | 12 | public int MajorVersionNumber 13 | { 14 | get 15 | { 16 | string[] s = Version.Split('.'); 17 | return int.Parse(s[0]); 18 | } 19 | } 20 | 21 | public int MinorVersionNumber 22 | { 23 | get 24 | { 25 | string[] s = Version.Split('.'); 26 | return int.Parse(s[1]); 27 | } 28 | } 29 | 30 | public int RevisionNumber 31 | { 32 | get 33 | { 34 | string[] s = Version.Split('.'); 35 | return int.Parse(s[2]); 36 | } 37 | } 38 | 39 | public int BuildNumber 40 | { 41 | get 42 | { 43 | string[] s = Version.Split('.'); 44 | return int.Parse(s[3]); 45 | } 46 | } 47 | } 48 | } -------------------------------------------------------------------------------- /LittleTips/Fonts/Favorites.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/Favorites.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/Fonts.xaml: -------------------------------------------------------------------------------- 1 |  3 | pack://application:,,,/Fonts/JetBrainsMono/#JetBrains Mono 4 | pack://application:,,,/Fonts/#Segoe MDL2 Assets 5 | pack://application:,,,/Fonts/#iconfont 6 | pack://application:,,,/Fonts/#Favorites 7 | -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Bold-Italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Bold-Italic.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Bold.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-BoldItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-BoldItalic.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ExtraBold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ExtraBold.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ExtraBoldItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ExtraBoldItalic.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ExtraLight.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ExtraLight.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ExtraLightItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ExtraLightItalic.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Italic.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Light.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Light.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-LightItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-LightItalic.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Medium.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-MediumItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-MediumItalic.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Regular.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Thin.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-Thin.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ThinItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/JetBrainsMono/JetBrainsMono-ThinItalic.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/iconfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/iconfont.ttf -------------------------------------------------------------------------------- /LittleTips/Fonts/segoe.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Fonts/segoe.ttf -------------------------------------------------------------------------------- /LittleTips/Images/icons8-memory-100.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Images/icons8-memory-100.ico -------------------------------------------------------------------------------- /LittleTips/Images/icons8-memory-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Images/icons8-memory-100.png -------------------------------------------------------------------------------- /LittleTips/Images/icons8-receive-cash-48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Images/icons8-receive-cash-48.png -------------------------------------------------------------------------------- /LittleTips/Images/icons8-receive-cash-96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Images/icons8-receive-cash-96.png -------------------------------------------------------------------------------- /LittleTips/Images/icons8-unknown-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenjing1294/LittleTips/6805beb944e5235fdc780f1311144929c2dd8497/LittleTips/Images/icons8-unknown-100.png -------------------------------------------------------------------------------- /LittleTips/LittleTips.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {2640DC0F-DA0F-40F3-BF2A-27B2228EF080} 8 | WinExe 9 | LittleTips 10 | LittleTips 11 | v4.7.2 12 | 512 13 | {60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 14 | 4 15 | true 16 | 17 | 18 | AnyCPU 19 | true 20 | full 21 | false 22 | bin\Debug\ 23 | DEBUG;TRACE 24 | prompt 25 | 4 26 | false 27 | 28 | 29 | AnyCPU 30 | pdbonly 31 | true 32 | bin\Release\ 33 | TRACE 34 | prompt 35 | 4 36 | true 37 | 38 | 39 | icons8-memory-100.ico 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 4.0 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | MSBuild:Compile 59 | Designer 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | True 73 | True 74 | Settings.settings 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | App.xaml 84 | Code 85 | 86 | 87 | 88 | 89 | DonateWindow.xaml 90 | 91 | 92 | MainWindow.xaml 93 | Code 94 | 95 | 96 | NotAdaptedWindow.xaml 97 | 98 | 99 | TipsWindow.xaml 100 | 101 | 102 | XMessageBox.xaml 103 | 104 | 105 | 106 | 107 | Code 108 | 109 | 110 | True 111 | True 112 | Resources.resx 113 | 114 | 115 | ResXFileCodeGenerator 116 | Resources.Designer.cs 117 | 118 | 119 | 120 | 121 | 122 | SettingsSingleFileGenerator 123 | Settings.Designer.cs 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | MSBuild:Compile 140 | Designer 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | 166 | 167 | 168 | 169 | 170 | 171 | 172 | Always 173 | 174 | 175 | Always 176 | 177 | 178 | Always 179 | 180 | 181 | Always 182 | 183 | 184 | Always 185 | 186 | 187 | Always 188 | 189 | 190 | Always 191 | 192 | 193 | Always 194 | 195 | 196 | Always 197 | 198 | 199 | Always 200 | 201 | 202 | Always 203 | 204 | 205 | Always 206 | 207 | 208 | Always 209 | 210 | 211 | Always 212 | 213 | 214 | Always 215 | 216 | 217 | Always 218 | 219 | 220 | Always 221 | 222 | 223 | Always 224 | 225 | 226 | Always 227 | 228 | 229 | Always 230 | 231 | 232 | Always 233 | 234 | 235 | Always 236 | 237 | 238 | Always 239 | 240 | 241 | Always 242 | 243 | 244 | Always 245 | 246 | 247 | Always 248 | 249 | 250 | Always 251 | 252 | 253 | Always 254 | 255 | 256 | Always 257 | 258 | 259 | Always 260 | 261 | 262 | Always 263 | 264 | 265 | Always 266 | 267 | 268 | Always 269 | 270 | 271 | Always 272 | 273 | 274 | Always 275 | 276 | 277 | Always 278 | 279 | 280 | Always 281 | 282 | 283 | 284 | 285 | Always 286 | 287 | 288 | Always 289 | 290 | 291 | Always 292 | 293 | 294 | 295 | Always 296 | 297 | 298 | 299 | 300 | 301 | 302 | 303 | 304 | 305 | 306 | Always 307 | 308 | 309 | Always 310 | 311 | 312 | Always 313 | 314 | 315 | Always 316 | 317 | 318 | Always 319 | 320 | 321 | Always 322 | 323 | 324 | Always 325 | 326 | 327 | Always 328 | 329 | 330 | Always 331 | 332 | 333 | Always 334 | 335 | 336 | 337 | 338 | Always 339 | 340 | 341 | Always 342 | 343 | 344 | 345 | 346 | Always 347 | 348 | 349 | Always 350 | 351 | 352 | Always 353 | 354 | 355 | Always 356 | 357 | 358 | 359 | 360 | Always 361 | 362 | 363 | 364 | -------------------------------------------------------------------------------- /LittleTips/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Resources; 3 | using System.Runtime.CompilerServices; 4 | using System.Runtime.InteropServices; 5 | using System.Windows; 6 | 7 | // General Information about an assembly is controlled through the following 8 | // set of attributes. Change these attribute values to modify the information 9 | // associated with an assembly. 10 | [assembly: AssemblyTitle("LittleTips")] 11 | [assembly: AssemblyDescription("")] 12 | [assembly: AssemblyConfiguration("")] 13 | [assembly: AssemblyCompany("")] 14 | [assembly: AssemblyProduct("LittleTips")] 15 | [assembly: AssemblyCopyright("Copyright © 2022")] 16 | [assembly: AssemblyTrademark("")] 17 | [assembly: AssemblyCulture("")] 18 | 19 | // Setting ComVisible to false makes the types in this assembly not visible 20 | // to COM components. If you need to access a type in this assembly from 21 | // COM, set the ComVisible attribute to true on that type. 22 | [assembly: ComVisible(false)] 23 | 24 | //In order to begin building localizable applications, set 25 | //CultureYouAreCodingWith in your .csproj file 26 | //inside a . For example, if you are using US english 27 | //in your source files, set the to en-US. Then uncomment 28 | //the NeutralResourceLanguage attribute below. Update the "en-US" in 29 | //the line below to match the UICulture setting in the project file. 30 | 31 | //[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)] 32 | 33 | 34 | [assembly: ThemeInfo( 35 | ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located 36 | //(used if a resource is not found in the page, 37 | // or application resource dictionaries) 38 | ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located 39 | //(used if a resource is not found in the page, 40 | // app, or any theme specific resource dictionaries) 41 | )] 42 | 43 | 44 | // Version information for an assembly consists of the following four values: 45 | // 46 | // Major Version 47 | // Minor Version 48 | // Build Number 49 | // Revision 50 | // 51 | // You can specify all the values or you can default the Build and Revision Numbers 52 | // by using the '*' as shown below: 53 | // [assembly: AssemblyVersion("1.0.*")] 54 | [assembly: AssemblyVersion("1.0.0.0")] 55 | [assembly: AssemblyFileVersion("1.0.0.0")] -------------------------------------------------------------------------------- /LittleTips/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace LittleTips.Properties 12 | { 13 | /// 14 | /// A strongly-typed resource class, for looking up localized strings, etc. 15 | /// 16 | // This class was auto-generated by the StronglyTypedResourceBuilder 17 | // class via a tool like ResGen or Visual Studio. 18 | // To add or remove a member, edit your .ResX file then rerun ResGen 19 | // with the /str option, or rebuild your VS project. 20 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] 21 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 22 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 23 | internal class Resources 24 | { 25 | private static global::System.Resources.ResourceManager resourceMan; 26 | 27 | private static global::System.Globalization.CultureInfo resourceCulture; 28 | 29 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 30 | internal Resources() 31 | { 32 | } 33 | 34 | /// 35 | /// Returns the cached ResourceManager instance used by this class. 36 | /// 37 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 38 | internal static global::System.Resources.ResourceManager ResourceManager 39 | { 40 | get 41 | { 42 | if ((resourceMan == null)) 43 | { 44 | global::System.Resources.ResourceManager temp = 45 | new global::System.Resources.ResourceManager("LittleTips.Properties.Resources", typeof(Resources).Assembly); 46 | resourceMan = temp; 47 | } 48 | 49 | return resourceMan; 50 | } 51 | } 52 | 53 | /// 54 | /// Overrides the current thread's CurrentUICulture property for all 55 | /// resource lookups using this strongly typed resource class. 56 | /// 57 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 58 | internal static global::System.Globalization.CultureInfo Culture 59 | { 60 | get { return resourceCulture; } 61 | set { resourceCulture = value; } 62 | } 63 | } 64 | } -------------------------------------------------------------------------------- /LittleTips/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 | -------------------------------------------------------------------------------- /LittleTips/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // 此代码由工具生成。 4 | // 运行时版本:4.0.30319.42000 5 | // 6 | // 对此文件的更改可能会导致不正确的行为,并且如果 7 | // 重新生成代码,这些更改将会丢失。 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace LittleTips.Properties { 12 | 13 | 14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.1.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 | [global::System.Configuration.UserScopedSettingAttribute()] 27 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 28 | [global::System.Configuration.DefaultSettingValueAttribute("False")] 29 | public bool LightMode { 30 | get { 31 | return ((bool)(this["LightMode"])); 32 | } 33 | set { 34 | this["LightMode"] = value; 35 | } 36 | } 37 | 38 | [global::System.Configuration.UserScopedSettingAttribute()] 39 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 40 | [global::System.Configuration.DefaultSettingValueAttribute("True")] 41 | public bool ChineseMode { 42 | get { 43 | return ((bool)(this["ChineseMode"])); 44 | } 45 | set { 46 | this["ChineseMode"] = value; 47 | } 48 | } 49 | 50 | [global::System.Configuration.UserScopedSettingAttribute()] 51 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 52 | [global::System.Configuration.DefaultSettingValueAttribute("")] 53 | public string DonateKey { 54 | get { 55 | return ((string)(this["DonateKey"])); 56 | } 57 | set { 58 | this["DonateKey"] = value; 59 | } 60 | } 61 | 62 | [global::System.Configuration.UserScopedSettingAttribute()] 63 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 64 | [global::System.Configuration.DefaultSettingValueAttribute("")] 65 | public string Favorites { 66 | get { 67 | return ((string)(this["Favorites"])); 68 | } 69 | set { 70 | this["Favorites"] = value; 71 | } 72 | } 73 | 74 | [global::System.Configuration.UserScopedSettingAttribute()] 75 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 76 | [global::System.Configuration.DefaultSettingValueAttribute("False")] 77 | public bool DataMigration { 78 | get { 79 | return ((bool)(this["DataMigration"])); 80 | } 81 | set { 82 | this["DataMigration"] = value; 83 | } 84 | } 85 | 86 | [global::System.Configuration.UserScopedSettingAttribute()] 87 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 88 | [global::System.Configuration.DefaultSettingValueAttribute("0")] 89 | public int TipsWindowWidth { 90 | get { 91 | return ((int)(this["TipsWindowWidth"])); 92 | } 93 | set { 94 | this["TipsWindowWidth"] = value; 95 | } 96 | } 97 | 98 | [global::System.Configuration.UserScopedSettingAttribute()] 99 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 100 | [global::System.Configuration.DefaultSettingValueAttribute("0")] 101 | public int TipsWindowHeight { 102 | get { 103 | return ((int)(this["TipsWindowHeight"])); 104 | } 105 | set { 106 | this["TipsWindowHeight"] = value; 107 | } 108 | } 109 | 110 | [global::System.Configuration.UserScopedSettingAttribute()] 111 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 112 | [global::System.Configuration.DefaultSettingValueAttribute("0")] 113 | public int ModifierKeyIndex { 114 | get { 115 | return ((int)(this["ModifierKeyIndex"])); 116 | } 117 | set { 118 | this["ModifierKeyIndex"] = value; 119 | } 120 | } 121 | 122 | [global::System.Configuration.UserScopedSettingAttribute()] 123 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 124 | [global::System.Configuration.DefaultSettingValueAttribute("")] 125 | public string HotKey { 126 | get { 127 | return ((string)(this["HotKey"])); 128 | } 129 | set { 130 | this["HotKey"] = value; 131 | } 132 | } 133 | } 134 | } 135 | -------------------------------------------------------------------------------- /LittleTips/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | False 7 | 8 | 9 | True 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | False 19 | 20 | 21 | 0 22 | 23 | 24 | 0 25 | 26 | 27 | 0 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /LittleTips/Styles/Buttons.xaml: -------------------------------------------------------------------------------- 1 |  3 | 4 | 49 | 50 | 51 | 52 | 78 | 79 | 80 | 105 | 106 | 131 | 132 | 156 | 157 | 205 | 206 | 234 | 235 | 251 | -------------------------------------------------------------------------------- /LittleTips/Styles/CustomGroupBoxStyle.xaml: -------------------------------------------------------------------------------- 1 |  3 | 4 | 50 | 51 | -------------------------------------------------------------------------------- /LittleTips/Styles/CustomWindowStyle.xaml: -------------------------------------------------------------------------------- 1 |  3 | 9 | -------------------------------------------------------------------------------- /LittleTips/Styles/DarkColors.xaml: -------------------------------------------------------------------------------- 1 |  3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /LittleTips/Styles/LightColors.xaml: -------------------------------------------------------------------------------- 1 |  3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /LittleTips/Utils/ActiveWindow.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Diagnostics; 3 | using System.Runtime.InteropServices; 4 | using System.Text; 5 | 6 | namespace LittleTips.Utils 7 | { 8 | public class ActiveWindow 9 | { 10 | [DllImport("user32.dll")] 11 | static extern IntPtr GetForegroundWindow(); 12 | 13 | [DllImport("user32.dll")] 14 | static extern int GetWindowText(IntPtr hWnd, StringBuilder text, int count); 15 | 16 | [DllImport("user32.dll", SetLastError = true)] 17 | static extern uint GetWindowThreadProcessId(IntPtr hWnd, out uint lpdwProcessId); 18 | 19 | 20 | /// 21 | /// 获取当前活动窗口的标题 22 | /// 23 | /// 24 | public static string GetActiveWindowTitle() 25 | { 26 | const int nChars = 256; 27 | StringBuilder buff = new StringBuilder(nChars); 28 | IntPtr handle = GetForegroundWindow(); 29 | 30 | if (GetWindowText(handle, buff, nChars) > 0) 31 | { 32 | return buff.ToString(); 33 | } 34 | 35 | return null; 36 | } 37 | 38 | /// 39 | /// 获取当前活动窗口所属程序名 40 | /// 41 | /// 42 | public static string GetActiveProgramName() 43 | { 44 | IntPtr hWnd = GetForegroundWindow(); 45 | GetWindowThreadProcessId(hWnd, out var procId); 46 | Process proc = Process.GetProcessById((int) procId); 47 | if (proc.MainModule != null) 48 | return proc.MainModule.FileName; 49 | else 50 | return string.Empty; 51 | } 52 | } 53 | } -------------------------------------------------------------------------------- /LittleTips/Utils/Common.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Globalization; 4 | using System.IO; 5 | using System.Net; 6 | using System.Reflection; 7 | using System.Resources; 8 | using System.Text; 9 | using System.Text.Json; 10 | 11 | namespace LittleTips.Utils 12 | { 13 | public class Common 14 | { 15 | public static readonly JsonSerializerOptions JsonSerializerOptions = new JsonSerializerOptions 16 | { 17 | WriteIndented = true, 18 | PropertyNameCaseInsensitive = true, 19 | Encoder = System.Text.Encodings.Web.JavaScriptEncoder.UnsafeRelaxedJsonEscaping 20 | }; 21 | 22 | public static readonly JsonSerializerOptions UglyJsonSerializerOptions = new JsonSerializerOptions 23 | { 24 | WriteIndented = false, 25 | PropertyNameCaseInsensitive = true, 26 | Encoder = System.Text.Encodings.Web.JavaScriptEncoder.UnsafeRelaxedJsonEscaping 27 | }; 28 | 29 | public static List ReadAllLine(string fileName) 30 | { 31 | List lines = new List(); 32 | Assembly assembly = Assembly.GetAssembly(typeof(Common)); 33 | string resourceName = assembly.GetName().Name + ".g"; 34 | ResourceManager rm = new ResourceManager(resourceName, assembly); 35 | using (ResourceSet set = rm.GetResourceSet(CultureInfo.InvariantCulture, true, true)) 36 | { 37 | UnmanagedMemoryStream s = (UnmanagedMemoryStream) set.GetObject(fileName, true); 38 | StreamReader reader = new StreamReader(s); 39 | string line = null; 40 | while ((line = reader.ReadLine()) != null) 41 | { 42 | if (!string.IsNullOrEmpty(line)) 43 | { 44 | lines.Add(line); 45 | } 46 | } 47 | 48 | reader.Close(); 49 | } 50 | 51 | return lines; 52 | } 53 | 54 | public static string ReadString(string fileName) 55 | { 56 | StringBuilder sb = new StringBuilder(); 57 | Assembly assembly = Assembly.GetAssembly(typeof(Common)); 58 | string resourceName = assembly.GetName().Name + ".g"; 59 | ResourceManager rm = new ResourceManager(resourceName, assembly); 60 | using (ResourceSet set = rm.GetResourceSet(CultureInfo.InvariantCulture, true, true)) 61 | { 62 | UnmanagedMemoryStream s = (UnmanagedMemoryStream) set.GetObject(fileName, true); 63 | StreamReader reader = new StreamReader(s); 64 | string line = null; 65 | while ((line = reader.ReadLine()) != null) 66 | { 67 | if (!string.IsNullOrEmpty(line)) 68 | { 69 | sb.Append(line); 70 | } 71 | } 72 | 73 | reader.Close(); 74 | } 75 | 76 | return sb.ToString(); 77 | } 78 | 79 | 80 | public static string Get(string uri) 81 | { 82 | //先根据用户请求的uri构造请求地址 83 | string serviceUrl = string.Format(uri); 84 | //创建Web访问对象 85 | HttpWebRequest myRequest = (HttpWebRequest) WebRequest.Create(serviceUrl); 86 | 87 | //通过Web访问对象获取响应内容 88 | HttpWebResponse myResponse = (HttpWebResponse) myRequest.GetResponse(); 89 | if (myResponse.StatusCode == HttpStatusCode.OK) 90 | { 91 | if (myResponse.GetResponseStream() != null) 92 | { 93 | //通过响应内容流创建StreamReader对象,因为StreamReader更高级更快 94 | StreamReader reader = new StreamReader(myResponse.GetResponseStream(), Encoding.UTF8); 95 | string res = reader.ReadToEnd(); //利用StreamReader就可以从响应内容从头读到尾 96 | reader.Close(); 97 | return res; 98 | } 99 | } 100 | 101 | myResponse.Close(); 102 | return null; 103 | } 104 | 105 | public static System.Windows.Input.Key WinformsToWPFKey(System.Windows.Forms.Keys inputKey) 106 | { 107 | // Put special case logic here if there's a key you need but doesn't map... 108 | try 109 | { 110 | return (System.Windows.Input.Key) Enum.Parse(typeof(System.Windows.Input.Key), inputKey.ToString()); 111 | } 112 | catch 113 | { 114 | // There wasn't a direct mapping... 115 | return System.Windows.Input.Key.None; 116 | } 117 | } 118 | 119 | public static System.Windows.Forms.Keys WPFToWinformsKey(System.Windows.Input.Key inputKey) 120 | { 121 | // Put special case logic here if there's a key you need but doesn't map... 122 | try 123 | { 124 | return (System.Windows.Forms.Keys) Enum.Parse(typeof(System.Windows.Forms.Keys), inputKey.ToString()); 125 | } 126 | catch 127 | { 128 | // There wasn't a direct mapping... 129 | return System.Windows.Forms.Keys.None; 130 | } 131 | } 132 | 133 | public static System.Windows.Forms.Keys StringToWinformsKey(string inputKey) 134 | { 135 | // Put special case logic here if there's a key you need but doesn't map... 136 | try 137 | { 138 | return (System.Windows.Forms.Keys) Enum.Parse(typeof(System.Windows.Forms.Keys), inputKey); 139 | } 140 | catch 141 | { 142 | // There wasn't a direct mapping... 143 | return System.Windows.Forms.Keys.None; 144 | } 145 | } 146 | } 147 | } -------------------------------------------------------------------------------- /LittleTips/Utils/ID.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Management; 3 | 4 | namespace Assistant.Utils 5 | { 6 | public static class Id 7 | { 8 | public static string GetBoisId() 9 | { 10 | string id = null; 11 | bool find = false; 12 | try 13 | { 14 | ManagementObjectSearcher searcher = new ManagementObjectSearcher("select * from Win32_BIOS"); 15 | ManagementObjectCollection collection = searcher.Get(); 16 | foreach (ManagementBaseObject baseObject in collection) 17 | { 18 | object serial = baseObject["SerialNumber"]; 19 | id = serial.ToString(); 20 | if (!string.IsNullOrEmpty(id)) 21 | { 22 | find = true; 23 | break; 24 | } 25 | } 26 | } 27 | catch 28 | { 29 | // ignored 30 | } 31 | 32 | return find ? id.Trim() : "null"; 33 | } 34 | 35 | public static string GetCpuId() 36 | { 37 | string id = null; 38 | bool find = false; 39 | try 40 | { 41 | ManagementObjectSearcher searcher = new ManagementObjectSearcher("select * from Win32_Processor"); 42 | ManagementObjectCollection collection = searcher.Get(); 43 | foreach (ManagementBaseObject baseObject in collection) 44 | { 45 | object serial = baseObject["ProcessorId"]; 46 | id = serial.ToString(); 47 | if (!string.IsNullOrEmpty(id)) 48 | { 49 | find = true; 50 | break; 51 | } 52 | } 53 | } 54 | catch 55 | { 56 | // ignored 57 | } 58 | 59 | return find ? id : "null"; 60 | } 61 | 62 | public static string GetMacId() 63 | { 64 | string id = null; 65 | bool find = false; 66 | try 67 | { 68 | ManagementObjectSearcher searcher = 69 | new ManagementObjectSearcher("select * from Win32_NetworkAdapterConfiguration"); 70 | ManagementObjectCollection collection = searcher.Get(); 71 | foreach (ManagementBaseObject baseObject in collection) 72 | { 73 | if ((bool) baseObject["IPEnabled"]) 74 | { 75 | object serial = baseObject["MacAddress"]; 76 | id = serial.ToString(); 77 | if (!string.IsNullOrEmpty(id)) 78 | { 79 | find = true; 80 | break; 81 | } 82 | } 83 | } 84 | } 85 | catch 86 | { 87 | // ignored 88 | } 89 | 90 | return find ? id : "null"; 91 | } 92 | 93 | /** 94 | * 获取电脑的唯一标识符=主板序号|CPU序号|MAC序号 95 | */ 96 | public static string GetIdentifier() 97 | { 98 | return $"{GetBoisId()}|{GetCpuId()}|{GetMacId()}"; 99 | } 100 | 101 | public static long GetTimeStamp() 102 | { 103 | TimeSpan ts = DateTime.Now - new DateTime(1970, 1, 1, 0, 0, 0, 0); 104 | return Convert.ToInt64(ts.TotalMilliseconds); 105 | } 106 | } 107 | } -------------------------------------------------------------------------------- /LittleTips/Utils/KeyboardHook.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Runtime.InteropServices; 3 | using System.Windows.Forms; 4 | 5 | namespace LittleTips.Utils 6 | { 7 | public sealed class KeyboardHook : IDisposable 8 | { 9 | // Registers a hot key with Windows. 10 | [DllImport("user32.dll")] 11 | private static extern bool RegisterHotKey(IntPtr hWnd, int id, uint fsModifiers, uint vk); 12 | 13 | // Unregisters the hot key with Windows. 14 | [DllImport("user32.dll")] 15 | private static extern bool UnregisterHotKey(IntPtr hWnd, int id); 16 | 17 | /// 18 | /// Represents the window that is used internally to get the messages. 19 | /// 20 | private class Window : NativeWindow, IDisposable 21 | { 22 | private static int WM_HOTKEY = 0x0312; 23 | 24 | public Window() 25 | { 26 | // create the handle for the window. 27 | this.CreateHandle(new CreateParams()); 28 | } 29 | 30 | /// 31 | /// Overridden to get the notifications. 32 | /// 33 | /// 34 | protected override void WndProc(ref Message m) 35 | { 36 | base.WndProc(ref m); 37 | 38 | // check if we got a hot key pressed. 39 | if (m.Msg == WM_HOTKEY) 40 | { 41 | // get the keys. 42 | Keys key = (Keys) (((int) m.LParam >> 16) & 0xFFFF); 43 | ModifierKeys modifier = (ModifierKeys) ((int) m.LParam & 0xFFFF); 44 | 45 | // invoke the event to notify the parent. 46 | if (KeyPressed != null) 47 | KeyPressed(this, new KeyPressedEventArgs(modifier, key)); 48 | } 49 | } 50 | 51 | public event EventHandler KeyPressed; 52 | 53 | #region IDisposable Members 54 | 55 | public void Dispose() 56 | { 57 | this.DestroyHandle(); 58 | } 59 | 60 | #endregion 61 | } 62 | 63 | private Window _window = new Window(); 64 | private int _currentId; 65 | 66 | public KeyboardHook() 67 | { 68 | // register the event of the inner native window. 69 | _window.KeyPressed += delegate(object sender, KeyPressedEventArgs args) 70 | { 71 | if (KeyPressed != null) 72 | KeyPressed(this, args); 73 | }; 74 | } 75 | 76 | /// 77 | /// Registers a hot key in the system. 78 | /// 79 | /// The modifiers that are associated with the hot key. 80 | /// The key itself that is associated with the hot key. 81 | public void RegisterHotKey(ModifierKeys modifier, Keys key) 82 | { 83 | // increment the counter. 84 | _currentId = _currentId + 1; 85 | 86 | // register the hot key. 87 | if (!RegisterHotKey(_window.Handle, _currentId, (uint) modifier, (uint) key)) 88 | throw new InvalidOperationException("Couldn’t register the hot key."); 89 | } 90 | 91 | /// 92 | /// A hot key has been pressed. 93 | /// 94 | public event EventHandler KeyPressed; 95 | 96 | #region IDisposable Members 97 | 98 | public void Dispose() 99 | { 100 | // unregister all the registered hot keys. 101 | for (int i = _currentId; i > 0; i--) 102 | { 103 | UnregisterHotKey(_window.Handle, i); 104 | } 105 | 106 | // dispose the inner native window. 107 | _window.Dispose(); 108 | } 109 | 110 | #endregion 111 | } 112 | 113 | /// 114 | /// Event Args for the event that is fired after the hot key has been pressed. 115 | /// 116 | public class KeyPressedEventArgs : EventArgs 117 | { 118 | private ModifierKeys _modifier; 119 | private Keys _key; 120 | 121 | internal KeyPressedEventArgs(ModifierKeys modifier, Keys key) 122 | { 123 | _modifier = modifier; 124 | _key = key; 125 | } 126 | 127 | public ModifierKeys Modifier 128 | { 129 | get { return _modifier; } 130 | } 131 | 132 | public Keys Key 133 | { 134 | get { return _key; } 135 | } 136 | } 137 | 138 | /// 139 | /// The enumeration of possible modifiers. 140 | /// 141 | [Flags] 142 | public enum ModifierKeys : uint 143 | { 144 | Alt = 1, 145 | Control = 2, 146 | Shift = 4, 147 | Win = 8 148 | } 149 | } -------------------------------------------------------------------------------- /LittleTips/Utils/WindowBlur.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Runtime.InteropServices; 3 | using System.Windows; 4 | using System.Windows.Interop; 5 | using LittleTips.Utils.Native; 6 | 7 | namespace LittleTips.Utils 8 | { 9 | public class WindowBlur 10 | { 11 | public static readonly DependencyProperty IsEnabledProperty = DependencyProperty.RegisterAttached( 12 | "IsEnabled", typeof(bool), typeof(WindowBlur), 13 | new PropertyMetadata(false, OnIsEnabledChanged)); 14 | 15 | public static void SetIsEnabled(DependencyObject element, bool value) 16 | { 17 | element.SetValue(IsEnabledProperty, value); 18 | } 19 | 20 | public static bool GetIsEnabled(DependencyObject element) 21 | { 22 | return (bool) element.GetValue(IsEnabledProperty); 23 | } 24 | 25 | private static void OnIsEnabledChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) 26 | { 27 | if (d is Window window) 28 | { 29 | if (true.Equals(e.OldValue)) 30 | { 31 | GetWindowBlur(window)?.Detach(); 32 | window.ClearValue(WindowBlurProperty); 33 | } 34 | 35 | if (true.Equals(e.NewValue)) 36 | { 37 | var blur = new WindowBlur(); 38 | blur.Attach(window); 39 | window.SetValue(WindowBlurProperty, blur); 40 | } 41 | } 42 | } 43 | 44 | public static readonly DependencyProperty WindowBlurProperty = DependencyProperty.RegisterAttached( 45 | "WindowBlur", typeof(WindowBlur), typeof(WindowBlur), 46 | new PropertyMetadata(null, OnWindowBlurChanged)); 47 | 48 | public static void SetWindowBlur(DependencyObject element, WindowBlur value) 49 | { 50 | element.SetValue(WindowBlurProperty, value); 51 | } 52 | 53 | public static WindowBlur GetWindowBlur(DependencyObject element) 54 | { 55 | return (WindowBlur) element.GetValue(WindowBlurProperty); 56 | } 57 | 58 | private static void OnWindowBlurChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) 59 | { 60 | if (d is Window window) 61 | { 62 | (e.OldValue as WindowBlur)?.Detach(); 63 | (e.NewValue as WindowBlur)?.Attach(window); 64 | } 65 | } 66 | 67 | private Window _window; 68 | 69 | private void Attach(Window window) 70 | { 71 | _window = window; 72 | var source = (HwndSource) PresentationSource.FromVisual(window); 73 | if (source == null) 74 | { 75 | window.SourceInitialized += OnSourceInitialized; 76 | } 77 | else 78 | { 79 | AttachCore(); 80 | } 81 | } 82 | 83 | private void Detach() 84 | { 85 | try 86 | { 87 | DetachCore(); 88 | } 89 | finally 90 | { 91 | _window = null; 92 | } 93 | } 94 | 95 | private void OnSourceInitialized(object sender, EventArgs e) 96 | { 97 | ((Window) sender).SourceInitialized -= OnSourceInitialized; 98 | AttachCore(); 99 | } 100 | 101 | private void AttachCore() 102 | { 103 | EnableBlur(_window); 104 | } 105 | 106 | private void DetachCore() 107 | { 108 | _window.SourceInitialized += OnSourceInitialized; 109 | } 110 | 111 | private static void EnableBlur(Window window) 112 | { 113 | var windowHelper = new WindowInteropHelper(window); 114 | 115 | var accent = new AccentPolicy 116 | { 117 | AccentState = AccentState.ACCENT_ENABLE_BLURBEHIND 118 | }; 119 | 120 | var accentStructSize = Marshal.SizeOf(accent); 121 | 122 | var accentPtr = Marshal.AllocHGlobal(accentStructSize); 123 | Marshal.StructureToPtr(accent, accentPtr, false); 124 | 125 | var data = new WindowCompositionAttributeData 126 | { 127 | Attribute = WindowCompositionAttribute.WCA_ACCENT_POLICY, 128 | SizeOfData = accentStructSize, 129 | Data = accentPtr 130 | }; 131 | 132 | SetWindowCompositionAttribute(windowHelper.Handle, ref data); 133 | 134 | Marshal.FreeHGlobal(accentPtr); 135 | } 136 | 137 | [DllImport("user32.dll")] 138 | internal static extern int SetWindowCompositionAttribute(IntPtr hwnd, ref WindowCompositionAttributeData data); 139 | } 140 | 141 | namespace Native 142 | { 143 | internal enum AccentState 144 | { 145 | ACCENT_DISABLED, 146 | ACCENT_ENABLE_GRADIENT, 147 | ACCENT_ENABLE_TRANSPARENTGRADIENT, 148 | ACCENT_ENABLE_BLURBEHIND, 149 | ACCENT_INVALID_STATE, 150 | } 151 | 152 | [StructLayout(LayoutKind.Sequential)] 153 | internal struct AccentPolicy 154 | { 155 | public AccentState AccentState; 156 | public int AccentFlags; 157 | public int GradientColor; 158 | public int AnimationId; 159 | } 160 | 161 | [StructLayout(LayoutKind.Sequential)] 162 | internal struct WindowCompositionAttributeData 163 | { 164 | public WindowCompositionAttribute Attribute; 165 | public IntPtr Data; 166 | public int SizeOfData; 167 | } 168 | 169 | internal enum WindowCompositionAttribute 170 | { 171 | // 省略其他未使用的字段 172 | WCA_ACCENT_POLICY = 19, 173 | // 省略其他未使用的字段 174 | } 175 | } 176 | } -------------------------------------------------------------------------------- /LittleTips/ViewModels/MainModel.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.ObjectModel; 2 | using System.ComponentModel; 3 | using System.Windows; 4 | 5 | namespace LittleTips.ViewModels 6 | { 7 | public class MainModel : INotifyPropertyChanged 8 | { 9 | public event PropertyChangedEventHandler PropertyChanged; 10 | 11 | private void OnPropertyChanged(string propertyName = null) 12 | { 13 | PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); 14 | } 15 | 16 | private Visibility _keyGridVisibility = Visibility.Collapsed; 17 | 18 | public Visibility KeyGridVisibility 19 | { 20 | get => _keyGridVisibility; 21 | set 22 | { 23 | _keyGridVisibility = value; 24 | OnPropertyChanged(nameof(KeyGridVisibility)); 25 | } 26 | } 27 | 28 | 29 | private ObservableCollection _supportApps = new ObservableCollection(); 30 | 31 | public ObservableCollection SupportApps 32 | { 33 | get => _supportApps; 34 | set 35 | { 36 | _supportApps = value; 37 | OnPropertyChanged(nameof(SupportApps)); 38 | } 39 | } 40 | 41 | private Visibility _supportAppsGridVisibility = Visibility.Collapsed; 42 | 43 | public Visibility SupportAppsGridVisibility 44 | { 45 | get => _supportAppsGridVisibility; 46 | set 47 | { 48 | _supportAppsGridVisibility = value; 49 | OnPropertyChanged(nameof(SupportAppsGridVisibility)); 50 | } 51 | } 52 | 53 | private Visibility _settingGridVisibility = Visibility.Collapsed; 54 | 55 | public Visibility SettingGridVisibility 56 | { 57 | get => _settingGridVisibility; 58 | set 59 | { 60 | _settingGridVisibility = value; 61 | OnPropertyChanged(nameof(SettingGridVisibility)); 62 | } 63 | } 64 | 65 | private Visibility _debugGridVisibility = Visibility.Collapsed; 66 | 67 | public Visibility DebugGridVisibility 68 | { 69 | get => _debugGridVisibility; 70 | set 71 | { 72 | _debugGridVisibility = value; 73 | OnPropertyChanged(nameof(DebugGridVisibility)); 74 | } 75 | } 76 | 77 | private Visibility _mainGridVisibility = Visibility.Visible; 78 | 79 | public Visibility MainGridVisibility 80 | { 81 | get => _mainGridVisibility; 82 | set 83 | { 84 | _mainGridVisibility = value; 85 | OnPropertyChanged(nameof(MainGridVisibility)); 86 | } 87 | } 88 | 89 | private ObservableCollection _shortcuts = new ObservableCollection(); 90 | 91 | public ObservableCollection Shortcuts 92 | { 93 | get => _shortcuts; 94 | set 95 | { 96 | _shortcuts = value; 97 | OnPropertyChanged(nameof(Shortcuts)); 98 | } 99 | } 100 | 101 | private ObservableCollection _favorites = new ObservableCollection(); 102 | 103 | public ObservableCollection Favorites 104 | { 105 | get => _favorites; 106 | set 107 | { 108 | _favorites = value; 109 | OnPropertyChanged(nameof(Favorites)); 110 | } 111 | } 112 | 113 | public string FavoritesString 114 | { 115 | get 116 | { 117 | if (LittleTips.Properties.Settings.Default.ChineseMode) 118 | { 119 | return "收藏夹"; 120 | } 121 | else 122 | { 123 | return "Favorites"; 124 | } 125 | } 126 | } 127 | 128 | 129 | private string _appIcon; 130 | 131 | public string AppIcon 132 | { 133 | get => _appIcon; 134 | set 135 | { 136 | _appIcon = value; 137 | OnPropertyChanged(nameof(AppIcon)); 138 | } 139 | } 140 | 141 | private string _appName; 142 | 143 | public string AppName 144 | { 145 | get => _appName; 146 | set 147 | { 148 | _appName = value; 149 | OnPropertyChanged(nameof(AppName)); 150 | } 151 | } 152 | 153 | 154 | private int _screenWidth; 155 | 156 | public int ScreenWidth 157 | { 158 | get => _screenWidth; 159 | set 160 | { 161 | _screenWidth = value; 162 | OnPropertyChanged(nameof(ScreenWidth)); 163 | } 164 | } 165 | 166 | private int _screenHeight; 167 | 168 | public int ScreenHeight 169 | { 170 | get => _screenHeight; 171 | set 172 | { 173 | _screenHeight = value; 174 | OnPropertyChanged(nameof(ScreenHeight)); 175 | } 176 | } 177 | } 178 | } -------------------------------------------------------------------------------- /LittleTips/ViewModels/NotAdaptedModel.cs: -------------------------------------------------------------------------------- 1 | using System.ComponentModel; 2 | 3 | namespace LittleTips.ViewModels 4 | { 5 | public class NotAdaptedModel : INotifyPropertyChanged 6 | { 7 | public event PropertyChangedEventHandler PropertyChanged; 8 | 9 | private void OnPropertyChanged(string propertyName = null) 10 | { 11 | PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); 12 | } 13 | 14 | private string _appPath; 15 | 16 | public string AppPath 17 | { 18 | get => _appPath; 19 | set 20 | { 21 | _appPath = value; 22 | OnPropertyChanged(nameof(AppPath)); 23 | } 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /LittleTips/ViewModels/Shortcut.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ComponentModel; 3 | 4 | namespace LittleTips.ViewModels 5 | { 6 | public class Shortcut : INotifyPropertyChanged 7 | { 8 | public event PropertyChangedEventHandler PropertyChanged; 9 | 10 | private void OnPropertyChanged(string propertyName = null) 11 | { 12 | PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); 13 | } 14 | 15 | private string _id; 16 | 17 | public string Id 18 | { 19 | get => _id; 20 | set 21 | { 22 | _id = value; 23 | OnPropertyChanged(nameof(Id)); 24 | } 25 | } 26 | 27 | public string Category 28 | { 29 | get 30 | { 31 | if (LittleTips.Properties.Settings.Default.ChineseMode) 32 | { 33 | return ChineseCategoryName; 34 | } 35 | else 36 | { 37 | return EnglishCategoryName; 38 | } 39 | } 40 | } 41 | 42 | private string _chineseCategoryName; 43 | 44 | public string ChineseCategoryName 45 | { 46 | get => _chineseCategoryName; 47 | set 48 | { 49 | _chineseCategoryName = value; 50 | OnPropertyChanged(nameof(ChineseCategoryName)); 51 | } 52 | } 53 | 54 | private string _englishCategoryName; 55 | 56 | public string EnglishCategoryName 57 | { 58 | get => _englishCategoryName; 59 | set 60 | { 61 | _englishCategoryName = value; 62 | OnPropertyChanged(nameof(EnglishCategoryName)); 63 | } 64 | } 65 | 66 | private string _shortcutKey; 67 | 68 | public string ShortcutKey 69 | { 70 | get => _shortcutKey; 71 | set 72 | { 73 | _shortcutKey = value; 74 | OnPropertyChanged(nameof(ShortcutKey)); 75 | } 76 | } 77 | 78 | public string FunctionDescription 79 | { 80 | get 81 | { 82 | if (LittleTips.Properties.Settings.Default.ChineseMode) 83 | { 84 | return ChineseFunctionDescription; 85 | } 86 | else 87 | { 88 | return EnglishFunctionDescription; 89 | } 90 | } 91 | } 92 | 93 | private string _englishFunctionDescription; 94 | 95 | public string EnglishFunctionDescription 96 | { 97 | get => _englishFunctionDescription; 98 | set 99 | { 100 | _englishFunctionDescription = value; 101 | OnPropertyChanged(nameof(EnglishFunctionDescription)); 102 | } 103 | } 104 | 105 | private string _chineseFunctionDescription; 106 | 107 | public string ChineseFunctionDescription 108 | { 109 | get => _chineseFunctionDescription; 110 | set 111 | { 112 | _chineseFunctionDescription = value; 113 | OnPropertyChanged(nameof(ChineseFunctionDescription)); 114 | } 115 | } 116 | 117 | private bool _isFavorite; 118 | 119 | public bool IsFavorite 120 | { 121 | get => _isFavorite; 122 | set 123 | { 124 | _isFavorite = value; 125 | OnPropertyChanged(nameof(IsFavorite)); 126 | } 127 | } 128 | } 129 | } -------------------------------------------------------------------------------- /LittleTips/Views/DonateWindow.xaml: -------------------------------------------------------------------------------- 1 |  12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 51 | 54 | 57 | 58 | http://www.redisant.cn/ltip/donate 59 | 60 | 61 | 62 | 63 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /LittleTips/Views/DonateWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | using System.Windows.Input; 3 | using LittleTips.Utils; 4 | 5 | namespace LittleTips.Views 6 | { 7 | public partial class DonateWindow : Window 8 | { 9 | private readonly MainWindow _mainWindow; 10 | 11 | public DonateWindow(MainWindow mainWindow) 12 | { 13 | InitializeComponent(); 14 | this._mainWindow = mainWindow; 15 | WindowBlur.SetIsEnabled(this, true); 16 | TipsWindow.SwitchMode(LittleTips.Properties.Settings.Default.LightMode == true); 17 | } 18 | 19 | private void Donate_OnClick(object sender, RoutedEventArgs e) 20 | { 21 | System.Diagnostics.Process.Start($"{App.Host}/donate"); 22 | e.Handled = true; 23 | } 24 | 25 | private void NotAdaptedWindow_OnKeyDown(object sender, KeyEventArgs e) 26 | { 27 | if (e.Key == Key.Escape) 28 | { 29 | if (_mainWindow != null) 30 | { 31 | _mainWindow.HiddenWidow(); 32 | e.Handled = true; 33 | } 34 | } 35 | } 36 | } 37 | } -------------------------------------------------------------------------------- /LittleTips/Views/NotAdaptedWindow.xaml: -------------------------------------------------------------------------------- 1 |  12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 47 | 50 | 53 | 54 | 55 | 56 | -------------------------------------------------------------------------------- /LittleTips/Views/NotAdaptedWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | using System.Windows.Input; 3 | using LittleTips.Utils; 4 | using LittleTips.ViewModels; 5 | 6 | namespace LittleTips.Views 7 | { 8 | public partial class NotAdaptedWindow : Window 9 | { 10 | public readonly NotAdaptedModel NotAdaptedModel; 11 | private readonly MainWindow _mainWindow; 12 | 13 | public NotAdaptedWindow(MainWindow mainWindow) 14 | { 15 | InitializeComponent(); 16 | this._mainWindow = mainWindow; 17 | this.NotAdaptedModel = (NotAdaptedModel) this.DataContext; 18 | WindowBlur.SetIsEnabled(this, true); 19 | TipsWindow.SwitchMode(LittleTips.Properties.Settings.Default.LightMode == true); 20 | } 21 | 22 | private void NotAdaptedWindow_OnKeyDown(object sender, KeyEventArgs e) 23 | { 24 | if (e.Key == Key.Escape) 25 | { 26 | if (_mainWindow != null) 27 | { 28 | _mainWindow.HiddenWidow(); 29 | e.Handled = true; 30 | } 31 | } 32 | } 33 | } 34 | } -------------------------------------------------------------------------------- /LittleTips/Views/TipsWindow.xaml: -------------------------------------------------------------------------------- 1 |  13 | 14 | 39 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 80 | 89 | 98 | 99 | 100 | 101 | 102 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 130 | 131 | 132 | 141 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 167 | 168 | 170 | 171 | 172 | 174 | 175 | 176 | 179 | 180 | 181 | 182 | 183 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 199 | 200 | 201 | 209 | 210 | 212 | 213 | 214 | 216 | 217 | 218 | 221 | 222 | 223 | 224 | 225 | 226 | 227 | -------------------------------------------------------------------------------- /LittleTips/Views/TipsWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Windows; 4 | using System.Windows.Controls.Primitives; 5 | using System.Windows.Input; 6 | using LittleTips.Utils; 7 | using LittleTips.ViewModels; 8 | 9 | namespace LittleTips.Views 10 | { 11 | public partial class TipsWindow : Window 12 | { 13 | private readonly MainModel _mainModel; 14 | private readonly MainWindow _mainWindow; 15 | 16 | public TipsWindow(MainModel mainModel, MainWindow mainWindow) 17 | { 18 | InitializeComponent(); 19 | this._mainModel = mainModel; 20 | this._mainWindow = mainWindow; 21 | this.DataContext = mainModel; 22 | WindowBlur.SetIsEnabled(this, true); 23 | SwitchMode(LittleTips.Properties.Settings.Default.LightMode == true); 24 | } 25 | 26 | private void NotAdaptedWindow_OnKeyDown(object sender, KeyEventArgs e) 27 | { 28 | if (e.Key == Key.Escape) 29 | { 30 | if (_mainWindow != null) 31 | { 32 | _mainWindow.HiddenWidow(); 33 | e.Handled = true; 34 | } 35 | } 36 | } 37 | 38 | public static void SwitchMode(bool lightMode) 39 | { 40 | ResourceDictionary rd = new ResourceDictionary 41 | { 42 | Source = lightMode 43 | ? new Uri("Styles/LightColors.xaml", UriKind.Relative) 44 | : new Uri("Styles/DarkColors.xaml", UriKind.Relative) 45 | }; 46 | Application.Current.Resources.MergedDictionaries[0] = rd; 47 | LittleTips.Properties.Settings.Default.LightMode = lightMode; 48 | } 49 | 50 | private void ModeButton_OnClick(object sender, RoutedEventArgs e) 51 | { 52 | if (sender is ToggleButton button) 53 | { 54 | SwitchMode(button.IsChecked == true); 55 | } 56 | } 57 | 58 | private void LanguageButton_OnClick(object sender, RoutedEventArgs e) 59 | { 60 | if (sender is ToggleButton button) 61 | { 62 | object bak = DataContext; 63 | DataContext = null; 64 | DataContext = bak; 65 | } 66 | } 67 | 68 | private void StarButton_OnClick(object sender, RoutedEventArgs e) 69 | { 70 | if (sender is ToggleButton button) 71 | { 72 | string id = (string) button.Tag; 73 | if (button.IsChecked == true) 74 | { 75 | foreach (var shortcut in _mainModel.Shortcuts) 76 | { 77 | if (!string.IsNullOrEmpty(shortcut.Id) && shortcut.Id.Equals(id)) 78 | { 79 | _mainModel.Favorites.Add(shortcut); 80 | break; 81 | } 82 | } 83 | } 84 | else 85 | { 86 | foreach (var shortcut in _mainModel.Favorites) 87 | { 88 | if (!string.IsNullOrEmpty(shortcut.Id) && shortcut.Id.Equals(id)) 89 | { 90 | _mainModel.Favorites.Remove(shortcut); 91 | break; 92 | } 93 | } 94 | } 95 | 96 | if (!string.IsNullOrEmpty(MainWindow.ShowingAppKey)) 97 | { 98 | if (MainWindow.FavoriteKeys.ContainsKey(MainWindow.ShowingAppKey)) 99 | { 100 | List favoriteKeys = MainWindow.FavoriteKeys[MainWindow.ShowingAppKey]; 101 | if (button.IsChecked == true) 102 | { 103 | if (!favoriteKeys.Contains(id)) 104 | { 105 | favoriteKeys.Add(id); 106 | } 107 | } 108 | else 109 | { 110 | if (favoriteKeys.Contains(id)) 111 | { 112 | favoriteKeys.Remove(id); 113 | } 114 | } 115 | } 116 | } 117 | } 118 | } 119 | } 120 | } -------------------------------------------------------------------------------- /LittleTips/Views/XMessageBox.xaml: -------------------------------------------------------------------------------- 1 |  5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 20 | 25 | 29 | 33 | 34 | 35 | 36 | 更多信息 37 | 38 | 39 | 40 | 41 | 42 | 43 |