From 62278bbfe035e8952ae47103e3d26fa63d013a84 Mon Sep 17 00:00:00 2001 From: denizk0461 Date: Mon, 15 May 2023 17:00:38 +0200 Subject: [PATCH] Revamped the settings page in SettingsNewFragment.kt, but no functions are currently implemented --- .../textbasic/fragment/SettingsNewFragment.kt | 10 + app/src/main/res/color/list_group_button.xml | 5 + app/src/main/res/drawable/minus.xml | 5 + app/src/main/res/drawable/plus.xml | 5 + app/src/main/res/layout/fragment_guide.xml | 51 +- app/src/main/res/layout/fragment_settings.xml | 81 ++- .../main/res/layout/fragment_settings_new.xml | 615 ++++++++++++++++++ app/src/main/res/menu/nav_items.xml | 7 +- .../main/res/navigation/main_nav_graph.xml | 7 +- app/src/main/res/values-de/strings.xml | 49 +- app/src/main/res/values-night/themes.xml | 4 + app/src/main/res/values/strings.xml | 49 +- app/src/main/res/values/themes.xml | 4 + 13 files changed, 834 insertions(+), 58 deletions(-) create mode 100644 app/src/main/java/com/denizd/textbasic/fragment/SettingsNewFragment.kt create mode 100644 app/src/main/res/color/list_group_button.xml create mode 100644 app/src/main/res/drawable/minus.xml create mode 100644 app/src/main/res/drawable/plus.xml create mode 100644 app/src/main/res/layout/fragment_settings_new.xml diff --git a/app/src/main/java/com/denizd/textbasic/fragment/SettingsNewFragment.kt b/app/src/main/java/com/denizd/textbasic/fragment/SettingsNewFragment.kt new file mode 100644 index 0000000..97c4219 --- /dev/null +++ b/app/src/main/java/com/denizd/textbasic/fragment/SettingsNewFragment.kt @@ -0,0 +1,10 @@ +package com.denizd.textbasic.fragment + +import com.denizd.textbasic.R +import com.denizd.textbasic.databinding.FragmentSettingsNewBinding +import com.denizd.textbasic.util.viewBinding + +class SettingsNewFragment : BaseFragment(R.layout.fragment_settings_new) { + + private val binding: FragmentSettingsNewBinding by viewBinding(FragmentSettingsNewBinding::bind) +} \ No newline at end of file diff --git a/app/src/main/res/color/list_group_button.xml b/app/src/main/res/color/list_group_button.xml new file mode 100644 index 0000000..6ef7a9d --- /dev/null +++ b/app/src/main/res/color/list_group_button.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/drawable/minus.xml b/app/src/main/res/drawable/minus.xml new file mode 100644 index 0000000..3e0b776 --- /dev/null +++ b/app/src/main/res/drawable/minus.xml @@ -0,0 +1,5 @@ + + + diff --git a/app/src/main/res/drawable/plus.xml b/app/src/main/res/drawable/plus.xml new file mode 100644 index 0000000..89633bb --- /dev/null +++ b/app/src/main/res/drawable/plus.xml @@ -0,0 +1,5 @@ + + + diff --git a/app/src/main/res/layout/fragment_guide.xml b/app/src/main/res/layout/fragment_guide.xml index 98073a9..756ea7c 100644 --- a/app/src/main/res/layout/fragment_guide.xml +++ b/app/src/main/res/layout/fragment_guide.xml @@ -1,22 +1,53 @@ - + tools:context=".fragment.GuideFragment"> - + android:fitsSystemWindows="true"> + + + + + + + android:orientation="vertical" + android:layout_marginVertical="8dp" + android:layout_marginHorizontal="16dp"> - + - \ No newline at end of file + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_settings.xml b/app/src/main/res/layout/fragment_settings.xml index 15308dc..0b1d898 100644 --- a/app/src/main/res/layout/fragment_settings.xml +++ b/app/src/main/res/layout/fragment_settings.xml @@ -1,14 +1,63 @@ - + tools:context=".fragment.SettingsFragment"> + + + + + + + + + + + + + + + + + android:scrollbars="vertical" + app:layout_behavior="@string/appbar_scrolling_view_behavior"> - - - - - - - - - - @@ -541,4 +566,4 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_settings_new.xml b/app/src/main/res/layout/fragment_settings_new.xml new file mode 100644 index 0000000..b08cb10 --- /dev/null +++ b/app/src/main/res/layout/fragment_settings_new.xml @@ -0,0 +1,615 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/menu/nav_items.xml b/app/src/main/res/menu/nav_items.xml index 35c2f14..90c8c96 100644 --- a/app/src/main/res/menu/nav_items.xml +++ b/app/src/main/res/menu/nav_items.xml @@ -11,7 +11,12 @@ android:title="@string/guide" android:enabled="true"/> + diff --git a/app/src/main/res/navigation/main_nav_graph.xml b/app/src/main/res/navigation/main_nav_graph.xml index 6e1a744..0da6f7b 100644 --- a/app/src/main/res/navigation/main_nav_graph.xml +++ b/app/src/main/res/navigation/main_nav_graph.xml @@ -16,8 +16,13 @@ tools:layout="@layout/fragment_guide" android:label="GuideFragment"/> + \ No newline at end of file diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index 05f452f..3d6b98e 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -21,6 +21,37 @@ Eintrag wurde gelöscht Rückgängig + Anleitung + + Einstellungen + + Textstil + Textschrift + Schrift + Schriftstil + Standard + Fett + Kursiv + Fett & Kursiv + Textgröße + Texttransparenz + + Highlight-Stil + Stil + Keiner + Hintergrund + Umrandet + Schatten + Stärke + Highlight-Transparenz + + Widget + Stelle Reihenfolge ein + Dies ist die Reihenfolge, in welcher deine Einträge angezeigt werden, wenn du auf das Widget klickst + Standard + Zufall + Setze Position des Texts + Text bearbeiten Einträge Anleitung @@ -29,15 +60,15 @@ Position Vorschau für das Widget - Positioniere Widget oben links - Positioniere Widget oben zentriert - Positioniere Widget oben rechts - Positioniere Widget zentriert links - Positioniere Widget zentriert - Positioniere Widget zentriert rechts - Positioniere Widget unten links - Positioniere Widget unten zentriert - Positioniere Widget unten rechts + Positioniere Text oben links + Positioniere Text oben zentriert + Positioniere Text oben rechts + Positioniere Text zentriert links + Positioniere Text zentriert + Positioniere Text zentriert rechts + Positioniere Text unten links + Positioniere Text unten zentriert + Positioniere Text unten rechts Textfarbe (hex, ohne #) Hintergrundfarbe (hex, ohne #) diff --git a/app/src/main/res/values-night/themes.xml b/app/src/main/res/values-night/themes.xml index f9f2754..b79cc51 100644 --- a/app/src/main/res/values-night/themes.xml +++ b/app/src/main/res/values-night/themes.xml @@ -41,4 +41,8 @@ @color/md_theme_dark_primary @color/md_theme_dark_outlineVariant + + diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 83b4fce..5bba7a2 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -20,6 +20,37 @@ Entry has been deleted Undo + Guide + + Settings + + Text Style + Text font + Font + Font style + Default + Bold + Italic + Bold & Italic + Text size + Text transparency + + Highlight Style + Style + None + Background + Stroke + Shadow + Intensity + Transparency + + Widget + Set entry order + This is the order in which your entries will be shown when you click on the widget + Default + Random + Set position of the text + Edit Text Entries Guide @@ -28,15 +59,15 @@ position Preview for the widget - Position widget at top left - Position widget at top center - Position widget at top right - Position widget at center left - Position widget at center - Position widget at center right - Position widget at bottom left - Position widget at bottom center - Position widget at bottom right + Position text at top left + Position text at top center + Position text at top right + Position text at center left + Position text at center + Position text at center right + Position text at bottom left + Position text at bottom center + Position text at bottom right Text colour (hex, no #) Background colour (hex, no #) diff --git a/app/src/main/res/values/themes.xml b/app/src/main/res/values/themes.xml index adfed29..c9b82f2 100644 --- a/app/src/main/res/values/themes.xml +++ b/app/src/main/res/values/themes.xml @@ -43,4 +43,8 @@ @color/md_theme_light_primary @color/md_theme_light_outlineVariant + +