├── .gitignore ├── App.xaml ├── App.xaml.cs ├── Assets ├── LargeTile.scale-100.png ├── LargeTile.scale-125.png ├── LargeTile.scale-150.png ├── LargeTile.scale-200.png ├── LargeTile.scale-400.png ├── LockScreenLogo.scale-200.png ├── SmallTile.scale-100.png ├── SmallTile.scale-125.png ├── SmallTile.scale-150.png ├── SmallTile.scale-200.png ├── SmallTile.scale-400.png ├── SplashScreen.scale-100.png ├── SplashScreen.scale-125.png ├── SplashScreen.scale-150.png ├── SplashScreen.scale-200.png ├── SplashScreen.scale-400.png ├── Square150x150Logo.scale-100.png ├── Square150x150Logo.scale-125.png ├── Square150x150Logo.scale-150.png ├── Square150x150Logo.scale-200.png ├── Square150x150Logo.scale-400.png ├── Square44x44Logo.altform-lightunplated_targetsize-16.png ├── Square44x44Logo.altform-lightunplated_targetsize-24.png ├── Square44x44Logo.altform-lightunplated_targetsize-256.png ├── Square44x44Logo.altform-lightunplated_targetsize-32.png ├── Square44x44Logo.altform-lightunplated_targetsize-48.png ├── Square44x44Logo.altform-unplated_targetsize-16.png ├── Square44x44Logo.altform-unplated_targetsize-24.png ├── Square44x44Logo.altform-unplated_targetsize-256.png ├── Square44x44Logo.altform-unplated_targetsize-32.png ├── Square44x44Logo.altform-unplated_targetsize-48.png ├── Square44x44Logo.scale-100.png ├── Square44x44Logo.scale-125.png ├── Square44x44Logo.scale-150.png ├── Square44x44Logo.scale-200.png ├── Square44x44Logo.scale-400.png ├── Square44x44Logo.targetsize-16.png ├── Square44x44Logo.targetsize-24.png ├── Square44x44Logo.targetsize-24_altform-unplated.png ├── Square44x44Logo.targetsize-256.png ├── Square44x44Logo.targetsize-32.png ├── Square44x44Logo.targetsize-48.png ├── StoreLogo.backup.png ├── StoreLogo.scale-100.png ├── StoreLogo.scale-125.png ├── StoreLogo.scale-150.png ├── StoreLogo.scale-200.png ├── StoreLogo.scale-400.png ├── Wide310x150Logo.scale-100.png ├── Wide310x150Logo.scale-125.png ├── Wide310x150Logo.scale-150.png ├── Wide310x150Logo.scale-200.png ├── Wide310x150Logo.scale-400.png ├── rtf-icon.png └── txt-icon.png ├── BasePage.xaml ├── BasePage.xaml.cs ├── Converters ├── BooleanToVisibility.cs ├── IntToTextWrapping.cs ├── IntToThickness.cs └── SettingsConverters.cs ├── Dialogs ├── AboutDialog.xaml ├── AboutDialog.xaml.cs ├── ImageOptionsDialog.xaml └── ImageOptionsDialog.xaml.cs ├── Helpers ├── ResourceHelper.cs └── RichEditHelpers.cs ├── LICENSE ├── Package.appxmanifest ├── Properties ├── AssemblyInfo.cs └── Default.rd.xml ├── README.md ├── Strings ├── de-DE │ └── Resources.resw ├── en-GB │ └── Resources.resw ├── en-US │ └── Resources.resw └── pt-PT │ └── Resources.resw ├── TowPad.csproj ├── TowPad.sln ├── UserControls ├── SettingsBlockControl.xaml ├── SettingsBlockControl.xaml.cs ├── SettingsDisplayControl.xaml └── SettingsDisplayControl.xaml.cs ├── ViewModels ├── RecentlyUsedViewModel.cs ├── Settings │ ├── SettingsViewModel.cs │ └── ViewModel.cs └── WhatsNewItemViewModel.cs ├── Views ├── HomePage.xaml ├── HomePage.xaml.cs ├── MainPage.xaml ├── MainPage.xaml.cs └── Settings │ ├── SettingsPage.xaml │ └── SettingsPage.xaml.cs └── privacy-policy.md /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | # User-specific files 7 | *.rsuser 8 | *.suo 9 | *.user 10 | *.userosscache 11 | *.sln.docstates 12 | 13 | # User-specific files (MonoDevelop/Xamarin Studio) 14 | *.userprefs 15 | 16 | # Mono auto generated files 17 | mono_crash.* 18 | 19 | # Build results 20 | [Dd]ebug/ 21 | [Dd]ebugPublic/ 22 | [Rr]elease/ 23 | [Rr]eleases/ 24 | x64/ 25 | x86/ 26 | [Aa][Rr][Mm]/ 27 | [Aa][Rr][Mm]64/ 28 | bld/ 29 | [Bb]in/ 30 | [Oo]bj/ 31 | [Ll]og/ 32 | [Ll]ogs/ 33 | 34 | # Visual Studio 2015/2017 cache/options directory 35 | .vs/ 36 | # Uncomment if you have tasks that create the project's static files in wwwroot 37 | #wwwroot/ 38 | 39 | # Visual Studio 2017 auto generated files 40 | Generated\ Files/ 41 | 42 | # MSTest test Results 43 | [Tt]est[Rr]esult*/ 44 | [Bb]uild[Ll]og.* 45 | 46 | # NUnit 47 | *.VisualState.xml 48 | TestResult.xml 49 | nunit-*.xml 50 | 51 | # Build Results of an ATL Project 52 | [Dd]ebugPS/ 53 | [Rr]eleasePS/ 54 | dlldata.c 55 | 56 | # Benchmark Results 57 | BenchmarkDotNet.Artifacts/ 58 | 59 | # .NET Core 60 | project.lock.json 61 | project.fragment.lock.json 62 | artifacts/ 63 | 64 | # StyleCop 65 | StyleCopReport.xml 66 | 67 | # Files built by Visual Studio 68 | *_i.c 69 | *_p.c 70 | *_h.h 71 | *.ilk 72 | *.meta 73 | *.obj 74 | *.iobj 75 | *.pch 76 | *.pdb 77 | *.ipdb 78 | *.pgc 79 | *.pgd 80 | *.rsp 81 | *.sbr 82 | *.tlb 83 | *.tli 84 | *.tlh 85 | *.tmp 86 | *.tmp_proj 87 | *_wpftmp.csproj 88 | *.log 89 | *.vspscc 90 | *.vssscc 91 | .builds 92 | *.pidb 93 | *.svclog 94 | *.scc 95 | 96 | # Chutzpah Test files 97 | _Chutzpah* 98 | 99 | # Visual C++ cache files 100 | ipch/ 101 | *.aps 102 | *.ncb 103 | *.opendb 104 | *.opensdf 105 | *.sdf 106 | *.cachefile 107 | *.VC.db 108 | *.VC.VC.opendb 109 | 110 | # Visual Studio profiler 111 | *.psess 112 | *.vsp 113 | *.vspx 114 | *.sap 115 | 116 | # Visual Studio Trace Files 117 | *.e2e 118 | 119 | # TFS 2012 Local Workspace 120 | $tf/ 121 | 122 | # Guidance Automation Toolkit 123 | *.gpState 124 | 125 | # ReSharper is a .NET coding add-in 126 | _ReSharper*/ 127 | *.[Rr]e[Ss]harper 128 | *.DotSettings.user 129 | 130 | # TeamCity is a build add-in 131 | _TeamCity* 132 | 133 | # DotCover is a Code Coverage Tool 134 | *.dotCover 135 | 136 | # AxoCover is a Code Coverage Tool 137 | .axoCover/* 138 | !.axoCover/settings.json 139 | 140 | # Visual Studio code coverage results 141 | *.coverage 142 | *.coveragexml 143 | 144 | # NCrunch 145 | _NCrunch_* 146 | .*crunch*.local.xml 147 | nCrunchTemp_* 148 | 149 | # MightyMoose 150 | *.mm.* 151 | AutoTest.Net/ 152 | 153 | # Web workbench (sass) 154 | .sass-cache/ 155 | 156 | # Installshield output folder 157 | [Ee]xpress/ 158 | 159 | # DocProject is a documentation generator add-in 160 | DocProject/buildhelp/ 161 | DocProject/Help/*.HxT 162 | DocProject/Help/*.HxC 163 | DocProject/Help/*.hhc 164 | DocProject/Help/*.hhk 165 | DocProject/Help/*.hhp 166 | DocProject/Help/Html2 167 | DocProject/Help/html 168 | 169 | # Click-Once directory 170 | publish/ 171 | 172 | # Publish Web Output 173 | *.[Pp]ublish.xml 174 | *.azurePubxml 175 | # Note: Comment the next line if you want to checkin your web deploy settings, 176 | # but database connection strings (with potential passwords) will be unencrypted 177 | *.pubxml 178 | *.publishproj 179 | 180 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 181 | # checkin your Azure Web App publish settings, but sensitive information contained 182 | # in these scripts will be unencrypted 183 | PublishScripts/ 184 | 185 | # NuGet Packages 186 | *.nupkg 187 | # NuGet Symbol Packages 188 | *.snupkg 189 | # The packages folder can be ignored because of Package Restore 190 | **/[Pp]ackages/* 191 | # except build/, which is used as an MSBuild target. 192 | !**/[Pp]ackages/build/ 193 | # Uncomment if necessary however generally it will be regenerated when needed 194 | #!**/[Pp]ackages/repositories.config 195 | # NuGet v3's project.json files produces more ignorable files 196 | *.nuget.props 197 | *.nuget.targets 198 | 199 | # Microsoft Azure Build Output 200 | csx/ 201 | *.build.csdef 202 | 203 | # Microsoft Azure Emulator 204 | ecf/ 205 | rcf/ 206 | 207 | # Windows Store app package directories and files 208 | AppPackages/ 209 | BundleArtifacts/ 210 | Package.StoreAssociation.xml 211 | _pkginfo.txt 212 | *.appx 213 | *.appxbundle 214 | *.appxupload 215 | 216 | # Visual Studio cache files 217 | # files ending in .cache can be ignored 218 | *.[Cc]ache 219 | # but keep track of directories ending in .cache 220 | !?*.[Cc]ache/ 221 | 222 | # Others 223 | ClientBin/ 224 | ~$* 225 | *~ 226 | *.dbmdl 227 | *.dbproj.schemaview 228 | *.jfm 229 | *.pfx 230 | *.publishsettings 231 | orleans.codegen.cs 232 | 233 | # Including strong name files can present a security risk 234 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 235 | #*.snk 236 | 237 | # Since there are multiple workflows, uncomment next line to ignore bower_components 238 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 239 | #bower_components/ 240 | 241 | # RIA/Silverlight projects 242 | Generated_Code/ 243 | 244 | # Backup & report files from converting an old project file 245 | # to a newer Visual Studio version. Backup files are not needed, 246 | # because we have git ;-) 247 | _UpgradeReport_Files/ 248 | Backup*/ 249 | UpgradeLog*.XML 250 | UpgradeLog*.htm 251 | ServiceFabricBackup/ 252 | *.rptproj.bak 253 | 254 | # SQL Server files 255 | *.mdf 256 | *.ldf 257 | *.ndf 258 | 259 | # Business Intelligence projects 260 | *.rdl.data 261 | *.bim.layout 262 | *.bim_*.settings 263 | *.rptproj.rsuser 264 | *- [Bb]ackup.rdl 265 | *- [Bb]ackup ([0-9]).rdl 266 | *- [Bb]ackup ([0-9][0-9]).rdl 267 | 268 | # Microsoft Fakes 269 | FakesAssemblies/ 270 | 271 | # GhostDoc plugin setting file 272 | *.GhostDoc.xml 273 | 274 | # Node.js Tools for Visual Studio 275 | .ntvs_analysis.dat 276 | node_modules/ 277 | 278 | # Visual Studio 6 build log 279 | *.plg 280 | 281 | # Visual Studio 6 workspace options file 282 | *.opt 283 | 284 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 285 | *.vbw 286 | 287 | # Visual Studio LightSwitch build output 288 | **/*.HTMLClient/GeneratedArtifacts 289 | **/*.DesktopClient/GeneratedArtifacts 290 | **/*.DesktopClient/ModelManifest.xml 291 | **/*.Server/GeneratedArtifacts 292 | **/*.Server/ModelManifest.xml 293 | _Pvt_Extensions 294 | 295 | # Paket dependency manager 296 | .paket/paket.exe 297 | paket-files/ 298 | 299 | # FAKE - F# Make 300 | .fake/ 301 | 302 | # CodeRush personal settings 303 | .cr/personal 304 | 305 | # Python Tools for Visual Studio (PTVS) 306 | __pycache__/ 307 | *.pyc 308 | 309 | # Cake - Uncomment if you are using it 310 | # tools/** 311 | # !tools/packages.config 312 | 313 | # Tabs Studio 314 | *.tss 315 | 316 | # Telerik's JustMock configuration file 317 | *.jmconfig 318 | 319 | # BizTalk build output 320 | *.btp.cs 321 | *.btm.cs 322 | *.odx.cs 323 | *.xsd.cs 324 | 325 | # OpenCover UI analysis results 326 | OpenCover/ 327 | 328 | # Azure Stream Analytics local run output 329 | ASALocalRun/ 330 | 331 | # MSBuild Binary and Structured Log 332 | *.binlog 333 | 334 | # NVidia Nsight GPU debugger configuration file 335 | *.nvuser 336 | 337 | # MFractors (Xamarin productivity tool) working folder 338 | .mfractor/ 339 | 340 | # Local History for Visual Studio 341 | .localhistory/ 342 | 343 | # BeatPulse healthcheck temp database 344 | healthchecksdb 345 | 346 | # Backup folder for Package Reference Convert tool in Visual Studio 2017 347 | MigrationBackup/ 348 | 349 | # Ionide (cross platform F# VS Code tools) working folder 350 | .ionide/ 351 | -------------------------------------------------------------------------------- /App.xaml: -------------------------------------------------------------------------------- 1 |  9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 27 | 28 | 35 | 36 | 151 | 152 | 153 | 154 | -------------------------------------------------------------------------------- /App.xaml.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.Toolkit.Uwp.UI.Helpers; 2 | using Rich_Text_Editor.ViewModels; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.IO; 6 | using System.Linq; 7 | using System.Runtime.InteropServices.WindowsRuntime; 8 | using Windows.ApplicationModel; 9 | using Windows.ApplicationModel.Activation; 10 | using Windows.ApplicationModel.Core; 11 | using Windows.ApplicationModel.Resources; 12 | using Windows.Foundation; 13 | using Windows.Foundation.Collections; 14 | using Windows.Storage; 15 | using Windows.Storage.Streams; 16 | using Windows.UI.Xaml; 17 | using Windows.UI.Xaml.Controls; 18 | using Windows.UI.Xaml.Controls.Primitives; 19 | using Windows.UI.Xaml.Data; 20 | using Windows.UI.Xaml.Input; 21 | using Windows.UI.Xaml.Media; 22 | using Windows.UI.Xaml.Navigation; 23 | 24 | namespace Rich_Text_Editor 25 | { 26 | /// 27 | /// Provides application-specific behavior to supplement the default Application class. 28 | /// 29 | sealed partial class App : Application 30 | { 31 | /// 32 | /// Initializes the singleton application object. This is the first line of authored code 33 | /// executed, and as such is the logical equivalent of main() or WinMain(). 34 | /// 35 | 36 | public static SettingsViewModel SViewModel { get; private set; } 37 | public static List Tips { get; private set; } 38 | 39 | public App() 40 | { 41 | InitializeComponent(); 42 | Suspending += OnSuspending; 43 | 44 | SViewModel = new(); 45 | Tips = new(); 46 | } 47 | 48 | /// 49 | /// Invoked when the application is launched normally by the end user. Other entry points 50 | /// will be used such as when the application is launched to open a specific file. 51 | /// 52 | /// Details about the launch request and process. 53 | protected override void OnLaunched(LaunchActivatedEventArgs e) 54 | { 55 | // Do not repeat app initialization when the Window already has content, 56 | // just ensure that the window is active 57 | if (Window.Current.Content is not Frame rootFrame) 58 | { 59 | // Create a Frame to act as the navigation context and navigate to the first page 60 | rootFrame = new Frame(); 61 | 62 | rootFrame.NavigationFailed += OnNavigationFailed; 63 | 64 | if (e.PreviousExecutionState == ApplicationExecutionState.Terminated) 65 | { 66 | //TODO: Load state from previously suspended application 67 | } 68 | 69 | // Place the frame in the current Window 70 | Window.Current.Content = rootFrame; 71 | } 72 | 73 | if (!e.PrelaunchActivated) 74 | { 75 | CoreApplication.EnablePrelaunch(true); 76 | 77 | switch (SViewModel.Theme) 78 | { 79 | case 0: 80 | rootFrame.RequestedTheme = ElementTheme.Light; 81 | break; 82 | case 1: 83 | rootFrame.RequestedTheme = ElementTheme.Dark; 84 | break; 85 | case 2: 86 | rootFrame.RequestedTheme = ElementTheme.Default; 87 | break; 88 | } 89 | 90 | if (rootFrame.Content == null) 91 | { 92 | // When the navigation stack isn't restored navigate to the first page, 93 | // configuring the new page by passing required information as a navigation 94 | // parameter 95 | rootFrame.Navigate(typeof(BasePage), e.Arguments); 96 | } 97 | // Ensure the current window is active 98 | Window.Current.Activate(); 99 | } 100 | } 101 | 102 | /// 103 | /// Invoked when Navigation to a certain page fails 104 | /// 105 | /// The Frame which failed navigation 106 | /// Details about the navigation failure 107 | void OnNavigationFailed(object sender, NavigationFailedEventArgs e) 108 | { 109 | throw new Exception("Failed to load Page " + e.SourcePageType.FullName); 110 | } 111 | 112 | /// 113 | /// Invoked when application execution is being suspended. Application state is saved 114 | /// without knowing whether the application will be terminated or resumed with the contents 115 | /// of memory still intact. 116 | /// 117 | /// The source of the suspend request. 118 | /// Details about the suspend request. 119 | private void OnSuspending(object sender, SuspendingEventArgs e) 120 | { 121 | var deferral = e?.SuspendingOperation?.GetDeferral(); 122 | //TODO: Save application state and stop any background activity 123 | deferral?.Complete(); 124 | } 125 | 126 | protected override void OnFileActivated(FileActivatedEventArgs args) 127 | { 128 | // TODO: Handle file activation 129 | // The number of files received is args.Files.Size 130 | // The name of the first file is args.Files[0].Name 131 | if (Window.Current.Content is not Frame) 132 | { 133 | Frame rootFrame = new(); 134 | 135 | rootFrame.Navigate(typeof(BasePage)); 136 | Window.Current.Content = rootFrame; 137 | Window.Current.Activate(); 138 | 139 | BasePage.Current.Tabs.TabItems.RemoveAt(0); 140 | } 141 | 142 | BasePage.Current?.OpenFilesWithArgs(args); 143 | } 144 | } 145 | } 146 | -------------------------------------------------------------------------------- /Assets/LargeTile.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/LargeTile.scale-100.png -------------------------------------------------------------------------------- /Assets/LargeTile.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/LargeTile.scale-125.png -------------------------------------------------------------------------------- /Assets/LargeTile.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/LargeTile.scale-150.png -------------------------------------------------------------------------------- /Assets/LargeTile.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/LargeTile.scale-200.png -------------------------------------------------------------------------------- /Assets/LargeTile.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/LargeTile.scale-400.png -------------------------------------------------------------------------------- /Assets/LockScreenLogo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/LockScreenLogo.scale-200.png -------------------------------------------------------------------------------- /Assets/SmallTile.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SmallTile.scale-100.png -------------------------------------------------------------------------------- /Assets/SmallTile.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SmallTile.scale-125.png -------------------------------------------------------------------------------- /Assets/SmallTile.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SmallTile.scale-150.png -------------------------------------------------------------------------------- /Assets/SmallTile.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SmallTile.scale-200.png -------------------------------------------------------------------------------- /Assets/SmallTile.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SmallTile.scale-400.png -------------------------------------------------------------------------------- /Assets/SplashScreen.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SplashScreen.scale-100.png -------------------------------------------------------------------------------- /Assets/SplashScreen.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SplashScreen.scale-125.png -------------------------------------------------------------------------------- /Assets/SplashScreen.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SplashScreen.scale-150.png -------------------------------------------------------------------------------- /Assets/SplashScreen.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SplashScreen.scale-200.png -------------------------------------------------------------------------------- /Assets/SplashScreen.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/SplashScreen.scale-400.png -------------------------------------------------------------------------------- /Assets/Square150x150Logo.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square150x150Logo.scale-100.png -------------------------------------------------------------------------------- /Assets/Square150x150Logo.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square150x150Logo.scale-125.png -------------------------------------------------------------------------------- /Assets/Square150x150Logo.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square150x150Logo.scale-150.png -------------------------------------------------------------------------------- /Assets/Square150x150Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square150x150Logo.scale-200.png -------------------------------------------------------------------------------- /Assets/Square150x150Logo.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square150x150Logo.scale-400.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-lightunplated_targetsize-16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-lightunplated_targetsize-16.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-lightunplated_targetsize-24.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-lightunplated_targetsize-24.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-lightunplated_targetsize-256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-lightunplated_targetsize-256.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-lightunplated_targetsize-32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-lightunplated_targetsize-32.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-lightunplated_targetsize-48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-lightunplated_targetsize-48.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-unplated_targetsize-16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-unplated_targetsize-16.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-unplated_targetsize-24.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-unplated_targetsize-24.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-unplated_targetsize-256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-unplated_targetsize-256.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-unplated_targetsize-32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-unplated_targetsize-32.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.altform-unplated_targetsize-48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.altform-unplated_targetsize-48.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.scale-100.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.scale-125.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.scale-150.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.scale-200.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.scale-400.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.targetsize-16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.targetsize-16.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.targetsize-24.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.targetsize-24.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.targetsize-24_altform-unplated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.targetsize-24_altform-unplated.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.targetsize-256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.targetsize-256.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.targetsize-32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.targetsize-32.png -------------------------------------------------------------------------------- /Assets/Square44x44Logo.targetsize-48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Square44x44Logo.targetsize-48.png -------------------------------------------------------------------------------- /Assets/StoreLogo.backup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/StoreLogo.backup.png -------------------------------------------------------------------------------- /Assets/StoreLogo.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/StoreLogo.scale-100.png -------------------------------------------------------------------------------- /Assets/StoreLogo.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/StoreLogo.scale-125.png -------------------------------------------------------------------------------- /Assets/StoreLogo.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/StoreLogo.scale-150.png -------------------------------------------------------------------------------- /Assets/StoreLogo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/StoreLogo.scale-200.png -------------------------------------------------------------------------------- /Assets/StoreLogo.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/StoreLogo.scale-400.png -------------------------------------------------------------------------------- /Assets/Wide310x150Logo.scale-100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Wide310x150Logo.scale-100.png -------------------------------------------------------------------------------- /Assets/Wide310x150Logo.scale-125.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Wide310x150Logo.scale-125.png -------------------------------------------------------------------------------- /Assets/Wide310x150Logo.scale-150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Wide310x150Logo.scale-150.png -------------------------------------------------------------------------------- /Assets/Wide310x150Logo.scale-200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Wide310x150Logo.scale-200.png -------------------------------------------------------------------------------- /Assets/Wide310x150Logo.scale-400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/Wide310x150Logo.scale-400.png -------------------------------------------------------------------------------- /Assets/rtf-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/rtf-icon.png -------------------------------------------------------------------------------- /Assets/txt-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/itsWindows11/TowPad/057657caa541e41ca307e5f02d56f4ef27d1201f/Assets/txt-icon.png -------------------------------------------------------------------------------- /BasePage.xaml.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.UI.Xaml.Controls; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.IO; 5 | using System.Linq; 6 | using System.Runtime.InteropServices.WindowsRuntime; 7 | using Windows.ApplicationModel.Activation; 8 | using Windows.ApplicationModel.Core; 9 | using Windows.Foundation; 10 | using Windows.Foundation.Collections; 11 | using Windows.Storage; 12 | using Windows.UI; 13 | using Windows.UI.Core.Preview; 14 | using Windows.UI.ViewManagement; 15 | using Windows.UI.Xaml; 16 | using Windows.UI.Xaml.Controls; 17 | using Windows.UI.Xaml.Controls.Primitives; 18 | using Windows.UI.Xaml.Data; 19 | using Windows.UI.Xaml.Input; 20 | using Windows.UI.Xaml.Media; 21 | using Windows.UI.Xaml.Navigation; 22 | 23 | // The Blank Page item template is documented at https://go.microsoft.com/fwlink/?LinkId=234238 24 | 25 | namespace Rich_Text_Editor 26 | { 27 | /// 28 | /// An empty page that can be used on its own or navigated to within a Frame. 29 | /// 30 | public sealed partial class BasePage : Page 31 | { 32 | public static BasePage Current; 33 | 34 | public bool _openDialog; 35 | 36 | public BasePage() 37 | { 38 | InitializeComponent(); 39 | 40 | Current = this; 41 | 42 | if (Tabs.TabItems.Count == 0) 43 | CreateNewTab(false); 44 | 45 | var appViewTitleBar = ApplicationView.GetForCurrentView().TitleBar; 46 | 47 | appViewTitleBar.ButtonBackgroundColor = Colors.Transparent; 48 | appViewTitleBar.ButtonInactiveBackgroundColor = Colors.Transparent; 49 | 50 | var coreTitleBar = CoreApplication.GetCurrentView().TitleBar; 51 | coreTitleBar.ExtendViewIntoTitleBar = true; 52 | 53 | Window.Current.SetTitleBar(CustomDragRegion); 54 | 55 | coreTitleBar.LayoutMetricsChanged += CoreTitleBar_LayoutMetricsChanged; 56 | 57 | // Keep tabs open if the root frame navigated elsewhere 58 | NavigationCacheMode = NavigationCacheMode.Enabled; 59 | 60 | (CompactOverlayBtn.Content as FontIcon).Glyph = ApplicationView.GetForCurrentView().ViewMode == ApplicationViewMode.CompactOverlay ? "\uEE49" : "\uEE47"; 61 | 62 | SystemNavigationManagerPreview.GetForCurrentView().CloseRequested += OnCloseRequest; 63 | } 64 | 65 | private async void OnCloseRequest(object sender, SystemNavigationCloseRequestedPreviewEventArgs e) 66 | { 67 | if (_openDialog) 68 | { 69 | e.Handled = true; 70 | return; 71 | } 72 | 73 | _openDialog = true; 74 | 75 | if (Tabs.TabItems.Count == 1) 76 | { 77 | if (!(((Tabs.SelectedItem as TabViewItem).Content as Frame).Content as MainPage).saved) 78 | { 79 | e.Handled = true; 80 | _ = (((Tabs.SelectedItem as TabViewItem).Content as Frame).Content as MainPage).ShowUnsavedDialog(); 81 | } 82 | } else if (Tabs.TabItems.Count > 1) 83 | { 84 | int unsavedItemsCount = 0; 85 | 86 | foreach (TabViewItem item in Tabs.TabItems.Cast()) 87 | { 88 | if (!((item.Content as Frame).Content as MainPage).saved) 89 | unsavedItemsCount++; 90 | } 91 | 92 | if (unsavedItemsCount > 0) 93 | { 94 | e.Handled = true; 95 | 96 | ContentDialog confirmationDialog = new() 97 | { 98 | Title = "Save", 99 | Content = $"There are unsaved changes to {(unsavedItemsCount > 1 ? "multiple documents" : "a document")}, want to save them?", 100 | CloseButtonText = "Cancel and save changes", 101 | CloseButtonStyle = Resources["AccentButtonStyle"] as Style, 102 | PrimaryButtonText = "Close app", 103 | }; 104 | 105 | // Allow the dialog to be opened again 106 | confirmationDialog.CloseButtonClick += (s, e) => _openDialog = false; 107 | 108 | ContentDialogResult result = await confirmationDialog.ShowAsync(); 109 | 110 | if (result == ContentDialogResult.Primary) 111 | await ApplicationView.GetForCurrentView().TryConsolidateAsync(); 112 | } 113 | } 114 | } 115 | 116 | private void CoreTitleBar_LayoutMetricsChanged(CoreApplicationViewTitleBar sender, object args) 117 | => CustomDragRegion.Height = ShellTitlebarInset.Height = sender.Height; 118 | 119 | public void TabView_AddTabButtonClick(TabView sender, object args) 120 | { 121 | CreateNewTab(); 122 | } 123 | 124 | public void CreateNewTab(bool selectTab = true, string tabName = null, object parameter = null) 125 | { 126 | TabViewItem newTab = new(); 127 | 128 | Frame frame = new(); 129 | 130 | newTab.Content = frame; 131 | newTab.IconSource = new Microsoft.UI.Xaml.Controls.SymbolIconSource() 132 | { 133 | Symbol = Symbol.Document 134 | }; 135 | 136 | newTab.Header = tabName ?? $"Text document {Tabs.TabItems.Count + 1}"; 137 | 138 | newTab.Style = Resources["TabViewItemStyle1"] as Style; 139 | 140 | frame.Navigate(typeof(MainPage), parameter); 141 | 142 | Tabs.TabItems.Add(newTab); 143 | 144 | if (selectTab) 145 | Tabs.SelectedItem = newTab; 146 | } 147 | 148 | public async void TabView_TabCloseRequested(TabView sender, TabViewTabCloseRequestedEventArgs args) 149 | { 150 | sender.TabItems.Remove(args.Tab); 151 | 152 | if (sender.TabItems.Count < 1) 153 | await ApplicationView.GetForCurrentView().TryConsolidateAsync(); 154 | } 155 | 156 | private async void CompactOverlayBtn_Click(object sender, RoutedEventArgs e) 157 | { 158 | if (sender is Button button) 159 | { 160 | if (ApplicationView.GetForCurrentView().ViewMode == ApplicationViewMode.CompactOverlay) 161 | { 162 | await ApplicationView.GetForCurrentView().TryEnterViewModeAsync(ApplicationViewMode.Default); 163 | (button.Content as FontIcon).Glyph = "\uEE49"; 164 | button.Margin = new(10, 5, 195, 10); 165 | } 166 | else 167 | { 168 | ViewModePreferences preferences = ViewModePreferences.CreateDefault(ApplicationViewMode.CompactOverlay); 169 | preferences.CustomSize = new Windows.Foundation.Size(400, 400); 170 | await ApplicationView.GetForCurrentView().TryEnterViewModeAsync(ApplicationViewMode.CompactOverlay, preferences); 171 | (button.Content as FontIcon).Glyph = "\uEE47"; 172 | button.Margin = new(10, 5, 70, 10); 173 | } 174 | } 175 | } 176 | 177 | public void OpenFilesWithArgs(FileActivatedEventArgs args) 178 | { 179 | foreach (var item in args.Files) 180 | { 181 | StorageFile file = item as StorageFile; 182 | 183 | CreateNewTab(tabName: file.Name, parameter: file); 184 | } 185 | } 186 | 187 | #region TabView keyboard accelerators 188 | private void NavigateToNumberedTabKeyboardAccelerator_Invoked(KeyboardAccelerator sender, KeyboardAcceleratorInvokedEventArgs args) 189 | { 190 | int tabToSelect = 0; 191 | 192 | switch (sender.Key) 193 | { 194 | case Windows.System.VirtualKey.Number1: 195 | case Windows.System.VirtualKey.NumberPad1: 196 | tabToSelect = 0; 197 | break; 198 | case Windows.System.VirtualKey.Number2: 199 | case Windows.System.VirtualKey.NumberPad2: 200 | tabToSelect = 1; 201 | break; 202 | case Windows.System.VirtualKey.Number3: 203 | case Windows.System.VirtualKey.NumberPad3: 204 | tabToSelect = 2; 205 | break; 206 | case Windows.System.VirtualKey.Number4: 207 | case Windows.System.VirtualKey.NumberPad4: 208 | tabToSelect = 3; 209 | break; 210 | case Windows.System.VirtualKey.Number5: 211 | case Windows.System.VirtualKey.NumberPad5: 212 | tabToSelect = 4; 213 | break; 214 | case Windows.System.VirtualKey.Number6: 215 | case Windows.System.VirtualKey.NumberPad6: 216 | tabToSelect = 5; 217 | break; 218 | case Windows.System.VirtualKey.Number7: 219 | case Windows.System.VirtualKey.NumberPad7: 220 | tabToSelect = 6; 221 | break; 222 | case Windows.System.VirtualKey.Number8: 223 | case Windows.System.VirtualKey.NumberPad8: 224 | tabToSelect = 7; 225 | break; 226 | case Windows.System.VirtualKey.Number9: 227 | case Windows.System.VirtualKey.NumberPad9: 228 | // Select the last tab 229 | tabToSelect = Tabs.TabItems.Count - 1; 230 | break; 231 | } 232 | 233 | // Only select the tab if it is in the list 234 | if (tabToSelect < Tabs.TabItems.Count) 235 | { 236 | Tabs.SelectedIndex = tabToSelect; 237 | } 238 | } 239 | 240 | #endregion 241 | } 242 | } 243 | -------------------------------------------------------------------------------- /Converters/BooleanToVisibility.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Windows.UI.Xaml; 7 | using Windows.UI.Xaml.Data; 8 | 9 | namespace Rich_Text_Editor.Converters 10 | { 11 | public class BooleanToVisibility : IValueConverter 12 | { 13 | public bool Reverse { get; set; } 14 | public object Convert(object value, Type targetType, object parameter, string language) 15 | { 16 | bool boolean = (bool)value; 17 | 18 | if (Reverse) 19 | { 20 | return boolean ? Visibility.Collapsed : Visibility.Visible; 21 | } 22 | 23 | return boolean ? Visibility.Visible : Visibility.Collapsed; 24 | } 25 | 26 | public object ConvertBack(object value, Type targetType, object parameter, string language) 27 | { 28 | return null; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Converters/IntToTextWrapping.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Windows.UI.Xaml; 7 | using Windows.UI.Xaml.Data; 8 | 9 | namespace Rich_Text_Editor.Converters 10 | { 11 | public class IntToTextWrapping : IValueConverter 12 | { 13 | public bool Reverse { get; set; } 14 | 15 | public object Convert(object value, Type targetType, object parameter, string language) 16 | { 17 | int val = (int)value; 18 | 19 | if (Reverse) 20 | { 21 | return val; 22 | } 23 | 24 | return val switch 25 | { 26 | 0 => TextWrapping.NoWrap, 27 | 1 => TextWrapping.Wrap, 28 | 2 => TextWrapping.WrapWholeWords, 29 | _ => TextWrapping.NoWrap, 30 | }; 31 | } 32 | 33 | public object ConvertBack(object value, Type targetType, object parameter, string language) 34 | { 35 | return null; 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /Converters/IntToThickness.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Windows.UI.Xaml; 7 | using Windows.UI.Xaml.Data; 8 | 9 | namespace Rich_Text_Editor.Converters 10 | { 11 | public class IntToThickness : IValueConverter 12 | { 13 | public bool Reverse { get; set; } 14 | 15 | public object Convert(object value, Type targetType, object parameter, string language) 16 | { 17 | int val = (int)value; 18 | 19 | if (Reverse) 20 | { 21 | return val; 22 | } 23 | 24 | return new Thickness(val); 25 | } 26 | 27 | public object ConvertBack(object value, Type targetType, object parameter, string language) 28 | { 29 | return null; 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Converters/SettingsConverters.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Windows.UI.Xaml; 3 | using Windows.UI.Xaml.Data; 4 | 5 | #nullable enable 6 | 7 | namespace Rich_Text_Editor.Converters 8 | { 9 | /// 10 | /// The generic base implementation of a value converter. 11 | /// 12 | /// The source type. 13 | /// The target type. 14 | public abstract class ValueConverter 15 | : IValueConverter 16 | { 17 | /// 18 | /// Converts a source value to the target type. 19 | /// 20 | /// 21 | /// 22 | public TTarget? Convert(TSource? value) 23 | { 24 | return Convert(value, null, null); 25 | } 26 | 27 | /// 28 | /// Converts a target value back to the source type. 29 | /// 30 | /// 31 | /// 32 | public TSource? ConvertBack(TTarget? value) 33 | { 34 | return ConvertBack(value, null, null); 35 | } 36 | 37 | /// 38 | /// Modifies the source data before passing it to the target for display in the UI. 39 | /// 40 | /// 41 | /// 42 | /// 43 | /// 44 | /// 45 | public object? Convert(object? value, Type? targetType, object? parameter, string? language) 46 | { 47 | // CastExceptions will occur when invalid value, or target type provided. 48 | return Convert((TSource?)value, parameter, language); 49 | } 50 | 51 | /// 52 | /// Modifies the target data before passing it to the source object. This method is called only in TwoWay bindings. 53 | /// 54 | /// 55 | /// 56 | /// 57 | /// 58 | /// 59 | public object? ConvertBack(object? value, Type? targetType, object? parameter, string? language) 60 | { 61 | // CastExceptions will occur when invalid value, or target type provided. 62 | return ConvertBack((TTarget?)value, parameter, language); 63 | } 64 | 65 | /// 66 | /// Converts a source value to the target type. 67 | /// 68 | /// 69 | /// 70 | /// 71 | /// 72 | protected virtual TTarget? Convert(TSource? value, object? parameter, string? language) 73 | { 74 | throw new NotSupportedException(); 75 | } 76 | 77 | /// 78 | /// Converts a target value back to the source type. 79 | /// 80 | /// 81 | /// 82 | /// 83 | /// 84 | protected virtual TSource? ConvertBack(TTarget? value, object? parameter, string? language) 85 | { 86 | throw new NotSupportedException(); 87 | } 88 | } 89 | 90 | /// 91 | /// The base class for converting instances of type T to object and vice versa. 92 | /// 93 | public abstract class ToObjectConverter 94 | : ValueConverter 95 | { 96 | /// 97 | /// Converts a source value to the target type. 98 | /// 99 | /// 100 | /// 101 | /// 102 | /// 103 | protected override object? Convert(T? value, object? parameter, string? language) 104 | { 105 | return value; 106 | } 107 | 108 | /// 109 | /// Converts a target value back to the source type. 110 | /// 111 | /// 112 | /// 113 | /// 114 | /// 115 | protected override T? ConvertBack(object? value, object? parameter, string? language) 116 | { 117 | return (T?)value; 118 | } 119 | } 120 | 121 | /// 122 | /// Converts a boolean to and from a visibility value. 123 | /// 124 | public class InverseBooleanConverter 125 | : ValueConverter 126 | { 127 | /// 128 | /// Converts a source value to the target type. 129 | /// 130 | /// 131 | /// 132 | /// 133 | /// 134 | protected override bool Convert(bool value, object? parameter, string? language) 135 | { 136 | return !value; 137 | } 138 | 139 | /// 140 | /// Converts a target value back to the source type. 141 | /// 142 | /// 143 | /// 144 | /// 145 | /// 146 | protected override bool ConvertBack(bool value, object? parameter, string? language) 147 | { 148 | return !value; 149 | } 150 | } 151 | 152 | public class NullToTrueConverter 153 | : ValueConverter 154 | { 155 | /// 156 | /// Determines whether an inverse conversion should take place. 157 | /// 158 | /// If set, the value True results in , and false in . 159 | public bool Inverse { get; set; } 160 | 161 | /// 162 | /// Converts a source value to the target type. 163 | /// 164 | /// 165 | /// 166 | /// 167 | /// 168 | protected override bool Convert(object? value, object? parameter, string? language) 169 | { 170 | return Inverse ? value != null : value == null; 171 | } 172 | 173 | /// 174 | /// Converts a target value back to the source type. 175 | /// 176 | /// 177 | /// 178 | /// 179 | /// 180 | protected override object? ConvertBack(bool value, object? parameter, string? language) 181 | { 182 | return null; 183 | } 184 | } 185 | 186 | public class StringNullOrWhiteSpaceToTrueConverter 187 | : ValueConverter 188 | { 189 | /// 190 | /// Determines whether an inverse conversion should take place. 191 | /// 192 | /// If set, the value True results in , and false in . 193 | public bool Inverse { get; set; } 194 | 195 | /// 196 | /// Converts a source value to the target type. 197 | /// 198 | /// 199 | /// 200 | /// 201 | /// 202 | protected override bool Convert(string? value, object? parameter, string? language) 203 | { 204 | return Inverse ? !string.IsNullOrWhiteSpace(value) : string.IsNullOrWhiteSpace(value); 205 | } 206 | 207 | /// 208 | /// Converts a target value back to the source type. 209 | /// 210 | /// 211 | /// 212 | /// 213 | /// 214 | protected override string ConvertBack(bool value, object? parameter, string? language) 215 | { 216 | return string.Empty; 217 | } 218 | } 219 | } -------------------------------------------------------------------------------- /Dialogs/AboutDialog.xaml: -------------------------------------------------------------------------------- 1 |  13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /Dialogs/AboutDialog.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Linq; 5 | using System.Reflection; 6 | using System.Runtime.InteropServices.WindowsRuntime; 7 | using Windows.Foundation; 8 | using Windows.Foundation.Collections; 9 | using Windows.UI.Xaml; 10 | using Windows.UI.Xaml.Controls; 11 | using Windows.UI.Xaml.Controls.Primitives; 12 | using Windows.UI.Xaml.Data; 13 | using Windows.UI.Xaml.Input; 14 | using Windows.UI.Xaml.Media; 15 | using Windows.UI.Xaml.Navigation; 16 | 17 | // The Content Dialog item template is documented at https://go.microsoft.com/fwlink/?LinkId=234238 18 | 19 | namespace Rich_Text_Editor.Dialogs 20 | { 21 | public sealed partial class AboutDialog : ContentDialog 22 | { 23 | public AboutDialog() 24 | { 25 | this.InitializeComponent(); 26 | 27 | Loaded += AboutDialog_Loaded; 28 | } 29 | 30 | private void AboutDialog_Loaded(object sender, RoutedEventArgs e) 31 | { 32 | VersionText.Text = $"Version {typeof(App).GetTypeInfo().Assembly.GetName().Version}"; 33 | } 34 | 35 | private void ContentDialog_PrimaryButtonClick(ContentDialog sender, ContentDialogButtonClickEventArgs args) 36 | { 37 | } 38 | 39 | private void ContentDialog_SecondaryButtonClick(ContentDialog sender, ContentDialogButtonClickEventArgs args) 40 | { 41 | } 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /Dialogs/ImageOptionsDialog.xaml: -------------------------------------------------------------------------------- 1 |  17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 29 | 30 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /Dialogs/ImageOptionsDialog.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Linq; 5 | using System.Runtime.InteropServices.WindowsRuntime; 6 | using Windows.Foundation; 7 | using Windows.Foundation.Collections; 8 | using Windows.UI.Xaml; 9 | using Windows.UI.Xaml.Controls; 10 | using Windows.UI.Xaml.Controls.Primitives; 11 | using Windows.UI.Xaml.Data; 12 | using Windows.UI.Xaml.Input; 13 | using Windows.UI.Xaml.Media; 14 | using Windows.UI.Xaml.Navigation; 15 | 16 | // The Content Dialog item template is documented at https://go.microsoft.com/fwlink/?LinkId=234238 17 | 18 | namespace Rich_Text_Editor.Dialogs 19 | { 20 | public sealed partial class ImageOptionsDialog : ContentDialog 21 | { 22 | public double DefaultWidth { get; set; } 23 | public double DefaultHeight { get; set; } 24 | public string Tag { get; private set; } 25 | 26 | public ImageOptionsDialog() 27 | { 28 | InitializeComponent(); 29 | 30 | Loaded += ImageOptionsDialog_Loaded; 31 | } 32 | 33 | private void ImageOptionsDialog_Loaded(object sender, RoutedEventArgs e) 34 | { 35 | WidthBox.Value = DefaultWidth; 36 | HeightBox.Value = DefaultHeight; 37 | } 38 | 39 | private void ContentDialog_PrimaryButtonClick(ContentDialog sender, ContentDialogButtonClickEventArgs args) 40 | { 41 | DefaultWidth = WidthBox.Value; 42 | DefaultHeight = HeightBox.Value; 43 | } 44 | 45 | private void ContentDialog_SecondaryButtonClick(ContentDialog sender, ContentDialogButtonClickEventArgs args) 46 | { 47 | } 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /Helpers/ResourceHelper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Windows.ApplicationModel.Resources; 7 | using Windows.UI.Xaml.Markup; 8 | 9 | namespace Rich_Text_Editor.Helpers 10 | { 11 | /// 12 | /// A markup extension that gets a string from a resource. 13 | /// Can also be used outside of XAML through the static 14 | /// method. 15 | /// 16 | [MarkupExtensionReturnType(ReturnType = typeof(string))] 17 | public sealed class ResourceHelper : MarkupExtension 18 | { 19 | private static readonly ResourceLoader loader = ResourceLoader.GetForViewIndependentUse(); 20 | 21 | /// 22 | /// Resource identifier to get the string from. 23 | /// 24 | public string Name { get; set; } 25 | 26 | protected override object ProvideValue() 27 | => loader.GetString(Name); 28 | 29 | /// 30 | /// Gets the string from the resource with the provided 31 | /// identifier. 32 | /// 33 | public static string GetString(string resource) 34 | => loader.GetString(resource); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /Helpers/RichEditHelpers.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Windows.UI.Text; 7 | using Windows.UI.Xaml.Controls; 8 | 9 | namespace Rich_Text_Editor.Helpers 10 | { 11 | public static class RichEditHelpers 12 | { 13 | public static void ChangeFontSize(this RichEditBox editor, float size) 14 | { 15 | ITextSelection selectedText = editor.Document.Selection; 16 | ITextCharacterFormat charFormatting = selectedText.CharacterFormat; 17 | charFormatting.Size = size; 18 | selectedText.CharacterFormat = charFormatting; 19 | } 20 | 21 | public static void Replace(this RichEditBox editor, bool replaceAll, string replace, string find = "") 22 | { 23 | if (replaceAll) 24 | { 25 | editor.Document.GetText(TextGetOptions.FormatRtf, out string value); 26 | if (!(string.IsNullOrWhiteSpace(value) && string.IsNullOrWhiteSpace(find) && string.IsNullOrWhiteSpace(replace))) 27 | { 28 | editor.Document.SetText(TextSetOptions.FormatRtf, value.Replace(find, replace)); 29 | } 30 | } else 31 | { 32 | editor.Document.Selection.SetText(TextSetOptions.None, replace); 33 | } 34 | } 35 | 36 | public static void AlignSelectedTo(this RichEditBox editor, AlignMode mode) 37 | { 38 | ITextSelection selectedText = editor.Document.Selection; 39 | 40 | if (selectedText != null) 41 | { 42 | switch (mode) 43 | { 44 | case AlignMode.Left: 45 | selectedText.ParagraphFormat.Alignment = ParagraphAlignment.Left; 46 | break; 47 | case AlignMode.Center: 48 | selectedText.ParagraphFormat.Alignment = ParagraphAlignment.Center; 49 | break; 50 | case AlignMode.Right: 51 | selectedText.ParagraphFormat.Alignment = ParagraphAlignment.Right; 52 | break; 53 | } 54 | } 55 | } 56 | 57 | public static void FormatSelected(this RichEditBox editor, FormattingMode mode) 58 | { 59 | ITextSelection selectedText = editor.Document.Selection; 60 | 61 | if (selectedText != null) 62 | { 63 | ITextCharacterFormat charFormatting = selectedText.CharacterFormat; 64 | switch (mode) 65 | { 66 | case FormattingMode.Bold: 67 | charFormatting.Bold = charFormatting.Bold == FormatEffect.On ? FormatEffect.Off : FormatEffect.On; 68 | break; 69 | case FormattingMode.Italic: 70 | charFormatting.Italic = charFormatting.Italic == FormatEffect.On ? FormatEffect.Off : FormatEffect.On; 71 | break; 72 | case FormattingMode.Underline: 73 | charFormatting.Underline = charFormatting.Underline == UnderlineType.Single ? UnderlineType.None : UnderlineType.Single; 74 | break; 75 | case FormattingMode.Strikethrough: 76 | charFormatting.Strikethrough = charFormatting.Strikethrough == FormatEffect.On ? FormatEffect.Off : FormatEffect.On; 77 | break; 78 | case FormattingMode.Subscript: 79 | charFormatting.Subscript = charFormatting.Subscript == FormatEffect.On ? FormatEffect.Off : FormatEffect.On; 80 | break; 81 | case FormattingMode.Superscript: 82 | charFormatting.Superscript = charFormatting.Superscript == FormatEffect.On ? FormatEffect.Off : FormatEffect.On; 83 | break; 84 | } 85 | selectedText.CharacterFormat = charFormatting; 86 | } 87 | } 88 | 89 | public enum AlignMode 90 | { 91 | Left, 92 | Right, 93 | Center 94 | } 95 | 96 | public enum FormattingMode 97 | { 98 | Bold, 99 | Italic, 100 | Strikethrough, 101 | Underline, 102 | Subscript, 103 | Superscript 104 | } 105 | } 106 | } 107 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 itsWindows11 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Package.appxmanifest: -------------------------------------------------------------------------------- 1 |  2 | 3 | 12 | 13 | 17 | 18 | 19 | 20 | 21 | TowPad 22 | itsWindows11 23 | Assets\StoreLogo.png 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 41 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | assets\rtf-icon.png 54 | 55 | .rtf 56 | 57 | 58 | 59 | 60 | 61 | assets\txt-icon.png 62 | 63 | .txt 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | -------------------------------------------------------------------------------- /Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.InteropServices; 3 | 4 | // General Information about an assembly is controlled through the following 5 | // set of attributes. Change these attribute values to modify the information 6 | // associated with an assembly. 7 | [assembly: AssemblyTitle("TowPad")] 8 | [assembly: AssemblyDescription("")] 9 | [assembly: AssemblyConfiguration("")] 10 | [assembly: AssemblyCompany("")] 11 | [assembly: AssemblyProduct("TowPad")] 12 | [assembly: AssemblyCopyright("Copyright © 2022")] 13 | [assembly: AssemblyTrademark("")] 14 | [assembly: AssemblyCulture("")] 15 | 16 | // Version information for an assembly consists of the following four values: 17 | // 18 | // Major Version 19 | // Minor Version 20 | // Build Number 21 | // Revision 22 | // 23 | // You can specify all the values or you can default the Build and Revision Numbers 24 | // by using the '*' as shown below: 25 | // [assembly: AssemblyVersion("1.0.*")] 26 | [assembly: AssemblyVersion("2.1.0.0")] 27 | [assembly: AssemblyFileVersion("2.1.0.0")] 28 | [assembly: ComVisible(false)] 29 | -------------------------------------------------------------------------------- /Properties/Default.rd.xml: -------------------------------------------------------------------------------- 1 | 17 | 18 | 19 | 20 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # TowPad 2 | 3 | 4 | A UWP version of... WordPad! 5 | 6 | This app features a simple and easy to use interface other than ribbons. 7 | 8 | ![TowPad](https://user-images.githubusercontent.com/81253203/134414755-894fcb4c-cac1-4edb-af92-4be47a342177.png) 9 | 10 | ### Windows 11 11 | ![image](https://user-images.githubusercontent.com/81253203/135627983-c9b242ba-ad76-4134-8ed6-a57e3b477390.png) 12 | ![image](https://user-images.githubusercontent.com/81253203/135628613-bc40ed7d-bc5d-4c30-811a-57578f2a18d3.png) 13 | 14 | ### Windows 10 15 | ![image](https://user-images.githubusercontent.com/81253203/133136254-4df31e72-2f6e-4a3c-8d29-5d0806003bd5.png) 16 | ![image](https://user-images.githubusercontent.com/81253203/133136586-65c15c90-9469-485e-b845-9579472aaced.png) 17 | 18 | ### **Features:** 19 | 20 | - **Bold** / *Italic* / Underline / ~~Strikethrough~~ 21 | 22 | - Superscript / Subscript 23 | 24 | - Change font size 25 | 26 | - Change font color 27 | 28 | - Change font family 29 | 30 | - Align to left/center/right 31 | 32 | - Adding image/hyperlink 33 | 34 | - Find text 35 | 36 | - Undo/redo 37 | 38 | - Fluid, fast 39 | 40 | ### **Requirements to run the app** 41 | You must run at least Windows 10, version 1809 42 | 43 | ### **Prerequisites to compile the app** 44 | - Have at least Windows SDK (UWP) version 1809 45 | - Visual Studio 2019 46 | 47 | ### Used libraries 48 | - [WinUI](https://github.com/microsoft/microsoft-ui-xaml) 49 | - [Win2D](https://github.com/Microsoft/Win2D) 50 | - [Windows Community Toolkit](https://github.com/CommunityToolkit/WindowsCommunityToolkit) 51 | 52 | This file and project is still in development, things might change over time as the app takes shape ~~and ideas~~. 53 | 54 | Licensed under the MIT license. 55 | -------------------------------------------------------------------------------- /Strings/de-DE/Resources.resw: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | Über 122 | 123 | 124 | Link hinzufügen 125 | 126 | 127 | Bild hinzufügen 128 | 129 | 130 | Zentrieren 131 | 132 | 133 | linksbündig ausrichten 134 | 135 | 136 | rechtsbündig ausrichten 137 | 138 | 139 | TowPad 140 | 141 | 142 | Fett 143 | 144 | 145 | Kopieren 146 | 147 | 148 | Ausschneiden 149 | 150 | 151 | Standardschriftart 152 | 153 | 154 | Polster zum Fensterrahmen für Dokumentenansicht 155 | 156 | 157 | Editor 158 | 159 | 160 | Bearbeiten 161 | 162 | 163 | Beenden 164 | 165 | 166 | Datei 167 | 168 | 169 | In Dokument finden 170 | 171 | 172 | Schriftfarbe 173 | 174 | 175 | Hilfe 176 | 177 | 178 | Startseite 179 | 180 | 181 | Kursiv 182 | 183 | 184 | Neues Dokument 185 | 186 | 187 | Öffnen 188 | 189 | 190 | Einfügen 191 | 192 | 193 | Drucken 194 | 195 | 196 | Zuletzt geöffnete Dateien 197 | 198 | 199 | Wiederholen 200 | 201 | 202 | Als Kopie speichern 203 | 204 | 205 | Speichern 206 | 207 | 208 | Einstellungen 209 | 210 | 211 | Durschstreichen 212 | 213 | 214 | Unterstreichen 215 | 216 | 217 | Rückgängig 218 | 219 | 220 | Was is neu 221 | 222 | 223 | Zeilenumbruch 224 | 225 | 226 | -------------------------------------------------------------------------------- /Strings/en-GB/Resources.resw: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | About 122 | 123 | 124 | Add hyperlink 125 | 126 | 127 | Add image 128 | 129 | 130 | Align to Centre 131 | 132 | 133 | Align to Left 134 | 135 | 136 | Align to Right 137 | 138 | 139 | TowPad 140 | 141 | 142 | Bold 143 | 144 | 145 | Copy 146 | 147 | 148 | Cut 149 | 150 | 151 | Default font family 152 | 153 | 154 | Document view padding 155 | 156 | 157 | Editor 158 | 159 | 160 | Edit 161 | 162 | 163 | Exit 164 | 165 | 166 | File 167 | 168 | 169 | Find in document 170 | 171 | 172 | Font colour 173 | 174 | 175 | Help 176 | 177 | 178 | Home 179 | 180 | 181 | Italic 182 | 183 | 184 | New document 185 | 186 | 187 | Open 188 | 189 | 190 | Paste 191 | 192 | 193 | Print 194 | 195 | 196 | Recently accessed files 197 | 198 | 199 | Redo 200 | 201 | 202 | Save as Copy 203 | 204 | 205 | Save 206 | 207 | 208 | Settings 209 | 210 | 211 | Strikethrough 212 | 213 | 214 | Underline 215 | 216 | 217 | Undo 218 | 219 | 220 | What's New 221 | 222 | 223 | Text wrapping 224 | 225 | -------------------------------------------------------------------------------- /Strings/en-US/Resources.resw: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | About 122 | 123 | 124 | Add hyperlink 125 | 126 | 127 | Add image 128 | 129 | 130 | Align to Center 131 | 132 | 133 | Align to Left 134 | 135 | 136 | Align to Right 137 | 138 | 139 | TowPad 140 | 141 | 142 | Bold 143 | 144 | 145 | Copy 146 | 147 | 148 | Cut 149 | 150 | 151 | Default font family 152 | 153 | 154 | Document view padding 155 | 156 | 157 | Editor 158 | 159 | 160 | Edit 161 | 162 | 163 | Exit 164 | 165 | 166 | File 167 | 168 | 169 | Find in document 170 | 171 | 172 | Font color 173 | 174 | 175 | Help 176 | 177 | 178 | Home 179 | 180 | 181 | Italic 182 | 183 | 184 | New document 185 | 186 | 187 | Open 188 | 189 | 190 | Paste 191 | 192 | 193 | Print 194 | 195 | 196 | Recently accessed files 197 | 198 | 199 | Redo 200 | 201 | 202 | Save as Copy 203 | 204 | 205 | Save 206 | 207 | 208 | Settings 209 | 210 | 211 | Strikethrough 212 | 213 | 214 | Underline 215 | 216 | 217 | Undo 218 | 219 | 220 | What's New 221 | 222 | 223 | Text wrapping 224 | 225 | -------------------------------------------------------------------------------- /Strings/pt-PT/Resources.resw: -------------------------------------------------------------------------------- 1 | 2 | 3 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | text/microsoft-resx 109 | 110 | 111 | 2.0 112 | 113 | 114 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 115 | 116 | 117 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 118 | 119 | 120 | Acerca de 121 | 122 | 123 | Adicionar hiperligação 124 | 125 | 126 | Adicionar imagem 127 | 128 | 129 | Alinhar ao Centro 130 | 131 | 132 | Alinhar à Esquerda 133 | 134 | 135 | Alinhar à Direita 136 | 137 | 138 | TowPad 139 | 140 | 141 | Negrito 142 | 143 | 144 | Copiar 145 | 146 | 147 | Cortar 148 | 149 | 150 | Família de fontes predefinida 151 | 152 | 153 | Estofamento de visualização de documentos 154 | 155 | 156 | Editor 157 | 158 | 159 | Editar 160 | 161 | 162 | Sair 163 | 164 | 165 | Ficheiro 166 | 167 | 168 | Localizar no documento 169 | 170 | 171 | Cor da fonte 172 | 173 | 174 | Ajuda 175 | 176 | 177 | Base 178 | 179 | 180 | Itálico 181 | 182 | 183 | Novo documento 184 | 185 | 186 | Abrir 187 | 188 | 189 | Colar 190 | 191 | 192 | Imprimir 193 | 194 | 195 | Ficheiros acedidos recentemente 196 | 197 | 198 | Anular 199 | 200 | 201 | Guardar como Cópia 202 | 203 | 204 | Guardar 205 | 206 | 207 | Definições 208 | 209 | 210 | Rasurado 211 | 212 | 213 | Sublinhado 214 | 215 | 216 | Refazer 217 | 218 | 219 | O que há de Novo 220 | 221 | 222 | Moldagem de texto 223 | 224 | 225 | -------------------------------------------------------------------------------- /TowPad.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | x86 7 | {288D1EDC-203B-437A-B570-70D34A6BBE94} 8 | AppContainerExe 9 | Properties 10 | Rich_Text_Editor 11 | Rich Text Editor 12 | en-US 13 | UAP 14 | 10.0.22000.0 15 | 10.0.17763.0 16 | 14 17 | 512 18 | {A5A43C5B-DE2A-4C0C-9213-0A381AF9435A};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 19 | true 20 | True 21 | False 22 | 23 | 24 | SHA256 25 | False 26 | False 27 | Always 28 | x86|x64|arm|arm64 29 | 0 30 | True 31 | True 32 | 33 | 34 | true 35 | bin\x86\Debug\ 36 | DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP 37 | ;2008 38 | full 39 | x86 40 | false 41 | prompt 42 | true 43 | 44 | 45 | bin\x86\Release\ 46 | TRACE;NETFX_CORE;WINDOWS_UWP 47 | true 48 | ;2008 49 | pdbonly 50 | x86 51 | false 52 | prompt 53 | true 54 | true 55 | 56 | 57 | true 58 | bin\ARM\Debug\ 59 | DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP 60 | ;2008 61 | full 62 | ARM 63 | false 64 | prompt 65 | true 66 | 67 | 68 | bin\ARM\Release\ 69 | TRACE;NETFX_CORE;WINDOWS_UWP 70 | true 71 | ;2008 72 | pdbonly 73 | ARM 74 | false 75 | prompt 76 | true 77 | true 78 | 79 | 80 | true 81 | bin\ARM64\Debug\ 82 | DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP 83 | ;2008 84 | full 85 | ARM64 86 | false 87 | prompt 88 | true 89 | true 90 | 91 | 92 | bin\ARM64\Release\ 93 | TRACE;NETFX_CORE;WINDOWS_UWP 94 | true 95 | ;2008 96 | pdbonly 97 | ARM64 98 | false 99 | prompt 100 | true 101 | true 102 | 103 | 104 | true 105 | bin\x64\Debug\ 106 | DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP 107 | ;2008 108 | full 109 | x64 110 | false 111 | prompt 112 | true 113 | 114 | 115 | bin\x64\Release\ 116 | TRACE;NETFX_CORE;WINDOWS_UWP 117 | true 118 | ;2008 119 | pdbonly 120 | x64 121 | false 122 | prompt 123 | true 124 | true 125 | false 126 | 127 | 128 | PackageReference 129 | 130 | 131 | 132 | App.xaml 133 | 134 | 135 | BasePage.xaml 136 | 137 | 138 | 139 | 140 | 141 | 142 | AboutDialog.xaml 143 | 144 | 145 | ImageOptionsDialog.xaml 146 | 147 | 148 | 149 | 150 | SettingsBlockControl.xaml 151 | 152 | 153 | SettingsDisplayControl.xaml 154 | 155 | 156 | 157 | 158 | 159 | 160 | HomePage.xaml 161 | 162 | 163 | Views\MainPage.xaml 164 | 165 | 166 | 167 | SettingsPage.xaml 168 | 169 | 170 | 171 | 172 | Designer 173 | 174 | 175 | 176 | 177 | 178 | 179 | 180 | 181 | 182 | 183 | 184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | 201 | 202 | 203 | 204 | 205 | 206 | 207 | 208 | 209 | 210 | 211 | 212 | 213 | 214 | 215 | 216 | 217 | 218 | 219 | 220 | 221 | 222 | 223 | 224 | 225 | 226 | 227 | 228 | 229 | 230 | 231 | 232 | 233 | 234 | MSBuild:Compile 235 | Designer 236 | 237 | 238 | Designer 239 | MSBuild:Compile 240 | 241 | 242 | Designer 243 | MSBuild:Compile 244 | 245 | 246 | Designer 247 | MSBuild:Compile 248 | 249 | 250 | MSBuild:Compile 251 | Designer 252 | 253 | 254 | MSBuild:Compile 255 | Designer 256 | 257 | 258 | Designer 259 | MSBuild:Compile 260 | 261 | 262 | MSBuild:Compile 263 | Designer 264 | 265 | 266 | Designer 267 | MSBuild:Compile 268 | 269 | 270 | 271 | 272 | 6.2.14 273 | 274 | 275 | 7.1.3 276 | 277 | 278 | 7.1.3 279 | 280 | 281 | 2.8.2-prerelease.220830001 282 | 283 | 284 | 1.26.0 285 | 286 | 287 | 288 | 289 | 290 | 291 | 292 | 293 | 294 | 14.0 295 | 296 | 297 | 304 | 305 | enable 306 | 9.0 307 | 308 | -------------------------------------------------------------------------------- /TowPad.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Version 17 4 | VisualStudioVersion = 17.0.32112.339 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TowPad", "TowPad.csproj", "{288D1EDC-203B-437A-B570-70D34A6BBE94}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|ARM = Debug|ARM 11 | Debug|ARM64 = Debug|ARM64 12 | Debug|x64 = Debug|x64 13 | Debug|x86 = Debug|x86 14 | Release|ARM = Release|ARM 15 | Release|ARM64 = Release|ARM64 16 | Release|x64 = Release|x64 17 | Release|x86 = Release|x86 18 | EndGlobalSection 19 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 20 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|ARM.ActiveCfg = Debug|ARM 21 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|ARM.Build.0 = Debug|ARM 22 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|ARM.Deploy.0 = Debug|ARM 23 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|ARM64.ActiveCfg = Debug|ARM64 24 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|ARM64.Build.0 = Debug|ARM64 25 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|ARM64.Deploy.0 = Debug|ARM64 26 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|x64.ActiveCfg = Debug|x64 27 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|x64.Build.0 = Debug|x64 28 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|x64.Deploy.0 = Debug|x64 29 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|x86.ActiveCfg = Debug|x86 30 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|x86.Build.0 = Debug|x86 31 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Debug|x86.Deploy.0 = Debug|x86 32 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|ARM.ActiveCfg = Release|ARM 33 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|ARM.Build.0 = Release|ARM 34 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|ARM.Deploy.0 = Release|ARM 35 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|ARM64.ActiveCfg = Release|ARM64 36 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|ARM64.Build.0 = Release|ARM64 37 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|ARM64.Deploy.0 = Release|ARM64 38 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|x64.ActiveCfg = Release|x64 39 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|x64.Build.0 = Release|x64 40 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|x64.Deploy.0 = Release|x64 41 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|x86.ActiveCfg = Release|x86 42 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|x86.Build.0 = Release|x86 43 | {288D1EDC-203B-437A-B570-70D34A6BBE94}.Release|x86.Deploy.0 = Release|x86 44 | EndGlobalSection 45 | GlobalSection(SolutionProperties) = preSolution 46 | HideSolutionNode = FALSE 47 | EndGlobalSection 48 | GlobalSection(ExtensibilityGlobals) = postSolution 49 | SolutionGuid = {BCBDC235-692C-406C-8E70-2A0B0582F2A0} 50 | EndGlobalSection 51 | EndGlobal 52 | -------------------------------------------------------------------------------- /UserControls/SettingsBlockControl.xaml: -------------------------------------------------------------------------------- 1 |  13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 27 | 28 | 37 | 38 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 78 | 79 | 80 | 81 | 82 | 83 | 88 | 89 | 90 | 91 | -------------------------------------------------------------------------------- /UserControls/SettingsBlockControl.xaml.cs: -------------------------------------------------------------------------------- 1 | using Windows.UI.Xaml; 2 | using Windows.UI.Xaml.Controls; 3 | using Windows.UI.Xaml.Markup; 4 | 5 | namespace Rich_Text_Editor.UserControls 6 | { 7 | [ContentProperty(Name = nameof(SettingsActionableElement))] 8 | public sealed partial class SettingsBlockControl : UserControl 9 | { 10 | public FrameworkElement SettingsActionableElement { get; set; } 11 | 12 | public static readonly DependencyProperty ExpandableContentProperty = DependencyProperty.Register( 13 | "ExpandableContent", 14 | typeof(FrameworkElement), 15 | typeof(SettingsBlockControl), 16 | new PropertyMetadata(null) 17 | ); 18 | 19 | public FrameworkElement ExpandableContent 20 | { 21 | get => (FrameworkElement)GetValue(ExpandableContentProperty); 22 | set => SetValue(ExpandableContentProperty, value); 23 | } 24 | 25 | public static readonly DependencyProperty AdditionalDescriptionContentProperty = DependencyProperty.Register( 26 | "AdditionalDescriptionContent", 27 | typeof(FrameworkElement), 28 | typeof(SettingsBlockControl), 29 | new PropertyMetadata(null) 30 | ); 31 | 32 | public FrameworkElement AdditionalDescriptionContent 33 | { 34 | get => (FrameworkElement)GetValue(AdditionalDescriptionContentProperty); 35 | set => SetValue(AdditionalDescriptionContentProperty, value); 36 | } 37 | 38 | public static readonly DependencyProperty TitleProperty = DependencyProperty.Register( 39 | "Title", 40 | typeof(string), 41 | typeof(SettingsBlockControl), 42 | new PropertyMetadata(null) 43 | ); 44 | 45 | public string Title 46 | { 47 | get => (string)GetValue(TitleProperty); 48 | set => SetValue(TitleProperty, value); 49 | } 50 | 51 | public static readonly DependencyProperty DescriptionProperty = DependencyProperty.Register( 52 | "Description", 53 | typeof(string), 54 | typeof(SettingsBlockControl), 55 | new PropertyMetadata(null) 56 | ); 57 | 58 | public string Description 59 | { 60 | get => (string)GetValue(DescriptionProperty); 61 | set => SetValue(DescriptionProperty, value); 62 | } 63 | 64 | public static readonly DependencyProperty IconProperty = DependencyProperty.Register( 65 | "Icon", 66 | typeof(IconElement), 67 | typeof(SettingsBlockControl), 68 | new PropertyMetadata(null) 69 | ); 70 | 71 | public IconElement Icon 72 | { 73 | get => (IconElement)GetValue(IconProperty); 74 | set => SetValue(IconProperty, value); 75 | } 76 | 77 | public static readonly DependencyProperty IsClickableProperty = DependencyProperty.Register( 78 | "IsClickable", 79 | typeof(bool), 80 | typeof(SettingsBlockControl), 81 | new PropertyMetadata(false) 82 | ); 83 | 84 | public bool IsClickable 85 | { 86 | get => (bool)GetValue(IsClickableProperty); 87 | set => SetValue(IsClickableProperty, value); 88 | } 89 | 90 | // 91 | // Summary: 92 | // Occurs when a button control is clicked. 93 | public event RoutedEventHandler Click; 94 | 95 | public SettingsBlockControl() 96 | { 97 | InitializeComponent(); 98 | } 99 | 100 | private void ActionableButton_Click(object sender, RoutedEventArgs e) 101 | { 102 | Click?.Invoke(this, e); 103 | } 104 | 105 | private void Expander_Expanding(Microsoft.UI.Xaml.Controls.Expander sender, Microsoft.UI.Xaml.Controls.ExpanderExpandingEventArgs args) 106 | { 107 | Click?.Invoke(this, new RoutedEventArgs()); 108 | } 109 | 110 | private void Expander_Collapsed(Microsoft.UI.Xaml.Controls.Expander sender, Microsoft.UI.Xaml.Controls.ExpanderCollapsedEventArgs args) 111 | { 112 | Click?.Invoke(this, new RoutedEventArgs()); 113 | } 114 | } 115 | } -------------------------------------------------------------------------------- /UserControls/SettingsDisplayControl.xaml: -------------------------------------------------------------------------------- 1 |  12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 62 | 63 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 77 | 78 | 83 | 84 | 88 | 89 | 90 | 97 | 98 | -------------------------------------------------------------------------------- /UserControls/SettingsDisplayControl.xaml.cs: -------------------------------------------------------------------------------- 1 | using Windows.UI.Xaml; 2 | using Windows.UI.Xaml.Controls; 3 | using Windows.UI.Xaml.Markup; 4 | 5 | namespace Rich_Text_Editor.UserControls 6 | { 7 | [ContentProperty(Name = nameof(SettingsActionableElement))] 8 | public sealed partial class SettingsDisplayControl : UserControl 9 | { 10 | public FrameworkElement SettingsActionableElement { get; set; } 11 | 12 | public static readonly DependencyProperty AdditionalDescriptionContentProperty = DependencyProperty.Register( 13 | "AdditionalDescriptionContent", 14 | typeof(FrameworkElement), 15 | typeof(SettingsDisplayControl), 16 | new PropertyMetadata(null) 17 | ); 18 | 19 | public FrameworkElement AdditionalDescriptionContent 20 | { 21 | get => (FrameworkElement)GetValue(AdditionalDescriptionContentProperty); 22 | set => SetValue(AdditionalDescriptionContentProperty, value); 23 | } 24 | 25 | public static readonly DependencyProperty TitleProperty = DependencyProperty.Register( 26 | "Title", 27 | typeof(string), 28 | typeof(SettingsDisplayControl), 29 | new PropertyMetadata(null) 30 | ); 31 | 32 | public string Title 33 | { 34 | get => (string)GetValue(TitleProperty); 35 | set => SetValue(TitleProperty, value); 36 | } 37 | 38 | public static readonly DependencyProperty DescriptionProperty = DependencyProperty.Register( 39 | "Description", 40 | typeof(string), 41 | typeof(SettingsDisplayControl), 42 | new PropertyMetadata(null) 43 | ); 44 | 45 | public string Description 46 | { 47 | get => (string)GetValue(DescriptionProperty); 48 | set => SetValue(DescriptionProperty, value); 49 | } 50 | 51 | public static readonly DependencyProperty IconProperty = DependencyProperty.Register( 52 | "Icon", 53 | typeof(IconElement), 54 | typeof(SettingsDisplayControl), 55 | new PropertyMetadata(null) 56 | ); 57 | 58 | public IconElement Icon 59 | { 60 | get => (IconElement)GetValue(IconProperty); 61 | set => SetValue(IconProperty, value); 62 | } 63 | 64 | public SettingsDisplayControl() 65 | { 66 | InitializeComponent(); 67 | VisualStateManager.GoToState(this, "NormalState", false); 68 | } 69 | 70 | private void MainPanel_SizeChanged(object sender, SizeChangedEventArgs e) 71 | { 72 | if (e.NewSize.Width == e.PreviousSize.Width || ActionableElement == null) 73 | return; 74 | 75 | if (ActionableElement.ActualWidth > e.NewSize.Width / 3) 76 | { 77 | VisualStateManager.GoToState(this, "CompactState", false); 78 | } 79 | else 80 | { 81 | VisualStateManager.GoToState(this, "NormalState", false); 82 | } 83 | } 84 | } 85 | } 86 | -------------------------------------------------------------------------------- /ViewModels/RecentlyUsedViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Windows.Storage; 7 | 8 | namespace Rich_Text_Editor.ViewModels 9 | { 10 | public class RecentlyUsedViewModel 11 | { 12 | public string Name { get; set; } 13 | public string Path { get; set; } 14 | public StorageFile OriginalFile { get; set; } 15 | public string Token { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /ViewModels/Settings/SettingsViewModel.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.Graphics.Canvas.Text; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using Windows.Storage; 6 | using Windows.UI.Xaml; 7 | using Windows.UI.Xaml.Controls; 8 | 9 | namespace Rich_Text_Editor.ViewModels 10 | { 11 | public class SettingsViewModel : ViewModel 12 | { 13 | public SettingsViewModel() { } 14 | 15 | public List Fonts 16 | => CanvasTextFormat.GetSystemFontFamilies().OrderBy(f => f).ToList(); 17 | 18 | #region Appearance 19 | public int DocumentViewPadding 20 | { 21 | get => Get("Appearance", nameof(DocumentViewPadding), 11); 22 | set => Set("Appearance", nameof(DocumentViewPadding), value); 23 | } 24 | 25 | public string DefaultFont 26 | { 27 | get => Get("Appearance", nameof(DefaultFont), "Calibri"); 28 | set => Set("Appearance", nameof(DefaultFont), value); 29 | } 30 | 31 | // Modes: 32 | // 0. No wrap 33 | // 1. Wrap 34 | // 2. Wrap whole words 35 | 36 | public int TextWrapping 37 | { 38 | get => Get("Appearance", nameof(TextWrapping), 0); 39 | set => Set("Appearance", nameof(TextWrapping), value); 40 | } 41 | 42 | // Modes: 43 | // 0. Light 44 | // 1. Dark 45 | // 2. Default 46 | 47 | public int Theme 48 | { 49 | get => Get("Appearance", nameof(Theme), 2); 50 | set 51 | { 52 | Set("Appearance", nameof(Theme), value); 53 | switch (value) 54 | { 55 | case 0: 56 | (Window.Current.Content as Frame).RequestedTheme = ElementTheme.Light; 57 | break; 58 | case 1: 59 | (Window.Current.Content as Frame).RequestedTheme = ElementTheme.Dark; 60 | break; 61 | case 2: 62 | (Window.Current.Content as Frame).RequestedTheme = ElementTheme.Default; 63 | break; 64 | } 65 | } 66 | } 67 | #endregion 68 | 69 | #region Setting/getting settings 70 | /// 71 | /// Gets an app setting. 72 | /// 73 | /// Setting store name. 74 | /// Setting name. 75 | /// Default setting value. 76 | /// App setting value. 77 | /// If the store parameter is "Local", a local setting will be returned. 78 | protected T Get(string store, string setting, T defaultValue) 79 | { 80 | // If store == "Local", get a local setting 81 | if (store == "Local") 82 | { 83 | // Get app settings 84 | ApplicationDataContainer localSettings = ApplicationData.Current.LocalSettings; 85 | 86 | // Check if the setting exists 87 | if (localSettings.Values[setting] == null) 88 | { 89 | localSettings.Values[setting] = defaultValue; 90 | } 91 | 92 | object val = localSettings.Values[setting]; 93 | 94 | // Return the setting if type matches 95 | if (val is not T) 96 | { 97 | throw new ArgumentException("Type mismatch for \"" + setting + "\" in local store. Got " + val.GetType()); 98 | } 99 | return (T)val; 100 | } 101 | 102 | // Get desired composite value 103 | ApplicationDataContainer roamingSettings = ApplicationData.Current.RoamingSettings; 104 | ApplicationDataCompositeValue composite = (ApplicationDataCompositeValue)roamingSettings.Values[store]; 105 | 106 | // If the store exists, check if the setting does as well 107 | composite ??= new ApplicationDataCompositeValue(); 108 | 109 | if (composite[setting] == null) 110 | { 111 | composite[setting] = defaultValue; 112 | roamingSettings.Values[store] = composite; 113 | } 114 | 115 | object value = composite[setting]; 116 | 117 | // Return the setting if type matches 118 | if (value is not T) 119 | { 120 | throw new ArgumentException("Type mismatch for \"" + setting + "\" in store \"" + store + "\". Current type is " + value.GetType()); 121 | } 122 | return (T)value; 123 | } 124 | 125 | /// 126 | /// Sets an app setting. 127 | /// 128 | /// Setting store name. 129 | /// Setting name. 130 | /// New setting value. 131 | /// If the store parameter is "Local", a local setting will be set. 132 | protected void Set(string store, string setting, T newValue) 133 | { 134 | // Try to get the setting, if types don't match, it'll throw an exception 135 | _ = Get(store, setting, newValue); 136 | 137 | // If store == "Local", set a local setting 138 | if (store == "Local") 139 | { 140 | // Get app settings 141 | ApplicationDataContainer localSettings = ApplicationData.Current.LocalSettings; 142 | localSettings.Values[setting] = newValue; 143 | return; 144 | } 145 | 146 | // Get desired composite value 147 | ApplicationDataContainer roamingSettings = ApplicationData.Current.RoamingSettings; 148 | ApplicationDataCompositeValue composite = (ApplicationDataCompositeValue)roamingSettings.Values[store]; 149 | 150 | // Store doesn't exist, create it 151 | composite ??= new ApplicationDataCompositeValue(); 152 | 153 | // Set the setting to the desired value 154 | composite[setting] = newValue; 155 | roamingSettings.Values[store] = composite; 156 | 157 | OnPropertyChanged(setting); 158 | } 159 | #endregion 160 | } 161 | } -------------------------------------------------------------------------------- /ViewModels/Settings/ViewModel.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.ComponentModel; 3 | using System.Runtime.CompilerServices; 4 | using System.Threading; 5 | 6 | namespace Rich_Text_Editor.ViewModels 7 | { 8 | /// 9 | /// Base ViewModel implementation, wraps a 10 | /// object for the Model-View-ViewModel pattern and contains methods 11 | /// to handle property changes. 12 | /// 13 | /// Type of the underlying model. 14 | public abstract class ViewModel : ViewModel 15 | { 16 | private Type _model; 17 | /// 18 | /// Gets or sets the underlying object. 19 | /// 20 | public Type Model 21 | { 22 | get => _model; 23 | set 24 | { 25 | if (_model == null || !_model.Equals(value)) 26 | { 27 | _model = value; 28 | 29 | // Raise the PropertyChanged event for all properties. 30 | OnPropertyChanged(string.Empty); 31 | } 32 | } 33 | } 34 | } 35 | 36 | /// 37 | /// Base ViewModel implementation, contains methods to 38 | /// handle property changes. 39 | /// 40 | public abstract class ViewModel : INotifyPropertyChanged 41 | { 42 | private readonly Dictionary PropertyChangedEvents = 43 | new Dictionary(); 44 | 45 | /// 46 | /// Occurs when a property value changes. 47 | /// 48 | public event PropertyChangedEventHandler PropertyChanged 49 | { 50 | add 51 | { 52 | PropertyChangedEvents.Add(value, SynchronizationContext.Current); 53 | } 54 | remove 55 | { 56 | PropertyChangedEvents.Remove(value); 57 | } 58 | } 59 | 60 | /// 61 | /// Notifies listeners that a property value has changed. 62 | /// 63 | /// Name of the property used to notify listeners. This 64 | /// value is optional and can be provided automatically when invoked from compilers 65 | /// that support . 66 | protected void OnPropertyChanged([CallerMemberName] string propertyName = null) 67 | { 68 | PropertyChangedEventArgs args = new PropertyChangedEventArgs(propertyName); 69 | foreach (KeyValuePair @event in PropertyChangedEvents) 70 | { 71 | if (@event.Value == null) 72 | { 73 | @event.Key.Invoke(this, args); 74 | } 75 | else 76 | { 77 | @event.Value.Post(s => @event.Key.Invoke(s, args), this); 78 | } 79 | } 80 | } 81 | 82 | /// 83 | /// Checks if a property already matches a desired value. Sets the property and 84 | /// notifies listeners only when necessary. 85 | /// 86 | /// Type of the property. 87 | /// Reference to a property with both getter and setter. 88 | /// Desired value for the property. 89 | /// Name of the property used to notify listeners. This 90 | /// value is optional and can be provided automatically when invoked from compilers that 91 | /// support CallerMemberName. 92 | /// True if the value was changed, false if the existing value matched the 93 | /// desired value. 94 | protected bool Set(ref T storage, T value, 95 | [CallerMemberName] string propertyName = null) 96 | { 97 | if (Equals(storage, value)) 98 | { 99 | return false; 100 | } 101 | 102 | storage = value; 103 | OnPropertyChanged(propertyName); 104 | return true; 105 | } 106 | } 107 | } -------------------------------------------------------------------------------- /ViewModels/WhatsNewItemViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace Rich_Text_Editor.ViewModels 8 | { 9 | public class WhatsNewItemViewModel 10 | { 11 | public string Title { get; set; } 12 | public string Icon { get; set; } 13 | public string Tag { get; set; } 14 | public string Description { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Views/HomePage.xaml: -------------------------------------------------------------------------------- 1 |  15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 32 | 33 | 41 | 47 | 48 | 49 | 50 | 77 | 78 | 79 | 80 | 88 | 89 | 90 | 91 | 96 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 116 | 117 | 118 | 122 | 123 | 124 | 125 | 126 | 130 | 131 | 132 | 133 | 134 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 162 | 163 | 164 | 165 | 166 | 167 | 168 | 169 | 170 | 171 | 175 | 176 | 177 | 182 | 183 | 184 | 185 | 186 | 187 | 188 | 189 | 193 | 194 | 198 | 203 | 204 | 205 | 210 | 211 | 212 | 213 | 214 | 215 | 216 | 217 | -------------------------------------------------------------------------------- /Views/HomePage.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using Windows.UI.Xaml.Controls; 4 | using Rich_Text_Editor.ViewModels; 5 | using Windows.Storage; 6 | using System.Collections.ObjectModel; 7 | using Windows.UI.Xaml; 8 | using Windows.UI; 9 | using Windows.UI.ViewManagement; 10 | using Windows.ApplicationModel.Core; 11 | using Windows.UI.Xaml.Media; 12 | using Windows.UI.Core; 13 | using Windows.System; 14 | using Windows.ApplicationModel.DataTransfer; 15 | 16 | namespace Rich_Text_Editor.Views 17 | { 18 | public sealed partial class HomePage : Page 19 | { 20 | private ObservableCollection list = new(); 21 | private ObservableCollection WhatsNew = new(); 22 | private WhatsNewItemViewModel SelectedItem = new() 23 | { 24 | Title = "Select an item from the sidebar", 25 | Description = "To view its details." 26 | }; 27 | private bool IsListEmpty = false; 28 | 29 | public HomePage() 30 | { 31 | InitializeComponent(); 32 | 33 | var appViewTitleBar = ApplicationView.GetForCurrentView().TitleBar; 34 | 35 | appViewTitleBar.ButtonBackgroundColor = Colors.Transparent; 36 | appViewTitleBar.ButtonInactiveBackgroundColor = Colors.Transparent; 37 | 38 | var coreTitleBar = CoreApplication.GetCurrentView().TitleBar; 39 | coreTitleBar.ExtendViewIntoTitleBar = true; 40 | UpdateTitleBarLayout(coreTitleBar); 41 | 42 | Window.Current.SetTitleBar(AppTitleBar); 43 | 44 | coreTitleBar.LayoutMetricsChanged += CoreTitleBar_LayoutMetricsChanged; 45 | coreTitleBar.IsVisibleChanged += CoreTitleBar_IsVisibleChanged; 46 | 47 | Loaded += HomePage_Loaded; 48 | } 49 | 50 | private void CoreTitleBar_LayoutMetricsChanged(CoreApplicationViewTitleBar sender, object args) 51 | { 52 | UpdateTitleBarLayout(sender); 53 | } 54 | 55 | private void CoreTitleBar_IsVisibleChanged(CoreApplicationViewTitleBar sender, object args) 56 | { 57 | AppTitleBar.Visibility = sender.IsVisible ? Visibility.Visible : Visibility.Collapsed; 58 | } 59 | 60 | // Update the TitleBar based on the inactive/active state of the app 61 | private void Current_Activated(object sender, WindowActivatedEventArgs e) 62 | { 63 | SolidColorBrush defaultForegroundBrush = (SolidColorBrush)Application.Current.Resources["TextFillColorPrimaryBrush"]; 64 | SolidColorBrush inactiveForegroundBrush = (SolidColorBrush)Application.Current.Resources["TextFillColorDisabledBrush"]; 65 | 66 | if (e.WindowActivationState == CoreWindowActivationState.Deactivated) 67 | { 68 | AppTitle.Foreground = inactiveForegroundBrush; 69 | } 70 | else 71 | { 72 | AppTitle.Foreground = defaultForegroundBrush; 73 | } 74 | } 75 | 76 | private void UpdateTitleBarLayout(CoreApplicationViewTitleBar coreTitleBar) 77 | { 78 | // Update title bar control size as needed to account for system size changes. 79 | AppTitleBar.Height = coreTitleBar.Height; 80 | 81 | // Ensure the custom title bar does not overlap window caption controls 82 | Thickness currMargin = AppTitleBar.Margin; 83 | AppTitleBar.Margin = new Thickness(currMargin.Left, currMargin.Top, coreTitleBar.SystemOverlayRightInset, currMargin.Bottom); 84 | } 85 | 86 | private async void HomePage_Loaded(object sender, RoutedEventArgs e) 87 | { 88 | list.Clear(); 89 | WhatsNew.Clear(); 90 | 91 | var mru = Windows.Storage.AccessCache.StorageApplicationPermissions.MostRecentlyUsedList; 92 | 93 | foreach (Windows.Storage.AccessCache.AccessListEntry entry in mru.Entries) 94 | { 95 | StorageFile file = await mru.GetFileAsync(entry.Token); 96 | 97 | list.Add(new() 98 | { 99 | Name = file.Name, 100 | OriginalFile = file, 101 | Path = file.Path, 102 | Token = entry.Token 103 | }); 104 | } 105 | 106 | WhatsNew.Add(new() 107 | { 108 | Title = "Tabs", 109 | Icon = "\uF7ED", 110 | Tag = "Tabs", 111 | Description = $"Now you can open multiple text documents." 112 | }); 113 | 114 | WhatsNew.Add(new() 115 | { 116 | Title = "Image resizing", 117 | Icon = "\uEE71", 118 | Tag = "ImageResizing", 119 | Description = $"Resizing images is now easier than ever, open an image, adjust the height/width, set a tag and insert it into your document." 120 | }); 121 | 122 | IsListEmpty = list.Count <= 0; 123 | } 124 | 125 | private void BackButton_Click(object sender, RoutedEventArgs e) 126 | { 127 | if (Window.Current.Content is Frame rootFrame && rootFrame.CanGoBack) 128 | rootFrame.GoBack(); 129 | } 130 | 131 | private async void OpenFileLocation_Click(object sender, RoutedEventArgs e) 132 | { 133 | RecentlyUsedViewModel item = (sender as MenuFlyoutItem).Tag as RecentlyUsedViewModel; 134 | 135 | try 136 | { 137 | await Launcher.LaunchFolderPathAsync(item.Path.Replace(item.Name, "")); 138 | } 139 | catch (Exception e1) 140 | { 141 | System.Diagnostics.Debug.WriteLine($"An error occured while opening the folder, {e1.Message}"); 142 | } 143 | } 144 | 145 | private void RemoveItem_Click(object sender, RoutedEventArgs e) 146 | { 147 | RecentlyUsedViewModel item = (sender as MenuFlyoutItem).Tag as RecentlyUsedViewModel; 148 | Windows.Storage.AccessCache.StorageApplicationPermissions.MostRecentlyUsedList.Remove(item.Token); 149 | list.Remove(item); 150 | 151 | IsListEmpty = list.Count <= 0; 152 | } 153 | 154 | private void CopyLocation_Click(object sender, RoutedEventArgs e) 155 | { 156 | var dataPackage = new DataPackage(); 157 | dataPackage.SetText((sender as MenuFlyoutItem).Tag as string); 158 | Clipboard.SetContent(dataPackage); 159 | } 160 | 161 | private void ListView_SelectionChanged(object sender, SelectionChangedEventArgs e) 162 | { 163 | if (e.AddedItems[0] is WhatsNewItemViewModel item) 164 | { 165 | SelectedItem = item; 166 | 167 | FontIconWhatsNew.Glyph = item.Icon; 168 | TitleWhatsNew.Text = item.Title; 169 | DescWhatsNew.Text = item.Description; 170 | } 171 | } 172 | } 173 | } 174 | -------------------------------------------------------------------------------- /Views/Settings/SettingsPage.xaml: -------------------------------------------------------------------------------- 1 |  16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 33 | 34 | 42 | 48 | 49 | 50 | 51 | 77 | 78 | 79 | 83 | 88 | 89 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 110 | 111 | 112 | 113 | No wrap 114 | Wrap 115 | Wrap whole words 116 | 117 | 118 | 119 | 120 | 125 | 126 | 127 | 128 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | -------------------------------------------------------------------------------- /Views/Settings/SettingsPage.xaml.cs: -------------------------------------------------------------------------------- 1 | using Windows.ApplicationModel.Core; 2 | using Windows.UI; 3 | using Windows.UI.Core; 4 | using Windows.UI.ViewManagement; 5 | using Windows.UI.Xaml; 6 | using Windows.UI.Xaml.Controls; 7 | using Windows.UI.Xaml.Media; 8 | 9 | namespace Rich_Text_Editor.Views.Settings 10 | { 11 | public sealed partial class SettingsPage : Page 12 | { 13 | public SettingsPage() 14 | { 15 | InitializeComponent(); 16 | 17 | var appViewTitleBar = ApplicationView.GetForCurrentView().TitleBar; 18 | 19 | appViewTitleBar.ButtonBackgroundColor = Colors.Transparent; 20 | appViewTitleBar.ButtonInactiveBackgroundColor = Colors.Transparent; 21 | 22 | var coreTitleBar = CoreApplication.GetCurrentView().TitleBar; 23 | coreTitleBar.ExtendViewIntoTitleBar = true; 24 | UpdateTitleBarLayout(coreTitleBar); 25 | 26 | Window.Current.SetTitleBar(AppTitleBar); 27 | 28 | coreTitleBar.LayoutMetricsChanged += CoreTitleBar_LayoutMetricsChanged; 29 | coreTitleBar.IsVisibleChanged += CoreTitleBar_IsVisibleChanged; 30 | } 31 | 32 | private void CoreTitleBar_LayoutMetricsChanged(CoreApplicationViewTitleBar sender, object args) 33 | => UpdateTitleBarLayout(sender); 34 | 35 | private void CoreTitleBar_IsVisibleChanged(CoreApplicationViewTitleBar sender, object args) 36 | => AppTitleBar.Visibility = sender.IsVisible ? Visibility.Visible : Visibility.Collapsed; 37 | 38 | // Update the TitleBar based on the inactive/active state of the app 39 | private void Current_Activated(object sender, WindowActivatedEventArgs e) 40 | { 41 | SolidColorBrush defaultForegroundBrush = (SolidColorBrush)Application.Current.Resources["TextFillColorPrimaryBrush"]; 42 | SolidColorBrush inactiveForegroundBrush = (SolidColorBrush)Application.Current.Resources["TextFillColorDisabledBrush"]; 43 | 44 | AppTitle.Foreground = e.WindowActivationState == CoreWindowActivationState.Deactivated ? inactiveForegroundBrush : defaultForegroundBrush; 45 | } 46 | 47 | private void UpdateTitleBarLayout(CoreApplicationViewTitleBar coreTitleBar) 48 | { 49 | // Update title bar control size as needed to account for system size changes. 50 | AppTitleBar.Height = coreTitleBar.Height; 51 | 52 | // Ensure the custom title bar does not overlap window caption controls 53 | Thickness currMargin = AppTitleBar.Margin; 54 | AppTitleBar.Margin = new Thickness(currMargin.Left, currMargin.Top, coreTitleBar.SystemOverlayRightInset, currMargin.Bottom); 55 | } 56 | 57 | private void BackButton_Click(object sender, RoutedEventArgs e) 58 | { 59 | if (Window.Current.Content is Frame rootFrame && rootFrame.CanGoBack) 60 | rootFrame.GoBack(); 61 | } 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /privacy-policy.md: -------------------------------------------------------------------------------- 1 | Last updated 1/2/2022 2 | 3 | #### INTRODUCTION 4 | 5 | itsWindows11 (“we” or “us” or “our”) respects the privacy of our users (“user” or “you”). This Privacy Policy explains how we collect, use, disclose, and safeguard your information when you visit our [website](itswin11.netlify.app), including any other media form, media channel, mobile website, or mobile application related or connected thereto (collectively, the “App”). Please read this privacy policy carefully. If you do not agree with the terms of this privacy policy, please do not download the app. 6 | 7 | We reserve the right to make changes to this Privacy Policy at any time and for any reason. We will alert you about any changes by updating the “Last Updated” date of this Privacy Policy. Any changes or modifications will be effective immediately upon posting the updated Privacy Policy on the Site, and you waive the right to receive specific notice of each such change or modification. 8 | 9 | You are encouraged to periodically review this Privacy Policy to stay informed of updates. You will be deemed to have been made aware of, will be subject to, and will be deemed to have accepted the changes in any revised Privacy Policy by your continued use of the Site after the date such revised Privacy Policy is posted. 10 | 11 | ##### Third-Party Data 12 | 13 | Information from third parties, such as personal information or network friends, if you connect your account to the third party and grant the Site permission to access this information. 14 | 15 | Having accurate information about you permits us to provide you with a smooth, efficient, and customized experience. Specifically, we may use information collected about you via the app to: 16 | 17 | Assist law enforcement and respond to subpoena. 18 | Compile anonymous statistical data and analysis for use internally or with third parties. 19 | Notify you of updates to the app. 20 | Offer new products, services and/or recommendations to you. 21 | Perform other business activities as needed. 22 | Prevent fraudulent transactions, monitor against theft, and protect against criminal activity. 23 | Request feedback and contact you about your use of the app. 24 | Resolve disputes and troubleshoot problems. 25 | Respond to product and customer service requests. 26 | 27 | #### DISCLOSURE OF YOUR INFORMATION 28 | 29 | We may share information we have collected about you in certain situations. Your information may be disclosed as follows: 30 | 31 | ##### By Law or to Protect Rights 32 | 33 | If we believe the release of information about you is necessary to respond to legal process, to investigate or remedy potential violations of our policies, or to protect the rights, property, and safety of others, we may share your information as permitted or required by any applicable law, rule, or regulation. This includes exchanging information with other entities for fraud protection and credit risk reduction. 34 | 35 | ##### Third-Party Service Providers 36 | 37 | We may share your information with third parties that perform services for us or on our behalf, including payment processing, data analysis, email delivery, hosting services, customer service, and marketing assistance. 38 | 39 | ##### Marketing Communications 40 | 41 | With your consent, or with an opportunity for you to withdraw consent, we may share your information with third parties for marketing purposes, as permitted by law. 42 | 43 | ##### Affiliates 44 | 45 | We may share your information with our affiliates, in which case we will require those affiliates to honor this Privacy Policy. Affiliates include our parent company and any subsidiaries, joint venture partners or other companies that we control or that are under common control with us. 46 | 47 | ##### Business Partners 48 | 49 | We may share your information with our business partners to offer you certain products, services or promotions. 50 | 51 | ##### Other Third Parties 52 | 53 | We may share your information with advertisers and investors for the purpose of conducting general business analysis. We may also share your information with such third parties for marketing purposes, as permitted by law. 54 | 55 | ##### Sale or Bankruptcy 56 | 57 | If we reorganize or sell all or a portion of our assets, undergo a merger, or are acquired by another entity, we may transfer your information to the successor entity. If we go out of business or enter bankruptcy, your information would be an asset transferred or acquired by a third party. You acknowledge that such transfers may occur and that the transferee may decline honor commitments we made in this Privacy Policy. 58 | 59 | We are not responsible for the actions of third parties with whom you share personal or sensitive data, and we have no authority to manage or control third-party solicitations. If you no longer wish to receive correspondence, emails or other communications from third parties, you are responsible for contacting the third party directly. 60 | 61 | #### TRACKING TECHNOLOGIES 62 | 63 | You should be aware that getting a new computer, installing a new browser, upgrading an existing browser, or erasing or otherwise altering your browser’s cookies files may also clear certain opt-out cookies, plug-ins, or settings. 64 | 65 | #### THIRD-PARTY WEBSITES 66 | 67 | The app may contain links to third-party websites and applications of interest, including advertisements and external services, that are not affiliated with us. Once you have used these links to leave the app, any information you provide to these third parties is not covered by this Privacy Policy, and we cannot guarantee the safety and privacy of your information. Before visiting and providing any information to any third-party websites, you should inform yourself of the privacy policies and practices (if any) of the third party responsible for that website, and should take those steps necessary to, in your discretion, protect the privacy of your information. We are not responsible for the content or privacy and security practices and policies of any third parties, including other sites, services or applications that may be linked to or from the app. 68 | 69 | #### SECURITY OF YOUR INFORMATION 70 | 71 | We use administrative, technical, and physical security measures to help protect your personal information. While we have taken reasonable steps to secure the personal information you provide to us, please be aware that despite our efforts, no security measures are perfect or impenetrable, and no method of data transmission can be guaranteed against any interception or other type of misuse. Any information disclosed online is vulnerable to interception and misuse by unauthorized parties. Therefore, we cannot guarantee complete security if you provide personal information. 72 | 73 | #### POLICY FOR CHILDREN 74 | 75 | We do not knowingly solicit information from or market to children under the age of 13. If you become aware of any data we have collected from children under age 13, please contact us using the contact information provided below. 76 | CONTACT US 77 | 78 | If you have questions or comments about this Privacy Policy, please contact us at itswin11@outlook.com 79 | --------------------------------------------------------------------------------