Skip to content

Commit

Permalink
Fix: Card Browser Border and Header Height.
Browse files Browse the repository at this point in the history
  • Loading branch information
argon2r committed Feb 2, 2025
1 parent b0d7b48 commit 2c3f0de
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 28 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -102,10 +102,6 @@ class BrowserMultiColumnAdapter(
inflate(R.layout.browser_column_cell).apply {
columnViews.add(this as TextView)
}

if (index <= value) {
inflate(R.layout.browser_column_divider)
}
}

columnViews.forEach { it.setupTextSize() }
Expand Down
15 changes: 15 additions & 0 deletions AnkiDroid/src/main/res/drawable/browser_heading_bottom_divider.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape android:shape="rectangle">
<solid android:color="@android:color/transparent" />
</shape>
</item>

<item android:gravity="bottom">
<shape android:shape="rectangle">
<size android:height="1dp" />
<solid android:color="?attr/cardBrowserDivider" />
</shape>
</item>
</layer-list>
2 changes: 1 addition & 1 deletion AnkiDroid/src/main/res/layout/browser_column_cell.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:paddingStart="4dp"
android:paddingStart="8dp"
android:paddingVertical="1dp"
android:layout_gravity="top"
/>
20 changes: 0 additions & 20 deletions AnkiDroid/src/main/res/layout/browser_column_divider.xml

This file was deleted.

5 changes: 3 additions & 2 deletions AnkiDroid/src/main/res/layout/browser_column_heading.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,10 @@
<com.ichi2.ui.FixedTextView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="0dp"
android:layout_height="match_parent"
android:minHeight="48dp"
android:layout_weight="1"
android:textFontWeight="700"
android:paddingStart="4dp"
android:paddingStart="8dp"
android:textAppearance="@style/TextAppearance.AppCompat.Widget.TextView.SpinnerItem"
android:layout_gravity="center_vertical"
android:gravity="center_vertical"
/>
2 changes: 1 addition & 1 deletion AnkiDroid/src/main/res/layout/card_browser.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<LinearLayout
android:id="@+id/browser_column_headings"
android:layout_width="match_parent"
android:background="?attr/selectableItemBackground"
android:background="@drawable/browser_heading_bottom_divider"
android:orientation="horizontal"
android:paddingVertical="2dp"
android:layout_height="wrap_content"
Expand Down

0 comments on commit 2c3f0de

Please sign in to comment.