更新界面
This commit is contained in:
1 parent
cd4caed170
commit
3908ff7cf2
76 files changed
+1586
-1393
No files matched your search
@@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="150">
|
||||
android:duration="320"
|
||||
android:interpolator="@android:interpolator/decelerate_cubic">
|
||||
<translate
|
||||
android:fromYDelta="100%"
|
||||
android:toYDelta="0" />
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200">
|
||||
android:duration="320"
|
||||
android:interpolator="@android:interpolator/decelerate_cubic">
|
||||
<translate
|
||||
android:fromYDelta="0%"
|
||||
android:toYDelta="100%" />
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200">
|
||||
android:duration="320"
|
||||
android:interpolator="@android:interpolator/decelerate_cubic">
|
||||
<translate
|
||||
android:fromYDelta="-100%"
|
||||
android:toYDelta="0" />
|
||||
</set>
|
||||
</set>
|
||||
@@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200">
|
||||
android:duration="320"
|
||||
android:interpolator="@android:interpolator/decelerate_cubic">
|
||||
<translate
|
||||
android:fromYDelta="0"
|
||||
android:toYDelta="-100%" />
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="960" android:viewportHeight="960" android:tint="?attr/colorControlNormal">
|
||||
<path android:fillColor="@android:color/white" android:pathData="M856,570L570,856Q558,868 543,874Q528,880 513,880Q498,880 483,874Q468,868 456,856L103,503Q92,492 86,477.5Q80,463 80,447L80,160Q80,127 103.5,103.5Q127,80 160,80L447,80Q463,80 478,86.5Q493,93 504,104L856,457Q868,469 873.5,484Q879,499 879,514Q879,529 873.5,543.5Q868,558 856,570ZM260,320Q285,320 302.5,302.5Q320,285 320,260Q320,235 302.5,217.5Q285,200 260,200Q235,200 217.5,217.5Q200,235 200,260Q200,285 217.5,302.5Q235,320 260,320Z"/>
|
||||
</vector>
|
||||
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="960" android:viewportHeight="960" android:tint="?attr/colorControlNormal">
|
||||
<path android:fillColor="@android:color/white" android:pathData="M480,840L422,788Q321,697 255,631Q189,565 150,512.5Q111,460 95.5,416Q80,372 80,326Q80,232 143,169Q206,106 300,106Q352,106 399,128Q446,150 480,190Q514,150 561,128Q608,106 660,106Q754,106 817,169Q880,232 880,326Q880,372 864.5,416Q849,460 810,512.5Q771,565 705,631Q639,697 538,788L480,840Z"/>
|
||||
</vector>
|
||||
@@ -1,409 +1,389 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/bg_book"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:contentDescription="@string/bg_image"
|
||||
android:scaleType="centerCrop"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="ImageContrastCheck" />
|
||||
android:foreground="@drawable/bg_book_mask"
|
||||
android:scaleType="centerCrop" />
|
||||
|
||||
<View
|
||||
android:id="@+id/vw_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="#50000000" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.TitleBar
|
||||
android:id="@+id/title_bar"
|
||||
<com.google.android.material.appbar.AppBarLayout
|
||||
android:id="@+id/app_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:title="@string/book_info"
|
||||
app:themeMode="dark" />
|
||||
android:background="@android:color/transparent"
|
||||
android:fitsSystemWindows="true">
|
||||
|
||||
<LinearLayout
|
||||
<com.google.android.material.appbar.CollapsingToolbarLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/collapsingToolbarLayoutLargeSize"
|
||||
style="?attr/collapsingToolbarLayoutLargeSize"
|
||||
app:collapsedTitleTextAppearance="?attr/textAppearanceTitleLarge"
|
||||
app:expandedTitleTextAppearance="?attr/textAppearanceHeadlineLarge"
|
||||
app:layout_scrollFlags="scroll|exitUntilCollapsed|snap">
|
||||
|
||||
<com.google.android.material.appbar.MaterialToolbar
|
||||
android:id="@+id/top_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
app:navigationIcon="@drawable/ic_arrow_back"
|
||||
app:title=" "
|
||||
app:layout_collapseMode="pin" />
|
||||
|
||||
</com.google.android.material.appbar.CollapsingToolbarLayout>
|
||||
</com.google.android.material.appbar.AppBarLayout>
|
||||
|
||||
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
|
||||
android:id="@+id/refresh_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintTop_toBottomOf="@id/title_bar"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
tools:ignore="DisableBaselineAlignment">
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/bg_gradient_mask"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1.0"
|
||||
android:layout_gravity="center"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
android:orientation="horizontal">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="30dp">
|
||||
|
||||
<io.legato.kazusa.ui.widget.image.ArcView
|
||||
android:id="@+id/arc_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="78dp"
|
||||
android:layout_marginTop="128dp"
|
||||
app:arcDirectionTop="true"
|
||||
app:arcHeight="36dp"
|
||||
/>
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="32dp"
|
||||
tools:ignore="RtlSymmetry">
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_margin="3dp"
|
||||
app:cardCornerRadius="5dp"
|
||||
app:cardElevation="8dp">
|
||||
android:layout_marginEnd="96dp"
|
||||
android:layout_marginStart="16dp"
|
||||
app:cardCornerRadius="16dp">
|
||||
|
||||
<io.legato.kazusa.ui.widget.image.CoverImageView
|
||||
android:id="@+id/iv_cover"
|
||||
android:layout_width="130dp"
|
||||
android:layout_height="200dp"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="210dp"
|
||||
android:contentDescription="@string/img_cover"
|
||||
android:scaleType="centerCrop"
|
||||
android:src="@drawable/image_cover_default"
|
||||
tools:ignore="ImageContrastCheck" />
|
||||
android:src="@drawable/image_cover_default" />
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_info"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
|
||||
android:orientation="vertical"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="16dp"
|
||||
android:paddingBottom="3dp"
|
||||
tools:ignore="RtlHardcoded">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_name"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="6dp"
|
||||
android:gravity="center"
|
||||
android:includeFontPadding="false"
|
||||
android:singleLine="true"
|
||||
android:text="@string/book_name"
|
||||
android:textSize="18sp"
|
||||
tools:ignore="RtlHardcoded" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.LabelsBar
|
||||
android:id="@+id/lb_kind"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginBottom="6dp"
|
||||
android:gravity="center"
|
||||
android:visibility="gone" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp"
|
||||
tools:ignore="UseCompoundDrawables">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/origin_format"
|
||||
android:paddingRight="4dp"
|
||||
android:src="@drawable/ic_author"
|
||||
app:tint="@color/tv_text_summary"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
android:orientation="vertical"
|
||||
android:padding="12dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_author"
|
||||
android:id="@+id/tv_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:ellipsize="end"
|
||||
android:includeFontPadding="false"
|
||||
android:singleLine="true"
|
||||
android:text="@string/author"
|
||||
android:textSize="13sp"
|
||||
tools:ignore="NestedWeights,TextContrastCheck" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_weight="1.0"
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<androidx.core.widget.NestedScrollView
|
||||
android:id="@+id/scroll_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:fillViewport="true"
|
||||
android:fitsSystemWindows="true"
|
||||
android:focusable="true"
|
||||
android:padding="0dp"
|
||||
android:scrollbarStyle="outsideInset"
|
||||
android:scrollbars="vertical"
|
||||
tools:ignore="NestedWeights">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingTop="16dp"
|
||||
android:paddingLeft="8dp"
|
||||
android:paddingRight="8dp"
|
||||
android:paddingBottom="8dp">
|
||||
android:maxLines="2"
|
||||
android:text="@string/book_name"
|
||||
style="@style/TextAppearance.Material3.ActionBar.Title"
|
||||
tools:ignore="RtlHardcoded" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingLeft="8dp"
|
||||
android:paddingRight="8dp"
|
||||
android:paddingBottom="8dp">
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="6dp"
|
||||
android:paddingBottom="2dp"
|
||||
tools:ignore="UseCompoundDrawables">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
<ImageView
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/author"
|
||||
android:src="@drawable/ic_author"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_author"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_web"
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/origin_format"
|
||||
android:paddingRight="2dp"
|
||||
android:src="@drawable/ic_web_outline"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_origin"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:includeFontPadding="false"
|
||||
android:paddingRight="6dp"
|
||||
android:singleLine="true"
|
||||
android:textSize="13sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry,TextContrastCheck"
|
||||
tools:text="@string/origin_format" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.text.AccentBgTextView
|
||||
android:id="@+id/tv_change_source"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:paddingLeft="5dp"
|
||||
android:paddingRight="5dp"
|
||||
android:text="@string/change_origin"
|
||||
android:textSize="13sp"
|
||||
app:radius="2dp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp"
|
||||
tools:ignore="UseCompoundDrawables">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ic_book_last"
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/read_dur_progress"
|
||||
android:paddingRight="2dp"
|
||||
android:src="@drawable/ic_book_last"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_lasted"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:includeFontPadding="false"
|
||||
android:paddingRight="6dp"
|
||||
android:singleLine="true"
|
||||
android:textSize="13sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry,TextContrastCheck"
|
||||
tools:text="@string/read_dur_progress" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/read_dur_progress"
|
||||
android:paddingRight="2dp"
|
||||
android:src="@drawable/ic_groups"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_group"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:includeFontPadding="false"
|
||||
android:paddingRight="6dp"
|
||||
android:singleLine="true"
|
||||
android:textSize="13sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry,TextContrastCheck"
|
||||
tools:text="@string/group_s" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.text.AccentBgTextView
|
||||
android:id="@+id/tv_change_group"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:paddingLeft="5dp"
|
||||
android:paddingRight="5dp"
|
||||
android:text="@string/change_group"
|
||||
android:textSize="13sp"
|
||||
app:radius="2dp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/read_dur_progress"
|
||||
android:paddingRight="2dp"
|
||||
android:src="@drawable/ic_folder_open"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_toc"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:includeFontPadding="false"
|
||||
android:paddingRight="6dp"
|
||||
android:singleLine="true"
|
||||
android:textSize="13sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry,TextContrastCheck"
|
||||
tools:text="@string/toc_s" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.text.AccentBgTextView
|
||||
android:id="@+id/tv_toc_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:paddingLeft="5dp"
|
||||
android:paddingRight="5dp"
|
||||
android:text="@string/view_toc"
|
||||
android:textSize="13sp"
|
||||
app:radius="2dp" />
|
||||
|
||||
</LinearLayout>
|
||||
android:layout_weight="1"
|
||||
android:layout_marginStart="2dp"
|
||||
android:ellipsize="end"
|
||||
android:singleLine="true"
|
||||
android:text="@string/author"
|
||||
android:textSize="14sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<io.legato.kazusa.ui.widget.text.ScrollTextView
|
||||
android:id="@+id/tv_intro"
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:minHeight="48dp"
|
||||
android:paddingLeft="8dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="@string/book_intro"
|
||||
android:textIsSelectable="true"
|
||||
android:textSize="14sp"
|
||||
android:visibility="visible"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_web"
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/origin_format"
|
||||
android:src="@drawable/ic_web_outline"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_origin"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginStart="2dp"
|
||||
android:ellipsize="end"
|
||||
android:paddingRight="6dp"
|
||||
android:singleLine="true"
|
||||
android:textSize="14sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry"
|
||||
tools:text="@string/origin_format" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/fl_action"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintBottom_toBottomOf="parent">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_shelf"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:background="?attr/selectableItemBackground"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:gravity="center"
|
||||
android:includeFontPadding="false"
|
||||
android:text="@string/remove_from_bookshelf"
|
||||
android:textSize="15sp" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.text.AccentBgTextView
|
||||
android:id="@+id/tv_read"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:includeFontPadding="false"
|
||||
android:text="@string/reading"
|
||||
android:textSize="15sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<io.legato.kazusa.ui.widget.NoChildScrollNestedScrollView
|
||||
android:id="@+id/scroll_view"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:fillViewport="true"
|
||||
android:fitsSystemWindows="false"
|
||||
android:focusable="true"
|
||||
android:padding="0dp"
|
||||
android:scrollbarStyle="outsideOverlay"
|
||||
android:scrollbars="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_info"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:padding="8dp">
|
||||
|
||||
<HorizontalScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:scrollbars="none">
|
||||
|
||||
<io.legato.kazusa.ui.widget.LabelsBar
|
||||
android:id="@+id/lb_kind"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="gone" />
|
||||
|
||||
</HorizontalScrollView>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="8dp"
|
||||
android:paddingBottom="8dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:weightSum="4"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/btn_shelf"
|
||||
style="@style/Widget.Material3.Button.TextButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:padding="8dp"
|
||||
android:text="@string/remove_from_bookshelf"
|
||||
android:textSize="13sp"
|
||||
app:icon="@drawable/ic_clear_all"
|
||||
app:iconGravity="top"
|
||||
app:iconPadding="4dp"
|
||||
app:iconSize="20dp" />
|
||||
|
||||
<!-- 查看目录按钮 -->
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_toc_view"
|
||||
style="@style/Widget.Material3.Button.TextButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginStart="8dp"
|
||||
android:padding="8dp"
|
||||
android:text="@string/view_toc"
|
||||
android:textSize="13sp"
|
||||
app:icon="@drawable/ic_toc"
|
||||
app:iconGravity="top"
|
||||
app:iconPadding="4dp"
|
||||
app:iconSize="20dp" />
|
||||
|
||||
<!-- 更换分组按钮 -->
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_change_group"
|
||||
style="@style/Widget.Material3.Button.TextButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginStart="8dp"
|
||||
android:padding="8dp"
|
||||
android:text="@string/change_group"
|
||||
android:textSize="13sp"
|
||||
app:icon="@drawable/ic_groups"
|
||||
app:iconGravity="top"
|
||||
app:iconPadding="4dp"
|
||||
app:iconSize="20dp" />
|
||||
|
||||
<!-- 更换来源按钮(保持原样) -->
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/btn_change_source"
|
||||
style="@style/Widget.Material3.Button.TextButton"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginStart="8dp"
|
||||
android:text="@string/book_source"
|
||||
android:padding="8dp"
|
||||
app:icon="@drawable/ic_change_source"
|
||||
android:textSize="13sp"
|
||||
app:iconGravity="top"
|
||||
app:iconPadding="4dp"
|
||||
app:iconSize="20dp"
|
||||
tools:contentDescription="@string/change_origin" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_toc"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="4dp"
|
||||
android:paddingBottom="4dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/read_dur_progress"
|
||||
android:paddingRight="2dp"
|
||||
android:src="@drawable/ic_chapter"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_toc"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:includeFontPadding="false"
|
||||
android:paddingRight="6dp"
|
||||
android:textSize="14sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry"
|
||||
tools:text="@string/toc_s" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp"
|
||||
tools:ignore="UseCompoundDrawables">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ic_book_last"
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/read_dur_progress"
|
||||
android:paddingRight="2dp"
|
||||
android:src="@drawable/ic_book_last"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_lasted"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:includeFontPadding="false"
|
||||
android:paddingRight="6dp"
|
||||
android:singleLine="true"
|
||||
android:textSize="14sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry"
|
||||
tools:text="@string/read_dur_progress" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp"
|
||||
tools:ignore="UseCompoundDrawables">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="18sp"
|
||||
android:layout_height="18sp"
|
||||
android:contentDescription="@string/read_dur_progress"
|
||||
android:paddingRight="2dp"
|
||||
android:src="@drawable/ic_groups"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_detail"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:minHeight="48dp"
|
||||
android:paddingHorizontal="8dp"
|
||||
android:paddingBottom="80dp"
|
||||
android:lineSpacingExtra="4dp"
|
||||
android:text="@string/book_intro"
|
||||
android:textIsSelectable="true"
|
||||
android:textSize="14sp"
|
||||
android:visibility="visible"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
</LinearLayout>
|
||||
</io.legato.kazusa.ui.widget.NoChildScrollNestedScrollView>
|
||||
</LinearLayout>
|
||||
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
|
||||
|
||||
</LinearLayout>
|
||||
<com.google.android.material.floatingactionbutton.ExtendedFloatingActionButton
|
||||
android:id="@+id/btn_read"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|end"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="24dp"
|
||||
android:text="@string/reading"
|
||||
android:textColor="?attr/colorOnPrimary"
|
||||
android:contentDescription="@string/reading"
|
||||
app:iconGravity="textStart"
|
||||
app:icon="@drawable/ic_bottom_books"
|
||||
app:backgroundTint="?attr/colorSecondary"
|
||||
app:iconTint="?attr/colorOnPrimary"
|
||||
app:layout_behavior="com.google.android.material.behavior.HideBottomViewOnScrollBehavior" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||
@@ -0,0 +1,28 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<com.google.android.material.navigationrail.NavigationRailView
|
||||
android:id="@+id/navigation_rail_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
app:menuGravity="center"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:menu="@menu/main_bnv" />
|
||||
|
||||
<androidx.viewpager.widget.ViewPager
|
||||
android:id="@+id/view_pager_main"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@id/navigation_rail_view"
|
||||
app:layout_constraintEnd_toEndOf="parent" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -0,0 +1,264 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/vw_menu_root"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<View
|
||||
android:id="@+id/vw_menu_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:contentDescription="@string/content"
|
||||
tools:layout_editor_absoluteX="0dp"
|
||||
tools:layout_editor_absoluteY="0dp" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.TitleBar
|
||||
android:id="@+id/title_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?attr/colorSurfaceContainer"
|
||||
android:alpha="0.92"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="32dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_book_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TextAppearance.Material3.TitleLarge"
|
||||
android:singleLine="true" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/title_bar_addition"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_chapter_name"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TextAppearance.Material3.BodyMedium"
|
||||
android:layout_weight="1"
|
||||
android:singleLine="true" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_chapter_url"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:singleLine="true"
|
||||
android:visibility="gone" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_source_action"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingVertical="8dp"
|
||||
android:text="@string/book_source" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
|
||||
</io.legato.kazusa.ui.widget.TitleBar>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_brightness"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginHorizontal="32dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintBottom_toTopOf="@+id/bottom_menu"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/title_bar"
|
||||
tools:ignore="RtlHardcoded">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_brightness_auto"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:layout_margin="8dp"
|
||||
android:contentDescription="@string/brightness_auto"
|
||||
android:src="@drawable/ic_brightness_auto"
|
||||
tools:ignore="ImageContrastCheck" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.seekbar.VerticalSeekBarWrapper
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1">
|
||||
|
||||
<io.legato.kazusa.ui.widget.seekbar.VerticalSeekBar
|
||||
android:id="@+id/seek_brightness"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:max="255"
|
||||
app:seekBarRotation="CW270" />
|
||||
|
||||
</io.legato.kazusa.ui.widget.seekbar.VerticalSeekBarWrapper>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/vw_brightness_pos_adjust"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:layout_margin="8dp"
|
||||
android:contentDescription="@string/adjust_pos"
|
||||
android:src="@drawable/ic_swap_horiz"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/bottom_menu"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:alpha="0.92"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintBottom_toBottomOf="parent">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_bottom_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@android:color/transparent"
|
||||
android:importantForAccessibility="no"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<!--章节设置-->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginVertical="8dp"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:importantForAccessibility="no"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_pre"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:clickable="true"
|
||||
android:enabled="false"
|
||||
android:focusable="true"
|
||||
app:icon="@drawable/ic_previous"
|
||||
android:contentDescription="@string/previous_chapter"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
app:cardCornerRadius="32dp"
|
||||
app:cardBackgroundColor="?attr/colorSurfaceContainer"
|
||||
app:strokeWidth="0dp">
|
||||
<com.google.android.material.slider.Slider
|
||||
android:id="@+id/seek_read_page"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"/>
|
||||
</com.google.android.material.card.MaterialCardView>
|
||||
|
||||
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_next"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:clickable="true"
|
||||
android:enabled="false"
|
||||
android:focusable="true"
|
||||
app:icon="@drawable/ic_next"
|
||||
android:contentDescription="@string/next_chapter"
|
||||
tools:ignore="TouchTargetSizeCheck"/>
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/bottom_view"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="end"
|
||||
android:importantForAccessibility="no"
|
||||
android:paddingVertical="8dp"
|
||||
android:paddingHorizontal="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/fabSearch"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:contentDescription="@string/search_content"
|
||||
android:tooltipText="@string/search_content"
|
||||
app:icon="@drawable/ic_search"
|
||||
app:iconGravity="textStart"/>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/iv_read_aloud"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:contentDescription="@string/read_aloud"
|
||||
android:maxHeight="24dp"
|
||||
app:icon="@drawable/ic_read_aloud"
|
||||
app:iconGravity="textStart"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/iv_catalog"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:contentDescription="@string/chapter_list"
|
||||
android:tooltipText="@string/chapter_list"
|
||||
android:maxHeight="24dp"
|
||||
app:icon="@drawable/ic_toc"
|
||||
app:iconGravity="textStart"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/fabAutoPage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:contentDescription="@string/auto_next_page"
|
||||
android:tooltipText="@string/auto_next_page"
|
||||
app:icon="@drawable/ic_auto_page"
|
||||
app:iconGravity="textStart"
|
||||
tools:ignore="UnusedAttribute" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/iv_setting"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:contentDescription="@string/setting"
|
||||
android:tooltipText="@string/setting"
|
||||
android:maxHeight="24dp"
|
||||
app:icon="@drawable/ic_settings"
|
||||
app:iconGravity="textStart"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -66,12 +66,9 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_gradient_mask"
|
||||
android:paddingHorizontal="16dp"
|
||||
android:paddingTop="8dp">
|
||||
android:paddingVertical="8dp">
|
||||
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp">
|
||||
|
||||
<io.legato.kazusa.ui.widget.image.CoverImageView
|
||||
android:id="@+id/iv_cover"
|
||||
@@ -81,7 +78,7 @@
|
||||
android:scaleType="centerCrop"
|
||||
android:src="@drawable/image_cover_default" />
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
@@ -341,19 +338,6 @@
|
||||
android:src="@drawable/ic_groups"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_group"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:includeFontPadding="false"
|
||||
android:paddingRight="6dp"
|
||||
android:singleLine="true"
|
||||
android:textSize="14sp"
|
||||
tools:ignore="NestedWeights,RtlHardcoded,RtlSymmetry"
|
||||
tools:text="@string/group_s" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
@@ -1,25 +1,28 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/coordinator_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<androidx.viewpager.widget.ViewPager
|
||||
android:id="@+id/view_pager_main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintBottom_toTopOf="@id/bottom_navigation_view"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="SpeakableTextPresentCheck" />
|
||||
|
||||
<!-- 底部导航栏 -->
|
||||
<io.legato.kazusa.lib.theme.view.ThemeBottomNavigationVIew
|
||||
<com.google.android.material.bottomnavigation.BottomNavigationView
|
||||
android:id="@+id/bottom_navigation_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom"
|
||||
app:menu="@menu/main_bnv"
|
||||
app:layout_behavior="com.google.android.material.behavior.HideBottomViewOnScrollBehavior" />
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:menu="@menu/main_bnv" />
|
||||
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -1,185 +1,184 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="16dp">
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:fillViewport="true">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_group_style"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
<com.google.android.material.materialswitch.MaterialSwitch
|
||||
android:id="@+id/sw_show_unread"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:padding="6dp"
|
||||
android:text="@string/group_style" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatSpinner
|
||||
android:id="@+id/sp_group_style"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:entries="@array/group_style"
|
||||
android:padding="8dp"
|
||||
android:text="@string/show_unread"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<io.legato.kazusa.lib.theme.view.ThemeSwitch
|
||||
android:id="@+id/sw_show_unread"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="6dp"
|
||||
android:text="@string/show_unread"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ll_group_style"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<io.legato.kazusa.lib.theme.view.ThemeSwitch
|
||||
android:id="@+id/sw_show_last_update_time"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="6dp"
|
||||
android:text="@string/show_last_update_time"
|
||||
app:layout_constraintTop_toBottomOf="@+id/sw_show_unread"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<io.legato.kazusa.lib.theme.view.ThemeSwitch
|
||||
android:id="@+id/sw_show_wait_up_books"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="6dp"
|
||||
android:text="@string/show_wait_up_count"
|
||||
app:layout_constraintTop_toBottomOf="@+id/sw_show_last_update_time"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<io.legato.kazusa.lib.theme.view.ThemeSwitch
|
||||
android:id="@+id/sw_show_bookshelf_fast_scroller"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="6dp"
|
||||
android:text="@string/show_bookshelf_fast_scroller"
|
||||
app:layout_constraintTop_toBottomOf="@+id/sw_show_wait_up_books"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_layout"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintRight_toLeftOf="@+id/ll_sort"
|
||||
app:layout_constraintTop_toBottomOf="@+id/sw_show_bookshelf_fast_scroller"
|
||||
app:layout_constraintLeft_toLeftOf="parent">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="6dp"
|
||||
android:text="@string/view"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<RadioGroup
|
||||
android:id="@+id/rg_layout"
|
||||
<com.google.android.material.materialswitch.MaterialSwitch
|
||||
android:id="@+id/sw_show_last_update_time"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
android:padding="8dp"
|
||||
android:text="@string/show_last_update_time"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/layout_list"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/layout_grid3"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/layout_grid4"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/layout_grid5"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/layout_grid6"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
</RadioGroup>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_sort"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintLeft_toRightOf="@+id/ll_layout"
|
||||
app:layout_constraintTop_toBottomOf="@id/sw_show_bookshelf_fast_scroller"
|
||||
app:layout_constraintRight_toRightOf="parent">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="6dp"
|
||||
android:text="@string/sort"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<RadioGroup
|
||||
android:id="@+id/rg_sort"
|
||||
<com.google.android.material.materialswitch.MaterialSwitch
|
||||
android:id="@+id/sw_show_wait_up_books"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
android:padding="8dp"
|
||||
android:text="@string/show_wait_up_count"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
<com.google.android.material.materialswitch.MaterialSwitch
|
||||
android:id="@+id/sw_show_bookshelf_fast_scroller"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="8dp"
|
||||
android:text="@string/show_bookshelf_fast_scroller"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_group_style"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:paddingHorizontal="6dp"
|
||||
android:paddingVertical="16dp"
|
||||
android:text="@string/group_style" />
|
||||
|
||||
<Spinner
|
||||
android:id="@+id/sp_group_style"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:entries="@array/group_style"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.material.chip.ChipGroup
|
||||
android:id="@+id/chip_group_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:singleSelection="true"
|
||||
app:selectionRequired="true"
|
||||
android:paddingVertical="8dp"
|
||||
android:paddingHorizontal="4dp">
|
||||
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/chip_list"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="列表" />
|
||||
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/chip_grid"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="网格" />
|
||||
</com.google.android.material.chip.ChipGroup>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_grid_slider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:visibility="visible">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="每行列数:"
|
||||
android:textSize="14sp"
|
||||
android:paddingVertical="8dp"
|
||||
android:paddingHorizontal="4dp"/>
|
||||
|
||||
<com.google.android.material.slider.Slider
|
||||
android:id="@+id/slider_grid_count"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_0"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
android:paddingVertical="8dp"
|
||||
android:valueFrom="1"
|
||||
android:valueTo="9"
|
||||
android:stepSize="1"
|
||||
android:value="3" />
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:baselineAligned="false"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_sort"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_1"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_2"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="6dp"
|
||||
android:text="@string/sort"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_3"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
<RadioGroup
|
||||
android:id="@+id/rg_sort"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_4"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_0"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_5"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_1"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
</RadioGroup>
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_2"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_3"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_4"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.radiobutton.MaterialRadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/bookshelf_px_5"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
</RadioGroup>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</ScrollView>
|
||||
@@ -1,298 +1,312 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<ScrollView
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tool="http://schemas.android.com/tools"
|
||||
android:id="@+id/root_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
android:layout_height="wrap_content">
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:gravity="center"
|
||||
android:paddingVertical="16dp"
|
||||
android:paddingHorizontal="16dp">
|
||||
|
||||
<View
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="4dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:background="@drawable/bg_bottom_sheet_handle"
|
||||
android:layout_marginBottom="16dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/bottom_sheet_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="界面设置"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/set_bar"
|
||||
android:id="@+id/root_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginHorizontal="12dp" >
|
||||
|
||||
<io.legato.kazusa.ui.book.read.config.TextFontWeightConverter
|
||||
android:id="@+id/text_font_weight_converter"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:layout_width="72dp"
|
||||
android:layout_height="72dp"
|
||||
app:icon="@drawable/font_bold"
|
||||
app:iconGravity="textTop"
|
||||
android:text="@string/font_weight_text" />
|
||||
android:orientation="vertical"
|
||||
android:gravity="center"
|
||||
android:paddingVertical="16dp"
|
||||
android:paddingHorizontal="16dp">
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="4dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:background="@drawable/bg_bottom_sheet_handle"
|
||||
android:layout_marginBottom="16dp" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_text_font"
|
||||
android:layout_width="72dp"
|
||||
android:layout_height="72dp"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
app:icon="@drawable/font_style"
|
||||
app:iconGravity="textTop"
|
||||
android:text="@string/text_font" />
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_text_indent"
|
||||
android:layout_width="72dp"
|
||||
android:layout_height="72dp"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
app:icon="@drawable/ic_segment"
|
||||
app:iconGravity="textTop"
|
||||
android:text="@string/text_indent" />
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_padding"
|
||||
android:layout_width="72dp"
|
||||
android:layout_height="72dp"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
app:icon="@drawable/ic_padding"
|
||||
app:iconGravity="textTop"
|
||||
android:text="@string/padding" />
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center">
|
||||
<TextView
|
||||
android:id="@+id/bottom_sheet_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="界面设置"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_day_night"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:layout_marginStart="8dp"
|
||||
app:icon="@drawable/ic_brightness"
|
||||
app:iconGravity="textStart" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/set_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginHorizontal="12dp" >
|
||||
|
||||
<io.legato.kazusa.ui.book.read.config.TextFontWeightConverter
|
||||
android:id="@+id/text_font_weight_converter"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:layout_width="64dp"
|
||||
android:layout_height="64dp"
|
||||
app:icon="@drawable/font_bold"
|
||||
app:iconGravity="textTop"
|
||||
android:text="@string/font_weight_text" />
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_text_font"
|
||||
android:layout_width="64dp"
|
||||
android:layout_height="64dp"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
app:icon="@drawable/font_style"
|
||||
app:iconGravity="textTop"
|
||||
android:text="@string/text_font" />
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_text_indent"
|
||||
android:layout_width="64dp"
|
||||
android:layout_height="64dp"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
app:icon="@drawable/ic_segment"
|
||||
app:iconGravity="textTop"
|
||||
android:text="@string/text_indent" />
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_padding"
|
||||
android:layout_width="64dp"
|
||||
android:layout_height="64dp"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
app:icon="@drawable/ic_padding"
|
||||
app:iconGravity="textTop"
|
||||
android:text="@string/padding" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginHorizontal="12dp" >
|
||||
|
||||
<io.legato.kazusa.ui.book.read.config.ChineseConverter
|
||||
android:id="@+id/chinese_converter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
style="@style/Widget.Material3.Button.IconButton.Outlined" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_tip"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
style="@style/Widget.Material3.Button.IconButton.Outlined"
|
||||
android:text="@string/information" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_more"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
style="@style/Widget.Material3.Button.IconButton.Outlined"
|
||||
android:text="@string/more_setting" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<io.legato.kazusa.ui.widget.DetailSeekBar
|
||||
android:id="@+id/dsb_text_size"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginHorizontal="12dp" >
|
||||
app:isBottomBackground="true"
|
||||
app:max="45"
|
||||
app:title="@string/text_size" />
|
||||
|
||||
<io.legato.kazusa.ui.book.read.config.ChineseConverter
|
||||
android:id="@+id/chinese_converter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
style="@style/Widget.Material3.Button.IconButton.Outlined" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_tip"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
style="@style/Widget.Material3.Button.IconButton.Outlined"
|
||||
android:text="@string/information" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
<io.legato.kazusa.ui.widget.DetailSeekBar
|
||||
android:id="@+id/dsb_text_size"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:layout_marginTop="8dp"
|
||||
app:isBottomBackground="true"
|
||||
app:max="45"
|
||||
app:title="@string/text_size" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.DetailSeekBar
|
||||
android:id="@+id/dsb_text_letter_spacing"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
app:isBottomBackground="true"
|
||||
app:max="100"
|
||||
app:title="@string/text_letter_spacing" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.DetailSeekBar
|
||||
android:id="@+id/dsb_line_size"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
app:isBottomBackground="true"
|
||||
app:max="20"
|
||||
app:title="@string/line_size" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.DetailSeekBar
|
||||
android:id="@+id/dsb_paragraph_spacing"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
app:isBottomBackground="true"
|
||||
app:max="20"
|
||||
app:title="@string/paragraph_size" />
|
||||
|
||||
<View
|
||||
android:id="@+id/vw_bg_fg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:layout_marginVertical="8dp"
|
||||
android:background="@color/btn_bg_press" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/set_bottom_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
<TextView
|
||||
android:id="@+id/tv_page_anim"
|
||||
<io.legato.kazusa.ui.widget.DetailSeekBar
|
||||
android:id="@+id/dsb_text_letter_spacing"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:layout_marginBottom="4dp"
|
||||
android:text="@string/page_anim"
|
||||
android:textSize="12sp" />
|
||||
app:isBottomBackground="true"
|
||||
app:max="100"
|
||||
app:title="@string/text_letter_spacing" />
|
||||
|
||||
<HorizontalScrollView
|
||||
<io.legato.kazusa.ui.widget.DetailSeekBar
|
||||
android:id="@+id/dsb_line_size"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:scrollbars="none">
|
||||
|
||||
<com.google.android.material.chip.ChipGroup
|
||||
android:id="@+id/rg_page_anim"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingHorizontal="16dp"
|
||||
app:singleLine="true"
|
||||
app:singleSelection="true"
|
||||
app:selectionRequired="true">
|
||||
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_anim0"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/page_anim_cover"
|
||||
/>
|
||||
|
||||
<!-- 滑动动画 Chip -->
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_anim1"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:text="@string/page_anim_slide"
|
||||
app:chipStrokeWidth="1dp" />
|
||||
|
||||
<!-- 仿真翻页 Chip -->
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_simulation_anim"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:text="@string/page_anim_simulation"
|
||||
app:chipStrokeWidth="1dp" />
|
||||
|
||||
<!-- 滚动动画 Chip -->
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_scroll_anim"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:text="@string/page_anim_scroll"
|
||||
app:chipStrokeWidth="1dp" />
|
||||
|
||||
<!-- 无动画 Chip -->
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_no_anim"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:text="@string/page_anim_none"
|
||||
app:chipStrokeWidth="1dp" />
|
||||
|
||||
</com.google.android.material.chip.ChipGroup>
|
||||
</HorizontalScrollView>
|
||||
|
||||
<View
|
||||
android:id="@+id/vw_bg_fg1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:layout_marginVertical="8dp" />
|
||||
app:isBottomBackground="true"
|
||||
app:max="20"
|
||||
app:title="@string/line_size" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.DetailSeekBar
|
||||
android:id="@+id/dsb_paragraph_spacing"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
app:isBottomBackground="true"
|
||||
app:max="20"
|
||||
app:title="@string/paragraph_size" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/set_bottom_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_bg_ts"
|
||||
android:layout_width="0dp"
|
||||
android:id="@+id/tv_page_anim"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_weight="1"
|
||||
android:alpha="0.75"
|
||||
android:text="@string/text_bg_style"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:layout_marginBottom="4dp"
|
||||
android:text="@string/page_anim"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<HorizontalScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:scrollbars="none">
|
||||
|
||||
<com.google.android.material.chip.ChipGroup
|
||||
android:id="@+id/rg_page_anim"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingHorizontal="16dp"
|
||||
app:singleLine="true"
|
||||
app:singleSelection="true"
|
||||
app:selectionRequired="true">
|
||||
|
||||
<com.google.android.material.checkbox.MaterialCheckBox
|
||||
android:id="@+id/cb_share_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="20dp"
|
||||
android:text="@string/share_layout"
|
||||
android:layout_marginStart="6dp"
|
||||
android:layout_marginEnd="16dp" />
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_anim0"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/page_anim_cover"
|
||||
/>
|
||||
|
||||
<!-- 滑动动画 Chip -->
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_anim1"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:text="@string/page_anim_slide"
|
||||
app:chipStrokeWidth="1dp" />
|
||||
|
||||
<!-- 仿真翻页 Chip -->
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_simulation_anim"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:text="@string/page_anim_simulation"
|
||||
app:chipStrokeWidth="1dp" />
|
||||
|
||||
<!-- 滚动动画 Chip -->
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_scroll_anim"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:text="@string/page_anim_scroll"
|
||||
app:chipStrokeWidth="1dp" />
|
||||
|
||||
<!-- 无动画 Chip -->
|
||||
<com.google.android.material.chip.Chip
|
||||
android:id="@+id/rb_no_anim"
|
||||
style="@style/Widget.Material3.Chip.Filter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:text="@string/page_anim_none"
|
||||
app:chipStrokeWidth="1dp" />
|
||||
|
||||
</com.google.android.material.chip.ChipGroup>
|
||||
</HorizontalScrollView>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_bg_ts"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_weight="1"
|
||||
android:alpha="0.75"
|
||||
android:text="@string/text_bg_style"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<com.google.android.material.checkbox.MaterialCheckBox
|
||||
android:id="@+id/cb_share_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="20dp"
|
||||
android:text="@string/share_layout"
|
||||
android:layout_marginStart="6dp"
|
||||
android:layout_marginEnd="16dp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rv_style"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:clipToPadding="false"
|
||||
android:orientation="horizontal"
|
||||
android:paddingHorizontal="12dp"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
tool:listitem="@layout/item_read_style" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rv_style"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:clipToPadding="false"
|
||||
android:orientation="horizontal"
|
||||
android:paddingHorizontal="12dp"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
tool:listitem="@layout/item_read_style" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
||||
@@ -3,10 +3,10 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:padding="20dp"
|
||||
android:padding="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ProgressBar
|
||||
<com.google.android.material.progressindicator.CircularProgressIndicator
|
||||
android:id="@+id/pb"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
@@ -17,7 +17,7 @@
|
||||
android:id="@+id/tv_msg"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="6dp"
|
||||
android:padding="8dp"
|
||||
android:gravity="center"
|
||||
android:text="@string/loading" />
|
||||
</LinearLayout>
|
||||
@@ -1,17 +1,24 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/text_view"
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/selector_fillet_btn_bg"
|
||||
android:ellipsize="end"
|
||||
android:gravity="center"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:paddingStart="16dp"
|
||||
android:paddingEnd="16dp"
|
||||
android:maxLines="1"
|
||||
android:textSize="14sp"
|
||||
android:textColor="?attr/colorPrimary"
|
||||
tools:ignore="UnusedAttribute" />
|
||||
android:clickable="true"
|
||||
android:focusable="true">
|
||||
<TextView
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/text_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:ellipsize="end"
|
||||
android:gravity="center"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:paddingStart="16dp"
|
||||
android:paddingEnd="16dp"
|
||||
android:maxLines="1"
|
||||
android:textSize="14sp"
|
||||
android:textColor="?attr/colorPrimary"
|
||||
tools:ignore="UnusedAttribute" />
|
||||
</com.google.android.material.card.MaterialCardView>
|
||||
|
||||
@@ -28,8 +28,8 @@
|
||||
android:name="@string/enable"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="6dp"
|
||||
android:layout_marginRight="6dp"
|
||||
android:layout_marginStart="8dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@id/iv_edit"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
@@ -37,12 +37,12 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_edit"
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:layout_gravity="center"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:contentDescription="@string/edit"
|
||||
android:padding="6dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@drawable/ic_edit"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@id/iv_menu_more"
|
||||
@@ -50,11 +50,11 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_menu_more"
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"
|
||||
android:contentDescription="@string/more_menu"
|
||||
android:padding="6dp"
|
||||
|
||||
android:src="@drawable/ic_more_vert"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
|
||||
@@ -7,9 +7,10 @@
|
||||
android:background="?attr/selectableItemBackground"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:padding="16dp">
|
||||
android:paddingHorizontal="16dp"
|
||||
android:paddingVertical="8dp">
|
||||
|
||||
<io.legato.kazusa.lib.theme.view.ThemeCheckBox
|
||||
<com.google.android.material.checkbox.MaterialCheckBox
|
||||
android:id="@+id/cb_source"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -21,13 +22,13 @@
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="TouchTargetSizeCheck,DuplicateSpeakableTextCheck" />
|
||||
|
||||
<io.legato.kazusa.lib.theme.view.ThemeSwitch
|
||||
<com.google.android.material.materialswitch.MaterialSwitch
|
||||
android:id="@+id/swt_enabled"
|
||||
android:name="@string/enable"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="6dp"
|
||||
android:layout_marginRight="6dp"
|
||||
android:layout_marginStart="8dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
app:layout_constraintBottom_toTopOf="@id/title_example"
|
||||
app:layout_constraintRight_toLeftOf="@id/iv_edit"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
@@ -35,12 +36,12 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_edit"
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:layout_gravity="center"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:contentDescription="@string/edit"
|
||||
android:padding="6dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@drawable/ic_edit"
|
||||
app:layout_constraintBottom_toTopOf="@id/title_example"
|
||||
app:layout_constraintRight_toLeftOf="@id/iv_menu_more"
|
||||
@@ -48,11 +49,11 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_menu_more"
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"
|
||||
android:contentDescription="@string/more_menu"
|
||||
android:padding="6dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@drawable/ic_more_vert"
|
||||
app:layout_constraintBottom_toTopOf="@id/title_example"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
|
||||
@@ -5,14 +5,14 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<io.legato.kazusa.ui.widget.anima.RotateLoading
|
||||
<com.google.android.material.progressindicator.CircularProgressIndicator
|
||||
android:id="@+id/rotate_loading"
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_margin="6dp"
|
||||
android:layout_gravity="center"
|
||||
android:visibility="invisible"
|
||||
app:loading_width="2dp" />
|
||||
android:indeterminate="true" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_text"
|
||||
@@ -21,7 +21,6 @@
|
||||
android:padding="10dp"
|
||||
android:layout_gravity="center"
|
||||
android:gravity="center"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
android:textSize="14sp"
|
||||
android:background="?attr/selectableItemBackground"
|
||||
android:visibility="invisible"
|
||||
|
||||
@@ -5,10 +5,8 @@
|
||||
android:background="?attr/selectableItemBackground"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="16dp"
|
||||
android:paddingTop="16dp"
|
||||
android:paddingRight="16dp"
|
||||
android:paddingBottom="16dp"
|
||||
android:paddingHorizontal="16dp"
|
||||
android:paddingVertical="16dp"
|
||||
android:minHeight="60dp"
|
||||
android:clickable="true"
|
||||
android:orientation="horizontal"
|
||||
@@ -20,9 +18,8 @@
|
||||
android:layout_marginRight="16dp"
|
||||
android:scaleType="fitCenter"
|
||||
android:visibility="visible"
|
||||
android:paddingTop="1dp"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_width="28dp"
|
||||
android:layout_height="28dp"
|
||||
app:tint="?attr/colorPrimary"
|
||||
tools:ignore="ContentDescription,RtlHardcoded" />
|
||||
|
||||
@@ -53,10 +50,8 @@
|
||||
<FrameLayout
|
||||
android:id="@+id/preference_widget"
|
||||
android:orientation="vertical"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginStart="12dp"
|
||||
android:layout_marginTop="2dp"
|
||||
android:layout_marginBottom="2dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="16dp"
|
||||
android:visibility="gone"
|
||||
android:gravity="right|center_vertical"
|
||||
android:layout_width="wrap_content"
|
||||
|
||||
@@ -19,53 +19,55 @@
|
||||
android:id="@+id/title_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?attr/colorSurfaceContainer"
|
||||
android:alpha="0.92"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/title_bar_addition"
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="16dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_chapter_name"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingRight="10dp"
|
||||
android:singleLine="true"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@+id/tv_source_action"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_chapter_url"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingRight="10dp"
|
||||
android:singleLine="true"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@+id/tv_source_action"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tv_chapter_name" />
|
||||
|
||||
<io.legato.kazusa.ui.widget.text.AccentBgTextView
|
||||
android:id="@+id/tv_source_action"
|
||||
android:id="@+id/tv_book_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:layout_margin="1dp"
|
||||
android:gravity="center"
|
||||
android:maxWidth="120dp"
|
||||
android:paddingLeft="6dp"
|
||||
android:paddingRight="6dp"
|
||||
android:text="@string/book_source"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_chapter_url"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:radius="2dp" />
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TextAppearance.Material3.TitleLarge"
|
||||
android:singleLine="true" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/title_bar_addition"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_chapter_name"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TextAppearance.Material3.BodyMedium"
|
||||
android:layout_weight="1"
|
||||
android:singleLine="true" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_chapter_url"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:singleLine="true"
|
||||
android:visibility="gone" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_source_action"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingVertical="8dp"
|
||||
android:text="@string/book_source" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</io.legato.kazusa.ui.widget.TitleBar>
|
||||
|
||||
@@ -119,113 +121,32 @@
|
||||
android:id="@+id/bottom_menu"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:alpha="0.92"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintBottom_toBottomOf="parent">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_floating_button"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="12dp"
|
||||
android:paddingEnd="12dp">
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fabSearch"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="12dp"
|
||||
android:contentDescription="@string/search_content"
|
||||
android:src="@drawable/ic_search"
|
||||
android:tooltipText="@string/search_content"
|
||||
app:elevation="2dp"
|
||||
app:fabSize="mini"
|
||||
tools:ignore="UnusedAttribute" />
|
||||
|
||||
<Space
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fabAutoPage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="12dp"
|
||||
android:contentDescription="@string/auto_next_page"
|
||||
android:src="@drawable/ic_auto_page"
|
||||
android:tooltipText="@string/auto_next_page"
|
||||
app:elevation="2dp"
|
||||
app:fabSize="mini"
|
||||
tools:ignore="UnusedAttribute" />
|
||||
|
||||
<Space
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fabReplaceRule"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="12dp"
|
||||
android:contentDescription="@string/replace_rule_title"
|
||||
android:src="@drawable/ic_find_replace"
|
||||
android:tooltipText="@string/replace_rule_title"
|
||||
app:elevation="2dp"
|
||||
app:fabSize="mini"
|
||||
tools:ignore="UnusedAttribute" />
|
||||
|
||||
<Space
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fabNightTheme"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="12dp"
|
||||
android:contentDescription="@string/dark_theme"
|
||||
android:src="@drawable/ic_brightness"
|
||||
android:tooltipText="@string/dark_theme"
|
||||
app:elevation="2dp"
|
||||
app:fabSize="mini"
|
||||
tools:ignore="UnusedAttribute" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:strokeWidth="0dp"
|
||||
android:layout_margin="8dp">
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_bottom_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?attr/colorSurface"
|
||||
android:background="@android:color/transparent"
|
||||
android:importantForAccessibility="no"
|
||||
android:orientation="vertical">
|
||||
<!--章节设置-->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_marginRight="16dp"
|
||||
android:layout_marginBottom="5dp"
|
||||
android:layout_marginVertical="8dp"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:importantForAccessibility="no"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_pre"
|
||||
style="@style/Widget.Material3.Button.IconButton.Outlined"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:clickable="true"
|
||||
android:enabled="false"
|
||||
android:focusable="true"
|
||||
@@ -233,22 +154,27 @@
|
||||
android:contentDescription="@string/previous_chapter"
|
||||
tools:ignore="TouchTargetSizeCheck" />
|
||||
|
||||
<com.google.android.material.slider.Slider
|
||||
android:id="@+id/seek_read_page"
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="1"
|
||||
android:valueTo="2.0"
|
||||
android:valueFrom="1.0"
|
||||
android:value="1.0"/>
|
||||
app:cardCornerRadius="32dp"
|
||||
app:cardBackgroundColor="?attr/colorSurfaceContainer"
|
||||
app:strokeWidth="0dp">
|
||||
<com.google.android.material.slider.Slider
|
||||
android:id="@+id/seek_read_page"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"/>
|
||||
</com.google.android.material.card.MaterialCardView>
|
||||
|
||||
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/tv_next"
|
||||
style="@style/Widget.Material3.Button.IconButton.Outlined"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="4dp"
|
||||
android:clickable="true"
|
||||
android:enabled="false"
|
||||
android:focusable="true"
|
||||
@@ -258,179 +184,43 @@
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/bottom_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:baselineAligned="false"
|
||||
android:importantForAccessibility="no"
|
||||
android:paddingVertical="8dp"
|
||||
android:paddingHorizontal="16dp"
|
||||
android:background="?attr/colorSurfaceContainer"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/fabSearch"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:backgroundTint="@android:color/transparent"
|
||||
android:contentDescription="@string/search_content"
|
||||
android:tooltipText="@string/search_content"
|
||||
app:icon="@drawable/ic_search"
|
||||
app:iconGravity="textStart"/>
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:importantForAccessibility="no" />
|
||||
|
||||
<!--目录按钮-->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_catalog"
|
||||
android:layout_width="56dp"
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/iv_read_aloud"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:clickable="true"
|
||||
android:contentDescription="@string/chapter_list"
|
||||
android:focusable="true"
|
||||
android:orientation="vertical"
|
||||
android:gravity="center"
|
||||
android:paddingBottom="4dp"
|
||||
tools:ignore="VisualLintBounds">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_catalog"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/chapter_list"
|
||||
android:maxHeight="24dp"
|
||||
android:src="@drawable/ic_toc"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_catalog"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="2dp"
|
||||
android:ellipsize="middle"
|
||||
android:singleLine="true"
|
||||
android:text="@string/chapter_list"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="2"
|
||||
android:importantForAccessibility="no" />
|
||||
|
||||
<!--调节按钮-->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_read_aloud"
|
||||
android:layout_width="56dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:clickable="true"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:backgroundTint="@android:color/transparent"
|
||||
android:contentDescription="@string/read_aloud"
|
||||
android:focusable="true"
|
||||
android:orientation="vertical"
|
||||
android:gravity="center"
|
||||
android:paddingBottom="4dp"
|
||||
tools:ignore="VisualLintBounds">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_read_aloud"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/read_aloud"
|
||||
android:maxHeight="24dp"
|
||||
android:src="@drawable/ic_read_aloud"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_read_aloud"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="2dp"
|
||||
android:ellipsize="middle"
|
||||
android:singleLine="true"
|
||||
android:text="@string/read_aloud"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="2"
|
||||
android:importantForAccessibility="no" />
|
||||
|
||||
<!--界面按钮-->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_font"
|
||||
android:layout_width="56dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:clickable="true"
|
||||
android:contentDescription="@string/interface_setting"
|
||||
android:focusable="true"
|
||||
android:orientation="vertical"
|
||||
android:gravity="center"
|
||||
android:paddingBottom="4dp"
|
||||
tools:ignore="VisualLintBounds">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_font"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/interface_setting"
|
||||
android:maxHeight="24dp"
|
||||
android:src="@drawable/ic_interface_setting"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_font"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="2dp"
|
||||
android:ellipsize="middle"
|
||||
android:singleLine="true"
|
||||
android:text="@string/interface_setting"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="2"
|
||||
android:importantForAccessibility="no" />
|
||||
|
||||
<!--设置按钮-->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_setting"
|
||||
android:layout_width="56dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:clickable="true"
|
||||
android:contentDescription="@string/setting"
|
||||
android:focusable="true"
|
||||
android:orientation="vertical"
|
||||
android:gravity="center"
|
||||
android:paddingBottom="4dp"
|
||||
tools:ignore="VisualLintBounds">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_setting"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/setting"
|
||||
android:maxHeight="24dp"
|
||||
android:src="@drawable/ic_settings"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_setting"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="2dp"
|
||||
android:ellipsize="middle"
|
||||
android:singleLine="true"
|
||||
android:text="@string/setting"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
android:maxHeight="24dp"
|
||||
app:icon="@drawable/ic_read_aloud"
|
||||
app:iconGravity="textStart"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
@@ -438,9 +228,58 @@
|
||||
android:layout_weight="1"
|
||||
android:importantForAccessibility="no" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/iv_catalog"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:backgroundTint="@android:color/transparent"
|
||||
android:contentDescription="@string/chapter_list"
|
||||
android:tooltipText="@string/chapter_list"
|
||||
android:maxHeight="24dp"
|
||||
app:icon="@drawable/ic_toc"
|
||||
app:iconGravity="textStart"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:importantForAccessibility="no" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/fabAutoPage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:backgroundTint="@android:color/transparent"
|
||||
android:contentDescription="@string/auto_next_page"
|
||||
android:tooltipText="@string/auto_next_page"
|
||||
app:icon="@drawable/ic_auto_page"
|
||||
app:iconGravity="textStart"
|
||||
tools:ignore="UnusedAttribute" />
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:importantForAccessibility="no" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/iv_setting"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Material3.Button.IconButton.Filled.Tonal"
|
||||
android:backgroundTint="@android:color/transparent"
|
||||
android:contentDescription="@string/setting"
|
||||
android:tooltipText="@string/setting"
|
||||
android:maxHeight="24dp"
|
||||
app:icon="@drawable/ic_settings"
|
||||
app:iconGravity="textStart"
|
||||
tools:ignore="NestedWeights" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</com.google.android.material.card.MaterialCardView>
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -88,6 +88,16 @@
|
||||
android:title="@string/replace_rule_title"
|
||||
app:showAsAction="never" />
|
||||
|
||||
<item
|
||||
android:id="@+id/menu_setting_replace"
|
||||
android:title="@string/replace_rule_title_setting"
|
||||
app:showAsAction="never" />
|
||||
|
||||
<item
|
||||
android:id="@+id/menu_effective_replaces"
|
||||
android:title="@string/effective_replaces"
|
||||
app:showAsAction="never" />
|
||||
|
||||
<item
|
||||
android:id="@+id/menu_same_title_removed"
|
||||
android:checkable="true"
|
||||
@@ -137,11 +147,6 @@
|
||||
android:title="@string/update_toc"
|
||||
app:showAsAction="never" />
|
||||
|
||||
<item
|
||||
android:id="@+id/menu_effective_replaces"
|
||||
android:title="@string/effective_replaces"
|
||||
app:showAsAction="never" />
|
||||
|
||||
<item
|
||||
android:id="@+id/menu_log"
|
||||
android:title="@string/log"
|
||||
|
||||
@@ -229,7 +229,7 @@
|
||||
<string name="import_select_book">导入选择书籍</string>
|
||||
<string name="threads_num_title">更新和搜索线程数(太多会卡顿)</string>
|
||||
<string name="change_icon">切换图标</string>
|
||||
<string name="remove_from_bookshelf">删除书籍</string>
|
||||
<string name="remove_from_bookshelf">已在书架</string>
|
||||
<string name="start_read">开始阅读</string>
|
||||
<string name="data_loading">加载数据中…</string>
|
||||
<string name="load_error_retry">加载失败,点击重试</string>
|
||||
@@ -589,7 +589,7 @@
|
||||
<string name="remove_group">移除分组</string>
|
||||
<string name="add_replace_rule">新建替换</string>
|
||||
<string name="group">分组</string>
|
||||
<string name="group_s">分组:%s</string>
|
||||
<string name="group_s">%s</string>
|
||||
<string name="toc_s">已读:%s</string>
|
||||
<string name="enable_explore">启用发现</string>
|
||||
<string name="disable_explore">禁用发现</string>
|
||||
|
||||
@@ -1221,4 +1221,6 @@
|
||||
<string name="ungroup">未分组</string>
|
||||
<string name="dynamic_colors">动态取色</string>
|
||||
<string name="change_icon_success">图标已修改</string>
|
||||
<string name="replace_rule_title_setting">配置替换规则</string>
|
||||
<string name="more_setting">更多设置</string>
|
||||
</resources>
|
||||
@@ -2,6 +2,14 @@
|
||||
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<io.legato.kazusa.lib.prefs.ThemeModePreference
|
||||
android:defaultValue="0"
|
||||
android:entries="@array/theme_mode"
|
||||
android:entryValues="@array/theme_mode_v"
|
||||
android:key="themeMode"
|
||||
android:title="@string/theme_mode"
|
||||
android:summary="切换浅色/深色/跟随系统" />
|
||||
|
||||
<io.legato.kazusa.lib.prefs.NameListPreference
|
||||
android:defaultValue="0"
|
||||
android:entries="@array/screen_direction_title"
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
<io.legato.kazusa.lib.prefs.PreferenceCategory
|
||||
android:title="@string/setting"
|
||||
app:allowDividerAbove="true"
|
||||
app:allowDividerAbove="false"
|
||||
app:allowDividerBelow="false"
|
||||
app:iconSpaceReserved="false"
|
||||
app:layout="@layout/view_preference_category">
|
||||
@@ -53,7 +53,7 @@
|
||||
|
||||
<io.legato.kazusa.lib.prefs.PreferenceCategory
|
||||
android:title="规则"
|
||||
app:allowDividerAbove="true"
|
||||
app:allowDividerAbove="false"
|
||||
app:allowDividerBelow="false"
|
||||
app:iconSpaceReserved="false"
|
||||
app:layout="@layout/view_preference_category">
|
||||
@@ -84,7 +84,7 @@
|
||||
<io.legato.kazusa.lib.prefs.PreferenceCategory
|
||||
android:key="aboutCategory"
|
||||
android:title="@string/other"
|
||||
app:allowDividerAbove="true"
|
||||
app:allowDividerAbove="false"
|
||||
app:allowDividerBelow="false"
|
||||
app:iconSpaceReserved="false"
|
||||
app:layout="@layout/view_preference_category">
|
||||
|
||||
Reference in new issue
Block a user