235 lines
9.8 KiB
XML
235 lines
9.8 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<android.support.constraint.ConstraintLayout
|
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
xmlns:tools="http://schemas.android.com/tools"
|
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
tools:context="com.kauron.newssarcher.MainActivity">
|
|
|
|
<EditText
|
|
android:id="@+id/editText"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginBottom="8dp"
|
|
android:layout_marginEnd="8dp"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:ems="10"
|
|
android:hint="@string/query"
|
|
android:imeOptions="actionSearch"
|
|
android:inputType="text"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
app:layout_constraintVertical_bias="0.4"
|
|
app:layout_constraintBottom_toTopOf="@+id/horizontalScrollView"
|
|
app:layout_constraintRight_toLeftOf="@+id/imageButton"
|
|
android:layout_marginRight="8dp" />
|
|
|
|
<CheckBox
|
|
android:id="@+id/stopwordsCheck"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginEnd="8dp"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginRight="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:text="@string/remove_stopwords"
|
|
app:layout_constraintHorizontal_bias="0.0"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
app:layout_constraintTop_toBottomOf="@+id/stemmingCheck" />
|
|
|
|
<CheckBox
|
|
android:id="@+id/stemmingCheck"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginRight="8dp"
|
|
android:text="@string/stemming"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginEnd="8dp"
|
|
app:layout_constraintHorizontal_bias="0.0"
|
|
android:layout_marginTop="8dp"
|
|
app:layout_constraintTop_toBottomOf="@+id/horizontalScrollView" />
|
|
|
|
<HorizontalScrollView
|
|
android:id="@+id/horizontalScrollView"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginEnd="8dp"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginRight="8dp"
|
|
android:layout_marginStart="8dp"
|
|
app:layout_constraintHorizontal_bias="0.0"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
android:layout_marginTop="8dp"
|
|
app:layout_constraintTop_toBottomOf="@+id/imageButton">
|
|
|
|
<LinearLayout
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
style="?android:buttonBarStyle"
|
|
android:orientation="horizontal">
|
|
|
|
<Button
|
|
android:id="@+id/button"
|
|
style="?android:attr/buttonBarButtonStyle"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:layout_weight="1"
|
|
android:onClick="onSymbolClick"
|
|
android:text="@string/asterisk"
|
|
app:layout_constraintLeft_toRightOf="@+id/button2"
|
|
app:layout_constraintTop_toBottomOf="@+id/editText" />
|
|
|
|
<Button
|
|
android:id="@+id/button2"
|
|
style="?android:attr/buttonBarButtonStyle"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:layout_weight="1"
|
|
android:onClick="onSymbolClick"
|
|
android:text="@string/question_mark"
|
|
app:layout_constraintLeft_toRightOf="@+id/button2"
|
|
app:layout_constraintTop_toBottomOf="@+id/editText" />
|
|
|
|
<Button
|
|
android:id="@+id/button3"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:onClick="onBoolClick"
|
|
android:text="@string/and_search"
|
|
style="?android:attr/buttonBarButtonStyle"
|
|
app:layout_constraintLeft_toRightOf="@+id/button2"
|
|
app:layout_constraintTop_toBottomOf="@+id/editText" />
|
|
|
|
<Button
|
|
android:id="@+id/button4"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:onClick="onBoolClick"
|
|
android:text="@string/or_search"
|
|
style="?android:attr/buttonBarButtonStyle"
|
|
app:layout_constraintLeft_toRightOf="@+id/button3"
|
|
app:layout_constraintTop_toBottomOf="@+id/editText" />
|
|
|
|
<Button
|
|
android:id="@+id/button8"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:layout_weight="1"
|
|
android:onClick="onBoolClick"
|
|
android:text="@string/not_search"
|
|
style="?android:attr/buttonBarButtonStyle"
|
|
app:layout_constraintLeft_toRightOf="@+id/button3"
|
|
app:layout_constraintTop_toBottomOf="@+id/editText" />
|
|
|
|
<Button
|
|
android:id="@+id/button7"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:layout_weight="1"
|
|
android:onClick="onFieldClick"
|
|
android:text="@string/category_search"
|
|
style="?android:attr/buttonBarButtonStyle"
|
|
app:layout_constraintLeft_toRightOf="@+id/button3"
|
|
app:layout_constraintTop_toBottomOf="@+id/editText"
|
|
android:layout_marginBottom="0dp" />
|
|
|
|
<Button
|
|
android:id="@+id/button6"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:layout_weight="1"
|
|
android:onClick="onFieldClick"
|
|
android:text="@string/headline_search"
|
|
style="?android:attr/buttonBarButtonStyle"
|
|
app:layout_constraintLeft_toRightOf="@+id/button3"
|
|
app:layout_constraintTop_toBottomOf="@+id/editText" />
|
|
|
|
<Button
|
|
android:id="@+id/button5"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:layout_weight="1"
|
|
android:onClick="onFieldClick"
|
|
android:text="@string/date_search"
|
|
style="?android:attr/buttonBarButtonStyle"
|
|
app:layout_constraintLeft_toRightOf="@+id/button3"
|
|
app:layout_constraintTop_toBottomOf="@+id/editText" />
|
|
|
|
</LinearLayout>
|
|
</HorizontalScrollView>
|
|
|
|
<TextView
|
|
android:id="@+id/textView"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:text="@string/click_to_see_the_result_long_click_to_copy"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
android:layout_marginTop="8dp"
|
|
app:layout_constraintTop_toBottomOf="@+id/stopwordsCheck" />
|
|
|
|
<ListView
|
|
android:id="@+id/listView"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginEnd="8dp"
|
|
android:layout_marginLeft="8dp"
|
|
android:layout_marginRight="8dp"
|
|
android:layout_marginStart="8dp"
|
|
app:layout_constraintHorizontal_bias="0.0"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
android:layout_marginTop="8dp"
|
|
app:layout_constraintTop_toBottomOf="@+id/textView" />
|
|
|
|
<ImageButton
|
|
android:id="@+id/imageButton"
|
|
style="@style/Widget.AppCompat.ImageButton"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginRight="8dp"
|
|
android:layout_marginStart="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:contentDescription="@string/search"
|
|
android:onClick="onButtonClick"
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
app:srcCompat="@drawable/ic_search_black_24dp"
|
|
android:layout_marginLeft="8dp" />
|
|
|
|
</android.support.constraint.ConstraintLayout>
|