]> git.ktnx.net Git - mobile-ledger.git/blob - app/src/main/res/layout/template_details_account.xml
more pronounced day/month delimiters in the transaction list
[mobile-ledger.git] / app / src / main / res / layout / template_details_account.xml
1 <?xml version="1.0" encoding="utf-8"?><!--
2   ~ Copyright © 2021 Damyan Ivanov.
3   ~ This file is part of MoLe.
4   ~ MoLe is free software: you can distribute it and/or modify it
5   ~ under the term of the GNU General Public License as published by
6   ~ the Free Software Foundation, either version 3 of the License, or
7   ~ (at your opinion), any later version.
8   ~
9   ~ MoLe is distributed in the hope that it will be useful,
10   ~ but WITHOUT ANY WARRANTY; without even the implied warranty of
11   ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12   ~ GNU General Public License terms for details.
13   ~
14   ~ You should have received a copy of the GNU General Public License
15   ~ along with MoLe. If not, see <https://www.gnu.org/licenses/>.
16   -->
17
18 <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
19     xmlns:app="http://schemas.android.com/apk/res-auto"
20     android:id="@+id/pattern_details_item_account_row"
21     android:layout_width="match_parent"
22     android:layout_height="wrap_content"
23     android:animateLayoutChanges="true"
24     android:padding="@dimen/text_margin"
25     >
26     <TextView
27         android:id="@+id/pattern_account_label"
28         android:layout_width="0dp"
29         android:layout_height="wrap_content"
30         android:clickable="false"
31         android:text="@string/template_details_account_row_label"
32         android:textAppearance="?attr/textAppearanceListItem"
33         app:drawableBottomCompat="@drawable/dashed_border_8dp"
34         app:drawableStartCompat="@drawable/ic_baseline_drag_handle_24"
35         app:layout_constraintBottom_toTopOf="@id/template_account_name_source_label"
36         app:layout_constraintEnd_toEndOf="parent"
37         app:layout_constraintTop_toTopOf="parent"
38         />
39     <TextView
40         android:id="@+id/template_account_name_source_label"
41         android:layout_width="0dp"
42         android:layout_height="match_parent"
43         android:paddingTop="@dimen/text_margin"
44         android:text="@string/account_name_source_label"
45         android:textAppearance="?attr/textAppearanceListItem"
46         app:layout_constraintBottom_toTopOf="@+id/template_details_account_name_source"
47         app:layout_constraintEnd_toEndOf="parent"
48         app:layout_constraintStart_toStartOf="parent"
49         app:layout_constraintTop_toBottomOf="@id/pattern_account_label"
50         />
51     <TextView
52         android:id="@+id/template_details_account_name_source"
53         android:layout_width="0dp"
54         android:layout_height="wrap_content"
55         android:minWidth="100dp"
56         android:textAppearance="?attr/textAppearanceListItemSecondary"
57         app:layout_constraintBottom_toTopOf="@+id/template_details_account_name_layout"
58         app:layout_constraintEnd_toEndOf="parent"
59         app:layout_constraintStart_toStartOf="parent"
60         app:layout_constraintTop_toBottomOf="@id/template_account_name_source_label"
61         />
62     <com.google.android.material.textfield.TextInputLayout
63         android:id="@+id/template_details_account_name_layout"
64         android:layout_width="match_parent"
65         android:layout_height="wrap_content"
66         android:layout_marginBottom="@dimen/text_margin"
67         android:textAppearance="?attr/textAppearanceListItem"
68         app:endIconMode="clear_text"
69         app:layout_constraintBottom_toTopOf="@+id/template_account_comment_source_label"
70         app:layout_constraintEnd_toEndOf="parent"
71         app:layout_constraintStart_toStartOf="parent"
72         app:layout_constraintTop_toBottomOf="@id/template_details_account_name_source"
73         >
74         <com.google.android.material.textfield.MaterialAutoCompleteTextView
75             android:id="@+id/template_details_account_name"
76             style="@style/MoLeMaterialAutoCompleteTextViewStyle"
77             android:textAppearance="@style/TextAppearance.MaterialComponents.Body1"
78             android:layout_width="match_parent"
79             android:layout_height="wrap_content"
80             android:hint="@string/template_details_account_name_label"
81             android:inputType="text"
82             />
83     </com.google.android.material.textfield.TextInputLayout>
84
85     <TextView
86         android:id="@+id/template_account_comment_source_label"
87         android:layout_width="0dp"
88         android:layout_height="match_parent"
89         android:text="@string/account_comment_source_label"
90         android:textAppearance="?attr/textAppearanceListItem"
91         app:layout_constraintBottom_toTopOf="@+id/template_details_account_comment_source"
92         app:layout_constraintEnd_toEndOf="parent"
93         app:layout_constraintStart_toStartOf="parent"
94         app:layout_constraintTop_toBottomOf="@id/template_details_account_name_layout"
95         />
96     <TextView
97         android:id="@+id/template_details_account_comment_source"
98         android:layout_width="0dp"
99         android:layout_height="wrap_content"
100         android:minWidth="100dp"
101         android:textAppearance="?attr/textAppearanceListItemSecondary"
102         app:layout_constraintBottom_toTopOf="@+id/template_details_account_comment_layout"
103         app:layout_constraintEnd_toEndOf="parent"
104         app:layout_constraintStart_toStartOf="parent"
105         app:layout_constraintTop_toBottomOf="@id/template_account_comment_source_label"
106         />
107     <com.google.android.material.textfield.TextInputLayout
108         android:id="@+id/template_details_account_comment_layout"
109         android:layout_width="match_parent"
110         android:layout_height="wrap_content"
111         android:layout_marginBottom="@dimen/text_margin"
112         android:textAppearance="?attr/textAppearanceListItem"
113         app:endIconMode="clear_text"
114         app:layout_constraintBottom_toTopOf="@+id/template_account_amount_source_label"
115         app:layout_constraintEnd_toEndOf="parent"
116         app:layout_constraintStart_toStartOf="parent"
117         app:layout_constraintTop_toBottomOf="@id/template_details_account_comment_source"
118         >
119         <com.google.android.material.textfield.TextInputEditText
120             android:id="@+id/template_details_account_comment"
121             android:layout_width="match_parent"
122             android:layout_height="wrap_content"
123             android:hint="@string/template_details_account_comment_label"
124             android:inputType="text"
125             />
126     </com.google.android.material.textfield.TextInputLayout>
127
128     <TextView
129         android:id="@+id/template_account_amount_source_label"
130         android:layout_width="0dp"
131         android:layout_height="match_parent"
132         android:text="@string/account_amount_source_label"
133         android:textAppearance="?attr/textAppearanceListItem"
134         app:layout_constraintBottom_toTopOf="@+id/template_details_account_amount_source"
135         app:layout_constraintEnd_toStartOf="@id/negate_amount_switch"
136         app:layout_constraintStart_toStartOf="parent"
137         app:layout_constraintTop_toBottomOf="@id/template_details_account_comment_layout"
138         />
139     <TextView
140         android:id="@+id/template_details_account_amount_source"
141         android:layout_width="0dp"
142         android:layout_height="wrap_content"
143         android:textAppearance="?attr/textAppearanceListItemSecondary"
144         app:layout_constraintBottom_toTopOf="@+id/template_details_account_amount_layout"
145         app:layout_constraintEnd_toStartOf="@id/negate_amount_switch"
146         app:layout_constraintStart_toStartOf="parent"
147         app:layout_constraintTop_toBottomOf="@id/template_account_amount_source_label"
148         />
149     <com.google.android.material.textfield.TextInputLayout
150         android:id="@+id/template_details_account_amount_layout"
151         android:layout_width="match_parent"
152         android:layout_height="wrap_content"
153         android:layout_marginBottom="@dimen/text_margin"
154         android:textAppearance="?attr/textAppearanceListItem"
155         app:layout_constraintBottom_toTopOf="@id/template_details_negate_amount_label"
156         app:layout_constraintEnd_toEndOf="parent"
157         app:layout_constraintStart_toStartOf="parent"
158         app:layout_constraintTop_toBottomOf="@id/template_details_account_amount_source"
159         >
160         <com.google.android.material.textfield.TextInputEditText
161             android:id="@+id/template_details_account_amount"
162             android:layout_width="match_parent"
163             android:layout_height="wrap_content"
164             android:hint="@string/template_details_account_amount_label"
165             android:inputType="number|numberDecimal|numberSigned"
166             android:selectAllOnFocus="true"
167             />
168     </com.google.android.material.textfield.TextInputLayout>
169
170     <TextView
171         android:id="@+id/template_details_negate_amount_label"
172         android:layout_width="0dp"
173         android:layout_height="wrap_content"
174         android:layout_marginTop="@dimen/text_margin"
175         android:text="@string/template_account_negate_amount_label"
176         android:textAppearance="?attr/textAppearanceListItem"
177         app:layout_constraintBottom_toTopOf="@id/template_details_negate_amount_text"
178         app:layout_constraintEnd_toStartOf="@+id/negate_amount_switch"
179         app:layout_constraintStart_toStartOf="parent"
180         app:layout_constraintTop_toBottomOf="@id/template_details_account_amount_layout"
181         />
182     <TextView
183         android:id="@+id/template_details_negate_amount_text"
184         android:layout_width="0dp"
185         android:layout_height="wrap_content"
186         android:text="@string/template_account_keep_amount_sign"
187         android:textAppearance="?attr/textAppearanceListItemSecondary"
188         app:layout_constraintBottom_toBottomOf="parent"
189         app:layout_constraintBottom_toTopOf="@id/template_details_negate_amount_text"
190         app:layout_constraintEnd_toStartOf="@+id/negate_amount_switch"
191         app:layout_constraintStart_toStartOf="parent"
192         app:layout_constraintTop_toBottomOf="@id/template_details_negate_amount_label"
193         />
194     <com.google.android.material.switchmaterial.SwitchMaterial
195         android:id="@+id/negate_amount_switch"
196         android:layout_width="wrap_content"
197         android:layout_height="wrap_content"
198         app:layout_constraintBottom_toBottomOf="@id/template_details_negate_amount_text"
199         app:layout_constraintEnd_toEndOf="parent"
200         app:layout_constraintTop_toTopOf="@id/template_details_negate_amount_label"
201         />
202
203     <TextView
204         android:id="@+id/template_account_currency_source_label"
205         android:layout_width="0dp"
206         android:layout_height="match_parent"
207         android:layout_marginTop="@dimen/text_margin"
208         android:text="@string/account_currency_source_label"
209         android:textAppearance="?attr/textAppearanceListItem"
210         app:layout_constraintBottom_toTopOf="@+id/template_details_account_currency_source"
211         app:layout_constraintEnd_toEndOf="parent"
212         app:layout_constraintStart_toStartOf="parent"
213         app:layout_constraintTop_toBottomOf="@id/negate_amount_switch"
214         />
215     <TextView
216         android:id="@+id/template_details_account_currency_source"
217         android:layout_width="0dp"
218         android:layout_height="wrap_content"
219         android:textAppearance="?attr/textAppearanceListItemSecondary"
220         app:layout_constraintBottom_toTopOf="@+id/template_details_account_currency"
221         app:layout_constraintEnd_toEndOf="parent"
222         app:layout_constraintStart_toStartOf="parent"
223         app:layout_constraintTop_toBottomOf="@id/template_account_currency_source_label"
224         />
225     <TextView
226         android:id="@+id/template_details_account_currency"
227         android:layout_width="0dp"
228         android:layout_height="wrap_content"
229         android:layout_marginVertical="@dimen/half_text_margin"
230         app:layout_constraintBottom_toBottomOf="parent"
231         app:layout_constraintEnd_toEndOf="parent"
232         app:layout_constraintStart_toStartOf="parent"
233         app:layout_constraintTop_toBottomOf="@id/template_details_account_currency_source"
234         />
235 </androidx.constraintlayout.widget.ConstraintLayout>