├── .editorconfig ├── .gitignore ├── .idea ├── codeStyles │ └── Project.xml ├── google-java-format.xml ├── gradle.xml ├── inspectionProfiles │ └── Project_Default.xml ├── misc.xml ├── runConfigurations.xml └── vcs.xml ├── LICENSE ├── README.md ├── app ├── .gitignore ├── build.gradle ├── libs │ ├── antlr-2.7.4.jar │ ├── chardet-1.0.jar │ ├── cpdetector_1.0.10.jar │ ├── fastscroll_v1.2_20160903.jar │ ├── jargs-1.0.jar │ ├── jtidy-r938.jar │ └── pinyin4j-2.5.0.jar ├── proguard-rules.pro ├── release │ └── output.json └── src │ ├── androidTest │ └── java │ │ └── xyz │ │ └── tcreopargh │ │ └── textconverter │ │ └── ExampleInstrumentedTest.java │ ├── main │ ├── AndroidManifest.xml │ ├── assets │ │ ├── help_document_en.html │ │ ├── help_document_zh_simplified.html │ │ └── help_document_zh_traditional.html │ ├── ic_launcher-web.png │ ├── ic_shortcut_lock-web.png │ ├── ic_shortcut_more-web.png │ ├── ic_shortcut_replace-web.png │ ├── ic_shortcut_search-web.png │ ├── ic_shortcut_shuffle-web.png │ ├── java │ │ └── xyz │ │ │ └── tcreopargh │ │ │ └── textconverter │ │ │ ├── AESUtils.java │ │ │ ├── AboutActivity.java │ │ │ ├── AesCbcWithIntegrity.java │ │ │ ├── AsciiUtil.java │ │ │ ├── CustomRegex.java │ │ │ ├── CustomRegexActivity.java │ │ │ ├── ListItems.java │ │ │ ├── MainActivity.java │ │ │ ├── MarkdownPreviewActivity.java │ │ │ ├── PinyinComparator.java │ │ │ ├── Range.java │ │ │ ├── RegexAdapter.java │ │ │ ├── SettingsActivity.java │ │ │ ├── SettingsFragment.java │ │ │ ├── TextConverter.java │ │ │ ├── TextEditActivity.java │ │ │ ├── ToolboxAdapter.java │ │ │ ├── UnicodeUtils.java │ │ │ └── ViewHelpActivity.java │ └── res │ │ ├── drawable-v24 │ │ └── ic_launcher_foreground.xml │ │ ├── drawable-xxhdpi │ │ ├── banner_new.png │ │ ├── ic_launcher.png │ │ ├── ic_launcher_background.xml │ │ ├── ic_launcher_foreground.xml │ │ ├── ic_launcher_round.png │ │ ├── ic_lock.xml │ │ ├── nav_background.webp │ │ └── shortcut_bg.xml │ │ ├── drawable │ │ ├── baselinedescription.xml │ │ ├── baselinefindreplace.xml │ │ ├── baselinehelpoutline.xml │ │ ├── baselinehelpoutline_white.xml │ │ ├── baselinehelpoutline_white_small.xml │ │ ├── baselinesearch.xml │ │ ├── baselinesettings.xml │ │ ├── baselinesettings_white.xml │ │ ├── baselineshuffle.xml │ │ ├── button_bg.xml │ │ ├── ic_account_balance_black_24dp.xml │ │ ├── ic_add_white_24dp.xml │ │ ├── ic_arrow_back_white_24dp.xml │ │ ├── ic_arrow_forward_white_24dp.xml │ │ ├── ic_attach_money_black_24dp.xml │ │ ├── ic_attach_money_white_48dp.xml │ │ ├── ic_check_black_24dp.xml │ │ ├── ic_code_white_24dp.xml │ │ ├── ic_code_white_48dp.xml │ │ ├── ic_content_copy_black_24dp.xml │ │ ├── ic_content_copy_white_24dp.xml │ │ ├── ic_custom.xml │ │ ├── ic_delete_black_24dp.xml │ │ ├── ic_format_list_numbered_white_24dp.xml │ │ ├── ic_info.xml │ │ ├── ic_info_black_24dp.xml │ │ ├── ic_keyboard_arrow_up_white_24dp.xml │ │ ├── ic_launcher_background.xml │ │ ├── ic_lock.xml │ │ ├── ic_lock_white.xml │ │ ├── ic_menu_camera.xml │ │ ├── ic_menu_gallery.xml │ │ ├── ic_menu_manage.xml │ │ ├── ic_menu_send.xml │ │ ├── ic_menu_share.xml │ │ ├── ic_menu_slideshow.xml │ │ ├── ic_mode_edit_white_24dp.xml │ │ ├── ic_notifications_black_24dp.xml │ │ ├── ic_public_white_24dp.xml │ │ ├── ic_redo_white_24dp.xml │ │ ├── ic_refresh_black_24dp.xml │ │ ├── ic_save_white_48dp.xml │ │ ├── ic_settings_backup_restore_white_24dp.xml │ │ ├── ic_settings_backup_restore_white_48dp.xml │ │ ├── ic_shuffle_white_48dp.xml │ │ ├── ic_star_border_white_24dp.xml │ │ ├── ic_stars_black_24dp.xml │ │ ├── ic_sync_black_24dp.xml │ │ ├── ic_text_fields_white_48dp.xml │ │ ├── ic_toolbox.xml │ │ ├── ic_undo_white_24dp.xml │ │ ├── ic_visibility_black_24dp.xml │ │ ├── lock_open.xml │ │ ├── nav_bg_selector.xml │ │ ├── nav_text_selector.xml │ │ ├── nav_tint_selector.xml │ │ ├── outline_more_horiz_24px.xml │ │ ├── outline_more_horiz_white.xml │ │ ├── rounded_button.xml │ │ ├── shortcut_bg.xml │ │ ├── shortcut_more_foreground.xml │ │ └── touch_bg_ripple.xml │ │ ├── layout │ │ ├── about_toolbar.xml │ │ ├── activity_about.xml │ │ ├── activity_custom_regex.xml │ │ ├── activity_main.xml │ │ ├── activity_markdown_preview.xml │ │ ├── activity_settings.xml │ │ ├── activity_text_edit.xml │ │ ├── activity_view_help.xml │ │ ├── add_regex_dialog.xml │ │ ├── app_bar_main.xml │ │ ├── content_custom_regex.xml │ │ ├── content_main.xml │ │ ├── dialog_header.xml │ │ ├── dialog_set_quantity.xml │ │ ├── list_layout.xml │ │ ├── nav_header_main.xml │ │ ├── random_string_dialog.xml │ │ ├── regex_item.xml │ │ ├── text_encrypt_layout.xml │ │ ├── text_more_layout.xml │ │ ├── text_replace_layout.xml │ │ ├── text_search_layout.xml │ │ └── text_shuffle_layout.xml │ │ ├── menu │ │ ├── activity_main_drawer.xml │ │ ├── edit_mode_toolbar.xml │ │ └── main.xml │ │ ├── mipmap-anydpi-v26 │ │ ├── ic_launcher.xml │ │ ├── ic_launcher_round.xml │ │ ├── ic_shortcut_lock.xml │ │ ├── ic_shortcut_lock_round.xml │ │ ├── ic_shortcut_more.xml │ │ ├── ic_shortcut_more_round.xml │ │ ├── ic_shortcut_replace.xml │ │ ├── ic_shortcut_replace_round.xml │ │ ├── ic_shortcut_search.xml │ │ ├── ic_shortcut_search_round.xml │ │ ├── ic_shortcut_shuffle.xml │ │ └── ic_shortcut_shuffle_round.xml │ │ ├── mipmap-hdpi │ │ ├── ic_launcher.png │ │ ├── ic_launcher_foreground.png │ │ ├── ic_launcher_round.png │ │ ├── ic_shortcut_foreground.png │ │ ├── ic_shortcut_foreground_lock.png │ │ ├── ic_shortcut_foreground_more.png │ │ ├── ic_shortcut_foreground_replace.png │ │ ├── ic_shortcut_foreground_search.png │ │ ├── ic_shortcut_foreground_shuffle.png │ │ ├── ic_shortcut_lock.png │ │ ├── ic_shortcut_lock_round.png │ │ ├── ic_shortcut_more.png │ │ ├── ic_shortcut_more_round.png │ │ ├── ic_shortcut_replace.png │ │ ├── ic_shortcut_replace_round.png │ │ ├── ic_shortcut_search.png │ │ ├── ic_shortcut_search_round.png │ │ ├── ic_shortcut_shuffle.png │ │ └── ic_shortcut_shuffle_round.png │ │ ├── mipmap-mdpi │ │ ├── ic_launcher.png │ │ ├── ic_launcher_foreground.png │ │ ├── ic_launcher_round.png │ │ ├── ic_shortcut_foreground.png │ │ ├── ic_shortcut_foreground_lock.png │ │ ├── ic_shortcut_foreground_more.png │ │ ├── ic_shortcut_foreground_replace.png │ │ ├── ic_shortcut_foreground_search.png │ │ ├── ic_shortcut_foreground_shuffle.png │ │ ├── ic_shortcut_lock.png │ │ ├── ic_shortcut_lock_round.png │ │ ├── ic_shortcut_more.png │ │ ├── ic_shortcut_more_round.png │ │ ├── ic_shortcut_replace.png │ │ ├── ic_shortcut_replace_round.png │ │ ├── ic_shortcut_search.png │ │ ├── ic_shortcut_search_round.png │ │ ├── ic_shortcut_shuffle.png │ │ └── ic_shortcut_shuffle_round.png │ │ ├── mipmap-xhdpi │ │ ├── ic_launcher.png │ │ ├── ic_launcher_foreground.png │ │ ├── ic_launcher_round.png │ │ ├── ic_shortcut_foreground.png │ │ ├── ic_shortcut_foreground_lock.png │ │ ├── ic_shortcut_foreground_more.png │ │ ├── ic_shortcut_foreground_replace.png │ │ ├── ic_shortcut_foreground_search.png │ │ ├── ic_shortcut_foreground_shuffle.png │ │ ├── ic_shortcut_lock.png │ │ ├── ic_shortcut_lock_round.png │ │ ├── ic_shortcut_more.png │ │ ├── ic_shortcut_more_round.png │ │ ├── ic_shortcut_replace.png │ │ ├── ic_shortcut_replace_round.png │ │ ├── ic_shortcut_search.png │ │ ├── ic_shortcut_search_round.png │ │ ├── ic_shortcut_shuffle.png │ │ └── ic_shortcut_shuffle_round.png │ │ ├── mipmap-xxhdpi │ │ ├── ic_launcher.png │ │ ├── ic_launcher_foreground.png │ │ ├── ic_launcher_round.png │ │ ├── ic_shortcut_foreground.png │ │ ├── ic_shortcut_foreground_lock.png │ │ ├── ic_shortcut_foreground_more.png │ │ ├── ic_shortcut_foreground_replace.png │ │ ├── ic_shortcut_foreground_search.png │ │ ├── ic_shortcut_foreground_shuffle.png │ │ ├── ic_shortcut_lock.png │ │ ├── ic_shortcut_lock_round.png │ │ ├── ic_shortcut_more.png │ │ ├── ic_shortcut_more_round.png │ │ ├── ic_shortcut_replace.png │ │ ├── ic_shortcut_replace_round.png │ │ ├── ic_shortcut_search.png │ │ ├── ic_shortcut_search_round.png │ │ ├── ic_shortcut_shuffle.png │ │ └── ic_shortcut_shuffle_round.png │ │ ├── mipmap-xxxhdpi │ │ ├── ic_launcher.png │ │ ├── ic_launcher_foreground.png │ │ ├── ic_launcher_round.png │ │ ├── ic_shortcut_foreground.png │ │ ├── ic_shortcut_foreground_lock.png │ │ ├── ic_shortcut_foreground_more.png │ │ ├── ic_shortcut_foreground_replace.png │ │ ├── ic_shortcut_foreground_search.png │ │ ├── ic_shortcut_foreground_shuffle.png │ │ ├── ic_shortcut_lock.png │ │ ├── ic_shortcut_lock_round.png │ │ ├── ic_shortcut_more.png │ │ ├── ic_shortcut_more_round.png │ │ ├── ic_shortcut_replace.png │ │ ├── ic_shortcut_replace_round.png │ │ ├── ic_shortcut_search.png │ │ ├── ic_shortcut_search_round.png │ │ ├── ic_shortcut_shuffle.png │ │ └── ic_shortcut_shuffle_round.png │ │ ├── values-en │ │ └── strings.xml │ │ ├── values-v21 │ │ └── styles.xml │ │ ├── values-zh-rHK │ │ └── strings.xml │ │ ├── values-zh-rTW │ │ └── strings.xml │ │ ├── values-zh │ │ └── strings.xml │ │ ├── values │ │ ├── arrays.xml │ │ ├── colors.xml │ │ ├── dimens.xml │ │ ├── ic_launcher_background.xml │ │ ├── ic_shortcut_background.xml │ │ ├── strings.xml │ │ └── styles.xml │ │ ├── xml-v25 │ │ └── shortcuts.xml │ │ └── xml │ │ ├── app_preferences.xml │ │ ├── backup_descriptor.xml │ │ ├── pref_data_sync.xml │ │ ├── pref_general.xml │ │ └── pref_notification.xml │ └── test │ └── java │ └── xyz │ └── tcreopargh │ └── textconverter │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle /.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | charset=utf-8 3 | end_of_line=crlf 4 | insert_final_newline=false 5 | indent_style=space 6 | indent_size=4 7 | 8 | [*.json] 9 | indent_style=space 10 | indent_size=2 11 | 12 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/caches/build_file_checksums.ser 5 | /.idea/libraries 6 | /.idea/modules.xml 7 | /.idea/workspace.xml 8 | .DS_Store 9 | /build 10 | /captures 11 | .externalNativeBuild 12 | -------------------------------------------------------------------------------- /.idea/codeStyles/Project.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 15 | 16 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /.idea/google-java-format.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | -------------------------------------------------------------------------------- /.idea/gradle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 14 | 15 | -------------------------------------------------------------------------------- /.idea/inspectionProfiles/Project_Default.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 36 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 14 | -------------------------------------------------------------------------------- /.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # 文本转换 2 | ### Text-Converter-Android 3 | ## 好用轻便的文本高级转换工具 4 | #### 此App支持根据正则表达式替换、删除、搜索文本,并且附带一些其他实用功能。 5 | #### 目前已经实现的功能有: 6 | 7 | * 字符串搜索(可选用正则表达式匹配) 8 | * 字符串替换/删除(可选用正则表达式匹配) 9 | * 文字分段、打乱、排序(如果文字是一串数字,可根据数字大小排序) 10 | * AES加解密 11 | * Java 代码格式化、JSON格式化、HTML格式化 12 | * Base64编码/解码、生成MD5摘要 13 | * 摩斯电码编码/解码 14 | * 字符串反转、分段、缩进、标号、大小写转换、批量复制 15 | * Markdown预览 16 | * 生成自定义格式的随机数、文本抽签 17 | * HTML/XML/JSON/Java/CSV/ECMAScript的转义与反转义 18 | * 转义正则表达式 19 | * 从文件读取/写入 20 | * 获取网页源代码 21 | * 计算字符串相似度 22 | * 自定义正则表达式 23 | * 生成随机字符串 24 | * 通过汉字生成拼音 25 | * 可撤销的编辑 26 | * 去除字符串两端空白字符 27 | * 附带正则表达式的参考文档(来源:OSChina) 28 | 29 | ### 如有合理建议欢迎提出,我会考虑采纳 30 | 31 | 已在酷安上架:https://www.coolapk.com/apk/xyz.tcreopargh.textconverter 32 | 33 | ``` 34 | Copyright 2019 TCreopargh 35 | ``` 36 | -------------------------------------------------------------------------------- /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 28 5 | defaultConfig { 6 | applicationId "xyz.tcreopargh.textconverter" 7 | minSdkVersion 23 8 | targetSdkVersion 28 9 | versionCode 69 10 | versionName "4.6.0" 11 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 12 | } 13 | buildTypes { 14 | release { 15 | zipAlignEnabled true 16 | minifyEnabled true 17 | shrinkResources true 18 | useProguard true 19 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' 20 | } 21 | } 22 | lintOptions { 23 | checkReleaseBuilds false 24 | abortOnError false 25 | } 26 | compileOptions { 27 | sourceCompatibility JavaVersion.VERSION_1_8 28 | targetCompatibility JavaVersion.VERSION_1_8 29 | } 30 | } 31 | 32 | configurations { 33 | all*.exclude group: 'com.google.guava', module: 'listenablefuture' 34 | } 35 | 36 | dependencies { 37 | implementation fileTree(include: ['*.jar'], dir: 'libs') 38 | implementation 'com.github.d-max:spots-dialog:1.1@aar' 39 | implementation 'org.apache.commons:commons-text:1.1' 40 | implementation 'com.github.florent37:viewtooltip:1.2.1' 41 | implementation 'com.github.didikee:AndroidDonate:0.1.0' 42 | implementation 'info.debatty:java-string-similarity:0.13' 43 | implementation 'com.android.support:recyclerview-v7:28.0.0' 44 | implementation 'com.yanzhenjie:recyclerview-swipe:1.2.1' 45 | implementation 'androidx.appcompat:appcompat:1.1.0-alpha02' 46 | implementation 'androidx.legacy:legacy-support-v4:1.0.0' 47 | implementation 'com.google.googlejavaformat:google-java-format:1.6' 48 | implementation 'com.orhanobut:dialogplus:1.11@aar' 49 | implementation 'com.google.android.material:material:1.1.0-alpha04' 50 | implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha3' 51 | implementation 'com.takwolf:morse-coder:0.0.3' 52 | implementation 'com.github.GrenderG:Toasty:1.3.1' 53 | implementation 'com.getkeepsafe.taptargetview:taptargetview:1.12.0' 54 | implementation 'com.google.code.gson:gson:2.8.5' 55 | implementation 'com.github.matecode:Snacky:1.1.4' 56 | implementation 'com.google.android.material:material:1.0.0' 57 | implementation 'com.yarolegovich:lovely-dialog:1.1.0' 58 | implementation 'com.github.dimorinny:floating-text-button:0.0.4' 59 | implementation 'com.android.support:customtabs:28.0.0' 60 | implementation 'com.scottyab:aescrypt:0.0.1' 61 | implementation 'com.github.medyo:android-about-page:1.2.4' 62 | implementation 'com.github.tiagohm.MarkdownView:library:0.19.0' 63 | implementation 'com.github.franmontiel:AttributionPresenter:1.0.1' 64 | implementation 'androidx.preference:preference:1.1.0-alpha03' 65 | //noinspection GradleDependency 66 | implementation 'com.leon:lfilepickerlibrary:1.7.0' 67 | implementation 'com.koushikdutta.ion:ion:2.2.1' 68 | implementation 'ren.qinc.edit:lib:0.0.5' 69 | testImplementation 'junit:junit:4.12' 70 | androidTestImplementation 'androidx.test:runner:1.1.1' 71 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1' 72 | implementation files('libs/pinyin4j-2.5.0.jar') 73 | implementation files('libs/fastscroll_v1.2_20160903.jar') 74 | implementation files('libs/jargs-1.0.jar') 75 | implementation files('libs/cpdetector_1.0.10.jar') 76 | implementation files('libs/chardet-1.0.jar') 77 | implementation files('libs/antlr-2.7.4.jar') 78 | implementation files('libs/jtidy-r938.jar') 79 | } 80 | -------------------------------------------------------------------------------- /app/libs/antlr-2.7.4.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/libs/antlr-2.7.4.jar -------------------------------------------------------------------------------- /app/libs/chardet-1.0.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/libs/chardet-1.0.jar -------------------------------------------------------------------------------- /app/libs/cpdetector_1.0.10.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/libs/cpdetector_1.0.10.jar -------------------------------------------------------------------------------- /app/libs/fastscroll_v1.2_20160903.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/libs/fastscroll_v1.2_20160903.jar -------------------------------------------------------------------------------- /app/libs/jargs-1.0.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/libs/jargs-1.0.jar -------------------------------------------------------------------------------- /app/libs/jtidy-r938.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/libs/jtidy-r938.jar -------------------------------------------------------------------------------- /app/libs/pinyin4j-2.5.0.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/libs/pinyin4j-2.5.0.jar -------------------------------------------------------------------------------- /app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | # 保留我们使用的四大组件,自定义的Application等等这些类不被混淆 23 | -keep public class * extends android.app.Activity 24 | -keep public class * extends android.app.Appliction 25 | -keep public class * extends android.app.Service 26 | -keep public class * extends android.content.BroadcastReceiver 27 | -keep public class * extends android.content.ContentProvider 28 | -keep public class * extends android.app.backup.BackupAgentHelper 29 | -keep public class * extends android.preference.Preference 30 | -keep public class * extends android.view.View 31 | -keep public class com.android.vending.licensing.ILicensingService 32 | 33 | # 保留support下的所有类及其内部类 34 | -keep class android.support.** {*;} 35 | -keep class androidx.** {*;} 36 | 37 | # 保留继承的 38 | -keep public class * extends android.support.v4.** 39 | -keep public class * extends android.support.v7.** 40 | -keep public class * extends android.support.annotation.** 41 | 42 | # 保留R下面的资源 43 | -keep class **.R$* {*;} 44 | 45 | # 保留本地native方法不被混淆 46 | -keepclasseswithmembernames class * { 47 | native ; 48 | } 49 | 50 | # 保留在Activity中的方法参数是view的方法, 51 | # 这样以来我们在layout中写的onClick就不会被影响 52 | -keepclassmembers class * extends android.app.Activity{ 53 | public void *(android.view.View); 54 | } 55 | 56 | # 保留枚举类不被混淆 57 | -keepclassmembers enum * { 58 | public static **[] values(); 59 | public static ** valueOf(java.lang.String); 60 | } 61 | 62 | # 保留我们自定义控件(继承自View)不被混淆 63 | -keep public class * extends android.view.View{ 64 | *** get*(); 65 | void set*(***); 66 | public (android.content.Context); 67 | public (android.content.Context, android.util.AttributeSet); 68 | public (android.content.Context, android.util.AttributeSet, int); 69 | } 70 | 71 | # 保留Parcelable序列化类不被混淆 72 | -keep class * implements android.os.Parcelable { 73 | public static final android.os.Parcelable$Creator *; 74 | } 75 | 76 | # 保留Serializable序列化的类不被混淆 77 | -keepclassmembers class * implements java.io.Serializable { 78 | static final long serialVersionUID; 79 | private static final java.io.ObjectStreamField[] serialPersistentFields; 80 | !static !transient ; 81 | !private ; 82 | !private ; 83 | private void writeObject(java.io.ObjectOutputStream); 84 | private void readObject(java.io.ObjectInputStream); 85 | java.lang.Object writeReplace(); 86 | java.lang.Object readResolve(); 87 | } 88 | 89 | # 对于带有回调函数的onXXEvent、**On*Listener的,不能被混淆 90 | -keepclassmembers class * { 91 | void *(**On*Event); 92 | void *(**On*Listener); 93 | } 94 | 95 | # webView处理,项目中没有使用到webView忽略即可 96 | -keepclassmembers class fqcn.of.javascript.interface.for.webview { 97 | public *; 98 | } 99 | -keepclassmembers class * extends android.webkit.webViewClient { 100 | public void *(android.webkit.WebView, java.lang.String, android.graphics.Bitmap); 101 | public boolean *(android.webkit.WebView, java.lang.String); 102 | } 103 | -keepclassmembers class * extends android.webkit.webViewClient { 104 | public void *(android.webkit.webView, jav.lang.String); 105 | } 106 | -keep class dmax.dialog.** { 107 | *; 108 | } 109 | 110 | -dontwarn demo.** 111 | -dontwarn com.google.** 112 | -dontwarn antlr.debug.** 113 | -dontwarn com.vladsch.** 114 | -dontwarn info.monitorenter.cpdetector.** 115 | -dontwarn org.openjdk.tools.javac.** 116 | -dontwarn org.w3c.tidy.** 117 | 118 | -keepattributes SourceFile, LineNumberTable -------------------------------------------------------------------------------- /app/release/output.json: -------------------------------------------------------------------------------- 1 | [{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":68,"versionName":"4.5.0","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}] -------------------------------------------------------------------------------- /app/src/androidTest/java/xyz/tcreopargh/textconverter/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import android.content.Context; 4 | import androidx.test.InstrumentationRegistry; 5 | import androidx.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("xyz.tcreopargh.textconverter", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 21 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 39 | 40 | 43 | 46 | 51 | 54 | 58 | 59 | 64 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /app/src/main/ic_launcher-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/ic_launcher-web.png -------------------------------------------------------------------------------- /app/src/main/ic_shortcut_lock-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/ic_shortcut_lock-web.png -------------------------------------------------------------------------------- /app/src/main/ic_shortcut_more-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/ic_shortcut_more-web.png -------------------------------------------------------------------------------- /app/src/main/ic_shortcut_replace-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/ic_shortcut_replace-web.png -------------------------------------------------------------------------------- /app/src/main/ic_shortcut_search-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/ic_shortcut_search-web.png -------------------------------------------------------------------------------- /app/src/main/ic_shortcut_shuffle-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/ic_shortcut_shuffle-web.png -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/AESUtils.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import java.io.UnsupportedEncodingException; 4 | import java.security.GeneralSecurityException; 5 | 6 | /** Created by lu on 2017/11/10 19:34 */ 7 | public class AESUtils { 8 | 9 | /** 10 | * 生成一个key。该key用于加密明文与解密密文 11 | * 12 | * @param password 口令 13 | * @param salt 盐值(密码学中的“颜值”,这玩意黑黑的) 14 | * @return 密钥串 15 | */ 16 | public static String generateKey(String password, String salt) { 17 | try { 18 | AesCbcWithIntegrity.SecretKeys key = 19 | AesCbcWithIntegrity.generateKeyFromPassword(password, salt); 20 | if (key != null) { 21 | return key.toString(); 22 | } 23 | } catch (GeneralSecurityException e) { 24 | e.printStackTrace(); 25 | } 26 | 27 | return null; 28 | } 29 | 30 | public static String getEnString(String clearText, String keyStr) { 31 | return getEnString(clearText, keyStr, "utf-8"); 32 | } 33 | 34 | /** 35 | * aes字符串加密 36 | * 37 | * @param clearText 待加密的明文 38 | * @param keyStr 密钥串 39 | * @param charset 字符串编码,utf-8,gbk等 40 | * @return 加密String(base64Iv And Cipher text) 41 | */ 42 | public static String getEnString(String clearText, String keyStr, String charset) { 43 | try { 44 | AesCbcWithIntegrity.SecretKeys key = AesCbcWithIntegrity.keys(keyStr); 45 | AesCbcWithIntegrity.CipherTextIvMac cipherTextIvMac = 46 | AesCbcWithIntegrity.encrypt(clearText, key, charset); 47 | return cipherTextIvMac.toString(); 48 | } catch (UnsupportedEncodingException e) { 49 | e.printStackTrace(); 50 | } catch (GeneralSecurityException e) { 51 | return "加密失败!错误信息" + e.toString(); 52 | } 53 | return null; 54 | } 55 | 56 | public static String getDeString(String cipherText, String keyStr) { 57 | return getDeString(cipherText, keyStr, "utf-8"); 58 | } 59 | 60 | /** 61 | * aes解密 62 | * 63 | * @param cipherText 已使用aes加密的密文(base64Iv And Cipher text) 64 | * @param keyStr 密钥串 65 | * @param charset 字符串编码,utf-8,gbk等 66 | * @return 解密结果,明文 67 | */ 68 | public static String getDeString(String cipherText, String keyStr, String charset) { 69 | try { 70 | AesCbcWithIntegrity.SecretKeys key = AesCbcWithIntegrity.keys(keyStr); 71 | AesCbcWithIntegrity.CipherTextIvMac cipherTextIvMac = 72 | new AesCbcWithIntegrity.CipherTextIvMac(cipherText); 73 | return AesCbcWithIntegrity.decryptString(cipherTextIvMac, key, charset); 74 | } catch (UnsupportedEncodingException e) { 75 | e.printStackTrace(); 76 | } catch (GeneralSecurityException e) { 77 | return "解密失败,可能是密码错误或输入了不正确的密文!"; 78 | } 79 | return null; 80 | } 81 | } 82 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/AsciiUtil.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | /** 4 | * @author codecraft 5 | * @link https://segmentfault.com/a/1190000010841143 6 | */ 7 | public class AsciiUtil { 8 | 9 | public static final char SBC_SPACE = 12288; // 全角空格 12288 10 | 11 | public static final char DBC_SPACE = 32; //半角空格 32 12 | 13 | // ASCII character 33-126 <-> unicode 65281-65374 14 | public static final char ASCII_START = 33; 15 | 16 | public static final char ASCII_END = 126; 17 | 18 | public static final char UNICODE_START = 65281; 19 | 20 | public static final char UNICODE_END = 65374; 21 | 22 | public static final char DBC_SBC_STEP = 65248; // 全角半角转换间隔 23 | 24 | public static char sbc2dbc(char src) { 25 | if (src == SBC_SPACE) { 26 | return DBC_SPACE; 27 | } 28 | 29 | if (src >= UNICODE_START && src <= UNICODE_END) { 30 | return (char) (src - DBC_SBC_STEP); 31 | } 32 | 33 | return src; 34 | } 35 | 36 | /** 37 | * Convert from SBC case to DBC case 38 | * 39 | * @return DBC case 40 | */ 41 | public static String sbc2dbcCase(String src) { 42 | if (src == null) { 43 | return null; 44 | } 45 | char[] c = src.toCharArray(); 46 | for (int i = 0; i < c.length; i++) { 47 | c[i] = sbc2dbc(c[i]); 48 | } 49 | return new String(c); 50 | } 51 | 52 | public static char dbc2sbc(char src) { 53 | if (src == DBC_SPACE) { 54 | return SBC_SPACE; 55 | } 56 | if (src <= ASCII_END && src != '\n') { 57 | return (char) (src + DBC_SBC_STEP); 58 | } 59 | return src; 60 | } 61 | 62 | /** 63 | * Convert from DBC case to SBC case. 64 | * 65 | * @return SBC case string 66 | */ 67 | public static String dbc2sbcCase(String src) { 68 | if (src == null) { 69 | return null; 70 | } 71 | 72 | char[] c = src.toCharArray(); 73 | for (int i = 0; i < c.length; i++) { 74 | c[i] = dbc2sbc(c[i]); 75 | } 76 | 77 | return new String(c); 78 | } 79 | } -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/CustomRegex.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import androidx.annotation.NonNull; 4 | 5 | public class CustomRegex { 6 | 7 | public static final String LABEL_KEY = "regex_label_"; 8 | public static final String REGEX_KEY = "regex_value_"; 9 | public static final String SIZE_KEY = "regex_size"; 10 | 11 | private String label; 12 | private String regex; 13 | 14 | public CustomRegex(String label, String regex) { 15 | this.label = label; 16 | this.regex = regex; 17 | } 18 | 19 | @NonNull 20 | @Override 21 | public String toString() { 22 | return label + ":" + regex; 23 | } 24 | 25 | public String getLabel() { 26 | return label; 27 | } 28 | 29 | public String getRegex() { 30 | return regex; 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/ListItems.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | public class ListItems { 4 | private String label; 5 | private String subtitle; 6 | 7 | public ListItems(String label, String subtitle) { 8 | this.label = label; 9 | this.subtitle = subtitle; 10 | } 11 | 12 | public String getLabel() { 13 | return label; 14 | } 15 | 16 | public String getSubtitle() { 17 | return subtitle; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/MarkdownPreviewActivity.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import android.os.Bundle; 4 | import android.view.MenuItem; 5 | import androidx.appcompat.app.AppCompatActivity; 6 | import br.tiagohm.markdownview.MarkdownView; 7 | import br.tiagohm.markdownview.css.styles.Github; 8 | import java.util.Objects; 9 | 10 | public class MarkdownPreviewActivity extends AppCompatActivity { 11 | 12 | @Override 13 | protected void onCreate(Bundle savedInstanceState) { 14 | super.onCreate(savedInstanceState); 15 | setContentView(R.layout.activity_markdown_preview); 16 | Objects.requireNonNull(getSupportActionBar()).setDisplayHomeAsUpEnabled(true); 17 | MarkdownView markdownView = findViewById(R.id.markdownView); 18 | markdownView 19 | .addStyleSheet(new Github()) 20 | .loadMarkdown(Objects.requireNonNull(getIntent().getStringExtra("markdownText"))); 21 | setTitle(R.string.markdown_preview); 22 | } 23 | 24 | public void returnHome() { 25 | finish(); 26 | } 27 | 28 | 29 | @Override 30 | public boolean onOptionsItemSelected(MenuItem item) { 31 | switch (item.getItemId()) { 32 | case android.R.id.home: 33 | returnHome(); 34 | break; 35 | default: 36 | } 37 | return true; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/PinyinComparator.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import net.sourceforge.pinyin4j.PinyinHelper; 4 | 5 | import java.util.Comparator; 6 | 7 | public class PinyinComparator implements Comparator { 8 | /* 9 | public int compare(Object o1, Object o2) { 10 | if (((String) o1).isEmpty()) { 11 | return 1; 12 | } 13 | if (((String) o2).isEmpty()) { 14 | return -1; 15 | } 16 | char c1 = ((String) o1).charAt(0); 17 | char c2 = ((String) o2).charAt(0); 18 | return concatPinyinStringArray( 19 | PinyinHelper.toHanyuPinyinStringArray(c1)).compareTo( 20 | concatPinyinStringArray(PinyinHelper 21 | .toHanyuPinyinStringArray(c2))); 22 | } 23 | */ 24 | // Code inferred from: https://he7ning3.iteye.com/blog/2287384 25 | @Override 26 | public int compare(String o1, String o2) { 27 | for (int i = 0; i < o1.length() && i < o2.length(); i++) { 28 | // 逐个获取字母 29 | char codePoint1 = o1.charAt(i); 30 | char codePoint2 = o2.charAt(i); 31 | // 确定字符是否在增补字符范围内,在范围内则跳过(确定指定字符是否为Unicode空白字符) 32 | if (Character.isSupplementaryCodePoint(codePoint1) 33 | || Character.isSupplementaryCodePoint(codePoint2)) { 34 | // 如果不相等则返回比较结果 35 | if (codePoint1 != codePoint2) { 36 | return codePoint1 - codePoint2; 37 | } else { // 相等则比较下一个 38 | continue; 39 | } 40 | } 41 | // 将汉字转换为拼音,不是汉子则为NULL 42 | String pinyin1 = pinyin(codePoint1); 43 | String pinyin2 = pinyin(codePoint2); 44 | // 不为汉字则与原英文比较 45 | if (pinyin1 == null) { 46 | pinyin1 = (codePoint1 + ""); 47 | } 48 | if (pinyin2 == null) { 49 | pinyin2 = (codePoint2 + ""); 50 | } 51 | // 忽略大小写比较 52 | if (!pinyin1.toLowerCase().equals(pinyin2.toLowerCase())) { 53 | return pinyin1.toLowerCase().compareTo(pinyin2.toLowerCase()); 54 | } else { 55 | // 不忽略大小写比较 56 | if (!pinyin1.equals(pinyin2)) { 57 | return pinyin1.compareTo(pinyin2); 58 | } 59 | } 60 | } 61 | return o1.length() - o2.length(); 62 | } 63 | 64 | private String pinyin(char c) { 65 | String[] pinyins = PinyinHelper.toHanyuPinyinStringArray(c); 66 | if (pinyins == null) { 67 | return null; 68 | } 69 | return pinyins[0]; 70 | } 71 | /* 72 | private String concatPinyinStringArray(String[] pinyinArray) { 73 | StringBuilder pinyinSbf = new StringBuilder(); 74 | if ((pinyinArray != null) && (pinyinArray.length > 0)) { 75 | for (String aPinyinArray : pinyinArray) { 76 | pinyinSbf.append(aPinyinArray); 77 | } 78 | } 79 | return pinyinSbf.toString(); 80 | } 81 | */ 82 | } 83 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/Range.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | public class Range { 4 | private int start; 5 | private int end; 6 | 7 | public Range(int start, int end) { 8 | this.start = start; 9 | this.end = end; 10 | } 11 | 12 | public int start() { 13 | return this.start; 14 | } 15 | 16 | public int end() { 17 | return this.end; 18 | } 19 | 20 | public int getLength() { 21 | return end - start + 1; 22 | } 23 | 24 | public boolean isLegal() { 25 | return end >= start; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/RegexAdapter.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import android.view.LayoutInflater; 4 | import android.view.View; 5 | import android.view.View.OnClickListener; 6 | import android.view.ViewGroup; 7 | import android.widget.TextView; 8 | import androidx.annotation.NonNull; 9 | import androidx.recyclerview.widget.RecyclerView; 10 | import java.util.List; 11 | 12 | public class RegexAdapter extends RecyclerView.Adapter implements OnClickListener { 13 | private List regexList; 14 | private OnItemClickListener onItemClickListener = null; 15 | 16 | public RegexAdapter(List regexList) { 17 | this.regexList = regexList; 18 | } 19 | @NonNull 20 | @Override 21 | public ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) { 22 | View view = LayoutInflater.from(parent.getContext()).inflate(R.layout.regex_item,parent,false); 23 | view.setOnClickListener(this); 24 | return new ViewHolder(view); 25 | } 26 | 27 | @Override 28 | public void onBindViewHolder(@NonNull ViewHolder holder, int position) { 29 | CustomRegex customRegex = regexList.get(position); 30 | holder.labelBox.setText(customRegex.getLabel()); 31 | holder.regexBox.setText(customRegex.getRegex()); 32 | holder.itemView.setTag(position); 33 | } 34 | 35 | @Override 36 | public int getItemCount() { 37 | return regexList.size(); 38 | } 39 | 40 | static class ViewHolder extends RecyclerView.ViewHolder { 41 | TextView regexBox; 42 | TextView labelBox; 43 | 44 | public ViewHolder(@NonNull View itemView) { 45 | super(itemView); 46 | regexBox = itemView.findViewById(R.id.regexValue); 47 | labelBox = itemView.findViewById(R.id.regexLabel); 48 | } 49 | } 50 | public static interface OnItemClickListener { 51 | void onItemClick(View view , int position); 52 | } 53 | 54 | public void setOnItemClickListener(OnItemClickListener listener) { 55 | this.onItemClickListener = listener; 56 | } 57 | 58 | @Override 59 | public void onClick(View v) { 60 | if (onItemClickListener != null) { 61 | onItemClickListener.onItemClick(v,(int)v.getTag()); 62 | } 63 | } 64 | } -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/SettingsActivity.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import android.content.Intent; 4 | import android.content.SharedPreferences; 5 | import android.content.pm.PackageManager; 6 | import android.os.Bundle; 7 | import android.os.Environment; 8 | import android.view.MenuItem; 9 | import android.widget.Toast; 10 | import androidx.annotation.NonNull; 11 | import androidx.annotation.Nullable; 12 | import androidx.appcompat.app.AppCompatActivity; 13 | import com.leon.lfilepickerlibrary.LFilePicker; 14 | import com.leon.lfilepickerlibrary.utils.Constant; 15 | import es.dmoral.toasty.Toasty; 16 | import java.io.File; 17 | import java.util.Objects; 18 | import xyz.tcreopargh.textconverter.SettingsFragment.MyListener; 19 | 20 | public class SettingsActivity extends AppCompatActivity implements MyListener { 21 | public static String path = ""; 22 | public static int REQUESTCODE_WRITE = 2000; 23 | boolean settingsReset = false; 24 | 25 | @Override 26 | protected void onDestroy() { 27 | super.onDestroy(); 28 | if (settingsReset) { 29 | MainActivity.mainActivity.finish(); 30 | Intent intent = new Intent(SettingsActivity.this, MainActivity.class); 31 | startActivity(intent); 32 | } 33 | } 34 | 35 | @Override 36 | public void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) { 37 | super.onActivityResult(requestCode, resultCode, data); 38 | if (resultCode == RESULT_OK) { 39 | if (requestCode == 0) { 40 | boolean whether = Objects.requireNonNull(data).getBooleanExtra("easter_egg", false); 41 | Intent intent = new Intent(); 42 | intent.putExtra("easter_egg1", whether); 43 | setResult(RESULT_OK, intent); 44 | } else if (requestCode == REQUESTCODE_WRITE) { 45 | path = Objects.requireNonNull(data).getStringExtra("path"); 46 | SharedPreferences sharedPreferences = 47 | getSharedPreferences("settings", MODE_PRIVATE); 48 | SharedPreferences.Editor editor = sharedPreferences.edit(); 49 | editor.putString("default_path", path); 50 | editor.apply(); 51 | } 52 | } 53 | } 54 | 55 | @Override 56 | protected void onCreate(Bundle savedInstanceState) { 57 | super.onCreate(savedInstanceState); 58 | setContentView(R.layout.activity_settings); 59 | Objects.requireNonNull(getSupportActionBar()).setDisplayHomeAsUpEnabled(true); 60 | setResult(RESULT_OK); 61 | SettingsFragment settingsFragment = new SettingsFragment(); 62 | getSupportFragmentManager() 63 | .beginTransaction() 64 | .replace(R.id.settingsFragment, settingsFragment) 65 | .commit(); 66 | } 67 | 68 | @Override 69 | public boolean onOptionsItemSelected(MenuItem item) { 70 | switch (item.getItemId()) { 71 | case android.R.id.home: 72 | finish(); 73 | break; 74 | } 75 | return true; 76 | } 77 | 78 | @Override 79 | public void sendContent(boolean isSettingsReset) { 80 | settingsReset = isSettingsReset; 81 | } 82 | 83 | @Override 84 | public void onRequestPermissionsResult( 85 | int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) { 86 | switch (requestCode) { 87 | case 233: 88 | if (grantResults.length > 0 89 | && grantResults[0] == PackageManager.PERMISSION_GRANTED 90 | && grantResults[1] == PackageManager.PERMISSION_GRANTED) { 91 | getStoreLocation(); 92 | } else { 93 | Toasty.error( 94 | SettingsActivity.this, 95 | R.string.file_permission_denied, 96 | Toast.LENGTH_LONG, 97 | true) 98 | .show(); 99 | } 100 | break; 101 | default: 102 | } 103 | } 104 | 105 | public void reLoadFragView() { 106 | SettingsFragment settingsFragment = new SettingsFragment(); 107 | getSupportFragmentManager() 108 | .beginTransaction() 109 | .replace(R.id.settingsFragment, settingsFragment) 110 | .commit(); 111 | } 112 | 113 | private void getStoreLocation() { 114 | String pathTemp = 115 | Environment.getExternalStorageDirectory().getAbsolutePath() + "/TextConverter"; 116 | File destDir = new File(pathTemp); 117 | if (!destDir.exists()) { 118 | boolean doMkdirSuccess = destDir.mkdirs(); 119 | if (!doMkdirSuccess) { 120 | Toasty.error(this, R.string.folder_create_failed, Toast.LENGTH_LONG, true).show(); 121 | pathTemp = Environment.getExternalStorageDirectory().getAbsolutePath(); 122 | } 123 | } 124 | SettingsActivity.path = ""; 125 | new LFilePicker() 126 | .withActivity(this) 127 | .withBackgroundColor("#03a9f4") 128 | .withRequestCode(REQUESTCODE_WRITE) 129 | .withTitle(getString(R.string.pick_folder)) 130 | .withChooseMode(false) 131 | .withStartPath(pathTemp) 132 | .withIconStyle(Constant.ICON_STYLE_YELLOW) 133 | .withBackIcon(Constant.BACKICON_STYLETHREE) 134 | .start(); 135 | } 136 | } 137 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/TextConverter.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import com.google.gson.Gson; 4 | import com.google.gson.GsonBuilder; 5 | import com.google.gson.JsonElement; 6 | import com.google.gson.JsonParser; 7 | import java.nio.charset.StandardCharsets; 8 | import java.security.MessageDigest; 9 | import java.util.ArrayList; 10 | import java.util.regex.Matcher; 11 | import java.util.regex.Pattern; 12 | 13 | /** 14 | * @author TCreopargh 15 | */ 16 | public class TextConverter { 17 | 18 | public static final String[] fbsArr = {"\\", "$", "(", ")", "*", "+", ".", "[", "]", "?", "^", "{", "}", "|"}; 19 | 20 | public static int stringAppearCounter(String srcText, String findText) { 21 | int count = 0; 22 | int index = 0; 23 | while ((index = srcText.indexOf(findText, index)) != -1) { 24 | index = index + findText.length(); 25 | count++; 26 | } 27 | return count; 28 | } 29 | 30 | public static int regexAppearCounter(String srcText, String findText) { 31 | int count = 0; 32 | Pattern p = Pattern.compile(findText); 33 | Matcher m = p.matcher(srcText); 34 | while (m.find()) { 35 | count++; 36 | } 37 | return count; 38 | } 39 | 40 | public static String getMD5(String plainText) { 41 | try { 42 | MessageDigest md = MessageDigest.getInstance("MD5"); 43 | md.update(plainText.getBytes(StandardCharsets.UTF_8)); 44 | byte s[] = md.digest(); 45 | StringBuilder result = new StringBuilder(); 46 | for (byte value : s) { 47 | result.append(Integer.toHexString((0x000000FF & value) | 0xFFFFFF00).substring(6)); 48 | } 49 | return result.toString(); 50 | } catch (Exception e) { 51 | e.printStackTrace(); 52 | } 53 | return null; 54 | } 55 | 56 | public static String jsonFormatter(String uglyJSONString) { 57 | Gson gson = new GsonBuilder().setPrettyPrinting().create(); 58 | JsonParser jp = new JsonParser(); 59 | JsonElement je = jp.parse(uglyJSONString); 60 | return gson.toJson(je); 61 | } 62 | 63 | public static String replaceWithRegex(String textReplaceInput, String replaceFromStr, String replaceToStr) { 64 | boolean bool = false; 65 | StringBuilder input = new StringBuilder(textReplaceInput); 66 | Pattern p = Pattern.compile(replaceFromStr); 67 | Matcher m = p.matcher(input); 68 | replaceToStr = 69 | replaceToStr.replace("$$", "\u2333\u2888\u7575\u3139\u6666\u4232"); 70 | ArrayList strings = new ArrayList<>(); 71 | while (m.find()) { 72 | bool = !bool; 73 | strings.add(m.group()); 74 | char c = bool ? '\ufffe' : '\uffff'; 75 | StringBuilder temp = new StringBuilder(); 76 | for (int i = 0; i < m.group().length(); i++) { 77 | temp.append(c); 78 | } 79 | input.replace(m.start(), m.end(), temp.toString()); 80 | } 81 | String str = input.toString(); 82 | for (int i = 0; i < strings.size(); i++) { 83 | String string = strings.get(i); 84 | str = 85 | str.replaceFirst( 86 | "\\uFFFF+|\\uFFFE+", 87 | replaceToStr.replace("$val", string) 88 | .replace("$num", String.valueOf(i + 1)) 89 | .replace("$rev", new StringBuffer(string).reverse()) 90 | .replace("$len", String.valueOf(string.length())) 91 | .replace("$low", string.toLowerCase()) 92 | .replace("$upp", string.toUpperCase())); 93 | } 94 | return str; 95 | } 96 | public static String replaceWithoutRegex(boolean doCapsSensetive, String input, String replaceFromStr, String replaceToStr) { 97 | String textReplaceOutput; 98 | if (doCapsSensetive) { 99 | textReplaceOutput = 100 | input.replace(replaceFromStr, replaceToStr); 101 | } else { 102 | for (String key : fbsArr) { 103 | if (replaceFromStr.contains(key)) { 104 | replaceFromStr = replaceFromStr.replace(key, "\\" + key); 105 | } 106 | } 107 | textReplaceOutput = 108 | input.replaceAll( 109 | "(?i)" + replaceFromStr, replaceToStr); 110 | } 111 | return textReplaceOutput; 112 | } 113 | } 114 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/ToolboxAdapter.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import android.content.Context; 4 | import android.view.LayoutInflater; 5 | import android.view.View; 6 | import android.view.ViewGroup; 7 | import android.widget.ArrayAdapter; 8 | import android.widget.TextView; 9 | import java.util.List; 10 | import java.util.Objects; 11 | 12 | public class ToolboxAdapter extends ArrayAdapter { 13 | private int resourceId; 14 | public ToolboxAdapter(Context context, int textViewResourceId, List objects) { 15 | super(context,textViewResourceId,objects); 16 | resourceId=textViewResourceId; 17 | } 18 | @Override 19 | public View getView(int position, View convertView, ViewGroup parent) { 20 | ListItems listItems = getItem(position); 21 | View view; 22 | ViewHolder viewHolder; 23 | if(convertView==null) { 24 | view=LayoutInflater.from(getContext()).inflate(resourceId, parent, false); 25 | viewHolder=new ViewHolder(); 26 | viewHolder.listSubtitle=view.findViewById(R.id.listSubtitle); 27 | viewHolder.listName=view.findViewById(R.id.listLabel); 28 | view.setTag(viewHolder); 29 | } 30 | else { 31 | view=convertView; 32 | viewHolder=(ViewHolder)view.getTag(); 33 | } 34 | viewHolder.listName.setText(Objects.requireNonNull(listItems).getLabel()); 35 | viewHolder.listSubtitle.setText(listItems.getSubtitle()); 36 | return view; 37 | } 38 | class ViewHolder { 39 | TextView listSubtitle; 40 | TextView listName; 41 | } 42 | } -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/UnicodeUtils.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | /** 4 | * @author Nan 5 | * @link https://blog.csdn.net/qq_34471736/article/details/70311796 6 | */ 7 | public class UnicodeUtils { 8 | 9 | /** 10 | * 将utf-8的汉字转换成unicode格式汉字码 11 | * 12 | * @param string utf-8 13 | * @return unicode格式汉字码 14 | */ 15 | public static String stringToUnicode(String string) { 16 | 17 | StringBuilder unicode = new StringBuilder(); 18 | for (int i = 0; i < string.length(); i++) { 19 | char c = string.charAt(i); 20 | unicode.append("\\u").append(String.format("%04x", (int) c)); 21 | } 22 | return unicode.toString(); 23 | } 24 | 25 | /** 26 | * 将unicode的汉字码转换成utf-8格式的汉字 27 | * 28 | * @param unicode unicode的汉字码 29 | * @return utf-8格式的汉字 30 | */ 31 | public static String unicodeToString(String unicode) { 32 | 33 | String str = unicode.replace("0x", "\\"); 34 | 35 | StringBuilder string = new StringBuilder(); 36 | String[] hex = str.split("\\\\u"); 37 | for (int i = 1; i < hex.length; i++) { 38 | int data = Integer.parseInt(hex[i], 16); 39 | string.append((char) data); 40 | } 41 | return string.toString(); 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/tcreopargh/textconverter/ViewHelpActivity.java: -------------------------------------------------------------------------------- 1 | package xyz.tcreopargh.textconverter; 2 | 3 | import android.annotation.SuppressLint; 4 | import android.os.Build; 5 | import android.os.Bundle; 6 | import android.view.MenuItem; 7 | import android.webkit.WebView; 8 | import android.webkit.WebViewClient; 9 | import androidx.appcompat.app.AppCompatActivity; 10 | import java.util.Locale; 11 | import java.util.Objects; 12 | 13 | public class ViewHelpActivity extends AppCompatActivity { 14 | 15 | @SuppressLint("SetJavaScriptEnabled") 16 | @Override 17 | protected void onCreate(Bundle savedInstanceState) { 18 | super.onCreate(savedInstanceState); 19 | setContentView(R.layout.activity_view_help); 20 | Objects.requireNonNull(getSupportActionBar()).setDisplayHomeAsUpEnabled(true); 21 | WebView viewHelp = findViewById(R.id.viewHelpPage); 22 | viewHelp.setWebViewClient(new WebViewClient()); 23 | /*viewHelp.getSettings().setJavaScriptEnabled(true); 24 | viewHelp.setWebViewClient(new WebViewClient(){ 25 | @Override 26 | public void onReceivedSslError(WebView view, SslErrorHandler handler, SslError error){ 27 | handler.proceed(); 28 | } 29 | });*/ 30 | String newValue = 31 | getSharedPreferences("settings", MODE_PRIVATE).getString("appLanguage", "auto"); 32 | Locale locale; 33 | if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { 34 | locale = getResources().getConfiguration().getLocales().get(0); 35 | } else { 36 | locale = getResources().getConfiguration().locale; 37 | } 38 | String lang = ""; 39 | if (newValue != null) { 40 | switch (newValue) { 41 | case "auto": 42 | lang = locale.getLanguage() + "-" + locale.getCountry(); 43 | break; 44 | case "en-us": 45 | lang = "en-US"; 46 | break; 47 | case "zh-cn": 48 | lang = "zh-CN"; 49 | break; 50 | case "zh-hk": 51 | lang = "zh-HK"; 52 | break; 53 | } 54 | } 55 | if (lang.equalsIgnoreCase("zh-CN")) { 56 | viewHelp.loadUrl("file:///android_asset/help_document_zh_simplified.html"); 57 | setTitle("查看帮助"); 58 | } else if (lang.equalsIgnoreCase("zh-TW") || lang.equalsIgnoreCase("zh-HK")) { 59 | viewHelp.loadUrl("file:///android_asset/help_document_zh_traditional.html"); 60 | setTitle("查看幫助"); 61 | } else { 62 | viewHelp.loadUrl("file:///android_asset/help_document_en.html"); 63 | setTitle("View Guidelines"); 64 | } 65 | } 66 | 67 | public void returnHome() { 68 | finish(); 69 | } 70 | 71 | @Override 72 | public boolean onOptionsItemSelected(MenuItem item) { 73 | switch (item.getItemId()) { 74 | case android.R.id.home: 75 | returnHome(); 76 | break; 77 | } 78 | return true; 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/ic_launcher_foreground.xml: -------------------------------------------------------------------------------- 1 | 7 | 12 | 13 | 19 | 22 | 25 | 26 | 27 | 28 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/banner_new.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/res/drawable-xxhdpi/banner_new.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/res/drawable-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_launcher_foreground.xml: -------------------------------------------------------------------------------- 1 | 7 | 12 | 13 | 19 | 22 | 25 | 26 | 27 | 28 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/res/drawable-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_lock.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 14 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/nav_background.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TCreopargh/Text-Converter-Android/de21f736bc25a77271d50906cacbd27f8e015683/app/src/main/res/drawable-xxhdpi/nav_background.webp -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/shortcut_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselinedescription.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselinefindreplace.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 17 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselinehelpoutline.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 16 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselinehelpoutline_white.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 16 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselinehelpoutline_white_small.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 16 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselinesearch.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 14 | 16 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselinesettings.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 22 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselinesettings_white.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 22 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/baselineshuffle.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_account_balance_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_add_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_arrow_back_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_arrow_forward_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_attach_money_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_attach_money_white_48dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_check_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_code_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_code_white_48dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_content_copy_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_content_copy_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_custom.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 33 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_delete_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_format_list_numbered_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_info.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_info_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_keyboard_arrow_up_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_lock.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 14 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_lock_white.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 14 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_menu_camera.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 12 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_menu_gallery.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_menu_manage.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_menu_send.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_menu_share.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_menu_slideshow.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_mode_edit_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_notifications_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_public_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_redo_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_refresh_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_save_white_48dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_settings_backup_restore_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_settings_backup_restore_white_48dp.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_shuffle_white_48dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_star_border_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_stars_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_sync_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_text_fields_white_48dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_toolbox.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 26 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_undo_white_24dp.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_visibility_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/lock_open.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/nav_bg_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/nav_text_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/nav_tint_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/outline_more_horiz_24px.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/outline_more_horiz_white.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 10 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/rounded_button.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shortcut_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shortcut_more_foreground.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 9 | 10 | 28 | 29 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/touch_bg_ripple.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/layout/about_toolbar.xml: -------------------------------------------------------------------------------- 1 | 2 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_about.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_custom_regex.xml: -------------------------------------------------------------------------------- 1 | 2 | 10 | 11 | 15 | 16 | 22 | 23 | 24 | 25 | 26 | 27 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 11 | 12 | 16 | 17 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_markdown_preview.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 21 | 22 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 18 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_text_edit.xml: -------------------------------------------------------------------------------- 1 | 2 | 10 | 11 | 19 | 29 | 30 | 31 | 32 | 41 | 58 | 59 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_view_help.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 21 | -------------------------------------------------------------------------------- /app/src/main/res/layout/add_regex_dialog.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | 25 | 26 | 42 | 43 |