Commit b5769c213db8e6f4438f32889036aa52d1257d08

Authored by shixianjie
1 parent 79ce9240dd
Exists in master

日报布局修改

.idea/deploymentTargetDropDown.xml
... ... @@ -3,7 +3,20 @@
3 3 <component name="deploymentTargetDropDown">
4 4 <value>
5 5 <entry key="app">
6   - <State />
  6 + <State>
  7 + <runningDeviceTargetSelectedWithDropDown>
  8 + <Target>
  9 + <type value="RUNNING_DEVICE_TARGET" />
  10 + <deviceKey>
  11 + <Key>
  12 + <type value="SERIAL_NUMBER" />
  13 + <value value="951f9ace" />
  14 + </Key>
  15 + </deviceKey>
  16 + </Target>
  17 + </runningDeviceTargetSelectedWithDropDown>
  18 + <timeTargetWasSelectedWithDropDown value="2024-10-11T03:19:45.857926300Z" />
  19 + </State>
7 20 </entry>
8 21 </value>
9 22 </component>
... ...
app/src/main/AndroidManifest.xml
... ... @@ -156,8 +156,7 @@
156 156 <activity android:name=".HomeworkSelectActivity" />
157 157 <activity android:name=".HomeworkFeedbackActivity" />
158 158 <activity android:name=".HomeworkTopicActivity" />
159   - <activity android:name=".HomeworkShareActivity"
160   - android:screenOrientation="landscape"/>
  159 + <activity android:name=".HomeworkShareActivity" />
161 160 <activity android:name=".HuyouDetailActivity" />
162 161  
163 162 <provider
... ...
app/src/main/java/com/hjx/parent/HomeworkShareActivity.java
... ... @@ -67,10 +67,10 @@ public class HomeworkShareActivity extends BaseRxActivity&lt;ActivityHomeworkShareB
67 67 binding.tvTitle.setText(title);
68 68 student = (Student) getIntent().getSerializableExtra("student");
69 69 assert student != null;
70   - binding.tvName.setText(student.stuName);
  70 + binding.tvStuName.setText(student.stuName);
71 71 Glide.with(this).load(student.photo).centerCrop().error(R.mipmap.ic_avatar_male).into(binding.ivAvatar);
72   - binding.tvGrade.setText("学员年级:" + getIntent().getStringExtra("grade"));
73   - binding.tvSubject.setText("作业科目:" + getIntent().getStringExtra("subject"));
  72 + binding.tvGrade.setText(getIntent().getStringExtra("grade"));
  73 + binding.tvSubject.setText(getIntent().getStringExtra("subject"));
74 74  
75 75 binding.btnShare.setOnClickListener(v -> {
76 76 if (shareUri == null) shareUri = saveBitmap();
... ... @@ -106,8 +106,8 @@ public class HomeworkShareActivity extends BaseRxActivity&lt;ActivityHomeworkShareB
106 106 }
107 107 @SuppressLint({"SetTextI18n", "DefaultLocale"})
108 108 private void showHomework(HomeworkDetail detail) {
109   - SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd", Locale.CHINA);
110   - binding.tvDate.setText("作业时间:" + format.format(detail.getDate()));
  109 + SimpleDateFormat format = new SimpleDateFormat("yyyy.M.d", Locale.CHINA);
  110 + binding.tvDate.setText(format.format(detail.getDate()));
111 111 binding.flComment.setVisibility(detail.getComment() == null || detail.getComment().isEmpty() ? View.INVISIBLE : View.VISIBLE);
112 112 binding.tvComment.setText(ifEmpty(detail.getComment(), "-"));
113 113 binding.tvRating.setText("-");
... ... @@ -177,7 +177,9 @@ public class HomeworkShareActivity extends BaseRxActivity&lt;ActivityHomeworkShareB
177 177  
178 178 private Uri saveBitmap() {
179 179 try {
  180 +// binding.toolbar.setVisibility(View.GONE);
180 181 Bitmap bitmap = BitmapUtils.shotView(binding.viewRoot);
  182 +// binding.toolbar.setVisibility(View.VISIBLE);
181 183 String fileName = student.stuName + "_" + title;
182 184 return ContentUtil.saveBitmapToGallery(this, bitmap, fileName);
183 185 } catch (Exception e) {
... ...
app/src/main/java/com/hjx/parent/StuHomeworkActivity.java
... ... @@ -110,6 +110,8 @@ public class StuHomeworkActivity extends BaseRxActivity&lt;ActivityStudentHomeworkB
110 110 intent.putExtra("id", data.getId());
111 111 intent.putExtra("grade", data.getGrade());
112 112 intent.putExtra("subject", data.getSubject());
  113 + String name = new SimpleDateFormat("yyyy年M月d日作业", Locale.CHINA).format(data.uploadTime);
  114 + intent.putExtra("name", name);
113 115 startActivity(intent);
114 116 }
115 117 };
... ...
app/src/main/res/drawable/bg_homework_comment.xml
1 1 <?xml version="1.0" encoding="utf-8"?>
2 2 <layer-list xmlns:android="http://schemas.android.com/apk/res/android">
3 3  
4   - <item android:height="5dp"
  4 + <item android:height="2dp"
  5 + android:bottom="3dp"
5 6 android:gravity="bottom">
6 7 <shape>
7 8 <corners android:radius="8dp"/>
8   - <solid android:color="#AAD1FF"/>
  9 + <solid android:color="#489AFA"/>
9 10 </shape>
10 11 </item>
11 12  
12 13 <item android:drawable="@drawable/png_icon_statistical_comment"
13   - android:width="30dp" android:height="30dp" />
  14 + android:gravity="bottom" android:bottom="4dp" android:start="4dp"
  15 + android:width="18dp" android:height="18dp" />
14 16  
15 17  
16 18 </layer-list>
17 19 \ No newline at end of file
... ...
app/src/main/res/drawable/bg_homework_error.xml
1 1 <?xml version="1.0" encoding="utf-8"?>
2 2 <layer-list xmlns:android="http://schemas.android.com/apk/res/android">
3 3  
4   - <item android:height="5dp"
  4 + <item android:height="2dp"
  5 + android:bottom="3dp"
5 6 android:gravity="bottom">
6 7 <shape>
7 8 <corners android:radius="8dp"/>
8   - <solid android:color="#AAD1FF"/>
  9 + <solid android:color="#489AFA"/>
9 10 </shape>
10 11 </item>
11 12  
12 13 <item android:drawable="@drawable/png_icon_statistical_error"
13   - android:width="30dp" android:height="30dp" />
  14 + android:gravity="bottom" android:bottom="4dp" android:start="4dp"
  15 + android:width="18dp" android:height="18dp" />
14 16  
15 17  
16 18 </layer-list>
17 19 \ No newline at end of file
... ...
app/src/main/res/drawable/bg_homework_eval.xml
1 1 <?xml version="1.0" encoding="utf-8"?>
2 2 <layer-list xmlns:android="http://schemas.android.com/apk/res/android">
3 3  
4   - <item android:height="5dp"
  4 + <item android:height="2dp"
  5 + android:bottom="3dp"
5 6 android:gravity="bottom">
6 7 <shape>
7 8 <corners android:radius="8dp"/>
8   - <solid android:color="#AAD1FF"/>
  9 + <solid android:color="#489AFA"/>
9 10 </shape>
10 11 </item>
11 12  
12 13 <item android:drawable="@drawable/png_icon_statistical_evaluate"
13   - android:width="30dp" android:height="30dp" />
  14 + android:gravity="bottom" android:bottom="4dp" android:start="4dp"
  15 + android:width="18dp" android:height="18dp" />
14 16  
15 17  
16 18 </layer-list>
17 19 \ No newline at end of file
... ...
app/src/main/res/drawable/png_iv_grade.png

5.4 KB

app/src/main/res/drawable/png_share_top.png

81 KB

app/src/main/res/layout/activity_homework_share.xml
... ... @@ -4,367 +4,461 @@
4 4 xmlns:app="http://schemas.android.com/apk/res-auto"
5 5 xmlns:tools="http://schemas.android.com/tools"
6 6 android:orientation="vertical"
7   - android:background="@drawable/bg_service"
  7 + android:background="#489AFA"
8 8 android:layout_width="match_parent"
9 9 android:layout_height="match_parent"
10 10 tools:ignore="HardcodedText,ContentDescription">
11 11  
12   - <androidx.appcompat.widget.Toolbar
13   - app:contentInsetStart="0px"
14   - android:paddingTop="16dp"
15   - android:layout_width="match_parent"
16   - android:layout_height="70dp">
17   - <androidx.appcompat.widget.AppCompatImageView
18   - android:id="@+id/btnBack"
19   - android:tint="@color/white"
20   - android:src="@drawable/svg_arrow_head_start_black"
21   - android:layout_width="48dp"
22   - android:layout_height="wrap_content"/>
23   -
24   - <TextView
25   - android:id="@+id/tvTitle"
26   - android:text="-"
27   - android:textSize="20sp"
28   - android:textColor="@color/white"
29   - android:textStyle="bold"
30   - android:layout_gravity="center"
31   - android:layout_width="wrap_content"
32   - android:layout_height="wrap_content"/>
33   -
34   - <TextView
35   - android:id="@+id/btnShare"
36   - android:text="分享"
37   - android:textSize="15sp"
38   - android:textColor="@color/black"
39   - android:paddingHorizontal="15dp"
40   - android:paddingVertical="5dp"
41   - android:background="@drawable/shape_circle"
42   - android:backgroundTint="#FCDC28"
43   - android:layout_marginEnd="25dp"
44   - android:layout_width="wrap_content"
45   - android:layout_height="wrap_content"
46   - android:layout_gravity="end|center_vertical" />
47   - </androidx.appcompat.widget.Toolbar>
48   -
49 12 <androidx.core.widget.NestedScrollView
50   - android:layout_marginHorizontal="16dp"
51 13 android:layout_width="match_parent"
52 14 android:layout_height="match_parent">
53 15 <LinearLayout
54 16 android:id="@+id/viewRoot"
55 17 android:orientation="vertical"
56   - android:background="@drawable/bg_statistical_once_content"
57   - android:paddingVertical="8dp"
58 18 android:paddingHorizontal="16dp"
59   - android:layout_marginBottom="16dp"
  19 + android:paddingVertical="16dp"
  20 + android:background="#489AFA"
60 21 android:layout_width="match_parent"
61 22 android:layout_height="wrap_content">
62   - <androidx.constraintlayout.utils.widget.ImageFilterView
63   - android:id="@+id/ivAvatar"
64   - app:round="888dp"
65   - android:background="#ddd"
66   - android:layout_width="50dp"
67   - android:layout_height="50dp"
68   - android:layout_gravity="center_horizontal"
69   - android:layout_marginVertical="8dp"/>
70   - <TextView
71   - android:id="@+id/tvName"
72   - android:text="-"
73   - android:textSize="20sp"
74   - android:textColor="#333"
75   - android:textStyle="bold"
76   - android:layout_gravity="center_horizontal"
77   - android:layout_width="wrap_content"
78   - android:layout_height="wrap_content"
79   - android:layout_marginVertical="8dp"/>
80   - <LinearLayout
81   - android:layout_width="match_parent"
82   - android:layout_height="wrap_content"
83   - android:layout_marginVertical="8dp">
84   - <TextView
85   - android:id="@+id/tvGrade"
86   - android:text="学员年级:-"
87   - android:textSize="15sp"
88   - android:textColor="#333"
89   - android:gravity="center_horizontal"
90   - android:layout_width="0dp"
91   - android:layout_height="wrap_content"
92   - android:layout_weight="1"/>
93   - <TextView
94   - android:id="@+id/tvSubject"
95   - android:text="作业科目:-"
96   - android:textSize="15sp"
97   - android:textColor="#333"
98   - android:gravity="center_horizontal"
99   - android:layout_width="0dp"
100   - android:layout_height="wrap_content"
101   - android:layout_weight="1"/>
102   - <TextView
103   - android:id="@+id/tvDate"
104   - android:text="作业时间:-"
105   - android:textSize="15sp"
106   - android:textColor="#333"
107   - android:gravity="center_horizontal"
108   - android:layout_width="0dp"
109   - android:layout_height="wrap_content"
110   - android:layout_weight="1"/>
111   - </LinearLayout>
112   -
113   - <TextView
114   - android:text="作业总评"
115   - android:textSize="20sp"
116   - android:textStyle="bold"
117   - android:textColor="#333"
118   - android:paddingStart="36dp"
119   - android:paddingEnd="0dp"
120   - android:background="@drawable/bg_homework_eval"
121   - android:layout_width="wrap_content"
122   - android:layout_height="wrap_content"
123   - android:layout_marginTop="20dp"/>
124 23  
125   - <androidx.constraintlayout.widget.ConstraintLayout
126   - android:background="@drawable/shape_radius_5"
127   - android:backgroundTint="#F4FAFF"
  24 + <androidx.appcompat.widget.Toolbar
  25 + android:id="@+id/toolbar"
  26 + app:contentInsetStart="0px"
128 27 android:layout_width="match_parent"
129   - android:layout_height="80dp"
130   - android:layout_marginTop="16dp">
131   - <androidx.constraintlayout.widget.Guideline
132   - android:id="@+id/guidVCenter"
133   - android:orientation="horizontal"
134   - app:layout_constraintGuide_percent="0.53"
135   - android:layout_width="0dp"
136   - android:layout_height="0dp"/>
137   - <View
138   - android:id="@+id/line1"
139   - android:background="#9ECAFC"
140   - android:layout_width="1dp"
141   - android:layout_height="match_parent"
142   - android:layout_marginVertical="8dp"
143   - app:layout_constraintStart_toStartOf="parent"
144   - app:layout_constraintEnd_toStartOf="@id/line2"/>
145   - <View
146   - android:id="@+id/line2"
147   - android:background="#9ECAFC"
148   - android:layout_width="1dp"
149   - android:layout_height="match_parent"
150   - android:layout_marginVertical="8dp"
151   - app:layout_constraintStart_toEndOf="@id/line1"
152   - app:layout_constraintEnd_toEndOf="parent"/>
153   -
154   - <!-- 作业正确率 -->
155   -
156   - <ImageView
157   - android:id="@+id/ic1"
158   - android:src="@drawable/png_icon_statistical_accuracy"
159   - android:layout_width="38sp"
160   - android:layout_height="44sp"
161   - app:layout_constraintTop_toTopOf="parent"
162   - app:layout_constraintBottom_toBottomOf="parent"
163   - app:layout_constraintStart_toStartOf="parent"
164   - app:layout_constraintEnd_toStartOf="@id/tx1"
165   - app:layout_constraintHorizontal_chainStyle="packed"/>
166   - <TextView
167   - android:id="@+id/tx1"
168   - android:text="作业正确率"
169   - android:textSize="15sp"
170   - android:textColor="#333"
171   - android:textStyle="bold"
  28 + android:layout_height="56dp">
  29 + <androidx.appcompat.widget.AppCompatImageView
  30 + android:id="@+id/btnBack"
  31 + android:tint="@color/white"
  32 + android:src="@drawable/svg_arrow_head_start_black"
  33 + android:paddingEnd="16dp"
172 34 android:layout_width="wrap_content"
173   - android:layout_height="wrap_content"
174   - android:layout_marginStart="14dp"
175   - app:layout_constraintTop_toTopOf="@id/guidVCenter"
176   - app:layout_constraintStart_toEndOf="@id/ic1"
177   - app:layout_constraintEnd_toStartOf="@id/line1"
178   - app:layout_constraintHorizontal_chainStyle="packed"/>
  35 + android:layout_height="wrap_content"/>
  36 +
179 37 <TextView
180   - android:id="@+id/tvPercent"
  38 + android:id="@+id/tvTitle"
181 39 android:text="-"
182   - android:textSize="25sp"
183   - android:textColor="#489AFA"
  40 + android:textSize="18sp"
  41 + android:singleLine="true"
  42 + android:ellipsize="middle"
  43 + android:textColor="@color/white"
184 44 android:textStyle="bold"
  45 + android:layout_gravity="center"
185 46 android:layout_width="wrap_content"
186   - android:layout_height="wrap_content"
187   - android:layout_marginBottom="-2dp"
188   - app:layout_constraintBottom_toBottomOf="@id/guidVCenter"
189   - app:layout_constraintStart_toStartOf="@id/tx1"
190   - app:layout_constraintEnd_toStartOf="@id/tv11"
191   - app:layout_constraintHorizontal_chainStyle="packed"/>
  47 + android:layout_height="wrap_content"/>
  48 +
192 49 <TextView
193   - android:id="@+id/tv11"
194   - android:text="%"
  50 + android:id="@+id/btnShare"
  51 + android:text="分享"
195 52 android:textSize="15sp"
196   - android:textColor="#489AFA"
197   - android:textStyle="bold"
  53 + android:textColor="@color/black"
  54 + android:paddingHorizontal="15dp"
  55 + android:paddingVertical="5dp"
  56 + android:background="@drawable/shape_circle"
  57 + android:backgroundTint="#FCDC28"
198 58 android:layout_width="wrap_content"
199 59 android:layout_height="wrap_content"
200   - app:layout_constraintBaseline_toBaselineOf="@id/tvPercent"
201   - app:layout_constraintStart_toEndOf="@id/tvPercent"
202   - app:layout_constraintEnd_toEndOf="@id/tx1"
203   - app:layout_constraintHorizontal_chainStyle="packed"/>
  60 + android:layout_gravity="end|center_vertical" />
  61 + </androidx.appcompat.widget.Toolbar>
  62 +
  63 + <ImageView
  64 + android:src="@drawable/png_share_top"
  65 + android:elevation="1dp"
  66 + android:layout_gravity="end"
  67 + android:layout_marginEnd="5dp"
  68 + android:layout_width="90dp"
  69 + android:layout_height="80dp"/>
204 70  
205   - <!-- 答对题数 -->
  71 + <LinearLayout
  72 + android:orientation="vertical"
  73 + android:background="@drawable/png_info_bg"
  74 + android:paddingHorizontal="16dp"
  75 + android:paddingVertical="16dp"
  76 + android:layout_marginTop="-70dp"
  77 + android:layout_width="match_parent"
  78 + android:layout_height="144dp">
  79 + <LinearLayout
  80 + android:orientation="horizontal"
  81 + android:layout_width="match_parent"
  82 + android:layout_height="wrap_content">
  83 + <androidx.constraintlayout.utils.widget.ImageFilterView
  84 + android:id="@+id/ivAvatar"
  85 + tools:background="#2491FF"
  86 + app:round="40dp"
  87 + android:layout_width="40dp"
  88 + android:layout_height="40dp"/>
  89 + <TextView
  90 + android:id="@+id/tvStuName"
  91 + tools:text="杨同学 "
  92 + android:textSize="14sp"
  93 + android:textColor="#333"
  94 + android:textStyle="bold"
  95 + android:layout_marginStart="8dp"
  96 + android:layout_gravity="center_vertical"
  97 + android:layout_width="wrap_content"
  98 + android:layout_height="wrap_content"/>
  99 + </LinearLayout>
  100 + <LinearLayout
  101 + android:orientation="horizontal"
  102 + android:background="@drawable/shape_radius_10"
  103 + android:backgroundTint="#F4FAFF"
  104 + android:layout_marginTop="12dp"
  105 + android:layout_width="match_parent"
  106 + android:layout_height="60dp">
  107 + <LinearLayout
  108 + android:orientation="vertical"
  109 + android:gravity="center"
  110 + android:layout_width="0dp"
  111 + android:layout_height="match_parent"
  112 + android:layout_weight="1">
  113 + <LinearLayout
  114 + android:paddingEnd="20dp"
  115 + android:gravity="center_vertical"
  116 + android:layout_width="wrap_content"
  117 + android:layout_height="wrap_content">
  118 + <ImageView
  119 + android:src="@drawable/png_iv_grade"
  120 + android:layout_marginEnd="5dp"
  121 + android:layout_width="16dp"
  122 + android:layout_height="14dp"/>
  123 + <TextView
  124 + android:text="年级"
  125 + android:textSize="12sp"
  126 + android:textColor="#333"
  127 + android:textStyle="bold"
  128 + android:layout_width="wrap_content"
  129 + android:layout_height="wrap_content"/>
  130 + </LinearLayout>
  131 + <TextView
  132 + android:id="@+id/tvGrade"
  133 + tools:text="七年级"
  134 + android:textSize="12sp"
  135 + android:textColor="#489AFA"
  136 + android:textStyle="bold"
  137 + android:layout_marginTop="8dp"
  138 + android:layout_width="wrap_content"
  139 + android:layout_height="wrap_content"/>
  140 + </LinearLayout>
  141 + <LinearLayout
  142 + android:orientation="vertical"
  143 + android:gravity="center"
  144 + android:layout_width="0dp"
  145 + android:layout_height="match_parent"
  146 + android:layout_weight="1">
  147 + <LinearLayout
  148 + android:paddingEnd="20dp"
  149 + android:gravity="center_vertical"
  150 + android:layout_width="wrap_content"
  151 + android:layout_height="wrap_content">
  152 + <ImageView
  153 + android:src="@drawable/png_iv_subject"
  154 + android:layout_marginEnd="5dp"
  155 + android:layout_width="16dp"
  156 + android:layout_height="14dp"/>
  157 + <TextView
  158 + android:text="学科"
  159 + android:textSize="12sp"
  160 + android:textColor="#333"
  161 + android:textStyle="bold"
  162 + android:layout_width="wrap_content"
  163 + android:layout_height="wrap_content"/>
  164 + </LinearLayout>
  165 + <TextView
  166 + android:id="@+id/tvSubject"
  167 + tools:text="数学"
  168 + android:textSize="12sp"
  169 + android:textColor="#489AFA"
  170 + android:textStyle="bold"
  171 + android:layout_marginTop="8dp"
  172 + android:layout_width="wrap_content"
  173 + android:layout_height="wrap_content"/>
  174 + </LinearLayout>
  175 + <LinearLayout
  176 + android:orientation="vertical"
  177 + android:gravity="center"
  178 + android:layout_width="0dp"
  179 + android:layout_height="match_parent"
  180 + android:layout_weight="1">
  181 + <LinearLayout
  182 + android:paddingEnd="20dp"
  183 + android:gravity="center_vertical"
  184 + android:layout_width="wrap_content"
  185 + android:layout_height="wrap_content">
  186 + <ImageView
  187 + android:src="@drawable/png_ic_during"
  188 + android:layout_marginEnd="5dp"
  189 + android:layout_width="14dp"
  190 + android:layout_height="13dp"/>
  191 + <TextView
  192 + android:text="周期"
  193 + android:textSize="12sp"
  194 + android:textColor="#333"
  195 + android:textStyle="bold"
  196 + android:layout_width="wrap_content"
  197 + android:layout_height="wrap_content"/>
  198 + </LinearLayout>
  199 + <TextView
  200 + android:id="@+id/tvDate"
  201 + tools:text="2024.09.01"
  202 + android:textSize="12sp"
  203 + android:textColor="#489AFA"
  204 + android:textStyle="bold"
  205 + android:layout_marginTop="8dp"
  206 + android:layout_width="wrap_content"
  207 + android:layout_height="wrap_content"/>
  208 + </LinearLayout>
  209 + </LinearLayout>
  210 + </LinearLayout>
206 211  
207   - <ImageView
208   - android:id="@+id/ic2"
209   - android:src="@drawable/png_icon_statistical_correct"
210   - android:layout_width="38sp"
211   - android:layout_height="44sp"
212   - app:layout_constraintTop_toTopOf="parent"
213   - app:layout_constraintBottom_toBottomOf="parent"
214   - app:layout_constraintStart_toStartOf="@id/line1"
215   - app:layout_constraintEnd_toStartOf="@id/tx2"
216   - app:layout_constraintHorizontal_chainStyle="packed"/>
  212 + <LinearLayout
  213 + android:orientation="vertical"
  214 + android:background="@drawable/shape_radius_10"
  215 + android:backgroundTint="@color/white"
  216 + android:paddingHorizontal="16dp"
  217 + android:paddingBottom="16dp"
  218 + android:layout_marginTop="12dp"
  219 + android:layout_width="match_parent"
  220 + android:layout_height="wrap_content">
217 221 <TextView
218   - android:id="@+id/tx2"
219   - android:text="答对题数"
220   - android:textSize="15sp"
221   - android:textColor="#333"
  222 + android:text="作业总评"
  223 + android:textSize="16sp"
222 224 android:textStyle="bold"
  225 + android:textColor="#333"
  226 + android:paddingStart="24dp"
  227 + android:paddingEnd="4dp"
  228 + android:paddingTop="4dp"
  229 + android:background="@drawable/bg_homework_eval"
  230 + android:layout_gravity="center_horizontal"
  231 + android:layout_marginTop="12dp"
223 232 android:layout_width="wrap_content"
224   - android:layout_height="wrap_content"
225   - android:layout_marginStart="14dp"
226   - app:layout_constraintTop_toTopOf="@id/guidVCenter"
227   - app:layout_constraintStart_toEndOf="@id/ic2"
228   - app:layout_constraintEnd_toStartOf="@id/line2"
229   - app:layout_constraintHorizontal_chainStyle="packed"/>
  233 + android:layout_height="wrap_content"/>
  234 +
  235 + <LinearLayout
  236 + android:orientation="horizontal"
  237 + android:background="@drawable/shape_radius_5"
  238 + android:backgroundTint="#F4FAFF"
  239 + android:layout_width="match_parent"
  240 + android:layout_height="80dp"
  241 + android:layout_marginTop="12dp">
  242 + <LinearLayout
  243 + android:orientation="vertical"
  244 + android:gravity="center"
  245 + android:layout_width="0dp"
  246 + android:layout_height="match_parent"
  247 + android:layout_weight="1">
  248 + <LinearLayout
  249 + android:orientation="horizontal"
  250 + android:gravity="center_vertical"
  251 + android:layout_width="wrap_content"
  252 + android:layout_height="wrap_content">
  253 + <ImageView
  254 + android:src="@drawable/png_icon_statistical_accuracy"
  255 + android:layout_width="12dp"
  256 + android:layout_height="13dp"/>
  257 + <TextView
  258 + android:text="作业正确率"
  259 + android:textSize="11sp"
  260 + android:textColor="#333"
  261 + android:textStyle="bold"
  262 + android:layout_marginStart="5dp"
  263 + android:layout_width="wrap_content"
  264 + android:layout_height="wrap_content"/>
  265 + </LinearLayout>
  266 + <LinearLayout
  267 + android:orientation="horizontal"
  268 + android:layout_marginTop="8dp"
  269 + android:layout_width="wrap_content"
  270 + android:layout_height="wrap_content">
  271 + <TextView
  272 + android:id="@+id/tvPercent"
  273 + tools:text="88"
  274 + android:textSize="14sp"
  275 + android:textColor="#489AFA"
  276 + android:textStyle="bold"
  277 + android:layout_width="wrap_content"
  278 + android:layout_height="wrap_content"/>
  279 + <TextView
  280 + android:text="%"
  281 + android:textSize="9sp"
  282 + android:textColor="#489AFA"
  283 + android:textStyle="bold"
  284 + android:layout_width="wrap_content"
  285 + android:layout_height="wrap_content"/>
  286 + </LinearLayout>
  287 + </LinearLayout>
  288 + <LinearLayout
  289 + android:orientation="vertical"
  290 + android:gravity="center"
  291 + android:layout_width="0dp"
  292 + android:layout_height="match_parent"
  293 + android:layout_weight="1">
  294 + <LinearLayout
  295 + android:orientation="horizontal"
  296 + android:gravity="center_vertical"
  297 + android:layout_width="wrap_content"
  298 + android:layout_height="wrap_content">
  299 + <ImageView
  300 + android:src="@drawable/png_icon_statistical_accuracy"
  301 + android:layout_width="12dp"
  302 + android:layout_height="13dp"/>
  303 + <TextView
  304 + android:text="答对题数"
  305 + android:textSize="11sp"
  306 + android:textColor="#333"
  307 + android:textStyle="bold"
  308 + android:layout_marginStart="5dp"
  309 + android:layout_width="wrap_content"
  310 + android:layout_height="wrap_content"/>
  311 + </LinearLayout>
  312 + <LinearLayout
  313 + android:orientation="horizontal"
  314 + android:layout_marginTop="8dp"
  315 + android:layout_width="wrap_content"
  316 + android:layout_height="wrap_content">
  317 + <TextView
  318 + android:id="@+id/tvCorrect"
  319 + tools:text="88"
  320 + android:textSize="14sp"
  321 + android:textColor="#489AFA"
  322 + android:textStyle="bold"
  323 + android:layout_width="wrap_content"
  324 + android:layout_height="wrap_content"/>
  325 + <TextView
  326 + android:text="道"
  327 + android:textSize="9sp"
  328 + android:textColor="#489AFA"
  329 + android:textStyle="bold"
  330 + android:layout_width="wrap_content"
  331 + android:layout_height="wrap_content"/>
  332 + </LinearLayout>
  333 + </LinearLayout>
  334 + <LinearLayout
  335 + android:orientation="vertical"
  336 + android:gravity="center"
  337 + android:layout_width="0dp"
  338 + android:layout_height="match_parent"
  339 + android:layout_weight="1">
  340 + <LinearLayout
  341 + android:orientation="horizontal"
  342 + android:gravity="center_vertical"
  343 + android:layout_width="wrap_content"
  344 + android:layout_height="wrap_content">
  345 + <ImageView
  346 + android:src="@drawable/png_icon_statistical_accuracy"
  347 + android:layout_width="12dp"
  348 + android:layout_height="13dp"/>
  349 + <TextView
  350 + android:text="答错题数"
  351 + android:textSize="11sp"
  352 + android:textColor="#333"
  353 + android:textStyle="bold"
  354 + android:layout_marginStart="5dp"
  355 + android:layout_width="wrap_content"
  356 + android:layout_height="wrap_content"/>
  357 + </LinearLayout>
  358 + <LinearLayout
  359 + android:orientation="horizontal"
  360 + android:layout_marginTop="8dp"
  361 + android:layout_width="wrap_content"
  362 + android:layout_height="wrap_content">
  363 + <TextView
  364 + android:id="@+id/tvWrong"
  365 + tools:text="88"
  366 + android:textSize="14sp"
  367 + android:textColor="#489AFA"
  368 + android:textStyle="bold"
  369 + android:layout_width="wrap_content"
  370 + android:layout_height="wrap_content"/>
  371 + <TextView
  372 + android:text="道"
  373 + android:textSize="9sp"
  374 + android:textColor="#489AFA"
  375 + android:textStyle="bold"
  376 + android:layout_width="wrap_content"
  377 + android:layout_height="wrap_content"/>
  378 + </LinearLayout>
  379 + </LinearLayout>
  380 + </LinearLayout>
230 381 <TextView
231   - android:id="@+id/tvCorrect"
  382 + android:id="@+id/tvRating"
232 383 android:text="-"
233   - android:textSize="25sp"
234   - android:textColor="#489AFA"
235   - android:textStyle="bold"
236   - android:layout_width="wrap_content"
237   - android:layout_height="wrap_content"
238   - android:layout_marginBottom="-2dp"
239   - app:layout_constraintBottom_toBottomOf="@id/guidVCenter"
240   - app:layout_constraintStart_toStartOf="@id/tx2"
241   - app:layout_constraintEnd_toStartOf="@id/tv22"
242   - app:layout_constraintHorizontal_chainStyle="packed"/>
243   - <TextView
244   - android:id="@+id/tv22"
245   - android:text="道"
246   - android:textSize="15sp"
247   - android:textColor="#489AFA"
248   - android:textStyle="bold"
249   - android:layout_width="wrap_content"
  384 + android:textSize="12sp"
  385 + android:textColor="#333"
  386 + android:lineSpacingMultiplier="1.3"
  387 + android:layout_width="match_parent"
250 388 android:layout_height="wrap_content"
251   - app:layout_constraintBaseline_toBaselineOf="@id/tvCorrect"
252   - app:layout_constraintStart_toEndOf="@id/tvCorrect"
253   - app:layout_constraintEnd_toEndOf="@id/tx2"
254   - app:layout_constraintHorizontal_chainStyle="packed"/>
  389 + android:layout_marginTop="16dp"/>
  390 + </LinearLayout>
255 391  
256   - <!-- 答错题数 -->
  392 + <LinearLayout
  393 + android:orientation="vertical"
  394 + android:background="@drawable/shape_radius_10"
  395 + android:backgroundTint="@color/white"
  396 + android:paddingHorizontal="16dp"
  397 + android:paddingBottom="16dp"
  398 + android:layout_marginTop="12dp"
  399 + android:layout_width="match_parent"
  400 + android:layout_height="wrap_content">
257 401  
258   - <ImageView
259   - android:id="@+id/ic3"
260   - android:src="@drawable/png_icon_statistical_wrong"
261   - android:layout_width="38sp"
262   - android:layout_height="44sp"
263   - app:layout_constraintTop_toTopOf="parent"
264   - app:layout_constraintBottom_toBottomOf="parent"
265   - app:layout_constraintStart_toStartOf="@id/line2"
266   - app:layout_constraintEnd_toStartOf="@id/tx3"
267   - app:layout_constraintHorizontal_chainStyle="packed"/>
268 402 <TextView
269   - android:id="@+id/tx3"
270   - android:text="答错题数"
271   - android:textSize="15sp"
272   - android:textColor="#333"
273   - android:textStyle="bold"
274   - android:layout_width="wrap_content"
275   - android:layout_height="wrap_content"
276   - android:layout_marginStart="14dp"
277   - app:layout_constraintTop_toTopOf="@id/guidVCenter"
278   - app:layout_constraintStart_toEndOf="@id/ic3"
279   - app:layout_constraintEnd_toEndOf="parent"
280   - app:layout_constraintHorizontal_chainStyle="packed"/>
281   - <TextView
282   - android:id="@+id/tvWrong"
283   - android:text="-"
284   - android:textSize="25sp"
285   - android:textColor="#489AFA"
286   - android:textStyle="bold"
287   - android:layout_width="wrap_content"
288   - android:layout_height="wrap_content"
289   - android:layout_marginBottom="-2dp"
290   - app:layout_constraintBottom_toBottomOf="@id/guidVCenter"
291   - app:layout_constraintStart_toStartOf="@id/tx3"
292   - app:layout_constraintEnd_toStartOf="@id/tv33"
293   - app:layout_constraintHorizontal_chainStyle="packed"/>
294   - <TextView
295   - android:id="@+id/tv33"
296   - android:text="道"
297   - android:textSize="15sp"
298   - android:textColor="#489AFA"
  403 + android:text="作业错题"
  404 + android:textSize="16sp"
299 405 android:textStyle="bold"
  406 + android:textColor="#333"
  407 + android:paddingStart="24dp"
  408 + android:paddingEnd="4dp"
  409 + android:paddingTop="4dp"
  410 + android:background="@drawable/bg_homework_error"
  411 + android:layout_gravity="center_horizontal"
  412 + android:layout_marginTop="12dp"
300 413 android:layout_width="wrap_content"
301   - android:layout_height="wrap_content"
302   - app:layout_constraintBaseline_toBaselineOf="@id/tvWrong"
303   - app:layout_constraintStart_toEndOf="@id/tvWrong"
304   - app:layout_constraintEnd_toEndOf="@id/tx3"
305   - app:layout_constraintHorizontal_chainStyle="packed"/>
306   - </androidx.constraintlayout.widget.ConstraintLayout>
  414 + android:layout_height="wrap_content"/>
307 415  
308   - <TextView
309   - android:id="@+id/tvRating"
310   - android:text="-"
311   - android:textSize="18sp"
312   - android:textColor="#333"
313   - android:lineSpacingMultiplier="1.3"
314   - android:layout_width="match_parent"
315   - android:layout_height="wrap_content"
316   - android:layout_marginHorizontal="24dp"
317   - android:layout_marginTop="48dp"/>
318   -
319   - <TextView
320   - android:text="作业错题"
321   - android:textSize="20sp"
322   - android:textStyle="bold"
323   - android:textColor="#333"
324   - android:paddingStart="36dp"
325   - android:paddingEnd="0dp"
326   - android:background="@drawable/bg_homework_error"
327   - android:layout_width="wrap_content"
328   - android:layout_height="wrap_content"
329   - android:layout_marginTop="64dp"/>
  416 + <androidx.recyclerview.widget.RecyclerView
  417 + android:id="@+id/rvWrong"
  418 + android:orientation="vertical"
  419 + app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
  420 + android:layout_marginTop="12dp"
  421 + tools:listitem="@layout/item_homework_error"
  422 + tools:itemCount="1"
  423 + android:layout_width="match_parent"
  424 + android:layout_height="wrap_content"/>
330 425  
331   - <androidx.recyclerview.widget.RecyclerView
332   - android:id="@+id/rvWrong"
333   - android:orientation="vertical"
334   - app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
335   - android:layout_marginTop="20dp"
336   - tools:listitem="@layout/item_homework_error"
337   - tools:itemCount="1"
338   - android:layout_width="match_parent"
339   - android:layout_height="wrap_content"/>
  426 + </LinearLayout>
340 427  
341 428 <LinearLayout
342 429 android:id="@+id/flComment"
343 430 android:orientation="vertical"
  431 + android:background="@drawable/shape_radius_10"
  432 + android:backgroundTint="@color/white"
  433 + android:layout_marginTop="12dp"
344 434 android:layout_width="match_parent"
345 435 android:layout_height="wrap_content">
346 436  
347 437 <TextView
348 438 android:text="教师评语"
349   - android:textSize="20sp"
  439 + android:textSize="16sp"
350 440 android:textStyle="bold"
351 441 android:textColor="#333"
352   - android:paddingStart="36dp"
353   - android:paddingEnd="0dp"
  442 + android:paddingStart="24dp"
  443 + android:paddingEnd="4dp"
  444 + android:paddingTop="4dp"
354 445 android:background="@drawable/bg_homework_comment"
  446 + android:layout_gravity="center_horizontal"
355 447 android:layout_width="wrap_content"
356 448 android:layout_height="wrap_content"
357   - android:layout_marginTop="32dp"/>
  449 + android:layout_marginTop="12dp"/>
358 450  
359 451 <TextView
360 452 android:id="@+id/tvComment"
361 453 android:text="-"
362   - android:textSize="18sp"
  454 + android:textSize="12sp"
363 455 android:textColor="#333"
364 456 android:lineSpacingMultiplier="1.3"
  457 + android:layout_marginHorizontal="16dp"
  458 + android:layout_marginTop="12dp"
  459 + android:layout_marginBottom="16dp"
365 460 android:layout_width="match_parent"
366   - android:layout_height="wrap_content"
367   - android:layout_marginVertical="16dp"/>
  461 + android:layout_height="wrap_content"/>
368 462  
369 463 </LinearLayout>
370 464 </LinearLayout>
... ...